/* === TWINS' ENGLISH - DESIGN SYSTEM V3 === */
/* Glassmorphism + Glow Cards + Shimmer Buttons */

/* === CSS VARIABLES === */
:root {
    --bg: #FAFAFA;
    --bg-alt: #F0F0F0;
    --bg-card: #FFFFFF;
    --text: #1a1a1a;
    --text-light: #666666;
    --text-muted: #999999;
    --accent: #FF6B35;
    --accent-light: rgba(255, 107, 53, 0.1);
    --accent-gradient: linear-gradient(135deg, #FF6B35 0%, #F7931E 50%, #FFB347 100%);
    --accent-purple: #7C3AED;
    --accent-blue: #3B82F6;
    --accent-green: #22C55E;
    --accent-amber: #F59E0B;
    --border: #E5E5E5;
    --border-light: rgba(0, 0, 0, 0.06);
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-md: 0 8px 30px rgba(0,0,0,0.1);
    --shadow-lg: 0 20px 60px rgba(0,0,0,0.12);
    --shadow-accent: 0 15px 40px rgba(255, 107, 53, 0.2);
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-xl: 40px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --ease: cubic-bezier(.4,0,.2,1);
    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Outfit', sans-serif;
    --font: 'Space Grotesk', -apple-system, sans-serif;
    --glass-bg: rgba(255,255,255,0.55);
    --glass-border: rgba(255,255,255,0.5);
    --glass-shadow: 0 2px 16px rgba(0,0,0,0.03), inset 0 1px 0 rgba(255,255,255,0.6);
}

/* @property for conic gradient animations */
@property --angle {
    syntax: '<angle>';
    initial-value: 0deg;
    inherits: true;
}

@property --btn-angle {
    syntax: '<angle>';
    initial-value: 0deg;
    inherits: true;
}

/* Dark Theme */
[data-theme="dark"], .theme-dark {
    --bg: #0F0F0F;
    --bg-alt: #1A1A1A;
    --bg-card: #1F1F1F;
    --text: #FAFAFA;
    --text-light: #A0A0A0;
    --text-muted: #666666;
    --border: #2A2A2A;
    --border-light: rgba(255, 255, 255, 0.1);
    --shadow-sm: 0 2px 8px 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);
    --glass-bg: rgba(30,30,30,0.55);
    --glass-border: rgba(255,255,255,0.1);
}

/* === GLOBAL RESET === */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-width: 320px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

*:focus {
    outline: none !important;
}

/* === CANVAS MESH BACKGROUND === */
#mesh-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    width: 100%;
    height: 100%;
}

/* Subtle grain texture overlay */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: 0.025;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 256px 256px;
}

/* Content sits above canvas + grain */
.hero, .section, .section-wide, .counter-bar, .cta,
.dark-block, .story-section, .values-section,
.testimonials-section, .social-section, .includes-section,
.stats-bar, .teacher-promo {
    position: relative;
    z-index: 1;
}

/* Legacy blob shapes (kept for DashboardLayout compatibility) */
.bg-shapes, .bg-shapes-dashboard {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    animation: float 20s infinite ease-in-out;
}

.shape-1 {
    width: 600px; height: 600px;
    background: var(--accent);
    top: -200px; right: -200px;
}

.shape-2 {
    width: 400px; height: 400px;
    background: var(--accent-purple);
    bottom: 20%; left: -100px;
    animation-delay: -5s;
}

.shape-3 {
    width: 300px; height: 300px;
    background: var(--accent-blue);
    top: 50%; right: 10%;
    animation-delay: -10s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(30px, -30px) scale(1.05); }
    66% { transform: translate(-20px, 20px) scale(0.95); }
}

/* === TYPOGRAPHY === */
h1, h2, h3, h4, h5, h6,
.section-title,
.hero-title {
    font-family: var(--font-heading);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

/* Gradient Text */
.text-gradient {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

/* dotBlink removed */

/* === SECTION HEADERS === */
.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: transparent;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    margin-bottom: 1rem;
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.section-tag::before {
    content: '';
    width: 24px;
    height: 2px;
    background: var(--accent-gradient);
    border-radius: 2px;
}

.section-tag.visible {
    opacity: 1;
    transform: translateY(0);
}

/* For tags that should show immediately (no scroll reveal needed) */
.section-tag.no-reveal,
.dark-inner .section-tag,
.dark-block .section-tag {
    opacity: 1;
    transform: none;
    color: var(--accent);
    background: none;
    -webkit-background-clip: unset;
    -webkit-text-fill-color: unset;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    letter-spacing: -1px;
    line-height: 1.1;
    max-width: min(600px, 100%);
    margin-bottom: 2.5rem;
    color: var(--text);
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.6s var(--ease) 0.1s, transform 0.6s var(--ease) 0.1s;
}

/* Centre titles inside centred containers */
.values-header .section-title,
.testimonials-header .section-title,
.social-section .section-title,
.includes-section .section-title {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.section-title.visible {
    opacity: 1;
    transform: translateY(0);
}

/* For titles that should show immediately */
.section-title.no-reveal {
    opacity: 1;
    transform: none;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-light);
    max-width: min(600px, 100%);
}

/* === NAVIGATION === */
.navbar-twins {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(250, 250, 250, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-light);
    transition: var(--transition);
}

.navbar-twins.scrolled {
    padding: 0.75rem 2rem;
    box-shadow: var(--shadow-sm);
}

.navbar-logo {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    color: var(--text);
    text-decoration: none;
}

/* === BUTTONS — Legacy === */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--text);
    color: white;
    padding: 1rem 2rem;
    border-radius: 100px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.btn-primary svg { transition: transform 0.3s; }
.btn-primary:hover svg { transform: translateX(5px); }

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text);
    padding: 1rem 1.5rem;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    background: transparent;
    cursor: pointer;
    transition: var(--transition);
}

.btn-secondary:hover { color: var(--accent); }

.btn-accent {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--accent-gradient);
    color: white;
    padding: 1rem 2rem;
    border-radius: 100px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-accent:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-accent);
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    color: var(--text);
    padding: 1rem 2rem;
    border-radius: 100px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    border: 2px solid var(--border);
    cursor: pointer;
    transition: var(--transition);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-2px);
}

/* === SHIMMER BUTTON === */
.btn-shimmer {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.9rem 2rem;
    border-radius: 100px;
    font-family: var(--font);
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    border: none;
    cursor: pointer;
    position: relative;
    z-index: 0;
    background: transparent;
    color: #fff;
    transition: transform 0.3s var(--ease), box-shadow 0.3s;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

/* Rotating conic shimmer border */
.btn-shimmer::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 100px;
    padding: 3px;
    background: conic-gradient(
        from var(--btn-angle, 0deg),
        transparent 0%,
        rgba(255,255,255,0.7) 5%,
        transparent 10%,
        transparent 45%,
        rgba(255,107,53,0.8) 50%,
        rgba(255,179,71,0.5) 55%,
        transparent 60%
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    z-index: -2;
}

/* Dark inner background */
.btn-shimmer::after {
    content: '';
    position: absolute;
    inset: 3px;
    border-radius: 100px;
    background: var(--text);
    transition: background 0.3s;
    z-index: -1;
}

.btn-shimmer:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(255,107,53,0.3), 0 0 20px rgba(255,107,53,0.15);
}

.btn-shimmer:hover::after {
    background: linear-gradient(135deg, #1a1a1a, #2d2d2d);
}

.btn-shimmer .shimmer-highlight {
    position: absolute;
    inset: 3px;
    border-radius: 100px;
    box-shadow: inset 0 -8px 12px rgba(255,255,255,0.08);
    pointer-events: none;
    transition: box-shadow 0.3s;
    z-index: 1;
}

.btn-shimmer:hover .shimmer-highlight {
    box-shadow: inset 0 -6px 12px rgba(255,255,255,0.15);
}

/* Light variant (for dark backgrounds) */
.btn-shimmer-light { color: var(--text); }
.btn-shimmer-light::after { background: #fff; }
.btn-shimmer-light:hover::after { background: linear-gradient(135deg, #fff, #f5f5f5); }
.btn-shimmer-light:hover {
    box-shadow: 0 8px 32px rgba(255,255,255,0.25), 0 0 20px rgba(255,107,53,0.15);
}
.btn-shimmer-light .shimmer-highlight {
    box-shadow: inset 0 -8px 12px rgba(0,0,0,0.03);
}

.btn-shimmer span, .btn-shimmer svg { position: relative; z-index: 2; }
.btn-shimmer svg { transition: transform 0.3s; }
.btn-shimmer:hover svg { transform: translateX(4px); }

/* === GHOST BUTTON === */
.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.9rem 2rem;
    border-radius: 100px;
    font-family: var(--font);
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    border: 1px solid rgba(0,0,0,0.06);
    cursor: pointer;
    transition: all 0.3s var(--ease);
    background: rgba(255,255,255,0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: var(--text);
}

.btn-ghost:hover {
    background: rgba(255,255,255,0.9);
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}

/* Form submit button */
.btn-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 1rem 2rem;
    background: var(--text);
    color: white;
    border: none;
    border-radius: 12px;
    font-family: var(--font);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s var(--ease);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

/* === HERO SECTION === */
.hero {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 10rem 0;
    z-index: 1;
}

.hero-content {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 2rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
}

/* Trust badge */
.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255,255,255,0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 0.55rem 1.2rem;
    border-radius: 100px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-light);
    border: 1px solid rgba(0,0,0,0.05);
    box-shadow: 0 2px 16px rgba(0,0,0,0.04);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.6s var(--ease) forwards;
}

.trust-dot {
    width: 8px;
    height: 8px;
    background: #22C55E;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

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

.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(3rem, 9vw, 7rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -2px;
    margin: 2rem 0 1.5rem;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 0.7s var(--ease) 0.1s forwards;
}

.hero-title .line { display: block; }

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-light);
    max-width: 520px;
    line-height: 1.65;
    margin-bottom: 3rem;
    text-align: center;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.6s var(--ease) 0.2s forwards;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.6s var(--ease) 0.3s forwards;
}

/* Scroll indicator */
.scroll-hint {
    position: absolute;
    bottom: 2.5rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    opacity: 0;
    animation: fadeUp 0.6s var(--ease) 1s forwards;
}

.scroll-hint span {
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-light);
}

.scroll-mouse {
    width: 24px; height: 38px;
    border: 2px solid var(--text-light);
    border-radius: 12px;
    position: relative;
}

.scroll-mouse::after {
    content: '';
    width: 3px; height: 8px;
    background: var(--accent);
    border-radius: 2px;
    position: absolute;
    top: 6px; left: 50%;
    transform: translateX(-50%);
    animation: scrollDown 1.5s ease-in-out infinite;
}

@keyframes scrollDown {
    0% { top: 6px; opacity: 1; }
    100% { top: 20px; opacity: 0; }
}

/* Hero — short variant (about, contact) */
.hero-short {
    min-height: 80vh;
    padding: 10rem 0 6rem;
}

.hero-contact {
    min-height: 50vh;
    padding: 8rem 0 4rem;
}

/* === COUNTER BAR === */
.counter-bar {
    display: flex;
    justify-content: center;
    gap: 4rem;
    padding: 2.5rem 3rem;
    max-width: min(600px, calc(100vw - 2rem));
    margin: -6rem auto 0;
    position: relative;
    z-index: 3;
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 0.6s var(--ease) 0.5s forwards;
    overflow: hidden;
    transition: box-shadow 0.35s, border-color 0.35s, background 0.35s;
}

/* Conic glow border on hover */
.counter-bar::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 1.5px;
    background: conic-gradient(
        from var(--angle, 0deg),
        transparent 0%,
        rgba(255,107,53,0.45) 10%,
        transparent 20%
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.5s;
    pointer-events: none;
    z-index: 0;
}

