/* ============================================================
   TRIBET CASH POKER · base.css
   Tokens, reset, tipografia, botões e utilitários.
   Cores da marca ficam TODAS nas variáveis abaixo — mude aqui
   e o site inteiro acompanha.
   ============================================================ */

/* ============================================================
   FONTES AUTO-HOSPEDADAS
   Arquivos variáveis (todos os pesos em um só), subset latino.
   Servidas do próprio domínio: sem requisição a fonts.googleapis.com
   nem a fonts.gstatic.com, que bloqueavam a primeira renderização.
   ============================================================ */
@font-face {
  font-family: 'Oswald';
  font-style: normal;
  font-weight: 400 700;          /* faixa da fonte variável */
  font-display: swap;
  src: url('../assets/fonts/oswald-latin-var.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC,
                 U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../assets/fonts/inter-latin-var.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC,
                 U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  /* --- Paleta (extraída da logo) --- */
  --bg:          #0F0B0B;   /* preto-carvão  */
  --bg-2:        #140F0F;   /* bloco alternado */
  --bg-3:        #1A1414;   /* cards / superfícies */
  --wine:        #6E1023;   /* marca */
  --wine-deep:   #4A0C18;   /* marca escura */
  --gold:        #C9A24B;   /* acento */
  --cream:       #F1E9DC;   /* texto */
  --wa:          #25D366;   /* CTA WhatsApp — só em conversão */
  --wa-dark:     #1EBE5A;

  /* --- Derivados --- */
  --text:        var(--cream);
  --text-soft:   rgba(241, 233, 220, .70);
  --text-dim:    rgba(241, 233, 220, .62);  /* .48 reprovava no WCAG AA (4.34:1) */
  --line:        rgba(201, 162, 75, .22);   /* fio dourado 1px */
  --line-soft:   rgba(241, 233, 220, .09);
  --surface:     rgba(241, 233, 220, .035);
  --surface-2:   rgba(241, 233, 220, .06);

  /* --- Forma & profundidade --- */
  --r-sm: 8px;
  --r:    12px;
  --r-lg: 16px;
  --r-pill: 999px;
  --shadow:    0 18px 40px -22px rgba(0, 0, 0, .95);
  --shadow-lg: 0 36px 80px -40px rgba(0, 0, 0, 1);

  /* --- Ritmo --- */
  --wrap: 1160px;
  --gut: clamp(1.25rem, 5vw, 2.5rem);
  --sec-y: clamp(4.5rem, 10vw, 8rem);

  /* --- Tipografia --- */
  --font-display: 'Oswald', 'Arial Narrow', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;

  /* --- Movimento --- */
  --ease: cubic-bezier(.22, .68, .28, 1);
  --t-fast: .18s var(--ease);
  --t: .32s var(--ease);
}

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

* { margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 88px;   /* compensa o header fixo */
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;            /* 16px mínimo */
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* Textura de feltro discretíssima + brilho vinho ao fundo */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: .035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
}

body > * { position: relative; z-index: 1; }

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

button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }

a { color: inherit; text-decoration: none; }

ul, ol { list-style: none; padding: 0; }

table { border-collapse: collapse; width: 100%; }

/* Foco visível e consistente */
:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection { background: var(--wine); color: var(--cream); }

/* ============================================================
   TIPOGRAFIA
   ============================================================ */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: .01em;
  text-transform: uppercase;
}

h3 { font-size: clamp(1.15rem, 2.4vw, 1.35rem); letter-spacing: .02em; }

p { text-wrap: pretty; }

em { font-style: normal; }

/* Números (stakes, horários) sempre alinhados */
.num, .stat__num, .schedule__table td, .schedule__table th {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--font-display);
  font-size: .8125rem;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
}
.eyebrow .ico { width: 16px; height: 16px; }
.eyebrow--light { color: rgba(241, 233, 220, .78); }

.sec-title {
  font-size: clamp(1.85rem, 5.2vw, 3.1rem);
  max-width: 20ch;
  margin-top: .9rem;
  text-wrap: balance;
}

.sec-lead {
  margin-top: 1.15rem;
  max-width: 62ch;
  color: var(--text-soft);
  font-size: clamp(1rem, 1.6vw, 1.0625rem);
}
.sec-lead em { color: var(--cream); font-style: italic; }

.sec-head { margin-bottom: clamp(2.25rem, 5vw, 3.25rem); }

