@font-face {
  font-family: "Geist";
  src: url("fonts/geist.woff2") format("woff2");
  font-weight: 400 600;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Geist";
  src: url("fonts/geist-ext.woff2") format("woff2");
  font-weight: 400 600;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* The sea at dusk from the app icon: sky above the horizon, a deeper sea below. */
:root {
  color-scheme: dark;
  --sky: #0b1122;
  --sea: #070b17;
  --raised: #111a30;
  --text: #e9ecf3;
  --text-2: #9ea6ba;
  --text-3: #7c859b;
  --line: rgb(233 236 243 / 0.08);
  --line-strong: rgb(233 236 243 / 0.14);
  --accent: #f5b04a;
  --on-accent: #1b1306;
  --day: rgb(245 176 74 / 0.32);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 88px; }
body {
  margin: 0;
  background: var(--sea);
  color: var(--text);
  font: 400 16px/1.6 "Geist", system-ui, sans-serif;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}
p { margin: 0; }
a { color: inherit; }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}
.defs { position: absolute; width: 0; height: 0; }
.skip {
  position: absolute; left: 16px; top: -48px; z-index: 10;
  padding: 8px 12px; border-radius: 8px; background: var(--accent); color: var(--on-accent);
}
.skip:focus { top: 12px; }
.wrap { max-width: 1152px; margin: 0 auto; padding: 0 32px; }
.narrow { max-width: 800px; }

/* Navigation: a compact bar floating off the top edge, the page faintly visible through it */
.nav { position: sticky; top: 12px; z-index: 5; height: 0; }
.nav-row {
  display: flex; align-items: center; gap: 32px; height: 52px;
  width: min(100% - 32px, 760px); margin: 0 auto; padding: 0 8px 0 16px;
  border: 1px solid var(--line); border-radius: 14px;
  background: rgb(11 17 34 / 0.72);
  -webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%);
  transition: background-color 300ms var(--ease), border-color 300ms var(--ease);
}
.nav.scrolled .nav-row { background: rgb(11 17 34 / 0.84); border-color: var(--line-strong); }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 16px; text-decoration: none; }
.brand img { border-radius: 6px; }
.nav-links { display: flex; gap: 24px; font-size: 14px; }
.nav-links a { color: var(--text-2); text-decoration: none; transition: color 150ms var(--ease); }
.nav-links a:hover { color: var(--text); }
.nav-row .button { margin-left: auto; }
.nav-row .brand { margin-right: 8px; }

