/* Luckyscope website — shared styles
   Brand palette mirrors the app (Theme.swift / ZodiacData.swift):
   purple-tinted ink on warm cream, pink→orange→purple→teal gradient,
   and a dark theme matching the app's dark palette. */

:root {
  --pink:   #FF8FC4;
  --orange: #FFB23E;
  --purple: #9B7BFF;
  --teal:   #5FD3E6;
  --gold:   #FFC857;

  --cream:    #FFF6EC;
  --card:     #FFFFFF;
  --ink:      #4B2F6B;
  --ink-soft: #7A6394;
  --line:     #F0E4D8;
  --link:     #7C5BE6;

  --header-bg: rgba(255, 246, 236, 0.82);
  --glow-a: rgba(255, 143, 196, 0.35);
  --glow-b: rgba(95, 211, 230, 0.35);
  --blob-opacity: 0.30;

  --grad: linear-gradient(100deg, var(--pink), var(--orange), var(--purple), var(--teal));
  --shadow: 0 18px 40px rgba(120, 80, 170, 0.16);
  --shadow-soft: 0 10px 26px rgba(75, 47, 107, 0.07);
  --radius: 22px;
  --maxw: 780px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --cream:    #140F20;
    --card:     #241D38;
    --ink:      #EFE7FF;
    --ink-soft: #AE9CD0;
    --line:     rgba(255, 255, 255, 0.12);
    --link:     #C3AFFF;

    --header-bg: rgba(20, 15, 32, 0.80);
    --glow-a: rgba(255, 143, 196, 0.20);
    --glow-b: rgba(95, 211, 230, 0.16);
    --blob-opacity: 0.22;

    --shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
    --shadow-soft: 0 10px 26px rgba(0, 0, 0, 0.30);
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Nunito", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* soft ambient blobs */
body::before,
body::after {
  content: "";
  position: fixed;
  z-index: -1;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: var(--blob-opacity);
  pointer-events: none;
}
body::before { background: var(--pink); top: -160px; right: -120px; }
body::after  { background: var(--teal); bottom: -180px; left: -140px; }

a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--purple);
  outline-offset: 3px;
  border-radius: 8px;
}

h1, h2, h3 { text-wrap: balance; }

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 22px;
}

/* ---------- Header / wordmark ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--header-bg);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header .bar {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 12px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.wordmark {
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  font-size: clamp(23px, 6vw, 28px);
  letter-spacing: 0.2px;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  white-space: nowrap;
}
.wordmark:hover { text-decoration: none; }
.wordmark .grad-text,
.grad-text {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.wordmark .star {
  display: inline-block;
  margin: 0 1px;
  animation: spin 9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.nav { display: flex; align-items: center; gap: 8px; }
.nav a {
  color: var(--ink-soft);
  font-weight: 800;
  font-size: 14px;
  padding: 7px 14px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--card);
  white-space: nowrap;
}
.nav a:hover { text-decoration: none; color: var(--ink); border-color: var(--purple); }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  text-align: center;
  padding: 44px 0 30px;
}
.clover {
  font-size: clamp(66px, 18vw, 84px);
  line-height: 1;
  display: inline-block;
  filter: drop-shadow(0 12px 24px var(--glow-b));
  animation: bob 4.5s ease-in-out infinite;
}
@keyframes bob {
  0%, 100% { transform: translateY(0) rotate(-3deg); }
  50%      { transform: translateY(-10px) rotate(3deg); }
}

/* twinkling accents scattered around the hero */
.sparkle {
  position: absolute;
  pointer-events: none;
  animation: twinkle 3.2s ease-in-out infinite;
}
.sparkle.s1 { top: 10%;  left: 12%; font-size: 22px; animation-delay: 0s; }
.sparkle.s2 { top: 4%;   right: 16%; font-size: 16px; animation-delay: 0.9s; }
.sparkle.s3 { top: 46%;  left: 5%;  font-size: 15px; animation-delay: 1.7s; }
.sparkle.s4 { top: 38%;  right: 7%; font-size: 24px; animation-delay: 2.4s; }
.sparkle.s5 { bottom: 6%; left: 22%; font-size: 14px; animation-delay: 1.2s; }
.sparkle.s6 { bottom: 12%; right: 24%; font-size: 18px; animation-delay: 0.4s; }
@keyframes twinkle {
  0%, 100% { opacity: 0.25; transform: scale(0.85); }
  50%      { opacity: 1;    transform: scale(1.15); }
}

