/* base.css — reset, the phone column, shared type, buttons, marquee.
 *
 * The invitation is one phone-width column. On desktop it stays phone-width and centred
 * over a tiny pre-blurred crop of the hero still (scaled up; no CSS filter).
 */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

html {
  background: var(--night);
  color: var(--cream);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

html.is-gated,
html.is-gated body {
  overflow: hidden;
  height: 100%;
}

body {
  font-family: var(--font-display);
  font-size: 17px;
  line-height: 1.5;
  background: var(--night);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

button,
input,
output {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

:focus-visible {
  outline: 3px solid var(--lime);
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.mono {
  font-family: var(--font-mono);
}

.serif {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
}

/* ---- desktop backdrop --------------------------------------------------- */
.backdrop {
  display: none;
}

@media (min-width: 560px) {
  .backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background:
      radial-gradient(ellipse at 50% 45%, rgba(20, 10, 18, 0.2), rgba(20, 10, 18, 0.9) 70%),
      url("../assets/img/backdrop.jpg") center / cover no-repeat;
  }
}

/* ---- the column ------------------------------------------------------------ */
.invite {
  position: relative;
  width: var(--col);
  margin: 0 auto;
  background: url("../assets/img/grain.png") repeat, var(--night);
  overflow-x: clip;
  box-shadow: 0 0 90px rgba(0, 0, 0, 0.6);
}

/* contain: paint keeps each section's layers inside its own box (no overlap
   promotion chains across the long scroll) */
.section {
  position: relative;
  padding: 84px var(--pad) 76px;
  text-align: center;
  contain: paint;
}

.section > * {
  position: relative;
}

/* ---- type ----------------------------------------------------------------- */
.eyebrow {
  margin: 0 0 10px;
  font: 700 12px/1.4 var(--font-mono);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--lime);
}

.eyebrow--ink {
  color: var(--rani-deep);
}

.section-title {
  margin: 0 0 12px;
  font-weight: 800;
  font-size: clamp(34px, 10vw, 44px);
  line-height: 0.98;
  letter-spacing: -0.035em;
  font-variation-settings: "wdth" 80, "opsz" 96;
}

.hint {
  margin: 16px 0 0;
  font-size: 12px;
  letter-spacing: 0.04em;
  color: rgba(255, 244, 230, 0.6);
}

.pill {
  display: inline-block;
  margin: 0;
  padding: 7px 14px 6px;
  border: 1.5px solid currentColor;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* ---- buttons -------------------------------------------------------------- */
.cta {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 56px;
  margin: 12px 0 0;
  padding: 14px 20px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: -0.01em;
  text-decoration: none;
  box-shadow: var(--shadow-hard);
  transition: transform var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}

.cta:active {
  transform: translate(4px, 4px);
  box-shadow: 1px 1px 0 var(--ink);
}

.cta--lime {
  background: var(--lime);
  color: var(--ink);
}

.cta--ink {
  background: var(--ink);
  color: var(--cream);
  border-color: var(--ink);
  box-shadow: 5px 5px 0 var(--rani);
}

.cta--ghost {
  background: transparent;
  color: var(--cream);
  border-color: var(--cream);
  box-shadow: 5px 5px 0 var(--rani);
}

.link {
  margin: 18px auto 0;
  padding: 8px 4px;
  border: 0;
  background: none;
  font: 400 13px/1.4 var(--font-mono);
  color: rgba(255, 244, 230, 0.7);
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ---- marquee strip ------------------------------------------------------------ */
.marquee {
  position: relative;
  overflow: hidden;
  padding: 10px 0 9px;
  font: 800 19px/1 var(--font-display);
  letter-spacing: -0.01em;
  text-transform: uppercase;
  white-space: nowrap;
  font-variation-settings: "wdth" 78;
}

.marquee--lime {
  background: var(--lime);
  color: var(--ink);
}

.marquee--rani {
  background: var(--rani);
  color: var(--cream);
}

.marquee__track {
  display: inline-flex;
  animation: marquee 22s linear infinite;
}

.marquee__track span {
  padding: 0 14px;
}

.marquee__track span::after {
  content: "✺";
  padding-left: 28px;
}

@keyframes marquee {
  to {
    transform: translateX(-50%);
  }
}

/* ---- tap sparkles (shared layer) --------------------------------------------- */
.tap-fx {
  position: fixed;
  inset: 0;
  z-index: 80;
  pointer-events: none;
  overflow: hidden;
}

.sparkle {
  position: absolute;
  left: 0;
  top: 0;
  width: 16px;
  height: 16px;
  margin: -8px 0 0 -8px;
  background: var(--c, var(--lime));
  clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%);
}

.confetti {
  position: absolute;
  left: 0;
  top: 0;
  font-size: var(--s, 26px);
  line-height: 1;
}

/* ---- sound toggle -------------------------------------------------------------- */
.sound {
  position: fixed;
  z-index: 90;
  top: max(14px, env(safe-area-inset-top));
  right: max(14px, calc((100vw - var(--col)) / 2 + 14px));
  width: 44px;
  height: 44px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 3px 3px 0 var(--ink);
  display: grid;
  place-items: center;
}

.sound__bars {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 16px;
}

.sound__bars i {
  width: 3px;
  height: 100%;
  background: var(--ink);
  border-radius: 2px;
  transform-origin: bottom;
  animation: eq 0.9s ease-in-out infinite alternate;
}

.sound__bars i:nth-child(2) {
  animation-delay: -0.3s;
}

.sound__bars i:nth-child(3) {
  animation-delay: -0.6s;
}

.sound[aria-pressed="false"] .sound__bars i {
  animation: none;
  transform: scaleY(0.25);
}

@keyframes eq {
  from {
    transform: scaleY(0.3);
  }
  to {
    transform: scaleY(1);
  }
}
