/* Ollivue website. Tokens match frontend/assets/theme/theme.json (olive palette), light and dark. */

@property --sky { syntax: "<color>"; inherits: true; initial-value: #FFE7C2; }

:root {
  --accent: #556B2F;
  --on-accent: #FFFFFF;
  --accent-tint: color-mix(in srgb, var(--accent) 12%, transparent);
  --bg: #F2F2F7;
  --card: #FFFFFF;
  --label: #000000;
  --label-2: #6C6C70;
  --separator: #D1D1D6;
  --fill: #E9E9EE;
  --done: #1E7A35;
  --done-tint: #E3F5E7;
  --blocked: #D70015;
  --risk: #B25000;
  --bar: rgba(249, 249, 249, 0.8);
  --bezel: #1C1C1E;
  --bezel-edge: #3A3A3C;
  --shadow: 0 24px 60px -20px rgba(40, 52, 20, 0.35);
  --sky-1: #FFE7C2; --sky-2: #D8EAFF; --sky-3: #FFD8C4; --sky-4: #DADAF2;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", "Segoe UI", Roboto, system-ui, sans-serif;
  --serif: ui-serif, "New York", "Iowan Old Style", Georgia, serif;
  --ease-pop: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --accent: #9ACD32;
    --on-accent: #000000;
    --accent-tint: color-mix(in srgb, var(--accent) 20%, transparent);
    --bg: #000000;
    --card: #1C1C1E;
    --label: #FFFFFF;
    --label-2: #98989F;
    --separator: #38383A;
    --fill: #2C2C2E;
    --done: #4CD964;
    --done-tint: #14301C;
    --blocked: #FF6961;
    --risk: #FFB340;
    --bar: rgba(28, 28, 30, 0.8);
    --bezel: #2C2C2E;
    --bezel-edge: #636366;
    --shadow: 0 24px 60px -20px rgba(154, 205, 50, 0.25);
    --sky-1: #3A2C12; --sky-2: #0E2338; --sky-3: #3A1E14; --sky-4: #14152C;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0; background: var(--bg); color: var(--label); font-family: var(--font);
  font-size: 17px; line-height: 1.47; -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, p { margin: 0; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.eyebrow { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.lede { font-size: 21px; line-height: 1.4; color: var(--label-2); }
.muted { color: var(--label-2); }
section { padding: 88px 0; }
h2 { text-wrap: balance; font-size: clamp(30px, 4.4vw, 44px); line-height: 1.1; letter-spacing: -0.02em; font-weight: 700; }
.section-head { max-width: 640px; margin-bottom: 44px; display: grid; gap: 12px; }

/* ---------- header ---------- */
header.nav {
  position: sticky; top: 0; z-index: 50; background: var(--bar);
  backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid color-mix(in srgb, var(--separator) 60%, transparent);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 19px; color: var(--label); }
.brand:hover { text-decoration: none; }
.brand img { width: 30px; height: 30px; border-radius: 8px; }
.nav nav { display: flex; align-items: center; gap: 26px; font-size: 15px; }
.nav nav a { color: var(--label-2); }
.nav nav a:hover { color: var(--label); text-decoration: none; }
.nav nav a.btn-filled, .nav nav a.btn-filled:hover { color: var(--on-accent); }
.pill {
  display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; font-size: 14px;
  font-weight: 600; background: var(--accent-tint); color: var(--accent);
}
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.7); opacity: 0.35; } }

.btn {
  display: inline-flex; align-items: center; justify-content: center; height: 50px; padding: 0 26px; border-radius: 14px;
  font-size: 17px; font-weight: 600; border: 0; cursor: pointer; transition: transform 0.2s var(--ease-pop), box-shadow 0.2s;
}
.btn:hover { transform: translateY(-2px); text-decoration: none; }
.btn:active { transform: scale(0.97); }
.btn-filled { background: var(--accent); color: var(--on-accent); box-shadow: 0 10px 24px -10px var(--accent); }
.btn-plain { background: var(--accent-tint); color: var(--accent); }

/* ---------- hero: the sky changes through the day, like the Today screen ---------- */
.hero {
  padding: 72px 0 96px; overflow: hidden;
  --sky: var(--sky-1);
  background: linear-gradient(180deg, var(--sky) 0%, var(--bg) 78%);
  animation: sky 32s linear infinite;
}
@keyframes sky {
  0%, 100% { --sky: var(--sky-1); } 25% { --sky: var(--sky-2); } 50% { --sky: var(--sky-3); } 75% { --sky: var(--sky-4); }
}
.hero .wrap { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center; }
.hero h1 { text-wrap: balance; font-size: clamp(40px, 5.4vw, 62px); line-height: 1.03; letter-spacing: -0.03em; font-weight: 800; margin: 18px 0 20px; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lede { max-width: 520px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero .soon { margin-top: 22px; font-size: 15px; color: var(--label-2); }

.stage { position: relative; display: grid; place-items: center; justify-items: end; min-height: 560px; }
.tilt { transition: transform 0.25s ease-out; transform-style: preserve-3d; }
.stage .phone { animation: float 7s ease-in-out infinite; }
@keyframes float { 0%, 100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(-14px) rotate(1deg); } }

/* ---------- iPhone frame ---------- */
.phone {
  position: relative; width: 270px; aspect-ratio: 390 / 844; border-radius: 46px; padding: 9px;
  background: var(--bezel); box-shadow: var(--shadow), inset 0 0 0 2px var(--bezel-edge); flex: none;
  transform-style: preserve-3d; transition: transform 0.25s ease-out;
}
.phone .screen { position: relative; width: 100%; height: 100%; border-radius: 38px; overflow: hidden; background: var(--bg); }
.phone .screen img { width: 100%; height: 100%; object-fit: cover; }
.phone .island { position: absolute; top: 20px; left: 50%; translate: -50% 0; width: 78px; height: 22px; border-radius: 12px; background: #000; z-index: 3; }
.phone .status {
  position: absolute; z-index: 2; top: 17px; left: 0; right: 0; display: flex; justify-content: space-between;
  padding: 0 30px; font-size: 11px; font-weight: 600; color: var(--label);
}
.phone .status i { display: inline-block; width: 18px; height: 9px; border-radius: 3px; border: 1.5px solid var(--label); position: relative; }
.phone .status i::after { content: ""; position: absolute; inset: 1px; right: 4px; border-radius: 1px; background: var(--label); }
.phone .bar { position: absolute; bottom: 6px; left: 50%; translate: -50% 0; width: 90px; height: 4px; border-radius: 2px; background: var(--label); opacity: 0.8; z-index: 2; }

/* chat bubbles that "type" beside the phone (like the PO in the app) */
.bubbles { position: absolute; left: 0; bottom: 6%; width: min(250px, 52%); display: grid; gap: 10px; z-index: 5; pointer-events: none; }
.bubble {
  padding: 11px 15px; border-radius: 18px; font-size: 15px; line-height: 1.35; box-shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.3);
  transform-origin: left bottom; position: relative;
}
.js .bubble { opacity: 0; transform: translateY(14px) scale(0.92); }
.js .bubble.show { opacity: 1; transform: none; transition: opacity 0.35s, transform 0.5s var(--ease-pop); }
.bubble.po { background: var(--card); color: var(--label); border-bottom-left-radius: 4px; font-family: var(--serif); font-size: 16px; }
.bubble.me { background: var(--accent); color: var(--on-accent); border-bottom-right-radius: 4px; justify-self: end; transform-origin: right bottom; }
.bubble.typing { display: inline-flex; gap: 4px; padding: 14px 16px; }
.bubble.typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--label-2); animation: blink 1.1s infinite; }
.bubble.typing span:nth-child(2) { animation-delay: 0.15s; }
.bubble.typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes blink { 0%, 60%, 100% { opacity: 0.25; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }

/* ---------- marquee ---------- */
.marquee { border-block: 1px solid var(--separator); overflow: hidden; padding: 18px 0; background: var(--card); }
.marquee .track { display: flex; gap: 48px; width: max-content; animation: slide 36s linear infinite; }
.marquee span { font-weight: 600; font-size: 17px; white-space: nowrap; display: inline-flex; align-items: center; gap: 48px; }
.marquee span::after { content: "•"; color: var(--accent); }
@keyframes slide { to { transform: translateX(-50%); } }

/* ---------- cards ---------- */
.grid { display: grid; gap: 16px; }
.grid.three { grid-template-columns: repeat(3, 1fr); }
.grid.four { grid-template-columns: repeat(4, 1fr); }
.card {
  background: var(--card); border-radius: 22px; padding: 26px; display: grid; gap: 10px; align-content: start;
  transition: transform 0.3s var(--ease-pop), box-shadow 0.3s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card h3 { font-size: 20px; line-height: 1.25; letter-spacing: -0.01em; }
.card p { color: var(--label-2); font-size: 16px; line-height: 1.45; }
.card .ico { width: 44px; height: 44px; border-radius: 12px; background: var(--accent-tint); color: var(--accent); display: grid; place-items: center; font-size: 22px; }

/* ---------- how it works ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; position: relative; counter-reset: step; }
.step { position: relative; }
.step .n {
  width: 38px; height: 38px; border-radius: 50%; background: var(--accent); color: var(--on-accent); font-weight: 700;
  display: grid; place-items: center; margin-bottom: 4px;
}
.lifecycle { margin-top: 28px; background: var(--card); border-radius: 22px; padding: 22px 26px; }
.lifecycle h3 { font-size: 15px; margin-bottom: 14px; color: var(--label-2); font-weight: 600; }
.lane { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.lane > div { background: var(--fill); border-radius: 14px; padding: 10px; min-height: 92px; position: relative; font-size: 13px; font-weight: 600; color: var(--label-2); }
.lane > div.on { background: var(--accent-tint); color: var(--accent); }
.story-chip {
  position: absolute; left: 10px; right: 10px; bottom: 10px; background: var(--card); color: var(--label); border-radius: 10px;
  padding: 9px 10px; font-size: 13px; font-weight: 600; box-shadow: 0 6px 16px -8px rgba(0, 0, 0, 0.3);
  animation: pop 0.55s var(--ease-pop);
}
.story-chip.ok { background: var(--done-tint); color: var(--done); }
@keyframes pop { from { transform: scale(0.7) translateY(10px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---------- meet your PO ---------- */
.po-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.avatars { display: flex; flex-wrap: wrap; gap: 14px; margin: 22px 0; }
.avatar { text-align: center; font-size: 13px; font-weight: 600; color: var(--label-2); }
.avatar img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; margin-bottom: 6px; box-shadow: 0 8px 20px -10px rgba(0, 0, 0, 0.5); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 7px 14px; border-radius: 999px; background: var(--fill); font-size: 14px; font-weight: 500; }
.seg { display: flex; padding: 3px; border-radius: 12px; background: var(--fill); margin-bottom: 18px; position: relative; }
.seg button {
  flex: 1; border: 0; background: none; font: inherit; font-size: 15px; font-weight: 600; padding: 9px 0; border-radius: 9px;
  color: var(--label-2); cursor: pointer; position: relative; z-index: 1; transition: color 0.2s;
}
.seg button[aria-selected="true"] { color: var(--label); }
.seg .thumb { position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc((100% - 6px) / 3); border-radius: 9px; background: var(--card); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12); transition: transform 0.35s var(--ease-pop); }
.voice { background: var(--card); border-radius: 22px; padding: 26px; display: grid; gap: 14px; box-shadow: var(--shadow); }
.voice .who { display: flex; align-items: center; gap: 12px; font-weight: 600; }
.voice .who img { width: 44px; height: 44px; border-radius: 50%; }
.voice .who small { display: block; font-weight: 400; color: var(--label-2); font-size: 13px; }
.voice blockquote { margin: 0; font-family: var(--serif); font-size: 22px; line-height: 1.35; min-height: 120px; }
.voice blockquote::after { content: "▍"; color: var(--accent); animation: caret 1s steps(1) infinite; margin-left: 2px; }
@keyframes caret { 50% { opacity: 0; } }