.hero h1 {
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  font-size: clamp(36px, 9vw, 56px);
  margin: 16px 0 8px;
  line-height: 1.08;
}
.tagline {
  font-size: clamp(17px, 4.4vw, 21px);
  color: var(--ink-soft);
  font-weight: 700;
  margin: 0 auto 24px;
  max-width: 32ch;
}

/* "coming soon" pill — a badge, not a button */
.soon-badge {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--grad);
  color: #fff;
  font-weight: 800;
  font-size: clamp(15px, 4vw, 16px);
  padding: 13px 24px;
  border-radius: 999px;
  box-shadow: var(--shadow), 0 0 0 0 var(--glow-a);
  animation: glow-pulse 3s ease-in-out infinite;
}
@keyframes glow-pulse {
  0%, 100% { box-shadow: var(--shadow), 0 0 0 0 var(--glow-a); }
  50%      { box-shadow: var(--shadow), 0 0 26px 4px var(--glow-a); }
}
.cta-note {
  display: block;
  margin-top: 12px;
  color: var(--ink-soft);
  font-size: 14.5px;
  font-weight: 700;
}
.hero-more {
  display: inline-block;
  margin-top: 20px;
  font-weight: 800;
  font-size: 15px;
}

/* button-shaped link (used on support & closing sections) */
.cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--grad);
  color: #fff;
  font-weight: 800;
  font-size: 16px;
  padding: 14px 26px;
  border-radius: 999px;
  box-shadow: var(--shadow);
  border: none;
  transition: transform 0.15s ease;
}
.cta:hover { text-decoration: none; transform: translateY(-2px); }

/* ---------- Zodiac marquee ---------- */

.zodiac {
  margin: 34px calc(50% - 50vw) 8px;   /* full-bleed */
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.zodiac-track {
  display: flex;
  width: max-content;
  padding: 6px 0;
  animation: marquee 36s linear infinite;
}
.zodiac-set {
  display: flex;
  gap: 10px;
  padding-right: 10px;
}
@keyframes marquee { to { transform: translateX(-50%); } }
.sign-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 800;
  font-size: 14.5px;
  color: var(--ink);
  padding: 8px 15px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--a) 16%, var(--card));
  border: 1.5px solid color-mix(in srgb, var(--a) 45%, transparent);
  white-space: nowrap;
}
.sign-chip .e { font-size: 17px; }

/* ---------- Feature cards ---------- */

.features {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin: 34px 0 10px;
}
.feature {
  display: flex;
  align-items: flex-start;
  gap: 15px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow-soft);
}
.feature .emoji {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  font-size: 27px;
  border-radius: 16px;
  background: color-mix(in srgb, var(--a, var(--purple)) 16%, var(--card));
  border: 1.5px solid color-mix(in srgb, var(--a, var(--purple)) 35%, transparent);
}
.feature h3 {
  margin: 0 0 3px;
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  font-size: 17.5px;
}
.feature p { margin: 0; color: var(--ink-soft); font-size: 15px; line-height: 1.55; }

@media (min-width: 560px) {
  .features { grid-template-columns: 1fr 1fr; gap: 16px; }
  .feature { flex-direction: column; gap: 12px; padding: 22px 20px; }
}

/* ---------- Showcase video + screenshot gallery ---------- */

.section-title {
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  font-size: clamp(26px, 6vw, 34px);
  text-align: center;
  margin: 56px 0 8px;
}
.section-sub {
  text-align: center;
  color: var(--ink-soft);
  font-weight: 700;
  font-size: 15.5px;
  margin: 0 auto 24px;
  max-width: 40ch;
}

/* phone-style frame shared by the video and screenshots */
.phone {
  position: relative;
  background: #0e0c14;
  border-radius: 40px;
  padding: 7px;
  margin: 0;
  box-shadow: var(--shadow);
  border: 1px solid rgba(0, 0, 0, 0.10);
  overflow: hidden;
}
.phone img,
.phone video {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 33px;
  background: #0e0c14;
}

