/* ===== MODERN RESET & VARIABLES ===== */
:root {
  --bg-primary: #070b12;
  --bg-secondary: #0e1520;
  --bg-card: #151f2e;
  --bg-card-hover: #1c2a3d;
  --bg-elevated: #1a2536;
  --accent: #00e0a0;
  --accent-glow: rgba(0, 224, 160, 0.3);
  --accent-secondary: #ff4d6d;
  --accent-gradient: linear-gradient(135deg, #00e0a0 0%, #00b8d9 100%);
  --text-primary: #f0f4f8;
  --text-secondary: #8899b0;
  --text-muted: #5a6b82;
  --border: #223044;
  --border-light: #2e4058;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 30px var(--accent-glow);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Cairo', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  direction: rtl;
  line-height: 1.6;
  overflow-x: hidden;
}

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }
::selection { background: var(--accent); color: var(--bg-primary); }
a { color: inherit; text-decoration: none; transition: var(--transition); }

.container { max-width: 1280px; margin: 0 auto; padding: 0 20px; }

/* ===== HEADER ===== */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(7, 11, 18, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 20px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.5px;
  white-space: nowrap;
}

.logo-icon {
  width: 42px;
  height: 42px;
  background: var(--accent-gradient);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: var(--shadow-glow);
  animation: logoPulse 3s ease-in-out infinite;
}

@keyframes logoPulse {
  0%, 100% { box-shadow: 0 0 20px var(--accent-glow); }
  50% { box-shadow: 0 0 35px var(--accent-glow); }
}

.logo-text .brand { color: var(--text-primary); }
.logo-text .brand span { color: var(--accent); }
.logo-text .tagline {
  font-size: 10px;
  font-weight: 400;
  color: var(--text-muted);
  letter-spacing: 2px;
  text-transform: uppercase;
  display: block;
  margin-top: -4px;
}

nav { display: flex; align-items: center; gap: 4px; }

.nav-link {
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  position: relative;
  white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
  color: var(--text-primary);
  background: var(--bg-card);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 20px;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

.header-actions { display: flex; align-items: center; gap: 10px; }

.icon-btn {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  font-size: 18px;
}

.icon-btn:hover {
  background: var(--bg-card-hover);
  color: var(--accent);
  border-color: var(--accent);
  transform: translateY(-2px);
}

.live-badge-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: rgba(255, 77, 109, 0.15);
  border: 1px solid rgba(255, 77, 109, 0.3);
  border-radius: var(--radius-md);
  font-size: 12px;
  font-weight: 700;
  color: var(--accent-secondary);
}

.live-dot {
  width: 8px;
  height: 8px;
  background: var(--accent-secondary);
  border-radius: 50%;
  animation: livePulse 1.5s ease-in-out infinite;
}

@keyframes livePulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(255, 77, 109, 0.6); }
  50% { opacity: 0.7; box-shadow: 0 0 0 6px rgba(255, 77, 109, 0); }
}

.mobile-menu-btn { display: none; }

/* ===== HERO ===== */
.hero {
  margin-top: 72px;
  position: relative;
  padding: 60px 0 40px;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%; right: -20%;
  width: 600px; height: 600px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  opacity: 0.3;
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%; left: -10%;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(0, 184, 217, 0.2) 0%, transparent 70%);
  opacity: 0.3;
  pointer-events: none;
}

.hero-inner { position: relative; z-index: 1; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 50px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 20px;
}

.hero h1 {
  font-size: clamp(28px, 5vw, 48px);
  font-weight: 900;
  line-height: 1.2;
  margin-bottom: 16px;
  letter-spacing: -1px;
}

.hero h1 .gradient-text {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 600px;
  margin-bottom: 28px;
}

.hero-stats { display: flex; gap: 32px; flex-wrap: wrap; }
.stat-item { display: flex; flex-direction: column; }
.stat-value { font-size: 28px; font-weight: 800; color: var(--accent); line-height: 1; }
.stat-label { font-size: 12px; color: var(--text-muted); margin-top: 4px; font-weight: 500; }

/* ===== FEATURED MATCH ===== */
.featured-match {
  margin-top: 40px;
  background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-elevated) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px;
  position: relative;
  overflow: hidden;
}

.featured-match::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--accent-gradient);
}