/* ---------- screens ---------- */
.screens { background: var(--card); }
.rail { display: flex; gap: 28px; overflow-x: auto; padding: 24px max(16px, calc((100vw - 1120px) / 2)) 40px; scroll-snap-type: x mandatory; scrollbar-width: none; }
.rail::-webkit-scrollbar { display: none; }
.shot { scroll-snap-align: center; display: grid; gap: 18px; justify-items: center; flex: none; width: 270px; }
.shot figcaption { text-align: center; font-size: 15px; color: var(--label-2); max-width: 250px; }
.shot figcaption b { display: block; color: var(--label); font-size: 17px; margin-bottom: 2px; }
.shot .phone { transition: transform 0.4s var(--ease-pop); }
.shot:hover .phone { transform: translateY(-8px) rotate(-1deg); }
.hint { text-align: center; color: var(--label-2); font-size: 14px; margin-top: -8px; }

/* ---------- stats ---------- */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 28px; }
.stat { text-align: center; }
.ring { width: 120px; height: 120px; margin: 0 auto 10px; position: relative; }
.ring svg { transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 9; }
.ring .track { stroke: var(--fill); }
.ring .bar-fg { stroke: var(--accent); stroke-linecap: round; stroke-dasharray: 289; stroke-dashoffset: 289; transition: stroke-dashoffset 1.6s var(--ease-out); }
.ring b { position: absolute; inset: 0; display: grid; place-items: center; font-size: 30px; font-weight: 800; letter-spacing: -0.02em; }

