/* ═══════════════════════════════════════════════════════════════
   TAG HOUSE – Premium Design System v3
   Palette: Nero profondo · Oro antico · Crema
   Typography: Cormorant Garamond (display) + Space Grotesk (UI)
   Compatibile con: index.html, admin.html, app.js originale
═══════════════════════════════════════════════════════════════ */

/* ── Skip link a11y ──────────────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  background: var(--c-gold);
  color: var(--c-bg);
  padding: .7rem 1.2rem;
  border-radius: 6px;
  z-index: 9999;
  font-weight: 600;
  letter-spacing: .05em;
  transition: top .2s ease;
}
.skip-link:focus { top: 1rem; }

/* ── Grain overlay ───────────────────────────────────────────── */
.grain-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: .03;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* ── Reset & Variables ───────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

:root {
  color-scheme: dark;

  /* ── Palette principale ── */
  --c-bg:           #080808;
  --c-bg-2:         #0f0f0f;
  --c-bg-3:         #161616;
  --c-bg-card:      #111111;
  --c-border:       rgba(255,255,255,0.07);
  --c-border-hover: rgba(192,160,96,0.35);

  --c-gold:         #c0a060;
  --c-gold-light:   #d4b878;
  --c-gold-dark:    #8a6e3a;
  --c-gold-rgb:     192,160,96;

  --c-cream:        #e8e0d0;
  --c-cream-dim:    rgba(232,224,208,0.65);
  --c-cream-faint:  rgba(232,224,208,0.35);

  --c-chrome:       #b0b8c4;
  --c-chrome-light: #d4dce8;

  /* ── Alias compatibilità v2 ── */
  --gold:           var(--c-gold);
  --gold-light:     var(--c-gold-light);
  --gold-dark:      var(--c-gold-dark);
  --gold-glow:      rgba(192,160,96,0.35);
  --gold-border:    linear-gradient(135deg, #c0a060 0%, #d4b878 30%, #8a6e3a 55%, #d4b878 75%, #c0a060 100%);
  --gold-shadow:    0 0 0 2px rgba(192,160,96,0.5), 0 0 18px rgba(192,160,96,0.2), 0 0 40px rgba(192,160,96,0.08);
  --accent:         var(--c-gold);
  --accent-2:       var(--c-gold-light);
  --card:           var(--c-bg-card);
  --stroke:         var(--c-border);

  /* ── Typography ── */
  --f-display: 'Cormorant Garamond', Georgia, serif;
  --f-ui:      'Space Grotesk', system-ui, sans-serif;
  --f-mono:    'Space Mono', 'Courier New', monospace;

  /* ── Spacing ── */
  --sp-xs:  0.25rem;
  --sp-sm:  0.5rem;
  --sp-md:  1rem;
  --sp-lg:  1.5rem;
  --sp-xl:  2.5rem;
  --sp-2xl: 4rem;
  --sp-3xl: 6rem;

  /* ── Transitions ── */
  --t-fast:  150ms ease;
  --t-base:  250ms ease;
  --t-slow:  450ms cubic-bezier(0.25, 0.46, 0.45, 0.94);

  /* ── Radius ── */
  --r-sm:   4px;
  --r-md:   8px;
  --r-lg:   16px;
  --r-xl:   24px;
  --r-pill: 999px;

  /* ── Shadows ── */
  --shadow-card: 0 1px 3px rgba(0,0,0,.6), 0 4px 16px rgba(0,0,0,.4);
  --shadow-gold: 0 0 24px rgba(var(--c-gold-rgb),.25), 0 0 60px rgba(var(--c-gold-rgb),.1);
}

/* ── Base ────────────────────────────────────────────────────── */
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  font-size: 16px;
}

body {
  font-family: var(--f-ui);
  background: var(--c-bg);
  color: var(--c-cream);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  margin: 0;
  min-height: 100vh;
}

img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: inherit; }
input, textarea, select { font-family: inherit; }
ul, ol { list-style: none; }

/* ── Scrollbar ───────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--c-bg); }
::-webkit-scrollbar-thumb { background: var(--c-gold-dark); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--c-gold); }

/* ── Selection ───────────────────────────────────────────────── */
::selection { background: rgba(var(--c-gold-rgb), .25); color: var(--c-cream); }

/* ── Focus visible ───────────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--c-gold);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}

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

/* ── Cursor Glow ─────────────────────────────────────────────── */
.cursor-glow {
  position: fixed;
  width: 400px; height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--c-gold-rgb),.05) 0%, transparent 70%);
  pointer-events: none;
  transform: translate(-50%, -50%);
  transition: left .15s ease, top .15s ease;
  z-index: 0;
  will-change: left, top;
}

/* ── Ambient Orbs ────────────────────────────────────────────── */
.orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
  will-change: transform;
}
.orb--1 {
  width: 600px; height: 600px;
  background: rgba(var(--c-gold-rgb), .04);
  top: -200px; left: -200px;
  animation: orbFloat1 18s ease-in-out infinite;
}
.orb--2 {
  width: 500px; height: 500px;
  background: rgba(180,200,220, .025);
  bottom: 0; right: -150px;
  animation: orbFloat2 22s ease-in-out infinite;
}
.orb--3 {
  width: 350px; height: 350px;
  background: rgba(var(--c-gold-rgb), .025);
  top: 50%; left: 50%;
  animation: orbFloat3 28s ease-in-out infinite;
}
@keyframes orbFloat1 {
  0%, 100% { transform: translate(0,0) scale(1); }
  50%       { transform: translate(60px, 40px) scale(1.1); }
}
@keyframes orbFloat2 {
  0%, 100% { transform: translate(0,0) scale(1); }
  50%       { transform: translate(-40px, -60px) scale(1.15); }
}
@keyframes orbFloat3 {
  0%, 100% { transform: translate(-50%,-50%) scale(1); }
  33%       { transform: translate(-50%,-50%) scale(1.2) rotate(10deg); }
  66%       { transform: translate(-50%,-50%) scale(0.9) rotate(-5deg); }
}

