/* ==========================================================================
   Anchor — marketing site
   Ivory paper, navy ink, coral accent, white cards. Mirrors the app in light mode.
   No purple, strong color, real shadows.
   ========================================================================== */

:root {
  --paper: #F5F1E8;          /* page background */
  --paper-deep: #EDE7DA;
  --surface: #FFFFFF;        /* cards */
  --surface-2: #FBF9F4;
  --track: #E4DDCD;          /* unlit ring track */
  --ink: #0F1B2D;
  --ink-soft: rgba(15, 27, 45, 0.76);
  --ink-faint: rgba(15, 27, 45, 0.52);
  --hairline: rgba(15, 27, 45, 0.10);

  --accent: #E8613C;         /* coral */
  --accent-deep: #C94A28;
  --accent-ink: #FFFFFF;     /* text on coral */

  --shadow-sm: 0 2px 10px -4px rgba(15, 27, 45, 0.22);
  --shadow: 0 30px 70px -30px rgba(15, 27, 45, 0.40);
  --shadow-card: 0 22px 50px -26px rgba(15, 27, 45, 0.35), 0 1px 0 rgba(255, 255, 255, 0.9) inset;
  --glow: 0 18px 44px -18px rgba(232, 97, 60, 0.60);

  --serif: ui-serif, "New York", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --rounded: ui-rounded, "SF Pro Rounded", var(--sans);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 86px; background: var(--paper); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--rounded);
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.5;
  min-height: 100dvh;
  overflow-x: hidden;
}

/* soft coral and navy light behind everything */
body::before {
  content: "";
  position: fixed;
  inset: -25%;
  z-index: -1;
  background:
    radial-gradient(34% 30% at 18% 6%, rgba(232, 97, 60, 0.14), transparent 70%),
    radial-gradient(40% 36% at 88% 10%, rgba(15, 27, 45, 0.08), transparent 70%),
    linear-gradient(180deg, var(--paper) 0%, var(--paper-deep) 100%);
}

.container { width: min(1120px, 100%); margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50; padding: 14px 0;
  border-bottom: 1px solid transparent;
}
.nav--scrolled {
  background: rgba(245, 241, 232, 0.82);
  backdrop-filter: blur(16px) saturate(1.3);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  border-color: var(--hairline);
  box-shadow: 0 8px 26px -18px rgba(15, 27, 45, 0.45);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; color: var(--ink); min-width: 0; }
.brand .mark {
  flex: none; width: 38px; height: 38px; border-radius: 11px;
  background: var(--ink);
  display: grid; place-items: center;
  box-shadow: 0 10px 22px -10px rgba(15, 27, 45, 0.7), inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.brand .mark img { width: 38px; height: 38px; border-radius: 11px; display: block; }
.brand__name { font-size: 18px; font-weight: 700; letter-spacing: -0.02em; }
.nav__links { display: flex; align-items: center; gap: clamp(16px, 4vw, 26px); }
.nav__links a { color: var(--ink-soft); text-decoration: none; font-size: 15px; font-weight: 550; transition: color .2s; }
.nav__links a:hover { color: var(--accent); }

/* ---------- Landing hero ---------- */
.hero { padding: clamp(40px, 8vw, 88px) 0 clamp(28px, 5vw, 48px); }
.hero__inner { display: grid; grid-template-columns: auto 1fr; gap: clamp(24px, 4vw, 44px); align-items: center; max-width: 900px; }
.appicon {
  width: clamp(112px, 22vw, 168px); height: auto; aspect-ratio: 1;
  border-radius: 22.5%;
  box-shadow: 0 34px 60px -26px rgba(15, 27, 45, 0.55), 0 0 0 1px rgba(15, 27, 45, 0.08);
  display: block;
}
.kicker { font-size: 12.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); }
.h1 {
  margin-top: 10px; font-family: var(--serif); font-weight: 600; letter-spacing: -0.02em; line-height: 1.04;
  font-size: clamp(2.6rem, 7vw, 4.2rem);
}
.lead { margin-top: 14px; font-size: clamp(1.05rem, 2.2vw, 1.28rem); color: var(--ink-soft); line-height: 1.55; max-width: 44ch; }
.meta { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 10px; }
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13.5px; font-weight: 650; font-family: var(--rounded);
  padding: 8px 14px; border-radius: 999px;
  background: var(--surface); color: var(--ink-soft);
  border: 1px solid var(--hairline); box-shadow: var(--shadow-sm);
}
.pill--accent { background: var(--accent); color: var(--accent-ink); border-color: transparent; box-shadow: var(--glow); }

/* App Store badge placeholder */
.store {
  margin-top: 22px;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 18px 12px 14px; border-radius: 14px;
  background: var(--ink); color: #FFFFFF; text-decoration: none;
  font-weight: 650; font-size: 15px; letter-spacing: -0.01em;
  box-shadow: 0 16px 34px -16px rgba(15, 27, 45, 0.7);
  transition: transform .15s ease, box-shadow .15s ease;
}
.store:hover { transform: translateY(-1px); box-shadow: 0 20px 40px -16px rgba(15, 27, 45, 0.75); }
.store svg { width: 22px; height: 22px; flex: none; }
.store span small { display: block; font-size: 11px; font-weight: 500; opacity: 0.7; letter-spacing: 0.02em; }

