/* ============================================================
   SHOA PLATFORM – MAIN STYLESHEET
   Shoaa Al Maarefa Schools | Educational Competitions
   ============================================================ */

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

/* ── CSS VARIABLES ── */
:root {
  --primary:        #2563EB;
  --primary-dark:   #1D4ED8;
  --primary-light:  #EFF6FF;
  --secondary:      #22C55E;
  --secondary-dark: #16A34A;
  --secondary-light:#DCFCE7;
  --accent:         #F59E0B;
  --accent-dark:    #D97706;
  --accent-light:   #FEF3C7;
  --danger:         #EF4444;
  --danger-light:   #FEE2E2;
  --bg:             #F8FAFC;
  --bg-card:        #FFFFFF;
  --bg-dark:        #0F172A;
  --text-primary:   #0F172A;
  --text-secondary: #475569;
  --text-muted:     #94A3B8;
  --border:         #E2E8F0;
  --border-focus:   #2563EB;
  --shadow-sm:      0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow:         0 4px 6px -1px rgba(0,0,0,.07), 0 2px 4px -1px rgba(0,0,0,.05);
  --shadow-md:      0 10px 15px -3px rgba(0,0,0,.08), 0 4px 6px -2px rgba(0,0,0,.04);
  --shadow-lg:      0 20px 25px -5px rgba(0,0,0,.10), 0 10px 10px -5px rgba(0,0,0,.04);
  --shadow-xl:      0 25px 50px -12px rgba(0,0,0,.18);
  --radius-sm:      8px;
  --radius:         12px;
  --radius-lg:      16px;
  --radius-xl:      24px;
  --radius-full:    9999px;
  --transition:     all .25s cubic-bezier(.4,0,.2,1);
  --transition-fast:all .15s cubic-bezier(.4,0,.2,1);
  --font:           'Cairo', sans-serif;
  --navbar-h:       72px;
}

