/* ==============================================================
   بطولة كأس المدير العام - شركة نفط الشمال
   تصميم واجهة مستخدم احترافية بنمط تطبيقات الهواتف الذكية (Mobile App UI)
   ============================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;500;600;700;800;900&family=Changa:wght@600;700;800&display=swap');

:root {
  /* الوضع المضيء الافتراضي (Modern Sports Light) */
  --bg-app: #F0F4F8;
  --bg-frame: #070B19;
  --surface: #FFFFFF;
  --surface-card: #FFFFFF;
  --surface-glass: rgba(255, 255, 255, 0.85);
  --surface-secondary: #F8FAFC;
  --border-color: #E2E8F0;
  --border-subtle: rgba(226, 232, 240, 0.8);
  
  --primary-gold: #D97706;
  --primary-gold-dark: #B45309;
  --primary-gold-light: #FDE68A;
  --gold-gradient: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
  --gold-glow: 0 4px 20px rgba(217, 119, 6, 0.25);
  
  --sports-blue: #2563EB;
  --sports-blue-dark: #1D4ED8;
  --blue-gradient: linear-gradient(135deg, #3B82F6 0%, #1D4ED8 100%);
  
  --emerald-green: #10B981;
  --emerald-green-dark: #059669;
  --green-glow: 0 0 12px rgba(16, 185, 129, 0.4);
  
  --crimson-red: #EF4444;
  --crimson-dark: #DC2626;
  
  --text-main: #0F172A;
  --text-muted: #64748B;
  --text-light: #94A3B8;
  --text-inverse: #FFFFFF;
  
  --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 6px 18px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 30px rgba(0, 0, 0, 0.09);
  --shadow-float: 0 20px 40px rgba(0, 0, 0, 0.15);
  
  --radius-xs: 8px;
  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-full: 9999px;
  
  --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

body.dark-mode {
  /* الوضع الليلي الرياضي الفاخر (Elite Dark Sports Theme) */
  --bg-app: #070B19;
  --surface: #0E1629;
  --surface-card: #141E34;
  --surface-glass: rgba(20, 30, 52, 0.85);
  --surface-secondary: #0A1020;
  --border-color: rgba(255, 255, 255, 0.08);
  --border-subtle: rgba(255, 255, 255, 0.04);
  
  --primary-gold: #F59E0B;
  --primary-gold-dark: #D97706;
  --primary-gold-light: rgba(245, 158, 11, 0.2);
  --gold-glow: 0 0 25px rgba(245, 158, 11, 0.3);
  
  --text-main: #F8FAFC;
  --text-muted: #94A3B8;
  --text-light: #64748B;
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 16px 36px rgba(0, 0, 0, 0.6);
  --shadow-float: 0 25px 50px rgba(0, 0, 0, 0.7);
}

/* التنسيقات الأساسية */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Cairo', system-ui, -apple-system, sans-serif;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

input, textarea, select {
  user-select: text;
}

html, body {
  width: 100%;
  height: 100%;
  background-color: var(--bg-frame);
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  color: var(--text-main);
  direction: rtl;
}

/* إطار هاتف الموبايل الذكي المتناسق مع كافة الشاشات (Fluid Responsive Container) */
.mobile-app-container {
  width: 100%;
  height: 100vh;
  height: 100dvh;
  max-width: 100%;
  background-color: var(--bg-app);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}

@media (min-width: 500px) {
  .mobile-app-container {
    max-width: 440px;
    height: 94vh;
    max-height: 920px;
    border-radius: 42px;
    border: 10px solid #1E293B;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255,255,255,0.08);
  }
}

/* شاشة الترحيب والسبلاش (Splash Screen) */
#splash-screen {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: radial-gradient(circle at top, #1E293B 0%, #0A0F1D 80%, #030712 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 999999;
  padding: 30px;
  text-align: center;
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.splash-badge {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid var(--primary-gold);
  color: var(--primary-gold);
  font-size: 11px;
  font-weight: 800;
  padding: 4px 14px;
  border-radius: var(--radius-full);
  margin-bottom: 16px;
  letter-spacing: 0.5px;
}

.splash-logo-wrap {
  position: relative;
  margin-bottom: 20px;
}

.splash-logo-wrap::after {
  content: '';
  position: absolute;
  top: -10px; left: -10px; right: -10px; bottom: -10px;
  border-radius: 34px;
  background: var(--gold-gradient);
  opacity: 0.35;
  filter: blur(14px);
  z-index: 1;
  animation: glowPulse 2.5s infinite alternate;
}

.splash-logo {
  width: 95px;
  height: 95px;
  border-radius: 26px;
  object-fit: cover;
  border: 2.5px solid var(--primary-gold);
  position: relative;
  z-index: 2;
  background: #FFF;
}

@keyframes glowPulse {
  0% { transform: scale(0.92); opacity: 0.25; }
  100% { transform: scale(1.08); opacity: 0.55; }
}

.splash-title {
  color: #FFF;
  font-size: 21px;
  font-weight: 900;
  line-height: 1.3;
  margin-bottom: 6px;
}

.splash-title span {
  color: var(--primary-gold);
  display: block;
  font-size: 17px;
  font-weight: 700;
}

.splash-subtitle {
  color: #94A3B8;
  font-size: 12px;
  margin-bottom: 24px;
}

.splash-actions {
  width: 100%;
  max-width: 270px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* أزرار التطبيق (Buttons) */
.btn-primary {
  background: var(--gold-gradient);
  color: #0A0F1D;
  border: none;
  padding: 13px 20px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: var(--gold-glow);
  transition: var(--transition);
}

.btn-primary:active {
  transform: scale(0.97);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: #FFF;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 12px 18px;
  border-radius: var(--radius-md);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: var(--transition);
}

.btn-secondary:active {
  background: rgba(255, 255, 255, 0.15);
}

/* ==============================================================
   هيدر التطبيق وشريط الإشعارات (Header & Notification Ticker)
   ============================================================== */
.app-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border-color);
  padding: 10px 14px;
  padding-top: max(10px, env(safe-area-inset-top));
  padding-right: max(14px, env(safe-area-inset-right));
  padding-left: max(14px, env(safe-area-inset-left));
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  z-index: 50;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.header-logo-box {
  position: relative;
}

.header-logo {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  object-fit: cover;
  border: 2px solid var(--primary-gold);
  background: #FFF;
  display: block;
}

.header-title-box h1 {
  font-size: 13px;
  font-weight: 900;
  color: var(--text-main);
  line-height: 1.2;
}

.header-title-box p {
  font-size: 10px;
  font-weight: 700;
  color: var(--primary-gold);
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 7px;
}

/* زر جرس الإشعارات مع شارة العداد (Notification Bell Button) */
.notif-bell-btn {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--surface-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.notif-bell-btn:hover, .notif-bell-btn:active {
  border-color: var(--primary-gold);
  color: var(--primary-gold);
  transform: scale(1.05);
}

.notif-badge {
  position: absolute;
  top: -3px;
  right: -3px;
  background: var(--crimson-red);
  color: #FFF;
  font-size: 10px;
  font-weight: 900;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--surface);
  box-shadow: 0 2px 6px rgba(239, 68, 68, 0.4);
  animation: badgePulse 2s infinite;
}

@keyframes badgePulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

.icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--surface-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  font-size: 13px;
}