/* Habit row mock */
.mock {
  margin-top: clamp(24px, 4vw, 36px);
  max-width: 900px;
  display: grid; gap: 10px;
}
.row {
  display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 16px;
  background: var(--surface); border: 1px solid var(--hairline); border-radius: 18px;
  padding: 16px 18px; box-shadow: var(--shadow-card);
}
.row__title { font-size: 1.05rem; font-weight: 700; letter-spacing: -0.01em; }
.row__cue { margin-top: 3px; font-size: 14px; color: var(--ink-faint); }
.row__cue b { color: var(--accent-deep); font-weight: 650; }
.row__streak { margin-top: 8px; display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 650; color: var(--ink-soft); }
.row__streak i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); display: inline-block; }
.row__streak.is-tiny i { background: var(--surface); box-shadow: inset 0 0 0 2px var(--accent); }
.row__btn {
  width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center;
  background: var(--track); color: var(--ink);
  box-shadow: inset 0 -3px 0 rgba(15, 27, 45, 0.10), 0 6px 14px -8px rgba(15, 27, 45, 0.5);
}
.row__btn svg { width: 24px; height: 24px; }
.row__btn.is-done { background: linear-gradient(160deg, var(--accent), var(--accent-deep)); color: #FFFFFF; box-shadow: var(--glow), inset 0 -3px 0 rgba(0, 0, 0, 0.18); }
.row__btn.is-tiny { background: var(--surface); box-shadow: inset 0 0 0 3px var(--accent), 0 6px 14px -8px rgba(15, 27, 45, 0.5); color: var(--accent-deep); }
.mock__cap { font-size: 13.5px; color: var(--ink-faint); padding: 0 4px; }

/* ---------- Sections ---------- */
.section { padding: clamp(28px, 5vw, 56px) 0; }
.h2 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; font-size: clamp(1.7rem, 4vw, 2.4rem); }
.sublead { margin-top: 12px; color: var(--ink-soft); font-size: 1.05rem; line-height: 1.6; max-width: 62ch; }

.grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: clamp(24px, 4vw, 36px); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.feat {
  background: linear-gradient(180deg, var(--surface), var(--surface-2));
  border: 1px solid var(--hairline); border-radius: 20px; padding: 24px;
  box-shadow: var(--shadow-card);
}
.feat__icon {
  width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center;
  color: var(--accent-ink); background: linear-gradient(140deg, var(--accent), var(--accent-deep));
  box-shadow: var(--glow);
}
.feat__icon svg { width: 23px; height: 23px; }
.feat__num { font-family: var(--serif); font-size: 2rem; font-weight: 600; color: var(--accent); line-height: 1; }
.feat h3 { margin-top: 16px; font-size: 1.18rem; font-weight: 700; letter-spacing: -0.01em; }
.feat p { margin-top: 8px; color: var(--ink-soft); font-size: 15px; line-height: 1.6; }
.feat ul { margin-top: 10px; list-style: none; display: grid; gap: 7px; }
.feat li { position: relative; padding-left: 18px; color: var(--ink-soft); font-size: 15px; line-height: 1.5; }
.feat li::before { content: ""; position: absolute; left: 3px; top: 9px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

.note {
  margin-top: clamp(24px, 4vw, 36px);
  display: grid; grid-template-columns: auto 1fr; gap: 18px; align-items: start;
  background: var(--surface); border: 1px solid rgba(232, 97, 60, 0.35);
  border-left: 4px solid var(--accent);
  border-radius: 18px; padding: 22px 22px 22px 20px; box-shadow: var(--shadow-card);
}
.note__icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: rgba(232, 97, 60, 0.12); color: var(--accent-deep); }
.note__icon svg { width: 22px; height: 22px; }
.note h3 { font-size: 1.1rem; font-weight: 700; }
.note p { margin-top: 6px; color: var(--ink-soft); font-size: 15.5px; line-height: 1.62; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: clamp(24px, 4vw, 36px); }
.panel { background: var(--surface); border: 1px solid var(--hairline); border-radius: 20px; padding: 24px; box-shadow: var(--shadow-card); }
.panel h3 { font-size: 1.1rem; font-weight: 700; }
.panel p { margin-top: 8px; color: var(--ink-soft); font-size: 15px; line-height: 1.6; }
.panel a { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 3px; }
.panel a:hover { color: var(--accent); }