/* ── RESET & BASE ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text-primary);
  direction: rtl;
  text-align: right;
  line-height: 1.6;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
button { font-family: var(--font); cursor: pointer; border: none; outline: none; }
input, select, textarea { font-family: var(--font); outline: none; }

/* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: var(--radius-full); }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ── SELECTION ── */
::selection { background: var(--primary); color: #fff; }

/* ─────────────────────────────────────────────────
   NAVBAR
───────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; right: 0; left: 0;
  height: var(--navbar-h);
  background: rgba(255,255,255,.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  z-index: 1000;
  transition: var(--transition);
}
.navbar.scrolled {
  background: rgba(255,255,255,.97);
  box-shadow: var(--shadow-md);
}
.nav-container {
  max-width: 1280px;
  margin: 0 auto;
  height: 100%;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.nav-logo-icon {
  width: 44px; height: 44px;
  
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 20px;
  box-shadow: 0 4px 12px rgba(37,99,235,.35);
}
.nav-logo-text { display: flex; flex-direction: column; }
.nav-logo-title {
  font-size: 18px;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.2;
}
.nav-logo-sub {
  font-size: 15px;
  color: var(--text-muted);
  font-weight: 400;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-link {
  padding: 8px 16px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: var(--transition-fast);
  position: relative;
}
.nav-link:hover { color: var(--primary); background: var(--primary-light); }
.nav-link.active { color: var(--primary); background: var(--primary-light); }
.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-user-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px 6px 6px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition-fast);
}
.nav-user-pill:hover { border-color: var(--primary); background: var(--primary-light); }
.nav-avatar {
  width: 32px; height: 32px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}
.nav-username { font-size: 13px; font-weight: 600; color: var(--text-primary); }
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  border-radius: var(--radius-sm);
  transition: var(--transition-fast);
}
.hamburger:hover { background: var(--bg); }
.hamburger span {
  display: block;
  width: 22px; height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition);
}
.mobile-menu {
  display: none;
  position: fixed;
  top: var(--navbar-h);
  right: 0; left: 0;
  background: #fff;
  border-bottom: 1px solid var(--border);
  padding: 16px 24px;
  flex-direction: column;
  gap: 8px;
  z-index: 999;
  box-shadow: var(--shadow-md);
}
.mobile-menu.open { display: flex; }
.mobile-menu .nav-link { text-align: right; }

/* ─────────────────────────────────────────────────
   BUTTONS
───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 700;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  white-space: nowrap;
  cursor: pointer;
  border: 2px solid transparent;
}
.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0);
  transition: var(--transition-fast);
}
.btn:hover::after { background: rgba(255,255,255,.12); }
.btn:active { transform: scale(.97); }

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  box-shadow: 0 4px 14px rgba(37,99,235,.35);
}
.btn-primary:hover { box-shadow: 0 6px 20px rgba(37,99,235,.45); transform: translateY(-1px); }

.btn-secondary {
  background: linear-gradient(135deg, var(--secondary), var(--secondary-dark));
  color: #fff;
  box-shadow: 0 4px 14px rgba(34,197,94,.3);
}
.btn-secondary:hover { box-shadow: 0 6px 20px rgba(34,197,94,.4); transform: translateY(-1px); }

.btn-accent {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff;
  box-shadow: 0 4px 14px rgba(245,158,11,.3);
}
.btn-accent:hover { box-shadow: 0 6px 20px rgba(245,158,11,.4); transform: translateY(-1px); }

.btn-danger {
  background: linear-gradient(135deg, var(--danger), #DC2626);
  color: #fff;
  box-shadow: 0 4px 14px rgba(239,68,68,.3);
}
.btn-danger:hover { box-shadow: 0 6px 20px rgba(239,68,68,.4); transform: translateY(-1px); }

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}
.btn-outline:hover { background: var(--primary); color: #fff; box-shadow: 0 4px 14px rgba(37,99,235,.3); }

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: transparent;
}
.btn-ghost:hover { background: var(--bg); color: var(--text-primary); }

.btn-sm { padding: 7px 14px; font-size: 13px; border-radius: var(--radius-sm); }
.btn-lg { padding: 14px 32px; font-size: 16px; border-radius: var(--radius-lg); }
.btn-xl { padding: 16px 40px; font-size: 17px; border-radius: var(--radius-lg); }
.btn-full { width: 100%; }
.btn-icon-only { padding: 10px; width: 40px; height: 40px; }

/* Ripple */
.btn-ripple { position: relative; overflow: hidden; }
.ripple-wave {
  position: absolute;
  border-radius: 50%;
  transform: scale(0);
  animation: rippleAnim .6s linear;
  background: rgba(255,255,255,.35);
  pointer-events: none;
}
@keyframes rippleAnim {
  to { transform: scale(4); opacity: 0; }
}

/* ─────────────────────────────────────────────────
   BADGES / STATUS
───────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 700;
}
.badge-primary   { background: var(--primary-light); color: var(--primary); }
.badge-secondary { background: var(--secondary-light); color: var(--secondary-dark); }
.badge-accent    { background: var(--accent-light); color: var(--accent-dark); }
.badge-danger    { background: var(--danger-light); color: var(--danger); }
.badge-muted     { background: #F1F5F9; color: var(--text-secondary); }

.status-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: currentColor;
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0%,100% { opacity: 1; }
  50%      { opacity: .4; }
}

/* Track badges */
.track-watani  { background: #EFF6FF; color: #1D4ED8; border: 1px solid #BFDBFE; }
.track-masry   { background: #FFF7ED; color: #C2410C; border: 1px solid #FED7AA; }
.track-dawli   { background: #F0FDF4; color: #15803D; border: 1px solid #BBF7D0; }

/* ─────────────────────────────────────────────────
   CARDS
───────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: var(--transition);
}
.card:hover {
  box-shadow: var(--shadow-lg);
  border-color: rgba(37,99,235,.15);
  transform: translateY(-4px);
}
.card-body { padding: 24px; }
.card-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.card-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  background: #FAFBFC;
}
.card-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
}
.card-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Competition Card */
.comp-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  position: relative;
}
.comp-card::before {
  content: '';
  position: absolute;
  top: 0; right: 0; left: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
}
.comp-card:hover {
  box-shadow: var(--shadow-xl);
  transform: translateY(-6px) scale(1.01);
  border-color: rgba(37,99,235,.2);
}
.comp-card-body { padding: 20px 20px 16px; flex: 1; }
.comp-card-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  background: #FAFBFC;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.comp-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
  line-height: 1.4;
}
.comp-meta {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-bottom: 14px;
}
.comp-meta-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
}
.comp-meta-item i {
  width: 16px;
  color: var(--primary);
  font-size: 12px;
  text-align: center;
}
.comp-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* ─────────────────────────────────────────────────
   FORMS
───────────────────────────────────────────────── */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}
.form-label span { color: var(--danger); margin-right: 3px; }
.form-control {
  width: 100%;
  padding: 11px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  font-family: var(--font);
  color: var(--text-primary);
  background: var(--bg-card);
  transition: var(--transition-fast);
  direction: rtl;
}
.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}
.form-control::placeholder { color: var(--text-muted); }
.form-control.error { border-color: var(--danger); }
.form-control.success { border-color: var(--secondary); }
.form-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 5px;
}
.form-error {
  font-size: 12px;
  color: var(--danger);
  margin-top: 5px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.input-wrapper { position: relative; }
.input-icon {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  right: 14px;
  color: var(--text-muted);
  font-size: 15px;
  pointer-events: none;
  transition: var(--transition-fast);
}
.input-wrapper .form-control { padding-right: 42px; }
.input-wrapper:focus-within .input-icon { color: var(--primary); }
.input-icon-left { left: 14px; right: auto; }
.input-wrapper .form-control.with-left-icon { padding-left: 42px; padding-right: 16px; }

/* Select */
.form-select {
  width: 100%;
  padding: 11px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  font-family: var(--font);
  color: var(--text-primary);
  background: var(--bg-card);
  transition: var(--transition-fast);
  direction: rtl;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%2394A3B8'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left 12px center;
  background-size: 16px;
  padding-left: 36px;
  cursor: pointer;
}
.form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,.12);
  outline: none;
}

