:root {
  --paper: #e9dfcc;
  --paper-dim: #c9bda6;
  --lamp: #ffc27a;
  --lamp-core: #fff1d6;
  --moon: #b9c6d6;
  --wood: #3a2a1d;
  --ink: #2a2017;
  --ink-soft: rgba(42, 32, 23, 0.68);
  --line: rgba(42, 32, 23, 0.16);
  --cta: #2a2017;
  --cta-ink: #fbf3e4;
  --font: "Mona Sans Variable", "Mona Sans", system-ui, sans-serif;
  --serif: "Fraunces Variable", "Fraunces", Georgia, serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; }

body {
  background: var(--paper-dim);
  color: var(--ink);
  font-family: var(--font);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

.stage {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 300px;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  /* what is left without canvas: paper with a warm glow, in CSS */
  background:
    radial-gradient(circle at 62% 46%, rgba(255, 194, 122, 0.55), transparent 55%),
    var(--paper);
}

.paper {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: -2;
}

.vignette {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(ellipse 80% 75% at 50% 50%, transparent 55%, rgba(40, 28, 16, 0.22) 100%);
}

.hero {
  position: relative;
  width: min(92vw, 640px);
  display: grid;
  justify-items: center;
  text-align: center;
  gap: clamp(10px, 2.2vh, 18px);
  padding: 0 4vw;
}

/* a soft halo of brighter paper behind the words, so the lattice never fights the text */
.hero::before {
  content: "";
  position: absolute;
  inset: -12% -10%;
  z-index: -1;
  background: radial-gradient(ellipse 50% 48% at 50% 50%, rgba(246, 238, 222, 0.78), rgba(246, 238, 222, 0) 72%);
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  inset: -12% -10%;
  z-index: -1;
  background: radial-gradient(ellipse 50% 48% at 50% 50%, rgba(226, 232, 238, 0.7), rgba(226, 232, 238, 0) 72%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 1.1s ease;
}

.hero::before { transition: opacity 1.1s ease; }
.stage.is-off .hero::before { opacity: 0; }
.stage.is-off .hero::after { opacity: 1; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px 6px 9px;
  border-radius: 999px;
  background: rgba(251, 245, 233, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6) inset, 0 6px 18px -10px rgba(58, 42, 29, 0.5);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  font-size: clamp(11px, 1.6vh, 13px);
  white-space: nowrap;
}

.pill__mark { width: 15px; height: 15px; fill: none; stroke: var(--ink); stroke-width: 1.4; stroke-linejoin: round; stroke-linecap: round; }
.pill__tag { font-weight: 650; }
.pill__text { color: var(--ink-soft); }

.title {
  font-family: var(--serif);
  font-weight: 420;
  font-size: clamp(30px, min(8.4vw, 9vh), 84px);
  line-height: 1.02;
  letter-spacing: -0.02em;
  text-wrap: balance;
  text-shadow: 0 0 24px rgba(248, 240, 224, 0.9);
}

.title em { font-style: italic; font-weight: 360; color: #6a4523; }

.lede {
  max-width: 36ch;
  font-size: clamp(13px, min(2vw, 2.2vh), 17px);
  line-height: 1.5;
  color: var(--ink-soft);
  font-stretch: 105%;
}

.actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}

.cta {
  position: relative;
  border: 0;
  cursor: pointer;
  font: inherit;
  color: var(--cta-ink);
  background: var(--cta);
  border-radius: 999px;
  height: clamp(40px, 6vh, 48px);
  padding: 0 22px;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.18) inset,
    0 -1px 0 rgba(0, 0, 0, 0.4) inset,
    0 10px 24px -12px rgba(42, 32, 23, 0.8),
    0 2px 6px -2px rgba(42, 32, 23, 0.4);
  transition: box-shadow 0.4s;
}

.cta:focus-visible { outline: 2px solid var(--wood); outline-offset: 3px; }

.cta__shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 30%, rgba(255, 226, 180, 0.38) 50%, transparent 70%);
  transform: translateX(-120%);
  pointer-events: none;
}

.cta__face { position: relative; display: grid; height: 100%; }

.cta__row {
  grid-area: 1 / 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font-size: clamp(13px, 1.9vh, 15px);
  font-weight: 600;
  white-space: nowrap;
}

.cta__icon { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.cta__row--off { opacity: 0; }

.note { font-size: clamp(12px, 1.7vh, 13px); color: var(--ink-soft); }

.ghost {
  position: absolute;
  left: 0;
  top: 0;
  width: 22px;
  height: 22px;
  fill: #fff;
  stroke: #1d150e;
  stroke-width: 1.2;
  stroke-linejoin: round;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.3));
  opacity: 0;
  pointer-events: none;
  z-index: 5;
}

@media (max-width: 520px) {
  .pill__text { display: none; }
}
