/* WellVersed — getwellversed.app
   Design system mirrors the app: mint background, teal + honey accents,
   Syne headings, DM Sans body, Amiri for Quranic Arabic. */

:root {
  --bg: #f3faf8;
  --bg-2: #eaf6f2;
  --teal: #0f8a7e;
  --teal-dark: #0e4d45;
  --honey: #d99a3a;
  --sage: #4f9b6e;
  --terracotta: #d9684f;
  --ink: #14302c;
  --muted: #6f9a93;
  --border: #d9ece7;
  --white: #ffffff;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  --shadow: 0 20px 60px -24px rgba(14, 77, 69, 0.35);
  --shadow-sm: 0 8px 24px -12px rgba(14, 77, 69, 0.28);
  --radius: 22px;
  --maxw: 1120px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  overflow-x: hidden;
}
h1, h2, h3, .font-head { font-family: var(--sans); font-weight: 800; letter-spacing: -0.02em; line-height: 1.05; }
.arabic { font-family: 'Amiri', serif; direction: rtl; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.accent { color: var(--teal); }
.honey { color: var(--honey); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--sans); font-weight: 700; font-size: 16px;
  padding: 14px 26px; border-radius: 999px; border: 0; cursor: pointer;
  transition: transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s, background .25s;
}
.btn-primary { background: linear-gradient(135deg, var(--teal), var(--teal-dark)); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 40px -14px rgba(15,138,126,.6); }
.btn-ghost { background: rgba(255,255,255,.7); color: var(--teal-dark); border: 1px solid var(--border); }
.btn-ghost:hover { transform: translateY(-2px); background: #fff; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: saturate(180%) blur(18px);
  background: rgba(243,250,248,.72);
  border-bottom: 1px solid rgba(217,236,231,.7);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 11px; font-family: var(--sans); font-weight: 800; font-size: 20px; color: var(--teal-dark); }
