/* HalfPast planner site. The app's warm neutrals, ink text, the icon's green and amber as accents. */

@font-face {
  font-family: "Jakarta";
  src: url("/fonts/PlusJakartaSans-latin.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --bg: #f5f3ee;
  --bg-deep: #ece8df;
  --card: #ffffff;
  --ink: #1b1c1e;
  --muted: #5c5f63;
  --faint: #8a8c8f;
  --line: #e4dfd5;
  --green: #1a7f37;
  --green-soft: #e2f0e5;
  --amber: #f9ab00;
  --amber-ink: #8a5a00;
  --amber-soft: #fdf1d0;
  --phone: #1b1c1f;
  --shadow-lg: 0 40px 80px -30px rgba(48, 40, 24, 0.32), 0 16px 32px -16px rgba(48, 40, 24, 0.18);
  --shadow-sm: 0 1px 2px rgba(48, 40, 24, 0.06), 0 8px 24px -12px rgba(48, 40, 24, 0.16);
  --radius: 24px;
  --max: 1180px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141413;
    --bg-deep: #1b1b19;
    --card: #1f1f1d;
    --ink: #efede7;
    --muted: #aeaba4;
    --faint: #85827c;
    --line: #2f2e2a;
    --green: #5bb974;
    --green-soft: #1d3123;
    --amber-ink: #fbc02d;
    --amber-soft: #352c19;
    --shadow-lg: 0 40px 80px -30px rgba(0, 0, 0, 0.75), 0 16px 32px -16px rgba(0, 0, 0, 0.5);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4), 0 8px 24px -12px rgba(0, 0, 0, 0.5);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Jakarta", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
figure { margin: 0; }
a { color: inherit; }
h1, h2, h3 { line-height: 1.1; letter-spacing: -0.028em; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2.6rem, 5.2vw, 4.1rem); font-weight: 800; }
h2 { font-size: clamp(2rem, 3.6vw, 2.9rem); font-weight: 800; }
h3 { font-size: 1.18rem; font-weight: 700; letter-spacing: -0.012em; line-height: 1.3; }
p { margin: 0; text-wrap: pretty; }
:focus-visible { outline: 2.5px solid var(--green); outline-offset: 3px; border-radius: 8px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 28px; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 50; background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 10px; }
.skip:focus { left: 8px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; margin: 0;
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--green);
}
.eyebrow::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

/* Buttons */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 24px; border-radius: 999px; border: 0; cursor: pointer;
  font: inherit; font-weight: 700; font-size: 0.95rem; text-decoration: none; white-space: nowrap;
  background: var(--ink); color: var(--bg);
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s;
}
.button:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.button.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.button.ghost:hover { box-shadow: inset 0 0 0 1.5px var(--faint); }
.button.light { background: var(--bg); color: var(--ink); }
.button.small { height: 40px; padding: 0 18px; font-size: 0.9rem; }
.play-badge { display: inline-block; line-height: 0; }
.play-badge img { height: 64px; width: auto; margin: -10px; }

