/* ═══════════════════════════════════════════════════════════════
   OneIQ — World Cup Streaming | Main Stylesheet
   Color Palette:
     --bg:        #000000  (Pure Black)
     --red:       #FF0000  (Accents / Shapes)
     --yellow:    #E8FF00  (Primary Bold Text / Brand)
     --green:     #00FF00  (Secondary Text / Tagline)
═══════════════════════════════════════════════════════════════ */

/* ── Reset & Root ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:         #000000;
  --red:        #FF0000;
  --yellow:     #E8FF00;
  --green:      #00FF00;
  --glass-bg:   rgba(255,255,255,0.05);
  --glass-bdr:  rgba(255,255,255,0.1);
  --glass-shd:  0 8px 32px rgba(0,0,0,0.6);
  --red-glow:   0 0 20px rgba(255,0,0,0.4);
  --yellow-glow:0 0 20px rgba(232,255,0,0.35);
  --green-glow: 0 0 15px rgba(0,255,0,0.4);
  --radius-lg:  20px;
  --radius-xl:  32px;
  --font-ar:    'Cairo', 'Tajawal', system-ui, sans-serif;
  --transition: 0.35s cubic-bezier(0.4,0,0.2,1);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-ar);
  background: var(--bg);
  color: #ffffff;
  min-height: 100vh;
  overflow-x: hidden;
  direction: rtl;
}

/* ── Background Geometry ─────────────────────────────────── */
.bg-geometry {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.geo-circle {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(255,0,0,0.15);
}
.geo-circle--1 {
  width: 600px; height: 600px;
  top: -200px; right: -150px;
  background: radial-gradient(circle, rgba(255,0,0,0.06) 0%, transparent 70%);
  animation: spin-slow 40s linear infinite;
}
.geo-circle--2 {
  width: 400px; height: 400px;
  bottom: 10%; left: -100px;
  background: radial-gradient(circle, rgba(232,255,0,0.04) 0%, transparent 70%);
  animation: spin-slow 55s linear infinite reverse;
}
.geo-circle--3 {
  width: 250px; height: 250px;
  top: 50%; right: 5%;
  border-color: rgba(232,255,0,0.1);
  animation: pulse-ring 6s ease-in-out infinite;
}

.geo-semicircle {
  position: absolute;
  border-radius: 50%;
  background: transparent;
}
.geo-semi--top-right {
  width: 500px; height: 500px;
  top: -250px; left: -50px;
  background: radial-gradient(circle at 70% 30%, rgba(255,0,0,0.12), transparent 65%);
  clip-path: ellipse(50% 50% at 50% 50%);
}
.geo-semi--bottom-left {
  width: 400px; height: 400px;
  bottom: -150px; right: -80px;
  background: radial-gradient(circle, rgba(255,0,0,0.1), transparent 65%);
}

.geo-ball {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%,
    rgba(255,255,255,0.08) 0%,
    rgba(255,0,0,0.06) 40%,
    transparent 75%);
  border: 1px solid rgba(255,0,0,0.2);
}
.geo-ball--1 {
  width: 120px; height: 120px;
  top: 20%; left: 3%;
  animation: float 8s ease-in-out infinite;
}
.geo-ball--2 {
  width: 70px; height: 70px;
  bottom: 25%; right: 4%;
  animation: float 11s ease-in-out infinite reverse;
}

.geo-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,0,0,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,0,0,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
}

/* ── Animations ──────────────────────────────────────────── */
@keyframes spin-slow { to { transform: rotate(360deg); } }
@keyframes pulse-ring {
  0%,100% { transform: scale(1); opacity: 0.6; }
  50%      { transform: scale(1.08); opacity: 1; }
}
@keyframes float {
  0%,100% { transform: translateY(0) rotate(0deg); }
  50%      { transform: translateY(-20px) rotate(5deg); }
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulse-dot {
  0%,100% { transform: scale(1); opacity: 1; }
  50%      { transform: scale(1.5); opacity: 0.6; }
}
@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position:  200% 0; }
}
@keyframes glow-pulse {
  0%,100% { box-shadow: var(--red-glow); }
  50%      { box-shadow: 0 0 40px rgba(255,0,0,0.7); }
}

