/* Cold Wave site. Tokens mirror src/theme.ts in the app. */
:root {
  --slate: #222B36;
  --slate-2: #2E3946;
  --cream: #F1EEE8;
  --ice: #7DB3C7;
  --ice-deep: #2F6F87;
  --muted: #5B6672;
  --surface: #FFFFFF;
  --line: #DDD8CF;
  --on-slate: #E9EEF2;
  --on-slate-muted: #9AA8B4;

  --measure: 34rem;
  --wrap: 72rem;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --radius: 1.5rem;

  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.3125rem;
  --step-2: 1.75rem;
  --step-3: clamp(2rem, 4.5vw, 2.75rem);
  --step-4: clamp(2.75rem, 7vw, 4.75rem);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--slate);
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  font-size: var(--step-0);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--ice-deep); text-underline-offset: 0.18em; }
a:hover { color: var(--slate); }
:focus-visible { outline: 3px solid var(--ice); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { margin: 0; line-height: 1.1; letter-spacing: -0.02em; }
p { margin: 0; }

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

/* Header */
.site-header { position: absolute; inset: 0 0 auto; z-index: 2; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 4.5rem; }
.logo { display: inline-flex; align-items: center; gap: 0.6rem; font-weight: 700; font-size: 1.0625rem; color: inherit; text-decoration: none; }
.logo img { width: 2rem; height: 2rem; border-radius: 0.55rem; }
.site-header nav { display: flex; gap: 1.5rem; font-size: var(--step--1); font-weight: 600; }
.site-header nav a { color: inherit; text-decoration: none; opacity: 0.8; }
.site-header nav a:hover { opacity: 1; color: inherit; }
.on-slate { color: var(--on-slate); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 3.25rem; padding: 0 1.6rem; border-radius: 999px; border: 0;
  font: inherit; font-weight: 700; font-size: 1rem; text-decoration: none; cursor: pointer;
}
.btn-ice { background: var(--ice); color: var(--slate); }
.btn-ice:hover { background: #93C2D3; color: var(--slate); }
.btn-slate { background: var(--slate); color: #fff; }
.btn-slate:hover { background: var(--slate-2); color: #fff; }
.btn-ghost { background: transparent; color: var(--on-slate); box-shadow: inset 0 0 0 1.5px rgba(233,238,242,0.35); }
.btn-ghost:hover { color: #fff; box-shadow: inset 0 0 0 1.5px rgba(233,238,242,0.7); }
.btn[aria-disabled="true"] { cursor: default; }
.btn svg { width: 1.15rem; height: 1.15rem; }

/* Hero: the in-session timer screen */
.hero {
  position: relative;
  background:
    radial-gradient(60rem 40rem at 72% 45%, rgba(125,179,199,0.16), transparent 60%),
    var(--slate);
  color: var(--on-slate);
  padding: 8rem 0 6rem;
  overflow: hidden;
}
.hero .wrap { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 3rem; align-items: center; }
.hero h1 { font-size: var(--step-4); font-weight: 800; letter-spacing: -0.035em; color: #fff; }
.hero .lede { margin-top: 1.25rem; max-width: 28rem; font-size: var(--step-1); line-height: 1.5; color: var(--on-slate-muted); }
.hero .ctas { margin-top: 2.25rem; display: flex; flex-wrap: wrap; gap: 0.75rem; }
.hero .fine { margin-top: 1rem; font-size: var(--step--1); color: var(--on-slate-muted); }

.timer { display: grid; justify-items: center; gap: 1.5rem; }
.ring { position: relative; width: min(24rem, 78vw); aspect-ratio: 1; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring .track { stroke: rgba(233,238,242,0.12); }
.ring .fill { stroke: var(--ice); stroke-linecap: round; transition: stroke-dashoffset 1s linear; }
.ring::before { content: ""; position: absolute; inset: 3%; border-radius: 50%; box-shadow: 0 0 40px 2px rgba(125,179,199,0.28), inset 0 0 40px rgba(125,179,199,0.12); pointer-events: none; }
.ring .readout { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.ring .clock { font-size: clamp(3.5rem, 11vw, 5.25rem); font-weight: 800; letter-spacing: -0.04em; color: #fff; font-variant-numeric: tabular-nums; line-height: 1; }
.ring .cue { margin-top: 0.85rem; font-weight: 600; color: var(--on-slate); min-height: 1.6em; }
.ring .sub { font-size: var(--step--1); color: var(--on-slate-muted); min-height: 1.4em; }
.timer .btn { min-width: 13rem; }
.breathing .ring::before { animation: breathe 8s ease-in-out infinite; }
@keyframes breathe { 0%, 100% { opacity: 0.45; transform: scale(0.97); } 50% { opacity: 1; transform: scale(1.03); } }

/* Sections */
.section { padding: clamp(4.5rem, 10vw, 7.5rem) 0; }
.section h2 { font-size: var(--step-3); font-weight: 800; max-width: 22ch; }
.section .intro { margin-top: 1rem; max-width: var(--measure); color: var(--muted); font-size: var(--step-1); line-height: 1.5; }

/* 11 minutes a week */
.week { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: clamp(2rem, 6vw, 5rem); align-items: end; }
.week .figure { font-size: clamp(6rem, 18vw, 11rem); font-weight: 800; letter-spacing: -0.06em; line-height: 0.85; font-variant-numeric: tabular-nums; }
.week .figure small { font-size: 0.22em; letter-spacing: -0.01em; font-weight: 700; margin-left: 0.4em; }
.week .note { margin-top: 1.5rem; max-width: 30rem; color: var(--muted); }
.week .note cite { font-style: normal; font-weight: 600; color: var(--slate); }
.bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: 0.6rem; align-items: end; height: 15rem; }
.bar { display: grid; grid-template-rows: 1fr auto auto; gap: 0.4rem; height: 100%; text-align: center; font-size: var(--step--1); }
.bar span:first-child { align-self: end; height: var(--h); min-height: 0.5rem; border-radius: 0.6rem; background: var(--slate); }
.bar.rest span:first-child { background: var(--line); }
.bar .min { font-weight: 700; font-variant-numeric: tabular-nums; }
.bar .day { color: var(--muted); }
.bars-total { margin-top: 1.25rem; display: flex; justify-content: space-between; gap: 1rem; padding-top: 1rem; border-top: 2px solid var(--slate); font-weight: 700; font-variant-numeric: tabular-nums; }
.bars-total span:last-child { color: var(--ice-deep); }

/* Session steps: a real sequence, so it is numbered */
.steps-section { background: var(--surface); }
.steps { margin-top: 3.5rem; display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.5rem, 4vw, 3rem); }
.step figure { margin: 0; }
.phone { border-radius: 2.25rem; overflow: hidden; border: 6px solid var(--slate); background: var(--slate); box-shadow: 0 30px 60px -30px rgba(34,43,54,0.45); }
.step figcaption { margin-top: 1.5rem; }
.step h3 { font-size: var(--step-1); font-weight: 700; display: flex; gap: 0.6rem; align-items: baseline; }
.step h3 b { color: var(--ice-deep); font-variant-numeric: tabular-nums; }
.step p { margin-top: 0.5rem; color: var(--muted); max-width: 22rem; }

/* Two-column prose blocks */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 6vw, 5rem); }
.split h2 { font-size: var(--step-2); }
.split p + p { margin-top: 1rem; }
.split .body { color: var(--muted); }
.plain-list { list-style: none; margin: 1.25rem 0 0; padding: 0; }
.plain-list li { padding: 0.75rem 0; border-top: 1px solid var(--line); }
.plain-list li:last-child { border-bottom: 1px solid var(--line); }
.plan-note { margin-top: 1.25rem; font-size: var(--step--1); color: var(--muted); }

/* Closing */
.closing { background: var(--slate); color: var(--on-slate); text-align: center; }
.closing h2 { margin: 0 auto; color: #fff; font-size: var(--step-4); letter-spacing: -0.035em; max-width: 14ch; }
.closing p { margin: 1.25rem auto 0; color: var(--on-slate-muted); max-width: 26rem; }
.closing .btn { margin-top: 2rem; }

/* Footer */
.site-footer { background: var(--slate); color: var(--on-slate-muted); font-size: var(--step--1); border-top: 1px solid rgba(233,238,242,0.1); }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 1rem 2rem; justify-content: space-between; padding-top: 2rem; padding-bottom: 2rem; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 1.5rem; }
.site-footer a { color: var(--on-slate); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }

/* Document pages (privacy, support) */
.doc-header { background: var(--slate); color: var(--on-slate); padding: 7.5rem 0 3.5rem; }
.doc-header h1 { font-size: var(--step-3); color: #fff; font-weight: 800; }
.doc-header p { margin-top: 0.75rem; color: var(--on-slate-muted); }
.doc { padding: 3.5rem 0 6rem; }
.doc .wrap, .doc-header .wrap { max-width: calc(40rem + 2 * var(--gutter)); }
.doc h2 { font-size: var(--step-1); font-weight: 700; margin: 2.75rem 0 0.6rem; }
.doc h2:first-child { margin-top: 0; }
.doc p, .doc li { color: #3A4452; }
.doc p + p { margin-top: 0.9rem; }
.doc ul { padding-left: 1.2rem; margin: 0.6rem 0 0; }
.doc li { margin: 0.35rem 0; }
.doc .summary { padding: 1.5rem; border-radius: var(--radius); background: var(--surface); color: var(--slate); font-size: var(--step-1); line-height: 1.5; }

@media (max-width: 860px) {
  .hero { padding: 6.5rem 0 4.5rem; }
  .hero .wrap, .week, .split { grid-template-columns: 1fr; }
  .timer { margin-top: 1rem; }
  .steps { grid-template-columns: 1fr; max-width: 22rem; margin-left: auto; margin-right: auto; }
  .site-header nav a:not(:last-child) { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .ring .fill { transition: none; }
  .breathing .ring::before { animation: none; }
}