.counter-bar:hover::before { opacity: 1; }
.counter-bar:hover {
    border-color: rgba(255,107,53,0.15);
    background: rgba(255,255,255,0.7);
    box-shadow: 0 24px 60px rgba(255,107,53,0.10), inset 0 1px 0 rgba(255,255,255,0.8);
}

.counter-item { position: relative; z-index: 1; text-align: center; }

.counter-value {
    font-size: 2.8rem;
    font-weight: 700;
    letter-spacing: -1px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.counter-label {
    font-size: 0.9rem;
    color: var(--text-light);
    font-weight: 500;
}

/* === SECTIONS === */
.section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 5rem 2rem;
    position: relative;
    z-index: 1;
}

.section-twins {
    padding: 6rem 2rem;
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
}

.section-header {
    margin-bottom: 4rem;
}

/* === GLOW CARDS === */
.card-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
}

.glow-card {
    position: relative;
    border-radius: 16px;
    background: white;
    overflow: hidden;
    cursor: default;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease), box-shadow 0.35s var(--ease);
}

.glow-card.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Animated conic border */
.glow-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    padding: 1.5px;
    background: conic-gradient(
        from var(--angle, 0deg),
        transparent 0%,
        rgba(255,107,53,0.45) 10%,
        transparent 20%
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.5s;
    pointer-events: none;
    z-index: 0;
}

.glow-card:hover::before { opacity: 1; }

.glow-card:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 24px 60px rgba(255,107,53,0.10), 0 0 0 1px rgba(255,107,53,0.06);
}

.card-inner {
    position: relative;
    z-index: 1;
    padding: 2rem;
    border: 1px solid rgba(255,255,255,0.5);
    border-radius: 16px;
    height: 100%;
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: var(--glass-shadow);
    transition: border-color 0.35s, background 0.35s, box-shadow 0.35s;
}

.glow-card:hover .card-inner {
    border-color: rgba(255,107,53,0.15);
    background: rgba(255,255,255,0.7);
    box-shadow: 0 4px 24px rgba(0,0,0,0.04), inset 0 1px 0 rgba(255,255,255,0.8);
}

/* Glow overlay that tracks cursor */
.glow-card .glow-overlay {
    position: absolute;
    inset: 0;
    border-radius: 16px;
    background: radial-gradient(
        400px circle at var(--mx, 50%) var(--my, 50%),
        rgba(255,107,53,0.10), transparent 40%
    );
    opacity: 0;
    transition: opacity 0.4s;
    pointer-events: none;
    z-index: 3;
}

.glow-card:hover .glow-overlay { opacity: 1; }

.card-icon {
    width: 52px; height: 52px;
    border-radius: 14px;
    background: linear-gradient(135deg, #FFF4ED, #FFE4D4);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
    color: #FF6B35;
    transition: transform 0.3s var(--ease);
}

.glow-card:hover .card-icon {
    transform: scale(1.08) rotate(-3deg);
}

.card-inner h3 {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    letter-spacing: -0.3px;
}

.card-inner p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Feature card decorative background icon */
.feature-card .card-inner { overflow: hidden; }

.feature-bg-icon {
    position: absolute;
    top: -10px; right: -10px;
    opacity: 0.04;
    color: rgba(var(--card-accent, 255,107,53), 1);
    transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
    pointer-events: none;
    z-index: 0;
}

.feature-card:hover .feature-bg-icon {
    opacity: 0.09;
    transform: scale(1.15) rotate(8deg);
}

.feature-card .card-inner::after {
    content: '';
    position: absolute;
    bottom: -30px; left: -30px;
    width: 120px; height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(var(--card-accent, 255,107,53), 0.06), transparent 70%);
    pointer-events: none;
    transition: transform 0.5s var(--ease), opacity 0.5s;
    z-index: 0;
}

.feature-card:hover .card-inner::after {
    transform: scale(1.8);
    opacity: 0.8;
}

.feature-card .card-icon,
.feature-card h3,
.feature-card p { position: relative; z-index: 1; }

/* === ADVANTAGES — numbered rows === */
.advantages-list {
    display: flex;
    flex-direction: column;
}

.advantage-row {
    display: flex;
    align-items: flex-start;
    gap: 2.5rem;
    padding: 2.2rem 2rem;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    opacity: 0;
    transform: translateX(-30px);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease),
                background 0.3s, border-radius 0.3s;
    border-radius: 16px;
    cursor: default;
}

.advantage-row:first-child { border-top: 1px solid rgba(0,0,0,0.06); }
.advantage-row.visible { opacity: 1; transform: translateX(0); }
.advantage-row:hover { background: rgba(255,255,255,0.25); }

.advantage-num {
    font-size: 3.2rem;
    font-weight: 700;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    flex-shrink: 0;
    min-width: 64px;
}

.advantage-body h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.4rem;
    letter-spacing: -0.3px;
}

.advantage-body p {
    color: var(--text-light);
    line-height: 1.65;
    font-size: 0.95rem;
    max-width: 520px;
}

/* === COURSE CARDS (new prototype style) === */
.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.25rem;
}

.course-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 16px;
    padding: 2rem;
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    text-decoration: none;
    color: inherit;
    display: block;
    position: relative;
    overflow: hidden;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease),
                box-shadow 0.35s, border-color 0.35s, background 0.35s;
}

.course-card.visible { opacity: 1; transform: translateY(0); }

/* Conic border on hover */
.course-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    padding: 1.5px;
    background: conic-gradient(
        from var(--angle, 0deg),
        transparent 0%,
        rgba(255,107,53,0.45) 10%,
        transparent 20%
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.5s;
    pointer-events: none;
    z-index: 0;
}

.course-card:hover::before { opacity: 1; }

.course-card:hover {
    transform: translateY(-6px) !important;
    border-color: rgba(255,107,53,0.15);
    background: rgba(255,255,255,0.7);
    box-shadow: 0 24px 60px rgba(255,107,53,0.10), inset 0 1px 0 rgba(255,255,255,0.8);
}

.course-card > * { position: relative; z-index: 1; }

.course-emoji { font-size: 2.8rem; margin-bottom: 1rem; display: block; }

.course-card h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    letter-spacing: -0.3px;
}

.course-card > p {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.course-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
    margin-bottom: 0.8rem;
}

.course-level {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent);
    background: rgba(255,107,53,0.1);
    padding: 0.3rem 0.7rem;
    border-radius: 100px;
}

.course-price { font-size: 1.1rem; font-weight: 700; }

.course-link {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent);
    transition: transform 0.3s;
    display: inline-block;
}

.course-card:hover .course-link { transform: translateX(4px); }

/* Legacy course cards */
.course-card-twins {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    transition: var(--transition);
    position: relative;
    border: 2px solid transparent;
}

.course-card-twins:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: var(--accent);
    box-shadow: var(--shadow-accent);
}

/* === TIMELINE === */
.timeline {
    position: relative;
    display: flex;
    flex-direction: column;
    padding-left: 56px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 19px;
    top: calc(2rem + 20px);
    bottom: calc(2rem + 20px);
    width: 2px;
    background: linear-gradient(to bottom, var(--accent), rgba(0,0,0,0.08));
    border-radius: 2px;
}

.timeline-step {
    display: flex;
    align-items: flex-start;
    gap: 2rem;
    padding: 2rem 0;
    position: relative;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.timeline-step.visible { opacity: 1; transform: translateY(0); }

.timeline-dot {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    position: absolute;
    left: -56px;
    top: 2rem;
    z-index: 1;
    box-shadow: 0 0 0 6px #ECECEC, 0 4px 12px rgba(255,107,53,0.2);
    transition: box-shadow 0.3s, transform 0.3s;
}

.timeline-step:hover .timeline-dot {
    transform: scale(1.15);
    box-shadow: 0 0 0 6px #E0E0E0, 0 6px 20px rgba(255,107,53,0.3);
}

.timeline-dot span { color: white; font-weight: 700; font-size: 1.05rem; }

.timeline-content h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.4rem;
    letter-spacing: -0.3px;
}

.timeline-content p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.65;
    max-width: 440px;
}

/* === TESTIMONIALS === */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: start;
}

.testimonial-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 20px;
    padding: 2.5rem 2rem 2rem;
    position: relative;
    border: 1px solid rgba(0,0,0,0.04);
    box-shadow: 0 2px 16px rgba(0,0,0,0.03);
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease),
                box-shadow 0.35s, border-color 0.35s;
    overflow: hidden;
}

.testimonial-card.visible { opacity: 1; transform: translateY(0); }

.testimonial-card.featured {
    border-color: rgba(255,107,53,0.1);
    box-shadow: 0 8px 40px rgba(255,107,53,0.06);
}

.testimonial-card.featured.visible { transform: translateY(-10px); }

/* Conic border on hover */
.testimonial-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 1.5px;
    background: conic-gradient(
        from var(--angle, 0deg),
        transparent 0%,
        rgba(255,107,53,0.45) 10%,
        transparent 20%
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.5s;
    pointer-events: none;
    z-index: 5;
}

.testimonial-card:hover::before { opacity: 1; }

.testimonial-card:hover {
    border-color: rgba(255,107,53,0.15);
    box-shadow: 0 12px 40px rgba(0,0,0,0.06);
    transform: translateY(-4px) !important;
}

.testimonial-card .glow-overlay {
    position: absolute;
    inset: 0;
    border-radius: 20px;
    background: radial-gradient(
        400px circle at var(--mx, 50%) var(--my, 50%),
        rgba(255,107,53,0.06), transparent 40%
    );
    opacity: 0;
    transition: opacity 0.4s;
    pointer-events: none;
    z-index: 4;
}

.testimonial-card:hover .glow-overlay { opacity: 1; }

.testimonial-quote {
    font-size: 4.5rem;
    line-height: 0.8;
    font-weight: 700;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
    user-select: none;
}

.testimonial-text {
    font-size: 1.02rem;
    line-height: 1.7;
    color: var(--text);
    margin-bottom: 1.2rem;
    position: relative;
    z-index: 1;
}

.testimonial-rating {
    color: var(--accent);
    font-size: 0.95rem;
    letter-spacing: 2px;
    margin-bottom: 1.2rem;
    position: relative;
    z-index: 1;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    z-index: 1;
}

.testimonial-avatar {
    width: 42px; height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: white;
    font-size: 0.95rem;
    flex-shrink: 0;
}

.author-avatar {
    width: 42px; height: 42px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: white;
    font-size: 1rem;
}

.testimonial-author strong,
.author-name { display: block; font-size: 0.95rem; font-weight: 700; }
.testimonial-author span,
.author-role { font-size: 0.85rem; color: var(--text-light); }

/* === CTA SECTION === */
.cta {
    background: var(--text);
    border-radius: 32px;
    padding: 5rem 2rem;
    margin: 2rem 1rem 3rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.cta::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(255,107,53,0.15) 0%, transparent 50%);
    animation: ctaSpin 30s linear infinite;
}

@keyframes ctaSpin { to { transform: rotate(360deg); } }

.cta-inner { position: relative; z-index: 1; }

.cta h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    color: white;
    margin-bottom: 0.8rem;
    letter-spacing: -1px;
}

.cta p {
    color: rgba(255,255,255,0.65);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

/* Legacy CTA */
.cta-section-twins {
    background: var(--text);
    border-radius: var(--radius-xl);
    padding: 6rem;
    margin: 4rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-section-twins::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(255,107,53,0.3) 0%, transparent 50%);
    animation: ctaSpin 20s linear infinite;
}

.cta-section-twins .cta-content { position: relative; z-index: 1; }

.cta-section-twins h2 {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    color: white;
    margin-bottom: 1rem;
    letter-spacing: -2px;
}

.cta-section-twins p {
    color: rgba(255,255,255,0.7);
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
}