/* ─────────────────────────────────────────────────
   HERO SECTION
───────────────────────────────────────────────── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #0F172A 0%, #1E3A8A 45%, #1D4ED8 100%);
  padding-top: var(--navbar-h);
}
.hero-bg-shapes {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
.hero-shape {
  position: absolute;
  border-radius: 50%;
  opacity: .08;
}
.hero-shape-1 {
  width: 600px; height: 600px;
  background: var(--primary-light);
  top: -200px; left: -200px;
}
.hero-shape-2 {
  width: 400px; height: 400px;
  background: var(--accent);
  bottom: -100px; right: -100px;
}
.hero-shape-3 {
  width: 200px; height: 200px;
  background: var(--secondary);
  top: 30%; left: 30%;
}
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 60px 60px;
}
.hero-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 80px 24px;
  position: relative;
  z-index: 1;
  /*display: grid;*/
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 80px;
}
.hero-content {}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: var(--radius-full);
  color: rgba(0, 0, 0, 0.9);
  font-size: 13px;
  font-weight: 650;
  margin-bottom: 28px;
  backdrop-filter: blur(10px);
}
.hero-badge i { color: var(--accent); }
.hero-title {
  font-size: 40px;
  font-weight: 900;
  line-height: 1.15;
  color: #fff;
  margin-bottom: 20px;
}
.hero-title .highlight {
  background: linear-gradient(135deg, var(--accent), #FBBF24);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-desc {
  font-size: 17px;
  color: rgba(255,255,255,.75);
  line-height: 1.8;
  margin-bottom: 36px;
  max-width: 500px;
}
.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.hero-visual {
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-card-stack {
  position: relative;
  width: 360px;
  height: 400px;
}
.hero-floating-card {
  position: absolute;
  background: rgba(255,255,255,.1);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: var(--radius-xl);
  padding: 20px;
  color: #fff;
  animation: float 6s ease-in-out infinite;
}
.hero-floating-card:nth-child(1) {
  top: 0; right: 0;
  width: 220px;
  animation-delay: 0s;
}
.hero-floating-card:nth-child(2) {
  bottom: 20px; left: 0;
  width: 260px;
  animation-delay: -2s;
}
.hero-floating-card:nth-child(3) {
  top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: 200px;
  animation-delay: -4s;
}
@keyframes float {
  0%,100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}
.hero-floating-card:nth-child(3) {
  animation: float3 6s ease-in-out infinite;
  animation-delay: -4s;
}
@keyframes float3 {
  0%,100% { transform: translate(-50%,-50%) translateY(0); }
  50%      { transform: translate(-50%,-50%) translateY(-12px); }
}
.hfc-icon {
  width: 40px; height: 40px;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  margin-bottom: 10px;
}
.hfc-title { font-size: 13px; font-weight: 700; margin-bottom: 4px; }
.hfc-sub { font-size: 11px; opacity: .7; }

/* ─────────────────────────────────────────────────
   SECTIONS
───────────────────────────────────────────────── */
.section { padding: 80px 0; }
.section-sm { padding: 48px 0; }
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}
.section-header {
  text-align: center;
  margin-bottom: 56px;
}
.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 16px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 16px;
}
.section-title {
  font-size: clamp(26px, 3vw, 36px);
  font-weight: 900;
  color: var(--text-primary);
  margin-bottom: 14px;
  line-height: 1.25;
}
.section-desc {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.8;
}