/* ── Container ───────────────────────────────────────────── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

/* ── Header ─────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(0,0,0,0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,0,0,0.25);
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  position: relative;
  z-index: 1;
}

.logo-wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.logo-ring {
  position: relative;
  width: 80px; height: 80px;
  flex-shrink: 0;
}
.logo-img {
  width: 80px; height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--red);
  box-shadow: var(--red-glow);
  transition: transform var(--transition), box-shadow var(--transition);
}
.logo-img:hover { transform: scale(1.08); box-shadow: 0 0 35px rgba(255,0,0,0.7); }

.logo-pulse {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid rgba(255,0,0,0.4);
  animation: pulse-ring 3s ease-in-out infinite;
  pointer-events: none;
}

.logo-text { flex: 1; }
.brand-name {
  font-size: clamp(1.3rem, 3.5vw, 1.9rem);
  font-weight: 900;
  color: var(--yellow);
  text-shadow: var(--yellow-glow);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.brand-tagline {
  font-size: clamp(0.75rem, 2vw, 0.95rem);
  font-weight: 600;
  color: var(--green);
  text-shadow: var(--green-glow);
  margin-top: 2px;
}

.header-badges {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.4rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.badge--live {
  background: rgba(255,0,0,0.15);
  border: 1px solid rgba(255,0,0,0.5);
  color: var(--red);
  animation: glow-pulse 2.5s ease-in-out infinite;
}
.badge--wc {
  background: rgba(232,255,0,0.1);
  border: 1px solid rgba(232,255,0,0.3);
  color: var(--yellow);
  font-size: 0.7rem;
}

.live-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--red);
  animation: pulse-dot 1.2s ease-in-out infinite;
  flex-shrink: 0;
}

.header-arc {
  position: absolute;
  bottom: -1px; left: 0; right: 0;
  width: 100%; height: 30px;
  pointer-events: none;
}

/* ── Hero Strip ──────────────────────────────────────────── */
.hero-strip {
  position: relative;
  z-index: 1;
  padding: 2rem 1.5rem 1.5rem;
  background: linear-gradient(180deg, rgba(255,0,0,0.05) 0%, transparent 100%);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1.2rem;
  animation: fadeInUp 0.6s ease both;
}

.hero-icon {
  font-size: 2.5rem;
  filter: drop-shadow(0 0 12px rgba(255,0,0,0.6));
  animation: float 5s ease-in-out infinite;
  flex-shrink: 0;
}

.hero-text { flex: 1; }
.hero-title {
  font-size: clamp(1.1rem, 3vw, 1.5rem);
  font-weight: 800;
  color: var(--yellow);
  text-shadow: var(--yellow-glow);
}
.hero-sub {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.5);
  margin-top: 2px;
}

.hero-ticker {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: rgba(255,0,0,0.1);
  border: 1px solid rgba(255,0,0,0.3);
  border-radius: var(--radius-lg);
  padding: 0.6rem 1.2rem;
  min-width: 80px;
  flex-shrink: 0;
}
.ticker-val {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--red);
  line-height: 1;
}
.ticker-label {
  font-size: 0.65rem;
  color: rgba(255,255,255,0.5);
  margin-top: 2px;
}

/* ── Matches Section ─────────────────────────────────────── */
.matches-section {
  position: relative;
  z-index: 1;
  padding: 2rem 0 4rem;
}

.matches-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

/* ── Match Card ──────────────────────────────────────────── */
.match-card {
  position: relative;
  background: var(--glass-bg);
  border: 1px solid var(--glass-bdr);
  border-radius: var(--radius-xl);
  padding: 1.6rem 1.4rem;
  cursor: pointer;
  overflow: hidden;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: var(--glass-shd);
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  animation: fadeInUp 0.5s ease both;
}
.match-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,0,0,0.08) 0%, transparent 60%);
  opacity: 0;
  transition: opacity var(--transition);
  border-radius: inherit;
}
.match-card:hover {
  transform: translateY(-6px) scale(1.01);
  box-shadow: 0 20px 50px rgba(0,0,0,0.7), var(--red-glow);
  border-color: rgba(255,0,0,0.5);
}
.match-card:hover::before { opacity: 1; }
.match-card:active { transform: translateY(-2px) scale(0.99); }

.match-card--live {
  border-color: rgba(255,0,0,0.5);
  box-shadow: var(--glass-shd), 0 0 25px rgba(255,0,0,0.2);
  animation: fadeInUp 0.5s ease both, glow-pulse 3s ease-in-out infinite;
}

