/* Crystal Lacon digital card. Client brand is fixed: near-black ground, gold accents, formal script wordmark.
   One theme (dark), one accent (gold), one radius scale (--r), one type pair (Great Vibes + Outfit). */
:root {
  --ground: #102A2B;
  --surface: #16343A;
  --surface-hi: #1E4044;
  --ink: #F5F1E9;          
  --muted: #B7C3C1;        
  --gold: #C9A76A;         
  --gold-ink: #102A2B;     
  --line: rgba(201, 167, 106, .38);
  --line-soft: rgba(201, 167, 106, .22);
  --r: 14px;
  --gap: 12px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --script: 'Great Vibes', 'Snell Roundhand', 'Apple Chancery', cursive;
  --sans: 'Outfit', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--ground); }
body {
  margin: 0; min-height: 100dvh; background: var(--ground); color: var(--ink);
  font: 400 16px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
h1, p { margin: 0; }

.skip {
  position: absolute; left: 12px; top: -80px; z-index: 10;
  background: var(--gold); color: var(--gold-ink); padding: 12px 16px; border-radius: var(--r); font-weight: 500;
}
.skip:focus { top: 12px; }

/* ---- layout: stacked on mobile ---- */
.card { width: 100%; max-width: 560px; margin: 0 auto; padding-bottom: max(32px, env(safe-area-inset-bottom)); }

.photo { position: relative; aspect-ratio: 1 / 1; max-height: 56dvh; width: 100%; overflow: hidden; background: #0C2122; }
.photo picture, .photo img { width: 100%; height: 100%; }
.photo img { object-fit: cover; object-position: 50% 28%; }
/* the photo dissolves into the ground so the wordmark can sit on it */
.photo::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 46%;
  background: linear-gradient(to bottom, rgba(16, 42, 43, 0), var(--ground) 92%);
  pointer-events: none;
}

.details { position: relative; padding: 0 20px; margin-top: -76px; }

.identity { text-align: left; }
.wordmark {
  font: 400 clamp(56px, 18vw, 76px)/1.15 var(--script);
  color: var(--gold); letter-spacing: 0; padding-bottom: 2px;
  text-shadow: 0 2px 18px rgba(16, 42, 43, .7);
}
.role {
  margin-top: 2px; font-weight: 500; font-size: 15px; letter-spacing: .28em; text-transform: uppercase; color: var(--ink);
}
.markets { margin-top: 6px; font-size: 15px; letter-spacing: .06em; color: var(--muted); }

/* ---- actions ---- */
.actions { margin-top: 28px; display: grid; gap: var(--gap); }
.btn {
  display: flex; align-items: center; gap: 14px; min-height: 56px; padding: 10px 18px;
  border-radius: var(--r); border: 1px solid transparent;
  font: 500 16px/1.2 var(--sans); color: var(--ink); background: none; cursor: pointer;
  touch-action: manipulation; -webkit-tap-highlight-color: transparent;
  transition: transform .18s var(--ease), background-color .2s ease, border-color .2s ease, color .2s ease;
}
.btn svg { width: 24px; height: 24px; flex: none; fill: currentColor; }
.btn:active { transform: scale(.98); }
.btn:focus-visible, .skip:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }

.btn-primary { justify-content: center; min-height: 60px; background: var(--gold); color: var(--gold-ink); font-weight: 600; font-size: 17px; }
.btn-primary:hover { background: #D4B57E; }
.btn-primary:active { background: #B8955A; }

.btn-row { background: var(--surface); border-color: var(--line-soft); }
.btn-row svg { color: var(--gold); }
.btn-row:hover { background: var(--surface-hi); border-color: var(--line); }
.btn-text { display: grid; gap: 3px; min-width: 0; }
.btn-label { font-size: 13px; letter-spacing: .04em; color: var(--muted); font-weight: 400; }
.btn-value { font-size: 17px; font-weight: 500; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }

.pair { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); }
.btn-quiet { justify-content: center; gap: 10px; padding-inline: 10px; white-space: nowrap; border-color: var(--line); color: var(--gold); }
.btn-quiet:hover { background: rgba(201, 167, 106, .1); border-color: var(--gold); }

/* ---- QR: dark modules on a light plate, quiet zone is part of the SVG ---- */
.qr { margin-top: 28px; display: grid; justify-items: center; gap: 12px; padding-top: 28px; border-top: 1px solid var(--line-soft); }
.qr-code { width: 207px; height: 207px; border-radius: var(--r); overflow: hidden; background: #F5F1E9; }
.qr-code svg { display: block; width: 100%; height: 100%; }
.qr-cap { font-size: 15px; letter-spacing: .04em; color: var(--muted); }

.legal { min-height: 8px; }

.toast {
  position: fixed; left: 50%; bottom: max(24px, env(safe-area-inset-bottom)); z-index: 20;
  transform: translate(-50%, 12px); opacity: 0; pointer-events: none;
  background: var(--ink); color: var(--ground); padding: 12px 20px; border-radius: var(--r); font-weight: 500; font-size: 15px;
  transition: opacity .2s ease, transform .3s var(--ease);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---- desktop: photo panel left, details right, inside a gold-bordered card ---- */
@media (min-width: 900px) {
  body { display: grid; place-items: center; padding: 40px 32px; }
  .card {
    max-width: 1040px; display: grid; grid-template-columns: 5fr 6fr; padding: 0;
    background: var(--ground); border: 1px solid var(--line); border-radius: 20px; overflow: hidden;
  }
  .photo { aspect-ratio: auto; max-height: none; height: 100%; min-height: 100%; }
  .photo img { object-position: 46% 30%; }
  .photo::after { inset: 0 0 0 auto; width: 30%; height: auto; background: linear-gradient(to right, rgba(16, 42, 43, 0), var(--ground) 96%); }
  .details { margin-top: 0; padding: 34px 48px 30px 24px; --gap: 10px; display: grid; align-content: center; }
  .wordmark { font-size: 76px; text-shadow: none; }
  .actions { margin-top: 22px; }
  .btn { min-height: 52px; }
  .btn-primary { min-height: 56px; }
  .qr { grid-template-columns: auto 1fr; justify-items: start; align-items: center; gap: 24px; margin-top: 20px; padding-top: 20px; }
  .qr-code { width: 207px; height: 207px; }
  .qr-cap { font-size: 16px; }
}

/* ---- entrance: one calm settle, only transform + opacity ---- */
@media (prefers-reduced-motion: no-preference) {
  @keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
  @keyframes settle { from { opacity: 0; transform: scale(1.04); } to { opacity: 1; transform: none; } }
  .photo img { animation: settle 1.1s var(--ease) both; }
  .identity > *, .actions > *, .qr { animation: rise .7s var(--ease) both; }
  .identity > :nth-child(1) { animation-delay: .15s; }
  .identity > :nth-child(2) { animation-delay: .25s; }
  .identity > :nth-child(3) { animation-delay: .32s; }
  .actions > :nth-child(1) { animation-delay: .38s; }
  .actions > :nth-child(2) { animation-delay: .44s; }
  .actions > :nth-child(3) { animation-delay: .50s; }
  .actions > :nth-child(4) { animation-delay: .56s; }
  .actions > :nth-child(5) { animation-delay: .62s; }
  .qr { animation-delay: .7s; }
}
@media (prefers-reduced-motion: reduce) {
  .btn, .toast { transition: none; }
  .btn:active { transform: none; }
}
