* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg: #f4f6fb;
  --card: #ffffff;
  --text: #1e2433;
  --muted: #6b7280;
  --primary: #0ea5a4;
  --primary-dark: #0c8c8b;
  --accent: #f59e0b;
  --danger: #ef4444;
  --ok: #22c55e;
  --border: #e5e7eb;
  --shadow: 0 4px 18px rgba(16, 24, 40, 0.07);
  --radius: 14px;
}

[data-theme="dark"] {
  --bg: #0f172a;
  --card: #1e293b;
  --text: #e2e8f0;
  --muted: #94a3b8;
  --border: #334155;
  --shadow: 0 4px 18px rgba(0, 0, 0, 0.45);
}

html { scroll-behavior: smooth; }

body {
  font-family: "Cairo", "Segoe UI", "Tahoma", Arial, sans-serif;
  font-weight: 600;
  background: var(--bg);
  color: var(--text);
  direction: rtl;
  min-height: 100vh;
  transition: background 0.3s, color 0.3s;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }

header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--card);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.navbar {
  max-width: 960px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand { display: flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 800; }
.brand .logo {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), #38bdf8);
  color: #fff;
  display: grid; place-items: center;
  font-size: 20px;
}

.nav-actions { display: flex; align-items: center; gap: 10px; }

.icon-btn {
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  width: 40px; height: 40px;
  border-radius: 10px;
  font-size: 18px;
  display: grid; place-items: center;
  transition: transform 0.15s;
}
.icon-btn:hover { transform: translateY(-2px); }

.user-chip {
  display: flex; align-items: center; gap: 8px;
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
}

.container { max-width: 960px; margin: 0 auto; padding: 20px 20px 60px; }

