/* ─────────────────────────────────────────────────────────────
   MinduBier × Copa 2026 — Pré-venda
   Hybrid: MinduBier (cream/glass/copper) + Copa accents
   ───────────────────────────────────────────────────────────── */

@font-face {
  font-family: 'Outfit';
  src: url('fonts/Outfit-VariableFont_wght.ttf') format('truetype');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: 'Nunito Sans';
  src: url('fonts/NunitoSans-VariableFont.ttf') format('truetype');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Nunito Sans';
  src: url('fonts/NunitoSans-Italic-VariableFont.ttf') format('truetype');
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}

:root {
  --bg-light:   #fffff4;
  --bg-dark:    #444444;
  --bg-darker:  #323231;
  --bg-footer:  #2a2a29;
  --brand-copper: #c5762a;
  --brand-amber:  #efa31f;
  --brand-gold:   #ffd503;
  --copa-green:   #009739;
  --copa-green-deep: #00622a;
  --copa-yellow:  #fedd00;
  --copa-blue:    #002776;
  --white: #ffffff;
  --error: #c0392b;
  --success: #1f8a5b;

  --font-display: 'Outfit', system-ui, sans-serif;
  --font-body:    'Nunito Sans', system-ui, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);

  --radius-input: 12px;
  --radius-card:  20px;

  --shadow-card:
    0 24px 64px rgba(50,50,49,0.16),
    0 6px 18px rgba(50,50,49,0.10),
    0 1px 3px rgba(50,50,49,0.06),
    inset 0 1px 0 rgba(255,255,255,0.85);
  --shadow-sm:
    0 4px 12px rgba(50,50,49,0.08),
    0 1px 2px rgba(50,50,49,0.06);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg-light);
  color: var(--bg-darker);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* Noise overlay — film grain */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: 9999; pointer-events: none;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

/* ── Theme: dark (estádio) ─────────────────────────────────── */
body.theme-dark {
  background: #0d1b14;
  color: #f4f1e4;
}
body.theme-dark .glass-card {
  background: rgba(20, 38, 28, 0.55);
  border: 1px solid rgba(254,221,0,0.10);
  color: #f4f1e4;
}
body.theme-dark .glass-input {
  background: rgba(255,255,244,0.06);
  border: 1px solid rgba(255,255,244,0.14);
  color: #f4f1e4;
}
body.theme-dark .glass-input::placeholder { color: rgba(244,241,228,0.45); }
body.theme-dark .glass-input:focus {
  border-color: var(--copa-yellow);
  box-shadow: 0 0 0 3px rgba(254,221,0,0.18);
}
body.theme-dark .label,
body.theme-dark .text-muted { color: rgba(244,241,228,0.65); }
body.theme-dark h1, body.theme-dark h2, body.theme-dark h3, body.theme-dark h4,
body.theme-dark p { color: #f4f1e4; }
body.theme-dark .summary-row { color: rgba(244,241,228,0.75); }
body.theme-dark .field-divider { background: rgba(255,255,244,0.08); }
body.theme-dark .qty-btn { background: rgba(255,255,244,0.06); color: #f4f1e4; border-color: rgba(255,255,244,0.14); }
body.theme-dark .qty-btn:hover:not(:disabled) { background: rgba(254,221,0,0.18); border-color: var(--copa-yellow); }
body.theme-dark .size-row-card { background: rgba(255,255,244,0.04); border: 1px solid rgba(255,255,244,0.08); }
body.theme-dark .size-row-card.has-qty { background: rgba(0,151,57,0.14); border-color: rgba(0,151,57,0.4); }
body.theme-dark .delivery-card { background: rgba(255,255,244,0.04); border: 1px solid rgba(255,255,244,0.14); color: #f4f1e4; }
body.theme-dark .delivery-card.selected { background: rgba(0,151,57,0.18); border-color: var(--copa-green); }
body.theme-dark .size-table { color: #f4f1e4; }
body.theme-dark .size-table thead { background: rgba(254,221,0,0.10); }
body.theme-dark .size-table tbody tr:nth-child(even) { background: rgba(255,255,244,0.03); }
body.theme-dark .countdown-tile { background: rgba(0,0,0,0.35); border-color: rgba(254,221,0,0.20); color: var(--copa-yellow); }

/* ─────────────────────────────────────────────────────────────
   TYPOGRAPHY
   ───────────────────────────────────────────────────────────── */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  color: var(--bg-darker);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.01em;
}

p {
  font-family: var(--font-body);
  line-height: 1.7;
}

.label {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--bg-dark);
}

.text-muted { color: var(--bg-dark); }

::selection { background: rgba(0,151,57,0.20); color: var(--bg-darker); }

/* ─────────────────────────────────────────────────────────────
   LAYOUT WRAPPER
   ───────────────────────────────────────────────────────────── */

.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
}
@media (min-width: 768px) {
  .container { padding: 0 32px; }
}

section { position: relative; }

/* ─────────────────────────────────────────────────────────────
   GLASS
   ───────────────────────────────────────────────────────────── */

.glass-card {
  background: rgba(255, 255, 244, 0.65);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}

.glass-input {
  background: rgba(255, 255, 244, 0.55);
  backdrop-filter: blur(10px) saturate(150%);
  -webkit-backdrop-filter: blur(10px) saturate(150%);
  border: 1px solid rgba(50,50,49,0.10);
  border-radius: var(--radius-input);
  padding: 12px 14px;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--bg-darker);
  width: 100%;
  transition: border-color 200ms var(--ease), box-shadow 200ms var(--ease), background 200ms var(--ease);
  outline: none;
}
.glass-input::placeholder { color: rgba(50,50,49,0.40); }
.glass-input:hover { border-color: rgba(50,50,49,0.18); }
.glass-input:focus {
  border-color: var(--copa-green);
  box-shadow: 0 0 0 3px rgba(0,151,57,0.16);
  background: rgba(255,255,244,0.85);
}
.glass-input[aria-invalid="true"] {
  border-color: var(--error);
  box-shadow: 0 0 0 3px rgba(192,57,43,0.10);
}
.glass-input[readonly] { background: rgba(50,50,49,0.04); color: var(--bg-dark); cursor: default; }

