/* ── PyramidLive Homepage Redesign — style.css ────────── */
/* This file is loaded AFTER main.css — overrides + new components */

/* ── Hero Section ─────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, #0d1117 0%, #161b22 50%, #0d1117 100%);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 16px;
  margin-top: 24px;
  margin-bottom: 24px;
  padding: 48px 32px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -60%;
  left: -20%;
  width: 140%;
  height: 140%;
  background: radial-gradient(ellipse at 30% 20%, rgba(35,134,54,0.08) 0%, transparent 60%),
              radial-gradient(ellipse at 70% 80%, rgba(56,139,253,0.06) 0%, transparent 60%);
  pointer-events: none;
}
.hero-inner {
  position: relative;
  z-index: 1;
}
.hero-title {
  font-size: 2.8rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 8px;
}
.hero-title-accent {
  color: #238636;
}
.hero-subtitle {
  font-size: 1.05rem;
  color: #8b949e;
  font-weight: 400;
  margin-bottom: 24px;
}
.hero-pills {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.hero-pill {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 99px;
  padding: 6px 16px;
  font-size: 0.82rem;
  font-weight: 500;
  color: #c9d1d9;
}
.hero-pill-accent {
  background: rgba(35,134,54,0.15);
  border-color: rgba(35,134,54,0.3);
  color: #3fb950;
  font-weight: 600;
}
.hero-pill-live {
  background: rgba(244,67,54,0.15);
  border-color: rgba(244,67,54,0.3);
  color: #f85149;
  font-weight: 700;
  animation: pulse-live 2s infinite;
}
@keyframes pulse-live {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

@media (max-width: 540px) {
  .hero { padding: 32px 20px 28px; margin-top: 16px; }
  .hero-title { font-size: 2rem; }
  .hero-subtitle { font-size: 0.9rem; }
}

/* ── Pyramid Section ──────────────────────────────────── */
.pyramid-section {
  background: #161b22;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 28px 24px 24px;
  margin-bottom: 24px;
}
.pyramid-header {
  text-align: center;
  margin-bottom: 24px;
}
.pyramid-heading {
  font-size: 1.1rem;
  font-weight: 700;
  color: #e6edf3;
  margin-bottom: 4px;
}
.pyramid-sub {
  font-size: 0.78rem;
  color: #484f58;
}
.pyramid-tiers {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.pyramid-tier {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  justify-content: center;
}
.tier-label {
  font-size: 0.68rem;
  font-weight: 700;
  color: #484f58;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  min-width: 52px;
  text-align: right;
  flex-shrink: 0;
}
.tier-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}
.tier-w-40 { max-width: 40%; }
.tier-w-35 { max-width: 35%; }
.tier-w-45 { max-width: 48%; }
.tier-w-55 { max-width: 60%; }
.tier-w-65 { max-width: 75%; }
.tier-box {
  background: #0d1117;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  padding: 8px 16px;
  font-size: 0.78rem;
  font-weight: 600;
  color: #c9d1d9;
  text-decoration: none;
  text-align: center;
  transition: all 0.2s ease;
  cursor: pointer;
}
.tier-box:hover {
  border-color: #388bfd;
  color: #58a6ff;
  background: rgba(56,139,253,0.08);
  transform: scale(1.03);
}
.tier-box-sm {
  font-size: 0.72rem;
  padding: 6px 10px;
}

@media (max-width: 768px) {
  .pyramid-tier {
    flex-direction: column;
    gap: 6px;
  }
  .tier-label {
    text-align: center;
    min-width: auto;
  }
  .tier-row {
    max-width: 100% !important;
  }
  .tier-w-40, .tier-w-35, .tier-w-45, .tier-w-55, .tier-w-65 {
    max-width: 100%;
  }
}
@media (max-width: 540px) {
  .pyramid-section { padding: 20px 16px; }
  .tier-row { flex-direction: column; align-items: stretch; }
  .tier-box, .tier-box-sm { padding: 10px 12px; font-size: 0.78rem; }
}

