/* ==================== CSS VARIABLES ==================== */
:root {
    /* Light Theme */
    --bg-primary: #f0f7ff;
    --bg-secondary: #ffffff;
    --bg-card: #ffffff;
    --text-primary: #1a1a2e;
    --text-secondary: #555580;
    --accent-primary: #1a73e8;
    --accent-secondary: #4fc3f7;
    --accent-gradient: linear-gradient(135deg, #1a73e8, #4fc3f7);
    --baby-blue: #89CFF0;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.3);
    --shadow-sm: 0 2px 10px rgba(0,0,0,0.08);
    --shadow-md: 0 8px 30px rgba(0,0,0,0.12);
    --shadow-lg: 0 20px 60px rgba(0,0,0,0.15);
    --shadow-glow: 0 0 30px rgba(26, 115, 232, 0.3);
    --border-radius: 16px;
    --border-radius-sm: 10px;
    --border-radius-lg: 24px;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --font-ar: 'Cairo', sans-serif;
    --font-en: 'Poppins', sans-serif;
}

[data-theme="dark"] {
    --bg-primary: #0a0a1a;
    --bg-secondary: #141428;
    --bg-card: #1a1a35;
    --text-primary: #e8e8f0;
    --text-secondary: #a0a0c0;
    --glass-bg: rgba(20, 20, 40, 0.8);
    --glass-border: rgba(255, 255, 255, 0.1);
    --shadow-sm: 0 2px 10px rgba(0,0,0,0.3);
    --shadow-md: 0 8px 30px rgba(0,0,0,0.4);
    --shadow-lg: 0 20px 60px rgba(0,0,0,0.5);
}

/* ==================== RESET & BASE ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-ar);
    background: var(--bg-primary);
    color: var(--text-primary);
    font-weight: 700;
    overflow-x: hidden;
    transition: var(--transition);
    line-height: 1.8;
}

[dir="ltr"] body {
    font-family: var(--font-en);
}

.hidden {
    display: none !important;
}

/* ==================== LOADING SCREEN ==================== */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0a0a2e 0%, #1a1a4e 30%, #0a0a2e 60%, #1a1a3e 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    overflow: hidden;
}

.loading-container {
    text-align: center;
    position: relative;
    z-index: 2;
}

.logo-3d-wrapper {
    perspective: 1000px;
    width: 200px;
    height: 200px;
    margin: 0 auto 40px;
}

.logo-3d {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    animation: logo3dRotate 4s ease-in-out infinite;
}

@keyframes logo3dRotate {
    0%, 100% { transform: rotateY(0deg) rotateX(0deg) scale(1); }
    25% { transform: rotateY(90deg) rotateX(10deg) scale(1.1); }
    50% { transform: rotateY(180deg) rotateX(0deg) scale(1); }
    75% { transform: rotateY(270deg) rotateX(-10deg) scale(1.1); }
}

.logo-face {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    backface-visibility: visible;
    border-radius: 20px;
}

.logo-face.front {
    transform: translateZ(50px);
}

.logo-face.back {
    transform: rotateY(180deg) translateZ(50px);
    background: rgba(26, 115, 232, 0.1);
    border: 2px solid rgba(79, 195, 247, 0.3);
    border-radius: 20px;
}

.logo-face.left {
    transform: rotateY(-90deg) translateZ(100px);
    width: 100px;
    left: 50px;
    background: rgba(26, 115, 232, 0.05);
}

.logo-face.right {
    transform: rotateY(90deg) translateZ(100px);
    width: 100px;
    left: 50px;
    background: rgba(79, 195, 247, 0.05);
}

.logo-svg {
    width: 160px;
    height: 160px;
    filter: drop-shadow(0 0 20px rgba(26, 115, 232, 0.5));
}

.logo-back-content {
    font-size: 80px;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

.loading-text h1 {
    font-size: 3rem;
    font-weight: 900;
    background: linear-gradient(135deg, #4fc3f7, #1a73e8, #4fc3f7);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 3s ease-in-out infinite;
    margin-bottom: 10px;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.glitch-text {
    position: relative;
}

.glitch-text::before,
.glitch-text::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
}

.glitch-text::before {
    animation: glitch1 2s infinite;
    clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
    -webkit-text-fill-color: #ff006e;
    opacity: 0.3;
}

.glitch-text::after {
    animation: glitch2 2s infinite;
    clip-path: polygon(0 55%, 100% 55%, 100% 100%, 0 100%);
    -webkit-text-fill-color: #00f5ff;
    opacity: 0.3;
}

@keyframes glitch1 {
    0%, 100% { transform: translate(0); }
    20% { transform: translate(-3px, 3px); }
    40% { transform: translate(3px, -3px); }
    60% { transform: translate(-3px, -3px); }
    80% { transform: translate(3px, 3px); }
}

@keyframes glitch2 {
    0%, 100% { transform: translate(0); }
    20% { transform: translate(3px, -3px); }
    40% { transform: translate(-3px, 3px); }
    60% { transform: translate(3px, 3px); }
    80% { transform: translate(-3px, -3px); }
}

.loading-subtitle {
    color: var(--baby-blue);
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.8;
}

.loading-bar-container {
    width: 300px;
    margin: 0 auto;
}

.loading-bar {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 10px;
}

.loading-bar-fill {
    width: 0%;
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 10px;
    transition: width 0.3s ease;
    box-shadow: 0 0 20px rgba(26, 115, 232, 0.5);
}

.loading-percent {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* Loading Particles */
.loading-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--baby-blue);
    border-radius: 50%;
    opacity: 0;
    animation: particleFloat 4s ease-in-out infinite;
}

@keyframes particleFloat {
    0% { opacity: 0; transform: translateY(100vh) scale(0); }
    50% { opacity: 1; }
    100% { opacity: 0; transform: translateY(-100px) scale(1); }
}

/* ==================== TOP BAR ==================== */
.top-bar {
    background: var(--accent-gradient);
    color: white;
    padding: 8px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.top-bar-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.btn-icon {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    font-size: 0.9rem;
}

.btn-icon:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: scale(1.1);
}

.btn-icon span {
    font-size: 0.7rem;
    margin-right: 2px;
    font-weight: 700;
}

.currency-selector select {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 5px 10px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
    font-family: inherit;
}

.currency-selector select option {
    background: var(--bg-card);
    color: var(--text-primary);
}

/* ==================== NAVBAR ==================== */
.navbar {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    padding: 15px 30px;
    position: sticky;
    top: 52px;
    z-index: 999;
    transition: var(--transition);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: 900;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 5px;
    align-items: center;
}

.nav-link {
    color: var(--text-primary);
    text-decoration: none;
    padding: 8px 16px;
    border-radius: var(--border-radius-sm);
    font-weight: 700;
    font-size: 0.9rem;
    transition: var(--transition);
    white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
    background: var(--accent-gradient);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    border-radius: 3px;
    transition: var(--transition);
}

/* ==================== VIDEO BACKGROUND ==================== */
.video-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-primary);
    opacity: 0.92;
    z-index: 1;
}