.cta-section-twins .btn-primary { background: white; color: var(--text); }
.cta-section-twins .btn-primary:hover { box-shadow: 0 15px 40px rgba(255,255,255,0.2); }

/* === DARK BLOCK (About page mission, etc.) === */
.dark-block {
    background: var(--text);
    border-radius: 32px;
    margin: 0 2rem 3rem;
    padding: 4rem 2rem;
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.dark-block::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(255,107,53,0.15) 0%, transparent 50%);
    animation: ctaSpin 25s linear infinite;
}

.dark-inner {
    position: relative;
    z-index: 1;
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.dark-inner .section-title { color: white; margin-left: auto; margin-right: auto; text-align: center; }

.dark-inner p {
    color: rgba(255,255,255,0.75);
    font-size: 1.05rem;
    line-height: 1.7;
    margin-left: auto;
    margin-right: auto;
}

/* === STATS BAR (About page) === */
.stats-bar {
    max-width: 900px;
    margin: -3rem auto 3rem;
    padding: 0 2rem;
    position: relative;
    z-index: 1;
}

.stats-bar-inner {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    padding: 2.5rem 2rem;
    border-radius: 20px;
    background: rgba(255,255,255,0.6);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 4px 24px rgba(0,0,0,0.04);
    position: relative;
    overflow: hidden;
}

.stats-bar-inner::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 1.5px;
    background: conic-gradient(
        from var(--angle, 0deg),
        transparent 0%,
        rgba(255,107,53,0.5) 10%,
        transparent 20%
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    z-index: 5;
}

.stat-item {
    text-align: center;
    padding: 1rem 0.5rem;
    border-radius: 12px;
    transition: background 0.3s var(--ease);
    opacity: 0;
    transform: translateY(20px) scale(0.9);
}

.stat-item.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease), background 0.3s var(--ease);
}

.stat-item:hover { background: rgba(255,107,53,0.04); }

.stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: block;
    transition: transform 0.3s var(--ease);
}

.stat-item:hover .stat-value { transform: scale(1.1); }

.stat-label {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-top: 0.3rem;
}

/* === STORY SECTION (About page) === */
.story-section {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 2rem 4rem;
    position: relative;
    z-index: 1;
}

.story-row {
    display: flex;
    gap: 4rem;
    align-items: center;
    opacity: 0;
    transform: translateY(40px);
}

.story-row.visible {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.story-visual {
    flex-shrink: 0;
    width: 300px; height: 300px;
    border-radius: 24px;
    background: var(--text);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    position: relative;
    overflow: hidden;
}

.story-visual::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(255,107,53,0.2) 0%, transparent 50%);
    animation: ctaSpin 20s linear infinite;
}

.story-emoji { font-size: 5rem; position: relative; z-index: 1; }

.story-visual-quote {
    color: rgba(255,255,255,0.7);
    font-style: italic;
    font-size: 1rem;
    text-align: center;
    max-width: 220px;
    position: relative;
    z-index: 1;
}

.story-text { flex: 1; }

.story-text p {
    color: var(--text-light);
    font-size: 1rem;
    line-height: 1.75;
    margin-bottom: 1rem;
}

/* === VALUES (About page) === */
.values-section {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 2rem 4rem;
    position: relative;
    z-index: 1;
}

.values-header { text-align: center; margin-bottom: 3rem; }

.values-list { display: flex; flex-direction: column; gap: 0; }

.value-row {
    display: flex;
    align-items: center;
    gap: 2rem;
    padding: 2rem 0;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.35s var(--ease);
}

.value-row:first-child { border-top: 1px solid rgba(0,0,0,0.06); }

.value-row.visible {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.value-row:hover {
    background: rgba(255,255,255,0.4);
    padding-left: 1.5rem;
    padding-right: 1.5rem;
    border-radius: 16px;
}

.value-num {
    font-size: 3rem;
    font-weight: 700;
    color: rgba(0,0,0,0.06);
    flex-shrink: 0;
    width: 70px;
    transition: color 0.3s;
}

.value-row:hover .value-num { color: rgba(255,107,53,0.2); }

.value-body h3 { font-size: 1.3rem; font-weight: 700; margin-bottom: 0.3rem; }
.value-body p { color: var(--text-light); font-size: 0.95rem; line-height: 1.6; }

/* === SOCIAL BUTTONS === */
.social-section {
    text-align: center;
    padding: 1.5rem 2rem 4rem;
    position: relative;
    z-index: 1;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1.5rem;
}

.social-btn {
    width: 60px; height: 60px;
    border-radius: 50%;
    background: rgba(255,255,255,0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text);
    text-decoration: none;
    transition: all 0.3s var(--ease);
}

.social-btn:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: white;
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(255,107,53,0.3);
}

/* === COURSES PAGE — Filter & Rows === */
.courses-divider {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
    margin-top: -3rem;
}

.divider-line {
    flex: 1;
    display: block;
    height: 0;
    border: none;
    border-top: 1px solid rgba(255,107,53,0.3);
    min-width: 40px;
}

.divider-label {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent);
    white-space: nowrap;
}

.filter-bar {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 3rem;
}

.filter-btn {
    padding: 0.6rem 1.5rem;
    border-radius: 999px;
    border: 2px solid var(--border);
    background: transparent;
    color: var(--text);
    font-family: var(--font);
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s var(--ease);
}

.filter-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.filter-btn.active {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

/* Course rows — magazine layout */
.course-row {
    display: flex;
    align-items: stretch;
    gap: 0;
    border-radius: 24px;
    overflow: hidden;
    background: white;
    margin-bottom: 2rem;
    position: relative;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease),
                box-shadow 0.4s var(--ease);
    border: 1px solid rgba(0,0,0,0.06);
}

.course-row.visible { opacity: 1; transform: translateY(0); }

.course-row::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 24px;
    padding: 1.5px;
    background: conic-gradient(
        from var(--angle, 0deg),
        transparent 0%,
        var(--card-accent, rgba(255,107,53,0.45)) 10%,
        transparent 20%
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.5s;
    pointer-events: none;
    z-index: 5;
}

.course-row:hover::before { opacity: 1; }

.course-row:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 24px 60px rgba(0,0,0,0.08);
}

/* Glow overlay for course rows */
.course-row .glow-overlay {
    position: absolute;
    inset: 0;
    border-radius: 24px;
    background: radial-gradient(
        500px circle at var(--mx, 50%) var(--my, 50%),
        var(--card-glow, rgba(255,107,53,0.06)), transparent 40%
    );
    opacity: 0;
    transition: opacity 0.4s;
    pointer-events: none;
    z-index: 4;
}

.course-row:hover .glow-overlay { opacity: 1; }

/* Gradient side */
.course-gradient {
    flex-shrink: 0;
    width: 220px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    position: relative;
    overflow: hidden;
}

.course-emoji {
    font-size: 4rem;
    position: relative;
    z-index: 1;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.15));
}

.course-level-badge {
    background: rgba(255,255,255,0.25);
    backdrop-filter: blur(8px);
    padding: 0.35rem 1rem;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
    position: relative;
    z-index: 1;
}

/* Info side */
.course-info {
    flex: 1;
    padding: 2.5rem;
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
}

.course-info-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.course-title {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.course-type-tag {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 100px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.course-subtitle {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--accent);
    margin-bottom: 0.8rem;
}

.course-desc {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.65;
    margin-bottom: 1.2rem;
    max-width: 550px;
}

.course-features {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
}

.course-feature {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.85rem;
    color: var(--text-light);
}

.course-feature svg {
    color: var(--accent);
    flex-shrink: 0;
}

.course-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1.2rem;
    border-top: 1px solid rgba(0,0,0,0.06);
    margin-top: auto;
}

.course-price {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.course-price small {
    font-size: 0.8rem;
    font-weight: 400;
    color: var(--text-light);
    margin-left: 0.3rem;
}

.course-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent);
    text-decoration: none;
    transition: gap 0.3s var(--ease);
}

.course-link:hover { gap: 0.7rem; }

/* === LEVELS SECTION === */
.levels {
    background: var(--text);
    border-radius: 32px;
    margin: 0 2rem 3rem;
    padding: 3.5rem 2rem;
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.levels::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,107,53,0.15) 0%, transparent 50%);
    animation: levelsRotate 30s linear infinite;
}

@keyframes levelsRotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.levels-inner {
    position: relative;
    z-index: 1;
    max-width: 1000px;
    margin: 0 auto;
}

.levels h2 {
    font-size: clamp(1.6rem, 4vw, 2rem);
    color: white;
    text-align: center;
    margin-bottom: 0.5rem;
}

.levels-sub {
    text-align: center;
    color: rgba(255,255,255,0.6);
    font-size: 0.95rem;
    margin-bottom: 2.5rem;
}

.levels-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 1rem;
}

.level-card {
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 1.5rem 1rem;
    text-align: center;
    transition: all 0.35s var(--ease);
    border: 1px solid rgba(255,255,255,0.06);
    opacity: 0;
    transform: translateY(20px);
}

.level-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.level-card:hover {
    background: rgba(255,255,255,0.14);
    transform: translateY(-4px) !important;
}

.level-code {
    font-size: 2rem;
    font-weight: 700;
    color: white;
    display: block;
    margin-bottom: 0.3rem;
}

.level-name {
    color: rgba(255,255,255,0.6);
    font-size: 0.8rem;
    display: block;
}

/* === INCLUDES SECTION === */
.includes-section {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 2rem 4rem;
    position: relative;
    z-index: 1;
}

.includes-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.include-card {
    text-align: center;
    padding: 2rem 1.5rem;
    border-radius: 20px;
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    transition: all 0.35s var(--ease);
    opacity: 0;
    transform: translateY(30px);
}

.include-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.include-card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 12px 40px rgba(0,0,0,0.06);
}

.include-icon {
    width: 64px;
    height: 64px;
    background: rgba(255, 107, 53, 0.08);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: var(--accent);
    transition: transform 0.3s var(--ease);
}

.include-card:hover .include-icon {
    transform: scale(1.1);
}

.include-card h4 {
    font-weight: 700;
    margin-bottom: 0.4rem;
}

.include-card p {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.5;
}

/* === TEACHERS PAGE — Magazine layout === */
.teacher-row {
    display: flex;
    align-items: center;
    gap: 4rem;
    padding: 3.5rem 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.teacher-row:first-child { border-top: 1px solid rgba(0,0,0,0.05); }
.teacher-row.visible { opacity: 1; transform: translateY(0); }

/* Avatar column */
.teacher-row-avatar {
    flex-shrink: 0;
    position: relative;
    width: 180px;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.avatar-ring {
    --ring-color: var(--accent);
    width: 150px;
    height: 150px;
    border-radius: 50%;
    padding: 4px;
    background: conic-gradient(
        from var(--angle, 0deg),
        transparent 0%,
        var(--ring-color) 15%,
        transparent 30%,
        transparent 70%,
        rgba(255,107,53,0.3) 85%,
        transparent 100%
    );
    position: relative;
    z-index: 1;
    transition: transform 0.4s var(--ease);
}

.teacher-row:hover .avatar-ring {
    transform: scale(1.06);
}

.avatar-ring img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: inset 0 0 0 3px var(--bg);
}

.avatar-ring .teacher-avatar-placeholder {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
    box-shadow: inset 0 0 0 3px var(--bg);
}

.avatar-decoration {
    position: absolute;
    inset: -20px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,107,53,0.12), transparent 70%);
    z-index: 0;
    transition: transform 0.5s var(--ease), opacity 0.5s;
}

.teacher-row:hover .avatar-decoration {
    transform: scale(1.3);
    opacity: 0.8;
}

/* Info column */
.teacher-row-info { flex: 1; }

.teacher-row-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 0.5rem;
}

