/* Ovelle web — tokens and components from the Ovelle Foundations design system (v1). */

@font-face {
  font-family: "Newsreader";
  src: url("/assets/fonts/newsreader-400.woff2?v=efae992d53") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* Metric-matched fallback so the swap to Newsreader does not shift the layout. */
@font-face {
  font-family: "Newsreader Fallback";
  src: local("Georgia");
  size-adjust: 96.3%;
  ascent-override: 76.4%;
  descent-override: 27.5%;
  line-gap-override: 0%;
}

:root {
  color-scheme: light dark;

  --bg: #FBF8F4;
  --surface: #FFFFFF;
  --fill: #F4EFE8;
  --line: #E9E2D9;
  --ink: #1F1B18;
  --muted: #6E655D;
  --primary: #3F6B57;
  --on-primary: #FFFFFF;
  --primary-tint: #E4EDE7;
  --accent: #C8795A;
  --accent-ink: #9A5236;
  --accent-tint: #F6E7DF;
  --amber: #E0A43A;
  --amber-ink: #85570C;
  --amber-tint: #FAEFD9;

  --menstrual: #C9989A; --menstrual-tint: #F3E3E2;
  --follicular: #E0CBA3; --follicular-tint: #F5ECDB;
  --ovulatory: #A3BEA4; --ovulatory-tint: #E4EDE3;
  --luteal: #8278A8; --luteal-tint: #E8E4F1;

  --shadow: 0 2px 12px rgba(31, 27, 24, 0.06);
  --card-border: 1px solid transparent;
  --frame: #1F1B18;

  --serif: "Newsreader", "Newsreader Fallback", "Iowan Old Style", Palatino, Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --r-button: 14px;
  --r-card: 20px;
  --r-chip: 22px;
  --r-sheet: 32px;
  --gutter: 20px;
  --max: 1120px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #171514;
    --surface: #211E1C;
    --fill: #2B2724;
    --line: #35302C;
    --ink: #F3EEE8;
    --muted: #A89E94;
    --primary: #7DB096;
    --on-primary: #10231A;
    --primary-tint: #233029;
    --accent: #D98C6E;
    --accent-ink: #E3A184;
    --accent-tint: #3A2822;
    --amber: #E7B04E;
    --amber-ink: #EDBE66;
    --amber-tint: #3A2F1C;

    --menstrual-tint: #3B2A2B;
    --follicular-tint: #38311F;
    --ovulatory-tint: #26322A;
    --luteal-tint: #2D2939;

    /* Dark: no shadows, a 1px line on cards. */
    --shadow: none;
    --card-border: 1px solid var(--line);
    --frame: #3A3531;
  }
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 1.0625rem/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }
img { height: auto; }

a { color: var(--primary); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
  border-radius: 6px;
}

h1, h2, h3, p, ul, ol, dl, figure { margin: 0; }

.serif, h1, h2 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

h1 { font-size: clamp(2.5rem, 10vw, 4.25rem); line-height: 1.04; }
h2 { font-size: clamp(2rem, 7vw, 3rem); line-height: 1.08; }
h3 { font-size: 1.0625rem; line-height: 1.3; font-weight: 600; }

.icon {
  width: 1.25em;
  height: 1.25em;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}


