/* calendar-md: "almanac at night". Night-blue ink, moon gold, cool paper,
   a serif for display and a grotesk for text. Keep the focus ring, the skip
   link and the 3-width check. */
:root {
  --night: #101a2e;
  --night-2: #182540;
  --gold: #e8c15a;
  --paper: #f1f1ec;
  --card: #fbfbf8;
  --ink: #141c2c;
  --muted: #5a6273;
  --line: #d3d5d0;
  --accent: #2b4fae;
  --display: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  --text: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --wrap: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 17px/1.6 var(--text); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-underline-offset: .18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 2px; box-shadow: 0 0 0 6px var(--night); }
h1, h2, h3 { margin: 0; text-wrap: balance; }
h2 { font: 400 clamp(36px, 5vw, 60px)/1.02 var(--display); letter-spacing: -.01em; display: flex; align-items: baseline; gap: 18px; flex-wrap: wrap; }
h3 { font-size: 18px; font-weight: 600; line-height: 1.25; }
p { margin: 0; }
code, pre { font-family: var(--mono); font-size: .86em; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; left: 12px; top: -48px; background: var(--gold); color: var(--night); padding: 8px 14px; z-index: 10; font-weight: 600; }
.skip:focus { top: 12px; }
.num { font: 600 14px/1 var(--mono); color: var(--accent); letter-spacing: .08em; border: 1.5px solid currentColor; border-radius: 999px; padding: 6px 10px; transform: translateY(-8px); }