.featured-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  background: rgba(255, 77, 109, 0.15);
  border: 1px solid rgba(255, 77, 109, 0.3);
  border-radius: 50px;
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-secondary);
  margin-bottom: 20px;
}

.featured-teams {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.featured-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.featured-team .team-logo {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  border: 2px solid var(--border-light);
  transition: var(--transition);
  overflow: hidden;
}

.featured-team .team-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 8px;
}

.featured-team:hover .team-logo {
  border-color: var(--accent);
  box-shadow: var(--shadow-glow);
  transform: scale(1.05);
}

.featured-team .team-name { font-size: 16px; font-weight: 700; text-align: center; }

.featured-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-width: 120px;
}

.featured-score {
  font-size: 42px;
  font-weight: 900;
  letter-spacing: 4px;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.featured-time { font-size: 14px; color: var(--text-secondary); font-weight: 600; }

.featured-league {
  margin-top: 20px;
  text-align: center;
  font-size: 13px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

/* ===== MAIN SECTION ===== */
.main-section { padding: 40px 0 80px; }

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.section-title .title-icon {
  width: 36px;
  height: 36px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.filter-tabs {
  display: flex;
  gap: 8px;
  background: var(--bg-card);
  padding: 6px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  overflow-x: auto;
  scrollbar-width: none;
}

.filter-tabs::-webkit-scrollbar { display: none; }

.filter-tab {
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
  border: none;
  background: transparent;
  font-family: inherit;
}

.filter-tab:hover { color: var(--text-primary); }

.filter-tab.active {
  background: var(--accent-gradient);
  color: var(--bg-primary);
  box-shadow: var(--shadow-glow);
}

.league-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 24px;
  scrollbar-width: none;
}

.league-chips::-webkit-scrollbar { display: none; }

.league-chip {
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 50px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
  font-family: inherit;
}

.league-chip:hover { border-color: var(--accent); color: var(--text-primary); }
.league-chip.active { background: var(--accent); color: var(--bg-primary); border-color: var(--accent); font-weight: 700; }

/* ===== MATCHES GRID ===== */
.matches-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

.match-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
  position: relative;
  display: flex;
  flex-direction: column;
  animation: cardFadeIn 0.4s ease backwards;
}

@keyframes cardFadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.match-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-light);
  box-shadow: var(--shadow-lg);
}

.match-card.status-live { border-color: rgba(255, 77, 109, 0.4); }
.match-card.status-live::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-secondary), #ff8a9b);
}

.match-card.status-finished { opacity: 0.85; }

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.15);
}

