/*
 * Landing pública de PaseGool.
 * Valores tomados de lib/core/design/app_colors.dart, app_tokens.dart y
 * app_typography.dart ("Petróleo de cancha"). Antes de cambiar un color o un
 * radio aquí, verifica el valor vigente en esos archivos (ver
 * docs/ai/design-system.md → «Regla de oro»).
 *
 * /resultados/ sigue usando styles.css; esta hoja solo la carga la portada y
 * las páginas /seguridad/ e /instalar/.
 */

@font-face { font-family: "Inter"; font-weight: 400; font-display: swap; src: url("/app/assets/assets/fonts/Inter-Regular.ttf") format("truetype"); }
@font-face { font-family: "Inter"; font-weight: 500; font-display: swap; src: url("/app/assets/assets/fonts/Inter-Medium.ttf") format("truetype"); }
@font-face { font-family: "Inter"; font-weight: 600; font-display: swap; src: url("/app/assets/assets/fonts/Inter-SemiBold.ttf") format("truetype"); }
@font-face { font-family: "Inter"; font-weight: 700; font-display: swap; src: url("/app/assets/assets/fonts/Inter-Bold.ttf") format("truetype"); }
@font-face { font-family: "Inter"; font-weight: 800; font-display: swap; src: url("/app/assets/assets/fonts/Inter-ExtraBold.ttf") format("truetype"); }

:root {
  color-scheme: light;

  /* Marca (AppColors.brand*) */
  --brand: #0e5251;
  --brand-light: #17766f;
  --brand-dark: #0a3837;
  --brand-on-dark: #4fa69c;
  --on-brand-on-dark: #06231f; /* ShellTheme petróleo onPrimaryDark */
  --brand-soft: #dceae8; /* ShellTheme petróleo soft */

  /* Superficies claras */
  --canvas: #f4f7f6;
  --surface: #ffffff;
  --surface-alt: #edf2f1;
  --surface-sunken: #e3eae8;
  --border: #d6dedc;
  --border-strong: #bcc7c4;
  --text: #12211f;
  --text-muted: #5b6b65;
  --text-subtle: #7a8a85;

  /* Superficies oscuras (hero, día del partido, CTA final) */
  --dark-canvas: #0c1615;
  --dark-surface: #14201f;
  --dark-surface-alt: #1a2624;
  --dark-border: #26332f;
  --dark-text: #e8efed;
  --dark-text-muted: #9baaa5;

  /* Semánticos */
  --success: #2e8b57;
  --success-on-dark: #5dbe87;
  --success-soft: #e7f2ec;
  --on-success-soft: #1b5638;
  --warning: #c98a2e;
  --warning-soft: #f6e9d3;
  --on-warning-soft: #7a5417;
  --danger: #b23a34;
  --info: #3e6e8e;
  --info-soft: #e9f0f5;
  --on-info-soft: #2c536b;
  --neutral: #5b6b65;

  /* AppRadius */
  --r-inset: 4px;
  --r-control: 6px;
  --r-surface: 10px;

  /* AppShadows (suaves) */
  --shadow-sm: 0 1px 2px rgba(18, 33, 31, 0.06), 0 1px 3px rgba(18, 33, 31, 0.04);
  --shadow-md: 0 8px 24px rgba(18, 33, 31, 0.08);

  /* AppBreakpoints.maxContentWidth y AppGrid */
  --max: 1240px;
  --gutter: 16px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--text);
  background: var(--surface);
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
table { border-collapse: collapse; }