/* Alias compatibilità v2: glow sinistra/destra */
.glow {
  position: fixed;
  top: 15%;
  width: 340px; height: 65%;
  filter: blur(130px);
  opacity: 0.35;
  z-index: 0;
  pointer-events: none;
}
.glow.left  { left: -140px;  background: radial-gradient(circle, rgba(var(--c-gold-rgb),.3) 0%, transparent 65%); }
.glow.right { right: -140px; background: radial-gradient(circle, rgba(192,160,200,.3) 0%, transparent 65%); }

/* ── Shell ───────────────────────────────────────────────────── */
.shell {
  max-width: 1200px;
  width: min(1200px, 100% - 4rem);
  margin: 0 auto;
  padding: 0 var(--sp-xl);
}

/* ═══════════════════════════════════════════════════════════════
   HEADER (mantiene classi originale: .header-bar, .main-nav,
   .logo-center, .header-actions)
═══════════════════════════════════════════════════════════════ */
.header-bar {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0 2rem;
  height: 72px;
  position: sticky;
  top: 0;
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  background: rgba(8,8,8,.85);
  border-bottom: 1px solid var(--c-border);
  z-index: 20;
  transition: box-shadow var(--t-base), background var(--t-base), border-color var(--t-base);
  width: 100%;
  overflow: hidden;
}
.header-bar.header-bar--solid {
  background: rgba(8,8,8,.97);
  box-shadow: 0 8px 32px rgba(0,0,0,.6);
  border-bottom-color: rgba(var(--c-gold-rgb),.15);
}

/* Logo centrato */
.logo-center {
  display: flex;
  justify-content: center;
  align-items: center;
}
.logo-img {
  height: 44px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
  display: block;
  mix-blend-mode: screen;
  filter: drop-shadow(0 0 8px rgba(var(--c-gold-rgb),.4));
  transition: filter var(--t-base);
}
.logo-img:hover { filter: drop-shadow(0 0 16px rgba(var(--c-gold-rgb),.7)); }

/* Logo persistente (admin.html) */
.logo-persistent {
  display: flex;
  align-items: center;
}
.logo-persistent img {
  height: 38px;
  width: auto;
  mix-blend-mode: screen;
  filter: drop-shadow(0 0 6px rgba(var(--c-gold-rgb),.4));
}

/* Nav sinistra */
.main-nav, .main-nav--left {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  justify-content: flex-start;
}
.main-nav--left a, .main-nav a {
  color: var(--c-cream-dim);
  text-decoration: none;
  font-size: .8rem;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  transition: color var(--t-fast);
  position: relative;
}
.main-nav--left a::after, .main-nav a::after {
  content: '';
  position: absolute;
  bottom: -3px; left: 0; right: 100%;
  height: 1px;
  background: var(--c-gold);
  transition: right var(--t-base);
}
.main-nav--left a:hover, .main-nav a:hover { color: var(--c-cream); }
.main-nav--left a:hover::after, .main-nav a:hover::after { right: 0; }

/* Actions destra */
.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: .65rem;
}
.btn-auth {
  padding: .48rem 1rem;
  font-size: .85rem;
}

/* Mobile menu toggle */
.mobile-menu-toggle { display: none; }

/* ── Account status bar ──────────────────────────────────────── */
.account-status {
  padding: .35rem 2rem;
  font-size: .82rem;
  color: var(--c-cream-dim);
  display: none;
  background: rgba(var(--c-gold-rgb),.02);
  border-bottom: 1px solid rgba(var(--c-gold-rgb),.06);
  position: relative;
  z-index: 2;
}
.account-status.visible { display: block; }
.account-status a { color: var(--c-gold); }
.account-status a:hover { color: var(--c-gold-light); text-decoration: underline; }

/* ═══════════════════════════════════════════════════════════════
   BUTTONS (mantiene .primary, .secondary + aggiunge .btn--*)
═══════════════════════════════════════════════════════════════ */
button, a.primary, a.secondary {
  border: none;
  font: inherit;
  cursor: pointer;
  border-radius: var(--r-pill);
  padding: .82rem 1.6rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: all var(--t-base);
  position: relative;
  overflow: hidden;
}
button:active { transform: scale(0.97); }

.primary {
  background: linear-gradient(135deg, var(--c-gold) 0%, var(--c-gold-dark) 100%);
  color: var(--c-bg);
  font-weight: 700;
  letter-spacing: .04em;
  box-shadow: 0 2px 12px rgba(var(--c-gold-rgb),.3);
}
.primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0);
  transition: background var(--t-fast);
}
.primary:hover::before { background: rgba(255,255,255,.06); }
.primary:hover {
  box-shadow: 0 4px 24px rgba(var(--c-gold-rgb),.5);
  transform: translateY(-1px);
}

/* Shine effect sui bottoni primary */
.primary::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.2), transparent);
  transition: left .6s ease;
  pointer-events: none;
}
.primary:hover::after { left: 100%; }

.secondary {
  background: rgba(255,255,255,.05);
  color: var(--c-cream);
  border: 1px solid var(--c-border);
}
.secondary:hover {
  background: rgba(var(--c-gold-rgb),.07);
  border-color: rgba(var(--c-gold-rgb),.3);
  color: var(--c-gold-light);
}

.primary.ghost {
  background: transparent;
  border: 1px solid rgba(var(--c-gold-rgb),.4);
  color: var(--c-gold-light);
  box-shadow: none;
}
.primary.ghost:hover {
  background: rgba(var(--c-gold-rgb),.07);
  border-color: var(--c-gold);
}

.full { width: 100%; justify-content: center; }
.btn-action-full { width: 100%; justify-content: center; margin-top: .5rem; }