.showcase { text-align: center; scroll-margin-top: 90px; }
.phone--video {
  max-width: min(74vw, 300px);
  margin: 0 auto;
}
.demo-glow {
  position: relative;
  display: block;
  padding: 10px 0 4px;
}
.demo-glow::before {
  content: "";
  position: absolute;
  inset: 6% 8%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--glow-a), transparent 70%);
  filter: blur(30px);
}

.gallery .shots {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding: 10px 22px 26px;
  margin: 0 -22px;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 22px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.gallery .shots::-webkit-scrollbar { display: none; }
.gallery figure {
  flex: 0 0 auto;
  width: clamp(205px, 56vw, 235px);
  scroll-snap-align: center;
  margin: 0;
}
.gallery figcaption {
  text-align: center;
  font-weight: 800;
  font-size: 14px;
  color: var(--ink-soft);
  margin-top: 11px;
}
.gallery .hint {
  text-align: center;
  color: var(--ink-soft);
  font-size: 13.5px;
  font-weight: 700;
  margin: 0;
}

/* Extra dark-mode cards for light-mode visitors; redundant in dark mode,
   where the main gallery shots already swap to their dark variants. */
@media (prefers-color-scheme: dark) {
  .dark-peek { display: none; }
}

/* ---------- Closing call-to-action ---------- */

.closing {
  position: relative;
  text-align: center;
  background: var(--card);
  border-radius: calc(var(--radius) + 4px);
  border: 1px solid transparent;
  background:
    linear-gradient(var(--card), var(--card)) padding-box,
    var(--grad) border-box;
  border-width: 2px;
  box-shadow: var(--shadow-soft);
  padding: 34px 24px 36px;
  margin: 56px 0 26px;
}
.closing .big { font-size: 40px; line-height: 1; }
.closing h2 {
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  font-size: clamp(24px, 6vw, 30px);
  margin: 12px 0 6px;
}
.closing p {
  color: var(--ink-soft);
  font-weight: 700;
  font-size: 15.5px;
  max-width: 38ch;
  margin: 0 auto 20px;
}

/* ---------- Legal / content pages ---------- */

.doc {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 34px clamp(20px, 5vw, 46px);
  box-shadow: var(--shadow-soft);
  margin: 16px 0 40px;
}
.doc h1 {
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  font-size: clamp(28px, 5vw, 38px);
  margin: 0 0 4px;
}
.doc .updated { color: var(--ink-soft); font-size: 14px; margin: 0 0 22px; }
.doc h2 {
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  font-size: 21px;
  margin: 28px 0 8px;
  padding-top: 8px;
}
.doc h3 { font-size: 17px; margin: 18px 0 6px; }
.doc p, .doc li { color: var(--ink); opacity: 0.88; font-size: 16px; }
.doc ul { padding-left: 22px; }
.doc li { margin: 6px 0; }
.doc a { font-weight: 700; }

.callout {
  background: linear-gradient(100deg, rgba(255, 143, 196, 0.12), rgba(95, 211, 230, 0.12));
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 18px;
  margin: 18px 0;
  font-weight: 700;
  color: var(--ink);
}

.back-link { display: inline-block; margin: 18px 0 6px; font-weight: 800; }

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 30px 0 max(50px, env(safe-area-inset-bottom));
  text-align: center;
  color: var(--ink-soft);
  font-size: 14px;
}
.site-footer .links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 22px;
  margin-bottom: 12px;
}
.site-footer .links a { color: var(--ink-soft); font-weight: 700; padding: 4px 0; }
.site-footer .brand { font-weight: 800; color: var(--ink); }

/* ---------- Motion preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .wordmark .star,
  .clover,
  .sparkle,
  .soon-badge { animation: none; }
  .zodiac { -webkit-mask-image: none; mask-image: none; }
  .zodiac-track {
    animation: none;
    width: auto;
    overflow-x: auto;
  }
  .zodiac-set { padding: 6px 22px 6px; }
  .zodiac-track .dup,
  .zodiac .dup { display: none; }
}