/* ── Filter Tab Bar ───────────────────────────────────── */
.filter-bar {
  position: sticky;
  top: 52px;
  z-index: 90;
  background: #0d1117;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  margin-bottom: 20px;
  margin-left: -16px;
  margin-right: -16px;
  padding: 0 16px;
}
.filter-bar-inner {
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.filter-bar-inner::-webkit-scrollbar { display: none; }
.filter-tab {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 12px 16px;
  font-size: 0.85rem;
  font-weight: 500;
  color: #8b949e;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s ease;
  white-space: nowrap;
  flex-shrink: 0;
}
.filter-tab:hover {
  color: #c9d1d9;
  border-bottom-color: rgba(255,255,255,0.15);
}
.filter-tab.active {
  color: #388bfd;
  border-bottom-color: #388bfd;
  font-weight: 600;
}

/* ── Override old filter nav (hide it) ────────────────── */
.filter-nav { display: none !important; }

/* ── Override old pyramid-diagram (hide it) ───────────── */
.pyramid-diagram { display: none !important; }

/* ── Page Title override ──────────────────────────────── */
.page-hub .page-title {
  padding: 8px 0 16px;
}
.page-hub .page-title h1 {
  font-size: 1.3rem;
  font-weight: 700;
  color: #e6edf3;
}
.page-hub .page-title .sub {
  color: #484f58;
  font-size: 0.82rem;
}

/* ── Match Row Enhancements ───────────────────────────── */
.page-hub .match-row .score {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #e6edf3;
}
.page-hub .badge-img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  padding: 2px;
  object-fit: contain;
}
.badge-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  flex-shrink: 0;
}
.badge-wrap .badge-img {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  padding: 0;
  background: transparent;
}

/* ── Competition pill on cards ────────────────────────── */
.page-hub .comp-group-title {
  font-size: 0.78rem;
  font-weight: 600;
  color: #8b949e;
  padding: 10px 16px 6px;
  background: #161b22;
  border: 1px solid rgba(255,255,255,0.08);
  border-bottom: none;
  border-radius: 10px 10px 0 0;
}
.page-hub .comp-group-title a {
  color: #388bfd;
  font-size: 0.75rem;
  font-weight: 500;
}
.page-hub .comp-group .card {
  background: #161b22;
  border-color: rgba(255,255,255,0.08);
  border-radius: 0 0 10px 10px;
}
.page-hub .match-row {
  border-bottom-color: rgba(255,255,255,0.05);
}
.page-hub .match-row:hover {
  background: rgba(56,139,253,0.04);
}

/* ── Status badges ────────────────────────────────────── */
.page-hub .badge.ft {
  background: rgba(110,118,129,0.12);
  color: #8b949e;
  font-size: 0.68rem;
}
.page-hub .badge.live {
  background: rgba(248,81,73,0.15);
  color: #f85149;
}
.page-hub .badge.ht {
  background: rgba(210,153,34,0.15);
  color: #d29922;
}

/* ── Section Labels ───────────────────────────────────── */
.page-hub .section-label {
  font-size: 0.78rem;
  font-weight: 700;
  color: #8b949e;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 24px 0 10px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 12px;
}

/* ── Empty State Card ─────────────────────────────────── */
.empty-card {
  background: #161b22;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 48px 24px;
  text-align: center;
}
.empty-icon {
  font-size: 2.4rem;
  margin-bottom: 12px;
  opacity: 0.5;
}
.empty-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #e6edf3;
  margin-bottom: 6px;
}
.empty-text {
  font-size: 0.88rem;
  color: #484f58;
}

/* ── Upcoming Section ─────────────────────────────────── */
.upcoming-section {
  margin-top: 32px;
}
.upcoming-header {
  margin-bottom: 4px;
}
.upcoming-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #e6edf3;
}

/* ── Org group title ──────────────────────────────────── */
.page-hub .org-group-title {
  font-size: 0.72rem;
  font-weight: 700;
  color: #484f58;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0 0 8px;
}

/* ── Body background override ─────────────────────────── */
.page-hub {
  background: #0d1117;
}

/* ── Poll indicator ───────────────────────────────────── */
.page-hub .poll-indicator {
  font-size: 0.78rem;
  color: #484f58;
  padding: 12px 0;
}
.page-hub .poll-dot {
  background: #238636;
}

/* ── Override old pyramid box styles ──────────────────── */
.pyramid-boxes.pyramid-6 { grid-template-columns: repeat(6, 1fr); }
.pyramid-boxes.pyramid-4 { grid-template-columns: repeat(4, 1fr); }
.pyramid-box-sm { font-size: 0.72rem; padding: 6px 4px; }
@media(max-width:768px) {
    .pyramid-boxes.pyramid-6 { grid-template-columns: repeat(3, 1fr); }
    .pyramid-boxes.pyramid-4 { grid-template-columns: repeat(2, 1fr); }
}

.league-stats-link { margin-bottom: 1.5rem; }
.btn-stats-link { display: inline-flex; align-items: center; gap: .5rem; background: rgba(16,185,129,.1); border: 1px solid rgba(16,185,129,.3); color: #10b981; padding: 8px 16px; border-radius: 8px; font-size: .88rem; font-weight: 600; text-decoration: none; transition: all .2s; }
.btn-stats-link:hover { background: rgba(16,185,129,.2); color: #fff; }
