:root {
  --ink: #19213d;
  --muted: #69708b;
  --paper: #fff;
  --canvas: #f7f5ff;
  --purple: #6c3df4;
  --purple-dark: #4d26c8;
  --coral: #ff6a65;
  --pink: #f44ca0;
  --blue: #3186f5;
  --green: #1eb980;
  --gold: #f4b93f;
  --shadow: 0 14px 35px rgba(51, 39, 105, .11);
  --radius: 24px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 10% 6%, rgba(244, 76, 160, .08), transparent 24rem),
    radial-gradient(circle at 92% 18%, rgba(49, 134, 245, .09), transparent 28rem),
    var(--canvas);
  font-family: "DM Sans", sans-serif;
  min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
main { overflow: hidden; }

.site-header {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1240px;
  padding: 0 24px;
  margin: auto;
  position: relative;
  z-index: 20;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-ball {
  display: grid; place-items: center;
  width: 42px; height: 42px; border-radius: 15px;
  background: linear-gradient(145deg, #ffe257, #ff8b5b);
  box-shadow: 0 7px 16px rgba(255, 116, 78, .3);
  transform: rotate(-6deg);
}
.brand b { display: block; font: 700 20px/1 "Fredoka"; color: var(--purple-dark); }
.brand small { color: var(--muted); font-size: 11px; font-weight: 700; letter-spacing: .08em; }
.main-nav { display: flex; align-items: center; gap: 8px; }
.main-nav a { padding: 10px 14px; border-radius: 12px; font-weight: 600; color: #555d78; font-size: 14px; }
.main-nav a:hover, .main-nav a.active { color: var(--purple); background: #ede8ff; }
.main-nav .admin-link { margin-left: 8px; border: 1px solid #ddd6f6; }
.menu-button { display: none; border: 0; background: #ece7ff; color: var(--purple); border-radius: 12px; padding: 8px 11px; font-size: 20px; }

.hero {
  max-width: 1240px;
  margin: 0 auto 26px;
  min-height: 430px;
  padding: 64px 70px;
  border-radius: 34px;
  background:
    radial-gradient(circle at 78% 33%, rgba(255,255,255,.18) 0 4px, transparent 5px),
    radial-gradient(circle at 92% 78%, rgba(255,255,255,.13) 0 7px, transparent 8px),
    linear-gradient(125deg, #5a2de0 0%, #7b3ff1 46%, #cc4eb1 100%);
  color: white;
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 60px;
  align-items: center;
  position: relative;
  overflow: hidden;
  box-shadow: 0 22px 55px rgba(76, 37, 183, .26);
}
.hero::before, .hero::after {
  content: ""; position: absolute; border: 1px solid rgba(255,255,255,.12); border-radius: 50%;
}
.hero::before { width: 440px; height: 440px; right: -120px; top: -230px; }
.hero::after { width: 260px; height: 260px; left: 43%; bottom: -210px; }
.hero-sparkles i { position: absolute; z-index: 1; color: #ffe36d; font-style: normal; animation: twinkle 2.3s ease-in-out infinite; }
.hero-sparkles i:nth-child(1) { right: 4%; top: 38%; font-size: 24px; }
.hero-sparkles i:nth-child(2) { left: 47%; top: 14%; font-size: 18px; animation-delay: .6s; }
.hero-sparkles i:nth-child(3) { right: 43%; bottom: 10%; font-size: 13px; animation-delay: 1.1s; }
@keyframes twinkle { 50% { opacity: .3; transform: scale(.72) rotate(25deg); } }
.eyebrow { display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: .16em; }
.hero .eyebrow { color: #ffdf76; margin-bottom: 13px; }
h1, h2, h3 { font-family: "Fredoka", sans-serif; margin-top: 0; }
.hero h1 { font-size: clamp(43px, 5vw, 68px); line-height: .98; margin-bottom: 18px; letter-spacing: -.03em; }
.hero h1 span { color: #ffd85e; }
.hero-copy > p { max-width: 530px; opacity: .86; line-height: 1.6; }
.hero-actions { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.button {
  display: inline-flex; justify-content: center; align-items: center;
  padding: 13px 19px; border-radius: 14px; border: 0;
  font-weight: 700; cursor: pointer; transition: transform .2s, box-shadow .2s;
}
.button:hover { transform: translateY(-2px); }
.button-primary { background: linear-gradient(135deg, #ffbc3e, #ff7863); color: #3d2458; box-shadow: 0 9px 22px rgba(72, 28, 92, .18); }
.button-ghost { border: 1px solid rgba(255,255,255,.35); color: white; background: rgba(255,255,255,.08); }
.countdown-card {
  background: rgba(255,255,255,.13); border: 1px solid rgba(255,255,255,.24);
  border-radius: 28px; padding: 28px; text-align: center; backdrop-filter: blur(8px);
  position: relative; z-index: 2;
}
.countdown-label { font-size: 10px; letter-spacing: .16em; font-weight: 800; color: #ffe788; }
.countdown { display: flex; justify-content: center; align-items: flex-start; margin: 20px 0 14px; gap: 10px; }
.countdown div { min-width: 66px; }
.countdown strong { display: block; font: 700 42px/1 "Fredoka"; }
.countdown small { display: block; font-size: 10px; margin-top: 6px; opacity: .72; text-transform: uppercase; }
.countdown i { font: normal 700 32px/1 "Fredoka"; opacity: .55; }
.countdown-card p { margin: 0 0 5px; }
.countdown-card > small { opacity: .72; }

.stats-strip {
  max-width: 1050px; margin: -52px auto 52px; position: relative; z-index: 3;
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: white; border-radius: 22px; box-shadow: var(--shadow); padding: 19px;
}
.stats-strip div { display: grid; grid-template-columns: 42px auto; grid-template-rows: auto auto; align-items: center; padding: 4px 25px; border-right: 1px solid #eeeaf8; }
.stats-strip div:last-child { border: 0; }
.stats-strip span { grid-row: 1/3; display: grid; place-items: center; width: 36px; height: 36px; background: #f1ecff; border-radius: 12px; }
.stats-strip strong { font: 700 24px/1 "Fredoka"; }
.stats-strip small { color: var(--muted); font-size: 11px; }

.worldcup2030-banner {
  max-width: 1180px;
  margin: 0 auto 20px;
  padding: 24px 28px;
  border-radius: 28px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 22px;
  align-items: center;
  color: white;
  background:
    radial-gradient(circle at 8% 16%, rgba(255,255,255,.22), transparent 15rem),
    linear-gradient(120deg, #173a8f 0%, #6c3df4 48%, #e35b77 100%);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.worldcup2030-banner::after {
  content: "";
  position: absolute;
  right: -90px;
  top: -110px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.18);
}
.worldcup2030-flags {
  display: grid;
  grid-template-columns: repeat(3, 46px);
  gap: 8px;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
}
.worldcup2030-flags span,
.worldcup2030-flags i {
  display: grid;
  place-items: center;
  min-width: 46px;
  height: 34px;
  border-radius: 11px;
  background: rgba(255,255,255,.16);
  border: 1px solid rgba(255,255,255,.18);
  font-size: 12px;
  font-weight: 800;
  font-style: normal;
  letter-spacing: .05em;
}
.worldcup2030-flags img { display: block; width: 32px; height: 22px; border-radius: 4px; object-fit: cover; box-shadow: 0 4px 8px rgba(0,0,0,.18); }
.worldcup2030-flags i { grid-column: 1 / -1; justify-self: center; min-width: 38px; width: 38px; height: 28px; color: #ffe27a; }
.worldcup2030-copy { position: relative; z-index: 1; min-width: 0; }
.worldcup2030-copy .section-kicker { color: #ffe27a; }
.worldcup2030-copy h2 { margin: 5px 0 7px; font-size: clamp(24px, 3vw, 34px); line-height: 1.05; }
.worldcup2030-copy p { margin: 0; max-width: 720px; font-size: 16px; line-height: 1.5; opacity: .9; }
.worldcup2030-copy strong { display: block; margin-top: 6px; color: #ffeeb0; font-size: 14px; }
.worldcup2030-banner .button { position: relative; z-index: 1; white-space: nowrap; }

.content-section { max-width: 1180px; margin: 0 auto; padding: 40px 20px; }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.section-heading h2 { margin: 5px 0 0; font-size: 32px; }
.section-kicker { font-size: 10px; font-weight: 800; letter-spacing: .14em; }
.section-kicker.coral { color: var(--coral); }
.section-kicker.blue { color: var(--blue); }
.section-kicker.green { color: var(--green); }
.date-chip { background: white; padding: 10px 14px; border-radius: 999px; font-weight: 700; font-size: 12px; color: var(--purple); box-shadow: 0 5px 18px rgba(55,45,100,.07); }
.cards-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.match-card {
  background: white; border-radius: var(--radius); padding: 22px;
  box-shadow: var(--shadow); border-top: 4px solid var(--blue);
  transition: transform .25s, box-shadow .25s;
}
.match-card:hover { transform: translateY(-4px); box-shadow: 0 20px 42px rgba(51,39,105,.16); }
.match-card.status-en_curso { border-color: var(--green); }
.match-card.status-finalizado { border-color: var(--gold); }
.match-card.status-resultado_pendiente { border-color: #f59e0b; }
.match-card.status-suspendido { border-color: #e5484d; }
.fixture-row.status-en_curso { border-left-color: var(--green); }
.fixture-row.status-finalizado { border-left-color: var(--gold); }
.fixture-row.status-resultado_pendiente { border-left-color: #f59e0b; }
.match-updated { animation: matchRefreshFlash 1.1s ease-out; }
@keyframes matchRefreshFlash {
  0% { box-shadow: 0 0 0 0 rgba(85,39,204,.28); }
  100% { box-shadow: var(--shadow); }
}
@media (prefers-reduced-motion: reduce) {
  .match-updated { animation: none; }
}
.match-card-top, .match-context { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.time-pill { color: var(--purple); font: 700 21px "Fredoka"; }
.time-pill small { font: 800 9px "DM Sans"; background: #ede7ff; padding: 3px 5px; border-radius: 5px; vertical-align: middle; }
.status-badge { display: inline-flex; padding: 5px 8px; border-radius: 7px; font-size: 8px; font-weight: 800; letter-spacing: .07em; white-space: nowrap; }
.status-programado { background: #e4efff; color: #1f68c8; }
.status-en_curso { background: #d9f7e9; color: #0b8d5c; animation: pulse 1.5s infinite; }
.status-finalizado { background: #f4edda; color: #8b6a14; }
.status-resultado_pendiente { background: #fff4dd; color: #9a5b00; }
.status-suspendido { background: #ffe4e5; color: #c72d34; }
@keyframes pulse { 50% { box-shadow: 0 0 0 5px rgba(30,185,128,.1); } }
.match-context { margin-top: 11px; color: var(--muted); font-size: 11px; }
.match-context b { color: var(--coral); }
.teams { margin: 24px 0; }
.team { display: flex; align-items: center; gap: 10px; min-width: 0; font-size: 15px; }
.team b, .fixture-teams span, .result-team span { min-width: 0; overflow-wrap: anywhere; }
.team-away { flex-direction: row-reverse; text-align: right; }
.team > strong { margin-left: auto; color: var(--ink); font: 700 24px "Fredoka"; }
.team-away > strong { margin-left: 0; margin-right: auto; }
.match-scoreboard {
  display: grid;
  gap: 9px;
  margin: 22px 0;
}
.score-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 8px 10px;
  border-radius: 13px;
  background: #f8f7fc;
}
.score-row .team-side {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-size: 15px;
  font-weight: 800;
}
.score-row .team-side b {
  min-width: 0;
  overflow-wrap: anywhere;
}
.score-row .score {
  min-width: 34px;
  text-align: right;
  color: var(--ink);
  font: 700 27px/1 "Fredoka";
}
.team-flag-image, .inline-flag-image, .mini-flag-image, .detail-flag-image, .profile-flag-image {
  display: inline-block; object-fit: cover; border-radius: 3px;
  box-shadow: 0 1px 3px rgba(21,18,40,.2); vertical-align: middle;
}
.team-flag-image { width: 32px; height: 22px; flex: 0 0 auto; }
.inline-flag-image { width: 24px; height: 16px; margin-right: 4px; }
.mini-flag-image { width: 24px; height: 16px; margin-right: 6px; }
.detail-flag-image { display: block; width: 64px; height: 43px; margin: 0 auto 8px; }
.profile-flag-image { width: 96px; height: 64px; border-radius: 7px; }
.flag-fallback { display: inline-grid; place-items: center; width: 24px; height: 18px; color: #8d90a1; font-size: 16px; vertical-align: middle; }
.flag-fallback[hidden] { display: none; }
.team-logo { width: 30px; height: 30px; object-fit: contain; }
.match-detail { display: grid; gap: 18px; }
.match-detail-score { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; text-align: center; }
.detail-team img { width: 72px; height: 72px; object-fit: contain; }
.detail-team h2 { margin: 8px 0 0; }
.detail-team-score { display: block; margin-top: 5px; color: var(--purple); font: 700 34px "Fredoka"; }
.detail-score strong { display: block; font: 700 44px "Fredoka"; margin: 12px 0 4px; }
.detail-score small { color: var(--muted); }
.match-summary-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.match-summary-grid p { margin: 0; padding: 12px; border-radius: 11px; background: #faf9fd; }
.match-summary-grid b, .match-summary-grid span { display: block; }
.match-summary-grid b { margin-bottom: 4px; color: var(--muted); font-size: 12px; }
.summary-update { grid-column: span 2; }
.detail-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.detail-tabs a { padding: 10px 14px; border-radius: 10px; background: white; color: var(--purple); font-weight: 800; }
.event-timeline { display: grid; gap: 8px; }
.event-timeline div { display: grid; grid-template-columns: 60px 1fr auto; gap: 10px; padding: 10px; border-radius: 10px; background: #faf9fd; }
.event-timeline small { color: var(--muted); }
@media (max-width: 640px) {
  .flag { flex: 0 0 auto; font-size: 23px; }
  .team, .team-away { align-items: flex-start; }
  .profile-flag { min-width: 58px; font-size: 42px; }
  .detail-team h2 { font-size: 16px; }
  .detail-team img { width: 48px; height: 48px; }
  .detail-team-score { font-size: 27px; }
  .detail-score strong { font-size: 30px; }
  .match-summary-grid { grid-template-columns: 1fr 1fr; }
  .event-timeline div { grid-template-columns: 45px 1fr; }
  .event-timeline small { grid-column: 2; }
}
.versus { display: block; text-align: center; color: #a9adbd; font: 700 10px "Fredoka"; margin: 7px 0; }
.venue { border-top: 1px dashed #e7e2f0; padding-top: 15px; display: flex; align-items: center; gap: 9px; font-size: 11px; }
.venue > span:first-child { color: var(--pink); font-size: 20px; }
.venue small { display: block; color: var(--muted); margin-top: 2px; }
.empty-state { border: 2px dashed #dcd3f5; padding: 50px 20px; text-align: center; border-radius: 28px; background: rgba(255,255,255,.6); }
.empty-state h3 { font-size: 23px; margin: 10px 0 5px; }
.empty-state p { color: var(--muted); margin: 0 0 20px; }
.empty-ball { font-size: 48px; animation: float 3s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-7px) rotate(8deg); } }

.results-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.result-card { background: white; border-radius: 20px; padding: 18px 20px; box-shadow: var(--shadow); }
.result-meta { display: flex; gap: 8px; align-items: center; color: var(--muted); font-size: 10px; }
.result-meta span:nth-child(2) { flex: 1; text-align: center; }
.score-line { display: grid; grid-template-columns: 1fr auto 1fr; gap: 14px; align-items: center; margin: 20px 0 13px; }
.score-line > div { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.score-line .right { justify-content: flex-end; text-align: right; flex-direction: row-reverse; }
.score-line > strong { font: 700 27px "Fredoka"; background: #f2effa; padding: 4px 12px; border-radius: 11px; }
.score-line i { font-style: normal; color: #9b9eaa; }
.result-card > p { border-top: 1px dashed #e8e4ef; padding-top: 10px; margin: 0; color: var(--muted); font-size: 10px; }

.fact-banner {
  max-width: 1140px; margin: 42px auto; border-radius: 25px; padding: 26px 32px;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 22px;
  color: white; box-shadow: var(--shadow);
}
.fact-violet { background: linear-gradient(120deg, #6035dd, #9050ed); }
.fact-coral { background: linear-gradient(120deg, #ff6761, #f04490); }
.fact-blue { background: linear-gradient(120deg, #247bdc, #4baee9); }
.fact-green { background: linear-gradient(120deg, #0ca66e, #55c78b); }
.fact-gold { background: linear-gradient(120deg, #ec9d22, #f4c84f); color: #4c3713; }
.fact-pink { background: linear-gradient(120deg, #e9449a, #a94ddf); }
.fact-icon { width: 60px; height: 60px; border-radius: 20px; display: grid; place-items: center; background: rgba(255,255,255,.17); font-size: 30px; }
.fact-banner span { font-size: 9px; font-weight: 800; letter-spacing: .14em; opacity: .75; }
.fact-banner h3 { margin: 5px 0 2px; font-size: 22px; }
.fact-banner p { margin: 0; opacity: .82; font-size: 13px; }
.fact-banner a { font-size: 12px; font-weight: 700; white-space: nowrap; }

.standings-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.standing-card { background: white; border-radius: 22px; overflow: hidden; box-shadow: var(--shadow); }
.standing-card header { padding: 15px 20px; display: flex; align-items: center; justify-content: space-between; background: linear-gradient(100deg, #f2eeff, #fff); }
.standing-card header span { text-transform: uppercase; font-size: 10px; font-weight: 800; letter-spacing: .13em; color: var(--purple); }
.standing-card header strong { width: 34px; min-width: 34px; height: 34px; display: grid; place-items: center; border-radius: 11px; background: var(--purple); color: white; font: 700 18px "Fredoka"; overflow: hidden; white-space: nowrap; }
.lineup-card header span { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.lineup-card header .inline-flag-image { flex: 0 0 auto; margin-right: 0; }
.lineup-card header strong { width: auto; min-width: 72px; padding: 0 12px; overflow: visible; font-size: 16px; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 11px; }
th { text-align: center; padding: 9px 7px; color: #9397a9; background: #faf9fd; font-size: 8px; }
th:nth-child(2), td:nth-child(2) { text-align: left; }
td { padding: 10px 7px; text-align: center; border-top: 1px solid #f0edf5; white-space: nowrap; }
tbody tr:nth-child(-n+2) td:first-child { color: var(--green); }
td:last-child strong { display: inline-grid; place-items: center; background: #eee8ff; color: var(--purple); min-width: 25px; height: 25px; border-radius: 8px; }
.mini-flag { font-size: 17px; margin-right: 5px; vertical-align: middle; }
.mini-team-logo { width: 22px; height: 22px; object-fit: contain; margin-right: 6px; vertical-align: middle; }

.page-hero, .admin-hero {
  max-width: 1240px; margin: 0 auto 20px; padding: 58px 70px; border-radius: 32px;
  color: white; position: relative; overflow: hidden;
}
.page-hero::after { content: "⚽"; position: absolute; right: 7%; top: 10%; font-size: 145px; opacity: .12; transform: rotate(15deg); }
.page-hero h1, .admin-hero h1 { font-size: clamp(38px, 5vw, 60px); margin: 9px 0; }
.page-hero p, .admin-hero p { margin: 0; opacity: .8; }
.page-hero-green { background: linear-gradient(120deg, #098e66, #49bd7a); }
.page-hero-purple { background: linear-gradient(120deg, #5830d5, #9b4de1); }
.page-hero-coral { background: linear-gradient(120deg, #ee5b62, #ec4c9a); }

.stadiums-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.stadium-card { background: white; border-radius: 24px; overflow: hidden; box-shadow: var(--shadow); transition: transform .25s; }
.stadium-card:hover { transform: translateY(-5px); }
.stadium-photo { min-height: 180px; background: linear-gradient(135deg, #d7d1f3, #b6d9e9); display: flex; flex-direction: column; align-items: center; justify-content: center; position: relative; color: #6d6c86; }
.stadium-photo > span { font-size: 62px; opacity: .75; }
.stadium-photo img { width: 100%; height: 180px; object-fit: cover; }
.stadium-photo > small { font-size: 10px; margin-top: 5px; }
.stadium-photo > b { position: absolute; top: 14px; right: 14px; background: rgba(255,255,255,.86); padding: 6px 9px; border-radius: 8px; font-size: 9px; color: var(--ink); }
.stadium-body { padding: 20px; }
.stadium-city { color: var(--purple); font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .12em; }
.stadium-body h2 { margin: 5px 0 2px; font-size: 22px; }
.fifa-name { color: var(--muted); font-size: 11px; margin: 0 0 18px; }
.capacity { display: flex; align-items: center; gap: 10px; }
.capacity > span { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: #eee9ff; }
.capacity small, .capacity strong { display: block; }
.capacity small { color: var(--muted); font-size: 9px; }
.capacity strong { font: 700 19px "Fredoka"; }
.map-placeholder { margin-top: 17px; border: 1px dashed #dcd5ea; border-radius: 13px; background: #faf9fd; padding: 11px; display: flex; align-items: center; gap: 9px; }
.map-placeholder > span { color: var(--coral); font-size: 22px; }
.map-placeholder p { margin: 0; font-size: 10px; font-weight: 700; }
.map-placeholder small { color: var(--muted); font-weight: 400; }

.filter-bar { display: flex; align-items: center; gap: 12px; background: white; border-radius: 17px; padding: 13px 16px; margin-bottom: 18px; box-shadow: var(--shadow); }
.filter-bar label { font-size: 11px; font-weight: 700; }
.filter-bar select, .admin-panel select, .admin-panel input, .admin-panel textarea {
  border: 1px solid #ddd8eb; background: #faf9fd; padding: 9px 11px; border-radius: 10px; color: var(--ink);
}
.filter-bar span { margin-left: auto; color: var(--muted); font-size: 11px; }
.fixture-list { display: grid; gap: 8px; }
.fixture-row { display: grid; grid-template-columns: 65px 85px 1.4fr 1fr auto; align-items: center; gap: 16px; background: white; padding: 13px 17px; border-radius: 16px; box-shadow: 0 5px 16px rgba(51,39,105,.06); }
.fixture-number { text-align: center; border-right: 1px solid #eeeaf3; }
.fixture-number small { display: block; font-size: 7px; color: var(--muted); }
.fixture-number strong { color: var(--purple); font: 700 20px "Fredoka"; }
.fixture-date strong, .fixture-date span { display: block; }
.fixture-date span { color: var(--coral); font-size: 11px; font-weight: 800; }
.fixture-teams { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; font-size: 12px; }
.fixture-teams > span { display: flex; align-items: center; gap: 5px; }
.fixture-teams .right { justify-content: flex-end; text-align: right; }
.fixture-team-score { margin-left: auto; color: var(--purple); font: 700 20px "Fredoka"; }
.fixture-teams .right .fixture-team-score { margin-left: 0; margin-right: auto; }
.fixture-teams > strong { font: 700 20px "Fredoka"; }
.fixture-teams i { color: var(--muted); font-size: 10px; }
.fixture-info b, .fixture-info small { display: block; font-size: 10px; }
.fixture-info small { color: var(--muted); margin-top: 3px; }

.facts-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.fact-card { border-radius: 24px; color: white; min-height: 220px; padding: 28px; box-shadow: var(--shadow); }
.fact-card > span { opacity: .5; font: 700 34px "Fredoka"; }
.fact-card h2 { font-size: 24px; margin: 30px 0 8px; }
.fact-card p { margin: 0; line-height: 1.55; opacity: .83; }

.admin-hero { background: #222944; }
.admin-layout { display: grid; grid-template-columns: 1.5fr .8fr; gap: 20px; align-items: start; }
.admin-panel { background: white; border-radius: 22px; padding: 22px; box-shadow: var(--shadow); }
.admin-panel h2 { margin-bottom: 4px; }
.muted { color: var(--muted); font-size: 12px; }
.admin-matches { max-height: 620px; overflow: auto; display: grid; gap: 6px; padding-right: 4px; }
.admin-matches form { display: grid; grid-template-columns: 36px 1fr 50px auto 50px 125px 65px; align-items: center; gap: 6px; border-top: 1px solid #eeeaf3; padding: 7px 0; font-size: 10px; }
.admin-matches input { width: 50px; }
.match-id { color: var(--purple); font-weight: 800; }
.small-button { border: 0; border-radius: 8px; padding: 7px 8px; background: #eae4ff; color: var(--purple); font-size: 9px; font-weight: 800; cursor: pointer; }
.fact-form { display: grid; gap: 9px; margin: 16px 0 22px; }
.fact-form textarea { min-height: 100px; resize: vertical; }
.admin-facts form { display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: center; padding: 10px 0; border-top: 1px solid #eeeaf3; font-size: 11px; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--purple); }
.dot-coral { background: var(--coral); }.dot-blue { background: var(--blue); }.dot-green { background: var(--green); }.dot-gold { background: var(--gold); }.dot-pink { background: var(--pink); }
.muted-button { filter: grayscale(1); opacity: .6; }
.flash { max-width: 1180px; margin: 5px auto 15px; padding: 11px 15px; border-radius: 12px; font-size: 12px; font-weight: 700; }
.flash-success { background: #dff7e9; color: #08764c; }
.flash-error { background: #ffe5e6; color: #b8232b; }
.auto-refresh-indicator {
  position: fixed; right: 16px; bottom: 16px; z-index: 80;
  padding: 9px 12px; border-radius: 999px;
  background: rgba(36,43,73,.92); color: white;
  box-shadow: 0 10px 24px rgba(21,18,40,.18);
  font-size: 12px; font-weight: 800;
}
.auto-refresh-indicator[hidden] { display: none; }
.empty-inline { padding: 25px; background: white; border-radius: 18px; color: var(--muted); text-align: center; }
.install-card, .error-card {
  max-width: 650px; margin: 20px auto; padding: 48px 30px; border-radius: 28px;
  background: white; text-align: center; box-shadow: var(--shadow);
}
.install-card h2, .error-card h1 { font-size: 30px; margin: 12px 0 6px; }
.install-card p, .error-card p { color: var(--muted); margin: 0 0 24px; }
.install-icon, .error-card > span {
  display: grid; place-items: center; width: 76px; height: 76px; margin: auto;
  border-radius: 25px; background: linear-gradient(145deg, #eee8ff, #ffe4f1);
  color: var(--purple); font: 700 35px "Fredoka";
}
.install-card code { background: #f0ecfa; border-radius: 6px; padding: 2px 6px; color: var(--purple); }

footer { margin-top: 60px; background: #242b49; color: white; text-align: center; padding: 28px 20px; font-size: 11px; }
footer p { margin: 3px; }
.footer-note { opacity: .5; }
.confetti { position: fixed; pointer-events: none; z-index: -1; }
.confetti-a { left: 3%; top: 35%; width: 7px; height: 20px; background: var(--gold); transform: rotate(25deg); }
.confetti-b { right: 3%; top: 65%; width: 13px; height: 13px; border: 4px solid var(--pink); border-radius: 50%; }

@media (max-width: 920px) {
  .main-nav { display: none; position: absolute; top: 68px; left: 16px; right: 16px; flex-direction: column; align-items: stretch; background: white; padding: 10px; border-radius: 17px; box-shadow: var(--shadow); }
  .main-nav.open { display: flex; }
  .main-nav .admin-link { margin-left: 0; }
  .menu-button { display: block; }
  .hero { margin-left: 14px; margin-right: 14px; grid-template-columns: 1fr; padding: 45px; gap: 30px; }
  .stats-strip { margin-left: 35px; margin-right: 35px; }
  .stats-strip div { padding: 4px 12px; }
  .worldcup2030-banner { margin-left: 16px; margin-right: 16px; grid-template-columns: auto 1fr; }
  .worldcup2030-banner .button { grid-column: 2; justify-self: start; }
  .cards-grid, .stadiums-grid, .facts-grid { grid-template-columns: repeat(2, 1fr); }
  .fixture-row { grid-template-columns: 50px 65px 1fr auto; }
  .fixture-info { display: none; }
  .admin-layout { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .site-header { height: 68px; padding: 0 16px; }
  .hero { padding: 36px 24px; border-radius: 26px; min-height: auto; }
  .hero h1 { font-size: 43px; }
  .hero-copy > p { font-size: 14px; }
  .countdown-card { padding: 22px 12px; }
  .countdown div { min-width: 55px; }
  .countdown strong { font-size: 35px; }
  .stats-strip { grid-template-columns: repeat(2, 1fr); margin: -25px 25px 30px; padding: 12px; }
  .stats-strip div { border-right: 0; padding: 10px; }
  .worldcup2030-banner { margin: 0 14px 18px; padding: 22px; grid-template-columns: 1fr; gap: 15px; }
  .worldcup2030-flags { grid-template-columns: repeat(3, 42px); gap: 6px; justify-content: start; }
  .worldcup2030-flags span,
  .worldcup2030-flags i { min-width: 0; height: 30px; border-radius: 9px; font-size: 10px; }
  .worldcup2030-flags img { width: 30px; height: 20px; }
  .worldcup2030-flags i { grid-column: 1 / -1; justify-self: center; width: 34px; }
  .worldcup2030-copy h2 { font-size: 24px; }
  .worldcup2030-copy p { font-size: 14px; }
  .worldcup2030-copy strong { font-size: 13px; }
  .worldcup2030-banner .button { grid-column: auto; width: 100%; }
  .content-section { padding: 30px 14px; }
  .section-heading { align-items: flex-start; }
  .section-heading h2 { font-size: 27px; }
  .date-chip { font-size: 9px; padding: 8px 10px; }
  .cards-grid, .results-grid, .standings-grid, .stadiums-grid, .facts-grid { grid-template-columns: 1fr; }
  .result-meta { flex-wrap: wrap; }
  .result-meta span:nth-child(2) { order: 3; flex-basis: 100%; text-align: left; }
  .score-line { gap: 6px; }
  .score-line > div { font-size: 11px; }
  .score-line .flag { font-size: 21px; }
  .fact-banner { margin: 25px 14px; padding: 24px; grid-template-columns: auto 1fr; }
  .fact-banner a { grid-column: 2; }
  .page-hero, .admin-hero { margin: 0 14px; padding: 38px 24px; border-radius: 25px; }
  .page-hero::after { font-size: 90px; }
  .filter-bar label { display: none; }
  .fixture-row { grid-template-columns: 42px 55px 1fr; gap: 8px; padding: 11px 10px; }
  .fixture-row > .status-badge { grid-column: 3; justify-self: end; margin-top: -4px; }
  .fixture-teams { font-size: 10px; gap: 4px; }
  .fixture-teams > strong { font-size: 16px; }
  .admin-matches form { grid-template-columns: 34px 1fr 44px auto 44px; }
  .admin-matches select, .admin-matches button { grid-column: span 2; }
}

/* RC1.1 Mundialero Deluxe */
.hero-deluxe {
  min-height: 330px;
  padding: 24px;
  grid-template-columns: .95fr .9fr .9fr;
  gap: 22px;
  align-items: stretch;
}
.world-slider {
  min-width: 0;
  min-height: 282px;
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #25165d;
  box-shadow: 0 14px 28px rgba(27, 13, 74, .28);
}
.world-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .55s ease; }
.world-slide.active { opacity: 1; z-index: 1; }
.world-slide img { width: 100%; height: 100%; object-fit: cover; }
.world-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(20,11,54,.9), rgba(20,11,54,.08) 65%); }
.slide-copy { position: absolute; z-index: 2; left: 20px; right: 20px; bottom: 24px; }
.slide-copy span { display: inline-block; padding: 4px 8px; border-radius: 7px; background: #ffd85e; color: #402069; font-size: 9px; font-weight: 800; letter-spacing: .12em; }
.slide-copy h2 { margin: 8px 0 3px; font-size: 22px; line-height: 1.05; }
.slide-copy p { margin: 0; opacity: .78; font-size: 11px; }
.slider-dots { position: absolute; z-index: 4; right: 15px; top: 14px; display: flex; gap: 5px; }
.slider-dots button { width: 7px; height: 7px; padding: 0; border: 0; border-radius: 50%; background: rgba(255,255,255,.45); cursor: pointer; }
.slider-dots button.active { width: 20px; border-radius: 8px; background: #ffd85e; }
.hero-center { align-self: center; position: relative; z-index: 2; }
.hero-center .eyebrow { color: #ffdf76; }
.hero-center h1 { font-size: clamp(34px, 3vw, 49px); line-height: 1; margin: 10px 0; }
.hero-center h1 span { color: #ffd85e; }
.hero-center > p { margin: 0; opacity: .82; font-size: 13px; }
.hero-center .hero-actions { margin-top: 18px; }
.hero-deluxe .countdown-card { padding: 20px; display: flex; flex-direction: column; justify-content: center; }
.next-teams { display: flex; justify-content: center; align-items: center; gap: 7px; margin-top: 10px; font-size: 12px; flex-wrap: wrap; }
.next-teams i { opacity: .6; font-style: normal; font-size: 9px; }
.hero-deluxe .countdown { margin: 14px 0 12px; }
.hero-deluxe .countdown strong { font-size: 31px; }
.hero-deluxe .countdown div { min-width: 48px; }
.next-venue { display: grid; gap: 3px; text-align: left; padding-top: 10px; border-top: 1px solid rgba(255,255,255,.18); font-size: 10px; opacity: .88; }
.stats-strip { margin-top: -46px; margin-bottom: 22px; }
.compact-section { padding-top: 24px; padding-bottom: 24px; }
.result-card { border-left: 4px solid var(--gold); }
.result-card.is-draw { border-left-color: var(--blue); }
.result-team { display: flex; justify-content: space-between; gap: 12px; padding: 8px 10px; margin-top: 7px; border-radius: 10px; background: #f8f7fc; font-size: 13px; }
.result-team.winner { color: #08764c; background: #e4f8ed; font-weight: 800; }
.result-team strong { font: 700 20px "Fredoka"; }
.result-card > p { margin-top: 9px; }
.bracket-scroll { overflow-x: auto; overflow-y: hidden; padding: 5px 4px 18px; }
.bracket-grid { display: grid; grid-template-columns: repeat(6, minmax(195px, 1fr)); gap: 18px; min-width: 1380px; align-items: start; }
.bracket-stage { position: relative; display: flex; flex-direction: column; min-width: 0; }
.bracket-stage h3 { position: sticky; top: 0; margin: 0 0 12px; padding: 10px 12px; border-radius: 11px; color: white; background: #322061; font-size: 13px; text-align: center; z-index: 4; }
.bracket-matches { flex: 1; display: flex; flex-direction: column; justify-content: flex-start; gap: 10px; padding: 4px 0; }
.bracket-match { position: relative; padding: 8px 9px; border-radius: 12px; background: white; border: 1px solid #ebe6f5; box-shadow: 0 4px 12px rgba(45,32,92,.08); z-index: 2; }
.bracket-match small { display: block; margin-bottom: 6px; color: var(--muted); font-size: 8px; }
.bracket-match > span { display: flex; align-items: center; min-height: 27px; padding: 3px 4px; font-size: 10px; font-weight: 700; line-height: 1.25; }
.bracket-match > span strong { margin-left: auto; padding-left: 8px; font-size: 15px; color: var(--ink); }
.third-place-bracket { width: min(420px, 100%); margin: 18px auto 0; padding: 14px; border-radius: 18px; background: #fffaf0; border: 1px solid #f0d48a; box-shadow: 0 10px 24px rgba(166,119,14,.10); }
.third-place-bracket h3 { margin: 0 0 10px; color: #7a5306; font-size: 16px; text-align: center; }
.third-place-match { border-color: #e5c56b; box-shadow: none; }
.third-place-match em { display: inline-flex; margin-top: 8px; padding: 4px 8px; border-radius: 999px; background: #f4ead0; color: #7a5306; font-size: 11px; font-style: normal; font-weight: 800; }
.bracket-stage .bracket-match::before,
.bracket-stage .bracket-match::after { content: none; display: none; }
.bracket-stage-1 { --branch-height: 43px; }
.bracket-stage-2 { --branch-height: 84px; }
.bracket-stage-3 { --branch-height: 172px; }
.bracket-stage-4 { --branch-height: 345px; }
.bracket-stage-2 .bracket-matches,
.bracket-stage-3 .bracket-matches,
.bracket-stage-4 .bracket-matches,
.bracket-stage-5 .bracket-matches { padding-block: 4px; }
.bracket-stage-5 h3 { background: linear-gradient(120deg, #a6770e, #e0ae31); }
.bracket-stage-5 .bracket-match { border: 2px solid #dfb64e; box-shadow: 0 10px 24px rgba(166,119,14,.18); }
.standing-card table a { display: inline-flex; align-items: center; }
.standing-card.standings-updated { animation: standingsRefreshFlash 1.2s ease-out; }
.standing-card [data-standing-field].standings-updated { color: var(--purple); font-weight: 900; }
.standing-card tr.standings-position-up { background: #e9fbf2; }
.standing-card tr.standings-position-down { background: #fff6df; }
@keyframes standingsRefreshFlash {
  0% { box-shadow: 0 0 0 0 rgba(30,185,128,.22); }
  100% { box-shadow: var(--shadow); }
}

/* RC1.1 desktop: mas ancho util para posiciones y llaves */
.standings-section,
.bracket-section {
  width: min(1500px, calc(100% - 48px));
  max-width: 1500px;
  padding-left: 0;
  padding-right: 0;
}
.standings-grid { gap: 16px; }
.standing-card .table-scroll { overflow-x: visible; }
.standing-card table { min-width: 0; table-layout: auto; }
.standing-card th,
.standing-card td { padding-left: 6px; padding-right: 6px; }
.standing-card th:first-child,
.standing-card td:first-child { width: 34px; }
.standing-card th:nth-child(2),
.standing-card td:nth-child(2) {
  width: 100%;
  white-space: normal;
}
.standing-card th:nth-child(n+3),
.standing-card td:nth-child(n+3) {
  width: 42px;
  white-space: nowrap;
}
.standing-card table a {
  max-width: 100%;
  gap: 6px;
}
.standing-card table a b {
  min-width: 0;
  overflow-wrap: anywhere;
  line-height: 1.25;
}
.standing-card .mini-flag-image { flex: 0 0 auto; }
.bracket-scroll { overflow-x: visible; }
.bracket-grid {
  min-width: 0;
  grid-template-columns: repeat(6, minmax(170px, 1fr));
  gap: clamp(18px, 2vw, 34px);
}

@media (max-width: 1366px) {
  .standings-section,
  .bracket-section {
    width: min(1320px, calc(100% - 36px));
  }
  .standings-grid { gap: 14px; }
  .standing-card header { padding: 14px 16px; }
  .bracket-grid { grid-template-columns: repeat(6, minmax(158px, 1fr)); }
}

@media (max-width: 1080px) {
  .standings-section,
  .bracket-section {
    width: min(1000px, calc(100% - 28px));
  }
  .standings-grid { gap: 12px; }
  .standing-card th,
  .standing-card td { padding-left: 5px; padding-right: 5px; }
  .standing-card th:nth-child(n+3),
  .standing-card td:nth-child(n+3) { width: 42px; }
  .bracket-scroll { overflow-x: auto; padding-bottom: 14px; }
  .bracket-grid { min-width: 1160px; }
}

@media (max-width: 840px) {
  .standings-section,
  .bracket-section {
    width: min(100% - 24px, 720px);
  }
  .standings-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .standings-section,
  .bracket-section {
    width: auto;
    max-width: none;
    margin-left: 14px;
    margin-right: 14px;
    padding-left: 0;
    padding-right: 0;
  }
  .standing-card .table-scroll { overflow-x: auto; }
  .standing-card table { min-width: 640px; }
  .bracket-scroll { overflow-x: auto; }
  .bracket-grid { min-width: 1160px; }
}
.visit-strip { max-width: 1140px; margin: 15px auto; display: flex; justify-content: center; gap: 30px; color: var(--muted); font-size: 11px; }
.team-profile-hero { max-width: 1180px; margin: 0 auto; padding: 45px; border-radius: 28px; color: white; background: linear-gradient(120deg, #38206e, #7a42db); }
.team-profile-title { display: flex; align-items: center; gap: 20px; margin-top: 25px; }
.team-profile-title > span { font-size: 76px; }
.team-profile-title small { color: #ffe271; font-weight: 800; letter-spacing: .14em; }
.team-profile-title h1 { margin: 2px 0; font-size: 52px; }
.team-profile-title p { margin: 0; opacity: .65; }
.back-link { display: inline-block; margin-top: 14px; color: var(--purple); font-size: 12px; font-weight: 800; }
.team-profile-hero .back-link { margin: 0; color: white; opacity: .8; }
.profile-layout { display: grid; grid-template-columns: 1.5fr .8fr; gap: 18px; align-items: start; }
.profile-panel, .stadium-profile article { padding: 25px; border-radius: 22px; background: white; box-shadow: var(--shadow); }
.profile-metrics { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 15px 0; }
.team-metrics { grid-template-columns: repeat(4, 1fr); }
.profile-metrics span { padding: 13px; border-radius: 13px; background: #f1edfc; }
.profile-metrics small, .profile-metrics b { display: block; }
.profile-metrics small { color: var(--muted); font-size: 9px; text-transform: uppercase; }
.profile-metrics b { margin-top: 4px; font: 700 20px "Fredoka"; }
.stats-list { display: grid; grid-template-columns: repeat(6, 1fr); gap: 7px; }
.stats-list span { padding: 10px; text-align: center; border-radius: 10px; background: #faf9fd; font-size: 10px; }
.stats-list b { display: block; margin-top: 4px; font-size: 17px; }
.next-profile-date { color: var(--coral); font-size: 12px; font-weight: 800; }
.stadium-profile { max-width: 900px; }
.stadium-profile article { margin-top: 14px; }
.stadium-profile h2 { margin: 6px 0; font-size: 38px; }
.profile-copy { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.profile-copy p, .stadium-curiosity { padding: 13px; border-radius: 12px; background: #faf9fd; color: var(--muted); font-size: 12px; line-height: 1.5; }
.card-link { display: inline-block; color: var(--purple); font-size: 11px; font-weight: 800; }
.analytics-panel { grid-column: 1 / -1; }
.analytics-panel .profile-metrics { max-width: 360px; }
.analytics-row { display: flex; justify-content: space-between; max-width: 360px; margin: 5px 0; padding: 7px 10px; border-radius: 8px; background: #faf9fd; font-size: 11px; }

@media (max-width: 1200px) {
  .hero.hero-deluxe {
    width: min(100% - 32px, 980px);
    min-height: 0;
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 24px;
    align-items: stretch;
  }

  .hero.hero-deluxe::after {
    bottom: -230px;
  }

  .world-slider {
    width: 100%;
    min-width: 0;
    min-height: clamp(240px, 34vw, 360px);
    grid-row: auto;
  }

  .hero-center {
    width: 100%;
    min-width: 0;
    padding: 4px 4px 0;
  }

  .hero-center h1 {
    max-width: 780px;
    font-size: clamp(34px, 5.2vw, 50px);
  }

  .hero-center > p {
    max-width: 720px;
  }

  .hero-deluxe .countdown-card {
    width: 100%;
    min-width: 0;
    min-height: 0;
  }

  .next-teams {
    justify-content: center;
    line-height: 1.35;
  }

  .next-venue {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    text-align: left;
  }

  .stats-strip {
    width: min(100% - 56px, 940px);
    margin-top: -18px;
    margin-bottom: 26px;
  }
}

@media (max-width: 1024px) {
  main {
    overflow-x: hidden;
  }

  .hero,
  .hero.hero-deluxe {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 0;
  }

  .world-slider,
  .countdown-card,
  .hero-deluxe .countdown-card {
    width: 100%;
    min-width: 0;
    height: auto;
    min-height: 0;
  }

  .world-slider {
    min-height: 260px;
  }

  .hero.hero-deluxe {
    color: #13285b;
    background:
      radial-gradient(circle at 92% 8%, rgba(49, 134, 245, .14), transparent 18rem),
      linear-gradient(180deg, #ffffff 0%, #eef5ff 100%);
    box-shadow: 0 16px 38px rgba(26, 47, 96, .14);
  }

  .hero.hero-deluxe::before,
  .hero.hero-deluxe::after {
    opacity: .18;
    border-color: rgba(49, 83, 158, .18);
  }

  .hero-center,
  .hero-deluxe .countdown-card {
    position: relative;
    z-index: 2;
    color: #13285b;
  }

  .hero-center .eyebrow,
  .hero .eyebrow {
    color: #0f7b5c;
  }

  .hero-center h1,
  .hero-center h1 span,
  .hero-center > p {
    color: #13285b;
    opacity: 1;
  }

  .hero-center h1 span {
    color: #254fd6;
  }

  .hero-center .button-primary {
    color: #10214d;
    background: linear-gradient(135deg, #ffbf3f, #ff7c5f);
  }

  .hero-center .button-ghost {
    color: #254fd6;
    background: #ffffff;
    border-color: #cad7ff;
    box-shadow: 0 8px 20px rgba(45, 69, 143, .10);
  }

  .hero-deluxe .countdown-card {
    background: #ffffff !important;
    border: 1px solid #cbd9ff !important;
    opacity: 1 !important;
    backdrop-filter: none !important;
    box-shadow: 0 14px 30px rgba(28, 51, 111, .14);
  }

  .hero-deluxe .countdown-card *,
  .hero-deluxe .countdown-card p,
  .hero-deluxe .countdown-card small,
  .hero-deluxe .countdown-card b,
  .hero-deluxe .countdown-card strong,
  .hero-deluxe .countdown-card span,
  .hero-deluxe .countdown-card i {
    color: #13285b;
    opacity: 1;
  }

  .hero-deluxe .countdown-label {
    color: #0f7b5c !important;
  }

  .hero-deluxe .countdown strong {
    color: #254fd6 !important;
  }

  .hero-deluxe .countdown i {
    color: #7890ca !important;
  }

  .next-teams {
    background: #eef4ff;
    border-radius: 14px;
    padding: 10px 12px;
  }

  .next-teams b {
    color: #0e2a66 !important;
  }

  .next-teams i {
    color: #6c7898 !important;
  }

  .next-venue {
    border-top-color: #d9e3ff;
    background: #f7faff;
    border-radius: 14px;
    padding: 12px;
  }

  .next-venue span {
    color: #243766 !important;
  }

  .slide-copy {
    bottom: 18px;
  }

  .slide-copy h2 {
    max-width: 620px;
    font-size: clamp(24px, 4.8vw, 36px);
  }

  .cards-grid {
    grid-template-columns: 1fr;
  }

  #partidos-hoy {
    width: min(100% - 32px, 980px);
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
  }

  #partidos-hoy .section-heading,
  #partidos-hoy .section-heading h2,
  #partidos-hoy .section-kicker,
  #partidos-hoy .date-chip {
    color: #13285b;
    opacity: 1;
  }

  #partidos-hoy .section-kicker {
    color: #d9414e;
  }

  #partidos-hoy .date-chip {
    background: #ffffff;
    border: 1px solid #dbe4ff;
  }

  .match-card {
    width: 100%;
    min-width: 0;
    background: #ffffff;
    color: #13285b;
    border-color: #3186f5;
    opacity: 1;
  }

  .match-card *,
  .match-card b,
  .match-card strong,
  .match-card small,
  .match-card span,
  .match-card a {
    opacity: 1;
  }

  .match-card .team b,
  .match-card .venue b,
  .match-card .time-pill {
    color: #102a66;
  }

  .match-card .match-context,
  .match-card .venue,
  .match-card .venue small,
  .match-card .versus {
    color: #4c5f8d;
  }

  .match-card .card-link {
    color: #254fd6;
  }

  .team,
  .team-away {
    min-width: 0;
  }

  .team b {
    overflow-wrap: anywhere;
  }

  .stats-strip {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    padding: 14px;
  }

  .stats-strip div {
    min-width: 0;
    padding: 8px 10px;
  }
}

@media (max-width: 720px) {
  .hero-deluxe { grid-template-columns: 1fr; padding: 15px; gap: 14px; }
  .world-slider { grid-row: auto; min-height: 220px; }
  .hero-center { padding: 8px 5px; }
  .hero-center h1 { font-size: 37px; }
  .hero-deluxe .countdown-card { padding: 17px; }
  .stats-strip { grid-template-columns: repeat(2, 1fr); margin-top: -12px; }
  .stats-strip div { border-right: 0; }
  .next-venue { grid-template-columns: 1fr; }
  .profile-layout, .profile-copy { grid-template-columns: 1fr; }
  .team-metrics { grid-template-columns: repeat(2, 1fr); }
  .stats-list { grid-template-columns: repeat(3, 1fr); }
  .team-profile-hero { margin: 0 14px; padding: 28px 22px; }
  .profile-flag-image { width: 72px; height: 48px; }
  .team-profile-title h1 { font-size: 38px; }
}

/* RC1.1 legibilidad: tipografia secundaria para lectura comoda */
.brand small { font-size: 13px; }
.main-nav a { font-size: 16px; }
.eyebrow { font-size: 13px; }
.page-hero p, .admin-hero p,
.hero-center > p { font-size: 16px; line-height: 1.55; }
.slide-copy span { font-size: 12px; }
.slide-copy p { font-size: 14px; line-height: 1.4; }
.countdown-label { font-size: 12px; }
.countdown small { font-size: 12px; }
.next-teams { font-size: 14px; }
.next-teams i { font-size: 12px; }
.next-venue { gap: 5px; font-size: 13px; line-height: 1.35; }
.stats-strip small { font-size: 14px; }
.section-kicker { font-size: 12px; }
.date-chip { font-size: 14px; }
.time-pill small { font-size: 12px; }
.status-badge { padding: 6px 9px; font-size: 11px; }
.match-context { font-size: 14px; }
.versus { font-size: 12px; }
.venue { font-size: 14px; line-height: 1.35; }
.venue small { font-size: 13px; }
.result-meta { font-size: 13px; }
.result-team { font-size: 15px; }
.result-card > p { font-size: 14px; line-height: 1.4; }
.fact-banner span { font-size: 12px; }
.fact-banner p { font-size: 15px; line-height: 1.5; }
.fact-banner a { font-size: 14px; }
.fact-card p { font-size: 16px; line-height: 1.65; }
.standing-card header span { font-size: 13px; }
table { font-size: 14px; }
th { font-size: 12px; }
td { padding: 12px 8px; }
.stadium-photo > small { font-size: 13px; }
.stadium-photo > b { font-size: 12px; }
.stadium-city { font-size: 13px; }
.fifa-name { font-size: 14px; line-height: 1.4; }
.capacity small { font-size: 13px; }
.map-placeholder p { font-size: 14px; }
.map-placeholder small { font-size: 13px; }
.stadium-curiosity { font-size: 15px; line-height: 1.6; }
.card-link { font-size: 14px; }
.filter-bar label,
.filter-bar span { font-size: 14px; }
.filter-bar select,
.admin-panel select,
.admin-panel input,
.admin-panel textarea { font-size: 15px; }
.fixture-number small { font-size: 11px; }
.fixture-date span { font-size: 14px; }
.fixture-teams { font-size: 15px; }
.fixture-teams i { font-size: 13px; }
.fixture-info b,
.fixture-info small { font-size: 13px; line-height: 1.35; }
.muted { font-size: 14px; line-height: 1.5; }
.admin-matches form { font-size: 13px; }
.small-button { padding: 8px 10px; font-size: 12px; }
.admin-facts form { font-size: 14px; }
.flash { font-size: 14px; }
.empty-inline,
.empty-state p,
.install-card p,
.error-card p { font-size: 15px; line-height: 1.55; }
footer { font-size: 14px; line-height: 1.5; }
.bracket-stage h3 { font-size: 15px; }
.bracket-match small { font-size: 12px; }
.bracket-match > span { padding: 7px; font-size: 14px; line-height: 1.35; }
.visit-strip { font-size: 14px; }
.back-link { font-size: 14px; }
.team-profile-title small { font-size: 13px; }
.team-profile-title p { font-size: 15px; }
.profile-panel > p,
.profile-panel aside p { font-size: 15px; line-height: 1.55; }
.profile-metrics small { font-size: 12px; }
.stats-list span { font-size: 13px; }
.next-profile-date { font-size: 15px; }
.profile-copy p { font-size: 15px; line-height: 1.65; }
.analytics-row { font-size: 14px; }

@media (max-width: 920px) {
  .main-nav a { font-size: 17px; padding: 12px 14px; }
  .fixture-row { gap: 10px; }
}

@media (max-width: 640px) {
  .hero-center > p,
  .page-hero p,
  .admin-hero p { font-size: 15px; }
  .slide-copy p { font-size: 13px; }
  .date-chip { font-size: 13px; }
  .fixture-teams { font-size: 14px; }
  .fixture-info b,
  .fixture-info small { font-size: 13px; }
  .result-meta { font-size: 13px; }
  .result-team { font-size: 15px; }
  table { font-size: 14px; }
  th { font-size: 12px; }
  .admin-matches form { font-size: 13px; }
}

/* Resultados manuales y goleadores */
.results-admin-panel { grid-column: 1 / -1; }
.manual-match-list { display: grid; gap: 10px; margin-top: 18px; }
.manual-match { border: 1px solid #e6e1f2; border-radius: 15px; background: #fbfaff; overflow: hidden; }
.manual-match summary { display: grid; grid-template-columns: 45px minmax(180px,1fr) auto auto auto; align-items: center; gap: 10px; padding: 14px; cursor: pointer; font-size: 16px; }
.manual-score { font-weight: 800; }
.origin-badge, .manual-lock { padding: 5px 8px; border-radius: 8px; font-size: 14px; font-weight: 800; }
.origin-manual { background: #fff0d8; color: #8a5800; }
.origin-api { background: #e5f0ff; color: #1e65b4; }
.origin-api_revisado_manualmente { background: #e7f8ef; color: #08764c; }
.manual-lock { background: #ffe4e5; color: #b8232b; }
.manual-result-form { padding: 16px; border-top: 1px solid #e6e1f2; background: white; }
.result-form-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 10px; }
.result-form-grid label, .score-editor label { display: grid; gap: 5px; color: var(--muted); font-size: 15px; font-weight: 700; }
.result-form-grid input, .result-form-grid select, .score-editor input, .goal-editor-row input, .goal-editor-row select {
  width: 100%; border: 1px solid #dcd6ea; border-radius: 9px; padding: 9px; color: var(--ink); background: #fff; font-size: 16px;
}
.score-editor { display: grid; grid-template-columns: 1fr auto 1fr; align-items: end; gap: 12px; max-width: 430px; margin: 16px auto; }
.score-editor > span { padding-bottom: 10px; font-weight: 800; }
.score-editor input { text-align: center; font: 700 22px "Fredoka"; }
.extra-scores { grid-template-columns: repeat(4,minmax(0,1fr)); }
.goals-editor { margin-top: 18px; }
.goals-editor-heading { display: flex; align-items: center; justify-content: space-between; }
.goals-editor-heading h3 { margin: 0; }
.goal-editor-row { display: grid; grid-template-columns: 150px minmax(180px,1fr) 70px 60px auto auto auto; gap: 7px; align-items: center; margin-top: 8px; padding: 9px; border-radius: 11px; background: #f8f7fc; }
.check-label { display: inline-flex; align-items: center; gap: 5px; font-size: 14px; white-space: nowrap; }
.check-label input { width: auto; }
.remove-goal { border: 0; border-radius: 8px; padding: 8px; color: #b8232b; background: #ffe5e6; cursor: pointer; font-size: 14px; font-weight: 800; }
.manual-form-actions { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.sync-button { background: #e7efff; color: #1f68c8; }
.result-log-list { display: grid; gap: 8px; max-height: 520px; overflow: auto; }
.result-log { padding: 10px; border-left: 4px solid var(--blue); border-radius: 8px; background: #faf9fd; }
.result-log-warning { border-color: var(--gold); }
.result-log-error { border-color: #d9363e; }
.result-log small, .result-log b { display: block; }
.result-log small { color: var(--muted); font-size: 14px; }
.result-log p { margin: 5px 0 0; font-size: 15px; line-height: 1.5; }
.public-goals { display: grid; gap: 8px; margin: 10px 0; padding: 10px; border-radius: 10px; background: #faf9fd; font-size: 15px; }
.public-goals div, .public-goals span { display: block; }
.public-goals .goals-team { display: flex; align-items: center; gap: 6px; margin-bottom: 3px; color: var(--ink); }
.public-goals .goals-team strong { min-width: 0; overflow-wrap: anywhere; }
.public-goals .goals-team .inline-flag-image { flex: 0 0 auto; margin-right: 0; }
.public-goals span { margin-top: 3px; color: var(--muted); }
.penalty-result, .extra-result { margin: 8px 0; color: var(--purple); font-size: 15px; font-weight: 800; }
.goals-pending { margin: 9px 0; color: var(--muted); font-size: 15px; font-style: italic; }
.install-report { margin: 18px 0; padding: 16px; border: 1px solid #b9e8d1; border-radius: 13px; background: #ecfbf3; text-align: left; }
.install-report h3 { margin: 0 0 8px; color: #08764c; }
.install-report ul { margin: 0; padding-left: 20px; }
.install-report li { margin: 6px 0; font-size: 15px; line-height: 1.45; }
.fixture-goals { grid-column: 3 / 5; }

@media (max-width: 920px) {
  .goal-editor-row { grid-template-columns: 1fr 1fr 70px 60px; }
  .goal-editor-row .check-label, .goal-editor-row .remove-goal { justify-self: start; }
}

@media (max-width: 640px) {
  .manual-match summary { grid-template-columns: 38px 1fr auto; }
  .manual-match summary .origin-badge, .manual-match summary .manual-lock { grid-column: span 1; }
  .result-form-grid, .extra-scores { grid-template-columns: 1fr 1fr; }
  .goal-editor-row { grid-template-columns: 1fr 72px 55px; }
  .goal-editor-row select, .goal-editor-row input[placeholder="Nombre completo"] { grid-column: span 3; }
  .fixture-goals { grid-column: 3; }
}

/* Comunidad, reacciones y compartir */
.community-section { max-width: 1180px; margin: 28px auto; padding: 26px; }
.community-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 18px; }
.community-heading h2 { margin: 4px 0 0; }
.share-main-button { color: white; background: linear-gradient(135deg, #6c3df4, #9b50e8); box-shadow: 0 8px 20px rgba(89,47,199,.22); }
.community-grid, .guestbook-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.guestbook-layout { margin-top: 16px; }
.community-card { padding: 22px; border: 1px solid #ece7f5; border-radius: 20px; background: white; box-shadow: var(--shadow); }
.community-card h3 { margin: 0 0 7px; font-size: 21px; }
.community-card > p { margin: 0 0 15px; color: var(--muted); font-size: 15px; line-height: 1.5; }
.reaction-buttons { display: grid; grid-template-columns: repeat(2, 1fr); gap: 9px; }
.reaction-buttons button { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 8px; min-height: 48px; padding: 10px 12px; border: 1px solid #e4def0; border-radius: 12px; color: var(--ink); background: #faf9fd; cursor: pointer; text-align: left; font-size: 15px; }
.reaction-buttons button:hover, .reaction-buttons button.reacted { border-color: #7a46e8; background: #f0eaff; }
.reaction-buttons button span { font-size: 20px; }
.reaction-buttons button small { min-width: 30px; color: var(--purple); font-size: 14px; font-weight: 800; text-align: right; }
.share-card[hidden] { display: none; }
.share-options { display: flex; flex-wrap: wrap; gap: 8px; }
.share-options a, .share-options button { padding: 10px 13px; border: 0; border-radius: 10px; color: #4d2d9e; background: #eee8ff; cursor: pointer; font: 700 15px "DM Sans", sans-serif; text-decoration: none; }
.interaction-message { min-height: 22px; margin: 12px 0 0 !important; color: #08764c !important; font-size: 15px !important; font-weight: 700; }
.guestbook-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
[data-guestbook-form] label { display: grid; gap: 6px; margin-bottom: 12px; color: var(--muted); font-size: 15px; font-weight: 700; }
[data-guestbook-form] label small { font-size: 13px; font-weight: 500; }
[data-guestbook-form] input, [data-guestbook-form] textarea { width: 100%; border: 1px solid #dcd6ea; border-radius: 10px; padding: 11px; color: var(--ink); background: white; font: 400 16px "DM Sans", sans-serif; }
[data-guestbook-form] textarea { min-height: 105px; resize: vertical; }
.guestbook-list { display: grid; gap: 10px; max-height: 350px; overflow: auto; }
.guestbook-list blockquote { margin: 0; padding: 13px; border-left: 4px solid var(--purple); border-radius: 10px; background: #faf9fd; }
.guestbook-list blockquote p { margin: 0; font-size: 15px; line-height: 1.5; }
.guestbook-list blockquote footer { margin-top: 7px; padding: 0; color: var(--muted); background: transparent; font-size: 14px; text-align: left; }
.footer-visits { font-size: 15px; }
.guestbook-admin-panel { grid-column: 1 / -1; }
.admin-guestbook-list { display: grid; gap: 10px; margin-top: 14px; }
.admin-guestbook-entry { padding: 14px; border: 1px solid #e5dff0; border-left: 5px solid var(--gold); border-radius: 12px; background: #faf9fd; }
.admin-guestbook-entry.status-aprobado { border-left-color: #18a56d; }
.admin-guestbook-entry.status-rechazado { border-left-color: #c6bfce; opacity: .8; }
.admin-guestbook-entry header { display: flex; justify-content: space-between; gap: 12px; font-size: 15px; }
.admin-guestbook-entry header span { color: var(--muted); font-size: 14px; }
.admin-guestbook-entry p { margin: 10px 0; font-size: 16px; line-height: 1.5; }
.guestbook-admin-actions, .guestbook-admin-actions form { display: flex; gap: 8px; flex-wrap: wrap; }
.reject-button { color: #7d5220; background: #fff1d7; }
.results-admin-panel > form:nth-of-type(1) button.small-button:last-child { display: none; }

@media (max-width: 720px) {
  .community-section { margin: 18px 14px; padding: 0; }
  .community-heading { align-items: stretch; flex-direction: column; }
  .share-main-button { width: 100%; min-height: 48px; }
  .community-grid, .guestbook-layout { grid-template-columns: 1fr; }
  .community-card { padding: 18px; }
  .reaction-buttons, .guestbook-fields { grid-template-columns: 1fr; }
  .admin-guestbook-entry header { flex-direction: column; }
}

/* Produccion: llaves limpias sin conectores temporales. */
.bracket-section .bracket-stage .bracket-match::before,
.bracket-section .bracket-stage .bracket-match::after,
.bracket-section .bracket-match::before,
.bracket-section .bracket-match::after {
  content: none !important;
  display: none !important;
  width: 0 !important;
  height: 0 !important;
  border: 0 !important;
}

.bracket-section .bracket-grid {
  min-height: 0 !important;
  align-items: start !important;
}

.bracket-section .bracket-matches {
  justify-content: flex-start !important;
  padding-block: 4px !important;
}

/* Llaves publicas: vista continua, limpia y legible. */
.bracket-section .bracket-scroll {
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x proximity;
  padding: 8px 2px 18px;
}

.bracket-section .bracket-grid {
  grid-template-columns: repeat(6, minmax(205px, 1fr)) !important;
  gap: clamp(24px, 3vw, 42px) !important;
  min-width: 1420px !important;
}

.bracket-section .bracket-stage {
  scroll-snap-align: start;
}

.bracket-section .bracket-stage h3 {
  position: static;
  margin-bottom: 14px;
  padding: 12px 14px;
  border-radius: 14px;
  background: linear-gradient(135deg, #322061, #5d35b4);
  box-shadow: 0 8px 18px rgba(50,32,97,.14);
  letter-spacing: .02em;
}

.bracket-section .bracket-matches {
  gap: 12px !important;
}

.bracket-section .bracket-match {
  display: grid;
  grid-template-rows: auto minmax(30px, 1fr) minmax(30px, 1fr);
  gap: 5px;
  min-height: 118px;
  padding: 10px;
  border-color: #e5e0f0;
  box-shadow: 0 7px 18px rgba(45,32,92,.07);
}

.bracket-section .bracket-match > small:not(.bracket-meta) {
  display: none;
}

.bracket-section .bracket-meta {
  display: grid;
  gap: 2px;
  margin-bottom: 2px;
  color: #6d6384;
  font-size: 10px;
  line-height: 1.25;
}

.bracket-section .bracket-meta b {
  color: #2f225d;
  font-size: 12px;
  font-weight: 900;
}

.bracket-section .bracket-meta span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bracket-section .bracket-match > span {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  padding: 5px 6px;
  border-radius: 9px;
  background: #faf9fd;
  font-size: 12px;
}

.bracket-section .bracket-match > span b {
  min-width: 0;
  overflow-wrap: anywhere;
}

.bracket-section .bracket-match > span strong {
  font-size: 16px;
}

@media (max-width: 1080px) {
  .bracket-section .bracket-grid {
    min-width: 1320px !important;
  }
}

@media (max-width: 640px) {
  .bracket-section .bracket-scroll {
    scroll-snap-type: x mandatory;
  }
  .bracket-section .bracket-grid {
    grid-template-columns: repeat(6, 245px) !important;
    min-width: max-content !important;
    gap: 16px !important;
  }
}