.button {
  display: inline-flex; align-items: center; justify-content: center;
  height: 44px; padding: 0 20px; border-radius: 10px;
  background: var(--accent); color: var(--on-accent);
  font-weight: 500; font-size: 15px; white-space: nowrap; text-decoration: none;
  transition: background-color 150ms var(--ease), transform 120ms var(--ease);
}
.button:hover { background: #f8bd62; }
.button:active { transform: scale(0.98); }
.button.small { height: 32px; padding: 0 14px; font-size: 14px; border-radius: 8px; }
.quiet-link {
  color: var(--text-2); text-decoration: underline;
  text-decoration-color: var(--line-strong); text-underline-offset: 4px;
  transition: color 150ms var(--ease), text-decoration-color 150ms var(--ease);
}
.quiet-link:hover { color: var(--text); text-decoration-color: currentColor; }

/* Hero */
.sky { background: var(--sky); }
.hero {
  display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: 48px; align-items: end;
  padding-top: 160px; padding-bottom: 64px;
}
.facts { margin-top: 20px; font-size: 14px; color: var(--text-3); }
h1 {
  font-weight: 500; font-size: 68px; line-height: 1.02; letter-spacing: -0.035em;
  margin: 0; text-wrap: balance;
}
.lede { font-size: 17px; line-height: 27px; color: var(--text-2); margin-bottom: 28px; max-width: 30rem; }
.actions { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }

.stage {
  display: grid; grid-template-columns: 1fr 360px 1fr; align-items: end;
  gap: 32px; margin-bottom: -152px; position: relative; z-index: 1;
}
.stage .side { width: 288px; }
.stage .side:first-child { justify-self: end; }
.horizon { height: 1px; background: var(--line-strong); }

/* The card: a SunZones card as the app draws it */
.card {
  position: relative; overflow: hidden; width: 100%;
  aspect-ratio: 360 / 480; border-radius: 28px; color: #fff;
  box-shadow: 0 32px 64px rgb(2 4 10 / 0.5), 0 0 0 1px rgb(255 255 255 / 0.06) inset;
}
.card-bg { position: absolute; inset: 0; transition: opacity 500ms var(--ease); }
.card-bg.b { opacity: 0; }
/* The app's scrim and TextShadowDefault keep white text legible on the light morning sky. */
.card-scrim { position: absolute; inset: 0; background: rgb(0 0 0 / 0.14); }
.card-body {
  position: relative; height: 100%;
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 32px 24px 28px; text-shadow: 0 1px 6px rgb(0 0 0 / 0.45);
}
.card-city { font-size: 28px; font-weight: 600; line-height: 1.1; }
.card-local, .card-label, .card-next, .card-times span { font-size: 13px; color: rgb(255 255 255 / 0.88); }
.card-local { margin-top: 6px; }
.arc { width: 100%; margin-top: 20px; overflow: visible; }
.card-length { font-size: 42px; font-weight: 600; line-height: 1; margin-top: 16px; }
.card-label { margin-top: 4px; }
.card-times { display: grid; grid-template-columns: 1fr 1fr; width: 100%; margin-top: auto; }
.card-times strong { display: block; font-size: 24px; font-weight: 600; line-height: 1.15; }
.card-next { margin-top: 16px; }
.side .card-body { padding: 24px 20px 22px; }
.side .card-city { font-size: 24px; }
.side .card-length { font-size: 34px; }
.side .card-times strong { font-size: 20px; }

/* Below the horizon */
main { padding-top: 152px; }
.section-head { margin-bottom: 40px; }
h2 {
  font-weight: 500; font-size: 40px; line-height: 1.1; letter-spacing: -0.03em;
  margin: 0 0 12px; text-wrap: balance;
}
.note { color: var(--text-2); max-width: 36rem; }
.note.after { margin-top: 24px; }
.block { padding-top: 128px; }
h3 { font-size: 18px; font-weight: 500; margin: 0; }

/* A day, scroll-driven */
.day { padding-top: 96px; }
.day-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 96px; }
.day-steps { padding-bottom: 30vh; }
.step {
  min-height: 52vh; padding: 24px 0 0 20px; margin-left: 1px;
  border-left: 1px solid var(--line);
  transition: border-color 250ms var(--ease);
}
.step p:not(.step-time) { color: var(--text-3); max-width: 28rem; margin-top: 8px; transition: color 250ms var(--ease); }
.step h3 { font-size: 24px; letter-spacing: -0.015em; color: var(--text-2); transition: color 250ms var(--ease); }
.step-time { font-size: 14px; color: var(--text-3); margin-bottom: 4px; }
.step.active { border-left-color: var(--accent); }
.step.active h3 { color: var(--text); }
.step.active p:not(.step-time) { color: var(--text-2); }
.step.active .step-time { color: var(--accent); }
.tag {
  display: inline-block; vertical-align: 3px; margin-left: 6px;
  padding: 0 6px; border: 1px solid var(--line-strong); border-radius: 5px;
  font-size: 12px; font-weight: 500; line-height: 18px; color: var(--text-2); letter-spacing: 0;
}
.day-card-col { position: relative; }
.day-card-col .card { position: sticky; top: calc(50vh - 240px + 30px); }

/* Almanac */
.almanac { width: 100%; border-collapse: collapse; font-size: 15px; }
.almanac th {
  text-align: left; font-weight: 400; font-size: 13px; color: var(--text-3);
  padding: 0 16px 12px 0; border-bottom: 1px solid var(--line);
}
.almanac td { padding: 16px 16px 16px 0; border-bottom: 1px solid var(--line); vertical-align: middle; white-space: nowrap; }
.almanac td.city { font-weight: 500; }
.almanac td.city small { display: block; font-weight: 400; font-size: 13px; color: var(--text-3); }
.almanac th.bar-h, .almanac td.bar { width: 34%; padding-right: 0; }
.day-bar { position: relative; height: 16px; }
.day-bar .track { position: absolute; left: 0; right: 0; top: 7px; height: 1px; background: var(--line-strong); }
.day-bar .lit { position: absolute; top: 5px; height: 5px; border-radius: 3px; background: var(--day); }
.day-bar .now {
  position: absolute; top: 3px; width: 9px; height: 9px; margin-left: -4px;
  border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px var(--sea);
}

/* Yearly chart */
.year { margin: 0 0 64px; padding: 24px 24px 20px; background: var(--raised); border: 1px solid var(--line); border-radius: 16px; }
.year svg { display: block; width: 100%; height: auto; overflow: visible; }
.year figcaption { color: var(--text-3); font-size: 13px; margin-top: 12px; }
.year .grid { stroke: var(--line); stroke-width: 1; }
.year .axis { fill: var(--text-3); font: 400 12px "Geist", system-ui, sans-serif; }
.year .band { fill: var(--day); }
.year .edge { fill: none; stroke: var(--accent); stroke-width: 1.5; stroke-opacity: 0.8; }
.year .today { stroke: var(--text-2); stroke-width: 1; stroke-dasharray: 2 3; }
.year .today-dot { fill: var(--accent); stroke: var(--raised); stroke-width: 2; }
.year .today-label { fill: var(--text-2); font: 500 12px "Geist", system-ui, sans-serif; }

.columns { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; }
.columns .meta { color: var(--text-3); font-size: 14px; margin: 2px 0 16px; }
ul.plain { list-style: none; margin: 0; padding: 0; }
ul.plain li { padding: 12px 0; border-top: 1px solid var(--line); }
ul.plain li span { display: block; margin-top: 2px; font-size: 14px; color: var(--text-2); }