.icon-btn:hover {
  border-color: var(--primary-gold);
  color: var(--primary-gold);
}

/* شريط الأخبار المتحرك أسفل الهيدر (Breaking News Ticker) */
.ticker-bar {
  margin-top: 8px;
  background: linear-gradient(90deg, rgba(217, 119, 6, 0.12), rgba(217, 119, 6, 0.04));
  border: 1px solid rgba(217, 119, 6, 0.25);
  border-radius: var(--radius-sm);
  padding: 4px 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  overflow: hidden;
  cursor: pointer;
}

.ticker-tag {
  background: var(--gold-gradient);
  color: #0A0F1D;
  font-size: 9px;
  font-weight: 900;
  padding: 2px 7px;
  border-radius: var(--radius-xs);
  display: flex;
  align-items: center;
  gap: 3px;
  flex-shrink: 0;
}

.ticker-content {
  flex: 1;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==============================================================
   مباريات اليوم في الهيدر (Today's Live Match Strip)
   ============================================================== */
.today-strip-wrap {
  padding: 10px 14px 4px 14px;
}

.strip-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.strip-title {
  font-size: 11.5px;
  font-weight: 800;
  color: var(--primary-gold);
  display: flex;
  align-items: center;
  gap: 5px;
}

.live-indicator-dot {
  width: 7px;
  height: 7px;
  background-color: var(--emerald-green);
  border-radius: 50%;
  display: inline-block;
  box-shadow: var(--green-glow);
  animation: liveBlink 1.5s infinite;
}

@keyframes liveBlink {
  0% { opacity: 0.4; }
  50% { opacity: 1; }
  100% { opacity: 0.4; }
}

.horizontal-matches-scroll {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 6px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.horizontal-matches-scroll::-webkit-scrollbar {
  display: none;
}

.today-match-card {
  flex: 0 0 240px;
  scroll-snap-align: start;
  background: var(--surface-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 9px 12px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: var(--transition);
}

.today-match-card:active {
  transform: scale(0.98);
}

.card-top-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 9.5px;
  color: var(--text-muted);
  font-weight: 700;
}

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

.card-team-name {
  font-size: 10.5px;
  font-weight: 700;
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-team-name.team-right { text-align: right; }
.card-team-name.team-left { text-align: left; }

.card-score-box {
  background: var(--surface-secondary);
  border: 1px solid var(--border-color);
  color: var(--primary-gold);
  font-size: 12px;
  font-weight: 900;
  padding: 3px 10px;
  border-radius: var(--radius-xs);
  min-width: 44px;
  text-align: center;
}

/* ==============================================================
   جسم التطبيق الرئيسي والمشاهد (App Body & Panes)
   ============================================================== */
.app-body {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 10px 14px 20px 14px;
  position: relative;
}

.app-body::-webkit-scrollbar {
  display: none;
}

.tab-pane {
  display: none;
  animation: tabFadeIn 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.tab-pane.active {
  display: block;
}

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

/* أزرار التبديل الدائرية والمجموعات (Segment Controls) */
.segment-pills {
  display: flex;
  background: var(--surface);
  padding: 4px;
  border-radius: var(--radius-md);
  margin-bottom: 12px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.pill-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text-muted);
  padding: 9px 8px;
  font-size: 12px;
  font-weight: 800;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: var(--transition);
}

.pill-btn.active {
  background: var(--surface-card);
  color: var(--primary-gold);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

/* البطاقات العامة (Cards) */
.app-card {
  background: var(--surface-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
}

/* جدول الترتيب العصري (Standings Table) */
.standings-table-wrap {
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.standings-table {
  width: 100%;
  border-collapse: collapse;
  text-align: center;
  font-size: 11px;
}

.standings-table thead th {
  background: var(--surface-secondary);
  color: var(--primary-gold);
  padding: 10px 4px;
  font-weight: 800;
  font-size: 10.5px;
  border-bottom: 1.5px solid var(--border-color);
}

.standings-table tbody td {
  padding: 10px 4px;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-main);
  font-weight: 600;
}

.standings-table tbody tr:hover {
  background: rgba(217, 119, 6, 0.04);
}

.standings-table .team-name-cell {
  text-align: right;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  padding-right: 6px;
}

.rank-badge {
  display: inline-flex;
  width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 10px;
  font-weight: 900;
  border: 1px solid var(--border-color);
  background: var(--surface-secondary);
  color: var(--text-muted);
}

.rank-badge.top-1 {
  background: var(--gold-gradient);
  color: #0A0F1D;
  border: none;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
}

.rank-badge.top-2 {
  background: linear-gradient(135deg, #94A3B8, #64748B);
  color: #FFF;
  border: none;
}

.rank-badge.top-3 {
  background: linear-gradient(135deg, #B45309, #78350F);
  color: #FFF;
  border: none;
}

/* عناصر قائمة المباريات (Match Schedule Items) */
.day-header-pill {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-right: 4px solid var(--primary-gold);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  margin: 14px 0 8px 0;
  font-size: 11.5px;
  font-weight: 800;
  color: var(--primary-gold);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.match-row-card {
  background: var(--surface-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px;
  margin-bottom: 9px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: var(--transition);
}

.match-row-card:hover {
  border-color: var(--primary-gold);
}

.match-row-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 700;
}

.match-row-teams {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 800;
  margin-top: 2px;
}

.team-block {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 6px;
}

.team-block.team-one {
  justify-content: flex-start;
}

.team-block.team-two {
  justify-content: flex-end;
}

.team-avatar-mini {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: var(--surface-secondary);
  border: 1px solid var(--border-color);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 900;
  color: var(--primary-gold);
}

.score-badge-main {
  background: var(--surface-secondary);
  border: 1px solid var(--border-color);
  color: var(--primary-gold);
  font-size: 13px;
  font-weight: 900;
  padding: 4px 12px;
  border-radius: var(--radius-sm);
  min-width: 50px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}

/* شارات الحالة (Status Badges) */
.badge-status {
  padding: 3px 8px;
  border-radius: var(--radius-xs);
  font-size: 9px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.badge-status.scheduled {
  background: rgba(245, 158, 11, 0.12);
  color: var(--primary-gold);
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.badge-status.live {
  background: rgba(16, 185, 129, 0.15);
  color: var(--emerald-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-status.finished {
  background: rgba(148, 163, 184, 0.15);
  color: var(--text-muted);
  border: 1px solid var(--border-color);
}

/* ==============================================================
   مخطط الأدوار الإقصائية (Knockout Tournament Bracket)
   ============================================================== */
.bracket-stage-card {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px;
  margin-bottom: 12px;
}

.stage-title {
  color: var(--primary-gold);
  font-size: 12px;
  font-weight: 900;
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-color);
}

.bracket-match-box {
  background: var(--surface-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
  margin-bottom: 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.bracket-team-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11.5px;
  font-weight: 700;
}

.bracket-score-val {
  color: var(--primary-gold);
  font-weight: 900;
}

/* ==============================================================
   المدخلات والنماذج (Inputs & Form Elements)
   ============================================================== */
.form-group {
  margin-bottom: 12px;
}

.form-label {
  display: block;
  font-size: 11px;
  font-weight: 800;
  color: var(--primary-gold);
  margin-bottom: 4px;
}

.form-control {
  width: 100%;
  background: var(--surface-secondary);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-size: 13px;
  color: var(--text-main);
  outline: none;
  transition: var(--transition);
}

.form-control:focus {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.15);
}

/* ==============================================================
   شريط التنقل السفلي (Bottom Mobile Navigation Bar)
   ============================================================== */
.app-bottom-nav {
  height: calc(64px + env(safe-area-inset-bottom, 0px));
  background: var(--surface);
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-around;
  flex-shrink: 0;
  z-index: 50;
  box-shadow: var(--shadow-md);
  padding: 0 6px max(6px, env(safe-area-inset-bottom, 0px)) 6px;
}

.nav-item {
  flex: 1;
  background: none;
  border: none;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  font-weight: 800;
  cursor: pointer;
  padding: 6px 0;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.nav-item svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
  transition: var(--transition);
}

.nav-item.active {
  color: var(--primary-gold);
}

.nav-item.active svg {
  transform: translateY(-2px);
}

/* ==============================================================
   النوافذ المنبثقة والشيتات (Modals & Bottom Sheets)
   ============================================================== */
.modal-overlay {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(3, 7, 18, 0.75);
  backdrop-filter: blur(6px);
  z-index: 100000;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: var(--surface-card);
  width: 100%;
  max-width: 380px;
  border-radius: var(--radius-lg);
  padding: 18px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-float);
  transform: scale(0.9);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 85vh;
  overflow-y: auto;
}

.modal-overlay.active .modal-card {
  transform: scale(1);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.modal-title {
  font-size: 14px;
  font-weight: 900;
  color: var(--primary-gold);
  display: flex;
  align-items: center;
  gap: 6px;
}

.close-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.close-btn:hover {
  color: var(--crimson-red);
}

/* قائمة الإشعارات داخل المودال (Notification Drawer List) */
.notif-item-card {
  background: var(--surface-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 10px;
  margin-bottom: 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.notif-item-card.urgent {
  border-right: 4px solid var(--crimson-red);
}

.notif-item-card.alert {
  border-right: 4px solid var(--primary-gold);
}

.notif-item-card.goal {
  border-right: 4px solid var(--emerald-green);
}

.notif-item-card.info {
  border-right: 4px solid var(--sports-blue);
}

.notif-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.notif-title {
  font-size: 12px;
  font-weight: 800;
  color: var(--text-main);
}

.notif-time {
  font-size: 9px;
  color: var(--text-muted);
}

.notif-body {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* التنبيهات المنبثقة (Toast Alert) */
#toast-notification {
  position: absolute;
  bottom: 76px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: var(--surface-card);
  color: var(--text-main);
  padding: 10px 18px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 800;
  box-shadow: var(--shadow-lg);
  border: 1.5px solid var(--primary-gold);
  z-index: 200000;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}

#toast-notification.show {
  transform: translateX(-50%) translateY(0);
}

/* ==============================================================
   قواعد التناسق والاستجابة مع كافة أنواع شاشات الموبايل (Responsive Rules)
   ============================================================== */

/* الهواتف الصغيرة جداً (iPhone SE, Galaxy A0x - بعرض 360px وأقل) */
@media (max-width: 360px) {
  .header-logo { width: 32px; height: 32px; border-radius: 9px; }
  .header-title-box h1 { font-size: 11.5px; }
  .header-title-box p { font-size: 8.5px; }
  .notif-bell-btn, .icon-btn { width: 32px; height: 32px; font-size: 11px; }
  .pill-btn { font-size: 10.5px; padding: 7px 4px; }
  .standings-table { font-size: 9.5px; }
  .standings-table thead th { padding: 8px 2px; font-size: 9px; }
  .standings-table tbody td { padding: 7px 2px; }
  .team-avatar-mini { width: 17px; height: 17px; font-size: 8px; }
  .rank-badge { width: 18px; height: 18px; font-size: 9px; }
  .score-badge-main { min-width: 40px; padding: 3px 6px; font-size: 11px; }
  .match-row-teams { font-size: 10.5px; }
  .nav-item { font-size: 9px; }
  .nav-item svg { width: 17px; height: 17px; }
  .modal-card { padding: 14px; max-width: 95%; }
}

/* الهواتف القياسية الحديثة (iPhone 13/14/15/16, Galaxy S21/S22/S23/S24 - بين 361px و 430px) */
@media (min-width: 361px) and (max-width: 440px) {
  .header-title-box h1 { font-size: 13px; }
  .standings-table { font-size: 11px; }
  .standings-table thead th { padding: 9px 3px; font-size: 10px; }
  .score-badge-main { min-width: 46px; font-size: 12.5px; }
}

/* تحسين تجربة اللمس على جميع الأجهزة الذكية */
button, select, input, .nav-item, .pill-btn, .today-match-card, .match-row-card {
  touch-action: manipulation;
}

/* منع تكبير النصوص التلقائي غير المرغوب في سفاري وكروم على الجوال */
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}


