/* ==========================================================================
   NGM FUTSAL SCOREBOARD DESIGN SYSTEM
   Neutral Monochrome Base (Carbon Black #09090B to Light Gray #F4F4F5)
   Preserved Time & Highlight Accents (#FFD21F Yellow, #35D07F Green, #D12828 Red)
   Typography: Figtree (UI) + Barlow Condensed (Tabular Digits)
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@500;600;700&family=Figtree:wght@400;500;600;700&display=swap');

:root {
  color-scheme: dark;

  /* Neutral Monochrome Scale (Black to Light Gray — zero teal/aqua tint) */
  --neutral-950: #09090B;
  --neutral-900: #121215;
  --neutral-800: #1C1C21;
  --neutral-700: #27272E;
  --neutral-600: #383842;
  --neutral-400: #71717A;
  --mist: #A1A1AA;
  --foam: #F4F4F5;

  /* Semantic Colors */
  --color-bg-deep: var(--neutral-950);
  --color-bg: var(--neutral-900);
  --color-surface: var(--neutral-800);
  --color-surface-raised: var(--neutral-700);
  --color-stopped: var(--neutral-700);
  --color-line: var(--neutral-600);
  --color-line-strong: var(--neutral-400);
  --color-text: var(--foam);
  --color-text-muted: var(--mist);
  --color-on-stopped: var(--foam);
  --color-scrim: rgba(9, 9, 11, 0.84);

  /* NGM Official Brand Blue / Cyan Accents (High-contrast with white button text) */
  --ngm-blue: #489BB5;
  --ngm-blue-light: #64C8E4;
  --ngm-blue-dark: #2B66AB;
  --ngm-gradient: linear-gradient(135deg, #2B66AB 0%, #489BB5 100%);
  --ball: var(--ngm-blue);
  --ball-light: var(--ngm-blue-light);
  --ball-dark: var(--ngm-blue-dark);
  --ball-ink: #FFFFFF;
  --color-brand: var(--ngm-blue);
  --color-brand-hover: var(--ngm-blue-light);
  --color-brand-active: var(--ngm-blue-dark);
  --color-on-brand: #FFFFFF;
  --brand-text-shadow: 0 1px 2px rgba(0, 0, 0, 0.32);
  --color-possession: var(--ngm-blue-light);
  --color-focus: var(--ngm-blue-light);

  /* Team Default Colors */
  --team-white: #FFFFFF;
  --color-team-white-edge: #FFFFFF;
  --color-team-white-text: #F4F4F5;
  --color-on-team-white: #09090B;

  --team-blue: #2064DC;
  --team-blue-light: #9CC4FF;
  --color-team-blue-edge: #9CC4FF;
  --color-team-blue-text: #9CC4FF;
  --color-on-team-blue: #FFFFFF;

  /* Status & Alerts (Blinded Referee Colors - Never Changed by Theme) */
  --alert-yellow: #FFD21F;
  --alert-yellow-ink: #09090B;
  --alert-red: #D12828;
  --alert-red-light: #FF9B91;
  --color-alert: var(--alert-red);
  --color-alert-text: var(--alert-red-light);
  --color-on-alert: #FFFFFF;

  --go-green: #35D07F;
  --color-running: var(--go-green);
  --color-running-text: var(--go-green);
  --color-on-running: var(--neutral-950);

  /* Typography */
  --font-ui: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-score: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;

  /* Radii & Motion */
  --radius-digit: 0.25rem;
  --radius-control: 0.625rem;
  --radius-panel: 1rem;
  --radius-pill: 62.5rem;
  --shadow-raised: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.5);
  --shadow-overlay: 0 1rem 3rem rgba(0, 0, 0, 0.7);
  --motion-press: 90ms;
  --motion-base: 160ms;
  --motion-slow: 280ms;
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* Light Theme (?tema=claro) */
[data-theme="light"] {
  --color-bg-deep: #FFFFFF;
  --color-bg: #F4F4F5;
  --color-surface: #FFFFFF;
  --color-surface-raised: #E4E4E7;
  --color-stopped: #E4E4E7;
  --color-line: #D4D4D8;
  --color-line-strong: #71717A;
  --color-text: #09090B;
  --color-text-muted: #52525B;
  --color-on-stopped: #09090B;
  --color-team-white-edge: #09090B;
  --color-team-white-text: #09090B;
  --color-team-blue-edge: #1549AD;
  --color-team-blue-text: #1549AD;
  --color-alert-text: #A0181A;
  --color-running-text: #075E33;
}

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