/* Alias .btn--* per compatibilità webapp */
.btn--primary  { @extend .primary; }
.btn--gold {
  background: transparent;
  color: var(--c-gold);
  border: 1px solid rgba(var(--c-gold-rgb),.5);
  border-radius: var(--r-sm);
  font-family: var(--f-ui);
  padding: .8rem 1.8rem;
  font-size: .85rem;
  font-weight: 500;
  letter-spacing: .08em;
  cursor: pointer;
  transition: all var(--t-base);
}
.btn--gold:hover {
  background: rgba(var(--c-gold-rgb),.08);
  border-color: var(--c-gold);
  box-shadow: 0 0 20px rgba(var(--c-gold-rgb),.2);
}
.btn--full { width: 100%; }
.btn--sm { padding: .55rem 1.2rem; font-size: .78rem; }

/* ── Icon button ─────────────────────────────────────────────── */
.icon-button {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.04);
  color: var(--c-cream);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--t-base);
  font-size: 1.1rem;
  padding: 0;
  position: relative;
  overflow: visible;
}
.icon-button:hover {
  background: rgba(var(--c-gold-rgb),.08);
  border-color: rgba(var(--c-gold-rgb),.4);
  color: var(--c-gold);
}

/* ── Cart badge ──────────────────────────────────────────────── */
.cart-toggle-btn { position: relative; }
.cart-count-badge {
  position: absolute;
  top: -4px; right: -4px;
  min-width: 18px; height: 18px;
  border-radius: 9px;
  background: var(--c-gold);
  color: var(--c-bg);
  font-size: .65rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
  pointer-events: none;
  font-family: var(--f-mono);
  box-shadow: 0 0 8px rgba(var(--c-gold-rgb),.4);
}
.cart-count-badge[hidden] { display: none !important; }

/* ── Btn preview ─────────────────────────────────────────────── */
.btn-preview {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  background: transparent;
  border: 1px solid rgba(var(--c-gold-rgb),.35);
  color: var(--c-gold);
  border-radius: var(--r-sm);
  padding: .75rem 1.1rem;
  font-size: .85rem;
  font-weight: 500;
  letter-spacing: .06em;
  flex-shrink: 0;
  font-family: var(--f-ui);
  transition: all var(--t-base);
  cursor: pointer;
}
.btn-preview:hover {
  background: rgba(var(--c-gold-rgb),.08);
  border-color: var(--c-gold);
  box-shadow: 0 4px 14px rgba(var(--c-gold-rgb),.2);
  transform: translateY(-1px);
}

/* Bottone paga ora */
.btn-pay-now {
  background: transparent !important;
  border: 1.5px solid rgba(var(--c-gold-rgb),.5) !important;
  color: var(--c-gold-light) !important;
  font-weight: 600 !important;
  box-shadow: none !important;
}
.btn-pay-now:hover {
  background: rgba(var(--c-gold-rgb),.07) !important;
  border-color: var(--c-gold) !important;
  color: var(--c-gold) !important;
  transform: translateY(-1px) !important;
}

/* ═══════════════════════════════════════════════════════════════
   TYPOGRAPHY
═══════════════════════════════════════════════════════════════ */
.eyebrow {
  display: block;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--c-gold);
  margin-bottom: var(--sp-sm);
}

.page-eyebrow {
  text-transform: uppercase;
  letter-spacing: .18em;
  font-size: .72rem;
  color: var(--c-gold);
  margin-bottom: .3rem;
}

h1 { font-family: var(--f-display); font-size: clamp(2.4rem, 5vw, 4rem); font-weight: 400; line-height: 1.1; color: var(--c-cream); }
h2 { font-family: var(--f-display); font-size: clamp(1.8rem, 3.5vw, 2.8rem); font-weight: 400; line-height: 1.15; color: var(--c-cream); }
h3 { font-family: var(--f-ui); font-size: 1rem; font-weight: 600; letter-spacing: .04em; color: var(--c-cream); }

/* ═══════════════════════════════════════════════════════════════
   HERO TOP (layout testo sx + viewer dx)
═══════════════════════════════════════════════════════════════ */
.hero-top {
  padding: 3rem 0 2rem;
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 2.5rem;
  align-items: center;
  max-width: 1100px;
  margin-inline: auto;
  position: relative;
  z-index: 1;
}

.hero-top__text .badge {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  background: rgba(var(--c-gold-rgb),.08);
  border: 1px solid rgba(var(--c-gold-rgb),.2);
  color: var(--c-gold-light);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .15em;
  text-transform: uppercase;
  padding: .4rem .9rem;
  border-radius: var(--r-pill);
  margin-bottom: .9rem;
}

.hero-top__text h1 {
  font-family: var(--f-display);
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.1;
  margin: 0 0 .9rem;
  color: var(--c-cream);
}

.hero-top__text .lead {
  color: var(--c-cream-dim);
  max-width: 44ch;
  line-height: 1.75;
  margin: 0;
  font-size: .97rem;
}

.hero-top__cta { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: 1.4rem; }

/* ── Viewer nell'hero (a destra del titolo) ──────────────────── */
.hero-viewer-wrap { flex-shrink: 0; }

.hero__viewer {
  background: rgba(255,255,255,.02);
  border-radius: var(--r-xl);
  border: 1px solid rgba(var(--c-gold-rgb),.12);
  padding: 1rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 0 60px rgba(var(--c-gold-rgb),.04), var(--shadow-card);
  transition: box-shadow var(--t-slow);
}
.hero__viewer::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 20%, rgba(var(--c-gold-rgb),.04) 0%, transparent 65%);
  pointer-events: none;
}
.hero__viewer:hover {
  box-shadow:
    var(--shadow-card),
    0 32px 80px rgba(0,0,0,.5),
    0 0 50px rgba(var(--c-gold-rgb),.07),
    inset 0 1px 0 rgba(255,255,255,.04);
}

.hero-viewer-wrap .viewer__canvas {
  aspect-ratio: 1 / 1;
  width: 100%;
  max-width: 380px;
}