#bgCanvas {
    width: 100%;
    height: 100%;
}

/* ==================== HERO SECTION ==================== */
.hero-section {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 30px;
    position: relative;
}

.hero-content {
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-block;
    background: var(--accent-gradient);
    color: white;
    padding: 8px 24px;
    border-radius: 50px;
    font-size: 0.9rem;
    margin-bottom: 20px;
    animation: bounceIn 0.8s ease;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1.3;
    margin-bottom: 20px;
}

.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-size: 4rem;
}

.hero-desc {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

.stat-card {
    padding: 20px;
    text-align: center;
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-10px) rotateX(5deg);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 900;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: block;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.hero-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ==================== GLASS CARD ==================== */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    overflow: hidden;
}

.glass-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
}

/* ==================== BUTTONS ==================== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border: none;
    border-radius: var(--border-radius-sm);
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    font-family: inherit;
    white-space: nowrap;
}

.btn-primary {
    background: var(--accent-gradient);
    color: white;
    box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 40px rgba(26, 115, 232, 0.4);
}

.btn-whatsapp {
    background: #25D366;
    color: white;
}

.btn-whatsapp:hover {
    background: #128C7E;
    transform: translateY(-3px) scale(1.05);
}

.btn-ghost {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--glass-border);
}

.btn-ghost:hover {
    background: var(--accent-gradient);
    color: white;
    border-color: transparent;
}

.btn-lg {
    padding: 16px 36px;
    font-size: 1.1rem;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.85rem;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

.btn-danger {
    background: #e74c3c;
    color: white;
}

.btn-success {
    background: #27ae60;
    color: white;
}

/* ==================== SECTIONS ==================== */
.page {
    display: none;
    min-height: 60vh;
}

.page.active {
    display: block;
    animation: fadeInUp 0.6s ease;
}

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

@keyframes bounceIn {
    0% { transform: scale(0.3); opacity: 0; }
    50% { transform: scale(1.05); }
    70% { transform: scale(0.9); }
    100% { transform: scale(1); opacity: 1; }
}

.section-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 60px 30px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 900;
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--accent-gradient);
    margin: 15px auto 0;
    border-radius: 4px;
}

/* ==================== FEATURES GRID ==================== */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.feature-card {
    padding: 35px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(26, 115, 232, 0.1), transparent);
    transition: 0.5s;
}

.feature-card:hover::before {
    left: 100%;
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 15px;
    display: block;
}

.feature-card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ==================== SUBJECTS GRID ==================== */
.subjects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.subject-card {
    padding: 40px;
    text-align: center;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
    perspective: 1000px;
}

.subject-card:hover {
    transform: translateY(-15px) rotateX(5deg) rotateY(-5deg);
    box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.subject-card .subject-emoji {
    font-size: 5rem;
    display: block;
    margin-bottom: 20px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(5deg); }
}

.subject-card h3 {
    font-size: 2rem;
    margin-bottom: 10px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subject-card p {
    color: var(--text-secondary);
}

.subject-card .subject-badge {
    display: inline-block;
    background: var(--accent-gradient);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    margin-top: 15px;
}

/* ==================== COURSES GRID ==================== */
.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
}

.course-card {
    padding: 0;
    overflow: hidden;
    cursor: pointer;
    transition: var(--transition);
    transform-style: preserve-3d;
}

.course-card:hover {
    transform: translateY(-10px) rotateY(3deg);
}

.course-card-header {
    background: var(--accent-gradient);
    padding: 25px;
    color: white;
    position: relative;
    overflow: hidden;
}

.course-card-header::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 0;
    width: 100%;
    height: 40px;
    background: var(--bg-card);
    border-radius: 50% 50% 0 0;
}

.course-card-header h3 {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.course-card-header .course-type {
    font-size: 0.9rem;
    opacity: 0.9;
}

.course-card-body {
    padding: 30px 25px;
    background: var(--bg-card);
}

.course-info-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    font-size: 0.95rem;
}

.course-info-item i {
    color: var(--accent-primary);
    width: 20px;
}

.course-price {
    font-size: 2rem;
    font-weight: 900;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: block;
    margin: 15px 0;
}

.course-price-old {
    text-decoration: line-through;
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-left: 10px;
}

.course-card-footer {
    padding: 0 25px 25px;
    background: var(--bg-card);
}

/* ==================== OFFERS ==================== */
.offers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.offer-card {
    position: relative;
    overflow: hidden;
    padding: 0;
}

.offer-badge {
    position: absolute;
    top: 20px;
    right: -30px;
    background: #e74c3c;
    color: white;
    padding: 5px 40px;
    transform: rotate(45deg);
    font-size: 0.8rem;
    font-weight: 900;
    z-index: 2;
}

.offer-card .course-card-header {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

/* ==================== TEACHERS ==================== */
.teachers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.teacher-card {
    text-align: center;
    padding: 35px;
}

.teacher-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    margin: 0 auto 15px;
    box-shadow: var(--shadow-glow);
}

