/* ===================== RESET / BASE ===================== */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg:        #0a1428;
  --bg-2:      #0d1a33;
  --card:      #102444;
  --card-2:    #0e1f3d;
  --border:    #1d3a63;
  --gold:      #f5b827;
  --gold-2:    #e0a216;
  --text:      #e8eef7;
  --muted:     #8ba0bf;
  --blue-link: #4a9eff;
  --green:     #28a745;
  --red:       #d63b3b;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  font-size: 14px;
}

.container { max-width: 1024px; margin: 0 auto; padding: 0 18px; }

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

h1, h2, h3, .brand-title, .hero-title, .btn-bet-top, .btn-gold, .group-tab {
  font-family: 'Oswald', sans-serif;
  letter-spacing: .5px;
}

/* ===================== HEADER ===================== */
.site-header {
  background: var(--bg-2);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 50;
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
}
.brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand-logo {
  width: 46px; height: 46px; border-radius: 50%; object-fit: cover;
  box-shadow: 0 0 12px rgba(245,184,39,.35);
}
.brand-text { display: flex; flex-direction: column; justify-content: center; }
.brand-title { font-size: 20px; font-weight: 700; color: #fff; white-space: nowrap; line-height: 1.05; }
.brand-sub { font-size: 8.5px; letter-spacing: 2px; color: var(--gold); white-space: nowrap; line-height: 1.4; margin-top: 1px; }

.main-nav { display: flex; gap: 15px; flex: 1; justify-content: center; }
.main-nav a {
  font-size: 12.5px; font-weight: 600; color: var(--text);
  letter-spacing: .3px; transition: color .2s; white-space: nowrap;
}
.main-nav a:hover, .main-nav a.active { color: var(--gold); }

.header-actions { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.btn-bet {
  background: linear-gradient(180deg, var(--gold), var(--gold-2));
  color: #1a1200; border-radius: 8px; padding: 7px 18px;
  display: flex; flex-direction: column; align-items: center; line-height: 1.2;
  box-shadow: 0 4px 14px rgba(245,184,39,.3); white-space: nowrap;
}
.btn-bet-top { font-size: 14px; font-weight: 700; }
.btn-bet-sub { font-size: 9px; font-weight: 700; letter-spacing: 1px; }
.user-icon {
  width: 36px; height: 36px; border: 1px solid var(--border); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-size: 16px;
}

/* ===================== HERO ===================== */
.hero {
  position: relative;
  background: linear-gradient(180deg, #0d1a33 0%, #0a1428 100%);
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
}
.hero-banner-img {
  width: 100%; height: auto; display: block; border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0,0,0,.4);
}
.hero-overlay {
  position: absolute; inset: 0;
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,.015) 0 2px, transparent 2px 40px),
    radial-gradient(ellipse at 50% 0%, rgba(120,170,230,.25), transparent 60%);
  pointer-events: none;
}
.hero-inner {
  position: relative; z-index: 2;
  display: grid;
  grid-template-columns: 1fr 1.1fr 1.4fr 1.1fr 1fr;
  align-items: center;
  min-height: 400px;
  gap: 10px;
  padding: 24px 18px 30px;
}