/* Card top bar */
.card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.2rem;
}
.card-status {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
}
.card-status--live {
  background: rgba(255,0,0,0.2);
  border: 1px solid var(--red);
  color: var(--red);
}
.card-status--live .live-dot { animation: pulse-dot 1s ease-in-out infinite; }
.card-status--upcoming {
  background: rgba(232,255,0,0.1);
  border: 1px solid rgba(232,255,0,0.3);
  color: var(--yellow);
}

.card-time {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.5);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}
.card-time-icon { color: var(--red); font-size: 0.8rem; }

/* Teams vs display */
.card-teams {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  margin-bottom: 1rem;
}
.team-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
  text-align: center;
  flex: 1;
}
.vs-badge {
  background: radial-gradient(circle, rgba(255,0,0,0.3), rgba(255,0,0,0.1));
  border: 1px solid rgba(255,0,0,0.4);
  border-radius: 50%;
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.65rem;
  font-weight: 900;
  color: var(--red);
  flex-shrink: 0;
}

/* Match name */
.card-name {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  text-align: center;
  margin-bottom: 1.4rem;
  line-height: 1.4;
}

/* Watch button */
.card-watch-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.75rem 1rem;
  background: linear-gradient(135deg, rgba(255,0,0,0.8), rgba(200,0,0,0.9));
  border: none;
  border-radius: var(--radius-lg);
  color: #fff;
  font-family: var(--font-ar);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  box-shadow: 0 4px 20px rgba(255,0,0,0.35);
  position: relative;
  overflow: hidden;
}
.card-watch-btn::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
  transition: left 0.5s ease;
}
.card-watch-btn:hover { transform: scale(1.03); box-shadow: 0 6px 30px rgba(255,0,0,0.6); }
.card-watch-btn:hover::after { left: 100%; }
.card-watch-btn .btn-icon { font-size: 0.85rem; }

/* Card ball decor */
.card-ball-decor {
  position: absolute;
  top: -20px; left: -20px;
  width: 80px; height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.04), transparent 70%);
  border: 1px solid rgba(255,0,0,0.1);
  pointer-events: none;
}

/* ── Skeleton Loading ─────────────────────────────────────── */
.skeleton-card {
  height: 220px;
  border-radius: var(--radius-xl);
  background: linear-gradient(90deg,
    rgba(255,255,255,0.04) 25%,
    rgba(255,255,255,0.08) 50%,
    rgba(255,255,255,0.04) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.6s infinite;
}

/* ── State Displays ───────────────────────────────────────── */
.hidden { display: none !important; }

.error-state, .empty-state {
  text-align: center;
  padding: 4rem 2rem;
  animation: fadeInUp 0.5s ease;
}
.error-icon, .empty-icon { font-size: 3rem; margin-bottom: 1rem; }
.error-msg { color: rgba(255,255,255,0.6); margin-bottom: 1.5rem; }
.btn-retry {
  padding: 0.6rem 2rem;
  background: rgba(255,0,0,0.2);
  border: 1px solid var(--red);
  border-radius: 999px;
  color: var(--red);
  font-family: var(--font-ar);
  font-weight: 700;
  cursor: pointer;
  transition: background var(--transition);
}
.btn-retry:hover { background: rgba(255,0,0,0.35); }

/* ── Modal ───────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  animation: fadeInUp 0.25s ease;
}

.modal-glass {
  background: rgba(10,10,10,0.9);
  border: 1px solid rgba(255,0,0,0.35);
  border-radius: var(--radius-xl);
  padding: 2rem;
  max-width: 440px;
  width: 100%;
  position: relative;
  box-shadow: 0 30px 80px rgba(0,0,0,0.8), var(--red-glow);
  backdrop-filter: blur(20px);
  animation: fadeInUp 0.3s ease;
}

.modal-close {
  position: absolute;
  top: 1rem; left: 1rem;
  background: rgba(255,0,0,0.1);
  border: 1px solid rgba(255,0,0,0.3);
  border-radius: 50%;
  width: 32px; height: 32px;
  color: var(--red);
  font-size: 0.85rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--transition), transform var(--transition);
}
.modal-close:hover { background: rgba(255,0,0,0.3); transform: rotate(90deg); }

.modal-header {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1.2rem;
}
.modal-ball { font-size: 1.8rem; filter: drop-shadow(0 0 8px rgba(255,0,0,0.6)); }
.modal-title {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--yellow);
  text-shadow: var(--yellow-glow);
  flex: 1;
}

.modal-teams {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 0.8rem;
  font-size: 1.1rem;
  font-weight: 700;
}
.modal-time {
  text-align: center;
  color: rgba(255,255,255,0.5);
  font-size: 0.85rem;
  margin-bottom: 1.5rem;
}

.modal-watch-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  padding: 1rem;
  background: linear-gradient(135deg, #FF0000, #cc0000);
  border-radius: var(--radius-lg);
  color: #fff;
  text-decoration: none;
  font-family: var(--font-ar);
  font-size: 1rem;
  font-weight: 800;
  box-shadow: 0 6px 30px rgba(255,0,0,0.5);
  transition: transform var(--transition), box-shadow var(--transition);
}
.modal-watch-btn:hover { transform: scale(1.03); box-shadow: 0 8px 40px rgba(255,0,0,0.7); }
.modal-watch-btn .btn-icon { font-size: 1.1rem; }

/* ── Footer ──────────────────────────────────────────────── */
.site-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid rgba(255,0,0,0.15);
  padding: 2rem 1.5rem;
  text-align: center;
}
.footer-arc {
  position: absolute;
  top: -1px; left: 0; right: 0;
  height: 30px; width: 100%;
}
.footer-arc svg { display: block; width: 100%; height: 100%; }
.footer-brand {
  font-size: 1rem;
  font-weight: 800;
  color: var(--yellow);
  text-shadow: var(--yellow-glow);
  margin-bottom: 0.3rem;
}
.footer-copy {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.3);
}

