/* =====================================================================
   آکادمی هنرهای رزمی کرار — استایل اصلی
   ===================================================================== */

:root {
  --bg: #07070a;
  --bg-alt: #0e0e12;
  --card: #141418;
  --card-alt: #1c1c22;
  --red: #c8102e;
  --red-dark: #9b0d23;
  --gold: #f0ad3a;
  --gold-text: #c9891e;
  --text: #f0f0f0;
  --text-dim: #b0b0b0;
  --text-muted: #888888;
  --border: rgba(255, 255, 255, 0.07);
  --border-strong: rgba(255, 255, 255, 0.13);
  --success: #4ade80;
  --danger: #ff6b6b;
  --font: 'Vazirmatn', sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  direction: rtl;
  overflow-x: hidden;
}

img { max-width: 100%; }
a { color: inherit; }

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--red); border-radius: 3px; }

.container { max-width: 1320px; margin: 0 auto; padding: 0 24px; }

/* ---------- Animations ---------- */
@keyframes karar-slowzoom { from { transform: scale(1.08); } to { transform: scale(1.0); } }
@keyframes karar-bounce { 0%, 100% { transform: translateX(-50%) translateY(0); } 50% { transform: translateX(-50%) translateY(8px); } }
@keyframes karar-gold-glow { 0%, 100% { box-shadow: 0 0 0 rgba(240,173,58,0); } 50% { box-shadow: 0 0 16px rgba(240,173,58,0.45); } }

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }

/* ---------- Navbar ---------- */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 999;
  padding: 0 48px; height: 68px;
  display: flex; align-items: center; justify-content: space-between;
  background: rgba(7,7,10,0.82);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: background .3s, box-shadow .3s;
}
.navbar.scrolled { background: rgba(7,7,10,0.97); box-shadow: 0 4px 32px rgba(0,0,0,0.5); }
.navbar .brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.navbar .brand img { width: 44px; height: 44px; object-fit: contain; }
.navbar .brand strong { font-size: 15px; font-weight: 800; color: var(--text); display: block; }
.navbar .brand small { font-size: 10px; font-weight: 400; color: var(--gold-text); letter-spacing: 1.5px; }
.nav-links { display: flex; gap: 26px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
.nav-links a { text-decoration: none; font-size: 14px; font-weight: 500; color: rgba(240,240,240,0.75); transition: color .2s; }
.nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; gap: 10px; align-items: center; }
.nav-actions .dashboard-link { text-decoration: none; font-size: 13px; font-weight: 600; color: var(--gold); white-space: nowrap; }
.btn-register {
  background: var(--red); color: #fff; font-size: 13px; font-weight: 700;
  padding: 9px 22px; border-radius: 5px; text-decoration: none; white-space: nowrap;
  transition: background .2s;
  border: none; cursor: pointer; font-family: var(--font);
}
.btn-register:hover { background: var(--red-dark); }
.nav-toggle { display: none; background: none; border: none; color: var(--text); font-size: 26px; cursor: pointer; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100vh; display: flex; align-items: flex-end; overflow: hidden;
  scroll-margin-top: 80px;
}
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-bg img {
  width: 100%; height: 100%; object-fit: cover; object-position: center 20%;
  filter: brightness(0.55) contrast(1.05);
  transform: scale(1.04);
  animation: karar-slowzoom 14s ease-out forwards;
}
.hero-overlay {
  position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(to left, transparent 25%, rgba(7,7,10,0.55) 50%, rgba(7,7,10,0.92) 72%, rgba(7,7,10,1) 100%),
              linear-gradient(to top, rgba(7,7,10,1) 0%, rgba(7,7,10,0.6) 18%, transparent 40%);
}
.hero-topline { position: absolute; top: 0; left: 0; right: 0; height: 3px; z-index: 3; background: linear-gradient(to left, transparent, var(--red) 40%, var(--red-dark) 100%); }
.hero-content { position: relative; z-index: 2; padding: 0 64px 80px; max-width: 680px; width: 100%; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 700; letter-spacing: 3px; color: var(--red); text-transform: uppercase; margin-bottom: 20px; }
.hero-badge span { display: block; width: 32px; height: 2px; background: var(--red); }
.hero h1 { font-size: clamp(34px, 5.5vw, 68px); font-weight: 900; line-height: 1.15; margin: 0 0 10px; text-shadow: 0 2px 24px rgba(0,0,0,0.5); }
.hero h1 em { color: var(--red); font-style: normal; }
.hero-sub { font-size: 14px; font-weight: 400; letter-spacing: 3px; color: var(--gold); margin: 0 0 28px; opacity: .9; }
.hero-tags { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 32px; }
.hero-tags span { font-size: 12px; font-weight: 600; padding: 6px 14px; border-radius: 3px; background: rgba(255,255,255,0.07); border: 1px solid var(--border-strong); letter-spacing: .3px; }
.hero-info { display: flex; align-items: center; gap: 16px; padding: 14px 20px; background: rgba(200,16,46,0.1); border-right: 3px solid var(--red); border-radius: 4px; margin-bottom: 36px; }
.hero-info-icon { font-size: 22px; flex-shrink: 0; }
.hero-info strong { font-size: 15px; font-weight: 700; display: block; }
.hero-info span.muted { color: var(--text-muted); }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.btn-primary {
  display: inline-flex; align-items: center; gap: 8px; background: var(--red); color: #fff;
  font-size: 15px; font-weight: 700; padding: 14px 32px; border-radius: 5px; text-decoration: none;
  transition: all .2s; border: none; cursor: pointer; font-family: var(--font);
}
.btn-primary:hover { background: var(--red-dark); transform: translateY(-2px); box-shadow: 0 10px 28px rgba(200,16,46,0.45); }
.btn-outline {
  display: inline-flex; align-items: center; gap: 8px; background: transparent; color: var(--text);
  font-size: 15px; font-weight: 600; padding: 14px 32px; border-radius: 5px; text-decoration: none;
  border: 1px solid rgba(255,255,255,0.25); transition: all .2s;
}
.btn-outline:hover { border-color: var(--gold); color: var(--gold); transform: translateY(-2px); }
.scroll-hint {
  position: absolute; bottom: 32px; left: 50%; transform: translateX(-50%); z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: 6px; opacity: .5;
  animation: karar-bounce 2.4s infinite;
}
.scroll-hint span { font-size: 10px; letter-spacing: 2px; }
.scroll-hint .arrow { width: 20px; height: 20px; border-right: 2px solid var(--text); border-bottom: 2px solid var(--text); transform: rotate(45deg); }