.viewer__canvas {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 12px;
  overflow: hidden;
  background: #080810;
}
.viewer__canvas canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
  border-radius: 12px;
}

.viewer__meta {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid rgba(255,255,255,.06);
  margin-top: .9rem;
  padding-top: .7rem;
  font-size: .8rem;
  color: var(--c-cream-faint);
}
.viewer__meta span:first-child { color: var(--c-gold); font-weight: 600; }

.viewer-hints {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: .75rem;
}
.viewer-hint {
  font-size: .68rem;
  color: var(--c-cream-faint);
  padding: .25rem .65rem;
  border: 1px solid rgba(255,255,255,.05);
  border-radius: var(--r-pill);
}

/* ── Page layout ─────────────────────────────────────────────── */
.page-layout {
  display: grid;
  grid-template-columns: 500px 1fr;
  gap: 2.5rem;
  align-items: start;
  padding-top: 2.5rem;
  padding-bottom: 4rem;
  position: relative;
  z-index: 1;
}
.page-layout--single {
  grid-template-columns: 1fr;
  max-width: 1100px;
  margin-inline: auto;
}
.page-left {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.page-right {
  position: sticky;
  top: 80px;
  align-self: start;
}
.viewer-sticky-wrap { position: sticky; top: 72px; }

/* ═══════════════════════════════════════════════════════════════
   SEZIONI CONFIGURATORE (mantiene .config-section, .steps-row)
═══════════════════════════════════════════════════════════════ */
#configuratore { position: relative; z-index: 1; }

.config-section {
  background: var(--c-bg-card);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: 1.6rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 1.25rem;
  transition: border-color var(--t-base);
  position: relative;
  overflow: hidden;
}
.config-section::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(to right, var(--c-gold-dark), var(--c-gold), var(--c-gold-dark));
  opacity: 0;
  transition: opacity var(--t-base);
}
.config-section:focus-within { border-color: rgba(var(--c-gold-rgb),.3); }
.config-section:focus-within::before { opacity: 1; }
.config-section:last-child { margin-bottom: 0; }

.config-section__head {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-bottom: 1.2rem;
  flex-wrap: wrap;
}
.config-section__head .eyebrow {
  background: rgba(var(--c-gold-rgb),.08);
  color: var(--c-gold);
  border: 1px solid rgba(var(--c-gold-rgb),.2);
  border-radius: var(--r-pill);
  padding: .15rem .65rem;
  font-size: .65rem;
  letter-spacing: .15em;
  margin-bottom: 0;
}
.config-section__title {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  flex: 1;
  color: var(--c-cream);
  font-family: var(--f-display);
  letter-spacing: .03em;
}

/* ── Price tag ───────────────────────────────────────────────── */
.price {
  font-size: 1.8rem;
  font-weight: 400;
  font-family: var(--f-display);
  color: var(--c-gold-light);
  margin-left: auto;
}

/* ── Steps row ───────────────────────────────────────────────── */
.steps-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: stretch;
}
.steps-row .config-section {
  margin-bottom: 0;
  height: 100%;
  box-sizing: border-box;
}

/* ── CTA buttons ─────────────────────────────────────────────── */
.cta-buttons {
  display: flex;
  flex-direction: column;
  gap: .65rem;
  margin-top: .9rem;
}
.cta-buttons .primary {
  padding: .9rem 1.2rem;
  font-size: .95rem;
  justify-content: center;
  border-radius: var(--r-sm);
}

/* ── Input parola ────────────────────────────────────────────── */
.input-row { display: flex; gap: .65rem; }
.input-row input[type="text"],
input[type="text"] {
  flex: 1;
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.03);
  padding: .85rem 1.1rem;
  color: var(--c-cream);
  font-size: 1.05rem;
  font-family: var(--f-mono);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  transition: all var(--t-base);
}
.input-row input[type="text"]:focus,
input[type="text"]:focus {
  outline: none;
  border-color: rgba(var(--c-gold-rgb),.5);
  background: rgba(var(--c-gold-rgb),.03);
  box-shadow: 0 0 0 3px rgba(var(--c-gold-rgb),.08);
}
.hint {
  font-size: .78rem;
  color: var(--c-cream-faint);
  margin-top: .4rem;
}

/* ── Fine print ──────────────────────────────────────────────── */
.fine-print {
  font-size: .73rem;
  color: var(--c-cream-faint);
  text-align: center;
  margin-top: .7rem;
}

/* ═══════════════════════════════════════════════════════════════
   FONT PICKER
═══════════════════════════════════════════════════════════════ */
.font-picker {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}
.font-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: .5rem .85rem;
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.03);
  cursor: pointer;
  transition: all var(--t-base);
  font-family: var(--f-ui);
  text-align: left;
}
.font-btn:hover {
  border-color: rgba(var(--c-gold-rgb),.35);
  background: rgba(var(--c-gold-rgb),.04);
}
.font-btn.active {
  border-color: var(--c-gold);
  background: rgba(var(--c-gold-rgb),.07);
  box-shadow: var(--gold-shadow);
}
.font-btn__name {
  font-size: .85rem;
  font-weight: 600;
  color: var(--c-cream);
  line-height: 1.2;
}
.font-btn.active .font-btn__name { color: var(--c-gold-light); }
.font-btn__label {
  font-size: .68rem;
  color: var(--c-cream-faint);
  margin-top: .1rem;
  letter-spacing: .05em;
}
.font-btn.active .font-btn__label { color: var(--c-gold); }

/* ═══════════════════════════════════════════════════════════════
   VARIANTI
═══════════════════════════════════════════════════════════════ */
.variants { display: grid; gap: .65rem; }