/* Plus pricing */
.plans { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: clamp(24px, 4vw, 36px); }
.plan { background: var(--surface); border: 1px solid var(--hairline); border-radius: 20px; padding: 24px; box-shadow: var(--shadow-card); position: relative; }
.plan--plus { background: var(--ink); color: #FFFFFF; border-color: transparent; box-shadow: 0 30px 60px -28px rgba(15, 27, 45, 0.85); }
.plan__tag { font-size: 12.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); }
.plan h3 { margin-top: 8px; font-family: var(--serif); font-size: 1.7rem; font-weight: 600; letter-spacing: -0.02em; }
.plan p { margin-top: 8px; color: var(--ink-soft); font-size: 15px; line-height: 1.6; }
.plan--plus p { color: rgba(255, 255, 255, 0.78); }
.plan ul { margin-top: 14px; list-style: none; display: grid; gap: 8px; }
.plan li { position: relative; padding-left: 26px; font-size: 15px; line-height: 1.5; color: var(--ink-soft); }
.plan--plus li { color: rgba(255, 255, 255, 0.86); }
.plan li::before {
  content: ""; position: absolute; left: 0; top: 4px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--accent);
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><circle cx='12' cy='12' r='12' fill='black'/><path d='M7 12.5l3.2 3.2L17 9' fill='none' stroke='white' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/></svg>") center / contain no-repeat;
          mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><circle cx='12' cy='12' r='12' fill='black'/><path d='M7 12.5l3.2 3.2L17 9' fill='none' stroke='white' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/></svg>") center / contain no-repeat;
}
.plan__terms { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 8px; }
.plan__terms span {
  font-size: 13px; font-weight: 650; padding: 7px 12px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.10); color: #FFFFFF; border: 1px solid rgba(255, 255, 255, 0.14);
}
.plan__fine { margin-top: 14px; font-size: 13px; color: rgba(255, 255, 255, 0.6); }

.landing-foot { padding-bottom: clamp(48px, 8vw, 96px); }
.foot__links { display: flex; flex-wrap: wrap; gap: 6px 18px; }

/* ---------- Legal / support documents ---------- */
.doc { padding: clamp(40px, 7vh, 88px) 0 clamp(56px, 9vh, 112px); }
.doc__inner { max-width: 740px; }
.doc__head { margin-bottom: clamp(26px, 5vw, 44px); padding-bottom: clamp(22px, 4vw, 34px); border-bottom: 1px solid var(--hairline); }
.doc__kicker { font-size: 12.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); }
.doc__title { margin-top: 12px; font-family: var(--serif); font-size: clamp(2.1rem, 4.6vw, 3.2rem); font-weight: 600; letter-spacing: -0.02em; line-height: 1.06; }
.doc__date { margin-top: 14px; color: var(--ink-faint); font-size: 14.5px; }
.doc__body { color: var(--ink-soft); font-size: 16px; line-height: 1.72; overflow-wrap: anywhere; }
.doc__body p { margin-top: 14px; }
.doc__body h2 { margin-top: 42px; font-family: var(--serif); font-size: 1.5rem; font-weight: 600; letter-spacing: -0.015em; color: var(--ink); }
.doc__body h3 { margin-top: 26px; font-size: 1.05rem; font-weight: 700; color: var(--ink); }
.doc__body h2 + p, .doc__body h3 + p { margin-top: 12px; }
.doc__body ul, .doc__body ol { margin-top: 14px; padding-left: 0; list-style: none; }
.doc__body ul li, .doc__body ol li { position: relative; padding-left: 22px; margin-top: 10px; }
.doc__body ul li::before { content: ""; position: absolute; left: 5px; top: 11px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.doc__body ol { counter-reset: step; }
.doc__body ol li { padding-left: 34px; }
.doc__body ol li::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 3px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--accent); color: #FFFFFF; font-size: 12.5px; font-weight: 700; display: grid; place-items: center;
}
.doc__body b, .doc__body strong { color: var(--ink); font-weight: 700; }
.doc__body a { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 3px; }
.doc__body a:hover { color: var(--accent); }
.doc__callout {
  margin-top: 22px; background: var(--surface); border: 1px solid rgba(232, 97, 60, 0.35);
  border-left: 4px solid var(--accent); border-radius: 16px; padding: 18px 20px; box-shadow: var(--shadow-card);
}
.doc__callout p { margin-top: 0; }
.faq { margin-top: 8px; }
.faq details { border-bottom: 1px solid var(--hairline); padding: 4px 0; }
.faq summary { cursor: pointer; list-style: none; padding: 16px 0; font-weight: 650; color: var(--ink); font-size: 1.05rem; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--accent); font-size: 1.4rem; font-weight: 400; line-height: 1; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--ink-soft); padding: 0 0 18px; margin-top: 0; line-height: 1.65; }
.faq details ol, .faq details ul { margin-top: 0; padding-bottom: 18px; }
.faq details ol li, .faq details ul li { margin-top: 8px; }
.doc__back { margin-top: clamp(44px, 7vw, 72px); padding-top: 24px; border-top: 1px solid var(--hairline); display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; color: var(--ink-faint); font-size: 13.5px; }
.doc__back a { color: var(--ink-faint); text-decoration: none; }
.doc__back a:hover { color: var(--accent); }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .grid { grid-template-columns: 1fr 1fr; }
  .grid .feat:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .grid--3 { grid-template-columns: 1fr; }
  .grid--3 .feat:last-child { grid-column: auto; }
}
@media (max-width: 600px) {
  .hero__inner { grid-template-columns: 1fr; }
  .grid, .split, .plans { grid-template-columns: 1fr; }
  .note { grid-template-columns: 1fr; gap: 12px; }
}