/* Player photo placeholders (swap background-image with real photos) */
.hero-player { display: flex; align-items: flex-end; height: 100%; }
.hero-player-left { justify-content: flex-start; }
.hero-player-right { justify-content: flex-end; }
.player-photo {
  width: 170px; height: 340px; border-radius: 8px;
  display: flex; align-items: flex-start; justify-content: center;
  padding-top: 18px; font-family: 'Oswald'; font-size: 40px; font-weight: 700;
  color: rgba(255,255,255,.85);
  background-size: cover; background-position: top center;
}
.player-messi {
  background:
    linear-gradient(180deg, rgba(255,255,255,.12), transparent 40%),
    linear-gradient(160deg, #9fd0ec 0%, #6fa9d6 45%, #14335c 100%);
}
.player-mbappe {
  background:
    linear-gradient(180deg, rgba(255,255,255,.10), transparent 40%),
    linear-gradient(200deg, #2b4d8a 0%, #16294d 60%, #0c1730 100%);
}

.hero-team { text-align: center; padding: 0 6px; }
.team-crest { font-size: 36px; margin-bottom: 6px; }
.team-name { font-size: 30px; font-weight: 700; color: #fff; letter-spacing: 2px; }
.team-titles { color: var(--gold); font-weight: 700; font-size: 14px; margin-top: 8px; }
.team-years { color: var(--gold); font-weight: 700; font-size: 14px; }
.team-desc { color: var(--muted); font-size: 12px; margin-top: 10px; line-height: 1.5; }

.hero-trophy { text-align: center; }
.trophy { font-size: 130px; line-height: 1; filter: drop-shadow(0 0 30px rgba(245,184,39,.55)); }
.hero-title {
  color: #fff; font-size: 26px; font-weight: 600; margin-top: 6px; letter-spacing: 1px;
}

/* ===================== JAVO88 BRAND BANNER ===================== */
.javo-banner {
  display: flex; align-items: center; gap: 20px;
  background: linear-gradient(135deg, #15294d 0%, #0e1f3d 60%, #1a1405 100%);
  border: 1px solid var(--gold-2); border-radius: 12px;
  padding: 18px 24px; margin-top: 18px;
  box-shadow: 0 0 30px rgba(245,184,39,.12) inset;
}
.javo-banner-logo {
  width: 92px; height: 92px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
  box-shadow: 0 0 22px rgba(245,184,39,.5);
}
.javo-banner-text { flex: 1; }
.javo-banner-text h2 {
  font-family: 'Oswald'; font-size: 22px; color: var(--gold); letter-spacing: 1px;
}
.javo-banner-text p { color: var(--muted); font-size: 13px; margin-top: 4px; }
.javo-banner-cta { white-space: nowrap; flex-shrink: 0; text-align: center; }

/* ===================== QUICK NAV ===================== */
.quicknav {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
  background: var(--card-2); border: 1px solid var(--border);
  border-radius: 10px; padding: 16px 20px; margin: 18px 0;
}
.quicknav-item {
  font-family: 'Oswald'; font-size: 13px; font-weight: 600; letter-spacing: .5px;
  display: flex; align-items: center; gap: 8px; color: var(--text); flex: 1;
  justify-content: center; border-right: 1px solid var(--border);
}
.quicknav-item:last-child { border-right: none; }
.quicknav-item:hover { color: var(--gold); }
.qn-icon { color: var(--gold); }

/* ===================== CARDS ===================== */
.card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 12px; padding: 20px; margin-bottom: 18px;
}
.card-head {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px;
}
.card-head h3 { font-size: 18px; font-weight: 600; color: #fff; display: flex; align-items: center; gap: 8px; }
.card-ic { color: var(--gold); }
.link-all { color: var(--blue-link); font-size: 13px; }
.block-title { font-family: 'Oswald'; font-size: 22px; color: #fff; margin-bottom: 18px; }
.muted { color: var(--muted); font-size: 13px; }
.gold { color: var(--gold); }

/* ===================== GRIDS ===================== */
.main-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 18px;
  align-items: stretch;
}
.left-col, .right-col { display: flex; flex-direction: column; }

/* fill the column height so all three columns end evenly (no empty gap) */
#h2h { display: flex; flex-direction: column; justify-content: space-between; }
.right-col .promo { flex: 1; display: flex; flex-direction: column; justify-content: center; }
/* Score Table card grows to fill the left column down to the same bottom line */
.left-col > .card:last-child { flex: 1; display: flex; flex-direction: column; }
.left-col > .card:last-child .standings { flex: 1; }
.three-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 18px; }
.two-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 18px; }

/* ===================== MATCH TABLE ===================== */
.match-table, .standings { width: 100%; border-collapse: collapse; font-size: 12px; }
.match-table th, .standings th {
  text-align: left; color: var(--muted); font-weight: 600; font-size: 11px;
  padding: 8px 4px; border-bottom: 1px solid var(--border); white-space: nowrap;
}
.match-table td {
  padding: 11px 4px; border-bottom: 1px solid rgba(29,58,99,.5); color: var(--text);
  white-space: nowrap;
}
.match-table th:last-child, .match-table td:last-child { text-align: right; }
.match-cell { font-weight: 500; }
.vs { color: var(--muted); margin: 0 5px; font-size: 11px; }

/* ===================== HEAD TO HEAD ===================== */
.h2h-flags { display: flex; align-items: center; justify-content: space-around; margin: 6px 0 14px; }
.h2h-side { display: flex; flex-direction: column; align-items: center; gap: 6px; font-weight: 600; }
.h2h-flag { font-size: 44px; line-height: 1; }
.h2h-vs { font-family: 'Oswald'; font-size: 26px; font-weight: 700; color: var(--gold); }
.h2h-label { text-align: center; color: var(--muted); font-size: 12px; margin-bottom: 10px; }
.h2h-form { display: flex; justify-content: center; gap: 6px; margin-bottom: 16px; }
.h2h-form span {
  width: 26px; height: 26px; border-radius: 5px; display: flex; align-items: center;
  justify-content: center; font-size: 12px; font-weight: 700; color: #fff;
}
.form-w { background: var(--green); }
.form-d { background: var(--gold); color: #1a1200; }
.form-l { background: var(--red); }
.h2h-stats { margin-bottom: 16px; }
.h2h-row {
  display: grid; grid-template-columns: 1fr auto auto; gap: 24px;
  padding: 9px 0; border-bottom: 1px solid rgba(29,58,99,.5); align-items: center;
}
.h2h-row span { color: var(--muted); }
.h2h-row strong { font-size: 16px; min-width: 24px; text-align: center; }
.h2h-row strong.center { grid-column: 2 / 4; }

/* ===================== BUTTONS ===================== */
.btn-gold {
  background: linear-gradient(180deg, var(--gold), var(--gold-2));
  color: #1a1200; border: none; border-radius: 7px; padding: 12px 22px;
  font-weight: 700; font-size: 14px; cursor: pointer; letter-spacing: .5px;
  box-shadow: 0 4px 14px rgba(245,184,39,.25);
}
.btn-gold:hover { filter: brightness(1.06); }
.btn-outline {
  background: transparent; color: var(--text); border: 1px solid var(--border);
  border-radius: 7px; padding: 11px 18px; font-weight: 600; font-size: 13px; cursor: pointer;
}
.btn-outline:hover { border-color: var(--gold); color: var(--gold); }
.full { width: 100%; margin-top: 6px; }

/* ===================== LIVE MATCH ===================== */
.live-row {
  display: flex; align-items: center; gap: 12px; padding: 11px 12px;
  background: var(--card-2); border: 1px solid var(--border); border-radius: 8px; margin: 10px 0;
}
.live-ic {
  width: 38px; height: 38px; border-radius: 7px; display: flex; align-items: center;
  justify-content: center; font-weight: 700; color: #fff; font-size: 13px; flex-shrink: 0;
}
.live-ic.fb { background: #1877f2; }
.live-ic.espn { background: #cc0000; font-size: 11px; }
.live-ic.sbobet { background: #0a3d62; }
.live-info { display: flex; flex-direction: column; flex: 1; }
.live-info strong { font-size: 13px; }
.live-info span { font-size: 11px; color: var(--muted); }
.live-badge {
  background: var(--red); color: #fff; font-size: 10px; font-weight: 700;
  padding: 3px 8px; border-radius: 4px; letter-spacing: 1px;
}

/* ===================== PROMO ===================== */
.promo {
  background: linear-gradient(160deg, #15294d, #0e1f3d);
  border-color: var(--gold-2);
}
.promo-title { font-size: 20px; color: var(--gold); margin-bottom: 8px; }
.promo-body { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 16px 0 12px; }
.promo-logo {
  width: 84px; height: 84px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
  box-shadow: 0 0 18px rgba(245,184,39,.45);
}
.promo-foot { text-align: center; color: var(--muted); font-size: 11px; }

/* ===================== STANDINGS ===================== */
.group-tabs { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: nowrap; }
.group-tab {
  background: var(--card-2); border: 1px solid var(--border); color: var(--muted);
  padding: 7px 12px; border-radius: 6px; font-size: 12px; font-weight: 600; cursor: pointer;
  white-space: nowrap; flex: 1;
}
.group-tab.active { background: var(--gold); color: #1a1200; border-color: var(--gold); }
.standings th, .standings td { text-align: center; padding: 9px 4px; }
.standings th.left, .standings td.left { text-align: left; }
.standings td { border-bottom: 1px solid rgba(29,58,99,.5); }
.standings .pts { color: var(--gold); font-weight: 700; }

/* ===================== TOURNAMENT STATS ===================== */
.stat-row {
  display: flex; align-items: center; gap: 12px; padding: 11px 0;
  border-bottom: 1px solid rgba(29,58,99,.5);
}
.stat-avatar {
  width: 40px; height: 40px; border-radius: 50%; background: var(--card-2);
  border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
  font-size: 18px; flex-shrink: 0;
}
.stat-info { display: flex; flex-direction: column; flex: 1; }
.stat-label { font-size: 11px; color: var(--muted); }
.stat-info strong { font-size: 14px; }
.stat-val { color: var(--gold); font-weight: 700; font-size: 14px; }

/* ===================== QUALIFIED NATIONS ===================== */
.nations-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px 8px; }
.nation {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  font-size: 12px; color: var(--text);
}
.nation-flag { font-size: 30px; line-height: 1; }

/* ===================== TEAM HIGHLIGHTS ===================== */
.hl-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid rgba(29,58,99,.5); }
.hl-crest { font-size: 34px; line-height: 1; flex-shrink: 0; }
.hl-info { display: flex; flex-direction: column; }
.hl-info strong { font-size: 16px; }
.hl-info span { font-size: 12px; color: var(--muted); }

/* ===================== COMMENTS ===================== */
.comment {
  display: grid; grid-template-columns: auto 1fr auto; gap: 12px;
  align-items: start; padding: 14px 0; border-bottom: 1px solid rgba(29,58,99,.5);
}
.comment-avatar {
  width: 38px; height: 38px; border-radius: 50%; background: var(--card-2);
  border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
  font-size: 18px; flex-shrink: 0;
}
.comment-meta { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.comment-meta strong { font-size: 14px; }
.comment-meta span { font-size: 11px; color: var(--muted); }
.comment-body p { font-size: 13px; }
.comment-actions { display: flex; align-items: center; gap: 12px; font-size: 12px; color: var(--muted); }
.comment-actions a { color: var(--gold); }
.comment-form { display: flex; gap: 12px; margin-top: 16px; }
.comment-form textarea {
  flex: 1; background: var(--card-2); border: 1px solid var(--border); border-radius: 8px;
  padding: 12px; color: var(--text); font-family: inherit; resize: vertical; min-height: 70px;
}
.comment-form textarea::placeholder { color: var(--muted); }

/* ===================== COMMUNITY ===================== */
.community .btn-telegram {
  width: 100%; background: linear-gradient(180deg, #2aa3e0, #1c87c7); color: #fff;
  border: none; border-radius: 8px; padding: 13px; font-weight: 700; font-size: 14px;
  cursor: pointer; margin: 18px 0; display: flex; align-items: center; justify-content: center; gap: 8px;
}
.community-handle { display: flex; align-items: center; gap: 12px; }
.community-handle strong { display: block; font-size: 14px; }

/* ===================== FOOTER ===================== */
.site-footer { border-top: 1px solid var(--border); margin-top: 24px; padding: 22px 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; }
.footer-inner p { color: var(--muted); font-size: 12px; }
.socials { display: flex; gap: 10px; }
.socials a {
  width: 34px; height: 34px; border-radius: 50%; background: var(--card-2);
  border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
  font-size: 14px;
}
.socials a:hover { color: var(--gold); border-color: var(--gold); }

/* ===================== RESPONSIVE ===================== */
@media (max-width: 980px) {
  .main-nav { display: none; }
  .main-grid, .three-grid, .two-grid { grid-template-columns: 1fr; }
  .hero-inner { grid-template-columns: 1fr 1fr; }
  .hero-player, .hero-trophy { display: none; }
  .quicknav-item { border-right: none; flex: 1 1 40%; }
  .javo-banner { flex-direction: column; text-align: center; }
}
@media (max-width: 560px) {
  .hero-inner { grid-template-columns: 1fr; }
  .nations-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-inner { flex-direction: column; gap: 12px; }
}