/* FAQ */
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 18px 32px 18px 0; position: relative;
  font-weight: 500; transition: color 150ms var(--ease);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 4px; top: 50%; width: 8px; height: 8px; margin-top: -6px;
  border-right: 1.5px solid var(--text-3); border-bottom: 1.5px solid var(--text-3);
  transform: rotate(45deg); transition: transform 200ms var(--ease);
}
.faq details[open] summary::after { transform: translate(0, 4px) rotate(225deg); }
.faq summary:hover { color: var(--text); }
.faq details p { color: var(--text-2); padding: 0 32px 20px 0; max-width: 40rem; }

/* Tagline: each word lights up as it crosses the reading line */
.tagline { padding: 160px 0 32px; }
.reveal {
  max-width: 920px; margin: 0;
  font-size: 48px; line-height: 1.12; font-weight: 500; letter-spacing: -0.03em; text-wrap: balance;
}
.reveal .w { color: rgb(233 236 243 / 0.42); transition: color 500ms var(--ease); }
.reveal .w.on { color: var(--text); }

/* How it works: a real sequence, so the steps are numbered */
.how { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; counter-reset: how; }
.how li { counter-increment: how; padding-top: 20px; border-top: 1px solid var(--line-strong); }
.how li::before { content: counter(how); display: block; font-size: 14px; color: var(--accent); margin-bottom: 12px; }
.how p { color: var(--text-2); margin-top: 8px; }

.closing { padding: 128px 0 112px; }
.closing-row { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding-top: 48px; border-top: 1px solid var(--line); }
.closing p { font-size: 28px; font-weight: 500; letter-spacing: -0.02em; }

.footer { border-top: 1px solid var(--line); padding: 32px 0 48px; color: var(--text-3); font-size: 13px; }
.footer-row { display: flex; flex-wrap: wrap; gap: 8px 32px; justify-content: space-between; }

@media (max-width: 1080px) {
  .stage { grid-template-columns: 1fr 340px 1fr; gap: 24px; }
  .stage .side { width: 240px; }
  .day-grid { gap: 56px; grid-template-columns: minmax(0, 1fr) 320px; }
  .day-card-col .card { top: calc(50vh - 213px + 30px); }
}
@media (max-width: 860px) {
  .wrap { padding: 0 20px; }
  .hero { grid-template-columns: 1fr; gap: 24px; padding-top: 104px; padding-bottom: 48px; }
  h1 { font-size: 46px; letter-spacing: -0.03em; }
  .stage { grid-template-columns: 1fr; justify-items: center; margin-bottom: -136px; }
  .stage .side { display: none; }
  .stage .main { width: min(100%, 320px); }
  main { padding-top: 136px; }
  .day-grid { grid-template-columns: 1fr; gap: 0; }
  /* On a phone the card rides on top and the steps scroll under it */
  .day-card-col { order: -1; position: sticky; top: 76px; z-index: 2; height: 0; }
  .day-card-col .card { position: relative; top: 0; width: 168px; margin-left: auto; aspect-ratio: 360 / 340; border-radius: 20px; }
  .day-card-col .card-body { padding: 14px 12px; }
  .day-card-col .card-city { font-size: 15px; }
  .day-card-col .card-local { font-size: 11px; margin-top: 2px; }
  .day-card-col .arc { margin-top: 6px; }
  .day-card-col .card-length { font-size: 20px; margin-top: 6px; }
  .day-card-col .card-label, .day-card-col .card-times, .day-card-col .card-next { display: none; }
  .day-steps { padding-right: 184px; padding-bottom: 20vh; }
  .step { min-height: 44vh; }
  .block { padding-top: 96px; }
  h2 { font-size: 32px; }
  .columns { grid-template-columns: 1fr; gap: 48px; }
  .reveal { font-size: 32px; }
  .tagline { padding-top: 112px; }
  .how { grid-template-columns: 1fr; gap: 24px; }
  .hide-sm { display: none; }
  .nav-links { gap: 16px; }
  .almanac th.bar-h, .almanac td.bar { width: 38%; }
  .year { padding: 16px 12px 14px; }
}
@media (max-width: 520px) {
  .wrap { padding: 0 16px; }
  h1 { font-size: 40px; }
  .nav-links { display: none; }
  .day-steps { padding-right: 148px; }
  .day-card-col .card { width: 132px; }
  .closing p { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* 404: the sun below the horizon */
.lost { min-height: 100vh; padding: 25vh 0 0; position: relative; background: var(--sky); }
.lost h1 { font-size: 56px; margin: 8px 0 16px; }
.lost-code { color: var(--accent); font-size: 14px; }
.lost-actions { margin-top: 32px; }
.lost-horizon { position: absolute; left: 0; right: 0; bottom: 30vh; }
.lost-sun {
  position: absolute; left: 62%; top: 1px; width: 48px; height: 24px; margin-left: -24px;
  border-radius: 0 0 24px 24px; background: var(--accent); opacity: 0.5;
}
@media (max-width: 860px) { .lost h1 { font-size: 36px; } }