/* top bar */
.top { background: var(--night); color: var(--paper); }
.top-row { display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; min-height: 68px; flex-wrap: wrap; padding-block: 10px; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; font: 600 16px/1 var(--mono); color: var(--paper); text-decoration: none; }
.nav { display: flex; gap: 6px 22px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
.nav a { color: #c9cfdb; text-decoration: none; font-size: 15px; }
.nav a:hover { color: var(--gold); }

/* hero */
.hero { background: radial-gradient(1200px 500px at 80% 10%, #1d2c4d 0, transparent 60%), var(--night); color: var(--paper); padding: 64px 0 40px; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 48px; align-items: center; }
.eyebrow { font: 600 13px/1.4 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--gold); }
.hero h1 { font: 400 clamp(42px, 5.6vw, 76px)/1 var(--display); letter-spacing: -.015em; margin-top: 18px; }
.hero h1 em { color: var(--gold); }
.lede { font-size: 19px; color: #c9cfdb; margin-top: 22px; max-width: 34em; }
.cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 30px; }
.btn { display: inline-block; padding: 13px 20px; border-radius: 999px; background: var(--gold); color: var(--night); font-weight: 700; text-decoration: none; border: 2px solid var(--gold); }
.btn:hover { background: #f3d27c; }
.btn-quiet { background: transparent; color: var(--paper); border-color: #3a4a6c; }
.btn-quiet:hover { background: var(--night-2); border-color: var(--gold); }
.one-liner { margin-top: 22px; }
.one-liner code { display: inline-block; background: var(--night-2); color: var(--paper); padding: 9px 14px; border-radius: 8px; border: 1px solid #2c3b5c; }
.hero-art { position: relative; height: 520px; }
.sheet { position: absolute; display: block; box-shadow: 0 2px 4px rgba(0,0,0,.25), 0 30px 60px rgba(0,0,0,.45); transition: transform .25s ease; }
.sheet:hover { transform: translateY(-6px) rotate(0deg) !important; z-index: 3; }
.s1 { width: 78%; right: -4%; top: 0; transform: rotate(3deg); }
.s2 { width: 40%; left: 0; top: 90px; transform: rotate(-5deg); z-index: 1; }
.s3 { width: 42%; left: 36%; top: 150px; transform: rotate(2deg); z-index: 2; }
.moon-row { display: flex; align-items: center; gap: 18px; margin-top: 48px; padding-top: 20px; border-top: 1px solid #26355a; color: #8b96ad; font: 12px/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; }
.moon-row img { width: min(620px, 70%); }

/* a week of reasons */
.week { padding: 80px 0 24px; }
.days { list-style: none; margin: 36px 0 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-top: 2px solid var(--ink); }
.days li { padding: 14px 14px 22px; border-inline-end: 1px solid var(--line); min-height: 200px; }
.days li:last-child { border-inline-end: 0; }
.days b { display: block; font: 600 12px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 18px; }
.days li.we b { color: var(--accent); }
.days h3 { font: 400 26px/1.05 var(--display); margin-bottom: 10px; }
.days p { font-size: 15px; color: var(--muted); }

/* how */
#how { padding: 72px 0; }
.how { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 48px; margin-top: 36px; align-items: start; }
.ask { margin: 0; font: italic 400 clamp(26px, 3vw, 36px)/1.2 var(--display); padding: 28px 30px; background: var(--card); border-radius: 18px; border: 1px solid var(--line); position: relative; }
.ask::after { content: ""; position: absolute; left: 40px; bottom: -14px; width: 26px; height: 26px; background: var(--card); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); transform: rotate(45deg); }
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; }
.steps li { display: grid; grid-template-columns: 54px minmax(0, 1fr); gap: 18px; align-items: start; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.steps li:last-child { border-bottom: 0; }
.steps span { width: 54px; height: 54px; border-radius: 50%; background: var(--night); color: var(--gold); display: grid; place-items: center; font: 400 30px/1 var(--display); }
.steps p { color: var(--muted); margin-top: 4px; }

/* themes */
.dark { background: var(--night); color: var(--paper); padding: 80px 0; }
.dark .num { color: var(--gold); }
.intro { color: var(--muted); max-width: 44em; margin-top: 14px; font-size: 18px; }
.dark .intro { color: #b8c0d0; }
.themes { list-style: none; margin: 40px 0 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 22px; }
.themes a { display: block; box-shadow: 0 18px 40px rgba(0,0,0,.4); transition: transform .2s ease; }
.themes a:hover { transform: translateY(-6px); }
.themes h3 { margin-top: 16px; font: 400 26px/1.1 var(--display); }
.themes p { color: #b8c0d0; font-size: 15px; margin-top: 4px; }

/* examples */
#examples { padding: 80px 0; }
.examples { list-style: none; margin: 40px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 28px; }
.examples a { display: flex; align-items: flex-end; justify-content: center; aspect-ratio: 4 / 3.4; background: #e2e3de; border-radius: 14px; padding: 26px 26px 0; overflow: hidden; }
.examples a img { max-height: 100%; width: auto; box-shadow: 0 10px 30px rgba(16,26,46,.22); transition: transform .2s ease; }
.examples a:hover img { transform: translateY(-6px); }
.tag { margin-top: 16px; font: 600 12px/1.4 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.examples h3 { font: 400 28px/1.1 var(--display); margin-top: 6px; }
.examples li > p:last-child { color: var(--muted); margin-top: 6px; font-size: 16px; }

/* install */
.install-sec { padding: 24px 0 88px; }
.install { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; margin-top: 36px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 24px; min-width: 0; }
.card.wide { grid-column: 1 / -1; }
.card > p { color: var(--muted); margin-top: 4px; }
pre { background: var(--night); color: #e7e9ef; padding: 16px 18px; border-radius: 10px; overflow-x: auto; margin: 16px 0 0; line-height: 1.6; }
pre .c { color: #8b96ad; }

/* footer */
.foot { background: var(--night); color: #b8c0d0; padding: 40px 0; font-size: 15px; }
.foot-row { display: flex; flex-wrap: wrap; gap: 10px 32px; align-items: baseline; justify-content: space-between; }
.foot a { color: var(--paper); }
.foot a:hover { color: var(--gold); }
.mark { font: 600 15px/1 var(--mono); text-decoration: none; }

/* 404 */
.lost { padding: 120px 0; background: var(--night); color: var(--paper); min-height: 60vh; }
.lost h1 { font: 400 clamp(44px, 7vw, 84px)/1 var(--display); margin-top: 16px; }

@media (max-width: 1020px) {
  .hero-grid, .how { grid-template-columns: minmax(0, 1fr); }
  .hero-art { height: 460px; max-width: 640px; }
  .days { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .days li { border-bottom: 1px solid var(--line); min-height: 0; }
  .days li:nth-child(4) { border-inline-end: 0; }
  .themes { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .examples { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .hero { padding-top: 40px; }
  .hero-art { height: 340px; }
  .days { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .days li:nth-child(4) { border-inline-end: 1px solid var(--line); }
  .days li:nth-child(2n) { border-inline-end: 0; }
  .themes { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
  .examples, .install { grid-template-columns: minmax(0, 1fr); }
  .moon-row { flex-direction: column; align-items: flex-start; }
  .moon-row img { width: 100%; }
  .nav { gap: 4px 16px; }
}