:focus-visible {
  outline: 2px solid var(--brand-on-dark);
  outline-offset: 2px;
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

@media (min-width: 768px) { :root { --gutter: 32px; } }

/* ---------- Botones ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--r-control);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  transition: background 150ms ease, border-color 150ms ease, color 150ms ease;
}
.btn-lg { min-height: 50px; padding: 0 22px; font-size: 16px; }

.btn-primary { color: #fff; background: var(--brand); }
.btn-primary:hover { background: var(--brand-light); }

.btn-outline { color: var(--brand); background: var(--surface); border-color: var(--border-strong); }
.btn-outline:hover { border-color: var(--brand); }

/* Sobre fondo oscuro el primario pasa a brandOnDark (AA sobre canvasDark). */
.hero .btn-primary,
.final-cta .btn-primary { color: var(--on-brand-on-dark); background: var(--brand-on-dark); }
.hero .btn-primary:hover,
.final-cta .btn-primary:hover { background: #63b5ab; }

.btn-ghost-dark { color: var(--dark-text); background: transparent; border-color: rgba(232, 239, 237, 0.35); }
.btn-ghost-dark:hover { border-color: var(--dark-text); }

.actions { display: flex; flex-wrap: wrap; gap: 12px; }

@media (max-width: 479px) {
  .actions .btn { flex: 1 1 100%; }
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--dark-canvas);
  border-bottom: 1px solid var(--dark-border);
  color: var(--dark-text);
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 60px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.3px;
}
.brand img { border-radius: var(--r-control); }

.menu-toggle {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0 11px;
  background: transparent;
  border: 1px solid var(--dark-border);
  border-radius: var(--r-control);
  cursor: pointer;
}
.menu-toggle span { display: block; height: 2px; background: var(--dark-text); border-radius: 2px; transition: transform 150ms ease, opacity 150ms ease; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.main-nav {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  display: none;
  flex-direction: column;
  padding: 8px var(--gutter) 20px;
  background: var(--dark-canvas);
  border-bottom: 1px solid var(--dark-border);
}
.main-nav.is-open { display: flex; }
.main-nav a:not(.btn) {
  padding: 14px 0;
  border-bottom: 1px solid var(--dark-border);
  color: var(--dark-text);
  font-weight: 600;
}
.main-nav .nav-cta { margin-top: 16px; color: var(--on-brand-on-dark); background: var(--brand-on-dark); }

@media (min-width: 900px) {
  .menu-toggle { display: none; }
  .main-nav {
    position: static;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 28px;
    padding: 0;
    background: none;
    border: 0;
  }
  .main-nav a:not(.btn) {
    padding: 0;
    border: 0;
    color: var(--dark-text-muted);
    font-size: 15px;
  }
  .main-nav a:not(.btn):hover { color: var(--dark-text); }
  .main-nav .nav-login { color: var(--dark-text); }
  .main-nav .nav-cta { margin: 0; min-height: 40px; }
}

/* ---------- Hero ---------- */

/*
 * Fotografía: cuando haya una foto real de cancha local (no estadio de élite),
 * guárdala en landing/assets/fotos/ y asígnala aquí, p. ej.
 *   --hero-photo: url("./assets/fotos/cancha-tarde.jpg");
 * Mientras tanto se dibuja una cancha con líneas sobre césped oscuro.
 */
.hero {
  --hero-photo: none;
  position: relative;
  overflow: hidden;
  color: var(--dark-text);
  background-color: var(--dark-canvas);
  background-image:
    linear-gradient(180deg, rgba(12, 22, 21, 0.55) 0%, rgba(12, 22, 21, 0.9) 100%),
    var(--hero-photo),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 800' preserveAspectRatio='xMidYMid slice'%3E%3Cg fill='%23112624'%3E%3Crect width='1200' height='800'/%3E%3Crect x='0' width='120' height='800' fill='%230f2221'/%3E%3Crect x='240' width='120' height='800' fill='%230f2221'/%3E%3Crect x='480' width='120' height='800' fill='%230f2221'/%3E%3Crect x='720' width='120' height='800' fill='%230f2221'/%3E%3Crect x='960' width='120' height='800' fill='%230f2221'/%3E%3C/g%3E%3Cg fill='none' stroke='%234fa69c' stroke-opacity='.22' stroke-width='3'%3E%3Crect x='60' y='60' width='1080' height='680'/%3E%3Cline x1='600' y1='60' x2='600' y2='740'/%3E%3Ccircle cx='600' cy='400' r='110'/%3E%3Crect x='60' y='230' width='170' height='340'/%3E%3Crect x='970' y='230' width='170' height='340'/%3E%3C/g%3E%3C/svg%3E");
  background-size: cover, cover, cover;
  background-position: center;
}

.hero-grid {
  display: grid;
  gap: 40px;
  padding-top: 48px;
  padding-bottom: 56px;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--dark-text-muted);
  font-size: 14px;
  font-weight: 600;
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success-on-dark);
  box-shadow: 0 0 0 4px rgba(93, 190, 135, 0.18);
}