.teacher-name {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.teacher-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.teacher-tag {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 0.25rem 0.65rem;
    border-radius: 100px;
    background: rgba(255,107,53,0.08);
    color: var(--accent);
}

.teacher-tag.exp {
    background: rgba(34,197,94,0.08);
    color: #16A34A;
}

.teacher-role {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--accent);
    margin-bottom: 0.8rem;
}

.teacher-bio {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.65;
    margin-bottom: 1rem;
    max-width: 500px;
}

.teacher-quote {
    font-style: italic;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text);
    padding-left: 1rem;
    border-left: 3px solid var(--accent);
    margin-bottom: 1.2rem;
    max-width: 480px;
}

.teacher-footer {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.teacher-education {
    font-size: 0.85rem;
    color: var(--text-light);
}

.teacher-rating {
    color: var(--accent);
    font-size: 0.85rem;
    letter-spacing: 2px;
}

.teacher-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent);
    text-decoration: none;
    transition: gap 0.3s var(--ease);
}

.teacher-link:hover { gap: 0.7rem; }

/* === CONTACT PAGE === */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2rem 4rem;
    position: relative;
    z-index: 1;
}

.contact-form-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 20px;
    padding: 2.5rem;
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    position: relative;
    overflow: hidden;
    transition: box-shadow 0.35s, border-color 0.35s;
}

/* Conic border */
.contact-form-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 1.5px;
    background: conic-gradient(
        from var(--angle, 0deg),
        transparent 0%,
        rgba(255,107,53,0.45) 10%,
        transparent 20%
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.5s;
    pointer-events: none;
    z-index: 5;
}

.contact-form-card:hover::before { opacity: 1; }

.form-row {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    margin-bottom: 1.2rem;
}

.form-row label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text);
}

.form-row input,
.form-row select,
.form-row textarea {
    padding: 0.9rem 1rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    font-family: var(--font);
    font-size: 0.95rem;
    background: white;
    transition: all 0.3s var(--ease);
    resize: vertical;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255,107,53,0.1);
    outline: none;
}

/* Contact info card */
.contact-info-card {
    background: var(--text);
    border-radius: 20px;
    padding: 2.5rem;
    color: white;
    position: relative;
    overflow: hidden;
}

.contact-info-card::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(255,107,53,0.12) 0%, transparent 50%);
    animation: ctaSpin 25s linear infinite;
}

.contact-info-card > * { position: relative; z-index: 1; }

.contact-info-card h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.contact-detail {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    color: rgba(255,255,255,0.8);
}

/* FAQ Accordion */
.faq-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 20px;
    padding: 2rem;
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

.faq-card h3 {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.faq-card details {
    border-bottom: 1px solid rgba(0,0,0,0.06);
    padding: 1rem 0;
}

.faq-card details:last-of-type { border-bottom: none; }

.faq-card summary {
    font-weight: 600;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: color 0.3s;
}

.faq-card summary:hover { color: var(--accent); }

.faq-card summary::after {
    content: '+';
    font-size: 1.3rem;
    font-weight: 300;
    transition: transform 0.3s;
}

.faq-card details[open] summary::after {
    transform: rotate(45deg);
}

.faq-card details p {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-top: 0.8rem;
}

/* Contact form elements */
.form-group {
    margin-bottom: 1.2rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 0.9rem 1rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    font-size: 1rem;
    font-family: var(--font);
    background: rgba(255,255,255,0.5);
    color: var(--text);
    transition: all 0.3s;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255,107,53,0.1);
}

.form-textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-info-column {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.2rem;
    position: relative;
    z-index: 1;
}

.contact-icon {
    width: 44px;
    height: 44px;
    background: rgba(255,255,255,0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
}

.contact-label {
    color: rgba(255,255,255,0.5);
    font-size: 0.8rem;
    display: block;
}

.contact-value {
    color: white;
    font-weight: 500;
}

.social-divider {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 1.2rem;
    margin-top: 0.5rem;
    position: relative;
    z-index: 1;
}

.social-label {
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
    display: block;
    margin-bottom: 0.8rem;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.faq-item {
    background: rgba(255,255,255,0.5);
    border-radius: 12px;
    overflow: hidden;
    transition: background 0.3s;
}

.faq-item[open] {
    background: rgba(255,255,255,0.8);
}

.faq-item summary {
    padding: 1rem;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text);
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: color 0.3s;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
    content: '+';
    font-size: 1.3rem;
    color: var(--accent);
    transition: transform 0.3s;
    flex-shrink: 0;
    margin-left: 1rem;
}

.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item summary:hover { color: var(--accent); }

.faq-item p {
    padding: 0 1rem 1rem;
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* Validation messages */
.validation-message {
    color: #ef4444;
    font-size: 0.8rem;
    margin-top: 0.3rem;
}

/* === NAVBAR — floating pill === */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 1.2rem 2rem;
    transition: padding 0.6s var(--ease);
}

.navbar.scrolled { padding: 0.5rem 1.5rem; }

.navbar-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    padding: 0.7rem 1.5rem;
    border-radius: 100px;
    background: transparent;
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
    border: 1px solid transparent;
    box-shadow: 0 0 0 0 rgba(0,0,0,0);
    transition: background 0.6s var(--ease),
                backdrop-filter 0.6s var(--ease),
                -webkit-backdrop-filter 0.6s var(--ease),
                box-shadow 0.6s var(--ease),
                border-color 0.6s var(--ease);
}

.navbar.scrolled .navbar-inner {
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    box-shadow: 0 8px 32px rgba(0,0,0,0.08), 0 2px 8px rgba(0,0,0,0.04);
    border-color: rgba(0,0,0,0.06);
}

.nav-logo {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    color: var(--text);
    text-decoration: none;
    flex-shrink: 0;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    margin: 0 auto;
}

.nav-link {
    position: relative;
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    border-radius: 100px;
    transition: all 0.3s var(--ease);
    overflow: hidden;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: calc(100% - 1.4rem);
    height: 2px;
    background: var(--accent);
    border-radius: 2px;
    transition: transform 0.3s var(--ease);
}

.nav-link:hover {
    color: var(--text);
    background: rgba(0,0,0,0.04);
}

.nav-link:hover::after {
    transform: translateX(-50%) scaleX(1);
}

.nav-link.active {
    color: var(--text);
    background: rgba(0,0,0,0.06);
}

.nav-link.active::after {
    transform: translateX(-50%) scaleX(1);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.nav-btn-login {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    border-radius: 100px;
    transition: all 0.3s var(--ease);
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--font);
}

.nav-btn-login:hover {
    color: var(--text);
    background: rgba(0,0,0,0.04);
}

.nav-btn-cta {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.55rem 1.4rem;
    font-family: var(--font);
    font-size: 0.85rem;
    font-weight: 600;
    color: white;
    text-decoration: none;
    border-radius: 100px;
    background: var(--text);
    border: none;
    cursor: pointer;
    transition: transform 0.3s var(--ease), box-shadow 0.4s var(--ease);
    box-shadow: 0 0 0 0 rgba(255,107,53,0);
}

.nav-btn-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 0 20px rgba(255,107,53,0.4), 0 0 40px rgba(255,107,53,0.15);
}

.nav-btn-cta:active {
    transform: translateY(0);
}

/* Nav user menu (authorized) */
.nav-user-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 1rem 0.4rem 0.5rem;
    border-radius: 100px;
    background: transparent;
    border: 1px solid rgba(0,0,0,0.06);
    cursor: pointer;
    font-family: var(--font);
    font-weight: 500;
    font-size: 0.85rem;
    color: var(--text);
    transition: all 0.3s var(--ease);
}

.nav-user-btn:hover {
    background: rgba(0,0,0,0.04);
    border-color: rgba(0,0,0,0.1);
}

.nav-user-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    color: white;
}

.nav-user-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 200px;
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: 12px;
    box-shadow: 0 16px 48px rgba(0,0,0,0.1);
    padding: 0.5rem;
    opacity: 0;
    transform: translateY(-4px) scale(0.98);
    pointer-events: none;
    transition: all 0.2s var(--ease);
    z-index: 2000;
}

.nav-user-menu.open {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.nav-user-menu a,
.nav-user-menu button {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    width: 100%;
    padding: 0.6rem 0.8rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text);
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--font);
    transition: background 0.2s;
    text-align: left;
}

.nav-user-menu a:hover,
.nav-user-menu button:hover {
    background: rgba(0,0,0,0.04);
}

.nav-user-menu .menu-divider {
    height: 1px;
    background: rgba(0,0,0,0.06);
    margin: 0.3rem 0;
}

.nav-user-menu .logout-item:hover {
    background: #fef2f2;
    color: #ef4444;
}

/* Notification bell (navbar) */
.nav-bell-wrap { position: relative; }

.nav-bell {
    position: relative;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    cursor: pointer;
    transition: all 0.3s var(--ease);
    background: transparent;
    border: none;
    font-size: 0;
}

.nav-bell:hover { background: rgba(0,0,0,0.04); color: var(--text); }

.nav-bell-dot {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
    border: 2px solid white;
    animation: bellPulse 2s infinite;
}

@keyframes bellPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255,107,53,0.4); }
    50% { box-shadow: 0 0 0 4px rgba(255,107,53,0); }
}

/* Notification popover (glass) */
.notif-popover {
    position: absolute;
    top: calc(100% + 10px);
    right: -60px;
    width: min(380px, calc(100vw - 2rem));
    max-height: 480px;
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.12), 0 1px 3px rgba(0,0,0,0.04);
    overflow: hidden;
    opacity: 0;
    transform: translateY(-8px) scale(0.96);
    pointer-events: none;
    transition: all 0.25s var(--ease);
    z-index: 2000;
}

.notif-popover.open {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.notif-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.2rem 0.6rem;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.notif-title { font-size: 0.95rem; font-weight: 700; color: var(--text); }

.notif-mark-read {
    font-size: 0.75rem;
    color: var(--accent);
    cursor: pointer;
    font-weight: 600;
    background: none;
    border: none;
    font-family: var(--font);
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    transition: background 0.2s;
}

.notif-mark-read:hover { background: rgba(255,107,53,0.08); }

.notif-list {
    max-height: 320px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(0,0,0,0.1) transparent;
}

.notif-item {
    display: flex;
    gap: 0.8rem;
    padding: 0.9rem 1.2rem;
    border-bottom: 1px solid rgba(0,0,0,0.03);
    cursor: pointer;
    transition: background 0.2s;
    position: relative;
}

.notif-item:hover { background: rgba(0,0,0,0.02); }

.notif-item.unread { background: rgba(255,107,53,0.03); }

.notif-item.unread::after {
    content: '';
    position: absolute;
    top: 50%;
    right: 1rem;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
}

.notif-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1rem;
}