/* ---------- contact + footer ---------- */
.contact { background: linear-gradient(135deg, var(--accent), color-mix(in srgb, var(--accent) 60%, #000)); color: var(--on-accent); border-radius: 28px; padding: 56px 40px; text-align: center; display: grid; gap: 14px; justify-items: center; }
.contact h2 { color: inherit; }
.contact p { opacity: 0.9; font-size: 19px; max-width: 520px; }
.contact a.mail { display: inline-block; margin-top: 8px; font-size: 22px; font-weight: 700; color: inherit; border-bottom: 2px solid currentColor; padding-bottom: 2px; }
.contact .meta { display: flex; flex-wrap: wrap; gap: 10px 28px; justify-content: center; margin-top: 12px; font-size: 15px; opacity: 0.85; }
footer { padding: 36px 0 56px; color: var(--label-2); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 28px; justify-content: space-between; align-items: center; }
footer nav { display: flex; gap: 22px; }
footer a { color: var(--label-2); }

/* ---------- scroll reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s var(--ease-out), transform 0.8s var(--ease-out); transition-delay: calc(var(--i, 0) * 90ms); }
.js .reveal.in { opacity: 1; transform: none; }

/* ---------- legal pages ---------- */
.doc { max-width: 720px; padding: 56px 0 24px; }
.doc h1 { font-size: clamp(34px, 5vw, 48px); letter-spacing: -0.02em; line-height: 1.1; margin-bottom: 8px; }
.doc .updated { color: var(--label-2); margin-bottom: 36px; }
.doc h2 { font-size: 22px; letter-spacing: -0.01em; margin: 36px 0 10px; }
.doc p, .doc li { color: var(--label); opacity: 0.88; margin-bottom: 12px; }
.doc ul { padding-left: 22px; margin: 0 0 12px; }
.doc .toc { background: var(--card); border-radius: 18px; padding: 18px 22px; margin-bottom: 20px; columns: 2; font-size: 15px; }
.doc .toc a { display: block; padding: 3px 0; }

/* ---------- small screens ---------- */
@media (max-width: 920px) {
  section { padding: 64px 0; }
  .hero .wrap, .po-grid { grid-template-columns: 1fr; gap: 36px; }
  .hero { padding: 40px 0 64px; }
  .grid.three, .grid.four, .steps, .stats { grid-template-columns: 1fr 1fr; }
  .stage { min-height: 0; padding-bottom: 8px; justify-items: center; }
  .bubbles { position: static; width: min(340px, 100%); margin: 20px auto 0; }
  .nav nav a:not(.keep) { display: none; }
  .doc .toc { columns: 1; }
}
@media (max-width: 560px) {
  .grid.three, .grid.four, .steps, .stats { grid-template-columns: 1fr; }
  .lane { grid-template-columns: 1fr 1fr; }
  .contact { padding: 40px 22px; }
  .lede { font-size: 19px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .js .reveal, .js .bubble { opacity: 1; transform: none; }
  .ring .bar-fg { stroke-dashoffset: 72; }
}