.variant-card {
  border-radius: var(--r-md);
  padding: 1rem 1.2rem;
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.02);
  cursor: pointer;
  transition: all var(--t-base);
  width: 100%;
  text-align: left;
  position: relative;
  overflow: hidden;
}
.variant-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent, rgba(var(--c-gold-rgb),.04));
  opacity: 0;
  transition: opacity var(--t-base);
}
.variant-card:hover {
  border-color: rgba(var(--c-gold-rgb),.3);
  background: rgba(var(--c-gold-rgb),.025);
}
.variant-card:hover::after { opacity: 1; }
.variant-card.active {
  border-color: var(--c-gold);
  transform: translateY(-2px);
  box-shadow: var(--gold-shadow);
  background: rgba(var(--c-gold-rgb),.05);
}
.variant-card.active::after { opacity: 1; }

/* Shimmer top bar su active */
.variant-card.active::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(to right, transparent, var(--c-gold), transparent);
  animation: shimmer 2s linear infinite;
}
@keyframes shimmer {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.variant-card.active h3 { color: var(--c-gold-light); }
.variant-card.active span { color: var(--c-gold); }
.variant-card__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}
.variant-card h3 { margin: 0; font-size: 1rem; font-family: var(--f-ui); }
.variant-card span { font-size: 1.05rem; font-weight: 600; color: var(--c-cream); font-family: var(--f-mono); }

/* ═══════════════════════════════════════════════════════════════
   SWATCHES & COLORI
═══════════════════════════════════════════════════════════════ */
.swatch-grid { display: flex; flex-wrap: wrap; gap: .6rem; }

button.swatch-dot {
  width: 42px; height: 42px;
  border-radius: 50%;
  border: 2px solid transparent;
  background: var(--swatch-color, #fff);
  padding: 0;
  cursor: pointer;
  transition: all var(--t-base);
  position: relative;
}
button.swatch-dot::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.07);
}
button.swatch-dot:hover {
  transform: scale(1.14);
  border-color: rgba(var(--c-gold-rgb),.5);
}
button.swatch-dot.active {
  border: 2px solid var(--c-gold);
  box-shadow: var(--gold-shadow);
  transform: scale(1.1);
}

.swatch-color-name {
  font-size: .78rem;
  font-weight: 600;
  color: var(--c-gold-light);
  margin: .5rem 0 0;
  min-height: 1.1em;
  letter-spacing: .04em;
  text-transform: uppercase;
  font-family: var(--f-mono);
}

/* Finish grid: varianti sx + colori dx */
.finish-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: start;
}
.finish-sub-label {
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .15em;
  color: var(--c-cream-faint);
  margin: 0 0 .7rem;
  font-weight: 600;
}

/* Custom colors */
.custom-colors { margin: 1rem 0; }
input[type="color"] {
  width: 100%;
  height: 44px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  background: transparent;
  padding: 2px;
  cursor: pointer;
  margin-bottom: .9rem;
}
input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; border-radius: 6px; }
input[type="color"]::-webkit-color-swatch { border: none; border-radius: 6px; }

/* ═══════════════════════════════════════════════════════════════
   SHIPPING FULL & FAQ
═══════════════════════════════════════════════════════════════ */
.shipping-full {
  padding: 2.5rem 0 1.5rem;
  border-top: 1px solid var(--c-border);
  margin-top: 1rem;
  max-width: 1100px;
  margin-inline: auto;
  text-align: center;
  position: relative;
}
.shipping-full::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(var(--c-gold-rgb),.25), transparent);
}
.shipping-full h2 {
  margin: 0 0 .2rem;
  font-family: var(--f-display);
  font-size: 1.8rem;
  text-align: center;
}
.shipping-full .shipping__grid { text-align: left; }

.shipping__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-top: .5rem;
}

article {
  padding: 1.5rem;
  border-radius: var(--r-lg);
  background: var(--c-bg-card);
  border: 1px solid var(--c-border);
  transition: all var(--t-base);
}
article:hover {
  border-color: rgba(var(--c-gold-rgb),.25);
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0,0,0,.3);
}
article h3 { margin: 0 0 .5rem; font-size: .95rem; font-family: var(--f-ui); }
article p  { margin: 0; font-size: .85rem; color: var(--c-cream-dim); line-height: 1.65; }

/* FAQ section */
.faq-section {
  padding: 3rem 0 2rem;
  background: var(--c-bg-2);
  position: relative;
  z-index: 1;
  margin-top: 2rem;
}
.faq-section::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(var(--c-gold-rgb),.2), transparent);
}
.faq-header { margin-bottom: 2rem; text-align: center; }
.faq-label-small {
  display: inline-block;
  font-size: .7rem;
  text-transform: uppercase;
  letter-spacing: .25em;
  color: var(--c-gold);
  margin-bottom: .5rem;
  background: rgba(var(--c-gold-rgb),.08);
  border: 1px solid rgba(var(--c-gold-rgb),.2);
  border-radius: var(--r-pill);
  padding: .18rem .8rem;
}
.faq-title {
  font-family: var(--f-display);
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  margin: .4rem 0 0;
  font-weight: 400;
  color: var(--c-cream);
}
.faq-grid { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

/* ═══════════════════════════════════════════════════════════════
   CART PANEL (slide laterale)
═══════════════════════════════════════════════════════════════ */
.cart-panel {
  position: fixed;
  top: 0; right: -420px;
  width: min(400px, 100vw);
  height: 100vh;
  background: var(--c-bg-2);
  border-left: 1px solid var(--c-border);
  box-shadow: -8px 0 40px rgba(0,0,0,.5);
  transition: right var(--t-slow);
  z-index: 1000;
  padding: 1.5rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.cart-panel.open { right: 0; }

.cart-panel__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--c-border);
}
.cart-panel__header h4 {
  margin: 0;
  font-size: 1.2rem;
  font-family: var(--f-display);
  font-weight: 400;
  color: var(--c-cream);
}
.cart-panel__section { margin-bottom: 1.25rem; }
.cart-panel__section h5 {
  margin: 0 0 .6rem;
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .68rem;
  color: var(--c-cream-faint);
}

.checkout-stage { display: flex; flex-direction: column; gap: .75rem; }