/* Header */
.top {
  position: sticky; top: 0; z-index: 30;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: saturate(1.5) blur(16px);
  -webkit-backdrop-filter: saturate(1.5) blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.top.scrolled { border-bottom-color: var(--line); }
.top .wrap { display: flex; align-items: center; gap: 32px; height: 70px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.2rem; text-decoration: none; letter-spacing: -0.02em; }
.brand img { width: 34px; height: 34px; border-radius: 10px; }
.nav { display: flex; gap: 30px; margin-left: auto; }
.nav a { text-decoration: none; color: var(--muted); font-weight: 600; font-size: 0.93rem; transition: color 0.15s; }
.nav a:hover { color: var(--ink); }
.menu { display: none; }

/* Hero */
.hero { padding: 72px 0 56px; overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: 1.02fr 1fr; gap: 48px; align-items: center; }
.hero h1 { margin: 20px 0 22px; text-wrap: wrap; }
.hero h1 em { font-style: normal; color: var(--green); }
.hero .lead { font-size: 1.2rem; color: var(--muted); max-width: 32ch; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; margin-top: 36px; }
.trust { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 10px 24px; margin: 30px 0 0; font-size: 0.92rem; color: var(--muted); font-weight: 600; }
.trust li { display: inline-flex; align-items: center; gap: 8px; }
.trust li::before {
  content: ""; width: 18px; height: 18px; border-radius: 50%;
  background: var(--green-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z' fill='%231a7f37'/%3E%3C/svg%3E") center / 13px no-repeat;
}

.stage { position: relative; height: 640px; }
.stage .phone { position: absolute; }
.stage .phone.front { width: 296px; left: 50%; top: 6px; transform: translateX(-26%) rotate(2deg); z-index: 2; }
.stage .phone.back { width: 256px; left: 50%; top: 66px; transform: translateX(-104%) rotate(-6deg); }
.stage .glow {
  position: absolute; inset: 30px -20px 0 0; border-radius: 50%;
  background:
    radial-gradient(closest-side at 62% 42%, color-mix(in srgb, var(--amber) 22%, transparent), transparent 70%),
    radial-gradient(closest-side at 38% 62%, color-mix(in srgb, var(--green) 18%, transparent), transparent 72%);
  filter: blur(10px);
}
.chip {
  position: absolute; z-index: 3; display: flex; align-items: center; gap: 12px;
  padding: 10px 18px 10px 10px; border-radius: 18px; background: var(--card); box-shadow: var(--shadow-lg);
  font-size: 0.88rem; font-weight: 700; white-space: nowrap; line-height: 1.35;
}
.chip small { display: block; font-weight: 600; color: var(--muted); font-size: 0.78rem; }
.chip.one { top: 118px; right: -8px; animation: float 6s ease-in-out infinite; }
.chip.two { bottom: 92px; left: 0; animation: float 7s ease-in-out -2s infinite; }
@keyframes float { 50% { transform: translateY(-8px); } }

.ic { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 12px; flex: none; }
.ic svg { width: 19px; height: 19px; }
.ic.green { background: var(--green-soft); fill: var(--green); }
.ic.amber { background: var(--amber-soft); fill: var(--amber-ink); }
.ic.big { width: 50px; height: 50px; border-radius: 16px; }
.ic.big svg { width: 24px; height: 24px; }

/* Phone and tablet frames */
.phone { padding: 9px; border-radius: 46px; background: var(--phone); box-shadow: var(--shadow-lg), inset 0 0 0 1.5px #3b3c40; }
.phone img { border-radius: 37px; width: 100%; height: auto; }
.tablet { margin: 44px auto 0; max-width: 1020px; padding: 14px; border-radius: 34px; background: var(--phone); box-shadow: var(--shadow-lg), inset 0 0 0 1.5px #3b3c40; }
.tablet img { border-radius: 22px; width: 100%; height: auto; }

/* Sections */
section { scroll-margin-top: 84px; }
.section-head { text-align: center; max-width: 740px; margin: 0 auto 24px; }
.section-head h2 { margin-top: 14px; }
.section-head p:not(.eyebrow) { margin-top: 16px; font-size: 1.12rem; color: var(--muted); }

.features { padding: 96px 0 40px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; padding: 64px 0; }
.row + .row { border-top: 1px solid var(--line); }
.row.flip .copy { order: 2; }
.row h3 { font-size: clamp(1.75rem, 3vw, 2.4rem); font-weight: 800; letter-spacing: -0.028em; line-height: 1.12; margin: 14px 0 18px; }
.row .copy > p:not(.eyebrow) { color: var(--muted); font-size: 1.1rem; }
.points { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 14px; }
.points li { position: relative; padding-left: 38px; color: var(--muted); }
.points li strong { color: var(--ink); font-weight: 700; }
.points li::before {
  content: ""; position: absolute; left: 0; top: 1px; width: 26px; height: 26px; border-radius: 9px;
  background: var(--green-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z' fill='%231a7f37'/%3E%3C/svg%3E") center / 15px no-repeat;
}
.tag {
  display: inline-block; padding: 2px 9px; border-radius: 999px; margin: 0 2px; vertical-align: 2px;
  font-size: 0.7rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase;
  background: var(--amber-soft); color: var(--amber-ink);
}

.shots { position: relative; display: flex; justify-content: center; align-items: flex-start; gap: 28px; padding: 34px 0; isolation: isolate; }
.shots::before { content: ""; position: absolute; inset: 0 2%; border-radius: 40px; z-index: -1; background: linear-gradient(160deg, var(--bg-deep), transparent 80%); }
.shots .phone { width: min(280px, 44%); }
.shots:not(.pair) .phone { width: min(300px, 62%); }
.shots.pair .phone:nth-child(2) { margin-top: 72px; }

/* How it works */
.how { padding: 80px 0; }
.steps { list-style: none; padding: 0; margin: 44px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; counter-reset: step; }
.steps li { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow-sm); }
.steps span { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 13px; background: var(--ink); color: var(--bg); font-weight: 800; margin-bottom: 22px; }
.steps p { color: var(--muted); margin-top: 10px; }

/* Tablet and dark bands */
.tablet-band { padding: 72px 0 96px; }
.dark-band {
  color: #eeece6; padding: 100px 0;
  background: radial-gradient(60% 80% at 80% 50%, rgba(249, 171, 0, 0.09), transparent), #0f0f0e;
  border-block: 1px solid #262522;
}
.dark-band .wrap { display: grid; grid-template-columns: 1fr 1.1fr; gap: 64px; align-items: center; }
.dark-band h2 { margin-top: 14px; }
.dark-band .copy > p:not(.eyebrow) { color: #aeaba4; font-size: 1.12rem; margin-top: 18px; max-width: 40ch; }
.dark-band .eyebrow { color: var(--amber); }
.dark-band .shots::before { background: radial-gradient(closest-side, rgba(249, 171, 0, 0.1), transparent); }
.dark-band .phone { box-shadow: 0 40px 80px -24px rgba(0, 0, 0, 0.9), inset 0 0 0 1.5px #3b3c40; }

/* Values */
.values { padding: 96px 0 72px; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 44px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow-sm); }
.card .ic { margin-bottom: 22px; }
.card p { color: var(--muted); margin-top: 10px; }

/* Pricing */
.plans { padding: 72px 0 88px; }
.plan-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin: 44px auto 0; max-width: 940px; }
.plan { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 36px; display: flex; flex-direction: column; box-shadow: var(--shadow-sm); }
.plan.plus { background: #1b1c1e; color: #f5f3ee; border-color: #1b1c1e; }
.plan h3 { font-size: 1.5rem; display: flex; align-items: center; gap: 10px; }
.plan .price { color: var(--muted); margin: 6px 0 24px; }
.plan.plus .price { color: #aeaba4; }
.plan ul { list-style: none; padding: 0; margin: 0 0 30px; display: grid; gap: 12px; flex: 1; }
.plan li { position: relative; padding-left: 30px; font-weight: 500; }
.plan li::before { content: "✓"; position: absolute; left: 0; font-weight: 800; color: var(--green); }
.plan.plus li::before { color: var(--amber); }
.plan .button { align-self: flex-start; }
.plan.plus .button.light { background: #f5f3ee; color: #1b1c1e; }
.badge { font-size: 0.7rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; background: var(--amber); color: #3a2a00; }

/* FAQ */
.faq { padding: 40px 0 96px; }
.faq .list { max-width: 800px; margin: 40px auto 0; display: grid; gap: 12px; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 0 26px; transition: box-shadow 0.2s; }
.faq details[open] { box-shadow: var(--shadow-sm); }
.faq summary { cursor: pointer; list-style: none; padding: 22px 0; font-weight: 700; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.5rem; font-weight: 500; line-height: 1; color: var(--faint); transition: transform 0.2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 0 24px; color: var(--muted); }
.faq details a { color: var(--green); font-weight: 600; }

/* Final call to action */
.final { padding: 0 0 100px; }
.final .box {
  border-radius: 40px; padding: 76px 40px; text-align: center; position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--green-soft), var(--amber-soft));
}
.final .icon { width: 76px; height: 76px; border-radius: 22px; margin: 0 auto 28px; box-shadow: var(--shadow-lg); }
.final p { color: var(--muted); font-size: 1.15rem; margin: 16px auto 30px; max-width: 46ch; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 56px 0 44px; font-size: 0.92rem; }
.site-footer .wrap { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 32px; }
.site-footer h2 { font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--faint); margin-bottom: 14px; }
.site-footer nav { display: flex; flex-direction: column; gap: 10px; }
.site-footer nav a { text-decoration: none; color: var(--muted); font-weight: 600; }
.site-footer nav a:hover { color: var(--ink); }
.foot-brand p { color: var(--muted); margin-top: 14px; max-width: 30ch; }
.site-footer .legal { grid-column: 1 / -1; color: var(--faint); font-size: 0.82rem; border-top: 1px solid var(--line); padding-top: 24px; margin-top: 12px; }

/* Text pages: account deletion, privacy policy, terms */
.doc { max-width: 780px; padding-top: 56px; padding-bottom: 88px; }
.crumbs { font-size: 0.88rem; color: var(--faint); margin-bottom: 18px; }
.crumbs a { color: var(--muted); text-decoration: none; font-weight: 600; }
.doc h1 { font-size: clamp(2.2rem, 4.5vw, 3rem); margin-bottom: 16px; }
.doc h2 { font-size: 1.45rem; margin: 48px 0 14px; letter-spacing: -0.015em; }
.doc h3 { margin: 30px 0 10px; }
.doc .lead { font-size: 1.2rem; color: var(--muted); }
.doc p + p { margin-top: 14px; }
.doc ul, .doc ol { padding-left: 1.3em; display: grid; gap: 8px; }
.doc a { color: var(--green); font-weight: 600; overflow-wrap: anywhere; }
.doc table { width: 100%; border-collapse: collapse; margin: 18px 0; font-size: 0.92rem; display: block; overflow-x: auto; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.doc th { font-weight: 700; }
.doc blockquote { margin: 18px 0; padding: 14px 18px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); }
.doc .small { font-size: 0.9rem; margin-top: 44px; color: var(--muted); }

/* Reveal on scroll: hidden only when the script runs, so the page is complete without JavaScript. */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.7s ease, transform 0.7s ease; }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .chip { animation: none !important; }
  html { scroll-behavior: auto; }
}

/* Responsive */
@media (max-width: 1000px) {
  .hero .wrap, .row, .dark-band .wrap { grid-template-columns: 1fr; gap: 32px; }
  .hero { padding-top: 40px; }
  .hero .copy { text-align: center; }
  .hero .lead { margin: 0 auto; }
  .hero .cta-row, .trust { justify-content: center; }
  .stage { height: 560px; max-width: 470px; width: 100%; margin: 0 auto; }
  .stage .phone.front { width: 252px; }
  .stage .phone.back { width: 220px; }
  .row.flip .copy { order: 0; }
  .row { padding: 48px 0; }
  .steps, .cards, .plan-grid { grid-template-columns: 1fr; }
  .site-footer .wrap { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
}
@media (max-width: 820px) {
  .top .wrap { gap: 14px; }
  .top .button.small { margin-left: auto; }
  .menu {
    display: grid; place-content: center; gap: 5px; width: 42px; height: 42px; border: 0; border-radius: 12px;
    background: transparent; cursor: pointer; color: var(--ink);
  }
  .menu span { display: block; width: 20px; height: 2px; border-radius: 2px; background: currentColor; transition: transform 0.2s; }
  .menu[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .menu[aria-expanded="true"] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
  .nav {
    display: none; position: absolute; top: 70px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px 28px 18px;
  }
  .nav.open { display: flex; }
  .nav a { padding: 12px 0; font-size: 1.05rem; border-bottom: 1px solid var(--line); }
  .nav a:last-child { border-bottom: 0; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .wrap { padding: 0 18px; }
  .stage { height: 470px; }
  .stage .phone.front { width: 206px; }
  .stage .phone.back { width: 180px; transform: translateX(-96%) rotate(-6deg); }
  .chip { font-size: 0.8rem; padding: 8px 12px 8px 8px; gap: 9px; }
  .chip .ic { width: 30px; height: 30px; }
  .chip.one { top: 70px; right: -4px; }
  .chip.two { bottom: 40px; left: -4px; }
  .shots { gap: 14px; }
  .phone { padding: 6px; border-radius: 30px; }
  .phone img { border-radius: 25px; }
  .final .box { padding: 54px 22px; border-radius: 30px; }
  .play-badge img { height: 58px; }
  .top .button.small { display: none; }
  .menu { margin-left: auto; }
}