.teacher-card h3 {
    font-size: 1.3rem;
    margin-bottom: 5px;
}

.teacher-card .teacher-subject {
    color: var(--accent-primary);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.teacher-card .teacher-desc {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* ==================== REVIEWS ==================== */
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.review-card {
    padding: 30px;
}

.review-stars {
    color: #f1c40f;
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.review-text {
    font-style: italic;
    color: var(--text-secondary);
    margin-bottom: 15px;
    position: relative;
    padding-right: 20px;
}

.review-text::before {
    content: '"';
    font-size: 3rem;
    color: var(--accent-primary);
    position: absolute;
    top: -10px;
    right: 0;
    opacity: 0.3;
}

.review-author {
    font-weight: 900;
    font-size: 0.95rem;
}

/* ==================== FAQ ==================== */
.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    margin-bottom: 15px;
    border-radius: var(--border-radius-sm);
    overflow: hidden;
}

.faq-question {
    width: 100%;
    background: var(--bg-card);
    border: 1px solid var(--glass-border);
    padding: 20px 25px;
    text-align: right;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
    font-family: inherit;
    color: var(--text-primary);
    border-radius: var(--border-radius-sm);
}

[dir="ltr"] .faq-question {
    text-align: left;
}

.faq-question:hover {
    background: var(--accent-gradient);
    color: white;
}

.faq-question .faq-icon {
    transition: var(--transition);
    font-size: 1.2rem;
}

.faq-question.active .faq-icon {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    background: var(--bg-card);
    transition: max-height 0.4s ease;
}

.faq-answer.active {
    max-height: 300px;
}

.faq-answer-content {
    padding: 20px 25px;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* ==================== CONTACT ==================== */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-form-card,
.contact-info-card {
    padding: 35px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
    font-size: 0.95rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--glass-border);
    border-radius: var(--border-radius-sm);
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 700;
    font-family: inherit;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 15px rgba(26, 115, 232, 0.2);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.contact-info-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.contact-info-item i {
    font-size: 1.5rem;
    color: var(--accent-primary);
}

.contact-info-item a {
    color: var(--text-primary);
    text-decoration: none;
}

.social-links {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.social-link {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: var(--transition);
    font-size: 1.2rem;
}

.social-link:hover {
    transform: translateY(-5px) scale(1.1);
}

.social-link.facebook { background: #1877f2; }
.social-link.instagram { background: linear-gradient(135deg, #e1306c, #fd1d1d, #f77737); }
.social-link.tiktok { background: #000; }
.social-link.youtube { background: #ff0000; }
.social-link.telegram { background: #0088cc; }

/* ==================== AUTH ==================== */
.auth-container {
    max-width: 600px;
    margin: 40px auto;
}

.auth-card {
    padding: 40px;
}

.auth-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 30px;
    background: var(--bg-primary);
    border-radius: var(--border-radius-sm);
    padding: 5px;
}

.auth-tab {
    flex: 1;
    padding: 12px;
    border: none;
    background: transparent;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    border-radius: 8px;
    transition: var(--transition);
    font-family: inherit;
    color: var(--text-secondary);
}

.auth-tab.active {
    background: var(--accent-gradient);
    color: white;
}

.auth-form h2 {
    text-align: center;
    margin-bottom: 25px;
}

/* ==================== STUDENT DASHBOARD ==================== */
.dashboard-container {
    display: grid;
    grid-template-columns: 280px 1fr;
    min-height: calc(100vh - 120px);
}

.dashboard-sidebar {
    background: var(--bg-card);
    padding: 30px 20px;
    border-left: 1px solid var(--glass-border);
}

[dir="ltr"] .dashboard-sidebar {
    border-left: none;
    border-right: 1px solid var(--glass-border);
}

.student-avatar {
    text-align: center;
    margin-bottom: 30px;
}

.avatar-circle {
    width: 80px;
    height: 80px;
    background: var(--accent-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin: 0 auto 10px;
}

.dashboard-nav {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.dash-link {
    display: block;
    padding: 12px 16px;
    border-radius: var(--border-radius-sm);
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 700;
    transition: var(--transition);
}

.dash-link:hover,
.dash-link.active {
    background: var(--accent-gradient);
    color: white;
}

.dashboard-content {
    padding: 30px;
}

.dash-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.dash-stat-card {
    padding: 25px;
    text-align: center;
}

.dash-stat-card .dash-stat-icon {
    font-size: 2rem;
    margin-bottom: 10px;
}

.dash-stat-card .dash-stat-number {
    font-size: 2rem;
    font-weight: 900;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.dash-stat-card .dash-stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* ==================== ADMIN DASHBOARD ==================== */
.admin-container {
    display: grid;
    grid-template-columns: 260px 1fr;
    min-height: calc(100vh - 120px);
}

.admin-sidebar {
    background: #1a1a2e;
    color: white;
    padding: 25px 15px;
}

.admin-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.admin-avatar {
    font-size: 3rem;
    margin-bottom: 10px;
}

.admin-nav {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.admin-link {
    display: block;
    padding: 10px 15px;
    border-radius: 8px;
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    transition: var(--transition);
}

.admin-link:hover,
.admin-link.active {
    background: var(--accent-gradient);
    color: white;
}

.admin-content {
    padding: 30px;
    background: var(--bg-primary);
    overflow-y: auto;
}

.admin-section-title {
    font-size: 1.5rem;
    font-weight: 900;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Admin Tables */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-card);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.admin-table th {
    background: var(--accent-gradient);
    color: white;
    padding: 15px;
    text-align: right;
    font-weight: 700;
}

[dir="ltr"] .admin-table th {
    text-align: left;
}

.admin-table td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--glass-border);
}

.admin-table tr:hover {
    background: rgba(26, 115, 232, 0.05);
}

/* Admin Form */
.admin-form {
    background: var(--bg-card);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 25px;
}

.admin-form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

/* ==================== LESSON PAGE ==================== */
.lesson-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 30px;
}

.lesson-video {
    width: 100%;
    aspect-ratio: 16/9;
    background: #000;
    border-radius: var(--border-radius);
    margin-bottom: 25px;
    overflow: hidden;
}

.lesson-video iframe,
.lesson-video video {
    width: 100%;
    height: 100%;
    border: none;
}

.lesson-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 25px;
}

.lesson-materials {
    padding: 20px;
}

.lesson-material-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    border-radius: var(--border-radius-sm);
    background: var(--bg-primary);
    margin-bottom: 10px;
    cursor: pointer;
    transition: var(--transition);
}

.lesson-material-item:hover {
    background: var(--accent-gradient);
    color: white;
}

/* ==================== QUIZ PAGE ==================== */
.quiz-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 30px;
}

.quiz-header {
    text-align: center;
    margin-bottom: 30px;
}

.quiz-progress {
    width: 100%;
    height: 8px;
    background: var(--bg-primary);
    border-radius: 8px;
    margin-bottom: 30px;
    overflow: hidden;
}

.quiz-progress-fill {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 8px;
    transition: width 0.5s ease;
}

.quiz-question-card {
    padding: 30px;
    margin-bottom: 20px;
}

.quiz-question-card h3 {
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.quiz-option {
    display: block;
    padding: 15px 20px;
    border: 2px solid var(--glass-border);
    border-radius: var(--border-radius-sm);
    margin-bottom: 10px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 700;
}

.quiz-option:hover {
    border-color: var(--accent-primary);
    background: rgba(26, 115, 232, 0.05);
}

.quiz-option.selected {
    border-color: var(--accent-primary);
    background: rgba(26, 115, 232, 0.1);
}

.quiz-option.correct {
    border-color: #27ae60;
    background: rgba(39, 174, 96, 0.1);
}

.quiz-option.wrong {
    border-color: #e74c3c;
    background: rgba(231, 76, 60, 0.1);
}

.quiz-result {
    text-align: center;
    padding: 40px;
}

.quiz-score {
    font-size: 4rem;
    font-weight: 900;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ==================== BREADCRUMB ==================== */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.breadcrumb a {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 700;
}

.breadcrumb span {
    color: var(--text-secondary);
}

/* ==================== FOOTER ==================== */
.footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--glass-border);
    padding: 60px 30px 20px;
    margin-top: 60px;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.footer-col h4 {
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.footer-col a {
    display: block;
    color: var(--text-secondary);
    text-decoration: none;
    margin-bottom: 8px;
    transition: var(--transition);
}

.footer-col a:hover {
    color: var(--accent-primary);
    transform: translateX(5px);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid var(--glass-border);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.kordy-trigger {
    cursor: pointer;
    color: var(--text-secondary);
    user-select: none;
}

/* ==================== WHATSAPP FLOAT ==================== */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 60px;
    height: 60px;
    background: #25D366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    text-decoration: none;
    box-shadow: 0 5px 20px rgba(37, 211, 102, 0.4);
    z-index: 998;
    transition: var(--transition);
    animation: whatsappPulse 2s infinite;
}

[dir="ltr"] .whatsapp-float {
    left: auto;
    right: 30px;
}

@keyframes whatsappPulse {
    0%, 100% { box-shadow: 0 5px 20px rgba(37, 211, 102, 0.4); }
    50% { box-shadow: 0 5px 40px rgba(37, 211, 102, 0.6), 0 0 0 10px rgba(37, 211, 102, 0.1); }
}

.whatsapp-float:hover {
    transform: scale(1.15);
}

.whatsapp-tooltip {
    position: absolute;
    right: 70px;
    background: var(--bg-card);
    color: var(--text-primary);
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.85rem;
    white-space: nowrap;
    box-shadow: var(--shadow-sm);
    opacity: 0;
    transition: var(--transition);
    pointer-events: none;
}

[dir="ltr"] .whatsapp-tooltip {
    right: auto;
    left: 70px;
}

.whatsapp-float:hover .whatsapp-tooltip {
    opacity: 1;
}

/* ==================== SCROLL TO TOP ==================== */
.scroll-top {
    position: fixed;
    bottom: 100px;
    left: 30px;
    width: 45px;
    height: 45px;
    background: var(--accent-gradient);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    z-index: 998;
    transition: var(--transition);
    box-shadow: var(--shadow-glow);
}

[dir="ltr"] .scroll-top {
    left: auto;
    right: 30px;
}

.scroll-top.visible {
    display: flex;
}

.scroll-top:hover {
    transform: translateY(-5px) scale(1.1);
}

/* ==================== MODAL ==================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    position: relative;
    z-index: 2;
    width: 90%;
    max-width: 450px;
    padding: 35px;
    animation: bounceIn 0.5s ease;
}

.modal-content h2 {
    text-align: center;
    margin-bottom: 25px;
}

/* ==================== TOAST ==================== */
.toast-container {
    position: fixed;
    top: 80px;
    right: 30px;
    z-index: 10001;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

[dir="ltr"] .toast-container {
    right: auto;
    left: 30px;
}

.toast {
    padding: 15px 25px;
    border-radius: var(--border-radius-sm);
    color: white;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideInRight 0.5s ease;
    min-width: 300px;
    box-shadow: var(--shadow-md);
}

.toast-success { background: #27ae60; }
.toast-error { background: #e74c3c; }
.toast-info { background: var(--accent-primary); }
.toast-warning { background: #f39c12; }

@keyframes slideInRight {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* ==================== PROGRESS BAR ==================== */
.progress-bar {
    width: 100%;
    height: 10px;
    background: var(--bg-primary);
    border-radius: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 10px;
    transition: width 1s ease;
}

/* ==================== ANIMATIONS ==================== */
.animate-in {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards;
}

.animate-in:nth-child(1) { animation-delay: 0.1s; }
.animate-in:nth-child(2) { animation-delay: 0.2s; }
.animate-in:nth-child(3) { animation-delay: 0.3s; }
.animate-in:nth-child(4) { animation-delay: 0.4s; }

.animate-card {
    opacity: 0;
    transform: translateY(40px) rotateX(10deg);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-card.visible {
    opacity: 1;
    transform: translateY(0) rotateX(0deg);
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }

    .gradient-text {
        font-size: 2.5rem;
    }

    .hero-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--bg-card);
        flex-direction: column;
        padding: 20px;
        box-shadow: var(--shadow-md);
    }

    .nav-links.open {
        display: flex;
    }

    .hamburger {
        display: flex;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .dashboard-container,
    .admin-container {
        grid-template-columns: 1fr;
    }

    .dashboard-sidebar,
    .admin-sidebar {
        border-left: none;
        border-bottom: 1px solid var(--glass-border);
    }

    .dashboard-nav,
    .admin-nav {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .subjects-grid,
    .courses-grid,
    .offers-grid {
        grid-template-columns: 1fr;
    }

    .lesson-content {
        grid-template-columns: 1fr;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .whatsapp-float {
        bottom: 20px;
        left: 20px;
        width: 50px;
        height: 50px;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.5rem;
    }

    .gradient-text {
        font-size: 2rem;
    }

    .loading-text h1 {
        font-size: 2rem;
    }

    .top-bar {
        padding: 8px 15px;
        font-size: 0.75rem;
    }
}

/* ==================== LOCKED CONTENT ==================== */
.locked-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--border-radius);
    z-index: 5;
}

.locked-overlay i {
    font-size: 3rem;
    color: white;
}

.course-locked {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
}

/* ==================== CERTIFICATE ==================== */
.certificate-card {
    background: linear-gradient(135deg, #ffeaa7, #fdcb6e);
    padding: 40px;
    text-align: center;
    border: 3px solid #f39c12;
    position: relative;
}

.certificate-card::before {
    content: '🏆';
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2.5rem;
}

/* ==================== CUSTOM SCROLLBAR ==================== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--accent-gradient);
    border-radius: 8px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-primary);
}

/* ==================== STATUS BADGES ==================== */
.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
}

.badge-active { background: rgba(39, 174, 96, 0.1); color: #27ae60; }
.badge-inactive { background: rgba(231, 76, 60, 0.1); color: #e74c3c; }
.badge-pending { background: rgba(243, 156, 18, 0.1); color: #f39c12; }
/* =========================================================
   MATRIX ACADEMY — FINAL PUBLIC VISUAL SYSTEM
   One fixed palette: White / Baby Blue / Blue
   ========================================================= */
:root,
[data-theme="light"],
[data-theme="dark"] {
    --bg-primary: #f7fcff;
    --bg-secondary: #ffffff;
    --bg-card: #ffffff;
    --text-primary: #102a43;
    --text-secondary: #5d7185;
    --accent-primary: #1687e8;
    --accent-secondary: #7bd4ff;
    --accent-gradient: linear-gradient(135deg, #1687e8 0%, #5ec8f6 100%);
    --baby-blue: #dff5ff;
    --glass-bg: rgba(255,255,255,.96);
    --glass-border: #d7ebf7;
    --shadow-sm: 0 4px 16px rgba(28, 117, 170, .08);
    --shadow-md: 0 12px 32px rgba(28, 117, 170, .10);
    --shadow-lg: 0 20px 50px rgba(28, 117, 170, .14);
    --shadow-glow: 0 10px 28px rgba(22, 135, 232, .18);
    --border-radius: 18px;
    --border-radius-sm: 12px;
    --border-radius-lg: 26px;
    --transition: 180ms ease;
}

html, body { background: var(--bg-primary); color: var(--text-primary); }
body { font-weight: 500; line-height: 1.7; }
h1,h2,h3,h4,h5,h6,.nav-brand,.btn,.nav-link { font-weight: 700; }

/* Never expose the old theme control */
#themeToggle { display:none !important; }

/* Loading: supplied PNG only */
.loading-screen {
    background: linear-gradient(145deg, #ffffff 0%, #effaff 52%, #dff5ff 100%);
}
.loading-container { width: min(92vw, 430px); }
.logo-3d-wrapper, .logo-3d { display:none !important; }
.loading-logo-wrap {
    width: 190px;
    height: 190px;
    margin: 0 auto 22px;
    display:flex;
    align-items:center;
    justify-content:center;
}
.loading-logo-img {
    display:block;
    width: 180px;
    height: 180px;
    object-fit:contain;
    border-radius: 0;
}
.loading-text h1 {
    font-family: var(--font-en);
    font-size: clamp(2rem, 6vw, 3rem);
    font-weight: 800;
    color:#126fc4;
    background:none;
    -webkit-text-fill-color:initial;
    animation:none;
    margin-bottom:4px;
}
.loading-subtitle { color:#587187; font-size:1rem; font-weight:600; }
.loading-particles { display:none; }
.loading-bar-container { width:min(300px,80vw); margin:24px auto 0; }
.loading-bar { background:#dceff9; height:5px; border-radius:99px; overflow:hidden; }
.loading-bar-fill { background:var(--accent-gradient); height:100%; border-radius:99px; }
.loading-percent { color:#1687e8; font-weight:700; margin-top:8px; display:block; }

/* Header / navbar */
.top-bar { background:#eaf8ff; border-bottom:1px solid #d6edf9; color:#31546b; }
.navbar { background:#ffffff; border-bottom:1px solid #dceef8; box-shadow:0 4px 20px rgba(22,135,232,.06); }
.nav-container { min-height:76px; }
.nav-logo { gap:10px; cursor:pointer; }
.nav-logo-img { width:56px; height:56px; object-fit:contain; display:block; }
.nav-brand { color:#126fc4; font-family:var(--font-en); font-size:1.15rem; letter-spacing:-.02em; }
.nav-links { gap:6px; }
.nav-link {
    color:#355268;
    padding:11px 14px;
    border-radius:11px;
    display:inline-flex;
    align-items:center;
    gap:8px;
    font-size:.92rem;
    white-space:nowrap;
}
.nav-link i { color:#1687e8; font-size:.9rem; }
.nav-link:hover { color:#126fc4; background:#eef9ff; transform:none; }
.nav-link.active { background:linear-gradient(135deg,#2e9ff0,#6ed1fa); color:#fff; box-shadow:0 7px 18px rgba(22,135,232,.20); }
.nav-link.active i { color:#fff; }
.btn-icon { background:#edf8ff; color:#2c5873; border:1px solid #d7ebf7; }
.currency-selector select { background:#fff; color:#31546b; border:1px solid #d7ebf7; }

/* Fixed hero video — only on the home hero */
.hero-section {
    min-height: 680px;
    position:relative;
    overflow:hidden;
    isolation:isolate;
    display:flex;
    align-items:center;
    justify-content:center;
    padding:90px 30px 80px;
}
.hero-video { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; z-index:-2; }
.hero-video-overlay { position:absolute; inset:0; z-index:-1; background:linear-gradient(180deg,rgba(255,255,255,.82),rgba(247,252,255,.92)); }
/* Gemini-mark cleanup: soften any visible generated-video watermark without affecting the page UI. */
.hero-video { filter: blur(2.2px); transform: scale(1.025); }
.hero-video-overlay { background: linear-gradient(90deg, rgba(247,251,255,.26) 0%, rgba(247,251,255,.18) 48%, rgba(247,251,255,.12) 100%); }

.hero-content { max-width:980px; position:relative; z-index:2; }
.hero-badge { background:rgba(255,255,255,.92); color:#126fc4; border:1px solid #cdeaf8; box-shadow:0 8px 22px rgba(22,135,232,.10); animation:none; }
.hero-title { color:#12304a; font-size:clamp(2.2rem,5vw,4rem); margin-bottom:18px; }
.gradient-text { color:#1687e8; background:none; -webkit-text-fill-color:initial; font-size:inherit; }
.education-systems { display:flex; align-items:center; justify-content:center; gap:22px; margin:22px 0 24px; flex-wrap:wrap; }
.system-logo { width:132px; height:64px; background:#fff; border:1px solid #d9edf8; border-radius:12px; box-shadow:0 8px 20px rgba(22,135,232,.10); display:flex; align-items:center; justify-content:center; padding:7px 12px; }
.system-logo img { max-width:100%; max-height:100%; object-fit:contain; display:block; }
.hero-desc { color:#4f687c; font-size:1.1rem; }
.stat-card { background:rgba(255,255,255,.88); border:1px solid #d8edf8; box-shadow:0 8px 24px rgba(22,135,232,.08); }
.stat-card:hover { transform:translateY(-3px); }

/* Public cards */
.glass-card { background:rgba(255,255,255,.96); border:1px solid #d9edf8; box-shadow:var(--shadow-md); backdrop-filter:blur(8px); }
.glass-card:hover { transform:translateY(-3px); box-shadow:var(--shadow-lg); }
.btn { transition:transform 180ms ease, box-shadow 180ms ease, background 180ms ease; }
.btn-primary { background:var(--accent-gradient); box-shadow:0 8px 22px rgba(22,135,232,.18); }
.btn-primary:hover { transform:translateY(-2px); box-shadow:0 12px 26px rgba(22,135,232,.24); }
.btn-whatsapp:hover { transform:translateY(-2px); }
.page.active { animation:pageIn 280ms ease both; }
@keyframes pageIn { from{opacity:0;transform:translateY(10px)} to{opacity:1;transform:none} }

.section-title { color:#12304a; font-size:clamp(1.9rem,3vw,2.5rem); margin-bottom:36px; }
.section-title::after { width:56px; height:3px; background:#45b8f2; margin-top:10px; }
.feature-card { padding:30px 26px; }
.feature-card::before { display:none; }
.feature-icon { margin-bottom:18px; display:flex; justify-content:center; }
.feature-icon span {
    width:66px; height:66px; border-radius:50%;
    display:flex; align-items:center; justify-content:center;
    background:#e8f7ff; border:1px solid #c8eafa; color:#1687e8;
    box-shadow:0 7px 18px rgba(22,135,232,.10);
}
.feature-icon i { font-size:1.55rem; }
.feature-card h3 { color:#173a54; }
.feature-card p { color:#667d8f; }

/* Subject cards with real local visuals */
.subjects-grid { grid-template-columns:repeat(3,minmax(0,1fr)); gap:24px; }
.subject-card { padding:0; overflow:hidden; transform:none; }
.subject-card:hover { transform:translateY(-5px); box-shadow:0 18px 40px rgba(22,135,232,.14); }
.subject-image-wrap { height:205px; overflow:hidden; background:#eaf8ff; }
.subject-image { width:100%; height:100%; display:block; object-fit:cover; transition:transform 300ms ease; }
.subject-card:hover .subject-image { transform:scale(1.025); }
.subject-card-content { padding:26px 26px 30px; text-align:center; }
.subject-card h3 { color:#1687e8; background:none; -webkit-text-fill-color:initial; font-size:1.8rem; margin-bottom:8px; }
.subject-card p { color:#62788b; min-height:50px; }
.subject-badge { background:#eaf8ff !important; color:#1677d8 !important; border:1px solid #cbeafa; padding:8px 15px !important; margin-top:14px !important; font-weight:700; }
.subject-badge i { margin-inline-end:6px; }

/* Social icons: icon centered inside circle */
.social-links { display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.social-link { width:44px !important; height:44px !important; min-width:44px; border-radius:50% !important; display:flex !important; align-items:center !important; justify-content:center !important; padding:0 !important; margin:0 !important; color:#fff !important; font-size:1.08rem !important; line-height:1 !important; }
.social-link i { margin:0 !important; line-height:1 !important; }
.social-link:hover { transform:translateY(-2px) !important; }
.social-link.facebook { background:#1877f2 !important; }
.social-link.instagram { background:linear-gradient(135deg,#feda75,#d62976,#4f5bd5) !important; }
.social-link.tiktok { background:#111 !important; }
.social-link.youtube { background:#ff0033 !important; }
.social-link.telegram { background:#229ed9 !important; }

/* Footer */
.footer { background:#eef9ff; border-top:1px solid #d7edf8; padding:50px 30px 20px; }
.footer-col h4 { color:#12304a; }
.footer-col p,.footer-col a { color:#61798c; }
.footer-col a:hover { color:#1687e8; transform:none; }
.footer-bottom { border-top:1px solid #d5ebf7; color:#6b8191; }

/* Form / content consistency */
.form-group label { color:#34546b; }
.form-group input,.form-group select,.form-group textarea { background:#fff; color:#18364d; border-color:#d5eaf6; }

/* Remove all public emoji-like feature icon animation */
.subject-card .subject-emoji, .feature-card > .feature-icon:not(:has(span)) { display:none; }

@media (max-width: 1000px) {
    .subjects-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .nav-links { gap:2px; }
    .nav-link { padding:10px 9px; font-size:.84rem; }
}
@media (max-width: 760px) {
    .nav-brand { display:none; }
    .nav-logo-img { width:50px; height:50px; }
    .nav-links { background:#fff; border-top:1px solid #dceef8; }
    .hero-section { min-height:620px; padding:80px 18px 60px; }
    .hero-video-overlay { background:linear-gradient(180deg,rgba(255,255,255,.87),rgba(247,252,255,.96)); }
    .education-systems { gap:12px; }
    .system-logo { width:104px; height:55px; }
    .subjects-grid { grid-template-columns:1fr; }
    .subject-image-wrap { height:190px; }
    .hero-stats { grid-template-columns:repeat(2,1fr); }
}
/* Header uses the brand blue so the supplied white logo reads cleanly */
.navbar { background:#117fc9; border-bottom:1px solid #0d70b4; box-shadow:0 5px 18px rgba(15,102,163,.16); }
.nav-brand { color:#fff; }
.nav-link { color:#f5fbff; }
.nav-link i { color:#ccefff; }
.nav-link:hover { color:#fff; background:rgba(255,255,255,.12); }
.nav-link.active { background:#ffffff; color:#126fc4; box-shadow:0 7px 18px rgba(0,0,0,.10); }
.nav-link.active i { color:#1687e8; }
.hamburger span { background:#fff; }

/* ==================== FINAL FRONTEND FIX ==================== */
/* One fixed Matrix Academy palette — no public theme switching. */
#themeToggle, #themeIcon { display:none !important; }

/* Loading uses the supplied PNG only. Remove the old glitch/purple reflection completely. */
.loading-text h1, .loading-text .glitch-text { display:none !important; }
.glitch-text::before, .glitch-text::after { display:none !important; content:none !important; animation:none !important; }
.loading-logo-img { filter:none !important; box-shadow:none !important; text-shadow:none !important; }
.loading-screen, .loading-screen * { text-shadow:none !important; }
.loading-subtitle { color:#167fc9 !important; text-shadow:none !important; }
.loading-bar-fill { box-shadow:none !important; }

/* Keep all public controls clickable and visually clean. */
.btn, .nav-link, .btn-icon, .currency-selector select, .whatsapp-float, .scroll-top {
    -webkit-tap-highlight-color:transparent;
}

/* Advanced Student Control Center */
.student-control-row{
  padding:14px 0;
  border-bottom:1px solid var(--glass-border);
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:14px;
}
.student-control-row:last-child{border-bottom:0}
.student-control-row small{display:block;color:var(--text-secondary);margin-top:4px;font-size:.8rem}
.student-control-card{transition:transform .2s ease, box-shadow .2s ease}
.student-control-card:hover{transform:translateY(-2px)}
@media(max-width:700px){
  .student-control-row{align-items:stretch;flex-direction:column}
  .student-control-row .btn,.student-control-row .form-input{width:100%}
}

.social-link.whatsapp { background:#25D366 !important; }

/* ==================== MATRIX PREMIUM UI V7 ==================== */
:root {
    --bg-primary: #f6faff;
    --bg-secondary: #ffffff;
    --bg-card: #ffffff;
    --text-primary: #0d2a4a;
    --text-secondary: #60758c;
    --accent-primary: #145ea8;
    --accent-secondary: #73c9ee;
    --accent-gradient: linear-gradient(135deg, #0d3f73 0%, #1769ad 52%, #79d2f2 100%);
    --baby-blue: #bfeafb;
    --glass-bg: rgba(255,255,255,.88);
    --glass-border: rgba(20,94,168,.10);
    --shadow-sm: 0 8px 24px rgba(13,42,74,.06);
    --shadow-md: 0 16px 42px rgba(13,42,74,.09);
    --shadow-lg: 0 26px 70px rgba(13,42,74,.13);
    --shadow-glow: 0 14px 40px rgba(20,94,168,.15);
}
body { color: var(--text-primary); -webkit-text-fill-color: initial; background: radial-gradient(circle at 15% 0%, rgba(191,234,251,.38), transparent 28%), var(--bg-primary); }
.glass-card, .admin-form, .admin-table { border: 1px solid var(--glass-border); box-shadow: var(--shadow-sm); }
.btn { box-shadow: 0 7px 18px rgba(13,63,115,.08); }
.btn-primary { background: var(--accent-gradient); }
.btn-primary:hover { box-shadow: 0 12px 28px rgba(20,94,168,.18); transform: translateY(-1px); }
.admin-container { grid-template-columns: 285px minmax(0,1fr); gap: 0; }
.admin-sidebar { background: linear-gradient(180deg,#0b3158 0%,#0d477c 55%,#125d99 100%); padding: 32px 18px; box-shadow: 14px 0 40px rgba(13,63,115,.10); }
.admin-header { margin-bottom: 34px; padding: 0 8px 24px; }
.admin-nav { gap: 8px; }
.admin-link { padding: 12px 15px; border: 1px solid transparent; }
.admin-link:hover,.admin-link.active { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.13); }
.admin-content { padding: 42px clamp(22px,4vw,52px); }
.admin-section-title { margin-bottom: 8px; }
.student-control-card { padding: 26px !important; min-height: 190px; border-radius: 20px; }
.student-control-card > div { gap: 18px; }
.student-control-row { margin: 14px 0; padding: 18px; border: 1px solid rgba(20,94,168,.09); border-radius: 16px; background: linear-gradient(180deg,#fff,#f9fcff); box-shadow: 0 5px 18px rgba(13,42,74,.045); }
.student-control-row + .student-control-row { margin-top: 14px; }
.student-control-row small { display:block; margin-top:6px; color:var(--text-secondary); line-height:1.6; }
.admin-page-head { display:flex; justify-content:space-between; align-items:flex-end; gap:24px; margin-bottom:28px; }
.admin-eyebrow { display:inline-block; letter-spacing:.18em; font-size:.72rem; font-weight:900; color:var(--accent-primary); margin-bottom:6px; }
.admin-page-subtitle { color:var(--text-secondary); line-height:1.8; margin-top:6px; }
.ai-status-pill { padding:9px 14px; border-radius:999px; background:#edf9ff; color:#145ea8; font-weight:800; border:1px solid #c8edfc; white-space:nowrap; }
.ai-status-pill span { display:inline-block; width:8px; height:8px; border-radius:50%; background:#3bc48a; margin-inline-end:7px; }
.ai-generator-layout { display:grid; grid-template-columns:minmax(0,1.6fr) minmax(280px,.75fr); gap:22px; align-items:stretch; }
.ai-generator-card,.ai-how-card,.ai-bulk-card { padding:30px; border-radius:24px; }
.ai-card-title { display:flex; gap:16px; align-items:center; margin-bottom:26px; }
.ai-icon { width:54px; height:54px; border-radius:16px; display:grid; place-items:center; background:linear-gradient(135deg,#e4f7ff,#c5ecfb); color:#145ea8; font-size:1.25rem; }
.ai-card-title h3 { margin:0 0 4px; }
.ai-card-title p,.ai-how-card p,.ai-bulk-card p { color:var(--text-secondary); line-height:1.7; }
.ai-form-grid { gap:18px; }
.ai-source-box { display:flex; align-items:center; gap:13px; margin:22px 0; padding:15px 17px; border-radius:15px; background:#f3faff; border:1px solid #d7f0fb; color:#145ea8; }
.ai-source-box > div { min-width:0; flex:1; }
.ai-source-box strong,.ai-source-box small { display:block; }
.ai-source-box small { margin-top:4px; color:var(--text-secondary); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.ai-source-box em { font-style:normal; font-size:.78rem; font-weight:800; color:#3b9c77; white-space:nowrap; }
.ai-source-box.missing { background:#fff8f5; border-color:#f4d6c9; color:#b55d3b; }
.ai-generate-btn { width:100%; min-height:52px; }
.ai-generate-btn:disabled { opacity:.65; cursor:wait; transform:none; }
.ai-generate-status { min-height:24px; margin-top:13px; color:var(--text-secondary); font-size:.9rem; }
.ai-step { display:flex; gap:15px; align-items:flex-start; padding:17px 0; border-bottom:1px solid #edf2f7; }
.ai-step:last-child { border-bottom:0; }
.ai-step b { color:#1769ad; font-size:.8rem; min-width:28px; }
.ai-step span { line-height:1.7; }
.ai-bulk-card { margin-top:22px; display:flex; justify-content:space-between; align-items:center; gap:22px; }
@media (max-width: 900px) { .ai-generator-layout{grid-template-columns:1fr;} .admin-page-head,.ai-bulk-card{align-items:flex-start;flex-direction:column;} .admin-container{grid-template-columns:1fr;} .admin-sidebar{position:relative;} }
@media (max-width: 620px) { .admin-content{padding:24px 15px;} .ai-generator-card,.ai-how-card,.ai-bulk-card{padding:21px;} .student-control-row{padding:14px;} }


/* Lesson PDF URL / Upload control */
.lesson-pdf-control{display:flex;flex-direction:column;gap:7px;min-width:245px}.lesson-pdf-upload-row{display:flex;align-items:center;gap:7px;flex-wrap:wrap}.lesson-pdf-or{font-size:11px;color:var(--text-secondary);font-weight:700}.lesson-pdf-upload-btn{cursor:pointer;display:inline-flex;align-items:center;gap:6px}.lesson-pdf-hint{display:block;color:var(--text-secondary);font-size:10px;line-height:1.4}

/* V32 placement/pricing polish */
.course-price.assessment-price{font-size:1.35rem;line-height:1.25;letter-spacing:-.02em;background:linear-gradient(135deg,#1266d6,#20a4e8);-webkit-background-clip:text;background-clip:text;color:transparent}.course-price-note{color:var(--text-secondary);font-size:.82rem;line-height:1.55;margin-top:6px}.assessment-price-admin{display:inline-flex;padding:7px 11px;border-radius:999px;background:rgba(26,115,232,.08);color:#1266d6;font-weight:800;font-size:.8rem}.assessment-offer-pricing{display:flex;flex-direction:column;align-items:flex-start;gap:5px}.offer-assessment-note{font-size:.78rem;color:var(--text-secondary);line-height:1.45}.eyebrow{font-size:.72rem;letter-spacing:.16em;font-weight:900;color:#1687d9;display:block;margin-bottom:5px}.empty-state{text-align:center;padding:42px 20px;color:var(--text-secondary)}.empty-state-icon{font-size:2.6rem;margin-bottom:8px}.notifications-list{display:grid;gap:12px}.notification-card{display:flex;gap:12px;align-items:flex-start;padding:15px 16px;border-radius:16px;background:rgba(255,255,255,.84);border:1px solid rgba(20,119,185,.11);margin:8px 0}.notification-card p{margin:4px 0;color:var(--text-secondary);line-height:1.5}.notification-card small{color:#8795a5}.notification-dot{width:9px;height:9px;border-radius:50%;background:#1687d9;margin-top:7px;flex:0 0 auto}