.input-card {
  display: flex;
  gap: .8rem;
  padding: .85rem 1rem;
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  margin-bottom: .6rem;
  background: rgba(255,255,255,.02);
  cursor: pointer;
  transition: all var(--t-base);
}
.input-card:hover { border-color: rgba(var(--c-gold-rgb),.3); }
.input-card:has(input:checked) {
  border-color: var(--c-gold);
  box-shadow: var(--gold-shadow);
  background: rgba(var(--c-gold-rgb),.04);
}
.input-card input { accent-color: var(--c-gold); flex-shrink: 0; margin-top: 3px; }
.input-card strong { display: block; font-size: .93rem; color: var(--c-cream); }
.input-card p { margin: .15rem 0 0; font-size: .78rem; color: var(--c-cream-faint); }

.cart-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: .75rem 0;
  border-top: 1px solid var(--c-border);
  margin-top: .25rem;
}
.cart-total-row span:last-child {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--c-gold-light);
  font-family: var(--f-mono);
}

/* Form grid nel cart */
.form-grid { display: grid; gap: .65rem; }
.form-grid label {
  display: flex;
  flex-direction: column;
  font-size: .82rem;
  color: var(--c-cream-dim);
}
.form-grid input, .form-grid textarea {
  margin-top: .25rem;
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.03);
  color: var(--c-cream);
  padding: .6rem .85rem;
  font-size: .88rem;
  font-family: inherit;
  transition: border-color var(--t-fast);
}
.form-grid input:focus, .form-grid textarea:focus {
  outline: none;
  border-color: rgba(var(--c-gold-rgb),.45);
  box-shadow: 0 0 0 3px rgba(var(--c-gold-rgb),.07);
}

.cart-panel textarea {
  width: 100%; margin-top: .25rem;
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.03);
  padding: .6rem .85rem;
  color: var(--c-cream); font-size: .88rem;
  resize: none; font-family: inherit;
}
.cart-panel label {
  display: block; font-size: .82rem;
  color: var(--c-cream-dim);
  margin-bottom: .6rem;
}
.cart-panel label input[type=text],
.cart-panel label input[type=email] {
  display: block; width: 100%;
  margin-top: .25rem; border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.03);
  padding: .6rem .85rem; color: var(--c-cream);
  font-size: .88rem;
}

/* Cart: stato vuoto */
.cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  text-align: center;
  color: var(--c-cream-faint);
}
.cart-empty__icon { font-size: 3rem; display: block; margin-bottom: 1rem; opacity: .5; }
.cart-empty__text { font-size: 1rem; font-weight: 600; color: var(--c-cream-dim); margin: 0 0 .35rem; }
.cart-empty__sub  { font-size: .82rem; color: var(--c-cream-faint); margin: 0; max-width: 24ch; line-height: 1.5; }

/* Cart: sezione prodotto */
.cart-product-row {
  display: flex;
  align-items: center;
  gap: .9rem;
  padding: .9rem 0;
  border-bottom: 1px solid var(--c-border);
  margin-bottom: .75rem;
}
.cart-prod-img {
  width: 72px; height: 72px;
  border-radius: var(--r-md);
  object-fit: cover;
  border: 1px solid rgba(var(--c-gold-rgb),.2);
  flex-shrink: 0;
  background: var(--c-bg-3);
}
.cart-product-info {
  flex: 1; display: flex; flex-direction: column; gap: .18rem; min-width: 0;
}
.cart-product-info strong { font-size: .97rem; font-weight: 700; color: var(--c-cream); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cart-product-info span { font-size: .8rem; color: var(--c-cream-faint); }
.cart-prod-color { font-size: .75rem !important; color: var(--c-cream-faint) !important; display: flex; align-items: center; gap: 4px; }
.cart-product-qty { display: flex; flex-direction: column; align-items: center; gap: .25rem; flex-shrink: 0; }
.qty-controls { display: flex; align-items: center; gap: .4rem; }
.qty-btn {
  width: 28px; height: 28px;
  border-radius: 50%;
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.04);
  color: var(--c-cream);
  font-size: 1rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: all var(--t-fast);
  padding: 0; font-family: inherit;
}
.qty-btn:hover { background: rgba(var(--c-gold-rgb),.1); border-color: var(--c-gold); color: var(--c-gold); }
.qty-val { font-size: 1.1rem; font-weight: 700; color: var(--c-cream); min-width: 20px; text-align: center; font-family: var(--f-mono); }
.qty-price { font-size: .85rem; font-weight: 700; color: var(--c-gold-light); font-family: var(--f-mono); }

/* Wire box */
.wire-box {
  background: rgba(var(--c-gold-rgb),.04);
  border: 1px solid rgba(var(--c-gold-rgb),.18);
  border-radius: var(--r-md);
  padding: 1.15rem 1.4rem;
  text-align: left;
  margin: 1.25rem 0;
}
.wire-box h4 { margin: 0 0 .65rem; color: var(--c-gold); font-size: .85rem; text-transform: uppercase; letter-spacing: .1em; }
.wire-box p  { margin: .3rem 0; font-size: .88rem; color: var(--c-cream-dim); }
.wire-box code { color: var(--c-gold-light); font-family: var(--f-mono); }

/* ═══════════════════════════════════════════════════════════════
   AUTH MODAL
═══════════════════════════════════════════════════════════════ */
.auth-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.75);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 40;
  padding: 1rem;
}
.auth-modal.open { display: flex; }

.auth-card {
  width: min(420px, 100%);
  background: var(--c-bg-2);
  border: 1px solid rgba(var(--c-gold-rgb),.15);
  border-radius: var(--r-xl);
  padding: 3.5rem 1.75rem 1.75rem;
  position: relative;
  box-shadow: 0 24px 80px rgba(0,0,0,.7), var(--shadow-gold);
}
.auth-card.register-mode { padding-top: 2rem; }