.notif-icon.lesson   { background: rgba(59,130,246,0.1); color: #3B82F6; }
.notif-icon.payment  { background: rgba(16,185,129,0.1); color: #10B981; }
.notif-icon.system   { background: rgba(245,158,11,0.1); color: #F59E0B; }
.notif-icon.homework { background: rgba(139,92,246,0.1); color: #8B5CF6; }
.notif-icon.message  { background: rgba(236,72,153,0.1); color: #EC4899; }

.notif-body { flex: 1; min-width: 0; padding-right: 1.2rem; }

.notif-text {
    font-size: 0.8rem;
    color: var(--text);
    line-height: 1.4;
    margin-bottom: 0.2rem;
}

.notif-text strong { font-weight: 600; }

.notif-time { font-size: 0.7rem; color: var(--text-light); }

.notif-empty {
    padding: 3rem 1.2rem;
    text-align: center;
    color: var(--text-light);
    font-size: 0.85rem;
}

.notif-footer {
    padding: 0.7rem 1.2rem;
    border-top: 1px solid rgba(0,0,0,0.05);
    text-align: center;
}

.notif-footer a {
    font-size: 0.8rem;
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
    transition: opacity 0.2s;
}

.notif-footer a:hover { opacity: 0.7; }

.notif-backdrop {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: none;
}

.notif-backdrop.open { display: block; }

/* Mobile hamburger */
.nav-mobile-btn {
    display: none;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0;
    border-radius: 8px;
    transition: background 0.3s;
}

.nav-mobile-btn:hover { background: rgba(0,0,0,0.04); }

.hamburger {
    width: 20px;
    height: 14px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: all 0.3s var(--ease);
    transform-origin: center;
}

.nav-mobile-btn.open .hamburger span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-mobile-btn.open .hamburger span:nth-child(2) { opacity: 0; }
.nav-mobile-btn.open .hamburger span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Mobile fullscreen menu */
.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 999;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s var(--ease);
}

.mobile-menu.open { opacity: 1; pointer-events: auto; }

.mobile-link {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text);
    text-decoration: none;
    padding: 0.8rem 2rem;
    border-radius: 12px;
    transition: all 0.3s var(--ease);
    opacity: 0;
    transform: translateY(20px);
}

.mobile-menu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

.mobile-link:hover { background: rgba(0,0,0,0.04); color: var(--accent); }

.mobile-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
    opacity: 0;
    transform: translateY(20px);
}

.mobile-menu.open .mobile-actions {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.4s var(--ease) 0.3s, transform 0.4s var(--ease) 0.3s;
}

.mobile-menu .nav-btn-cta { font-size: 1rem; padding: 0.75rem 2rem; }

@media (max-width: 1024px) {
    .nav-links { display: none; }
    .nav-actions { display: none; }
    .nav-mobile-btn { display: flex; }
}

/* === COLLAPSIBLE SIDEBAR (dashboard) === */
:root {
    --sidebar-collapsed: 68px;
    --sidebar-expanded: 280px;
    --topbar-height: 64px;
}

.sidebar-dash {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: var(--sidebar-collapsed);
    background: rgba(255,255,255,0.75);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-right: 1px solid rgba(0,0,0,0.06);
    z-index: 100;
    display: flex;
    flex-direction: column;
    transition: width 0.3s var(--ease);
    overflow: hidden;
}

.sidebar-dash:hover,
.sidebar-dash.pinned {
    width: var(--sidebar-expanded);
}

.sidebar-dash:hover .sb-label,
.sidebar-dash.pinned .sb-label,
.sidebar-dash:hover .sb-section-label,
.sidebar-dash.pinned .sb-section-label,
.sidebar-dash:hover .sb-logo-text,
.sidebar-dash.pinned .sb-logo-text,
.sidebar-dash:hover .sb-footer-text,
.sidebar-dash.pinned .sb-footer-text,
.sidebar-dash:hover .sb-pin-btn,
.sidebar-dash.pinned .sb-pin-btn,
.sidebar-dash:hover .sb-user-info,
.sidebar-dash.pinned .sb-user-info {
    opacity: 1;
}

.sb-header {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 1.2rem;
    height: var(--topbar-height);
    flex-shrink: 0;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    position: relative;
    text-decoration: none;
    color: inherit;
}

.sb-logo-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.1rem;
    font-weight: 700;
    color: white;
    font-family: var(--font-heading);
}

.sb-logo-text {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text);
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.2s var(--ease);
}

.sb-pin-btn {
    position: absolute;
    right: 12px;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: var(--text-muted, #999);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.2s var(--ease);
}

.sb-pin-btn:hover { background: rgba(0,0,0,0.04); color: var(--text); }
.sb-pin-btn.pinned { color: var(--accent); }

.sb-nav {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0.5rem 0.75rem;
    scrollbar-width: thin;
    scrollbar-color: rgba(0,0,0,0.08) transparent;
}

.sb-section-label {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--text-muted, #999);
    padding: 1rem 0.75rem 0.4rem;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.2s var(--ease);
}

.sb-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.6rem 0.75rem;
    border-radius: 10px;
    text-decoration: none;
    color: var(--text-light);
    font-weight: 500;
    font-size: 0.88rem;
    transition: all 0.2s var(--ease);
    cursor: pointer;
    position: relative;
    white-space: nowrap;
    margin-bottom: 2px;
}

.sb-item:hover { background: rgba(0,0,0,0.04); color: var(--text); }

.sb-item.active {
    background: rgba(255,107,53,0.08);
    color: var(--accent);
}

.sb-item.active .sb-icon { color: var(--accent); }

.sb-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    transition: color 0.2s;
}

.sb-item:hover .sb-icon { color: var(--text); }

.sb-label {
    opacity: 0;
    transition: opacity 0.2s var(--ease);
    white-space: nowrap;
}

/* Tooltip for collapsed state */
.sb-item[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    left: calc(100% + 12px);
    top: 50%;
    transform: translateY(-50%);
    padding: 0.35rem 0.7rem;
    background: var(--text);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 8px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s;
    z-index: 200;
}

.sidebar-dash:not(:hover):not(.pinned) .sb-item:hover::after { opacity: 1; }

.sb-divider {
    height: 1px;
    background: rgba(0,0,0,0.06);
    margin: 0.5rem 1rem;
}

.sb-footer {
    flex-shrink: 0;
    border-top: 1px solid rgba(0,0,0,0.06);
    padding: 0.75rem;
}

.sb-user {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.6rem 0.75rem;
    border-radius: 10px;
    margin-bottom: 0.25rem;
    transition: background 0.2s;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

.sb-user:hover { background: rgba(0,0,0,0.04); }

.sb-user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
}

.sb-user-info {
    min-width: 0;
    opacity: 0;
    transition: opacity 0.2s var(--ease);
}

.sb-user-name {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sb-user-role { font-size: 0.68rem; color: var(--text-muted, #999); }

.sb-footer .sb-item.logout:hover { background: #fef2f2; color: #ef4444; }
.sb-footer .sb-item.logout:hover .sb-icon { color: #ef4444; }

.sb-footer-text {
    opacity: 0;
    transition: opacity 0.2s var(--ease);
}

/* Dashboard topbar (works with sidebar) */
.topbar-dash {
    position: fixed;
    top: 0;
    left: var(--sidebar-collapsed);
    right: 0;
    height: var(--topbar-height);
    background: rgba(255,255,255,0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    padding: 0 2rem;
    z-index: 90;
    transition: left 0.3s var(--ease);
}

.sidebar-dash:hover ~ .topbar-dash,
.sidebar-dash.pinned ~ .topbar-dash {
    left: var(--sidebar-expanded);
}

.topbar-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 600;
}

.topbar-spacer { flex: 1; }

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.topbar-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: none;
    background: transparent;
    color: var(--text-light);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    position: relative;
}

.topbar-btn:hover { background: rgba(0,0,0,0.04); color: var(--text); }

.topbar-btn .dot {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 7px;
    height: 7px;
    background: var(--accent);
    border-radius: 50%;
    border: 2px solid white;
}

/* Dashboard main content (shifts with sidebar) */
.main-dash {
    margin-left: var(--sidebar-collapsed);
    padding-top: var(--topbar-height);
    min-height: 100vh;
    transition: margin-left 0.3s var(--ease);
}

.sidebar-dash:hover ~ .topbar-dash ~ .main-dash,
.sidebar-dash.pinned ~ .topbar-dash ~ .main-dash {
    margin-left: var(--sidebar-expanded);
}

.main-dash-inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

/* Dashboard mobile overlay */
.sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.3);
    z-index: 99;
    display: none;
    opacity: 0;
    transition: opacity 0.3s;
}

.sidebar-overlay.open { display: block; opacity: 1; }

.mobile-menu-btn {
    display: none;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    color: var(--text);
    cursor: pointer;
    border-radius: 10px;
    transition: background 0.2s;
}

.mobile-menu-btn:hover { background: rgba(0,0,0,0.04); }

@media (max-width: 1024px) {
    .sidebar-dash {
        width: 0 !important;
        transform: translateX(-100%);
    }

    .sidebar-dash.mobile-open {
        width: var(--sidebar-expanded) !important;
        transform: translateX(0);
    }

    .sidebar-dash.mobile-open .sb-label,
    .sidebar-dash.mobile-open .sb-section-label,
    .sidebar-dash.mobile-open .sb-logo-text,
    .sidebar-dash.mobile-open .sb-footer-text,
    .sidebar-dash.mobile-open .sb-pin-btn,
    .sidebar-dash.mobile-open .sb-user-info {
        opacity: 1;
    }

    .topbar-dash { left: 0 !important; padding: 0 1rem; }
    .main-dash { margin-left: 0 !important; }
    .mobile-menu-btn { display: flex; }

    .sidebar-dash:hover ~ .topbar-dash,
    .sidebar-dash.pinned ~ .topbar-dash {
        left: 0 !important;
    }

    .sidebar-dash:hover ~ .topbar-dash ~ .main-dash,
    .sidebar-dash.pinned ~ .topbar-dash ~ .main-dash {
        margin-left: 0 !important;
    }
}

@media (max-width: 480px) {
    .topbar-dash { padding: 0 0.75rem; }
    .topbar-actions { gap: 0.25rem; }
    .topbar-btn { width: 32px; height: 32px; }
}

/* === ERROR LOG DETAIL === */
.error-log-message {
    font-size: 0.95rem;
    line-height: 1.6;
    word-break: break-word;
    white-space: pre-wrap;
    padding: 1rem;
    background: var(--bg, #f8f9fa);
    border-radius: 8px;
    border: 1px solid rgba(0,0,0,.06);
}

.error-log-stacktrace {
    font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
    font-size: 0.8rem;
    line-height: 1.7;
    white-space: pre-wrap;
    word-break: break-all;
    padding: 1rem;
    background: #1e1e2e;
    color: #cdd6f4;
    border-radius: 8px;
    max-height: 500px;
    overflow: auto;
    margin: 0;
}

/* === NOT FOUND (404) PAGE === */
.notfound-container {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 80vh;
    overflow: hidden;
    padding: 2rem;
}

.notfound-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
    pointer-events: none;
    animation: notfound-float 8s ease-in-out infinite;
}

.notfound-orb--primary {
    width: 400px;
    height: 400px;
    background: var(--accent);
    top: 20%;
    left: calc(50% - 240px);
    animation-delay: 0s;
}

.notfound-orb--secondary {
    width: 300px;
    height: 300px;
    background: var(--accent-purple);
    bottom: 15%;
    right: calc(50% - 200px);
    animation-delay: -4s;
}

@keyframes notfound-float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(40px, -20px) scale(1.05); }
    50% { transform: translate(-20px, 20px) scale(0.95); }
    75% { transform: translate(20px, 10px) scale(1.02); }
}

.notfound-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1.5rem;
}

.notfound-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.25rem;
    border-radius: 100px;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-light);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-light);
    animation: notfound-fadeUp 0.6s ease-out both;
}

.notfound-code {
    font-family: var(--font-heading);
    font-size: clamp(6rem, 15vw, 12rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: notfound-fadeUp 0.6s 0.15s ease-out both;
}

.notfound-desc {
    font-family: var(--font-body);
    font-size: 1.125rem;
    color: var(--text-light);
    max-width: 400px;
    line-height: 1.6;
    animation: notfound-fadeUp 0.6s 0.3s ease-out both;
}

.notfound-actions {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
    animation: notfound-fadeUp 0.6s 0.45s ease-out both;
}

.notfound-btn-primary {
    font-weight: 600 !important;
    padding: 0.625rem 2rem !important;
    box-shadow: var(--shadow-accent) !important;
    transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease) !important;
}
.notfound-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 50px rgba(255, 107, 53, 0.3) !important;
}

.notfound-btn-secondary {
    font-weight: 600 !important;
    padding: 0.625rem 2rem !important;
    border-color: var(--border) !important;
    color: var(--text) !important;
    transition: transform 0.3s var(--ease), border-color 0.3s var(--ease) !important;
}
.notfound-btn-secondary:hover {
    transform: translateY(-2px);
    border-color: var(--accent) !important;
    color: var(--accent) !important;
}

