:root {
  color-scheme: dark;
  --background: #19080d;
  --text: #fff7ef;
  --muted: #d8b8b9;
  --accent: #ff8d98;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { min-width: 280px; background: var(--background); }
body { margin: 0; color: var(--text); }

.backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: var(--background);
}
.backdrop img { width: 100%; height: 100%; object-fit: cover; object-position: 70% center; }
.backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(20, 5, 10, .9) 0%, rgba(20, 5, 10, .6) 32%, rgba(20, 5, 10, .08) 63%, transparent 100%);
}
.page {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  padding: clamp(1.5rem, 4vw, 3.5rem) clamp(1.5rem, 6vw, 7rem);
}
.masthead {
  display: flex;
  align-items: center;
  gap: .875rem;
  color: #ead5d3;
  font-size: .875rem;
  font-weight: 500;
  letter-spacing: .16em;
  line-height: 1.5;
  text-transform: uppercase;
}
.masthead-line { width: 1.75rem; height: 1px; background: var(--accent); flex-shrink: 0; }
.content { margin-block: auto; padding-block: 4.5rem 6rem; max-width: 46rem; }
h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(3rem, 5.1vw, 5rem);
  font-weight: 400;
  letter-spacing: -.045em;
  line-height: 1.07;
  text-shadow: 0 2px 24px rgba(20, 5, 10, .25);
}
.year { display: block; font-style: italic; color: #ebc6c5; }
.event-time {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: .8rem;
  row-gap: .25rem;
  margin: 1.5rem 0 0;
  font-size: 1rem;
  line-height: 1.5;
  color: #f0dcdc;
}
.time-divider { color: #b38d92; }
.timezone { color: var(--muted); }
.countdown { margin-top: clamp(2.5rem, 5.5vh, 4rem); }
.countdown-label {
  margin: 0 0 1rem;
  font-size: .875rem;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #e0b8bd;
}
.timer { display: flex; align-items: flex-start; gap: clamp(.45rem, 1.3vw, 1.25rem); }
.unit { display: flex; flex-direction: column; align-items: center; }
.number {
  font-size: clamp(3.2rem, 6.5vw, 6.25rem);
  font-weight: 300;
  font-variant-numeric: tabular-nums lining-nums;
  letter-spacing: -.035em;
  line-height: 1.05;
  min-width: 1.2em;
  text-align: center;
}
.separator {
  font-size: clamp(2.2rem, 4.2vw, 4rem);
  line-height: 1.5;
  font-weight: 200;
  color: #9e696f;
}
.unit-label {
  margin-top: .8rem;
  font-size: .875rem;
  font-weight: 400;
  letter-spacing: .045em;
  line-height: 1.5;
  color: var(--muted);
}
.unit-seconds .number { color: var(--accent); }
.no-script { margin: 1.5rem 0 0; font-size: 1rem; line-height: 1.5; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

@media (max-width: 760px) {
  .backdrop img { height: 78svh; min-height: 420px; object-position: 76% center; }
  .backdrop::after { background: linear-gradient(180deg, rgba(25, 8, 13, .15) 0%, rgba(25, 8, 13, 0) 28%, rgba(25, 8, 13, .35) 43%, rgba(25, 8, 13, .94) 65%, #19080d 82%); }
  .page { padding: 1.5rem; }
  .masthead { font-size: .875rem; letter-spacing: .12em; }
  .content { margin-top: auto; margin-bottom: 0; padding-top: 42svh; padding-bottom: 1.25rem; width: 100%; max-width: 32rem; }
  h1 { font-size: clamp(2.4rem, 7.8vw, 3.6rem); line-height: 1.1; }
  .year { display: inline; }
  .event-time { margin-top: 1rem; column-gap: .65rem; }
  .countdown { margin-top: 2rem; }
  .timer { justify-content: space-between; gap: .4rem; }
  .number { font-size: clamp(2.55rem, 11.5vw, 4.5rem); }
  .separator { font-size: clamp(1.9rem, 7.5vw, 3.1rem); }
  .unit-label { letter-spacing: 0; margin-top: .5rem; }
}

@media (max-width: 350px) {
  .page { padding: 1.25rem; }
  .event-time { column-gap: .5rem; }
  .number { font-size: 2.5rem; }
  .timer { gap: .2rem; }
}

@media (prefers-reduced-motion: no-preference) {
  .content { animation: appear 900ms ease-out both; }
  @keyframes appear { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
}