/* ─────────────────────────────────────────────────
   STATS SECTION
───────────────────────────────────────────────── */
.stats-section {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  padding: 64px 0;
  position: relative;
  overflow: hidden;
}
.stats-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 40px 40px;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2px;
  position: relative;
}
.stat-item {
  text-align: center;
  padding: 28px 20px;
  position: relative;
}
.stat-item::after {
  content: '';
  position: absolute;
  top: 20%; bottom: 20%;
  left: 0;
  width: 1px;
  background: rgba(255,255,255,.15);
}
.stat-item:first-child::after { display: none; }
.stat-icon {
  width: 52px; height: 52px;
  background: rgba(255,255,255,.15);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 22px;
  margin: 0 auto 16px;
  backdrop-filter: blur(10px);
}
.stat-number {
  font-size: 40px;
  font-weight: 900;
  color: #fff;
  line-height: 1;
  margin-bottom: 8px;
  font-variant-numeric: tabular-nums;
}
.stat-label {
  font-size: 14px;
  color: rgba(255,255,255,.75);
  font-weight: 500;
}

/* ─────────────────────────────────────────────────
   TIMELINE SECTION
───────────────────────────────────────────────── */
.timeline-section { background: var(--bg); }
.timeline {
  position: relative;
  padding: 20px 0;
}
.timeline::before {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  right: 50%;
  transform: translateX(50%);
  width: 2px;
  background: linear-gradient(to bottom, var(--primary), var(--secondary));
}
.timeline-item {
  display: grid;
  grid-template-columns: 1fr 60px 1fr;
  gap: 0;
  margin-bottom: 32px;
  align-items: start;
}
.timeline-content {
  padding: 20px;
}
.timeline-content.right { text-align: left; }
.timeline-content.left { text-align: right; }
.timeline-dot-wrapper {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 18px;
}
.timeline-dot {
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--primary);
  border: 3px solid #fff;
  box-shadow: 0 0 0 3px var(--primary);
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}
.timeline-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  padding: 18px 20px;
  transition: var(--transition);
}
.timeline-card:hover {
  box-shadow: var(--shadow-md);
  border-color: rgba(37,99,235,.2);
  transform: translateY(-2px);
}
.timeline-date {
  font-size: 12px;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.timeline-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}