/* ---------- Stats ---------- */
.stats-grid {
  background: var(--card); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  display: grid; grid-template-columns: repeat(4, minmax(0,1fr));
}
.stats-grid .stat { padding: 28px 20px; text-align: center; border-left: 1px solid var(--border); transition: background .2s; }
.stats-grid .stat:last-child { border-left: none; }
.stats-grid .stat:hover { background: rgba(255,255,255,0.02); }
.stats-grid .stat .num { font-size: 36px; font-weight: 900; display: block; line-height: 1; margin-bottom: 5px; }
.stats-grid .stat .label { font-size: 12px; color: var(--text-muted); }

/* ---------- Section shared ---------- */
.section { padding: 100px 64px; scroll-margin-top: 80px; }
.section.alt { background: var(--bg-alt); }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 11px; font-weight: 700; letter-spacing: 3px; color: var(--red); text-transform: uppercase; margin-bottom: 14px; }
.eyebrow span { display: block; width: 24px; height: 2px; background: var(--red); }
.section h2 { font-size: clamp(26px, 3.5vw, 44px); font-weight: 900; line-height: 1.2; margin: 0 0 14px; }
.section p.lead { font-size: 15px; color: var(--text-muted); max-width: 560px; line-height: 1.9; margin: 0; }

/* ---------- About ---------- */
.about-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 72px; align-items: center; margin-top: 56px; }
.about-grid p { font-size: 15px; color: var(--text-dim); line-height: 1.95; margin: 0 0 18px; }
.about-grid strong { color: var(--text); font-weight: 700; }
.badge-pills { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.badge-pill { font-size: 12px; font-weight: 600; padding: 7px 16px; border-radius: 100px; background: rgba(200,16,46,0.1); border: 1px solid rgba(200,16,46,0.3); }
.about-visual { position: relative; }
.about-visual-img { position: relative; border-radius: 10px; overflow: hidden; background: #000; display: flex; align-items: center; justify-content: center; height: 420px; }
.about-visual-img img { width: 100%; height: 100%; object-fit: contain; display: block; }
.about-badge { position: absolute; bottom: -18px; left: -18px; background: var(--red); padding: 18px 24px; border-radius: 8px; text-align: center; box-shadow: 0 8px 32px rgba(200,16,46,0.4); }
.about-badge strong { display: block; font-size: 30px; font-weight: 900; color: #fff; line-height: 1; }
.about-badge span { font-size: 12px; color: rgba(255,255,255,0.8); }

/* ---------- Disciplines ---------- */
.disciplines-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 22px; margin-top: 52px; }
.discipline-card {
  background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 38px 30px;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.discipline-card:hover { transform: translateY(-5px); border-color: var(--red); box-shadow: 0 0 0 1px var(--red), 0 16px 40px rgba(0,0,0,0.4); }
.discipline-icon { width: 58px; height: 58px; background: rgba(200,16,46,0.1); border-radius: 12px; display: flex; align-items: center; justify-content: center; margin-bottom: 24px; }
.discipline-card h3 { font-size: 20px; font-weight: 800; margin: 0 0 4px; }
.discipline-card .en { font-size: 11px; letter-spacing: 2px; color: var(--gold-text); font-weight: 400; margin-bottom: 14px; display: block; }
.discipline-card p { font-size: 13px; color: var(--text-muted); line-height: 1.85; margin: 0; }

/* ---------- Divider ---------- */
.divider-section { position: relative; height: 280px; overflow: hidden; }
.divider-section img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 30%; filter: brightness(0.28) saturate(0.7); }
.divider-overlay { position: absolute; inset: 0; background: linear-gradient(to bottom, var(--bg-alt) 0%, transparent 30%, transparent 70%, var(--bg) 100%); }
.divider-content { position: relative; z-index: 2; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 0 32px; }
.divider-content h2 { font-size: clamp(22px, 4vw, 44px); font-weight: 900; margin: 0 0 8px; }
.divider-content p { font-size: 14px; color: var(--text-muted); max-width: 500px; line-height: 1.8; margin: 0; }

/* ---------- Achievements ---------- */
.medals-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 20px; margin-top: 52px; }
.medal-card {
  background: var(--bg); border: 1px solid var(--gold); border-radius: 10px; padding: 28px 20px; text-align: center;
  animation: karar-gold-glow 2.4s ease-in-out infinite; transition: transform .2s, box-shadow .2s;
}
.medal-card:hover { transform: translateY(-4px); border-color: var(--gold); box-shadow: 0 0 18px rgba(240,173,58,0.5); }
.medal-card .year { font-size: 24px; font-weight: 900; color: var(--gold); margin-bottom: 20px; }
.medal-card .row { display: flex; justify-content: space-around; gap: 8px; }
.medal-card .item { text-align: center; }
.medal-card .item .n { font-size: 28px; font-weight: 900; display: block; line-height: 1; margin-bottom: 4px; }
.medal-card .item .l { font-size: 10px; color: var(--text-muted); }
.medals-caption { text-align: center; margin-top: 28px; font-size: 12px; color: #555; }

/* ---------- Gallery ---------- */
.gallery-tabs { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.gallery-tab {
  font-family: var(--font); font-size: 13px; font-weight: 600; padding: 9px 22px; border-radius: 100px; cursor: pointer;
  border: 1px solid var(--border); background: var(--card); color: var(--text-muted); transition: all .2s;
}
.gallery-tab.active { border-color: var(--red); background: var(--red); color: #fff; }
.gallery-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); grid-auto-rows: 220px; gap: 16px; margin-top: 32px; }
.gallery-grid.preview { grid-auto-rows: 200px; }
.gallery-item { position: relative; border-radius: 10px; overflow: hidden; background: var(--card); border: 1px solid var(--border); }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-item .caption { position: absolute; bottom: 0; right: 0; left: 0; padding: 8px 12px; font-size: 11px; background: linear-gradient(to top, rgba(0,0,0,0.75), transparent); }
.gallery-item.span-wide { grid-column: span 2; }
.gallery-item.span-tall { grid-row: span 2; }

/* ---------- Schedule + Contact ---------- */
.schedule-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; margin-top: 52px; }
.schedule-card { background: var(--card); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.schedule-head { background: var(--red); padding: 20px 28px; font-size: 15px; font-weight: 800; letter-spacing: .5px; }
.schedule-row { display: flex; align-items: center; gap: 16px; padding: 16px 28px; border-bottom: 1px solid var(--border); transition: background .2s; }
.schedule-row:last-child { border-bottom: none; }
.schedule-row:hover { background: rgba(255,255,255,0.02); }
.schedule-icon { width: 42px; height: 42px; border-radius: 8px; background: rgba(200,16,46,0.12); border: 1px solid rgba(200,16,46,0.22); display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 18px; }
.schedule-row strong { display: block; font-size: 14px; font-weight: 700; margin-bottom: 2px; }
.schedule-row span { font-size: 12px; color: var(--text-muted); }
.contact-links { display: flex; flex-direction: column; gap: 14px; }
.contact-link {
  display: flex; align-items: center; gap: 14px; padding: 16px 22px; border-radius: 8px; text-decoration: none;
  font-size: 15px; font-weight: 600; transition: all .2s;
}
.contact-link:hover { transform: translateX(-4px); opacity: .9; }
.contact-link .icon-wrap { width: 40px; height: 40px; border-radius: 8px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.contact-link.telegram { border: 1px solid rgba(231,100,28,.35); background: rgba(231,100,28,.12); color: #f07030; }
.contact-link.telegram .icon-wrap { background: rgba(231,100,28,.18); }
.contact-link.eitaa { border: 1px solid rgba(231,100,28,.35); background: rgba(231,100,28,.12); color: #e7641c; }
.contact-link.eitaa .icon-wrap { background: rgba(231,100,28,.18); }
.contact-link.phone { border: 1px solid rgba(240,173,58,.35); background: rgba(240,173,58,.10); color: var(--gold); }
.contact-link.phone .icon-wrap { background: rgba(240,173,58,.18); }

/* ---------- Instructor ---------- */
.instructor-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 60px; align-items: center; margin-top: 52px; }
.class-detail-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; }
.instructor-photo { position: relative; }
.instructor-photo img { width: 100%; border-radius: 10px; display: block; filter: contrast(1.05) brightness(.95); }
.instructor-photo .frame { position: absolute; inset: -10px; border: 2px solid rgba(200,16,46,.35); border-radius: 16px; pointer-events: none; z-index: -1; }
.instructor-photo .tag { position: absolute; bottom: 20px; right: -16px; background: var(--red); padding: 14px 20px; border-radius: 8px; box-shadow: 0 8px 28px rgba(200,16,46,.45); }
.instructor-photo .tag strong { display: block; font-size: 13px; font-weight: 800; color: #fff; }
.instructor-photo .tag span { font-size: 10px; color: rgba(255,255,255,.75); letter-spacing: 1px; }
.instructor-info h3 { font-size: 34px; font-weight: 900; margin: 0 0 4px; }
.instructor-info .role { font-size: 15px; color: var(--gold); font-weight: 400; display: block; margin-bottom: 24px; }
.instructor-info p { font-size: 14px; color: var(--text-dim); line-height: 1.95; margin: 0 0 16px; }

/* ---------- Footer ---------- */
.site-footer { background: #040406; border-top: 1px solid var(--border); padding: 60px 64px 36px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 56px; padding-bottom: 40px; border-bottom: 1px solid var(--border); }
.footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.footer-brand img { height: 52px; object-fit: contain; }
.footer-brand strong { font-size: 16px; font-weight: 800; }
.footer-brand small { font-size: 11px; color: var(--gold-text); display: block; letter-spacing: 1px; margin-top: 2px; }
.site-footer .desc { font-size: 13px; color: var(--text-muted); line-height: 1.85; max-width: 280px; margin: 0; }
.site-footer .desc p { margin: 0 0 8px; }
.site-footer .desc p:last-child { margin-bottom: 0; }
.social-links { display: flex; gap: 14px; margin-top: 16px; }
.social-links a { display: flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 8px; text-decoration: none; transition: opacity .2s; }
.social-links a:hover { opacity: .7; }
.footer-col h4 { font-size: 13px; font-weight: 700; color: var(--text); letter-spacing: 1px; margin: 0 0 18px; text-transform: uppercase; }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; }
.footer-col ul a { text-decoration: none; font-size: 13px; color: var(--text-muted); transition: color .2s; }
.footer-col ul a:hover { color: var(--red); }
.footer-contact-item { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--text-muted); margin-bottom: 12px; }
.footer-contact-item a { color: var(--text-muted); text-decoration: none; }
.footer-contact-item a:hover { color: var(--gold); }
.footer-bottom { padding-top: 28px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.footer-bottom p { font-size: 12px; color: #444; margin: 0; }
.footer-bottom .credit { font-size: 13px; color: #555; font-style: italic; }
.footer-bottom .credit a { color: var(--gold-text); text-decoration: none; font-style: normal; }

/* ---------- Buttons / Forms shared ---------- */
.form-input, .form-select, .form-textarea {
  font-family: var(--font); background: var(--bg); border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px; padding: 12px 14px; color: var(--text); font-size: 14px; outline: none; width: 100%;
  transition: border-color .2s;
}
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--red); }
.form-select option {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  padding: 8px;
}
.form-textarea { min-height: 90px; resize: vertical; }
.form-label { font-size: 12px; color: var(--text-muted); display: block; margin-bottom: 6px; }
.btn-submit {
  font-family: var(--font); background: var(--red); color: #fff; font-weight: 700; font-size: 15px;
  padding: 13px; border: none; border-radius: 8px; cursor: pointer; width: 100%; transition: background .2s;
}
.btn-submit:hover { background: var(--red-dark); }
.btn-small { font-family: var(--font); font-weight: 700; font-size: 12px; padding: 8px 16px; border-radius: 6px; cursor: pointer; border: none; transition: all .2s; }
.btn-small.approve { background: rgba(34,197,94,.15); border: 1px solid rgba(34,197,94,.35); color: var(--success); }
.btn-small.reject, .btn-small.danger { background: rgba(200,16,46,.15); border: 1px solid rgba(200,16,46,.35); color: #ff8a8a; }
.alert { font-size: 13px; padding: 10px 14px; border-radius: 8px; margin-bottom: 16px; }
.alert.success { background: rgba(34,197,94,.12); border: 1px solid rgba(34,197,94,.35); color: var(--success); }
.alert.error { background: rgba(200,16,46,.12); border: 1px solid rgba(200,16,46,.35); color: #ff8a8a; }
.alert.info { background: rgba(240,173,58,.12); border: 1px solid rgba(240,173,58,.35); color: var(--gold); }

.status-badge { font-size: 11px; font-weight: 700; padding: 5px 12px; border-radius: 100px; }
.status-badge.pending { color: var(--gold); background: rgba(240,173,58,.13); }
.status-badge.approved { color: var(--success); background: rgba(74,222,128,.13); }
.status-badge.rejected { color: var(--danger); background: rgba(255,107,107,.13); }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .nav-links, .nav-actions .dashboard-link { display: none; }
  .nav-toggle { display: block; }
  .about-grid, .schedule-grid, .instructor-grid, .class-detail-grid { grid-template-columns: 1fr; gap: 36px; }
  .disciplines-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .medals-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .gallery-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .gallery-item.span-wide { grid-column: span 2; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .section { padding: 70px 24px; }
  .hero-content { padding: 0 24px 60px; }
  .navbar { padding: 0 20px; }
}
@media (max-width: 560px) {
  .stats-grid, .medals-grid, .gallery-grid { grid-template-columns: repeat(1, minmax(0,1fr)); }
  .gallery-item.span-wide, .gallery-item.span-tall { grid-column: span 1; grid-row: span 1; }
  .hero h1 { font-size: 34px; }
}

/* ---------- Mobile nav menu ---------- */
.mobile-menu {
  position: fixed; inset: 0; z-index: 1000; background: rgba(7,7,10,0.98); backdrop-filter: blur(10px);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px;
  transform: translateY(-100%); transition: transform .3s ease; padding: 24px;
}
.mobile-menu.open { transform: translateY(0); }
.mobile-menu a { text-decoration: none; color: var(--text); font-size: 14px; font-weight: 600; letter-spacing: .3px; padding: 10px 22px; border-radius: 8px; transition: background .2s; }
.mobile-menu a:active, .mobile-menu a:hover { background: rgba(255,255,255,.06); }
.mobile-menu .close-btn { position: absolute; top: 20px; left: 24px; background: none; border: none; color: var(--text); font-size: 26px; cursor: pointer; }

/* ---------- Dashboard shared ---------- */
.dash-navbar {
  position: sticky; top: 0; z-index: 50; display: flex; align-items: center; justify-content: space-between;
  padding: 0 32px; height: 64px; background: rgba(7,7,10,0.95); border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
}
.dash-navbar .brand { text-decoration: none; color: var(--text); font-size: 14px; font-weight: 800; }
.btn-ghost { font-family: var(--font); background: transparent; border: 1px solid rgba(255,255,255,0.2); color: var(--text); font-size: 12px; padding: 8px 16px; border-radius: 6px; cursor: pointer; text-decoration: none; }
.dash-wrap { max-width: 1180px; margin: 0 auto; padding: 32px 24px 80px; }
.dash-wrap.narrow { max-width: 920px; }
.dash-title { font-size: 26px; font-weight: 900; margin: 0 0 6px; }
.dash-subtitle { font-size: 13px; color: var(--text-muted); margin: 0 0 32px; }

.dash-welcome { display: flex; align-items: center; gap: 18px; margin-bottom: 28px; }
.dash-welcome-avatar { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; border: 2px solid rgba(200,16,46,.35); flex-shrink: 0; background: var(--card); }
.dash-welcome .dash-title { margin-bottom: 4px; }
.dash-welcome .dash-subtitle { margin-bottom: 0; }
@media (max-width: 560px) {
  .dash-welcome { gap: 12px; }
  .dash-welcome-avatar { width: 48px; height: 48px; }
  .dash-welcome .dash-title { font-size: 20px; }
}
.info-cards { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 16px; margin-bottom: 32px; }
.info-card { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 20px; text-align: center; }
.info-card .label { font-size: 11px; color: var(--text-muted); display: block; margin-bottom: 6px; }
.info-card strong { font-size: 15px; }
.panel-card { background: var(--card); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; margin-bottom: 32px; box-shadow: 0 8px 24px rgba(0,0,0,.18); }
.panel-card .panel-head { background: var(--red); padding: 16px 24px; font-size: 15px; font-weight: 800; }
.panel-card .panel-head.alt { background: var(--card-alt); border-bottom: 1px solid var(--border); }
.panel-card .panel-body { padding: 24px; }
.list-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 24px; border-bottom: 1px solid rgba(255,255,255,0.05); flex-wrap: wrap; }
.list-row:last-child { border-bottom: none; }
.tabs-row { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 28px; justify-content: flex-start; }
.tab-btn { font-family: var(--font); font-size: 13px; font-weight: 700; padding: 10px 18px; border-radius: 8px; border: none; cursor: pointer; background: var(--card); color: var(--text-muted); }
.tab-btn.active { background: var(--red); color: #fff; }
.role-badge { font-size: 10px; font-weight: 700; padding: 3px 10px; border-radius: 100px; margin-right: 6px; }
.role-badge.admin { background: rgba(240,173,58,.15); color: var(--gold); }
.role-badge.assistant { background: rgba(96,165,250,.15); color: #60a5fa; }
.role-badge.athlete { background: rgba(255,255,255,.08); color: #aaa; }

/* فرم‌های ویرایش قابل باز/بسته شدن (کاربران، پیام‌ها، دستاوردها) */
.edit-user-box { display: none; }
.edit-user-box.open-edit { display: block !important; }

@media (max-width: 700px) {
  .info-cards { grid-template-columns: 1fr; }
  .dash-wrap { padding: 24px 16px 60px; }
}

/* ---------- Unread message alarm badge ---------- */
.unread-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 100px;
  background: var(--red); color: #fff; font-size: 10px; font-weight: 800; margin-right: 6px;
}
.nav-alarm-dot {
  display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--red);
  margin-right: 4px; box-shadow: 0 0 0 2px rgba(200,16,46,.25);
}

/* ---------- Month payment grid (responsive) ---------- */
.month-grid { display: grid; grid-template-columns: repeat(6, minmax(0,1fr)); gap: 8px; }
@media (max-width: 640px) { .month-grid { grid-template-columns: repeat(3, minmax(0,1fr)); } }
@media (max-width: 380px) { .month-grid { grid-template-columns: repeat(2, minmax(0,1fr)); } }

/* ---------- Rich text content (admin-authored HTML) ---------- */
.rich-content { font-size: 14px; color: var(--text-dim); line-height: 1.95; }
.rich-content p { margin: 0 0 14px; }
.rich-content a { color: var(--gold); text-decoration: underline; }
.rich-content strong, .rich-content b { color: var(--text); font-weight: 700; }
.rich-content ul, .rich-content ol { padding-inline-start: 22px; margin: 0 0 14px; }

/* ---------- Affiliations / licenses strip ---------- */
.affiliations-strip {
  display: flex; align-items: center; justify-content: center; gap: 64px;
  flex-wrap: nowrap; overflow-x: auto; padding: 8px 24px 48px;
  -webkit-overflow-scrolling: touch;
}
.affiliations-strip::-webkit-scrollbar { height: 4px; }
.affiliation-item { display: flex; flex-direction: column; align-items: center; gap: 10px; opacity: .6; transition: opacity .2s; flex-shrink: 0; }
.affiliation-item:hover { opacity: 1; }
.affiliation-item img { height: 70px; width: auto; object-fit: contain; filter: grayscale(40%); transition: filter .2s; display: block; }
.affiliation-item:hover img { filter: grayscale(0%); }
.affiliation-item span { font-size: 11px; color: var(--text-muted); letter-spacing: .5px; text-align: center; white-space: nowrap; }
@media (max-width: 720px) {
  .affiliations-strip { gap: 36px; justify-content: flex-start; }
  .affiliation-item img { height: 52px; }
}

/* ---------- FAQ accordion ---------- */
.faq-item { border: 1px solid var(--border); border-radius: 8px; background: transparent; margin-bottom: 8px; overflow: hidden; }
.faq-question {
  width: 100%; text-align: right; background: none; border: none; color: var(--text-dim); font-family: var(--font);
  font-size: 13px; font-weight: 600; padding: 14px 18px; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.faq-question:hover { color: var(--text); }
.faq-question .plus { flex-shrink: 0; font-size: 15px; color: var(--red); transition: transform .25s; }
.faq-item.open .faq-question .plus { transform: rotate(45deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height .3s ease; }
.faq-item.open .faq-answer { max-height: 400px; }
.faq-answer-inner { padding: 0 18px 16px; font-size: 12.5px; color: var(--text-muted); line-height: 1.85; }

/* ---------- Rich text editor toolbar (admin) ---------- */
.rich-editor-mount { display: none; background: var(--bg); border: 1px solid rgba(255,255,255,.12); border-radius: 8px; overflow: hidden; }
.rich-editor-mount.ready { display: block; }

/* ---------- Image lightbox ---------- */
img.zoomable { cursor: zoom-in; }
.lightbox-overlay {
  position: fixed; inset: 0; z-index: 3000; background: rgba(4,4,6,0.94);
  display: none; align-items: center; justify-content: center; padding: 32px;
  backdrop-filter: blur(4px);
}
.lightbox-overlay.open { display: flex; }
.lightbox-overlay img { max-width: 92vw; max-height: 88vh; border-radius: 10px; box-shadow: 0 20px 60px rgba(0,0,0,.6); object-fit: contain; }
.lightbox-close {
  position: absolute; top: 20px; left: 24px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.2);
  color: #fff; font-size: 26px; width: 42px; height: 42px; border-radius: 50%; cursor: pointer; line-height: 1;
}
.rich-editor-mount .ql-toolbar { border: none; border-bottom: 1px solid rgba(255,255,255,.1); background: var(--card-alt); }
.rich-editor-mount .ql-container { border: none; font-family: var(--font); font-size: 14px; color: var(--text); min-height: 140px; }
.rich-editor-mount .ql-editor { min-height: 140px; }
.rich-editor-mount .ql-picker, .rich-editor-mount .ql-stroke { color: #ccc; }
.rich-editor-mount .ql-stroke { stroke: #ccc; }
.rich-editor-mount .ql-fill { fill: #ccc; }