.card-league {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

.card-league .league-icon { font-size: 14px; }

.status-pill {
  padding: 4px 10px;
  border-radius: 50px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.status-pill.live {
  background: rgba(255, 77, 109, 0.2);
  color: var(--accent-secondary);
  border: 1px solid rgba(255, 77, 109, 0.3);
  animation: livePulse 1.5s ease-in-out infinite;
}

.status-pill.upcoming {
  background: rgba(0, 224, 160, 0.12);
  color: var(--accent);
  border: 1px solid rgba(0, 224, 160, 0.25);
}

.status-pill.finished {
  background: rgba(136, 153, 176, 0.12);
  color: var(--text-secondary);
  border: 1px solid rgba(136, 153, 176, 0.2);
}

.card-body { padding: 20px 18px; flex: 1; display: flex; flex-direction: column; gap: 16px; }

.teams-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

.team-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.team-logo-sm {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  border: 1.5px solid var(--border-light);
  transition: var(--transition);
  flex-shrink: 0;
  overflow: hidden;
}

.team-logo-sm img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 6px;
}

.team-block:hover .team-logo-sm {
  border-color: var(--accent);
  transform: scale(1.08);
  box-shadow: var(--shadow-glow);
}

.team-name-sm {
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

.score-block { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 80px; }

.score-value {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: 2px;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.score-value.live { color: var(--accent-secondary); }

.match-time-sm {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  padding: 4px 10px;
  border-radius: 6px;
}

.scorers {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0 0;
  border-top: 1px dashed var(--border);
  font-size: 11px;
  color: var(--text-muted);
}

.scorers-side { display: flex; flex-direction: column; gap: 2px; }
.scorers-side.right { align-items: flex-end; text-align: left; }
.scorer-item { white-space: nowrap; }

.card-footer { padding: 0 18px 18px; }

.watch-btn {
  width: 100%;
  padding: 12px;
  background: var(--accent-gradient);
  border: none;
  border-radius: var(--radius-md);
  color: var(--bg-primary);
  font-family: inherit;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.watch-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-glow); }
.watch-btn:active { transform: translateY(0); }

.watch-btn.disabled {
  background: var(--bg-secondary);
  color: var(--text-muted);
  cursor: not-allowed;
  box-shadow: none;
}

.watch-btn.disabled:hover { transform: none; box-shadow: none; }

.no-matches {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 20px;
  color: var(--text-muted);
}

.no-matches .icon { font-size: 48px; margin-bottom: 16px; opacity: 0.5; }
.no-matches p { font-size: 16px; }

/* ===== MODAL ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.2s ease;
}

.modal-overlay.active { display: flex; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.modal-content {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 900px;
  overflow: hidden;
  animation: slideUp 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-lg);
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(30px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.modal-title { font-size: 16px; font-weight: 700; }

.modal-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  transition: var(--transition);
}

.modal-close:hover { background: var(--accent-secondary); color: white; }

.modal-video-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.modal-video-wrapper iframe,
.modal-video-wrapper video {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.modal-video-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: var(--text-secondary);
  text-align: center;
  padding: 20px;
}

.modal-video-placeholder .big-icon { font-size: 56px; opacity: 0.4; }
.modal-video-placeholder p { font-size: 14px; max-width: 400px; }

.modal-video-placeholder .external-link {
  padding: 12px 24px;
  background: var(--accent-gradient);
  color: var(--bg-primary);
  border-radius: var(--radius-md);
  font-weight: 800;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.modal-video-placeholder .external-link:hover { box-shadow: var(--shadow-glow); transform: translateY(-2px); }

.modal-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  gap: 12px;
  flex-wrap: wrap;
}

.quality-selector { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-secondary); }

.quality-badge {
  padding: 4px 10px;
  border-radius: 6px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  font-size: 11px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 0.3px;
}

.quality-selector select {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text-primary);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  outline: none;
}

.quality-selector select:focus { border-color: var(--accent); }

.modal-note { font-size: 11px; color: var(--text-muted); display: flex; align-items: center; gap: 6px; }

/* ===== FOOTER ===== */
footer {
  border-top: 1px solid var(--border);
  background: var(--bg-secondary);
  padding: 40px 0 24px;
  margin-top: 40px;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.footer-brand { max-width: 300px; }
.footer-brand .logo { font-size: 20px; margin-bottom: 10px; }
.footer-brand p { font-size: 13px; color: var(--text-muted); line-height: 1.7; }

.footer-links { display: flex; gap: 60px; flex-wrap: wrap; }
.footer-col h4 {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.footer-col a { display: block; font-size: 13px; color: var(--text-secondary); padding: 4px 0; }
.footer-col a:hover { color: var(--accent); }

.footer-bottom {
  padding-top: 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 12px;
  color: var(--text-muted);
}

/* ===== LIGHT MODE ===== */
body.light-mode {
  --bg-primary: #f5f7fa;
  --bg-secondary: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f0f3f7;
  --bg-elevated: #f8fafc;
  --text-primary: #0d1b2a;
  --text-secondary: #4a5b6e;
  --text-muted: #8494a8;
  --border: #e2e8f0;
  --border-light: #cbd5e1;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.12);
}

body.light-mode header { background: rgba(255, 255, 255, 0.85); }
body.light-mode .card-header { background: rgba(0, 0, 0, 0.02); }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  nav { display: none; }
  nav.open {
    display: flex;
    position: absolute;
    top: 72px;
    right: 16px;
    left: 16px;
    flex-direction: column;
    align-items: stretch;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 10px;
    box-shadow: var(--shadow-lg);
    z-index: 1001;
  }
  nav.open .nav-link { padding: 12px 16px; }
  .mobile-menu-btn { display: flex; }
  .live-badge-header { display: none; }
}

@media (max-width: 768px) {
  .container { padding: 0 16px; }
  .header-inner { height: 64px; }
  .logo { font-size: 20px; }
  .logo-icon { width: 36px; height: 36px; font-size: 18px; }
  .hero { margin-top: 64px; padding: 40px 0 30px; }
  .hero-stats { gap: 24px; }
  .stat-value { font-size: 22px; }
  .featured-match { padding: 20px; }
  .featured-team .team-logo { width: 56px; height: 56px; font-size: 26px; }
  .featured-score { font-size: 32px; }
  .featured-team .team-name { font-size: 13px; }
  .matches-grid { grid-template-columns: 1fr; gap: 16px; }
  .section-title { font-size: 18px; }
  .footer-links { gap: 32px; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 26px; }
  .hero p { font-size: 14px; }
  .featured-teams { gap: 10px; }
  .featured-center { min-width: 80px; }
  .featured-score { font-size: 28px; }
  .filter-tab { padding: 7px 14px; font-size: 12px; }
}

/* ===== PAGE CONTENT (about / contact / privacy) ===== */
.page-hero {
  margin-top: 72px;
  padding: 60px 0 30px;
  background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
  text-align: center;
}

.page-hero h1 { font-size: 36px; margin-bottom: 10px; }
.page-hero p { color: var(--text-secondary); font-size: 15px; }

.page-content { padding: 40px 0 80px; }
.page-content .container { max-width: 820px; }

.content-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  margin-bottom: 24px;
}

.content-card h2 {
  font-size: 22px;
  margin-bottom: 16px;
  color: var(--accent);
}

.content-card h3 {
  font-size: 18px;
  margin: 20px 0 10px;
  color: var(--text-primary);
}

.content-card p {
  color: var(--text-secondary);
  margin-bottom: 14px;
  line-height: 1.8;
}

.content-card ul {
  color: var(--text-secondary);
  padding-right: 20px;
  margin-bottom: 14px;
  line-height: 1.8;
}

.content-card li { margin-bottom: 8px; }

.contact-form { display: flex; flex-direction: column; gap: 16px; }

.form-group { display: flex; flex-direction: column; gap: 6px; }

.form-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 14px;
  outline: none;
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus { border-color: var(--accent); }

.form-group textarea { min-height: 120px; resize: vertical; }

.submit-btn {
  padding: 12px 24px;
  background: var(--accent-gradient);
  border: none;
  border-radius: var(--radius-md);
  color: var(--bg-primary);
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: var(--transition);
  align-self: flex-start;
}

.submit-btn:hover { box-shadow: var(--shadow-glow); transform: translateY(-2px); }

.contact-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.contact-info-item {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
  text-align: center;
}

.contact-info-item .icon { font-size: 28px; margin-bottom: 8px; }
.contact-info-item h4 { font-size: 14px; margin-bottom: 4px; }
.contact-info-item p { font-size: 13px; color: var(--text-muted); }

/* ===== LOGO FALLBACK / PLAYER ===== */
.logo-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-wrap img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 6px;
}

.featured-team .team-logo .logo-wrap img { padding: 8px; }

.team-mono.fill {
  width: 100%;
  height: 100%;
  border: none;
  border-radius: 50%;
  font-size: 14px;
}

.logo-wrap.team-logo-arch {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
}

.logo-wrap.team-logo-arch img { padding: 3px; }

.featured-team .team-logo .team-mono.fill { font-size: 20px; }

.player-frame { width: 100%; height: 100%; }
.player-frame iframe { width: 100%; height: 100%; border: none; display: block; }

.modal-match-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  flex-wrap: wrap;
}

