/* =========================================================
   NX DESIGN TOKENS — shared by the guest site and admin panel
   Palette taken from the couple's passport invitation:
   aged paper, sepia ink, champagne gold, dark leather.
========================================================= */
:root {
  /* paper & ink */
  --paper: #f3eee2;
  --paper-2: #e9e2d0;
  --paper-3: #ddd3bb;
  --paper-edge: #cdc4ad;
  --ink: #3d3324;
  --ink-soft: #64573f;
  --ink-faint: #8a7d63;
  --line: rgba(61, 51, 36, .22);
  --line-strong: rgba(61, 51, 36, .4);

  /* gold */
  --gold: #a87d2f;
  --gold-2: #d8b25e;
  --gold-3: #f1d898;
  --gold-ink: #7d5a1c;

  /* leather / night */
  --night: #21180e;
  --night-2: #2e2214;
  --night-3: #3d2e1b;
  --on-night: #f3ead6;
  --on-night-soft: #cbbd9e;

  /* status */
  --ok: #2f6b4a;
  --ok-bg: #e4efe6;
  --danger: #9b2c2c;
  --danger-bg: #f6e3df;
  --stamp-red: #a8332a;
  --stamp-blue: #2c4f7c;
  --stamp-green: #3b6b48;

  /* type */
  --font-serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --font-title: 'Cinzel', 'Trajan Pro', Georgia, serif;
  --font-script: 'Pinyon Script', 'Brush Script MT', cursive;
  --font-mono: 'JetBrains Mono', 'Courier New', monospace;

  /* spacing scale: 4 8 12 16 24 32 48 64 96 */
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px; --s8: 64px; --s9: 96px;

  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow-sm: 0 2px 8px -2px rgba(33, 24, 14, .18);
  --shadow: 0 18px 40px -16px rgba(33, 24, 14, .45);
  --shadow-lg: 0 30px 70px -20px rgba(20, 14, 6, .65);

  --ease-out: cubic-bezier(.22, 1, .36, 1);
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);

  --gold-foil: linear-gradient(100deg, #8a6424 0%, #e8c877 22%, #b58a39 40%, #f6e2a6 55%, #a87d2f 72%, #e2bf6c 88%, #8a6424 100%);
  --paper-texture:
    radial-gradient(ellipse at 20% 10%, rgba(255, 255, 255, .55), transparent 60%),
    radial-gradient(ellipse at 90% 90%, rgba(170, 140, 90, .14), transparent 55%);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 1.125rem;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }
[hidden] { display: none !important; }

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

/* ---------- buttons ---------- */
.btn {
  --btn-bg: transparent; --btn-fg: var(--ink); --btn-bd: var(--line-strong);
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s2);
  min-height: 44px; padding: 10px 22px;
  font-family: var(--font-title); font-size: .82rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  text-decoration: none; color: var(--btn-fg); background: var(--btn-bg);
  border: 1px solid var(--btn-bd); border-radius: 999px; cursor: pointer;
  transition: transform .25s var(--ease-spring), box-shadow .25s var(--ease-out), background-color .2s, color .2s, border-color .2s;
  -webkit-tap-highlight-color: transparent;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.btn:active { transform: translateY(0) scale(.97); }
.btn:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--paper), 0 0 0 5px var(--gold); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }
.btn-primary {
  --btn-fg: #fffaf0; --btn-bd: transparent;
  background: linear-gradient(180deg, #b88d3f, #8c6425);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3), 0 6px 16px -6px rgba(140, 100, 37, .7);
}
.btn-primary:hover { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3), 0 12px 24px -8px rgba(140, 100, 37, .8); }
.btn-ghost:hover { --btn-bd: var(--gold); --btn-fg: var(--gold-ink); }
.btn-small { min-height: 38px; padding: 8px 16px; font-size: .72rem; }
.btn-block { width: 100%; }
.btn-danger { --btn-fg: #fff; --btn-bd: transparent; --btn-bg: var(--danger); }

.btn .btn-spin {
  width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid currentColor; border-right-color: transparent;
  animation: nx-spin .8s linear infinite;
}
@keyframes nx-spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important; scroll-behavior: auto !important;
  }
}