@keyframes notfound-fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 480px) {
    .notfound-container { min-height: 70vh; padding: 1.5rem; }
    .notfound-orb--primary { width: 250px; height: 250px; }
    .notfound-orb--secondary { width: 200px; height: 200px; }
    .notfound-actions { flex-direction: column; width: 100%; }
    .notfound-actions .mud-button { width: 100%; }
}

/* === FOOTER === */
.footer-twins {
    background: var(--text);
    color: white;
    padding: 4rem 2rem 2rem;
    position: relative;
    z-index: 1;
}

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

.footer-top {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 4rem;
    padding-bottom: 3rem;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    text-decoration: none;
    color: white;
}

.footer-logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    background: var(--accent);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.1rem;
    color: white;
}

.footer-logo-text {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.footer-desc {
    color: rgba(255, 255, 255, 0.55);
    max-width: 320px;
    line-height: 1.6;
    font-size: 0.9375rem;
}

.footer-social {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.25rem;
}

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.6);
    transition: background 0.3s var(--ease), color 0.3s var(--ease), transform 0.3s var(--ease);
}

.footer-social a:hover {
    background: var(--accent);
    color: white;
    transform: translateY(-2px);
}

.footer-links-group {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.footer-column h4 {
    font-family: var(--font-heading);
    font-size: 0.875rem;
    font-weight: 600;
    color: white;
    margin-bottom: 1.25rem;
    letter-spacing: -0.01em;
}

.footer-column ul { list-style: none; }

.footer-column li { margin-bottom: 0.625rem; }

.footer-column a {
    color: rgba(255, 255, 255, 0.55);
    text-decoration: none;
    font-weight: 400;
    font-size: 0.9375rem;
    transition: color 0.3s var(--ease);
}

.footer-column a:hover {
    color: var(--accent);
}

.footer-divider-line {
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
}

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 2rem;
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.875rem;
}

.footer-legal {
    display: flex;
    gap: 1.5rem;
}

.footer-legal a {
    color: rgba(255, 255, 255, 0.4);
    text-decoration: none;
    font-size: 0.875rem;
    transition: color 0.3s var(--ease);
}

.footer-legal a:hover {
    color: var(--accent);
}

@media (max-width: 1024px) {
    .footer-top { grid-template-columns: 1fr; gap: 3rem; }
    .footer-links-group { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .footer-twins { padding: 3rem 1.25rem 1.5rem; }
    .footer-links-group { grid-template-columns: repeat(2, 1fr); gap: 2rem; }
    .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
    .footer-legal { flex-wrap: wrap; justify-content: center; gap: 1rem; }
}

@media (max-width: 480px) {
    .footer-links-group { grid-template-columns: 1fr; }
}

/* === DASHBOARD LAYOUT === */
.dashboard-layout {
    display: flex;
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--bg);
}

.dashboard-sidebar {
    width: 280px;
    max-width: 80vw;
    background: rgba(255,255,255,0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-right: 1px solid var(--border-light);
    padding: 2rem;
    position: fixed;
    height: 100vh;
    height: 100dvh;
    overflow-y: auto;
}

.dashboard-main {
    flex: 1;
    margin-left: 280px;
    padding: 2rem;
    min-width: 0;
}

.sidebar-logo {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-light);
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1rem;
    border-radius: var(--radius-md);
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.sidebar-link:hover { background: var(--bg-alt); color: var(--text); }

.sidebar-link.active {
    background: var(--accent-light);
    color: var(--accent);
}

/* Dashboard Glassmorphism Cards */
.dashboard-card,
.dash-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: var(--radius-lg);
    padding: 2rem;
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    transition: var(--transition);
}

.dashboard-card:hover,
.dash-card:hover {
    box-shadow: 0 8px 32px rgba(0,0,0,0.06);
    border-color: rgba(255,107,53,0.1);
}

/* Dashboard Glow Stat Card */
.dashboard-stat-card,
.dash-stat {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.dashboard-stat-card:hover,
.dash-stat:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(255,107,53,0.08);
    border-color: rgba(255,107,53,0.15);
}

.stat-icon {
    width: 48px; height: 48px;
    background: linear-gradient(135deg, #FFF4ED, #FFE4D4);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
}

.stat-content h3 {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    margin: 0;
    color: var(--text);
}

.stat-content p {
    font-size: 0.9rem;
    color: var(--text-light);
    margin: 0;
}

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

/* Dashboard quick action buttons */
.quick-action-btn {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s var(--ease);
    cursor: pointer;
}

.quick-action-btn:hover {
    background: rgba(255,255,255,0.8);
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.06);
    border-color: rgba(255,107,53,0.15);
}

/* Dashboard lesson/homework card shared style */
.dash-item-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    padding: 1.5rem;
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    transition: all 0.3s var(--ease);
    border-left: 4px solid var(--accent);
}

.dash-item-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}

/* === DASHBOARD — Global MudBlazor Overrides (glassmorphism) === */
.dashboard-layout-twins .mud-paper {
    background: var(--glass-bg) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;
    border: 1px solid var(--glass-border) !important;
    box-shadow: var(--glass-shadow) !important;
    transition: all 0.3s var(--ease) !important;
}

.dashboard-layout-twins .mud-paper:hover {
    box-shadow: 0 8px 32px rgba(0,0,0,0.06) !important;
    border-color: rgba(255,107,53,0.1) !important;
}

.dashboard-layout-twins .mud-card {
    background: var(--glass-bg) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;
    border: 1px solid var(--glass-border) !important;
    box-shadow: var(--glass-shadow) !important;
    transition: all 0.3s var(--ease) !important;
    overflow: hidden;
}

.dashboard-layout-twins .mud-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(255,107,53,0.08) !important;
    border-color: rgba(255,107,53,0.15) !important;
}

.dashboard-layout-twins .mud-table {
    background: transparent !important;
    box-shadow: none !important;
}

.dashboard-layout-twins .mud-table .mud-table-head .mud-table-cell {
    background: rgba(255,107,53,0.04) !important;
    font-weight: 600;
    color: var(--text);
    border-bottom: 1px solid var(--glass-border) !important;
}

.dashboard-layout-twins .mud-table .mud-table-body .mud-table-row:hover {
    background: rgba(255,107,53,0.03) !important;
}

.dashboard-layout-twins .mud-table .mud-table-cell {
    border-bottom: 1px solid rgba(0,0,0,0.04) !important;
}

.dashboard-layout-twins .mud-tabs .mud-tab {
    color: var(--text-light) !important;
    font-weight: 500;
    letter-spacing: 0.01em;
    opacity: 0.75;
    transition: color 0.25s, opacity 0.25s;
}

.dashboard-layout-twins .mud-tabs .mud-tab:hover {
    color: var(--text) !important;
    opacity: 0.9;
}

.dashboard-layout-twins .mud-tabs .mud-tab.mud-tab-active {
    color: var(--accent) !important;
    font-weight: 600;
    opacity: 1;
}

.dashboard-layout-twins .mud-tabs-toolbar {
    background: transparent !important;
}

.dashboard-layout-twins .mud-tabs-toolbar .mud-tab-slider {
    background: var(--accent) !important;
}

/* Dashboard page header */
.dash-page-header {
    margin-bottom: 2rem;
}

.dash-page-header h1 {
    font-family: var(--font);
    font-size: clamp(1.6rem, 3.5vw, 2.2rem);
    font-weight: 700;
    color: var(--text);
    margin: 0 0 0.5rem;
}

.dash-page-header p {
    color: rgba(0,0,0,0.5);
    font-size: 1rem;
    margin: 0;
}

/* R18: баннер о верификации преподавателя на /teacher/schedule.
   Отдельный визуал, чтобы выделялся и не сливался с остальным дашбордом. */
.verify-banner {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    background: var(--bg-card);
}

.verify-banner__icon {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
}

.verify-banner__body {
    flex: 1;
    min-width: 0;
}

.verify-banner__title {
    font-family: var(--font-heading, var(--font));
    font-weight: 600;
    font-size: 1rem;
    color: var(--text);
}

.verify-banner__text {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-top: 2px;
}

.verify-banner__cta {
    flex-shrink: 0;
    padding: 0.6rem 1.1rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.92rem;
    text-decoration: none;
    transition: var(--transition);
    white-space: nowrap;
}

/* «нет заявки» — мягкий тёплый акцент */
.verify-banner--none .verify-banner__icon {
    background: rgba(99, 102, 241, 0.12);
    color: #6366F1;
}
.verify-banner--none .verify-banner__cta {
    background: #6366F1;
    color: white;
}
.verify-banner--none .verify-banner__cta:hover { filter: brightness(1.05); }

/* «pending» — спокойный синий */
.verify-banner--pending .verify-banner__icon {
    background: rgba(14, 165, 233, 0.12);
    color: #0ea5e9;
}
.verify-banner--pending .verify-banner__cta {
    background: rgba(14, 165, 233, 0.1);
    color: #0ea5e9;
    border: 1px solid rgba(14, 165, 233, 0.4);
}

/* «rejected» — тревожный, но не катастрофический */
.verify-banner--rejected .verify-banner__icon {
    background: rgba(239, 68, 68, 0.12);
    color: #ef4444;
}
.verify-banner--rejected .verify-banner__cta {
    background: #ef4444;
    color: white;
}
.verify-banner--rejected .verify-banner__cta:hover { filter: brightness(1.05); }

@media (max-width: 700px) {
    .verify-banner {
        flex-direction: column;
        align-items: flex-start;
    }
    .verify-banner__cta {
        width: 100%;
        text-align: center;
    }
}