/* ============================================================
   LAYOUT
   ============================================================ */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gut);
}
.wrap--narrow { max-width: 820px; }

.section {
  padding-block: var(--sec-y);
  border-top: 1px solid var(--line);   /* fio dourado entre seções */
}
.section--alt { background: var(--bg-2); }

/* ============================================================
   ÍCONES
   ============================================================ */
.icon-sprite { display: none; }

.ico {
  width: 20px;
  height: 20px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.ico--lg { width: 30px; height: 30px; stroke-width: 1.35; color: var(--gold); }

/* ============================================================
   BOTÕES
   ============================================================ */
.btn {
  --btn-py: .95rem;
  --btn-px: 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .65rem;
  min-height: 48px;                    /* área de toque */
  padding: var(--btn-py) var(--btn-px);
  border-radius: var(--r);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: .045em;
  text-transform: uppercase;
  text-align: center;
  transition: transform var(--t-fast), background-color var(--t-fast),
              border-color var(--t-fast), box-shadow var(--t-fast), color var(--t-fast);
  will-change: transform;
}
.btn:active { transform: translateY(1px); }

/* CTA de conversão — verde WhatsApp, usado apenas aqui */
.btn--wa {
  background: var(--wa);
  color: #06210F;
  box-shadow: 0 14px 30px -16px rgba(37, 211, 102, .75);
}
.btn--wa:hover { background: var(--wa-dark); transform: translateY(-2px); }
.btn--wa .ico { stroke: none; fill: currentColor; }

.btn--ghost {
  border: 1px solid var(--line);
  color: var(--cream);
  background: var(--surface);
}
.btn--ghost:hover {
  border-color: var(--gold);
  background: rgba(201, 162, 75, .08);
  transform: translateY(-2px);
}

.btn--sm  { --btn-py: .6rem; --btn-px: 1rem; font-size: .875rem; border-radius: var(--r-sm); }
/* Some visualmente em telas estreitas, mas continua legível para leitores de
   tela — display:none apagaria o nome acessível do link (falha WCAG). */
.btn__label--hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.btn--lg  { --btn-py: 1.05rem; --btn-px: 1.9rem; font-size: 1.0625rem; }
.btn--xl  { --btn-py: 1.2rem; --btn-px: 2.4rem; font-size: clamp(1.0625rem, 2.4vw, 1.25rem); }

.sec-cta {
  margin-top: clamp(2rem, 4vw, 3rem);
  display: flex;
  justify-content: center;
}
.sec-cta--left { justify-content: flex-start; margin-top: 2rem; }

/* ============================================================
   SELO DE STATUS "MESA RODANDO"
   ============================================================ */
.live {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  margin-top: 1.1rem;
  padding: .5rem 1.05rem .5rem .9rem;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: rgba(15, 11, 11, .6);
  backdrop-filter: blur(6px);
  font-family: var(--font-display);
  font-size: .875rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--cream);
}
.live__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 0 rgba(201, 162, 75, .55);
}

/* Mesa aberta agora: ponto verde pulsante */
.live[data-state="on"] { border-color: rgba(37, 211, 102, .38); }
.live[data-state="on"] .live__dot {
  background: var(--wa);
  animation: pulse 2.1s var(--ease) infinite;
}
.live[data-state="soon"] .live__dot { background: var(--gold); }
.live[data-state="off"]  .live__dot { background: rgba(241, 233, 220, .45); }

@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(37, 211, 102, .6); }
  70%  { box-shadow: 0 0 0 12px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* ============================================================
   ANIMAÇÃO DE ENTRADA (fade-in ao rolar)
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(18px);
}
.reveal.is-in {
  opacity: 1;
  transform: none;
  transition: opacity .7s var(--ease), transform .7s var(--ease);
  transition-delay: var(--d, 0ms);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* ============================================================
   UTILITÁRIOS
   ============================================================ */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  z-index: 200;
  padding: .75rem 1.15rem;
  background: var(--gold);
  color: #14100C;
  border-radius: 0 0 var(--r-sm) var(--r-sm);
  font-weight: 600;
  transition: top var(--t-fast);
}
.skip-link:focus { top: 0; }

.note {
  display: flex;
  align-items: flex-start;
  gap: .7rem;
  margin-top: 1.5rem;
  color: var(--text-dim);
  font-size: .9375rem;
  max-width: 70ch;
}
.note .ico { margin-top: 3px; color: var(--gold); }