/* ── Telegram ────────────────────────────────────────────── */
.tg-icon {
  width: 14px; height: 14px;
  flex-shrink: 0;
}

/* Header badge variant */
.badge--tg {
  background: rgba(41,182,246,0.12);
  border: 1px solid rgba(41,182,246,0.4);
  color: #29b6f6;
  text-decoration: none;
  transition: background var(--transition), box-shadow var(--transition), transform var(--transition);
}
.badge--tg:hover {
  background: rgba(41,182,246,0.25);
  box-shadow: 0 0 16px rgba(41,182,246,0.35);
  transform: scale(1.05);
}
.badge--tg .tg-icon { width: 13px; height: 13px; }

/* Footer CTA button */
.footer-tg-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1rem;
  padding: 0.65rem 1.6rem;
  background: rgba(41,182,246,0.1);
  border: 1px solid rgba(41,182,246,0.35);
  border-radius: 999px;
  color: #29b6f6;
  text-decoration: none;
  font-family: var(--font-ar);
  font-size: 0.875rem;
  font-weight: 700;
  transition: background var(--transition), box-shadow var(--transition), transform var(--transition);
}
.footer-tg-btn:hover {
  background: rgba(41,182,246,0.2);
  box-shadow: 0 0 24px rgba(41,182,246,0.3);
  transform: translateY(-2px);
}
.footer-tg-btn .tg-icon { width: 16px; height: 16px; }

/* Empty-state CTA */
.tg-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.2rem;
  padding: 0.7rem 1.8rem;
  background: rgba(41,182,246,0.1);
  border: 1px solid rgba(41,182,246,0.4);
  border-radius: 999px;
  color: #29b6f6;
  text-decoration: none;
  font-family: var(--font-ar);
  font-size: 0.9rem;
  font-weight: 700;
  transition: background var(--transition), box-shadow var(--transition), transform var(--transition);
}
.tg-cta-btn:hover {
  background: rgba(41,182,246,0.2);
  box-shadow: 0 0 24px rgba(41,182,246,0.35);
  transform: translateY(-2px);
}
.tg-cta-btn .tg-icon { width: 16px; height: 16px; }

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 640px) {
  .header-inner { flex-wrap: wrap; }
  .logo-wrap { gap: 0.8rem; }
  .logo-ring, .logo-img { width: 60px; height: 60px; }
  .header-badges { flex-direction: row; align-items: center; flex-wrap: wrap; }
  .matches-grid { grid-template-columns: 1fr; }
  .hero-inner { flex-wrap: wrap; }
  .hero-ticker { min-width: auto; flex-direction: row; gap: 0.5rem; }
}

@media (max-width: 400px) {
  .brand-name { font-size: 1.1rem; }
  .badge { font-size: 0.65rem; padding: 0.2rem 0.5rem; }
}