.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: var(--r-button);
  background: var(--primary);
  color: var(--on-primary);
  font-weight: 600;
}
.skip-link:focus { top: 12px; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.muted { color: var(--muted); }

/* ---------- Header / footer ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 60%, transparent);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  text-decoration: none;
  font-family: var(--serif);
  font-size: 1.625rem;
  line-height: 1;
  letter-spacing: -0.01em;
}
.brand svg { width: 28px; height: 28px; }

.nav { display: flex; align-items: center; gap: 4px; }
.nav a:not(.btn) {
  display: none;
  padding: 10px 12px;
  color: var(--muted);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
}
.nav a:not(.btn):hover { color: var(--ink); }
@media (min-width: 760px) { .nav a:not(.btn) { display: inline-block; } }

.site-footer {
  margin-top: 40px;
  padding-block: 40px 48px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.875rem;
}
.site-footer .wrap { display: grid; gap: 20px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 4px 20px; padding: 0; list-style: none; }
.footer-links a { color: var(--ink); text-decoration: none; font-weight: 500; display: inline-block; padding-block: 6px; }
.footer-links a:hover { text-decoration: underline; }
.site-footer p { max-width: 60ch; }

/* ---------- Buttons, badges, chips ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: var(--r-button);
  background: var(--primary);
  color: var(--on-primary);
  font: 600 0.9375rem/1 var(--sans);
  text-decoration: none;
  white-space: nowrap;
  transition: filter 0.15s ease, transform 0.15s ease;
}
.btn:hover { filter: brightness(1.06); }
.btn:active { transform: scale(0.98); }
.btn-lg { min-height: 52px; padding-inline: 24px; font-size: 1.0625rem; }

.store-badge { display: inline-block; border-radius: 10px; line-height: 0; }
.store-badge img { width: 168px; height: 56px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 14px 0 12px;
  border-radius: var(--r-chip);
  background: var(--fill);
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 600;
  white-space: nowrap;
}
.chip .icon { width: 17px; height: 17px; }
.chip-primary { background: var(--primary-tint); }
.chip-primary .icon { color: var(--primary); }

.phase-menstrual { background: var(--menstrual-tint); } .phase-menstrual .icon { color: var(--menstrual); }
.phase-follicular { background: var(--follicular-tint); } .phase-follicular .icon { color: #B39157; }
.phase-ovulatory { background: var(--ovulatory-tint); } .phase-ovulatory .icon { color: #5F8A63; }
.phase-luteal { background: var(--luteal-tint); } .phase-luteal .icon { color: var(--luteal); }
@media (prefers-color-scheme: dark) {
  .phase-follicular .icon { color: var(--follicular); }
  .phase-ovulatory .icon { color: var(--ovulatory); }
  .phase-luteal .icon { color: #A9A0CF; }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-ink);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.eyebrow .icon { width: 16px; height: 16px; }

.card {
  background: var(--surface);
  border: var(--card-border);
  border-radius: var(--r-card);
  box-shadow: var(--shadow);
}

/* ---------- Sections ---------- */

.section { padding-block: 64px; }
@media (min-width: 960px) { .section { padding-block: 104px; } }

.section-head { display: grid; gap: 14px; max-width: 40rem; margin-bottom: 36px; }
.section-head p { color: var(--muted); font-size: 1.125rem; }

.tinted { background: var(--fill); }

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

.hero { padding-block: 32px 64px; overflow: clip; }
.hero .wrap { display: grid; gap: 48px; align-items: center; }
.hero-copy { display: grid; gap: 20px; justify-items: start; }
.hero .lead { color: var(--muted); font-size: 1.1875rem; line-height: 1.5; max-width: 34rem; }
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-top: 4px; }
.cta-note { color: var(--muted); font-size: 0.9375rem; }

.ticks { display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 0; list-style: none; color: var(--muted); font-size: 0.9375rem; }
.ticks li { display: inline-flex; align-items: center; gap: 6px; }
.ticks .icon { color: var(--primary); width: 16px; height: 16px; stroke-width: 2.4; }

@media (min-width: 960px) {
  .hero { padding-block: 56px 96px; }
  .hero .wrap { grid-template-columns: 1.1fr 0.9fr; gap: 64px; }
}

/* ---------- Phone frame ---------- */

.phone {
  --phone-w: min(300px, 78vw);
  position: relative;
  width: var(--phone-w);
  margin-inline: auto;
  padding: 9px;
  border-radius: 48px;
  background: var(--frame);
  box-shadow: 0 30px 60px -20px rgba(31, 27, 24, 0.35), 0 8px 20px -8px rgba(31, 27, 24, 0.2);
}
.phone::before {
  content: "";
  position: absolute;
  z-index: 2;
  top: 18px;
  left: 50%;
  width: 29%;
  height: 22px;
  border-radius: 12px;
  background: #0E0C0B;
  transform: translateX(-50%);
}
.phone > .screen,
.phone > picture > img,
.phone > img {
  display: block;
  width: 100%;
  aspect-ratio: 393 / 852;
  border-radius: 39px;
  overflow: hidden;
  background: var(--bg);
}