.hero h1 {
  font-size: clamp(38px, 10.5vw, 68px);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.03em;
  max-width: 12ch;
}

.lead {
  margin: 18px 0 28px;
  max-width: 34ch;
  color: var(--dark-text-muted);
  font-size: clamp(17px, 4.4vw, 20px);
}

.guarantees {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin-top: 24px;
  font-size: 14px;
  font-weight: 600;
  color: var(--dark-text);
}
.guarantees li { display: inline-flex; align-items: center; gap: 6px; }
.guarantees li::before { content: "✓"; color: var(--success-on-dark); font-weight: 800; }

.hero-visual { display: flex; justify-content: center; }

@media (min-width: 900px) {
  .hero-grid {
    grid-template-columns: 1.15fr 0.85fr;
    align-items: center;
    padding-top: 80px;
    padding-bottom: 88px;
  }
}

/* ---------- Mockups de la app ---------- */

.phone {
  width: 100%;
  max-width: 300px;
  padding: 10px;
  background: #050b0a;
  border: 1px solid #2c3a37;
  border-radius: 34px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
}
.phone-hero { max-width: 320px; }
.phone > .app-bar { border-radius: 24px 24px 0 0; }
.phone > .app-body { border-radius: 0 0 24px 24px; }
.phone-notch { width: 84px; height: 18px; margin: 0 auto -4px; background: #050b0a; border-radius: 0 0 12px 12px; position: relative; z-index: 1; }
.phone-hero .app-bar { border-radius: 24px 24px 0 0; padding-top: 18px; }
.phone-hero .app-body { border-radius: 0 0 24px 24px; }

.app-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 14px 14px 12px;
  color: #fff;
  background: var(--brand);
}
.app-bar-title { font-size: 14px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.app-body {
  display: grid;
  gap: 10px;
  padding: 12px;
  min-height: 300px;
  align-content: start;
  color: var(--text);
  background: var(--canvas);
}

.app-section {
  margin-top: 4px;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.chip-live { color: #fff; background: #1f6b41; }
.chip-live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #fff; }
.chip-ok { color: var(--on-success-soft); background: var(--success-soft); }
.chip-warn { color: var(--on-warning-soft); background: var(--warning-soft); }
.chip-info { color: var(--on-info-soft); background: var(--info-soft); }
.chip-done { color: var(--text); background: var(--surface); }

.match-card {
  padding: 14px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-surface);
}
.match-meta { color: var(--text-muted); font-size: 11px; font-weight: 600; text-align: center; }
.scoreline {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 6px;
  margin: 12px 0 8px;
}
.team { display: grid; justify-items: center; gap: 6px; font-size: 13px; font-weight: 700; text-align: center; }
.score { font-size: 30px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.score i { font-style: normal; color: var(--text-subtle); }
.match-clock { color: #1f6b41; font-size: 12px; font-weight: 700; text-align: center; }

.crest {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 50% 50% 46% 46% / 40% 40% 60% 60%;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.02em;
}
.c1 { background: var(--brand); }
.c2 { background: var(--info); }
.c3 { background: var(--danger); }
.c4 { background: #9c6a22; }
.c5 { background: #455a64; }

.mini-table {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-surface);
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.mini-table th { padding: 7px 8px; color: var(--text-muted); font-weight: 600; text-align: left; background: var(--surface-alt); }
.mini-table td { padding: 7px 8px; border-top: 1px solid var(--border); }
.mini-table td:first-child, .mini-table th:first-child { width: 22px; color: var(--text-muted); }
.mini-table td:last-child { font-weight: 800; text-align: right; }
.mini-table th:last-child { text-align: right; }
.mini-table tr.up td { background: var(--success-soft); }

/* ---------- Secciones genéricas ---------- */

.section { padding: 64px 0; }
@media (min-width: 1024px) { .section { padding: 96px 0; } }

.section-title {
  max-width: 22ch;
  font-size: clamp(28px, 7vw, 44px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.section-title.on-dark { color: var(--dark-text); }
.section-lead { margin: 16px 0 24px; max-width: 46ch; color: var(--text-muted); font-size: 18px; }

/* ---------- Problema ---------- */

.problem { background: var(--surface); }
.pain-list {
  display: grid;
  gap: 0;
  margin-top: 32px;
  counter-reset: pain;
  border-top: 1px solid var(--border);
}
.pain-list li {
  position: relative;
  padding: 20px 0 20px 48px;
  border-bottom: 1px solid var(--border);
  counter-increment: pain;
}
.pain-list li::before {
  content: "0" counter(pain);
  position: absolute;
  left: 0;
  top: 20px;
  color: var(--danger);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.pain-list h3 { font-size: 19px; font-weight: 700; }
.pain-list p { margin-top: 4px; color: var(--text-muted); }

@media (min-width: 768px) {
  .pain-list { grid-template-columns: repeat(3, 1fr); gap: 32px; border-top: 0; }
  .pain-list li { padding: 20px 0 0; border-bottom: 0; border-top: 3px solid var(--text); }
  .pain-list li::before { position: static; display: block; margin-bottom: 10px; }
}

/* ---------- Cómo funciona (flujo) ---------- */

.flow-section { background: var(--canvas); }
.flow { display: grid; margin-top: 36px; }
.flow li {
  position: relative;
  display: grid;
  grid-template-columns: 44px 1fr;
  column-gap: 16px;
  padding-bottom: 28px;
}
.flow li:last-child { padding-bottom: 0; }
/* Línea que une los pasos: el flujo se lee como un recorrido, no como tarjetas. */
.flow li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 21px;
  top: 44px;
  bottom: 0;
  width: 2px;
  background: var(--brand);
  opacity: 0.35;
}
.flow-step {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  color: #fff;
  background: var(--brand);
  border-radius: 50%;
  font-weight: 800;
}
.flow li:last-child .flow-step { background: var(--success); }
.flow h3 { align-self: end; font-size: 20px; font-weight: 800; }
.flow p { color: var(--text-muted); }

@media (min-width: 768px) {
  .flow { grid-template-columns: repeat(4, 1fr); gap: 24px; }
  .flow li { grid-template-columns: 1fr; row-gap: 10px; padding: 0; }
  .flow-step { grid-row: auto; }
  .flow h3 { margin-top: 8px; }
  .flow li:not(:last-child)::after {
    left: 52px;
    right: -20px;
    top: 21px;
    bottom: auto;
    width: auto;
    height: 2px;
  }
}

/* ---------- Día del partido ---------- */

.matchday { background: var(--dark-canvas); }

.phones-row {
  display: flex;
  gap: 16px;
  margin: 36px calc(var(--gutter) * -1) 0;
  padding: 0 var(--gutter) 8px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gutter);
  scrollbar-width: thin;
}
.phone-step {
  flex: 0 0 min(80%, 280px);
  margin: 0;
  scroll-snap-align: start;
}
.phone-step figcaption {
  margin-bottom: 14px;
  color: var(--dark-text-muted);
  font-size: 15px;
  font-weight: 600;
}
.phone-step figcaption span {
  display: block;
  color: var(--brand-on-dark);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.phone-sm { max-width: none; border-radius: 28px; }
.phone-sm > .app-bar { border-radius: 20px 20px 0 0; }
.phone-sm > .app-body { border-radius: 0 0 20px 20px; min-height: 290px; }

@media (min-width: 900px) {
  .phones-row { overflow: visible; margin: 48px 0 0; padding: 0; gap: 32px; }
  .phone-step { flex: 1 1 0; }
}

.stat-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.stat-row div { padding: 10px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-surface); }
.stat-row strong { display: block; font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums; }
.stat-row span { color: var(--text-muted); font-size: 12px; }

.player-list { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-surface); }
.player-list li { display: flex; align-items: center; gap: 8px; padding: 8px 10px; font-size: 13px; font-weight: 600; }
.player-list li + li { border-top: 1px solid var(--border); }
.player-list .chip { margin-left: auto; }
.avatar { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--surface-sunken); color: var(--text-muted); font-size: 10px; font-weight: 800; }

.carnet { display: flex; align-items: center; gap: 10px; padding: 10px; color: #fff; background: var(--brand-dark); border-radius: var(--r-surface); }
.carnet strong { display: block; font-size: 13px; }
.carnet span { color: #b9d3cf; font-size: 12px; }
.qr {
  flex: none;
  width: 44px;
  height: 44px;
  border: 4px solid #fff;
  border-radius: var(--r-inset);
  background:
    conic-gradient(from 90deg at 50% 50%, #12211f 25%, #fff 0 50%, #12211f 0 75%, #fff 0) 0 0 / 12px 12px,
    #fff;
}

.scoreboard {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px;
  color: #fff;
  background: var(--text);
  border-radius: var(--r-surface);
  font-weight: 700;
  font-size: 13px;
}
.scoreboard strong { font-size: 28px; font-weight: 800; font-variant-numeric: tabular-nums; }

.event-list { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-surface); }
.event-list li { display: flex; align-items: center; gap: 8px; padding: 8px 10px; font-size: 12.5px; font-weight: 600; }
.event-list li + li { border-top: 1px solid var(--border); }
.event-list em { margin-left: auto; color: var(--text-muted); font-style: normal; font-variant-numeric: tabular-nums; }
.ev { flex: none; width: 10px; height: 14px; border-radius: 2px; }
.ev-goal { width: 12px; height: 12px; border-radius: 50%; background: var(--success); }
.ev-yellow { background: #e0a84f; }
.ev-note { background: var(--info); }

.event-buttons { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.event-buttons span { padding: 9px 4px; color: var(--brand); background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--r-control); font-size: 12px; font-weight: 700; text-align: center; }
.event-buttons span:first-child { color: #fff; background: var(--brand); border-color: var(--brand); }

.acta-row { display: flex; align-items: center; justify-content: space-between; padding: 10px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-surface); font-size: 13px; font-weight: 700; }

/* ---------- Demo del campeonato ---------- */

.demo { background: var(--surface); }
.demo-app {
  margin-top: 32px;
  background: var(--canvas);
  border: 1px solid var(--border);
  border-radius: var(--r-surface);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}
.demo-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 16px 0;
  color: #fff;
  background: var(--brand);
}
.demo-kicker { color: #b9d3cf; font-size: 13px; font-weight: 600; }
.demo-head h3 { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; }
.tabs { display: flex; gap: 4px; }
.tabs button {
  min-height: 44px;
  padding: 0 16px;
  color: #b9d3cf;
  background: transparent;
  border: 0;
  border-bottom: 3px solid transparent;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.tabs button[aria-selected="true"] { color: #fff; border-bottom-color: #fff; }

.demo-panel { display: grid; gap: 20px; padding: 20px 16px; }
.demo-panel[hidden] { display: none; }
.demo-col { display: grid; gap: 10px; align-content: start; min-width: 0; }

.fixture { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-surface); }
.fixture li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2px 12px;
  padding: 12px 14px;
}
.fixture li + li { border-top: 1px solid var(--border); }
.fixture .time { grid-row: span 2; align-self: center; color: var(--brand); font-weight: 800; font-variant-numeric: tabular-nums; }
.fixture .teams { font-weight: 700; }
.fixture .teams i { color: var(--text-subtle); font-style: normal; font-weight: 500; }
.fixture .where { color: var(--text-muted); font-size: 13px; }

.positions {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-surface);
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.positions th { padding: 10px; color: var(--text-muted); background: var(--surface-alt); font-size: 12px; font-weight: 600; text-align: right; }
.positions td { padding: 8px 10px; border-top: 1px solid var(--border); text-align: right; }
.positions th:nth-child(-n + 2), .positions td:nth-child(-n + 2) { text-align: left; }
.positions td:first-child { width: 28px; color: var(--text-muted); font-weight: 700; }
.positions td:nth-child(2) { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.positions td:last-child { font-weight: 800; }
.positions tbody tr:first-child td:first-child { color: var(--brand); }
.positions .crest { width: 26px; height: 26px; font-size: 9px; }

@media (max-width: 379px) {
  .positions th:nth-child(4), .positions td:nth-child(4) { display: none; }
}

.demo-foot { padding: 0 16px 20px; }
@media (max-width: 479px) { .demo-foot .btn { width: 100%; } }

@media (min-width: 768px) {
  .demo-head { padding: 24px 24px 0; }
  .demo-panel { grid-template-columns: 1fr 1.2fr; gap: 28px; padding: 24px; }
  .demo-foot { padding: 0 24px 24px; }
}

/* ---------- Flexibilidad ---------- */

.flex-section { background: var(--canvas); }
.flex-grid { display: grid; gap: 32px; }
.league-types { display: flex; flex-wrap: wrap; gap: 10px; align-content: center; }
.league-types li {
  padding: 12px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-weight: 700;
}
.league-types li:nth-child(odd) { border-color: var(--brand); color: var(--brand); }

@media (min-width: 900px) {
  .flex-grid { grid-template-columns: 1.1fr 0.9fr; align-items: center; gap: 64px; }
}

/* ---------- Roles ---------- */

.roles-section { background: var(--surface); }
.roles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px 20px; margin-top: 32px; }
.roles li { padding-top: 14px; border-top: 3px solid var(--brand); }
.roles li:nth-child(4) { border-top-color: var(--text-subtle); }
.roles h3 { font-size: 18px; font-weight: 800; }
.roles p { margin-top: 4px; color: var(--text-muted); font-size: 15px; }
@media (max-width: 359px) { .roles { grid-template-columns: 1fr; } }
@media (min-width: 900px) { .roles { grid-template-columns: repeat(4, 1fr); gap: 32px; } }

/* ---------- Seguridad ---------- */

.security { background: var(--canvas); border-top: 1px solid var(--border); }
.security .section-title { font-size: clamp(24px, 5.5vw, 32px); }
.security-grid { display: grid; gap: 24px; }
.security-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.security-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-surface);
  font-size: 15px;
  font-weight: 700;
}
.security-grid > .btn { justify-self: start; }
@media (max-width: 359px) { .security-list { grid-template-columns: 1fr; } }
@media (min-width: 1024px) {
  .security-grid { grid-template-columns: 1fr 1.4fr auto; align-items: center; gap: 40px; }
  .security-list { grid-template-columns: repeat(4, auto); }
}

/* ---------- CTA final ---------- */

.final-cta {
  --final-photo: none; /* Foto nocturna de cancha local cuando exista. */
  padding: 80px 0;
  color: var(--dark-text);
  text-align: center;
  background-color: var(--dark-canvas);
  background-image:
    linear-gradient(180deg, rgba(12, 22, 21, 0.7), rgba(12, 22, 21, 0.92)),
    var(--final-photo),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 500' preserveAspectRatio='xMidYMid slice'%3E%3Crect width='1200' height='500' fill='%23102220'/%3E%3Cg fill='none' stroke='%234fa69c' stroke-opacity='.18' stroke-width='3'%3E%3Cline x1='600' y1='0' x2='600' y2='500'/%3E%3Ccircle cx='600' cy='250' r='110'/%3E%3C/g%3E%3C/svg%3E");
  background-size: cover;
  background-position: center;
}
.final-cta h2 { font-size: clamp(32px, 8vw, 54px); font-weight: 800; line-height: 1.05; letter-spacing: -0.03em; }
.final-cta p { margin: 16px auto 28px; max-width: 30ch; color: var(--dark-text-muted); font-size: 19px; }
.final-cta .actions { justify-content: center; }
.final-cta .fine { margin: 20px auto 0; font-size: 14px; }
@media (min-width: 1024px) { .final-cta { padding: 120px 0; } }

/* ---------- Footer ---------- */

.site-footer { padding: 36px 0 96px; color: var(--dark-text-muted); background: var(--dark-canvas); border-top: 1px solid var(--dark-border); }
.footer-row { display: grid; gap: 20px; }
.site-footer .brand { color: var(--dark-text); }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 12px 22px; font-size: 14px; font-weight: 600; }
.site-footer nav a { padding: 4px 0; }
.site-footer nav a:hover { color: var(--dark-text); }
@media (min-width: 900px) {
  .site-footer { padding-bottom: 36px; }
  .footer-row { grid-template-columns: auto 1fr; align-items: center; }
  .site-footer nav { justify-content: flex-end; }
}

/* ---------- Aviso de cookies ---------- */

.cookie-banner {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 40;
  display: grid;
  gap: 12px;
  max-width: 560px;
  margin: 0 auto;
  padding: 14px 16px;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-surface);
  box-shadow: var(--shadow-md);
  font-size: 14px;
}
.cookie-banner.is-hidden { display: none; }
.cookie-actions { display: flex; justify-content: flex-end; gap: 10px; }
.cookie-actions a,
.cookie-actions button {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: var(--r-control);
  font: inherit;
  font-weight: 700;
}
.cookie-actions a { color: var(--brand); }
.cookie-actions button { color: #fff; background: var(--brand); border: 0; cursor: pointer; }

/* ---------- Páginas secundarias (/seguridad/, /instalar/) ---------- */

.page { padding: 48px 0 72px; background: var(--surface); }
.page h1 { font-size: clamp(30px, 7vw, 44px); font-weight: 800; line-height: 1.1; letter-spacing: -0.02em; }
.page h2 { margin-top: 40px; font-size: 22px; font-weight: 800; }
.page p, .page li { color: var(--text-muted); }
.page .prose { max-width: 70ch; }
.page .prose > p { margin-top: 14px; }
.info-list { display: grid; gap: 12px; margin-top: 16px; }
.info-list li { padding: 14px 16px; background: var(--canvas); border: 1px solid var(--border); border-radius: var(--r-surface); }
.info-list strong { display: block; color: var(--text); }
.page details { margin-top: 12px; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--r-surface); }
.page summary { color: var(--text); font-weight: 700; cursor: pointer; }
.page details p { margin-top: 8px; }
.page .actions { margin-top: 24px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* ---------- Descarga del APK (beta fuera de Play Store) ---------- */

.apk-line {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin-top: 16px;
  font-size: 15px;
  font-weight: 700;
}
.apk-line a { color: var(--brand-on-dark); text-decoration: underline; text-underline-offset: 3px; }
.apk-line a + a { color: var(--dark-text-muted); font-weight: 600; }
.final-cta .apk-line { justify-content: center; max-width: none; margin: 12px auto 0; font-size: 15px; }
.main-nav .nav-apk { color: var(--brand-on-dark) !important; }
@media (min-width: 900px) { .main-nav .nav-apk { display: none; } }