.brand .mark {
  width: 34px; height: 34px; border-radius: 10px;
  display: block; object-fit: cover;
  box-shadow: var(--shadow-sm);
}
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a { font-weight: 500; font-size: 15px; color: var(--ink); opacity: .8; transition: opacity .2s; }
.nav-links a:hover { opacity: 1; }
.nav-cta { padding: 10px 20px; font-size: 15px; }
.nav-burger { display: none; background: none; border: 0; font-size: 24px; color: var(--ink); cursor: pointer; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 84px 0 60px; overflow: hidden; }
.hero::before {
  content: ''; position: absolute; inset: -20% -10% auto -10%; height: 720px; z-index: -1;
  background:
    radial-gradient(closest-side at 20% 30%, rgba(15,138,126,.16), transparent),
    radial-gradient(closest-side at 82% 20%, rgba(217,154,58,.16), transparent),
    radial-gradient(closest-side at 60% 70%, rgba(79,155,110,.12), transparent);
  filter: blur(8px);
}
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 40px; align-items: center; }
.pill {
  display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600;
  padding: 7px 14px; border-radius: 999px; background: #fff; border: 1px solid var(--border);
  color: var(--teal-dark); box-shadow: var(--shadow-sm);
}
.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--sage); box-shadow: 0 0 0 4px rgba(79,155,110,.18); }
.hero h1 { font-size: clamp(38px, 6vw, 68px); margin: 22px 0 18px; }
.hero h1 .grad { background: linear-gradient(120deg, var(--teal), var(--honey)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: clamp(17px, 2vw, 20px); color: var(--muted); max-width: 520px; margin-bottom: 30px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.hero-note { margin-top: 18px; font-size: 13px; color: var(--muted); }

/* ---------- Phone mockups ---------- */
.phone-stage { position: relative; display: grid; place-items: center; perspective: 1400px; min-height: 560px; }
.phone {
  position: relative; width: 268px; height: 560px; border-radius: 42px;
  background: #0e2c28; padding: 12px;
  box-shadow: var(--shadow), inset 0 0 0 2px rgba(255,255,255,.06);
  transform-style: preserve-3d; transition: transform .2s ease-out;
}
.phone .notch { position: absolute; top: 14px; left: 50%; transform: translateX(-50%); width: 92px; height: 22px; background: #0e2c28; border-radius: 0 0 14px 14px; z-index: 3; }
.phone .screen { width: 100%; height: 100%; border-radius: 32px; background: var(--bg); overflow: hidden; position: relative; }
.phone.floaty { animation: float 6s ease-in-out infinite; }
.phone.behind { position: absolute; width: 232px; height: 486px; opacity: .9; }
.phone.behind.left { transform: translateX(-150px) rotate(-9deg) scale(.86); z-index: 1; }
.phone.behind.right { transform: translateX(150px) rotate(9deg) scale(.86); z-index: 1; }
.phone.front { z-index: 2; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }

/* In-app rendered screens */
.app { padding: 34px 14px 14px; height: 100%; font-size: 12px; }
.app .topline { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.app .greet { font-family: var(--sans); font-weight: 800; font-size: 16px; color: var(--ink); }
.app .streak { display: flex; align-items: center; gap: 5px; background: #fff; border: 1px solid var(--border); border-radius: 999px; padding: 5px 10px; font-weight: 700; color: var(--honey); font-size: 12px; }
.app .card { background: #fff; border: 1px solid var(--border); border-radius: 16px; padding: 13px; margin-bottom: 10px; box-shadow: var(--shadow-sm); }
.app .card .ttl { font-family: var(--sans); font-weight: 700; font-size: 13px; margin-bottom: 3px; }
.app .card .sub { color: var(--muted); font-size: 11px; margin-bottom: 9px; }
.app .bar { height: 7px; background: var(--bg-2); border-radius: 99px; overflow: hidden; }
.app .bar > i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--teal), var(--sage)); }
.app .chip { display: inline-block; font-size: 10px; font-weight: 600; padding: 3px 9px; border-radius: 99px; background: rgba(15,138,126,.1); color: var(--teal-dark); margin-bottom: 8px; }
.app .word-ar { font-family: 'Amiri', serif; font-size: 34px; text-align: center; color: var(--ink); margin: 18px 0 6px; }
.app .word-tr { text-align: center; color: var(--teal); font-weight: 600; font-size: 13px; }
.app .word-en { text-align: center; color: var(--muted); font-size: 12px; margin-top: 3px; }
.app .verse { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 12px; margin-top: 16px; }
.app .verse .v-ar { font-family: 'Amiri', serif; direction: rtl; font-size: 17px; line-height: 1.9; color: var(--ink); }
.app .verse .hl { color: var(--honey); }
.app .verse .v-en { color: var(--muted); font-size: 11px; margin-top: 6px; }
.app .ring-wrap { display: grid; place-items: center; margin: 8px 0 14px; }
.app .ring { width: 118px; height: 118px; border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--teal) 72%, var(--bg-2) 0); }
.app .ring > div { width: 92px; height: 92px; border-radius: 50%; background: #fff; display: grid; place-items: center; font-family: var(--sans); font-weight: 800; font-size: 22px; color: var(--teal-dark); }
.app .stat-row { display: flex; gap: 8px; }
.app .stat { flex: 1; background: #fff; border: 1px solid var(--border); border-radius: 13px; padding: 10px; text-align: center; }
.app .stat b { font-family: var(--sans); font-size: 16px; color: var(--ink); display: block; }
.app .stat span { font-size: 10px; color: var(--muted); }

/* ---------- Sections ---------- */
section { padding: 76px 0; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--teal); margin-bottom: 12px; }
.section-head { max-width: 640px; margin: 0 auto 46px; text-align: center; }
.section-head h2 { font-size: clamp(30px, 4vw, 46px); margin-bottom: 14px; }
.section-head p { color: var(--muted); font-size: 18px; }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 28px;
  box-shadow: var(--shadow-sm); transition: transform .3s cubic-bezier(.2,.8,.2,1), box-shadow .3s;
}
.feature:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.feature .ico { width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; font-size: 24px; margin-bottom: 16px; color: #fff; }
.feature h3 { font-size: 20px; margin-bottom: 8px; }
.feature p { color: var(--muted); font-size: 15px; }

/* Verse showcase band */
.showcase { background: linear-gradient(160deg, var(--teal-dark), var(--teal)); color: #fff; border-radius: 34px; padding: 60px 40px; text-align: center; box-shadow: var(--shadow); }
.showcase .verse-ar { font-family: 'Amiri', serif; direction: rtl; font-size: clamp(28px, 5vw, 46px); line-height: 1.9; margin-bottom: 18px; }
.showcase .verse-ar .hl { color: var(--honey); }
.showcase .verse-en { font-size: 18px; opacity: .9; max-width: 620px; margin: 0 auto 8px; }
.showcase .verse-ref { font-weight: 700; opacity: .8; letter-spacing: .05em; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.step { text-align: center; }
.step .n { width: 46px; height: 46px; border-radius: 50%; margin: 0 auto 14px; display: grid; place-items: center; font-family: var(--sans); font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--honey), #c07f24); box-shadow: var(--shadow-sm); }
.step h3 { font-size: 19px; margin-bottom: 7px; }
.step p { color: var(--muted); font-size: 15px; }

/* CTA */
.cta-band { text-align: center; }
.cta-card { background: #fff; border: 1px solid var(--border); border-radius: 34px; padding: 56px 32px; box-shadow: var(--shadow); }
.cta-card h2 { font-size: clamp(28px, 4vw, 44px); margin-bottom: 14px; }
.cta-card p { color: var(--muted); font-size: 18px; margin-bottom: 26px; }

/* Footer */
footer { border-top: 1px solid var(--border); padding: 50px 0 40px; background: var(--bg-2); }
.foot-grid { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.foot-brand { max-width: 300px; }
.foot-brand p { color: var(--muted); font-size: 14px; margin-top: 12px; }
.foot-cols { display: flex; gap: 60px; flex-wrap: wrap; }
.foot-col h4 { font-family: var(--sans); font-size: 14px; letter-spacing: .05em; text-transform: uppercase; color: var(--teal-dark); margin-bottom: 14px; }
.foot-col a { display: block; color: var(--muted); font-size: 15px; margin-bottom: 10px; transition: color .2s; }
.foot-col a:hover { color: var(--teal); }
.foot-bottom { margin-top: 40px; padding-top: 22px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; color: var(--muted); font-size: 13px; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s cubic-bezier(.2,.8,.2,1), transform .7s cubic-bezier(.2,.8,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; } .reveal.d2 { transition-delay: .16s; } .reveal.d3 { transition-delay: .24s; }

/* ---------- Legal / content pages ---------- */
.doc { max-width: 780px; margin: 0 auto; padding: 60px 0 90px; }
.doc h1 { font-size: clamp(32px, 5vw, 48px); margin-bottom: 8px; }
.doc .updated { color: var(--muted); font-size: 14px; margin-bottom: 34px; }
.doc h2 { font-size: 22px; margin: 34px 0 12px; }
.doc h3 { font-family: var(--sans); font-size: 17px; margin: 22px 0 8px; }
.doc p, .doc li { color: #2c463f; font-size: 16px; margin-bottom: 12px; }
.doc ul { padding-left: 22px; margin-bottom: 14px; }
.doc li { margin-bottom: 8px; }
.doc a { color: var(--teal); font-weight: 600; }
.doc a:hover { text-decoration: underline; }
.doc .box { background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 22px; box-shadow: var(--shadow-sm); margin: 20px 0; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; text-align: center; }
  .hero p.lead { margin-left: auto; margin-right: auto; }
  .hero-cta { justify-content: center; }
  .phone-stage { min-height: 500px; margin-top: 20px; }
  .phone.behind.left { transform: translateX(-110px) rotate(-8deg) scale(.82); }
  .phone.behind.right { transform: translateX(110px) rotate(8deg) scale(.82); }
  .features, .steps { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .nav-burger { display: block; }
  .nav-links.open { display: flex; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; background: rgba(243,250,248,.98); padding: 18px 24px; gap: 16px; border-bottom: 1px solid var(--border); }
}
@media (max-width: 520px) {
  .foot-cols { gap: 34px; }
}

/* ===== App-accurate mockups + rotating carousel ===== */
.phone-stage { height: 600px; min-height: 600px; perspective: 1600px; }
.phone {
  position: absolute; top: 50%; left: 50%; width: 262px; height: 548px;
  margin: -274px 0 0 -131px; animation: none;
  transition: transform .85s cubic-bezier(.55,.08,.25,1), opacity .85s ease, filter .85s ease;
  will-change: transform, opacity;
}
.phone .screen { background: #F7F3EA; }           /* real app cream background */
.phone.pos-front { transform: translateX(0) scale(1) rotateY(0deg); opacity: 1; z-index: 3; filter: none; }
.phone.pos-left  { transform: translateX(-158px) scale(.82) rotateY(14deg);  opacity: .88; z-index: 1; filter: brightness(.96); }
.phone.pos-right { transform: translateX(158px)  scale(.82) rotateY(-14deg); opacity: .88; z-index: 1; filter: brightness(.96); }

/* In-app palette matched to the real app (cream / dark-teal / gold) */
.app { color: var(--ink); }
.app .greet { color: var(--ink); }
.app .streak { border-color: #C8D2CC; color: #D4A63F; }
.app .card { border-color: #C8D2CC; position: relative; overflow: hidden; }
.app .card::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--acc, #0E4D45); }
.app .card .ttl, .app .card .sub { padding-left: 6px; }
.app .bar { background: #e7ece8; }
.app .bar > i { background: linear-gradient(90deg, #0E4D45, #4f9b6e); }
.app .chip { background: rgba(14,77,69,.09); color: #0E4D45; }
.app .word-tr { color: #0E4D45; }
.app .verse { border-color: #C8D2CC; }
.app .verse .hl { color: #D4A63F; }
.app .ring { background: conic-gradient(#0E4D45 72%, #e7ddca 0); }
.app .ring > div { color: #0E4D45; }
.app .stat { border-color: #C8D2CC; }

@media (prefers-reduced-motion: reduce) { .phone { transition: none; } }
@media (max-width: 760px) {
  .phone-stage { height: 560px; min-height: 560px; }
  .phone.pos-left, .phone.pos-right { opacity: 0; pointer-events: none; }
  .phone.pos-front { transform: translateX(0) scale(.9) rotateY(0deg); }
}