.auth-card .icon-button.close {
  position: absolute;
  top: 1rem; right: 1rem;
  width: 34px; height: 34px;
  border-radius: 50%;
  font-size: 1rem;
  background: rgba(255,255,255,.06);
  border-color: var(--c-border);
}

.auth-tabs { display: flex; gap: .4rem; margin: 0 0 1.5rem; }
.auth-card.register-mode .auth-tabs { display: none; }

.auth-tab {
  flex: 1;
  border-radius: var(--r-pill);
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.04);
  color: var(--c-cream-dim);
  padding: .6rem;
  font-size: .9rem;
  cursor: pointer;
  font-family: inherit;
  transition: all var(--t-base);
}
.auth-tab.active {
  background: linear-gradient(135deg, var(--c-gold) 0%, var(--c-gold-dark) 100%);
  color: var(--c-bg);
  border-color: transparent;
  font-weight: 700;
}

.auth-panel { display: none; }
.auth-panel:not(.hidden) { display: block; }
.auth-panel.hidden { display: none; }

.auth-panel label {
  display: block;
  font-size: .83rem;
  color: var(--c-cream-dim);
  margin-bottom: .85rem;
}
.auth-panel input[type='text'],
.auth-panel input[type='email'],
.auth-panel input[type='password'] {
  width: 100%;
  margin-top: .25rem;
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  background: rgba(255,255,255,.03);
  padding: .65rem .9rem;
  color: var(--c-cream);
  font-size: .9rem;
  font-family: inherit;
  transition: all var(--t-base);
}
.auth-panel input:focus {
  outline: none;
  border-color: rgba(var(--c-gold-rgb),.45);
  box-shadow: 0 0 0 3px rgba(var(--c-gold-rgb),.08);
}

.auth-grid { display: flex; gap: .75rem; }