.modal-vs { font-size: 13px; color: var(--text-muted); font-weight: 700; }

.modal-status-box {
  max-width: 420px;
  font-size: 12px;
  line-height: 1.8;
  color: var(--text-muted);
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 16px;
}

/* ===== ARCHIVE PAGE ===== */
.archive-page .container { max-width: 1180px; }

.archive-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 28px;
  max-width: 640px;
}

.arch-stat {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 10px;
  text-align: center;
}

.arch-stat span {
  display: block;
  font-size: 22px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1.2;
}

.arch-stat small { font-size: 11px; color: var(--text-muted); }

.archive-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 200px 130px 150px auto;
  gap: 10px;
  align-items: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px;
  margin-bottom: 16px;
}

.archive-controls > * { min-width: 0; }

.arch-search { position: relative; display: flex; align-items: center; min-width: 0; }

.arch-search-icon {
  position: absolute;
  right: 14px;
  font-size: 14px;
  opacity: 0.55;
  pointer-events: none;
}

.arch-search input {
  width: 100%;
  min-width: 0;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 11px 40px 11px 14px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 14px;
  outline: none;
  transition: var(--transition);
}

.arch-search input:focus { border-color: var(--accent); }

.arch-select {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 11px 12px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 13px;
  outline: none;
  cursor: pointer;
  transition: var(--transition);
  max-width: 100%;
  width: 100%;
  min-width: 0;
}