.screen { display: none; }
.screen.show { display: block; animation: fadeIn 0.25s ease; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.posters {
  max-width: 520px;
  margin: 0 auto;
}

.poster {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  aspect-ratio: 3 / 4;
  border: 1px solid var(--border);
  background: linear-gradient(160deg, #0f766e, #0ea5a4 45%, #0ea5e9);
  display: grid;
  place-items: center;
}
.poster img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.poster .poster-text {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #fff;
  text-shadow: 0 3px 12px rgba(0, 0, 0, 0.4);
}
.poster .poster-text .big { font-size: 56px; font-weight: 900; letter-spacing: 2px; }
.poster .poster-text .sm { font-size: 17px; opacity: 0.95; font-weight: 700; }

.telegram-cta {
  margin-top: 18px;
  display: flex;
  justify-content: center;
}
.telegram-cta a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #229ed9;
  color: #fff;
  font-weight: 800;
  font-size: 16px;
  padding: 14px 34px;
  border-radius: 999px;
  box-shadow: 0 6px 20px rgba(34, 158, 217, 0.4);
  transition: transform 0.15s;
}
.telegram-cta a:hover { transform: translateY(-3px); }
.telegram-cta .tg { width: 28px; height: 28px; }

.code-panel {
  margin-top: 26px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
}
.code-panel h2 { font-size: 20px; margin-bottom: 4px; text-align: center; }
.code-panel p { text-align: center; color: var(--muted); font-size: 14px; margin-bottom: 18px; }

.code-row { display: flex; gap: 8px; }
.code-row input {
  flex: 1;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  border-radius: 12px;
  padding: 13px 15px;
  font-size: 16px;
  text-align: center;
  letter-spacing: 2px;
  direction: ltr;
  outline: none;
}
.code-row input:focus { border-color: var(--primary); }

.btn {
  border: none;
  border-radius: 12px;
  padding: 13px 18px;
  font-size: 15px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: opacity 0.15s, transform 0.15s, background 0.15s;
}
.btn:active { transform: scale(0.97); }
.btn.primary { background: var(--primary); color: #fff; }
.btn.primary:hover { background: var(--primary-dark); }
.btn.accent { background: var(--accent); color: #fff; }
.btn.outline { border: 1px solid var(--border); background: var(--card); color: var(--text); }
.btn.outline:hover { border-color: var(--primary); color: var(--primary); }
.btn.danger { background: var(--danger); color: #fff; }
.btn.ok { background: var(--ok); color: #fff; }
.btn.small { padding: 9px 13px; font-size: 13px; }
.btn.block { width: 100%; }

.alert {
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 14px;
  text-align: center;
}
.alert.error { background: #fef2f2; color: #b91c1c; border: 1px solid #fecaca; }
.alert.ok { background: #f0fdf4; color: #15803d; border: 1px solid #bbf7d0; }
[data-theme="dark"] .alert.error { background: #450a0a; color: #fca5a5; border-color: #7f1d1d; }
[data-theme="dark"] .alert.ok { background: #052e16; color: #86efac; border-color: #14532d; }

.welcome-card {
  text-align: center;
  background: linear-gradient(135deg, var(--primary), #0ea5e9);
  color: #fff;
  border-radius: var(--radius);
  padding: 26px 20px;
  margin-bottom: 22px;
  box-shadow: var(--shadow);
}
.welcome-card h1 { font-size: 24px; margin-bottom: 6px; }
.welcome-card p { opacity: 0.95; font-size: 14.5px; font-weight: 600; }

.timer-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 22px;
  box-shadow: var(--shadow);
  flex-wrap: wrap;
}
.timer-strip .type { font-size: 14px; font-weight: 800; }
.timer-strip .time { font-size: 15px; font-weight: 900; color: var(--primary); direction: ltr; }
.timer-strip .time.warn { color: var(--danger); }

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 20px;
  font-size: 14px;
}
.breadcrumb button {
  background: var(--card);
  border: 1px solid var(--border);
  color: var(--muted);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 700;
}
.breadcrumb button:hover, .breadcrumb .current { color: var(--primary); border-color: var(--primary); }
.breadcrumb span.sep { color: var(--muted); }

.section-title { font-size: 20px; font-weight: 900; margin-bottom: 16px; }
.section-title small { display: block; color: var(--muted); font-weight: 400; font-size: 13px; margin-top: 3px; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }

.subject-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--card);
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.18s;
}
.subject-card:hover { transform: translateY(-4px); }
.subject-card .img { height: 110px; background: linear-gradient(135deg, var(--primary), #38bdf8); display: grid; place-items: center; font-size: 46px; color: #fff; }
.subject-card .img img { width: 100%; height: 100%; object-fit: cover; }
.subject-card .nm { padding: 13px; text-align: center; font-size: 16px; font-weight: 800; }

.teacher-card { border: 1px solid var(--border); border-radius: var(--radius); background: var(--card); padding: 16px; text-align: center; box-shadow: var(--shadow); }
.teacher-card .ava {
  width: 74px; height: 74px;
  margin: 0 auto 10px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, var(--primary), #38bdf8);
  display: grid; place-items: center;
  font-size: 30px; color: #fff;
}
.teacher-card .ava img { width: 100%; height: 100%; object-fit: cover; }
.teacher-card h3 { font-size: 16px; margin-bottom: 12px; }

.month-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
  padding: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
  cursor: pointer;
  transition: transform 0.15s;
}
.month-card:hover { transform: translateX(-4px); border-color: var(--primary); }
.month-card .lbl { font-size: 16px; font-weight: 800; }
.month-card .cnt { font-size: 13px; color: var(--muted); }

.lecture-row {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card);
  box-shadow: var(--shadow);
  padding: 14px 16px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.lecture-row .ic {
  width: 46px; height: 46px;
  border-radius: 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  display: grid; place-items: center;
  font-size: 22px;
  flex-shrink: 0;
}
.lecture-row .info { flex: 1; min-width: 0; }
.lecture-row .info h4 { font-size: 15px; margin-bottom: 3px; }
.lecture-row .info small { color: var(--muted); font-size: 12px; }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--border);
}
.tag.pdf { color: #dc2626; } .tag.video { color: #2563eb; }
.tag.audio { color: #d97706; } .tag.image { color: #16a34a; }
.tag.notes { color: #475569; }

.empty { text-align: center; padding: 40px 20px; color: var(--muted); }
.empty .big { font-size: 42px; margin-bottom: 10px; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; margin-bottom: 20px; }
.stat { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; text-align: center; }
.stat .num { font-size: 26px; font-weight: 900; color: var(--primary); }
.stat .lbl { font-size: 12.5px; color: var(--muted); margin-top: 4px; }

.admin-grid { display: grid; grid-template-columns: 1fr; gap: 18px; }
.panel-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; }
.panel-card h2 { font-size: 17px; margin-bottom: 14px; }

.code-badge {
  background: var(--bg);
  border: 1px dashed var(--primary);
  color: var(--primary);
  font-weight: 900;
  letter-spacing: 2px;
  direction: ltr;
  padding: 12px;
  border-radius: 10px;
  text-align: center;
  font-size: 20px;
  margin: 10px 0 4px;
}

.status-pill { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 800; padding: 3px 10px; border-radius: 999px; }
.status-pill.active { background: #f0fdf4; color: #15803d; }
.status-pill.used { background: #eff6ff; color: #1d4ed8; }
.status-pill.revoked { background: #fef2f2; color: #b91c1c; }
.status-pill.expired { background: #fef3c7; color: #b45309; }
[data-theme="dark"] .status-pill.active { background: #052e16; color: #86efac; }
[data-theme="dark"] .status-pill.used { background: #172554; color: #93c5fd; }
[data-theme="dark"] .status-pill.revoked { background: #450a0a; color: #fca5a5; }
[data-theme="dark"] .status-pill.expired { background: #451a03; color: #fcd34d; }

.list-item { display: flex; align-items: center; gap: 12px; border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; background: var(--bg); }
.list-item .info { flex: 1; min-width: 0; }
.list-item .info h4 { font-size: 14px; margin-bottom: 3px; }
.list-item .info small { color: var(--muted); font-size: 12px; }
.list-item .acts { display: flex; gap: 6px; flex-wrap: wrap; }

.event-item { display: flex; align-items: flex-start; gap: 10px; border-bottom: 1px solid var(--border); padding: 10px 0; font-size: 13.5px; }
.event-item:last-child { border-bottom: none; }
.event-item .stamp { color: var(--muted); font-size: 11.5px; direction: ltr; white-space: nowrap; }
.event-item b { color: var(--primary); }

.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; color: var(--muted); }
.form-control { width: 100%; border: 1px solid var(--border); background: var(--bg); color: var(--text); border-radius: 10px; padding: 11px 13px; font-size: 14px; outline: none; }
.form-control:focus { border-color: var(--primary); }
textarea.form-control { min-height: 80px; resize: vertical; }
.form-inline { display: flex; gap: 8px; flex-wrap: wrap; }

.inline-cta { margin-top: 4px; background: var(--bg); border: 1px dashed var(--border); border-radius: 10px; padding: 12px; text-align: center; font-size: 13px; color: var(--muted); }
.inline-cta button { border: none; background: none; color: var(--primary); font-weight: 700; font-size: 13px; }

.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.switch-row:last-child { border-bottom: none; }
.switch-row .lbl { font-size: 14px; font-weight: 700; }
.switch-row small { color: var(--muted); display: block; margin-top: 2px; }
.switch { position: relative; width: 46px; height: 26px; flex-shrink: 0; }
.switch input { display: none; }
.switch .slider { position: absolute; inset: 0; background: var(--border); border-radius: 999px; transition: 0.25s; }
.switch .slider::before { content: ""; position: absolute; width: 20px; height: 20px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: 0.25s; box-shadow: 0 1px 4px rgba(0,0,0,0.25); }
.switch input:checked + .slider { background: var(--primary); }
.switch input:checked + .slider::before { transform: translateX(20px); }

.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(80px); background: var(--text); color: var(--bg); padding: 12px 22px; border-radius: 999px; font-size: 14px; font-weight: 700; opacity: 0; transition: 0.3s; z-index: 200; box-shadow: var(--shadow); white-space: nowrap; max-width: 90vw; }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.modal-overlay { position: fixed; inset: 0; background: rgba(2, 6, 23, 0.55); backdrop-filter: blur(3px); display: none; align-items: center; justify-content: center; padding: 20px; z-index: 100; }
.modal-overlay.show { display: flex; }
.modal { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; max-width: 460px; max-height: 90vh; overflow-y: auto; padding: 24px; border: 1px solid var(--border); text-align: center; }
.modal h3 { font-size: 19px; margin-bottom: 10px; }
.modal p { color: var(--muted); font-size: 14px; line-height: 1.8; margin-bottom: 16px; }

.avatar-input { display: flex; align-items: center; gap: 12px; }
.avatar-input .ava { width: 52px; height: 52px; border-radius: 50%; overflow: hidden; background: var(--bg); display: grid; place-items: center; font-size: 22px; flex-shrink: 0; border: 1px solid var(--border); }
.avatar-input .ava img { width: 100%; height: 100%; object-fit: cover; }

footer { border-top: 1px solid var(--border); text-align: center; color: var(--muted); font-size: 13px; padding: 18px; }

/* ============  PAGE DESIGN v2 (LUX)  ============ */
.lux-header {
  position: sticky; top: 0; z-index: 90;
  background: rgba(70, 16, 26, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.lux-nav {
  max-width: 1120px; margin: 0 auto; padding: 12px 22px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; row-gap: 8px; flex-wrap: wrap;
}
.lux-brand { display: flex; align-items: center; gap: 11px; cursor: pointer; }
.lux-logo, .lux-logo-sm {
  width: 42px; height: 42px; border-radius: 13px;
  background: linear-gradient(135deg, #ff9540, #ef6f2c);
  color: #fff; font-weight: 900; font-size: 21px;
  display: grid; place-items: center;
  box-shadow: 0 6px 22px rgba(255, 111, 44, 0.4);
}
.lux-brand-txt b { color: #e9a46f; font-size: 17px; display: block; line-height: 1.15; }
.lux-brand-txt small { color: #8b93ad; font-size: 11.5px; }
.lux-links { display: flex; align-items: center; gap: 6px; }
.lux-links a {
  color: #c7cde0; text-decoration: none; font-size: 13.5px; font-weight: 700;
  padding: 8px 14px; border-radius: 999px; transition: 0.2s;
}
.lux-links a:hover { color: #fff; background: rgba(255, 255, 255, 0.07); }
.lux-actions { display: flex; align-items: center; gap: 10px; }
.lux-icon-btn {
  width: 40px; height: 40px; border-radius: 12px; font-size: 17px;
  background: rgba(255, 255, 255, 0.07); color: #e9a46f;
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: grid; place-items: center; cursor: pointer; transition: 0.2s;
}
.lux-icon-btn:hover { background: rgba(255, 255, 255, 0.14); }
.lux-btn {
  border: none; border-radius: 12px; padding: 10px 18px;
  font-size: 14px; font-weight: 800; cursor: pointer; transition: 0.2s;
  display: inline-flex; align-items: center; gap: 8px;
}
.lux-btn-solid {
  background: linear-gradient(135deg, #ff9540, #ef6f2c);
  color: #fff; box-shadow: 0 6px 20px rgba(255, 111, 44, 0.4);
  border: none;
  transition: 0.18s;
}
.lux-btn-solid:hover { transform: translateY(-3px); box-shadow: 0 12px 28px rgba(255, 111, 44, 0.55), 0 0 0 4px rgba(255, 140, 66, 0.2); }
.lux-btn-ghost {
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
}
.lux-btn-ghost:hover { background: #ff7f33; color: #fff; }

.lux-main { min-height: 100vh; position: relative; }
.lux-hero {
  position: relative;
  min-height: calc(100vh - 66px);
  display: flex; align-items: center; justify-content: center;
  padding: 36px 18px 60px;
  overflow: hidden;
  background: radial-gradient(1200px 700px at 85% -10%, rgba(255, 140, 70, 0.09) 0%, transparent 55%), radial-gradient(1000px 620px at 5% 112%, rgba(255, 140, 70, 0.07) 0%, transparent 52%), #471320;
}
.lux-orb { position: absolute; border-radius: 50%; filter: blur(70px); opacity: 0.45; pointer-events: none; }
.lux-orb-a { width: 420px; height: 420px; top: -120px; right: -80px; background: radial-gradient(circle, rgba(255, 140, 70, 0.22), transparent 65%); }
.lux-orb-b { width: 400px; height: 400px; bottom: -140px; left: -100px; background: radial-gradient(circle, rgba(255, 140, 70, 0.16), transparent 65%); }
.lux-orb-c { width: 260px; height: 260px; top: 40%; left: 30%; background: radial-gradient(circle, rgba(255, 140, 70, 0.14), transparent 70%); opacity: 0.22; }

.lux-scene { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 1; }
.lux-dot {
  position: absolute; border-radius: 50%;
  background: radial-gradient(circle, #ffb27a 0%, rgba(255, 178, 122, 0.35) 55%, transparent 75%);
  filter: blur(0.5px);
  box-shadow: 0 0 14px rgba(255, 150, 90, 0.55);
  animation: luxFloat var(--d, 9s) ease-in-out infinite;
}
.lux-ring {
  position: absolute; border-radius: 50%;
  border: 1.5px solid rgba(255, 150, 90, 0.3);
  animation: luxPulse var(--d, 6s) ease-in-out infinite;
}
.lux-student {
  position: absolute; left: 5%; bottom: 26px; width: 300px; max-width: 30vw;
  opacity: 0.55;
  filter: drop-shadow(0 0 26px rgba(255, 130, 60, 0.25));
  animation: luxFloat 9s ease-in-out infinite;
}
@keyframes luxFloat {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-18px); }
}
@keyframes luxPulse {
  0%, 100% { transform: scale(1); opacity: 0.35; }
  50% { transform: scale(1.12); opacity: 0.12; }
}
.ln { display: block; }
.lux-info-inner .ln,
.lux-info-inner .lux-info-desc,
.lux-feats li,
.lux-badge,
.lux-pill {
  transition: transform 0.25s ease;
  will-change: transform;
}
.lux-info-inner .ln:hover,
.lux-info-inner .lux-info-desc:hover,
.lux-feats li:hover,
.lux-badge:hover,
.lux-pill:hover { transform: translateY(-5px); }

.lux-login-card {
  position: relative; z-index: 5;
  width: 100%; max-width: 1040px; min-width: 0;
  display: grid; grid-template-columns: 1.15fr 0.85fr;
  border-radius: 24px;
  overflow: hidden;
  background: rgba(38, 9, 17, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}
.lux-panel { padding: 40px 34px; }
.lux-panel-enter {
  display: flex; flex-direction: column; justify-content: center;
  border-left: 1px solid rgba(255, 255, 255, 0.07);
}
.lux-eyebrow {
  display: inline-flex; align-self: flex-start;
  font-size: 11.5px; font-weight: 800; letter-spacing: 0.5px;
  color: #ffb27a; background: rgba(255, 140, 70, 0.12);
  border: 1px solid rgba(255, 140, 70, 0.28);
  padding: 5px 12px; border-radius: 999px; margin-bottom: 14px;
}
.lux-panel h1 { color: #e9a46f; font-size: clamp(24px, 4.6vw, 30px); font-weight: 900; margin-bottom: 6px; overflow-wrap: anywhere; }
.lux-sub { color: #97a0ba; font-size: 13.5px; margin-bottom: 20px; line-height: 1.7; }
.lux-sub b { color: #e9a46f; }
.lux-panel-enter label { color: #a9b1c9; font-size: 12.5px; font-weight: 700; margin-bottom: 7px; display: block; }
.lux-input {
  width: 100%; border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: #ffd9b0; border-radius: 13px; padding: 13px 15px; font-size: 14.5px;
  outline: none; transition: 0.2s;
}
.lux-input:focus, .lux-code-row input:focus { border-color: rgba(255, 140, 70, 0.6); box-shadow: 0 0 0 4px rgba(255, 140, 70, 0.18); }
.lux-code-row input {
  width: 100%; border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05); color: #ffd9b0;
  border-radius: 13px; padding: 13px 15px; font-size: 16px;
  text-align: center; letter-spacing: 4px; direction: ltr;
  outline: none; transition: 0.2s; font-weight: 800; text-transform: uppercase;
}
.btn.lux-btn-primary {
  margin-top: 6px; width: 100%;
  background: linear-gradient(135deg, #ff9540, #ef6f2c);
  color: #fff; font-size: 15px;
  box-shadow: 0 10px 28px rgba(255, 111, 44, 0.45);
  transition: 0.18s;
  transition: 0.2s;
}
.btn.lux-btn-primary:hover { filter: brightness(1.08); transform: translateY(-2px); }
.btn.lux-btn-primary:disabled { opacity: 0.65; transform: none; cursor: wait; }
.lux-hints { margin-top: 18px; text-align: center; color: #8f98b2; font-size: 13px; line-height: 1.9; }
.lux-hints a { color: #e9a46f; font-weight: 800; text-decoration: none; }
.lux-hints a:hover { text-decoration: underline; }
.lux-channel {
  display: inline-block; margin-top: 6px; padding: 9px 20px; border-radius: 14px;
  background: rgba(120, 22, 40, 0.5);
  color: #fff !important; font-size: 14px; font-weight: 900; text-decoration: none !important;
  border: 1px solid rgba(255, 255, 255, 0.15); box-shadow: 0 8px 22px rgba(110, 16, 34, 0.35);
  transition: 0.2s;
}
.lux-channel:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(110, 16, 34, 0.5); background: rgba(140, 30, 52, 0.6); text-decoration: none !important; }
.lux-channel small { display: block; font-size: 11px; font-weight: 700; color: rgba(255, 255, 255, 0.75); margin-top: 1px; }
.lux-staff { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.lux-staff-item { display: flex; align-items: center; gap: 11px; padding: 10px 14px; border-radius: 14px; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.12); text-decoration: none; transition: 0.2s; }
.lux-staff-item:hover { border-color: rgba(255, 140, 70, 0.45); background: rgba(255, 140, 70, 0.10); }
.staff-ic { width: 38px; height: 38px; border-radius: 11px; background: linear-gradient(135deg, #ff9540, #ef6f2c); display: grid; place-items: center; font-size: 17px; flex-shrink: 0; }
.staff-txt { flex: 1; color: #e9a46f; font-size: 13px; font-weight: 800; display: flex; flex-direction: column; gap: 2px; text-align: right; }
.staff-txt small { color: #8f98b2; font-size: 11.5px; direction: ltr; text-align: right; }
.staff-go { color: #e9a46f; }
.lux-staff-off { color: #8f98b2; font-size: 12.5px; text-align: center; padding: 8px; }

.lux-login-card .lux-panel-enter { order: 1; }
.lux-login-card .lux-panel-info { order: 2; }

.lux-panel-info {
  position: relative;
  background: linear-gradient(160deg, rgba(255, 140, 70, 0.06), rgba(255, 140, 70, 0.09));
  display: flex; align-items: center;
  overflow: hidden;
}
.lux-info-inner { width: 100%; position: relative; z-index: 2; }
.lux-mini-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 22px; }
.lux-logo-sm { width: 40px; height: 40px; font-size: 19px; border-radius: 12px; }
.lux-mini-brand b { display: block; color: #e9a46f; font-size: 15.5px; }
.lux-mini-brand small { color: #8f98b2; font-size: 11.5px; }
.lux-panel-info h2 { color: #e9a46f; font-size: clamp(25px, 5vw, 33px); font-weight: 900; line-height: 1.4; margin-bottom: 12px; overflow-wrap: anywhere; }
.lux-info-desc { color: #b6bed6; font-size: 13.5px; line-height: 1.85; margin-bottom: 20px; max-width: 42ch; }
.lux-feats { list-style: none; display: flex; flex-direction: column; gap: 13px; margin-bottom: 22px; }
.lux-feats li { display: flex; align-items: center; gap: 12px; }
.li-ic {
  width: 40px; height: 40px; flex-shrink: 0; border-radius: 12px;
  display: grid; place-items: center; font-size: 18px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.lux-feats b { display: block; color: #e9a46f; font-size: 13.5px; }
.lux-feats small { color: #8f98b2; font-size: 12px; }
.lux-badge {
  display: flex; align-items: center; gap: 8px;
  background: rgba(255, 140, 70, 0.10);
  border: 1px dashed rgba(255, 140, 70, 0.4);
  color: #e9a46f; font-size: 12.5px; font-weight: 700;
  border-radius: 13px; padding: 11px 14px;
}

.lux-welcome { background: rgba(255, 140, 70, 0.12); border: 1px solid rgba(255, 140, 70, 0.3); }
.lux-timer { border-color: rgba(255, 255, 255, 0.1); background: rgba(255, 255, 255, 0.05); }

@media (max-width: 1240px) {
  .lux-student { width: 210px; left: 2%; bottom: 46px; opacity: 0.42; }
  .lux-ring { display: none; }
}
@media (max-width: 1000px) {
  .lux-student { width: 140px; left: 1%; bottom: 70px; opacity: 0.3; }
  .lux-dot { opacity: 0.55; }
  .lux-hero { padding-bottom: 46px; }
}
@media (max-width: 880px) {
  .lux-login-card { grid-template-columns: 1fr; max-width: 470px; }
  .lux-panel-enter { border-left: none; border-bottom: 1px solid rgba(255, 255, 255, 0.07); }
  .lux-links a:not(:last-child) { display: none; }
  .lux-student { display: none; }
  .lux-ring { display: none; }
}
@media (max-width: 440px) {
  .lux-nav { padding: 10px 14px; }
  .lux-links a { padding: 8px 10px; font-size: 12.5px; }
  .lux-panel { padding: 28px 20px; }
  .lux-panel-info h2 { font-size: 25px; }
}
.viewer-overlay { position: fixed; inset: 0; background: rgba(2, 6, 23, 0.88); display: none; align-items: center; justify-content: center; padding: 16px; z-index: 300; }
.viewer-overlay.show { display: flex; }
.viewer-box { background: var(--card); border-radius: var(--radius); max-width: 980px; width: 100%; height: 88vh; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--border); box-shadow: var(--shadow); }
.viewer-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.viewer-head h3 { font-size: 15px; max-width: 85%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.modal-close { border: none; background: var(--bg); color: var(--text); width: 34px; height: 34px; border-radius: 10px; font-size: 16px; flex-shrink: 0; }
.viewer-body { position: relative; flex: 1; min-height: 0; overflow: hidden; background: #fff; }
.viewer-body iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: none; background: #fff; }
.viewer-spinner { position: absolute; inset: 0; z-index: 5; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; background: #fff; color: #475569; font-size: 13px; }
.viewer-spinner .spin { width: 42px; height: 42px; border-radius: 50%; border: 4px solid #e2e8f0; border-top-color: #f97316; animation: vspin 0.9s linear infinite; }
@keyframes vspin { to { transform: rotate(360deg); } }
.viewer-body img { width: 100%; height: 100%; object-fit: contain; background: #111827; }
.viewer-body video { width: 100%; height: 100%; object-fit: contain; background: #000; }
.viewer-body audio { width: 90%; margin: 30px auto; display: block; }
.viewer-note { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; height: 100%; color: var(--muted); font-size: 14px; text-align: center; }

/* ===================== شاشات الطالب (هَب/مكتبة) — ثيم بنج/برتقالي ===================== */
body.lux-page {
  background:
    radial-gradient(1000px 500px at 85% -10%, rgba(255, 140, 70, 0.10), transparent 60%),
    radial-gradient(800px 420px at 5% 110%, rgba(255, 110, 60, 0.08), transparent 60%),
    linear-gradient(180deg, #4a1220 0%, #300c12 55%, #1c070b 100%);
  background-attachment: fixed;
  color: #ffeadd;
  min-height: 100vh;
}
body.lux-page .screen { display: none; }
body.lux-page .screen.show { display: block; animation: luxFadeIn .45s ease both; }
@keyframes luxFadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.lux-page .lux-header { position: sticky; top: 0; z-index: 50; }

.hub-wrap { max-width: 1020px; margin: 0 auto; padding-inline: clamp(14px, 4vw, 22px); }
#screen-welcome .hub-wrap { display: flex; flex-direction: column; align-items: center; text-align: center; padding-top: 34px; gap: 18px; }

.poster-frame {
  width: min(560px, 94%);
  aspect-ratio: 16/8;
  border-radius: 22px;
  overflow: hidden;
  position: relative;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #2a0a11, #4a1220);
  border: 1px solid rgba(255, 159, 96, 0.35);
  box-shadow: 0 22px 60px rgba(255, 120, 50, 0.16), inset 0 0 60px rgba(255, 120, 50, 0.08);
}
.poster-frame img { width: 100%; height: 100%; object-fit: cover; }
.poster-frame .pf-empty { color: #e9a46f; font-size: 44px; filter: drop-shadow(0 4px 10px rgba(255,120,50,.4)); }
.welcome-title { color: #ffd0a0; font-size: clamp(22px, 5.6vw, 30px); font-weight: 900; margin: 2px 0 0; line-height: 1.4; text-shadow: 0 0 22px rgba(255, 140, 70, 0.35); overflow-wrap: anywhere; }
.poster-slogan { color: rgba(255, 224, 199, 0.82); font-size: clamp(13px, 2.6vw, 15px); line-height: 1.9; max-width: 46ch; margin: 0; }
.hub-cta { font-size: 17px; padding: 15px 44px; border-radius: 16px; }
.welcome-under { color: rgba(255, 224, 199, 0.45); font-size: 13px; }
.welcome-under b { color: #e9a46f; }

.greet-block { text-align: center; margin: 2px 0 12px; padding-right: 8px; }
.greet-title {
  margin: 0; font-size: clamp(19px, 4.6vw, 25px); font-weight: 900; line-height: 1.7;
  color: #ffd9ad; text-shadow: 0 0 20px rgba(255, 150, 90, 0.4);
  animation: greetPulse 3s ease-in-out infinite;
  overflow-wrap: anywhere;
}
@keyframes greetPulse { 0%,100% { text-shadow: 0 0 18px rgba(255,150,90,.35); } 50% { text-shadow: 0 0 30px rgba(255,180,120,.7); } }

.flag-wrap {
  position: fixed; right: 18px; top: 68px; z-index: 95;
  display: flex; align-items: center; gap: 4px;
  animation: flagFloat 5.5s ease-in-out infinite;
  pointer-events: none;
}
@keyframes flagFloat { 0%,100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-10px) rotate(1.6deg); } }
.flag-pole {
  width: 6px; height: 132px; border-radius: 3px;
  background: linear-gradient(90deg, #c9bda0, #8a7f6a);
  box-shadow: 0 0 8px rgba(0,0,0,.35);
}
.flag-egypt {
  position: relative; width: 88px; height: 58px; border-radius: 6px; overflow: hidden;
  display: flex; flex-direction: column;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.45), 0 0 0 2px rgba(255, 255, 255, 0.08);
  transform-origin: left center;
  animation: flagWave 4.5s ease-in-out infinite;
}
@keyframes flagWave { 0%,100% { transform: skewY(0); } 30% { transform: skewY(3deg); } 70% { transform: skewY(-2.4deg); } }
.flag-e-stripe { flex: 1; }
.flag-e-stripe.red { background: #ce1126; }
.flag-e-stripe.white { background: #ffffff; position: relative; }
.flag-e-stripe.black { background: #101010; }
.flag-eagle {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-size: 26px; line-height: 1;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.35));
}

@media (max-width: 520px) {
  .flag-wrap { right: 8px; top: 60px; }
  .flag-pole { height: 96px; }
  .flag-egypt { width: 66px; height: 44px; }
  .flag-eagle { font-size: 20px; }
}

.hub-greet { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 18px 22px; border-radius: 18px; margin-bottom: 20px; }
.hub-greet h1 { margin: 0 0 4px; font-size: clamp(16.5px, 3.2vw, 21px); color: #ffd0a0; overflow-wrap: anywhere; }
.hub-greet p { margin: 0; font-size: 13.5px; color: rgba(255, 224, 199, 0.75); line-height: 1.7; }
.hub-greet .timer-strip { margin: 0; }

.hub-head { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin: 20px 0 18px; }
.back-btn {
  min-width: 108px; height: 44px; padding: 0 16px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 1px solid rgba(255, 150, 95, 0.45);
  background: rgba(255, 150, 95, 0.12);
  color: #ffd9ad; font-weight: 800; font-size: 14.5px; border-radius: 13px;
  cursor: pointer; transition: 0.2s; white-space: nowrap;
}
.back-btn:hover { background: rgba(255, 150, 95, 0.25); transform: translateX(-3px); }
.hub-titles { flex: 1; }
.hub-titles .section-title { margin: 0 0 4px; color: #ffd0a0; font-size: clamp(17px, 3.4vw, 21px); }
.hub-titles .tnum { color: #0ea5a4; display: inline-block; text-shadow: 0 0 14px rgba(14, 165, 164, 0.5); }
.page-sub { margin: 0; color: rgba(255, 224, 199, 0.62); font-size: 13px; line-height: 1.7; }
.hub-head .breadcrumb { width: 100%; margin: 0; font-size: 12.5px; }
.hub-head .breadcrumb button, .hub-head .breadcrumb .sep { color: rgba(255, 224, 199, 0.45); }
.hub-head .breadcrumb button { cursor: pointer; background: none; border: none; padding: 0; font-size: 12.5px; }
.hub-head .breadcrumb button.current { color: #e9a46f; font-weight: 800; }
.hub-foot { margin-top: 46px; display: flex; justify-content: center; }
body.lux-page #screen-home.show { display: flex; align-items: flex-start; justify-content: center; }
body.lux-page #screen-home .hub-wrap { flex: 1; display: flex; flex-direction: column; width: 100%; max-width: 1020px; }
body.lux-page #screen-home #pageBody { flex: 1 0 auto; }
body.lux-page #screen-home .hub-foot { margin-top: 26px; padding-bottom: 18px; }

.quran-widget { position: fixed; left: 16px; bottom: 16px; z-index: 960; direction: rtl; }
.qw-mini {
  width: 56px; height: 56px; border-radius: 50%; border: none; cursor: pointer;
  background: linear-gradient(135deg, #16a36a, #0d7a4b);
  color: #fff; font-size: 24px;
  box-shadow: 0 10px 24px rgba(13, 122, 75, 0.45);
  display: flex; align-items: center; justify-content: center;
  transition: 0.2s;
}
.qw-mini:hover { transform: scale(1.08); }
.qw-panel {
  position: absolute; bottom: 66px; left: 0; width: 250px;
  background: rgba(16, 24, 20, 0.96); border: 1px solid rgba(22, 163, 106, 0.4);
  border-radius: 16px; padding: 12px; box-shadow: 0 18px 46px rgba(0, 0, 0, 0.55);
  animation: luxFadeIn 0.25s ease;
}
.qw-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.qw-head b { color: #c6f6d5; font-size: 12.5px; line-height: 1.5; }
.qw-head-acts { display: flex; gap: 5px; }
.qw-btn {
  width: 30px; height: 30px; border-radius: 9px; border: 1px solid rgba(22, 163, 106, 0.35);
  background: rgba(22, 163, 106, 0.12); color: #d1fae5; cursor: pointer; font-size: 12px;
  display: flex; align-items: center; justify-content: center; transition: 0.2s;
}
.qw-btn:hover { background: rgba(22, 163, 106, 0.25); }
.qw-btn.play { background: linear-gradient(135deg, #16a36a, #0d7a4b); border: none; font-size: 13px; }
.qw-btn.play:hover { filter: brightness(1.12); }
.qw-name { color: #fff; font-weight: 800; font-size: 15px; text-align: center; margin-bottom: 8px; }
.qw-progress { height: 5px; border-radius: 4px; background: rgba(255, 255, 255, 0.12); overflow: hidden; }
.qw-bar { height: 100%; width: 0; background: linear-gradient(90deg, #34d399, #0ea56a); transition: width 0.25s linear; }
.qw-vol { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.qw-vol-ic { font-size: 13px; color: #d1fae5; width: 18px; text-align: center; }
.qw-vol-range {
  flex: 1; -webkit-appearance: none; appearance: none; height: 5px; border-radius: 4px;
  background: rgba(255, 255, 255, 0.14); outline: none; cursor: pointer;
}
.qw-vol-range::-webkit-slider-thumb {
  -webkit-appearance: none; width: 14px; height: 14px; border-radius: 50%;
  background: #34d399; border: none; cursor: pointer; box-shadow: 0 0 8px rgba(52, 211, 153, 0.55);
}
.qw-vol-range::-moz-range-thumb {
  width: 14px; height: 14px; border-radius: 50%;
  background: #34d399; border: none; cursor: pointer;
}

#pageBody .grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(290px, 100%), 1fr)); gap: clamp(14px, 2.4vw, 22px); }
.scard {
  min-width: 0;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 150, 95, 0.16);
  border-radius: 18px;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.38), 0 3px 9px rgba(0, 0, 0, 0.28);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.scard:hover { transform: translateY(-6px); border-color: rgba(255, 150, 95, 0.5); box-shadow: 0 22px 48px rgba(0, 0, 0, 0.5), 0 16px 38px rgba(255, 100, 40, 0.14); }
.scard .simg {
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, #3d131f, #1c070c);
  display: grid; place-items: center; overflow: hidden;
  position: relative; border-bottom: 1px solid rgba(255, 150, 95, 0.12);
}
.scard .simg img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.scard:hover .simg img { transform: scale(1.06); }
.scard .simoji { font-size: 40px; filter: drop-shadow(0 4px 12px rgba(255, 120, 50, 0.35)); }
.scard .sch-hero { position: relative; width: 100%; height: 100%; display: grid; place-items: center; overflow: hidden; }
.scard .sch-hero .simoji { position: absolute; z-index: 0; font-size: 58px; opacity: 0.45; filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.55)); }
.scard .sch-hero .sch-char { position: absolute; z-index: 2; left: 50%; bottom: -6px; height: 86%; width: auto; transform: translateX(-50%); pointer-events: none; transition: filter 0.35s ease; }
.scard:hover .sch-hero .sch-char { filter: brightness(1.12) drop-shadow(0 12px 22px rgba(0, 0, 0, 0.5)); }
.sch-fig { transform-box: fill-box; transform-origin: 50% 100%; animation: scBreath 3.8s ease-in-out infinite; }
.sch-head { transform-box: fill-box; transform-origin: 50% 85%; animation: scHead 5.6s ease-in-out infinite; }
.sch-eyes { transform-box: fill-box; transform-origin: 50% 50%; animation: scBlink 4.4s linear infinite; }
.sch-coat { transform-box: fill-box; transform-origin: 50% 0%; animation: scSway 5s ease-in-out infinite; }
.sch-glow { animation: scGlowPulse 4.5s ease-in-out infinite; }
.spell { transform-box: fill-box; transform-origin: 50% 50%; animation: spFloat 4.6s ease-in-out infinite; }
.spell.sp-b { animation-duration: 6.2s; animation-delay: 0.5s; }
.spell.sp-c { animation-duration: 3.7s; animation-delay: 1.1s; }
.spell.sp-d { animation-duration: 5.4s; animation-delay: 0.3s; }
.spell.sp-h { opacity: 0; transition: opacity 0.4s ease; }
.scard:hover .spell.sp-h { opacity: 1; }
@keyframes scBreath { 0%, 100% { transform: translateY(0) scaleY(1); } 50% { transform: translateY(3px) scaleY(1.015); } }
@keyframes scHead { 0%, 100% { transform: rotate(0deg); } 50% { transform: rotate(2.4deg); } }
@keyframes scBlink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(0.06); } }
@keyframes scSway { 0%, 100% { transform: rotate(0deg); } 50% { transform: rotate(-1.6deg); } }
@keyframes scGlowPulse { 0%, 100% { opacity: 0.75; } 50% { opacity: 1; } }
@keyframes spFloat { 0%, 100% { transform: translate(0, 0) rotate(-5deg); } 50% { transform: translate(0, -16px) rotate(7deg); } }
@media (prefers-reduced-motion: reduce) {
  .spell, .sch-fig, .sch-head, .sch-eyes, .sch-coat, .sch-glow { animation: none !important; }
}
.scard .sbody { padding: 16px 17px 18px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.scard .sstatus {
  right: auto;
  font-size: 11px;
  padding: 3px 11px;
  border-radius: 99px;
  color: #c7ffd8;
  background: rgba(34, 197, 94, 0.16);
  border: 1px solid rgba(34, 197, 94, 0.35);
}
.scard .sname { margin: 0; color: #ffeadd; font-size: clamp(15px, 2.8vw, 18.5px); font-weight: 800; overflow-wrap: anywhere; }
.scard .sdate { color: rgba(255, 224, 199, 0.55); font-size: 12.5px; }
.sbtn {
  margin-top: 5px;
  border: none; cursor: pointer;
  color: #fff7e8; font-weight: 900; font-size: 14px;
  padding: 11px 20px; border-radius: 12px;
  background: linear-gradient(135deg, #ff9540, #ef6f2c);
  box-shadow: 0 8px 20px rgba(255, 130, 60, 0.28);
  transition: 0.2s;
}
.sbtn:hover { filter: brightness(1.09); transform: translateY(-1px); }
.sbtn.sm { padding: 9px 15px; font-size: 12.5px; white-space: nowrap; }

.slot {
  display: flex; align-items: center; gap: 14px; row-gap: 10px; flex-wrap: wrap;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 150, 95, 0.16);
  border-radius: 16px; padding: 14px 16px;
  transition: 0.22s; margin-bottom: 12px;
}
.slot:not(.soon):hover { border-color: rgba(255, 150, 95, 0.5); transform: translateX(-4px); box-shadow: 0 12px 28px rgba(255, 100, 40, 0.12); }
.slot .sic { width: 46px; height: 46px; border-radius: 13px; background: linear-gradient(135deg, #ff9540, #ef6f2c); display: grid; place-items: center; font-size: 20px; flex-shrink: 0; }
.slot .sint { flex: 1 1 150px; min-width: 0; }
.slot .sint h4 { margin: 0 0 5px; color: #ffeadd; font-size: 15.5px; }
.chips { display: flex; gap: 7px; flex-wrap: wrap; }
.chip { font-size: 11px; color: rgba(255, 224, 199, 0.75); background: rgba(255, 150, 95, 0.10); border: 1px solid rgba(255, 150, 95, 0.18); padding: 3px 10px; border-radius: 99px; font-weight: 700; }
.slot.soon { opacity: 0.55; border-style: dashed; }
.slot.soon .sic { background: rgba(255, 255, 255, 0.07); color: rgba(255, 224, 199, 0.5); }
.slot.soon .sint h4 { color: rgba(255, 224, 199, 0.6); font-weight: 700; }
.slot.soon .sint small { display: block; color: rgba(255, 224, 199, 0.4); }

.empty { text-align: center; padding: 44px 12px; color: rgba(255, 224, 199, 0.55); }
.empty .big { font-size: 38px; margin-bottom: 8px; }
.empty p { margin: 0; font-size: 13.5px; }

.content-sec { margin-bottom: 30px; }
.content-sec h3 { color: #ffd0a0; font-size: 18.5px; margin: 0 0 14px; display: flex; align-items: center; gap: 8px; }
.vlist { display: flex; flex-direction: column; gap: 12px; }
.vitem { display: flex; flex-wrap: wrap; gap: 14px; background: rgba(255, 255, 255, 0.045); border: 1px solid rgba(255, 150, 95, 0.16); border-radius: 16px; padding: 12px; transition: 0.22s; }
.vitem:hover { border-color: rgba(255, 150, 95, 0.45); }
.vthumb { position: relative; width: 190px; flex-shrink: 0; aspect-ratio: 16/9; border-radius: 12px; overflow: hidden; background: #000; display: grid; place-items: center; }
.vthumb img { width: 100%; height: 100%; object-fit: cover; }
.vthumb .vim { font-size: 26px; }
.vdur { position: absolute; bottom: 6px; left: 6px; background: rgba(0, 0, 0, 0.7); color: #ffd0a0; font-size: 10.5px; padding: 2px 8px; border-radius: 7px; }
.vmeta { flex: 1 1 160px; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 5px; justify-content: center; }
.vmeta h4 { margin: 0; color: #ffeadd; font-size: 15px; }
.vmeta small { color: rgba(255, 224, 199, 0.55); font-size: 12px; }
.flist { display: flex; flex-direction: column; gap: 10px; }
.fitm { display: flex; align-items: center; gap: 12px; background: rgba(255, 255, 255, 0.045); border: 1px solid rgba(255, 150, 95, 0.16); border-radius: 14px; padding: 12px 14px; flex-wrap: wrap; }
.fitm .fic { font-size: 22px; }
.fitm .fmeta { flex: 1 1 130px; min-width: 0; }
.fitm .fmeta h4 { margin: 0; color: #ffeadd; font-size: 14.5px; }
.fitm .fmeta small { color: rgba(255, 224, 199, 0.55); font-size: 11.5px; }

/* ===================== المشغل المحمي (ووترمارك/سرعة 3x/بدون تحميل) ===================== */
.viewer-overlay.player { background: rgba(6, 3, 4, 0.93); }
.viewer-overlay.player .viewer-box { max-width: 1080px; height: 92vh; background: #140609; border-color: rgba(255, 150, 95, 0.35); }
.viewer-overlay.player .viewer-head { border-color: rgba(255, 150, 95, 0.16); background: #1b090d; }
.viewer-overlay.player .viewer-head h3 { color: #ffd0a0; }
.viewer-overlay.player .viewer-body { background: #000; }
.vplayer { position: relative; height: 100%; display: flex; flex-direction: column; user-select: none; -webkit-user-select: none; }
.vplayer video { flex: 1; width: 100%; height: 100%; object-fit: contain; background: #000; cursor: pointer; }
.wm {
  position: absolute; top: 12%; left: 18%;
  transform: translate(-50%, -50%);
  padding: 5px 12px; border-radius: 8px;
  font-size: 13px; font-weight: 800; font-family: monospace;
  color: rgba(255, 235, 215, 0.3);
  text-shadow: 0 0 8px rgba(0, 0, 0, 0.75);
  background: rgba(255, 150, 95, 0.06);
  border: 1px solid rgba(255, 150, 95, 0.16);
  pointer-events: none; white-space: nowrap;
  animation: wmMove 55s linear infinite;
  will-change: top, left;
}
@keyframes wmMove {
  0%   { top: 12%; left: 18%; transform: translate(-50%, -50%) rotate(-2deg); }
  10%  { top: 14%; left: 80%; transform: translate(-50%, -50%) rotate(1deg); }
  20%  { top: 30%; left: 90%; transform: translate(-50%, -50%) rotate(-1deg); }
  30%  { top: 60%; left: 80%; transform: translate(-50%, -50%) rotate(2deg); }
  40%  { top: 84%; left: 64%; transform: translate(-50%, -50%) rotate(-1deg); }
  50%  { top: 78%; left: 26%; transform: translate(-50%, -50%) rotate(1deg); }
  60%  { top: 50%; left: 12%; transform: translate(-50%, -50%) rotate(-1deg); }
  70%  { top: 22%; left: 36%; transform: translate(-50%, -50%) rotate(2deg); }
  80%  { top: 46%; left: 52%; transform: translate(-50%, -50%) rotate(-1deg); }
  90%  { top: 72%; left: 40%; transform: translate(-50%, -50%) rotate(1deg); }
  100% { top: 12%; left: 18%; transform: translate(-50%, -50%) rotate(-2deg); }
}
.p-controls {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  background: #1b090d; border-top: 1px solid rgba(255, 150, 95, 0.16);
}
.p-btn {
  width: 38px; height: 38px; flex-shrink: 0;
  border: 1px solid rgba(255, 150, 95, 0.3);
  background: rgba(255, 150, 95, 0.10);
  color: #ffd0a0; border-radius: 11px; cursor: pointer; font-size: 14px; transition: 0.2s;
}
.p-btn:hover { background: rgba(255, 150, 95, 0.2); }
.p-time { color: rgba(255, 224, 199, 0.75); font-size: 12px; white-space: nowrap; direction: ltr; }
.p-seek { flex: 1; height: 4px; accent-color: #ff9540; cursor: pointer; min-width: 80px; }
.p-sel {
  background: #2a0e14; color: #ffd0a0;
  border: 1px solid rgba(255, 150, 95, 0.3);
  border-radius: 9px; padding: 7px 8px; font-size: 12px; cursor: pointer;
  font-family: inherit;
}
.vplayer audio { width: 96%; margin: auto; display: block; }
@media (max-width: 640px) {
  .vitem { flex-direction: column; }
  .vthumb { width: 100%; }
  .hub-greet { flex-direction: column; align-items: flex-start; }
  .p-controls { flex-wrap: wrap; }
}
@media (max-width: 480px) {
  .welcome-title { font-size: 24px; }
  .poster-slogan { font-size: 13.5px; }
}

/* ===================== هيرو الفصول / المحاضرات ===================== */
.lec-hero {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  margin: 0 0 24px; padding: 20px;
  background: linear-gradient(135deg, rgba(16, 30, 19, 0.94), rgba(27, 42, 23, 0.9));
  border: 1px solid rgba(22, 163, 106, 0.25);
  border-radius: 20px;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.35);
}
.lh-ava {
  width: 86px; height: 86px; border-radius: 50%; overflow: hidden; flex-shrink: 0;
  border: 3px solid rgba(22, 163, 106, 0.55);
  background: linear-gradient(135deg, #16a36a, #0d7a4b);
  display: flex; align-items: center; justify-content: center;
}
.lh-ava img { width: 100%; height: 100%; object-fit: cover; }
.lh-ava span { font-size: 34px; }
.lh-meta { display: flex; flex-direction: column; gap: 5px; min-width: 0; flex: 1 1 240px; }
.lh-route { font-size: 14px; font-weight: 700; color: #ffd9ad; }
.lh-title { font-size: clamp(20px, 4.6vw, 28px); font-weight: 900; color: #fff; margin: 0; line-height: 1.3; overflow-wrap: anywhere; }
.lh-sub { font-size: 13.5px; color: rgba(255, 255, 255, 0.72); line-height: 1.7; margin: 0; }
@media (max-width: 520px) {
  .lec-hero { gap: 12px; padding: 16px; }
  .lh-ava { width: 64px; height: 64px; }
  .lh-title { font-size: 22px; }
}

/* ===================== منيو الطالب (أهلاً + حسابي) ===================== */
.user-menu { position: fixed; left: 18px; top: 16px; z-index: 950; direction: rtl; }
.um-badge {
  display: flex; align-items: center; gap: 8px; cursor: pointer;
  background: linear-gradient(135deg, rgba(255, 140, 60, 0.16), rgba(255, 140, 60, 0.08));
  border: 1px solid rgba(255, 150, 95, 0.4);
  border-radius: 999px; padding: 5px 14px 5px 8px;
  color: #ffd9ad; font-family: inherit; transition: 0.2s;
}
.um-badge:hover { background: linear-gradient(135deg, rgba(255, 140, 60, 0.28), rgba(255, 140, 60, 0.14)); border-color: rgba(255, 150, 95, 0.65); }
.um-av { width: 34px; height: 34px; border-radius: 50%; background: linear-gradient(135deg, #ff9540, #ef6f2c); display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; }
.um-txt { display: flex; flex-direction: column; line-height: 1.2; text-align: right; }
.um-txt b { font-size: 13.5px; font-weight: 900; }
.um-txt small { font-size: 11px; opacity: 0.75; }
.um-drop {
  position: absolute; top: calc(100% + 8px); left: 0; min-width: 224px;
  background: rgba(24, 12, 8, 0.97); border: 1px solid rgba(255, 150, 95, 0.3);
  border-radius: 14px; padding: 8px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  animation: luxFadeIn 0.2s ease;
}
.um-drop-head { font-size: 11px; color: rgba(255, 224, 199, 0.55); padding: 4px 8px 8px; border-bottom: 1px solid rgba(255, 150, 95, 0.14); margin-bottom: 6px; font-weight: 700; }
.um-item {
  width: 100%; text-align: right; display: flex; flex-direction: column; gap: 2px;
  background: transparent; border: none; cursor: pointer; color: #ffeadd;
  padding: 9px 10px; border-radius: 10px; font-size: 14px; font-weight: 800;
  font-family: inherit;
}
.um-item small { font-size: 11px; font-weight: 500; color: rgba(255, 224, 199, 0.62); }
.um-item:hover { background: rgba(255, 150, 95, 0.12); }
.um-item.danger { color: #ffb4ad; }
.um-item.danger:hover { background: rgba(255, 90, 80, 0.14); }
.acc-box { max-width: 440px; }
.acc-sec { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 14px 6px 8px; }
.acc-ava { width: 64px; height: 64px; border-radius: 50%; background: linear-gradient(135deg, #ff9540, #ef6f2c); display: flex; align-items: center; justify-content: center; font-size: 26px; font-weight: 900; color: #fff; box-shadow: 0 8px 22px rgba(255, 120, 50, 0.4); }
.acc-sec h2 { margin: 4px 0 0; font-size: 20px; color: #ffd9ad; }
.acc-uid { font-family: monospace; font-size: 13px; color: #43d9a3; background: rgba(67, 217, 163, 0.1); border: 1px dashed rgba(67, 217, 163, 0.4); padding: 4px 12px; border-radius: 9px; letter-spacing: 1px; }
.acc-sec small { color: rgba(255, 224, 199, 0.65); font-size: 12px; }
.acc-box2 { display: flex; gap: 8px; justify-content: center; margin: 10px 0; }
.acc-stat { flex: 1; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 150, 95, 0.16); border-radius: 12px; padding: 10px 6px; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.acc-stat b { font-size: 17px; color: #ffd9ad; }
.acc-stat span { font-size: 11px; color: rgba(255, 224, 199, 0.6); }
.acc-note { background: rgba(67, 217, 163, 0.08); border: 1px solid rgba(67, 217, 163, 0.25); color: #c9f7e2; font-size: 13px; line-height: 1.8; border-radius: 12px; padding: 12px; margin: 8px 0; }
.acc-stats { display: flex; gap: 8px; justify-content: center; margin: 4px 0 0; }
.acc-sec-label { font-size: 12.5px; font-weight: 800; color: rgba(255, 224, 199, 0.72); margin-bottom: 8px; }
.acc-bar { margin-bottom: 8px; }
.acc-bar-t { display: flex; justify-content: space-between; align-items: center; font-size: 12px; margin-bottom: 4px; }
.acc-bar-t span { color: rgba(255, 224, 199, 0.85); font-weight: 700; }
.acc-bar-t b { color: #43d9a3; }
.acc-bar-tr { height: 9px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.acc-bar-tr i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #43d9a3, #ff9540); transition: width 0.6s ease; }
.acc-mini { font-size: 12px; color: rgba(255, 224, 199, 0.7); text-align: center; margin: 6px 0; }
.acc-mini b { color: #ffd9ad; }
@media (max-width: 520px) {
  .acc-stats .acc-stat b { font-size: 14px; }
}
@media (max-width: 520px) {
  .user-menu { left: 10px; top: 10px; }
  .um-txt b { font-size: 12.5px; }
}

/* ===================== التجاوب الكامل: تابلت وموبايل ===================== */
html { -webkit-text-size-adjust: 100%; }
body.lux-page { overflow-x: hidden; }
.slot .sint h4, .vmeta h4, .fmeta h4 { overflow-wrap: anywhere; min-width: 0; }

@media (max-width: 900px) {
  .lux-login-card { grid-template-columns: 1fr; max-width: 500px; }
  .lux-panel-enter { border-left: none; border-bottom: 1px solid rgba(255, 255, 255, 0.07); }
  .lux-panel { padding: 30px 24px; }
  .lux-hero { padding: 30px 14px 48px; }
}

@media (max-width: 768px) {
  .hub-greet { padding: 14px 16px; }
  .hub-head { margin: 16px 0 14px; }
  #pageBody .grid { gap: 14px; }
  .slot { padding: 12px 14px; gap: 10px; }
  .lec-hero { padding: 16px; gap: 12px; }
  .lh-ava { width: 66px; height: 66px; }
  .scard .sbody { padding: 13px 15px 16px; }
  .viewer-overlay { padding: 10px; }
}

@media (max-width: 560px) {
  .lux-nav { padding: 10px 14px; gap: 10px; }
  .lux-links a { padding: 7px 10px; font-size: 12.5px; }
  .lux-actions { gap: 7px; }
  .lux-brand-txt b { font-size: 15px; }
  .poster-frame { border-radius: 18px; }
  .vitem { flex-direction: column; align-items: flex-start; }
  .vthumb { width: 100%; }
  .vmeta .sbtn { align-self: flex-start; }
  .hub-wrap { padding-inline: 12px; }
  .flag-wrap { right: 8px; top: 58px; }
}

@media (max-width: 480px) {
  .lux-panel { padding: 26px 18px; }
  .lux-panel-info { padding: 26px 16px; }
  .lux-btn { padding: 9px 14px; font-size: 13px; }
  .lux-icon-btn { width: 38px; height: 38px; }
  .back-btn { min-width: 0; padding: 0 12px; font-size: 13.5px; height: 42px; }
  .hub-titles .section-title { font-size: 18px; }
  .scard .simg { aspect-ratio: 16/11; }
  .slot .sbtn { align-self: flex-end; }
  .lec-hero { align-items: flex-start; }
  .lh-ava { width: 56px; height: 56px; }
  .lh-ava span { font-size: 26px; }
  .content-sec h3 { font-size: 16.5px; }
  .fitm .fic { font-size: 18px; }
  .fitm .btn { font-size: 12px; padding: 8px 10px; }
  .p-controls { gap: 6px; padding: 8px; }
  .p-seek { min-width: 40px; }
  .p-btn { width: 34px; height: 34px; font-size: 12.5px; }
  .vplayer audio { width: 100%; }
  .qw-panel { width: 224px; }
}

@media (max-width: 360px) {
  .lux-logo { width: 38px; height: 38px; }
  .lux-brand { gap: 8px; }
  .lux-input, .lux-code-row input { padding: 12px 13px; font-size: 15px; }
  .lux-panel { padding: 24px 14px; }
  .scard .sbody { padding: 11px 12px 13px; }
  .sbtn { padding: 9px 15px; font-size: 13px; }
  .slot .sic { width: 42px; height: 42px; }
  .poster-frame .pf-empty { font-size: 34px; }
  .flag-egypt { width: 60px; height: 40px; }
}