/* ═══════════════════════════════════════════════════════════════
   ALERTS & STATUS BADGES
═══════════════════════════════════════════════════════════════ */
.alert {
  padding: .75rem 1rem;
  border-radius: var(--r-md);
  margin-bottom: .85rem;
  font-size: .85rem;
  line-height: 1.4;
}
.alert-error   { background: rgba(200,60,60,.08);  border: 1px solid rgba(200,60,60,.25);  color: #e08080; }
.alert-success { background: rgba(80,160,80,.08);   border: 1px solid rgba(80,160,80,.25);  color: #8fce8f; }
.alert-info    { background: rgba(var(--c-gold-rgb),.08); border: 1px solid rgba(var(--c-gold-rgb),.2); color: var(--c-gold-light); }

.status-badge {
  display: inline-block;
  padding: .16rem .55rem;
  border-radius: var(--r-pill);
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .03em;
  font-family: var(--f-mono);
}
.status-badge--pending    { background: rgba(192,160,96,.15); color: var(--c-gold); }
.status-badge--paid       { background: rgba(80,160,80,.15);  color: #8fce8f; }
.status-badge--processing { background: rgba(80,120,200,.15); color: #8ab4ff; }
.status-badge--awaiting   { background: rgba(200,120,60,.15); color: #e0a060; }
.status-badge--cancelled  { background: rgba(200,60,60,.1);   color: #e08080; }

/* ═══════════════════════════════════════════════════════════════
   SPINNER
═══════════════════════════════════════════════════════════════ */
.spinner {
  display: inline-block;
  width: 16px; height: 16px;
  border: 2px solid rgba(var(--c-gold-rgb),.15);
  border-top-color: var(--c-gold);
  border-radius: 50%;
  animation: spin .7s linear infinite;
  vertical-align: middle;
  margin-right: .3rem;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ═══════════════════════════════════════════════════════════════
   ADMIN TABLE
═══════════════════════════════════════════════════════════════ */
.admin-table { width: 100%; border-collapse: collapse; font-size: .83rem; }
.admin-table th {
  padding: .6rem .8rem;
  text-align: left;
  text-transform: uppercase;
  letter-spacing: .1em;
  font-size: .67rem;
  color: var(--c-cream-faint);
  border-bottom: 1px solid var(--c-border);
  font-family: var(--f-mono);
}
.admin-table td {
  padding: .6rem .8rem;
  border-bottom: 1px solid rgba(255,255,255,.03);
  color: var(--c-cream-dim);
}
.admin-table tr:hover td { background: rgba(var(--c-gold-rgb),.02); }

.admin-select {
  background: rgba(255,255,255,.04);
  border: 1px solid var(--c-border);
  border-radius: var(--r-sm);
  color: var(--c-cream);
  padding: .22rem .45rem;
  font-size: .73rem;
  cursor: pointer;
  font-family: inherit;
  transition: border-color var(--t-fast);
}
.admin-select:focus { outline: none; border-color: rgba(var(--c-gold-rgb),.4); }

.admin-tabs { display: flex; gap: .5rem; margin-bottom: 1.25rem; }
.admin-tab-btn {
  background: rgba(255,255,255,.04);
  border: 1px solid var(--c-border);
  border-radius: var(--r-pill);
  color: var(--c-cream-dim);
  padding: .48rem 1.15rem;
  font-size: .83rem;
  cursor: pointer;
  transition: all var(--t-base);
  font-family: inherit;
}
.admin-tab-btn.active, .admin-tab-btn:hover {
  background: linear-gradient(135deg, var(--c-gold) 0%, var(--c-gold-dark) 100%);
  color: var(--c-bg);
  border-color: transparent;
  font-weight: 600;
}

/* ═══════════════════════════════════════════════════════════════
   ORDERS LIST
═══════════════════════════════════════════════════════════════ */
.orders-list { display: flex; flex-direction: column; gap: .65rem; }
.order-item {
  padding: .9rem 1.2rem;
  border-radius: var(--r-md);
  background: var(--c-bg-card);
  border: 1px solid var(--c-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .5rem;
  transition: border-color var(--t-base);
}
.order-item:hover { border-color: rgba(var(--c-gold-rgb),.2); }
.order-item__info strong { display: block; margin-bottom: .12rem; font-size: .92rem; color: var(--c-cream); }
.order-item__info span  { font-size: .78rem; color: var(--c-cream-faint); }
.order-item__price { font-size: 1.05rem; font-weight: 700; color: var(--c-gold); font-family: var(--f-mono); }

/* ═══════════════════════════════════════════════════════════════
   RESULT PAGES (success/cancel)
═══════════════════════════════════════════════════════════════ */
.result-page {
  max-width: 500px;
  margin: 6rem auto;
  padding: 0 1rem;
  text-align: center;
}
.result-page h1 {
  font-family: var(--f-display);
  font-size: clamp(1.8rem, 4vw, 3rem);
  margin-bottom: .5rem;
}
.result-icon { font-size: 3.5rem; margin-bottom: 1.25rem; display: block; }

/* ═══════════════════════════════════════════════════════════════
   STL DOWNLOAD BUTTON
═══════════════════════════════════════════════════════════════ */
.btn-stl {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .6rem 1.1rem;
  border-radius: var(--r-md);
  border: 1px solid rgba(var(--c-gold-rgb),.3);
  background: rgba(var(--c-gold-rgb),.05);
  color: var(--c-gold);
  font-size: .85rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all var(--t-base);
}
.btn-stl:hover {
  background: rgba(var(--c-gold-rgb),.1);
  border-color: var(--c-gold);
  transform: translateY(-1px);
}
.btn-stl:disabled { opacity: .5; cursor: wait; transform: none; }

/* ═══════════════════════════════════════════════════════════════
   FOOTER
═══════════════════════════════════════════════════════════════ */
.footer {
  padding: 2rem 2rem 3rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .75rem;
  border-top: 1px solid var(--c-border);
  text-align: center;
  position: relative;
  z-index: 2;
  background: var(--c-bg-2);
}
.footer::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(var(--c-gold-rgb),.25), transparent);
}
.footer__links { display: flex; gap: 1.25rem; margin-bottom: .25rem; }
.footer__links a {
  color: var(--c-cream-faint);
  text-decoration: none;
  font-size: .88rem;
  transition: color var(--t-fast);
}
.footer__links a:hover { color: var(--c-gold); }
.footer p { margin: 0; color: var(--c-cream-faint); font-size: .82rem; }

/* ═══════════════════════════════════════════════════════════════
   LABEL & FORM GENERICI
═══════════════════════════════════════════════════════════════ */
label {
  display: block;
  font-size: .88rem;
  margin-bottom: .35rem;
  color: var(--c-cream-dim);
}
@media (min-width: 600px) {
  .form-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* ═══════════════════════════════════════════════════════════════
   TOAST
═══════════════════════════════════════════════════════════════ */
#toast-container {
  position: fixed;
  bottom: var(--sp-xl);
  right: var(--sp-xl);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: var(--sp-sm);
  pointer-events: none;
}
.toast {
  display: flex;
  align-items: center;
  gap: var(--sp-md);
  padding: .85rem 1.2rem;
  border-radius: var(--r-md);
  font-size: .86rem;
  font-weight: 500;
  box-shadow: 0 4px 20px rgba(0,0,0,.4);
  pointer-events: auto;
  animation: toastIn .3s ease;
  max-width: 340px;
}
@keyframes toastIn {
  from { opacity: 0; transform: translateX(20px); }
  to   { opacity: 1; transform: translateX(0); }
}
.toast--success { background: var(--c-bg-2); border: 1px solid rgba(80,160,80,.35); color: #8fce8f; }
.toast--error   { background: var(--c-bg-2); border: 1px solid rgba(200,60,60,.3);  color: #e08080; }
.toast--info    { background: var(--c-bg-2); border: 1px solid rgba(var(--c-gold-rgb),.3); color: var(--c-gold-light); }

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════════ */
@media (max-width: 1000px) {
  .page-layout { grid-template-columns: 1fr; gap: 1.5rem; }
  .page-layout--single { grid-template-columns: 1fr; }
  .hero-top { grid-template-columns: 1fr; gap: 1.5rem; padding-top: 1.5rem; }
  .hero-viewer-wrap { display: flex; justify-content: center; }
  .hero-viewer-wrap .viewer__canvas { max-width: 360px; }
}

@media (max-width: 768px) {
  .header-bar { padding: .55rem 1rem; height: 60px; }
  .mobile-menu-toggle {
    display: flex;
    background: transparent;
    border: 1px solid var(--c-border);
    border-radius: var(--r-sm);
    padding: 7px;
    color: var(--c-cream-dim);
    cursor: pointer;
    order: -1;
  }
  .main-nav { display: none; }
  .main-nav.mobile-open {
    display: flex;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: rgba(8,8,8,.98);
    border-top: 1px solid var(--c-border);
    padding: 1rem 1.5rem;
    flex-direction: column;
    gap: 1rem;
    z-index: 50;
  }
  .shell { width: calc(100% - 2rem); padding: 0 1rem; }
  .cart-panel { width: 100%; right: -100%; }
  .cart-panel.open { right: 0; }
  .auth-grid { flex-direction: column; }
  .input-row { flex-direction: column; }
  .input-row button { width: 100%; }
  .page-layout { padding-top: 1.5rem; }
  .steps-row { grid-template-columns: 1fr; }
  .hero-top__cta { width: 100%; }
  .hero-top__cta button { flex: 1; }
  .btn-preview { width: 100%; justify-content: center; }
  .font-picker { gap: .4rem; }
  .config-section { padding: 1.2rem 1rem; }
  #toast-container { right: var(--sp-md); left: var(--sp-md); }
  .toast { max-width: 100%; }
}

@media (max-width: 600px) {
  .finish-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .hero-top__text h1 { font-size: 1.85rem; }
  .config-section__title { font-size: 1rem; }
  .price { font-size: 1.5rem; }
  .logo-img { height: 34px; }
}

/* ── Motion safe ─────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .orb, .cursor-glow { display: none; }
}