/* ---------- Hero mock: the Snap result screen, drawn in HTML ---------- */
/* Sized in design points: --u is one iOS point of the 393pt-wide screen. */

.mock {
  --u: calc((var(--phone-w) - 18px) / 393); /* screen width = frame minus 2 x 9px padding */
  position: relative;
  color: var(--ink);
  background: var(--bg);
}

.mock-bar {
  position: absolute;
  top: calc(var(--u) * 62);
  left: calc(var(--u) * 16);
  right: calc(var(--u) * 16);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: calc(var(--u) * 17);
  font-weight: 600;
}
.mock-round {
  display: grid;
  place-items: center;
  width: calc(var(--u) * 36);
  height: calc(var(--u) * 36);
  border-radius: 50%;
  background: var(--fill);
}
.mock-round .icon { width: calc(var(--u) * 16); height: calc(var(--u) * 16); stroke-width: 2; }

.mock-plate {
  position: absolute;
  top: calc(var(--u) * 118);
  left: 50%;
  width: calc(var(--u) * 224);
  transform: translateX(-50%);
}
.mock-plate svg { width: 100%; height: auto; overflow: visible; }
.ring-track { stroke: var(--line); }
.ring { stroke: var(--amber); }

.mock-result {
  position: absolute;
  top: calc(var(--u) * 356);
  left: calc(var(--u) * 20);
  right: calc(var(--u) * 20);
  display: grid;
  justify-items: center;
  gap: calc(var(--u) * 18);
}
.mock-chip {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--u) * 6);
  height: calc(var(--u) * 32);
  padding: 0 calc(var(--u) * 12);
  border-radius: calc(var(--u) * 22);
  background: var(--amber-tint);
  color: var(--amber-ink);
  font-size: calc(var(--u) * 15);
  font-weight: 600;
}
.mock-chip i {
  width: calc(var(--u) * 10);
  height: calc(var(--u) * 10);
  border: calc(var(--u) * 2.4) solid var(--amber);
  border-radius: 50%;
}
.mock-bars { display: flex; gap: calc(var(--u) * 4); width: 100%; height: calc(var(--u) * 9); }
.mock-bars span { border-radius: 99px; }
.mock-bars span:nth-child(1) { flex: 14; background: var(--primary); }
.mock-bars span:nth-child(2) { flex: 20; background: var(--ovulatory); }
.mock-bars span:nth-child(3) { flex: 60; background: var(--amber); }
.mock-levels {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 100%;
  font-size: calc(var(--u) * 13);
  color: var(--muted);
}
.mock-levels b { display: block; color: var(--ink); font-size: calc(var(--u) * 15); font-weight: 600; }
.mock-levels i {
  display: inline-block;
  width: calc(var(--u) * 9);
  height: calc(var(--u) * 9);
  margin-right: calc(var(--u) * 5);
  border-radius: calc(var(--u) * 2);
}