html, body {
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-ui);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Tabular Score & Clock Typography */
.font-score {
  font-family: var(--font-score);
  font-variant-numeric: lining-nums tabular-nums;
  line-height: 1;
  font-weight: 700;
}

.digits-row {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  font-family: var(--font-score);
  font-variant-numeric: lining-nums tabular-nums;
  line-height: 1;
  font-weight: 700;
}

.digit {
  display: inline-block;
  width: 0.54em;
  text-align: center;
}

.digit-sep {
  display: inline-block;
  width: 0.24em;
  text-align: center;
}

/* Keycap Badge [Espaço] [G] [F] */
.kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.45rem;
  height: 1.45rem;
  padding: 0 0.38rem;
  border: 1.5px solid currentColor;
  border-radius: 0.3rem;
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
  opacity: 0.85;
}

/* Indicator Dots (Possession, Fouls, Timeouts) */
.dot {
  display: inline-block;
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  border: 2px solid var(--color-line-strong);
  background: transparent;
  transition: background var(--motion-base) var(--ease-out), border-color var(--motion-base) var(--ease-out);
  flex-shrink: 0;
}

.dot.filled-yellow {
  background: var(--alert-yellow) !important;
  border-color: var(--alert-yellow) !important;
}

.dot.filled-red {
  background: var(--color-alert) !important;
  border-color: var(--color-alert) !important;
}

.dot.filled-white {
  background: var(--foam);
  border-color: var(--foam);
}

.dot.filled-blue {
  background: var(--team-blue-light);
  border-color: var(--team-blue-light);
}

.poss-circle {
  display: inline-block;
  width: 1.15rem;
  height: 1.15rem;
  border-radius: 50%;
  border: 2px solid var(--color-line-strong);
  background: transparent;
  transition: all var(--motion-base) var(--ease-out);
  flex-shrink: 0;
}

.poss-circle.active {
  background: var(--alert-yellow) !important;
  border-color: var(--alert-yellow) !important;
}

.poss-circle.active.expired {
  background: var(--color-alert) !important;
  border-color: var(--color-alert) !important;
}

/* Shirt Number Badge (Futsal Player Number) */
.num-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 0.35rem;
  font-family: var(--font-score);
  font-weight: 700;
  font-size: 0.92rem;
  line-height: 1;
  flex-shrink: 0;
}

.num-chip.white {
  background: var(--team-white);
  color: var(--color-on-team-white);
  border: 1.5px solid var(--team-white);
}

.num-chip.blue {
  background: var(--team-blue);
  color: var(--color-on-team-blue);
  border: 1.5px solid var(--team-blue-light);
}

.num-chip.gk-white {
  background: transparent;
  color: var(--foam);
  border: 2px solid var(--team-white);
}

.num-chip.gk-blue {
  background: transparent;
  color: var(--team-blue-light);
  border: 2px solid var(--team-blue-light);
}

/* Secondary Raised Button (Neutral Grayscale hover) */
.t-btn {
  background: var(--color-surface-raised);
  color: var(--color-text);
  border: 2px solid var(--color-line-strong);
  border-radius: var(--radius-control);
  padding: 0.45rem 0.85rem;
  font-family: var(--font-ui);
  font-size: 0.875rem;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
  transition: background var(--motion-base) var(--ease-out), border-color var(--motion-base) var(--ease-out), transform var(--motion-press);
}

.t-btn:hover {
  background: #32323B;
  border-color: #A1A1AA;
}

.t-btn:active {
  transform: scale(0.985);
}

.t-btn-brand {
  background-color: var(--ngm-blue-dark) !important;
  background-image: var(--ngm-gradient) !important;
  color: var(--color-on-brand) !important;
  border: 2px solid var(--ngm-blue-light) !important;
  font-weight: 700;
  text-shadow: var(--brand-text-shadow, none);
}

.t-btn-brand:hover {
  filter: brightness(1.1);
  border-color: var(--color-brand-hover) !important;
}

/* Official NGM Header Logo */
.ngm-logo-img {
  height: 1.65rem;
  width: auto;
  display: block;
}

/* Crisp Minimalist Vector Icons (SVG) */
.ico-svg {
  width: 1rem;
  height: 1rem;
  stroke: currentColor;
  stroke-width: 1.85;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  flex-shrink: 0;
  display: inline-block;
  vertical-align: middle;
}