.arch-select:focus { border-color: var(--accent); }

.arch-reset {
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 11px 16px;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}

.arch-reset:hover { border-color: var(--accent); color: var(--accent); }

.archive-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--text-muted);
  padding: 0 6px 12px;
}

.archive-list { display: flex; flex-direction: column; gap: 8px; }

.arch-row {
  display: grid;
  grid-template-columns: 116px 1fr 240px;
  align-items: center;
  gap: 16px;
  width: 100%;
  text-align: right;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  color: var(--text-primary);
  font-family: inherit;
  cursor: pointer;
  transition: var(--transition);
  animation: cardFadeIn 0.35s ease both;
}

.arch-row:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-light);
  transform: translateX(-3px);
}

.arch-date {
  display: flex;
  flex-direction: column;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-secondary);
  line-height: 1.4;
}

.arch-date small { font-size: 11px; font-weight: 400; color: var(--text-muted); }

.arch-teams {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-width: 0;
}

.arch-team {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
  font-size: 14px;
  font-weight: 600;
}

.arch-team.away { flex-direction: row-reverse; text-align: left; }
.arch-team.away > span:last-child { text-align: left; }

.arch-team > span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.team-mono {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  color: #fff;
  background: hsl(var(--h, 160), 45%, 30%);
  border: 1px solid hsl(var(--h, 160), 50%, 45%);
  letter-spacing: -0.5px;
}

.arch-score {
  flex: 0 0 auto;
  min-width: 56px;
  text-align: center;
  font-size: 15px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  direction: ltr;
}

.arch-score i { font-style: normal; opacity: 0.4; }

.arch-score.vs { font-size: 12px; color: var(--text-muted); font-weight: 700; }

.arch-league {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  font-size: 12px;
  color: var(--text-secondary);
  min-width: 0;
}

.arch-league-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.archive-more-wrap { display: flex; justify-content: center; padding: 28px 0 0; }

.archive-more {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  padding: 12px 40px;
  cursor: pointer;
  transition: var(--transition);
}

.archive-more:hover { border-color: var(--accent); color: var(--accent); }

/* ===== MATCH DETAIL MODAL ===== */
.detail-modal { max-width: 560px; }

.detail-body { padding: 24px; }

.detail-score {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  padding: 18px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  margin-bottom: 18px;
}

.detail-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
  font-size: 13px;
}

.detail-team .team-mono { width: 44px; height: 44px; font-size: 15px; }

.detail-mid {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.detail-num { font-size: 22px; font-weight: 900; direction: ltr; }

.detail-table { width: 100%; border-collapse: collapse; font-size: 13px; }

.detail-table th,
.detail-table td {
  padding: 10px 4px;
  border-bottom: 1px solid var(--border);
  text-align: right;
}

.detail-table th { color: var(--text-muted); font-weight: 600; width: 40%; }

.detail-table td { color: var(--text-primary); }

.detail-note {
  margin-top: 16px;
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.7;
}

.detail-cta {
  display: block;
  margin-top: 16px;
  text-align: center;
  padding: 12px;
  border-radius: var(--radius-md);
  background: var(--accent-gradient);
  color: var(--bg-primary);
  font-weight: 800;
  font-size: 14px;
}

@media (max-width: 900px) {
  .archive-controls { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .arch-search { grid-column: 1 / -1; }
  .arch-row { grid-template-columns: 1fr; gap: 8px; padding: 14px; }
  .arch-date { flex-direction: row; gap: 8px; align-items: center; }
  .arch-league { justify-content: space-between; }
  .arch-teams { justify-content: space-between; }
  .arch-team { font-size: 13px; }
}

@media (max-width: 768px) {
  .page-hero { margin-top: 64px; padding: 40px 0 20px; }
  .page-hero h1 { font-size: 28px; }
  .content-card { padding: 20px; }
  .archive-stats { grid-template-columns: repeat(2, 1fr); }
  .arch-team > span:last-child { max-width: 88px; }
}