.mock-sheet {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: grid;
  gap: calc(var(--u) * 10);
  padding: calc(var(--u) * 26) calc(var(--u) * 20) calc(var(--u) * 34);
  border-radius: calc(var(--u) * 32) calc(var(--u) * 32) 0 0;
  background: var(--surface);
  box-shadow: 0 -4px 24px rgba(31, 27, 24, 0.07);
}
.mock-sheet::before {
  content: "";
  position: absolute;
  top: calc(var(--u) * 10);
  left: 50%;
  width: calc(var(--u) * 36);
  height: calc(var(--u) * 5);
  border-radius: 9px;
  background: var(--line);
  transform: translateX(-50%);
}
.mock-tag {
  display: flex;
  align-items: center;
  gap: calc(var(--u) * 6);
  color: var(--accent-ink);
  font-size: calc(var(--u) * 13);
  font-weight: 600;
}
.mock-tag .icon { width: calc(var(--u) * 16); height: calc(var(--u) * 16); }
.mock-title { font-family: var(--serif); font-size: calc(var(--u) * 26); line-height: 1.15; }
.mock-body { color: var(--muted); font-size: calc(var(--u) * 15); line-height: 1.4; }
.mock-btn {
  display: grid;
  place-items: center;
  height: calc(var(--u) * 52);
  margin-top: calc(var(--u) * 8);
  border-radius: calc(var(--u) * 14);
  background: var(--primary);
  color: var(--on-primary);
  font-size: calc(var(--u) * 17);
  font-weight: 600;
}
.mock-link { text-align: center; color: var(--primary); font-size: calc(var(--u) * 16); font-weight: 500; padding-top: calc(var(--u) * 6); }
.mock-foot { text-align: center; color: var(--muted); font-size: calc(var(--u) * 12); }

/* Motion spec: ring draws, then the swap card slides up (+40pt, fade) 120ms after. */
@media (prefers-reduced-motion: no-preference) {
  .ring { stroke-dasharray: 100; animation: ring-draw 1.1s cubic-bezier(0.3, 0.7, 0.3, 1) 0.35s both; }
  .mock-result > * { animation: rise 0.45s ease-out both; }
  .mock-chip { animation-delay: 1.3s; }
  .mock-bars { animation-delay: 1.4s; }
  .mock-levels { animation-delay: 1.45s; }
  .mock-sheet { animation: sheet-up 0.55s cubic-bezier(0.2, 0.8, 0.2, 1) 1.75s both; }
}
@keyframes ring-draw { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes sheet-up { from { opacity: 0; transform: translateY(40%); } to { opacity: 1; transform: none; } }

/* ---------- How it works ---------- */

.steps { display: grid; gap: 14px; padding: 0; list-style: none; counter-reset: step; }
.steps li { display: grid; gap: 10px; padding: 22px; }
.steps .num {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary-tint);
  color: var(--primary);
}
.steps .num .icon { width: 22px; height: 22px; }
.steps p { color: var(--muted); }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Features ---------- */

.features { display: grid; gap: 72px; }
.feature { display: grid; gap: 36px; align-items: center; }
.feature-copy { display: grid; gap: 16px; }
.feature-copy > p { color: var(--muted); font-size: 1.125rem; }
.bullets { display: grid; gap: 12px; padding: 0; list-style: none; }
.bullets li { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: start; }
.bullets .icon {
  width: 36px;
  height: 36px;
  padding: 8px;
  border-radius: 10px;
  background: var(--fill);
  color: var(--ink);
}
.bullets strong { display: block; font-weight: 600; }
.bullets span { color: var(--muted); font-size: 0.9375rem; }

@media (min-width: 960px) {
  .features { gap: 120px; }
  .feature { grid-template-columns: 1fr 1fr; gap: 80px; }
  .feature:nth-child(even) .feature-copy { order: 2; }
  .phone { --phone-w: 320px; }
}

.lessons {
  display: grid;
  gap: 2px 20px;
  padding: 0;
  list-style: none;
  counter-reset: lesson;
  font-family: var(--serif);
  font-size: 1.0625rem;
}
.lessons li { counter-increment: lesson; padding: 6px 0; border-bottom: 1px solid var(--line); }
.lessons li::before { content: counter(lesson) " · "; color: var(--muted); }
@media (min-width: 560px) { .lessons { grid-template-columns: 1fr 1fr; } }

/* ---------- Cycle ---------- */

