:root {
  --night: #171108;
  --cream: #f2e9d1;
  --gold: #c2a35c;
  --glow: #ffd98a;
  --line: rgba(194, 163, 92, 0.35);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
html.closed { overflow: hidden; }
body {
  background: var(--night);
  color: var(--cream);
  font-family: "Iowan Old Style", Charter, Georgia, "Times New Roman", serif;
  line-height: 1.6;
  min-height: 100svh;
  text-align: center;
}
/* The light is fixed to the room; it does not scroll and has no visible end. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 62% 72% at 50% -12%, rgba(255, 217, 138, 0.24), transparent 62%),
    radial-gradient(ellipse 50% 26% at 50% 106%, rgba(255, 217, 138, 0.08), transparent 70%);
}
main { position: relative; z-index: 1; }

/* The green dot. Top left. Behind the curtain, next to the gathered leg. */
.dot {
  position: fixed;
  top: max(1.2rem, env(safe-area-inset-top));
  left: calc(clamp(44px, 6vw, 90px) + 1rem);
  width: 48px;
  height: 48px;
  z-index: 10;
}

/* Stage */
.stage {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 3rem 1.5rem;
}
.kicker {
  font-size: 0.8rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
}
h1 {
  margin-top: 2.8rem;
  max-width: 21ch;
  font-size: clamp(2.1rem, 5.4vw, 3.4rem);
  font-weight: 400;
  line-height: 1.22;
  text-wrap: balance;
  text-shadow: 0 0 60px rgba(255, 217, 138, 0.25);
}
.motto {
  margin-top: 1.8rem;
  font-style: italic;
  font-size: clamp(1.1rem, 2.6vw, 1.3rem);
  color: var(--gold);
}

/* House */
.house {
  max-width: 34rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}
.rule {
  width: 3.5rem;
  height: 1px;
  background: var(--line);
  margin: clamp(4rem, 10vh, 6rem) auto;
}
h2 {
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
  text-align: left;
  margin-bottom: 2.2rem;
}

/* News: timeline with colored markers */
.news { text-align: left; }
.news ol { list-style: none; position: relative; }
.news ol::before {
  content: "";
  position: absolute;
  left: 0.6rem;
  top: 0.5rem;
  bottom: 0.5rem;
  width: 1px;
  background: var(--line);
}
.news li { position: relative; padding: 0 0 2.6rem 2.5rem; }
.news li:last-child { padding-bottom: 0.3rem; }
.marker {
  position: absolute;
  left: 0;
  top: 0.25rem;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--night);
}
.news li[data-color] .marker { border-color: rgba(0, 0, 0, 0.35); }
.news .dot-marker { border: 0; background: none; }
.news em.date {
  display: block;
  font-style: normal;
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.45rem;
}
.news p { font-size: 1.13rem; line-height: 1.55; }

/* P.S. */
.ps { text-align: left; margin-top: 3.8rem; }
.ps p { font-size: 1.05rem; }

footer {
  padding-bottom: clamp(4rem, 10vh, 6rem);
  font-size: 1.05rem;
  color: var(--gold);
}
.colophon {
  margin: 2.4rem auto 0;
  max-width: 44ch;
  font-size: 0.78rem;
  line-height: 1.7;
  color: rgba(194, 163, 92, 0.6);
}
a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--line);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: color 0.2s;
}
a:hover { color: var(--glow); }
::selection { background: var(--glow); color: var(--night); }

/* Curtain */
#curtain, #open-button, .close-button { display: none; }
html.js #curtain {
  display: block;
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 20;
  pointer-events: none;
}
html.js.closed #open-button {
  display: block;
  position: fixed;
  inset: 0;
  z-index: 25;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
#open-button:focus-visible { outline: 3px solid var(--glow); outline-offset: -6px; }
/* The gathered curtain legs close the curtain again */
html.js:not(.closed):not(.static) .close-button {
  display: block;
  position: fixed;
  top: 0;
  height: 100%;
  width: clamp(44px, 6vw, 90px);
  z-index: 22;
  border: 0;
  background: transparent;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.close-button.left { left: 0; }
.close-button.right { right: 0; }
.close-button:focus-visible { outline: 2px solid var(--glow); outline-offset: -4px; }

/* Scroll hint */
#hint {
  position: fixed;
  left: 50%;
  bottom: 1.6rem;
  z-index: 15;
  width: 10px;
  height: 10px;
  border-right: 1px solid var(--gold);
  border-bottom: 1px solid var(--gold);
  transform: translateX(-50%) rotate(45deg);
  opacity: 0;
  transition: opacity 1.2s;
}
#hint.shown { opacity: 0.7; animation: nod 2.6s ease-in-out infinite; }
@keyframes nod {
  0%, 100% { transform: translateX(-50%) translateY(0) rotate(45deg); }
  50% { transform: translateX(-50%) translateY(6px) rotate(45deg); }
}
@media (prefers-reduced-motion: reduce) {
  #hint.shown { animation: none; }
  html { scroll-behavior: auto; }
}