/* ─────────────────────────────────────────────────────────────
   BUTTONS
   ───────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  padding: 14px 28px;
  border-radius: 14px;
  border: none;
  cursor: pointer;
  transition: transform 200ms var(--ease), box-shadow 200ms var(--ease), opacity 200ms var(--ease);
  text-decoration: none;
  white-space: nowrap;
}
.btn:disabled { opacity: 0.45; cursor: not-allowed; }

.btn-primary {
  background: linear-gradient(135deg, var(--copa-green) 0%, var(--copa-green-deep) 100%);
  color: #fff;
  box-shadow:
    0 4px 16px rgba(0,151,57,0.32),
    0 2px 4px rgba(0,0,0,0.08),
    inset 0 1px 0 rgba(255,255,255,0.25);
}
.btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow:
    0 8px 28px rgba(0,151,57,0.45),
    0 4px 8px rgba(0,0,0,0.10),
    inset 0 1px 0 rgba(255,255,255,0.30);
}
.btn-primary:active:not(:disabled) { transform: translateY(0); }

.btn-copper {
  background: linear-gradient(135deg, var(--brand-copper), var(--brand-amber));
  color: #fff;
  box-shadow:
    0 4px 16px rgba(197,118,42,0.32),
    inset 0 1px 0 rgba(255,255,255,0.25);
}
.btn-copper:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(197,118,42,0.45), inset 0 1px 0 rgba(255,255,255,0.30);
}

.btn-ghost {
  background: transparent;
  color: var(--bg-darker);
  border: 1.5px solid rgba(50,50,49,0.18);
}
.btn-ghost:hover:not(:disabled) { border-color: var(--bg-darker); background: rgba(50,50,49,0.04); }
body.theme-dark .btn-ghost { color: #f4f1e4; border-color: rgba(255,255,244,0.25); }
body.theme-dark .btn-ghost:hover:not(:disabled) { border-color: #f4f1e4; background: rgba(255,255,244,0.06); }

.btn-block { width: 100%; }

/* ─────────────────────────────────────────────────────────────
   PILL / BADGE
   ───────────────────────────────────────────────────────────── */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.badge-copa {
  background: rgba(0,151,57,0.10);
  color: var(--copa-green-deep);
  border: 1px solid rgba(0,151,57,0.25);
}
body.theme-dark .badge-copa {
  background: rgba(254,221,0,0.12);
  color: var(--copa-yellow);
  border-color: rgba(254,221,0,0.30);
}

.badge-gold {
  background: linear-gradient(135deg, var(--copa-yellow), #ffc800);
  color: var(--bg-darker);
  border: 1px solid rgba(0,0,0,0.05);
}

/* gradient underline */
.gradient-line {
  height: 3px;
  width: 64px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--copa-green), var(--copa-yellow), var(--brand-copper));
}

/* ─────────────────────────────────────────────────────────────
   FORM FIELDS
   ───────────────────────────────────────────────────────────── */

.field { display: flex; flex-direction: column; gap: 6px; }
.field label {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--bg-dark);
}
body.theme-dark .field label { color: rgba(244,241,228,0.65); }

.field-error {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--error);
  display: flex;
  align-items: center;
  gap: 6px;
}
body.theme-dark .field-error { color: #ff8a7a; }

.field-skeleton {
  height: 46px;
  border-radius: var(--radius-input);
  background: linear-gradient(90deg, rgba(50,50,49,0.06) 0%, rgba(50,50,49,0.12) 50%, rgba(50,50,49,0.06) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.4s linear infinite;
}
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ─────────────────────────────────────────────────────────────
   ANIMATIONS
   ───────────────────────────────────────────────────────────── */

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp 600ms var(--ease) both; }
.fade-up-delay-1 { animation: fadeUp 600ms var(--ease) both; animation-delay: 80ms; }
.fade-up-delay-2 { animation: fadeUp 600ms var(--ease) both; animation-delay: 160ms; }
.fade-up-delay-3 { animation: fadeUp 600ms var(--ease) both; animation-delay: 240ms; }

@keyframes spin { to { transform: rotate(360deg); } }
.spinner {
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  display: inline-block;
}

@keyframes pulseDot {
  0%, 100% { opacity: 0.4; transform: scale(0.9); }
  50%      { opacity: 1; transform: scale(1.1); }
}

/* ─────────────────────────────────────────────────────────────
   TOAST
   ───────────────────────────────────────────────────────────── */

.toast-stack {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
  max-width: 360px;
}
.toast {
  pointer-events: auto;
  padding: 14px 18px;
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--shadow-card);
  font-family: var(--font-body);
  font-size: 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  animation: toastIn 350ms var(--ease) both;
}
.toast-error { border-left: 4px solid var(--error); }
.toast-success { border-left: 4px solid var(--success); }
@keyframes toastIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

/* ─────────────────────────────────────────────────────────────
   CTA SCROLL ANCHORS — soft scroll padding for sticky nav
   ───────────────────────────────────────────────────────────── */

#formulario { scroll-margin-top: 80px; }
#galeria, #medidas, #preco { scroll-margin-top: 80px; }