.phases { display: grid; gap: 12px; }
.phase { display: grid; gap: 10px; padding: 18px; }
.phase .bar { height: 6px; border-radius: 6px; }
.phase .chip { justify-self: start; }
.phase p { color: var(--muted); font-size: 0.9375rem; }
@media (min-width: 760px) { .phases { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Principles ---------- */

.principles { display: grid; gap: 12px; padding: 0; list-style: none; }
.principles li { display: grid; gap: 8px; padding: 22px; }
.principles .icon { width: 26px; height: 26px; color: var(--primary); }
.principles p { color: var(--muted); font-size: 0.9375rem; }
@media (min-width: 640px) { .principles { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .principles { grid-template-columns: repeat(3, 1fr); } }

/* ---------- FAQ ---------- */

.faq { display: grid; gap: 10px; max-width: 48rem; }
.faq details { padding: 0 20px; }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 60px;
  padding-block: 14px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  flex-shrink: 0;
  width: 9px;
  height: 9px;
  margin-right: 4px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(45deg) translateY(-3px);
  transition: transform 0.2s ease;
}
.faq details[open] summary::after { transform: rotate(-135deg) translate(-2px, -1px); }
.faq details > div { display: grid; gap: 10px; padding-bottom: 20px; color: var(--muted); }

/* ---------- Download ---------- */

.download {
  display: grid;
  justify-items: center;
  gap: 18px;
  padding: 48px 24px;
  border-radius: var(--r-sheet);
  background: var(--primary-tint);
  text-align: center;
}
.download p { color: var(--muted); max-width: 32rem; }
.download .brand-mark { width: 64px; height: 64px; }

/* ---------- Legal / support pages ---------- */

.page-head { padding-block: 40px 8px; }
.page-head .wrap { display: grid; gap: 14px; max-width: 48rem; margin-inline: 0; }
.page-head p { color: var(--muted); font-size: 1.125rem; }
@media (min-width: 960px) { .page-head { padding-top: 72px; } }

.page-body { padding-block: 24px 40px; }
.page-body .wrap { max-width: 48rem; margin-inline: 0; }
@media (min-width: 1120px) {
  .page-head .wrap, .page-body .wrap { margin-inline: auto; }
}

.prose { display: grid; gap: 16px; font-size: 1.0625rem; line-height: 1.6; }
.prose h2 { margin-top: 28px; font-size: clamp(1.625rem, 5vw, 2rem); line-height: 1.15; }
.prose h3 { margin-top: 8px; }
.prose ul, .prose ol { display: grid; gap: 8px; padding-left: 1.25em; }
.prose li::marker { color: var(--muted); }
.prose .note { padding: 16px 18px; border-radius: 16px; background: var(--primary-tint); }
.prose .note.amber { background: var(--amber-tint); }

.toc { padding: 18px 20px; }
.toc ol { display: grid; gap: 6px; margin-top: 8px; padding-left: 1.25em; font-size: 0.9375rem; }

.table-scroll { overflow-x: auto; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); }
.table-scroll table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 0.9375rem; line-height: 1.45; }
.table-scroll th, .table-scroll td { padding: 12px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.table-scroll th { background: var(--fill); font-weight: 600; }
.table-scroll tr:last-child td { border-bottom: 0; }

/* Phones: each row becomes a small card, with the column name above each value. */
@media (max-width: 639px) {
  .table-scroll table { min-width: 0; }
  .table-scroll thead { display: none; }
  .table-scroll tr, .table-scroll td { display: block; }
  .table-scroll tr { padding: 14px 16px; border-bottom: 1px solid var(--line); }
  .table-scroll tr:last-child { border-bottom: 0; }
  .table-scroll td { padding: 0; border: 0; }
  .table-scroll td:first-child { font-weight: 600; font-size: 1rem; }
  .table-scroll td[data-label] { margin-top: 8px; }
  .table-scroll td[data-label]::before {
    content: attr(data-label);
    display: block;
    color: var(--muted);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
  }
}

.contact-card { display: grid; gap: 12px; padding: 24px; }
.contact-card .btn { justify-self: start; }

/* ---------- 404 ---------- */

.not-found { display: grid; place-items: center; gap: 16px; min-height: 60vh; padding-block: 64px; text-align: center; }
.not-found p { color: var(--muted); }