.timeline-badges { display: flex; gap: 6px; flex-wrap: wrap; }

/* ─────────────────────────────────────────────────
   COMPETITIONS GRID
───────────────────────────────────────────────── */
.comp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

/* Filters bar */
.filters-bar {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  margin-bottom: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  box-shadow: var(--shadow-sm);
}
.filter-search { flex: 1; min-width: 220px; }
.filter-group { display: flex; gap: 8px; flex-wrap: wrap; }
.filter-chip {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  border: 2px solid var(--border);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition-fast);
}
.filter-chip:hover { border-color: var(--primary); color: var(--primary); }
.filter-chip.active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ─────────────────────────────────────────────────
   FOOTER
───────────────────────────────────────────────── */
.footer {
  background: var(--bg-dark);
  color: rgba(255,255,255,.8);
  padding: 64px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand-icon {
  width: 52px; height: 52px;
  
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: #fff;
  margin-bottom: 16px;
}
.footer-brand-name {
  font-size: 18px;
  font-weight: 800;
  color: #fff;
  margin-bottom: 12px;
}
.footer-desc {
  font-size: 14px;
  line-height: 1.8;
  color: rgba(255,255,255,.55);
  margin-bottom: 20px;
}
.footer-heading {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.footer-links { display: flex; flex-direction: column; gap: 12px; }
.footer-link {
  font-size: 14px;
  color: rgba(255,255,255,.55);
  transition: var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 8px;
}
.footer-link:hover { color: #fff; }
.footer-link i { font-size: 12px; color: var(--primary); }
.footer-bottom {
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-copy {
  font-size: 13px;
  color: rgba(255,255,255,.4);
}
.footer-copy a { color: var(--accent); }
.footer-tracks {
  display: flex;
  gap: 8px;
}
.footer-track-badge {
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 700;
  border: 1px solid rgba(255,255,255,.15);
  color: rgba(255,255,255,.6);
}

/* ─────────────────────────────────────────────────
   TOAST NOTIFICATIONS
───────────────────────────────────────────────── */
.toast-container {
  position: fixed;
  top: calc(var(--navbar-h) + 16px);
  left: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.toast {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px 20px;
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--border);
  min-width: 300px;
  max-width: 400px;
  pointer-events: all;
  animation: toastIn .4s cubic-bezier(.34,1.56,.64,1) both;
  position: relative;
  overflow: hidden;
}
.toast.hiding { animation: toastOut .3s ease forwards; }
.toast::before {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 4px;
  height: 100%;
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}
.toast-success::before { background: var(--secondary); }
.toast-error::before   { background: var(--danger); }
.toast-warning::before { background: var(--accent); }
.toast-info::before    { background: var(--primary); }
.toast-icon {
  width: 36px; height: 36px;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.toast-success .toast-icon { background: var(--secondary-light); color: var(--secondary-dark); }
.toast-error .toast-icon   { background: var(--danger-light); color: var(--danger); }
.toast-warning .toast-icon { background: var(--accent-light); color: var(--accent-dark); }
.toast-info .toast-icon    { background: var(--primary-light); color: var(--primary); }
.toast-body { flex: 1; }
.toast-title { font-size: 14px; font-weight: 700; color: var(--text-primary); margin-bottom: 2px; }
.toast-msg   { font-size: 13px; color: var(--text-secondary); line-height: 1.5; }
.toast-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px;
  font-size: 14px;
  transition: var(--transition-fast);
  flex-shrink: 0;
}
.toast-close:hover { color: var(--text-primary); }
@keyframes toastIn {
  from { transform: translateX(-120%); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}
@keyframes toastOut {
  from { transform: translateX(0); opacity: 1; }
  to   { transform: translateX(-120%); opacity: 0; }
}

/* ─────────────────────────────────────────────────
   LOADING / SKELETON
───────────────────────────────────────────────── */
.skeleton {
  background: linear-gradient(90deg, #E2E8F0 25%, #F1F5F9 50%, #E2E8F0 75%);
  background-size: 200% 100%;
  animation: skeleton-shimmer 1.5s infinite;
  border-radius: var(--radius);
}
@keyframes skeleton-shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.sk-text { height: 16px; margin-bottom: 8px; }
.sk-title { height: 24px; width: 70%; margin-bottom: 12px; }
.sk-badge { height: 24px; width: 80px; border-radius: var(--radius-full); }
.sk-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  padding: 20px;
  overflow: hidden;
}

/* Global Spinner */
.spinner-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,.85);
  backdrop-filter: blur(4px);
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 16px;
}
.spinner {
  width: 48px; height: 48px;
  border: 4px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
.spinner-sm {
  width: 20px; height: 20px;
  border-width: 2px;
}
.spinner-text { font-size: 14px; font-weight: 600; color: var(--text-secondary); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ─────────────────────────────────────────────────
   EMPTY STATE
───────────────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 64px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.empty-icon {
  width: 80px; height: 80px;
  background: var(--bg);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--text-muted);
  border: 2px dashed var(--border);
}
.empty-title { font-size: 18px; font-weight: 700; color: var(--text-primary); }
.empty-desc { font-size: 14px; color: var(--text-muted); max-width: 320px; line-height: 1.7; }

/* ─────────────────────────────────────────────────
   PAGE TRANSITION
───────────────────────────────────────────────── */
.page-enter {
  animation: pageEnter .5s cubic-bezier(.4,0,.2,1) both;
}
@keyframes pageEnter {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-in-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .6s ease, transform .6s ease;
}
.fade-in-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─────────────────────────────────────────────────
   MODAL
───────────────────────────────────────────────── */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,.6);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: backdropIn .2s ease both;
}
@keyframes backdropIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.modal {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalIn .3s cubic-bezier(.34,1.56,.64,1) both;
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(.92) translateY(20px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}
.modal-header {
  padding: 24px 28px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-title { font-size: 18px; font-weight: 800; color: var(--text-primary); }
.modal-close {
  width: 32px; height: 32px;
  border-radius: var(--radius);
  background: var(--bg);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: var(--transition-fast);
  font-size: 14px;
}
.modal-close:hover { background: var(--danger-light); color: var(--danger); }
.modal-body { padding: 24px 28px; }
.modal-footer {
  padding: 20px 28px;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 10px;
  justify-content: flex-start;
}

/* ─────────────────────────────────────────────────
   COMPETITION DETAIL
───────────────────────────────────────────────── */
.detail-hero {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  padding: calc(var(--navbar-h) + 40px) 0 48px;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.detail-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 40px 40px;
}
.detail-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(255,255,255,.75);
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 24px;
  transition: var(--transition-fast);
}
.detail-back:hover { color: #fff; }
.detail-title {
  font-size: clamp(24px, 3vw, 40px);
  font-weight: 900;
  margin-bottom: 16px;
  line-height: 1.2;
}
.detail-badges { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.detail-badge {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 700;
  background: rgba(255,255,255,.15);
  color: #fff;
  border: 1px solid rgba(255,255,255,.25);
}
.detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  margin-top: 32px;
}
.detail-meta-card {
  background: rgba(255,255,255,.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
}
.dmc-label { font-size: 12px; color: rgba(255,255,255,.6); margin-bottom: 4px; }
.dmc-value { font-size: 16px; font-weight: 700; }

/* ─────────────────────────────────────────────────
   AUTH PAGES
───────────────────────────────────────────────── */
.auth-page {
  min-height: 100vh;
  background: linear-gradient(135deg, #0F172A 0%, #1E3A8A 60%, #1D4ED8 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  overflow: hidden;
}
.auth-bg-shape {
  position: absolute;
  border-radius: 50%;
  opacity: .06;
  pointer-events: none;
}
.auth-bg-shape-1 {
  width: 700px; height: 700px;
  background: #fff;
  top: -300px; right: -200px;
}
.auth-bg-shape-2 {
  width: 500px; height: 500px;
  background: var(--accent);
  bottom: -200px; left: -150px;
}
.auth-card {
  background: #fff;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 460px;
  padding: 40px;
  position: relative;
  z-index: 1;
  animation: pageEnter .5s cubic-bezier(.4,0,.2,1) both;
}
.auth-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 32px;
}
.auth-logo-icon {
  width: 64px; height: 64px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: #fff;
  margin-bottom: 14px;
  box-shadow: 0 8px 24px rgba(37,99,235,.35);
}
.auth-school-name {
  font-size: 27px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.auth-school-sub {
  font-size: 20px;
  color: var(--text-muted);
}
.auth-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 8px;
  text-align: center;
}
.auth-subtitle {
  font-size: 14px;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 28px;
  line-height: 1.6;
}
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 24px 0;
}
.auth-divider::before, .auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}
.auth-divider span {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}
.auth-footer-link {
  text-align: center;
  margin-top: 24px;
  font-size: 14px;
  color: var(--text-secondary);
}
.auth-footer-link a {
  color: var(--primary);
  font-weight: 700;
  transition: var(--transition-fast);
}
.auth-footer-link a:hover { color: var(--primary-dark); text-decoration: underline; }
.role-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}
.role-option {
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 12px;
  cursor: pointer;
  transition: var(--transition-fast);
  text-align: center;
  position: relative;
}
.role-option:hover { border-color: var(--primary); background: var(--primary-light); }
.role-option.selected { border-color: var(--primary); background: var(--primary-light); }
.role-option.selected::after {
  content: '\f058';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  top: 8px; left: 8px;
  color: var(--primary);
  font-size: 14px;
}
.role-option input { display: none; }
.role-icon { font-size: 22px; margin-bottom: 6px; }
.role-name { font-size: 13px; font-weight: 700; color: var(--text-primary); }

/* ─────────────────────────────────────────────────
   PAGE HERO (inner pages)
───────────────────────────────────────────────── */
.page-hero {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  padding: calc(var(--navbar-h) + 32px) 0 40px;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 40px 40px;
}
.page-hero-content { position: relative; z-index: 1; }
.page-hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 14px;
  background: rgba(255,255,255,.15);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  color: rgba(255,255,255,.9);
  margin-bottom: 14px;
}
.page-hero-title {
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 900;
  margin-bottom: 10px;
}
.page-hero-desc {
  font-size: 15px;
  color: rgba(255,255,255,.75);
  max-width: 500px;
}

/* ─────────────────────────────────────────────────
   RESPONSIVE
───────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .hero-container { grid-template-columns: 1fr; gap: 40px; }
  .hero-visual { display: none; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-item:nth-child(2)::after { display: none; }
  .stat-item:first-child::after { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .hero-title { font-size: 28px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .timeline::before { right: 24px; transform: none; }
  .timeline-item { grid-template-columns: 1fr 40px; }
  .timeline-item > .timeline-content.right { display: none; }
  .timeline-dot-wrapper { justify-content: flex-start; }
  .footer-grid { grid-template-columns: 1fr; }
  .modal { margin: 16px; }
  .comp-grid { grid-template-columns: 1fr; }
  .role-selector { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .stat-item::after { display: none; }
  .auth-card { padding: 28px 20px; }
  .hero-desc { font-size: 15px; }
}