/* Dashboard icon box */
.dash-icon-box {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.dash-icon-box.accent {
    background: linear-gradient(135deg, #FFF4ED, #FFE4D4);
    color: var(--accent);
}

.dash-icon-box.success {
    background: linear-gradient(135deg, #ECFDF5, #D1FAE5);
    color: #16a34a;
}

.dash-icon-box.info {
    background: linear-gradient(135deg, #EFF6FF, #DBEAFE);
    color: #3B82F6;
}

.dash-icon-box.warning {
    background: linear-gradient(135deg, #FFFBEB, #FEF3C7);
    color: #F59E0B;
}

.dash-icon-box.purple {
    background: linear-gradient(135deg, #F5F3FF, #EDE9FE);
    color: #7C3AED;
}

.dash-icon-box.lg {
    width: 72px;
    height: 72px;
    border-radius: 50%;
}

.dash-icon-box.lg .mud-icon-root {
    font-size: 2rem !important;
}

/* Dashboard level circle */
.dash-level-circle {
    width: 80px;
    height: 80px;
    background: var(--accent-gradient, linear-gradient(135deg, #FF6B35, #FF8F5E));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-family: var(--font);
    font-size: 1.8rem;
    font-weight: 700;
    color: white;
}

/* Status badges */
.dash-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.35rem 0.75rem;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    white-space: nowrap;
}

.dash-badge.success {
    background: #ECFDF5;
    color: #16a34a;
}

.dash-badge.warning {
    background: #FFFBEB;
    color: #ca8a04;
}

.dash-badge.info {
    background: #EFF6FF;
    color: #3B82F6;
}

.dash-badge.error {
    background: #FEF2F2;
    color: #DC2626;
}

.dash-badge.accent {
    background: rgba(255,107,53,0.1);
    color: var(--accent);
}

/* Dashboard lesson/homework item row */
.dash-list-item {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    padding: 1.25rem 1.5rem;
    border: 1px solid var(--glass-border);
    border-left: 4px solid var(--accent);
    margin-bottom: 1rem;
    transition: all 0.3s var(--ease);
}

.dash-list-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.05);
    border-color: rgba(255,107,53,0.15);
    border-left-color: var(--accent);
}

.dash-list-item.border-success { border-left-color: #16a34a; }
.dash-list-item.border-warning { border-left-color: #F59E0B; }
.dash-list-item.border-info    { border-left-color: #3B82F6; }
.dash-list-item.border-purple  { border-left-color: #7C3AED; }

/* Dashboard notification item */
.dash-notification {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    padding: 1.25rem 1.5rem;
    border: 1px solid var(--glass-border);
    border-left: 4px solid var(--accent);
    margin-bottom: 0.75rem;
    transition: all 0.3s var(--ease);
    cursor: pointer;
}

.dash-notification.unread {
    background: rgba(255,107,53,0.03);
    border-color: rgba(255,107,53,0.12);
}

.dash-notification:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.04);
}

/* Dashboard empty state */
.dash-empty {
    text-align: center;
    padding: 3rem 2rem;
}

.dash-empty .mud-icon-root {
    font-size: 4rem !important;
    opacity: 0.2;
    color: var(--text);
}

.dash-empty p {
    color: rgba(0,0,0,0.4);
    margin-top: 1rem;
    font-size: 1rem;
}

/* Dashboard section title */
.dash-section-title {
    font-family: var(--font);
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text);
    margin: 0 0 1.5rem;
}

/* Dashboard course card gradient header */
.dash-course-gradient {
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    position: relative;
}

.dash-course-gradient .course-level-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(8px);
    color: white;
    padding: 0.25rem 0.7rem;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* Dashboard stat value (big number) */
.dash-stat-value {
    font-family: var(--font);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1;
}

.dash-stat-label {
    font-size: 0.9rem;
    color: rgba(0,0,0,0.45);
    margin-top: 0.25rem;
}

/* Dashboard MudButton overrides */
.dashboard-layout-twins .mud-button-filled.mud-button-primary {
    background: var(--accent-gradient, linear-gradient(135deg, #FF6B35, #FF8F5E)) !important;
    border: none !important;
    box-shadow: 0 4px 16px rgba(255,107,53,0.25) !important;
    transition: all 0.3s var(--ease) !important;
}

.dashboard-layout-twins .mud-button-filled.mud-button-primary:hover {
    box-shadow: 0 8px 24px rgba(255,107,53,0.35) !important;
    transform: translateY(-1px);
}

.dashboard-layout-twins .mud-button-outlined.mud-button-primary {
    border-color: rgba(255,107,53,0.3) !important;
    color: var(--accent) !important;
}

.dashboard-layout-twins .mud-button-outlined.mud-button-primary:hover {
    background: rgba(255,107,53,0.05) !important;
    border-color: var(--accent) !important;
}

.dashboard-layout-twins .mud-button-text.mud-button-primary {
    color: var(--accent) !important;
}

.dashboard-layout-twins .mud-button-text.mud-button-primary:hover {
    background: rgba(255,107,53,0.05) !important;
}

/* Dashboard MudDataGrid overrides */
.dashboard-layout-twins .mud-data-grid {
    background: transparent !important;
    box-shadow: none !important;
}

.dashboard-layout-twins .mud-data-grid .mud-table-head .mud-table-cell {
    background: rgba(255,107,53,0.04) !important;
    font-weight: 600;
    color: var(--text) !important;
    border-bottom: 1px solid var(--glass-border) !important;
}

.dashboard-layout-twins .mud-data-grid .mud-table-body .mud-table-row:hover {
    background: rgba(255,107,53,0.03) !important;
}

.dashboard-layout-twins .mud-data-grid .mud-table-cell {
    border-bottom: 1px solid rgba(0,0,0,0.04) !important;
}

/* Dashboard MudChip overrides */
.dashboard-layout-twins .mud-chip {
    font-weight: 600;
    letter-spacing: 0.01em;
}

/* Dashboard MudAlert overrides */
.dashboard-layout-twins .mud-alert {
    border-radius: 16px !important;
    backdrop-filter: blur(8px);
}

/* Dashboard form fields — visible borders & text */
.dashboard-layout-twins .mud-input-outlined .mud-input-outlined-border {
    border-color: var(--border) !important;
    border-width: 1.5px !important;
    border-radius: 12px !important;
}

.dashboard-layout-twins .mud-input-outlined:hover .mud-input-outlined-border {
    border-color: rgba(255,107,53,0.4) !important;
}

.dashboard-layout-twins .mud-input-outlined.mud-input-focused .mud-input-outlined-border {
    border-color: var(--accent) !important;
    border-width: 2px !important;
    box-shadow: 0 0 0 3px rgba(255,107,53,0.1) !important;
}

/* Dashboard input — background, text, label */
.dashboard-layout-twins .mud-input.mud-input-outlined .mud-input-slot {
    background: var(--bg, #FAFAFA) !important;
    border-radius: 12px !important;
    color: var(--text, #1a1a1a) !important;
}

.dashboard-layout-twins .mud-input-label,
.dashboard-layout-twins .mud-input-label-outlined,
.dashboard-layout-twins .mud-input-label-inputcontrol,
.dashboard-layout-twins label.mud-input-label {
    color: var(--text-light, #666) !important;
    opacity: 1 !important;
}

.dashboard-layout-twins .mud-input-label-outlined.mud-input-label-animated {
    background: var(--bg-card, #FFFFFF) !important;
    padding: 0 6px !important;
}

.dashboard-layout-twins .mud-input.mud-input-outlined input,
.dashboard-layout-twins .mud-input.mud-input-outlined textarea {
    color: var(--text, #1a1a1a) !important;
    -webkit-text-fill-color: var(--text, #1a1a1a) !important;
}

.dashboard-layout-twins .mud-input.mud-input-outlined input::placeholder,
.dashboard-layout-twins .mud-input.mud-input-outlined textarea::placeholder {
    color: var(--text-muted, #999) !important;
    opacity: 0.7 !important;
}

.dashboard-layout-twins .mud-input.mud-input-outlined input:disabled,
.dashboard-layout-twins .mud-input.mud-input-outlined textarea:disabled {
    color: var(--text-light, #666) !important;
    -webkit-text-fill-color: var(--text-light, #666) !important;
    opacity: 0.65 !important;
}

/* Helper text under inputs */
.dashboard-layout-twins .mud-input-helper-text {
    color: var(--text-light, #666) !important;
}

/* Select / dropdown in dashboard */
.dashboard-layout-twins .mud-select .mud-input-slot {
    color: var(--text, #1a1a1a) !important;
}

.dashboard-layout-twins .mud-select-input {
    color: var(--text, #1a1a1a) !important;
}

/* === AUTH PAGES === */
.auth-container {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

.auth-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    padding: 3rem;
    width: 100%;
    max-width: min(440px, calc(100vw - 4rem));
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-lg);
}

.auth-card h1 { font-family: var(--font-heading); font-size: 2rem; font-weight: 700; margin-bottom: 0.5rem; text-align: center; }
.auth-card p { color: var(--text-light); text-align: center; margin-bottom: 2rem; }

.auth-form { display: flex; flex-direction: column; gap: 1.5rem; }

.form-group { display: flex; flex-direction: column; gap: 0.5rem; }
.form-group label { font-weight: 600; font-size: 0.9rem; color: var(--text); }
.form-group input {
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-family: var(--font-body);
    transition: var(--transition);
    background: var(--bg);
}
.form-group input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-light); }

.auth-divider { text-align: center; color: var(--text-muted); font-size: 0.9rem; position: relative; margin: 1rem 0; }
.auth-divider::before, .auth-divider::after { content: ''; position: absolute; top: 50%; width: 40%; height: 1px; background: var(--border); }
.auth-divider::before { left: 0; }
.auth-divider::after { right: 0; }

.auth-link { text-align: center; margin-top: 1.5rem; color: var(--text-light); }
.auth-link a { color: var(--accent); text-decoration: none; font-weight: 600; }
.auth-link a:hover { text-decoration: underline; }

/* === MUDBLAZOR OVERRIDES === */
.mud-typography { font-family: var(--font-body) !important; }

.mud-typography-h1, .mud-typography-h2, .mud-typography-h3,
.mud-typography-h4, .mud-typography-h5, .mud-typography-h6 {
    font-family: var(--font-heading) !important;
    letter-spacing: -0.02em !important;
}

.mud-button {
    font-family: var(--font-body) !important;
    text-transform: none !important;
    font-weight: 600 !important;
    border-radius: 100px !important;
    transition: var(--transition) !important;
}

.mud-button-filled-primary { background: var(--text) !important; }
.mud-button-filled-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-md) !important; }

.mud-button-filled-secondary { background: var(--accent) !important; }
.mud-button-filled-secondary:hover { transform: translateY(-2px); box-shadow: var(--shadow-accent) !important; }

.mud-card {
    border-radius: var(--radius-lg) !important;
    border: 1px solid var(--border-light) !important;
    box-shadow: none !important;
    transition: var(--transition) !important;
}

.mud-card:hover { box-shadow: var(--shadow-md) !important; }

.mud-input, .mud-input-control { font-family: var(--font-body) !important; }
.mud-input-outlined .mud-input-slot { border-radius: var(--radius-md) !important; }

/* MudPaper glassmorphism in dashboard */
.mud-layout .mud-paper,
.dashboard-main .mud-paper {
    background: var(--glass-bg) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;
    border: 1px solid var(--glass-border) !important;
    box-shadow: var(--glass-shadow) !important;
    transition: var(--transition) !important;
}

.mud-table {
    border-radius: var(--radius-lg) !important;
    overflow: hidden;
}

.mud-table .mud-table-head .mud-table-row .mud-table-cell {
    font-weight: 600 !important;
    font-size: 0.85rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    color: var(--text-light) !important;
}

/* MudTabs styled as filter pills */
.mud-tabs .mud-tab {
    border-radius: 100px !important;
    font-weight: 500 !important;
    text-transform: none !important;
    min-width: auto !important;
    padding: 0.5rem 1.5rem !important;
    transition: all 0.3s var(--ease) !important;
}

.mud-tabs .mud-tab.mud-tab-active {
    background: var(--text) !important;
    color: white !important;
}

.mud-tabs .mud-tabs-toolbar { border-bottom: none !important; }
.mud-tab-slider { display: none !important; }

.mud-drawer { background: rgba(255,255,255,0.7) !important; backdrop-filter: blur(20px) !important; }

.mud-nav-link {
    border-radius: var(--radius-md) !important;
    margin: 0.25rem 0.5rem !important;
    transition: var(--transition) !important;
}

.mud-nav-link:hover { background: var(--bg-alt) !important; }
.mud-nav-link.active { background: var(--accent-light) !important; color: var(--accent) !important; }

/* MudTextField accent focus */
.mud-input-outlined:focus-within .mud-input-slot {
    border-color: var(--accent) !important;
    box-shadow: 0 0 0 3px rgba(255,107,53,0.1) !important;
}

/* MudChip pill style */
.mud-chip {
    border-radius: 100px !important;
    font-weight: 500 !important;
}

.mud-dialog { border-radius: var(--radius-xl) !important; }
.mud-snackbar { border-radius: var(--radius-md) !important; }

/* === ANIMATIONS === */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.animate-fade-in-up { animation: fadeInUp 0.6s ease-out both; }
.animate-fade-in { animation: fadeIn 0.5s ease-out both; }
.animate-slide-in-left { animation: slideInLeft 0.5s ease-out both; }
.animate-scale-in { animation: scaleIn 0.4s ease-out both; }

.page-transition { animation: pageIn 0.35s ease-out both; }

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

/* Animation Delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }

/* === UTILITIES === */
.container-twins { max-width: 1400px; margin: 0 auto; padding: 0 2rem; }
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.gap-4 { gap: 2rem; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }
.w-full { width: 100%; }
.h-full { height: 100%; }
.relative { position: relative; }
.z-1 { z-index: 1; }

/* Content wrapper for dashboard pages */
.content-wrapper-twins {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .card-grid { grid-template-columns: 1fr 1fr; }
    .section-white { margin: 0 1rem; padding: 3rem 2rem; }
    .cta-section-twins { margin: 2rem 1rem; padding: 4rem 2rem; }
    .contact-grid { grid-template-columns: 1fr; }
    .course-row { flex-direction: column; }
    .course-gradient { width: 100%; height: 160px; }
    .levels-grid { grid-template-columns: repeat(3, 1fr); }
    .includes-grid { grid-template-columns: repeat(2, 1fr); }
    .teacher-row { flex-direction: column !important; text-align: center; gap: 2rem; padding: 2.5rem 0; }
    .teacher-row-header { justify-content: center; }
    .teacher-footer { justify-content: center; }
    .teacher-bio, .teacher-quote { max-width: 100%; margin-left: auto; margin-right: auto; }
    .teacher-row-avatar { margin: 0 auto; }

    .dashboard-sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    .dashboard-sidebar.open { transform: translateX(0); }
    .dashboard-main { margin-left: 0; }
}

@media (max-width: 768px) {
    .hero { min-height: auto; padding: 5rem 0 4rem; }
    .hero-content { padding: 0 2rem !important; }
    .hero-title { letter-spacing: -1px; }
    .hero-actions { flex-direction: column; align-items: center; }
    .card-grid { grid-template-columns: 1fr 1fr; }
    .counter-bar { gap: 2rem; flex-wrap: wrap; margin-top: -2rem; }
    .scroll-hint { display: none; }
    .testimonials-grid { grid-template-columns: 1fr 1fr; }
    .testimonial-card.featured.visible { transform: translateY(0); }
    .advantage-row { gap: 1.5rem; padding: 1.5rem 1rem; }
    .advantage-num { font-size: 2.5rem; min-width: 48px; }
    .navbar-twins { padding: 1rem 1.5rem; }
    .nav-links { display: none; }
    .section { padding: 4rem 1.5rem; }
    .section-twins { padding: 4rem 1.5rem; }
    .auth-card { padding: 2rem; }
    .dark-block { margin: 0 1rem 2rem; border-radius: 24px; }
    .stats-bar-inner { grid-template-columns: repeat(2, 1fr); }
    .story-row { flex-direction: column; gap: 2rem; }
    .story-visual { width: 100%; height: 200px; }
}

@media (max-width: 480px) {
    .hero-title { font-size: 2.2rem; }
    .hero-cta, .hero-actions { flex-direction: column; width: 100%; }
    .btn-primary, .btn-secondary, .btn-accent, .btn-outline { width: 100%; justify-content: center; }
    .btn-shimmer, .btn-ghost { width: 100%; justify-content: center; }
    .stat-value { font-size: 2.5rem; }
    .card-grid { grid-template-columns: 1fr; }
    .courses-grid { grid-template-columns: 1fr; }
    .counter-bar { flex-direction: column; gap: 1rem; margin-top: -1rem; padding: 1.5rem 2rem; }
    .testimonials-grid { grid-template-columns: 1fr; }
    .advantage-row { flex-direction: column; gap: 0.5rem; }
    .timeline { padding-left: 48px; }
    .timeline-dot { left: -48px; width: 34px; height: 34px; }
    .timeline::before { left: 16px; }
    .stats-bar-inner { grid-template-columns: repeat(2, 1fr); }
    .levels-grid { grid-template-columns: repeat(2, 1fr); }
    .includes-grid { grid-template-columns: 1fr; }
    .levels { margin: 0 1rem 2rem; border-radius: 24px; }
}

/* === DASHBOARD RESPONSIVE === */
@media (max-width: 768px) {
    .dashboard-grid { grid-template-columns: 1fr; }
    .dash-page-header h1 { font-size: 1.5rem; }
    .dashboard-card, .dashboard-stat-card { padding: 1.25rem; }
    .dash-list-item { padding: 1rem 1.25rem; }
    .quick-action-btn { padding: 0.75rem 1rem; font-size: 0.9rem; }
    .dash-stat-value { font-size: 2rem; }
    .dash-level-circle { width: 64px; height: 64px; font-size: 1.4rem; }
    .templates-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    .dash-page-header h1 { font-size: 1.3rem; }
    .dash-icon-box { width: 40px; height: 40px; border-radius: 10px; }
    .dash-icon-box.lg { width: 56px; height: 56px; }
    .dash-badge { font-size: 0.75rem; padding: 0.25rem 0.6rem; }
}

/* === SCROLLBAR === */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-alt); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-light); }

/* === ZOOM-SAFE === */
img, video, iframe, svg, canvas { max-width: 100%; height: auto; }
.mud-layout { min-width: 0; }
.mud-main-content { min-width: 0; overflow-x: hidden; }

/* === MOBILE UTILITY CLASSES === */
/*
  Standardized breakpoints:
  - 480px  : phone (small)
  - 768px  : tablet / phone (large)
  - 1024px : iPad / small laptop
  - 1200px : desktop
*/

@media (max-width: 768px) {
    .hide-mobile { display: none !important; }
    .show-mobile { display: block !important; }
    .show-mobile-flex { display: flex !important; }
    .mobile-stack { flex-direction: column !important; }
    .mobile-full-width { width: 100% !important; max-width: 100% !important; }
    .mobile-p-1 { padding: 0.75rem !important; }
    .mobile-p-05 { padding: 0.5rem !important; }
    .mobile-gap-1 { gap: 0.75rem !important; }
    .mobile-text-sm { font-size: 0.875rem !important; }
}

@media (min-width: 769px) {
    .show-mobile { display: none !important; }
    .show-mobile-flex { display: none !important; }
}

@media (max-width: 1024px) {
    .hide-tablet { display: none !important; }
    .show-tablet { display: block !important; }
    .show-tablet-flex { display: flex !important; }
    .tablet-stack { flex-direction: column !important; }
}

@media (min-width: 1025px) {
    .show-tablet { display: none !important; }
    .show-tablet-flex { display: none !important; }
}

/* === MUDBLAZOR MOBILE OVERRIDES === */
@media (max-width: 768px) {
    /* MudDialog fullscreen on mobile */
    .mud-dialog {
        margin: 0 !important;
        max-height: 100vh !important;
        max-height: 100dvh !important;
        height: 100vh !important;
        height: 100dvh !important;
        width: 100vw !important;
        max-width: 100vw !important;
        border-radius: 0 !important;
    }

    .mud-dialog .mud-dialog-content {
        max-height: calc(100dvh - 130px) !important;
        overflow-y: auto !important;
    }

    .mud-dialog-container {
        align-items: stretch !important;
    }

    /* MudTabs horizontal scroll on mobile */
    .mud-tabs .mud-tabs-toolbar {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        flex-wrap: nowrap !important;
    }

    .mud-tabs .mud-tabs-toolbar::-webkit-scrollbar {
        display: none;
    }

    .mud-tabs .mud-tab {
        white-space: nowrap !important;
        flex-shrink: 0 !important;
        padding: 0.4rem 1rem !important;
        font-size: 0.85rem !important;
    }

    /* MudTable: reduce cell padding on mobile */
    .mud-table .mud-table-cell {
        padding: 0.5rem 0.75rem !important;
        font-size: 0.85rem !important;
    }

    .mud-table .mud-table-head .mud-table-row .mud-table-cell {
        font-size: 0.75rem !important;
        padding: 0.5rem 0.75rem !important;
    }

    /* MudDataGrid: scrollable container */
    .mud-data-grid .mud-table-container {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
    }

    /* Touch-friendly button sizes */
    .mud-button {
        min-height: 44px !important;
    }

    .mud-icon-button {
        min-width: 44px !important;
        min-height: 44px !important;
    }

    /* Table fixed height adjustment for mobile */
    .mud-table[style*="height:600px"],
    .mud-table[style*="height: 600px"] {
        max-height: 60vh !important;
    }

    /* Main dash inner reduce padding on mobile */
    .main-dash-inner {
        padding: 1rem !important;
    }

    /* Content wrapper reduce padding */
    .content-wrapper-twins {
        padding: 0 1rem;
    }

    .container-twins {
        padding: 0 1rem;
    }
}

@media (max-width: 480px) {
    .main-dash-inner {
        padding: 0.75rem !important;
    }

    .mud-dialog .mud-dialog-title {
        font-size: 1.1rem !important;
        padding: 1rem !important;
    }

    .mud-dialog .mud-dialog-actions {
        padding: 0.75rem 1rem !important;
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .mud-dialog .mud-dialog-actions .mud-button {
        flex: 1 1 auto;
    }
}

/* === iPad SPECIFIC === */
@media (min-width: 769px) and (max-width: 1024px) {
    .main-dash-inner {
        padding: 1.5rem !important;
    }

    /* Sidebar on iPad: show collapsed by default */
    .sidebar-dash {
        width: var(--sidebar-collapsed);
    }
}

/* === HOMEWORK — MOBILE TOUCH OPTIMIZATIONS === */
@media (max-width: 768px) {
    .hw-card {
        padding: 1rem;
        border-radius: 12px;
    }

    .hw-exercise-card {
        flex-direction: column;
        gap: 0.5rem;
        padding: 0.75rem;
    }

    .hw-exercise-drag {
        flex-direction: row;
        gap: 0.25rem;
    }

    .hw-exercise-editor {
        padding: 1rem;
    }

    .hw-type-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 0.5rem;
    }

    .hw-type-card {
        padding: 0.75rem 0.5rem;
    }

    .hw-type-icon {
        width: 36px;
        height: 36px;
        border-radius: 8px;
    }

    .hw-studio-bottombar {
        padding: 0.5rem 1rem;
        flex-direction: column;
        gap: 0.5rem;
    }

    .hw-material-chip {
        font-size: 0.8rem;
        padding: 0.4rem 0.6rem;
    }

    .hw-student-row {
        padding: 0.6rem 0.75rem;
        min-height: 48px;
    }

    .hw-summary-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }

    .hw-exercise-card .mud-input,
    .hw-exercise-editor .mud-input {
        font-size: 16px !important;
    }

    .hw-exercise-card .mud-radio .mud-radio-content {
        min-height: 44px;
        display: flex;
        align-items: center;
    }

    .homework-progress-bar {
        position: sticky;
        top: 0;
        z-index: 10;
        background: var(--bg-card, white);
        padding: 0.75rem 1rem;
        border-bottom: 1px solid var(--border, #e5e5e5);
    }
}

@media (max-width: 480px) {
    .hw-type-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .hw-summary-grid {
        grid-template-columns: 1fr;
    }
}

/* === VIDEO LESSON — MOBILE TOUCH OPTIMIZATIONS === */
@media (max-width: 768px) {
    .vl-material-card {
        min-height: 52px;
        -webkit-tap-highlight-color: transparent;
    }

    .vl-participant {
        min-height: 44px;
    }

    .vl-exercise-card .mud-radio .mud-radio-content {
        min-height: 44px;
        display: flex;
        align-items: center;
    }

    .vl-exercise-card .mud-input {
        font-size: 16px !important;
    }
}

/* === iOS SAFARI FIXES === */
@supports (padding: env(safe-area-inset-top)) {
    .video-lesson-container {
        padding-top: env(safe-area-inset-top);
        padding-bottom: env(safe-area-inset-bottom);
        padding-left: env(safe-area-inset-left);
        padding-right: env(safe-area-inset-right);
    }

    .vl-topbar {
        padding-top: max(0.5rem, env(safe-area-inset-top));
    }

    .vl-exercise-overlay {
        bottom: max(1rem, env(safe-area-inset-bottom));
    }
}

/* === PRINT === */
@media print {
    .bg-shapes, .bg-shapes-dashboard,
    #mesh-bg, .navbar-twins, .footer-twins { display: none !important; }
    body::after { display: none !important; }
}
