/* =====================================================
   HeyyGuru Student Portal — Global CSS
   ===================================================== */

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

:root {
    --brand-dark: #2A75B8;
    --brand-color: #4DA2FF; /* HeyyGuru Blue */
    --brand-light: #E1F0FD;
    --brand-glow: rgba(59, 150, 233, 0.1);
    
    --text: #000000;      /* Bold Black for White Canvas */
    --text-heading: #000000;
    --text-mid: #4A5568;
    --text-light: #718096;
    --text-hover: #4DA2FF;
    
    --r: 18px;          /* Minimalist rounding */
    --r-sm: 10px;
    
    /* Antigravity Lift: Weightless Shadows (Phase 9) */
    --sh: 0 4px 30px rgba(0, 0, 0, 0.03); /* Refined to brand spec */
    --sh-premium: 0 20px 40px rgba(0, 0, 0, 0.05); 
    
    /* Deep Charcoal for visibility */
    --text-charcoal: #222222;
    
    /* Dual-Tone Accents */
    --green: #00C853;
    --red: #FF4D4D; /* More vibrant action red */
    --amber: #FFD600;
    --blue: #2979FF;
    
    /* Royal Gold Gradient (Phase 9) */
    --gold-grad: linear-gradient(135deg, #6366f1 0%, #4DA2FF 50%, #7c3aed 100%);
    --gold-glow: 0 0 15px rgba(59, 150, 233, 0.3);
    
    --brand-pill: linear-gradient(135deg, #4DA2FF 0%, #2979FF 100%);
    /* Dual-Tone Progress Bar */
    --prog-grad: linear-gradient(90deg, #4DA2FF 0%, #00E5FF 100%);
}

/* Antigravity Custom Animations */
@keyframes pulsing-flame {
    0% { transform: scale(1); filter: drop-shadow(0 0 5px rgba(59, 150, 233, 0.4)); }
    50% { transform: scale(1.15); filter: drop-shadow(0 0 15px rgba(59, 150, 233, 0.8)); }
    100% { transform: scale(1); filter: drop-shadow(0 0 5px rgba(59, 150, 233, 0.4)); }
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

body {
    margin: 0;
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    background: var(--bg-alt); /* Use the alt background for better glassmorphism contrast */
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}


/* ── Dark Mode Support ──────────────────────────── */
body.dark-mode {
    --bg: #0f172a;
    --card: #1e293b;
    --border: #334155;
    --text: #f8fafc;
    --text-mid: #94a3b8;
    --text-light: #64748b;
    --blue-light: rgba(59, 150, 233, 0.15);
    --nav-bg: rgba(30, 41, 59, 0.8);
    --sh: 0 8px 24px rgba(0, 0, 0, 0.3);
    --glass-bg: rgba(30, 41, 59, 0.8);
    --glass-border: rgba(255, 255, 255, 0.08);
}

.theme-transition,
.theme-transition *,
.theme-transition *:before,
.theme-transition *:after {
    transition: all 0.3s ease !important;
    transition-delay: 0s !important;
}

body.dark-mode .s-card-header { background: #1e293b; border-bottom-color: #334155; }
body.dark-mode .quick-link { background: #1e293b; border-color: #334155; }
body.dark-mode .quick-icon { background: rgba(255,255,255,0.05) !important; }
body.dark-mode .quick-label { color: #cbd5e1; }
body.dark-mode .ann-row { border-bottom-color: #334155; }
body.dark-mode .ann-row:hover { background: #334155; }

/* ── Unified Page Background ────────────────────── */
.antigravity-bg {
    background-color: var(--bg);
    min-height: 100vh;
}

/* ── Antigravity Visual Utilities ─────────────── */

/* Glassmorphism */
.glass {
    background: #FFFFFF;
    border: none;
    box-shadow: var(--sh-premium);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.glass:hover {
    transform: translateY(-4px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.12);
}

/* Glow Effects */
.glow-purple { box-shadow: 0 10px 30px -5px var(--purple-glow); }
.glow-blue { box-shadow: 0 10px 30px -5px var(--blue-glow); }
.glow-amber { box-shadow: 0 10px 30px -5px var(--amber-glow); }
.glow-green { box-shadow: 0 10px 30px -5px var(--green-glow); }

/* Minimalist Hero */
.hero-minimal {
    padding: 60px 40px;
    background: var(--brand-color);
    background-image: var(--hero-grad);
    border-radius: var(--r);
    border: 1px solid rgba(255, 255, 255, 0.2);
    margin-bottom: 40px;
    position: relative;
    overflow: hidden;
    color: #fff;
}
.hero-minimal h1 { font-size: 42px; font-weight: 900; color: #fff; margin-bottom: 12px; letter-spacing: -1px; }
.hero-minimal p { font-size: 18px; color: rgba(255, 255, 255, 0.9); font-weight: 500; }
/* Antigravity Components */
.prog-bar-dual {
    height: 8px;
    border-radius: 99px;
    background: #EDF2F7;
    overflow: hidden;
    position: relative;
}
.prog-fill-grad {
    height: 100%;
    background: var(--prog-grad);
    border-radius: 99px;
    transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.gold-pill {
    background: var(--gold-grad);
    color: #fff;
    padding: 6px 16px;
    border-radius: 99px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
    box-shadow: 0 10px 15px -3px rgba(255, 215, 0, 0.3);
}

/* 3D Spinning Coin Polish (Phase 10) */
@keyframes coin-spin-3d {
    0% { transform: rotateY(0deg) scale(1); filter: drop-shadow(0 0 5px rgba(255, 215, 0, 0.4)); }
    50% { transform: rotateY(180deg) scale(1.05); filter: drop-shadow(0 0 12px rgba(255, 215, 0, 0.7)); }
    100% { transform: rotateY(360deg) scale(1); filter: drop-shadow(0 0 5px rgba(255, 215, 0, 0.4)); }
}
.coin-3d { 
    animation: coin-spin-3d 3s infinite linear; 
    transform-style: preserve-3d;
}

/* Achievement Card & Quest Elements */
.achievement-card {
    background: #FFFFFF;
    border-radius: 20px;
    padding: 20px 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    border: 1.5px solid var(--border);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
}
.achievement-card:hover {
    transform: translateX(8px) scale(1.01);
    border-color: var(--brand-color);
    box-shadow: var(--sh-premium);
}
.achievement-card.completed {
    background: #f0fdf4;
    border-color: #10b981;
}

.quest-status-ring {
    width: 60px;
    height: 60px;
    position: relative;
}

.knowledge-tag {
    background: linear-gradient(90deg, #6366f1, #a855f7);
    color: #fff;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    display: inline-block;
}


/* Day Tabs System */
.day-tab-strip {
    display: flex;
    overflow-x: auto;
    gap: 8px;
    padding: 4px 4px 12px 4px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.day-tab-strip::-webkit-scrollbar { display: none; }

.day-tab {
    padding: 8px 16px;
    background: #F1F5F9;
    color: #475569;
    border-radius: 99px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    transition: 0.3s;
    border: 1.5px solid transparent;
}
.day-tab.active {
    background: var(--brand-color);
    color: #fff;
    box-shadow: 0 4px 12px rgba(59, 150, 233, 0.2);
}
.day-tab:hover:not(.active) {
    background: #E2E8F0;
    transform: translateY(-2px);
}

.quest-item.fade-out {
    opacity: 0;
    transform: translateY(10px);
}
.quest-item.fade-in {
    animation: achievementFadeIn 0.5s forwards;
}
@keyframes achievementFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ── Modern LMS Utilities ─────────────────────────── */
.lms-card {
    background: var(--card);
    border-radius: var(--r-sm);
    border: 1px solid var(--border);
    box-shadow: var(--sh);
    padding: 24px;
    transition: all 0.3s ease;
}
.lms-card:hover {
    box-shadow: var(--sh-premium);
    transform: translateY(-2px);
}

.lms-grid-12 { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; }
.lms-span-8 { grid-column: span 8; }
.lms-span-4 { grid-column: span 4; }
.lms-span-12 { grid-column: span 12; }

@media (max-width: 900px) {
    .lms-span-8, .lms-span-4 { grid-column: span 12; }
}

/* Mesh Gradient Hero */
.hero-mesh-premium {
    background: linear-gradient(135deg, #4DA2FF 0%, #7c3aed 100%);
    background-image: 
        radial-gradient(at 0% 0%, hsla(253,16%,7%,1) 0, transparent 50%), 
        radial-gradient(at 50% 0%, hsla(225,39%,30%,1) 0, transparent 50%), 
        radial-gradient(at 100% 0%, hsla(339,49%,30%,1) 0, transparent 50%);
    box-shadow: 0 20px 40px rgba(59, 150, 233, 0.2);
    color: #fff !important;
}

/* Pulsing Flame */
.streak-pulse {
    animation: flame-pulse 1.5s infinite ease-in-out;
}

@keyframes flame-pulse {
    0%, 100% { transform: scale(1); filter: drop-shadow(0 0 5px #ff4d00) brightness(1); }
    50% { transform: scale(1.15); filter: drop-shadow(0 0 15px #ff9e00) brightness(1.3); }
}


/* Mobile Optimizations */
@media (max-width: 768px) {
    .metric-val {
        font-size: 32px !important;
        font-weight: 900;
    }
}

/* ── Unified Dashboard Tokens ─────────────────────── */
.st-welcome-card {
    background: linear-gradient(130deg, #1e1b4b, #4338ca);
    color: #ffffff;
    padding: 32px;
    border-radius: 16px;
    position: relative;
    overflow: hidden;
}
.st-welcome-card::after {
    content: "";
    position: absolute;
    right: -20px;
    top: -20px;
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
}

/* Purged Legacy Grids */

/* ── Reset & Core ─────────────────────────────────── */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    background: var(--bg);
    font-family: 'Plus Jakarta Sans', sans-serif;
    color: var(--text);
    min-height: 100vh;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; transition: all 0.2s; }
img { max-width: 100%; height: auto; }

/* ── Layout ───────────────────────────────────────── */
.s-main { max-width: 1120px; margin: 0 auto; padding: 28px 20px; }

/* ── Grid System ──────────────────────────────────── */
.s-grid   { display: grid; gap: 20px; margin-bottom: 20px; }
.s-grid-1 { display: grid; grid-template-columns: 1fr; gap: 20px; margin-bottom: 20px; }
.s-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-bottom: 20px; }
.s-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-bottom: 20px; }
.s-grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 20px; }
.s-grid-auto { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.s-scroll-x { display: flex; overflow-x: auto; gap: 12px; scroll-behavior: smooth; padding-bottom: 8px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.s-scroll-x::-webkit-scrollbar { display: none; }

/* Legacy grid aliases used in dashboard */
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 22px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 22px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-bottom: 22px; }

/* ── Cards ────────────────────────────────────────── */
.s-card {
    background: var(--card);
    border-radius: var(--r);
    border: 1.5px solid var(--border);
    box-shadow: var(--sh);
    overflow: hidden;
    margin-bottom: 20px;
    transition: box-shadow 0.25s, transform 0.25s;
}
.s-card:hover { box-shadow: var(--sh-hover); transform: translateY(-4px); }
.s-card-header {
    padding: 16px 22px;
    border-bottom: 1.5px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: #fafbff;
}
.s-card-title { font-size: 15px; font-weight: 900; color: var(--text); }
.s-card-body  { padding: 20px; }

.see-all {
    font-size: 12.5px;
    font-weight: 800;
    color: var(--blue);
    white-space: nowrap;
}
.see-all:hover { opacity: 0.75; }

/* ── Hero Banner ─────────────────────────────────── */
.s-hero {
    border-radius: var(--r);
    padding: 30px 32px;
    color: #fff;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(130deg, #1e1b4b 0%, #4338ca 50%, #7c3aed 100%);
    box-shadow: 0 12px 40px rgba(59, 150, 233, 0.28);
}
.s-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 50%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,.07) 0%, transparent 65%);
    pointer-events: none;
}
.s-hero h1  { font-size: 28px; font-weight: 900; margin-bottom: 4px; line-height: 1.2; }
.s-hero p   { font-size: 14px; opacity: .8; font-weight: 600; }
.hero-deco  { position: absolute; right: 28px; top: 15%; font-size: 80px; opacity: .8; pointer-events: none; }

.hero-stats     { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; justify-content: flex-start; }
.hero-stat,
.s-hero-stat    { background: rgba(255,255,255,.13); backdrop-filter: blur(8px); border: 1px solid rgba(255,255,255,.22); border-radius: 16px; padding: 12px 18px; text-align: center; min-width: 88px; flex: 1 1 auto; max-width: max-content; }
.s-hero-stat-num { font-size: 24px; font-weight: 900; }
.s-hero-stat-lbl { font-size: 10px; font-weight: 700; opacity: .75; text-transform: uppercase; letter-spacing: .5px; margin-top: 2px; }

/* ── Badges ──────────────────────────────────────── */
.s-badge        { display: inline-flex; align-items: center; padding: 4px 12px; border-radius: 99px; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; }
.s-badge-blue   { background: var(--blue-light); color: var(--blue); }
.s-badge-green  { background: var(--green-light); color: var(--green); }
.s-badge-amber  { background: var(--amber-light); color: var(--amber); }
.s-badge-red    { background: #fee2e2; color: #ef4444; }
.s-badge-gray   { background: #f1f5f9; color: #475569; }

/* Proper Clean Contrast Pills */
.pill-contrast {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 800;
}
.pill-amber-contrast { background: #fffbeb; color: #92400e; border: 1px solid #fef08a; }
.pill-blue-contrast { background: #eef2ff; color: #4338ca; border: 1px solid #c7d2fe; }
.pill-purple-contrast { background: #f5f3ff; color: #6d28d9; border: 1px solid #ddd6fe; }
.pill-green-contrast { background: #f0fdf4; color: #15803d; border: 1px solid #bbf7d0; }

/* ── Quick Links ─────────────────────────────────── */
.quick-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 18px 10px;
    border-radius: 18px;
    background: var(--card);
    border: 1.5px solid var(--border);
    box-shadow: var(--sh);
    position: relative;
    transition: all 0.2s cubic-bezier(.4,0,.2,1);
    cursor: pointer;
    color: var(--text);
}
.quick-link:hover { transform: translateY(-4px); box-shadow: var(--sh-hover); border-color: #c7d2fe; }
.quick-icon  { font-size: 28px; }
.quick-label { font-size: 11.5px; font-weight: 800; color: var(--text-mid); text-align: center; }
.quick-badge {
    position: absolute;
    top: -8px; right: -8px;
    background: var(--red);
    color: #fff;
    font-size: 10px;
    font-weight: 900;
    min-width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(239,68,68,.4);
}

/* ── Row Items (homework, notes, announcements) ───── */
.ann-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1.5px solid #f8fafc;
    transition: background .15s;
}
.ann-row:last-child { border-bottom: none; }
.ann-row:hover { background: #f8fafc; border-radius: 10px; padding-left: 8px; }
.ann-title { font-size: 13.5px; font-weight: 800; margin-bottom: 2px; }
.ann-msg   { font-size: 12px; color: var(--text-mid); font-weight: 600; }
.ann-time  { font-size: 11px; color: var(--text-light); font-weight: 700; margin-top: 4px; }

/* ── Quiz Rows ────────────────────────────────────── */
.quiz-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1.5px solid #f8fafc;
}
.quiz-row:last-child { border-bottom: none; }

/* ── Empty States ─────────────────────────────────── */
.empty { text-align: center; padding: 28px 16px; color: var(--text-light); }
.empty-icon { font-size: 40px; margin-bottom: 10px; }

/* ── Timetable rows ──────────────────────────────── */
.slot-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1.5px solid var(--border); }
.slot-row:last-child { border-bottom: none; }
.slot-time { min-width: 85px; font-size: 12px; font-weight: 800; color: var(--blue); }
.subj-pill { display: inline-flex; padding: 4px 12px; border-radius: 99px; font-size: 12px; font-weight: 800; }

/* ── Lecture Grid ─────────────────────────────────── */
.lec-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.lec-card { border-radius: 12px; overflow: hidden; border: 1.5px solid var(--border); transition: all 0.2s; }
.lec-card:hover { transform: translateY(-3px); border-color: var(--blue-glow); }

/* ── Subject Palette ─────────────────────────────── */
.color-0 { background: #eef2ff; color: #4338ca; }
.color-1 { background: #fef3c7; color: #92400e; }
.color-2 { background: #dcfce7; color: #15803d; }
.color-3 { background: #fce7f3; color: #be185d; }
.color-4 { background: #f0f9ff; color: #0369a1; }
.color-5 { background: #fdf4ff; color: #7e22ce; }

/* ════════════════════════════════════════════════════
   AWESOME NAVIGATION BAR
   ════════════════════════════════════════════════════ */
.hg-bar {
    position: sticky;
    top: 0;
    z-index: 500;
    background: rgba(255, 255, 255, 0.8); /* Refined transparency */
    backdrop-filter: blur(20px); /* Refined blur */
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    height: 72px; 
    padding: 0 5%; /* Adjusted padding per brand request */
    gap: 32px; /* gap-8 between main sections */
    border-bottom: 1px solid rgba(0,0,0,0.05); /* Softer border */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    transition: all 0.4s ease;
}

/* Logo Section */
.hg-logo { 
    display: flex; 
    align-items: center; 
    gap: 12px; 
    flex-shrink: 0; 
    text-decoration: none;
    transition: transform 0.2s;
}
.hg-logo:hover { transform: scale(1.02); }
.hg-lt {
    font-size: 22px;
    font-weight: 950;
    letter-spacing: -1px;
    color: #4DA2FF;
}

/* Awesome Nav Links */
.hg-nav {
    display: flex;
    align-items: center;
    gap: 2px;
    flex: 1;
    justify-content: center;
    overflow-x: auto;
    scrollbar-width: none;
}
.hg-nav::-webkit-scrollbar { display: none; }
.hg-lnk {
    color: var(--text-mid);
    font-size: 13px;
    font-weight: 700;
    padding: 8px 12px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 8px; /* gap-2 between icon and text */
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    position: relative;
    white-space: nowrap;
}
.hg-lnk svg { flex-shrink: 0; width: 16px; height: 16px; }
.hg-lnk:hover {
    color: var(--blue);
    background: var(--blue-light);
}
.hg-lnk.ha {
    color: #fff;
    background: var(--brand-color);
    padding: 8px 16px;
    border-radius: 50px;
}
.hg-lnk.ha::after { display: none; }

.hg-nav-toggle {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--blue-light);
    border: 1px solid var(--border);
    color: var(--blue);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    margin-right: 8px;
}
.hg-nav-toggle:hover { transform: scale(1.1); background: var(--blue); color: #fff; }


/* Awesome Right Section */
.hg-rt { 
    display: flex; 
    align-items: center; 
    gap: 12px; 
    flex-shrink: 0; 
    margin-left: auto;
}
.hg-coin {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff8eb !important;
    color: #b45309 !important;
    border: 1.5px solid #fef3c7 !important;
    padding: 8px 16px !important;
    border-radius: 14px !important;
    font-size: 14px;
    font-weight: 800;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 10px rgba(245, 158, 11, 0.1) !important;
    text-decoration: none;
}
.hg-coin:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(245, 158, 11, 0.2) !important;
    border-color: #fde68a !important;
}
.hg-bll {
    position: relative;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff !important;
    border: 1.5px solid var(--border) !important;
    border-radius: 14px !important;
    color: var(--text-mid) !important;
    transition: all 0.2s;
    text-decoration: none;
}
.hg-bll:hover {
    background: var(--blue-light) !important;
    color: var(--blue) !important;
    border-color: var(--blue) !important;
    transform: translateY(-2px);
}
.hg-bdg {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--red);
    color: #fff;
    min-width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 10px;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
}
.hg-chp {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: var(--blue-light);
    border-radius: 14px;
    font-weight: 800;
    font-size: 14px;
    color: var(--blue);
    text-decoration: none;
    transition: 0.2s;
}
.hg-chp:hover {
    background: var(--blue);
    color: #fff;
    transform: translateY(-2px);
}
.hg-out {
    background: #fff !important;
    color: var(--text-mid) !important;
    border: 1.5px solid var(--border) !important;
    padding: 10px 18px !important;
    font-size: 13px;
    font-weight: 800;
    border-radius: 14px !important;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
    text-decoration: none;
}
.hg-out:hover {
    background: #fef2f2 !important;
    color: var(--red) !important;
    border-color: #fee2e2 !important;
    transform: translateY(-2px);
}

/* ── Hamburger Button (hidden on wide screens) ─────── */
.hg-ham {
    display: none;
    flex-direction: column;
    gap: 5px;
    width: 44px;
    height: 44px;
    background: #f1f5f9;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    margin-left: 4px;
    transition: background .18s;
}
.hg-ham:hover { background: #e2e8f0; }
.hg-ham span {
    display: block;
    width: 20px;
    height: 2.5px;
    background: #374151;
    border-radius: 4px;
    transition: all .3s cubic-bezier(.4,0,.2,1);
    pointer-events: none;
}
.hg-ham.on span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.hg-ham.on span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hg-ham.on span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ── Mobile Drawer ────────────────────────────────── */
.hg-drw {
    display: none;
    position: fixed;
    top: var(--hg-h);
    left: 0; right: 0;
    background: linear-gradient(180deg, #1e1b4b, #312e81);
    z-index: 499;
    padding: 10px 12px 16px;
    flex-direction: column;
    gap: 2px;
    box-shadow: 0 16px 48px rgba(0,0,0,.45);
    border-bottom: 2px solid rgba(255,255,255,.1);
    max-height: calc(100vh - var(--hg-h));
    overflow-y: auto;
}
.hg-drw.on { display: flex !important; }
.hg-ml {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    border-radius: 12px;
    color: rgba(255,255,255,.82);
    font-weight: 700;
    font-size: 14px;
    transition: all .18s;
}
.hg-ml:hover, .hg-ml.ha { background: rgba(255,255,255,.1); color: #fff; }
.hg-ml.ha { border-left: 3.5px solid #4DA2FF; padding-left: 12px; }
.hg-div { height: 1px; background: rgba(255,255,255,.1); margin: 6px 0; }
.hg-ovl { display: none; position: fixed; inset: 0; top: var(--hg-h); background: rgba(0,0,0,.55); z-index: 498; backdrop-filter: blur(2px); }
.hg-ovl.on { display: block; }

/* ════════════════════════════════════════════════════
   RESPONSIVE
   ════════════════════════════════════════════════════ */

/* Standard laptops (1300px - 1500px): tighten spacing to keep text visible */
@media (max-width: 1550px) and (min-width: 1201px) {
    .hg-bar { padding: 0 2%; gap: 12px; }
    .hg-nav { gap: 0; }
    .hg-lnk { padding: 6px 8px; font-size: 12.5px; gap: 4px; }
    .hg-lnk.ha { padding: 6px 12px; }
    .hg-rt { gap: 8px; }
    .hg-logo span { display: none; } /* Hide 'HeyyGuru' text only if absolutely needed, or keep it. Let's keep it but make it smaller */
    .hg-logo span { display: inline; font-size: 18px; }
    .hg-logo img { width: 32px; height: 32px; }
}

/* Tablets & small laptops: show hamburger, hide nav links */
@media (max-width: 1200px) {
    .hg-ham { display: flex; }
    .hg-nav { display: none; }
    .hg-out { display: none; }
    .hg-bar { padding: 0 16px; height: 64px; }
    .hg-logout-btn { display: none !important; }
}

@media (max-width: 1024px) {
    .s-grid-4 { grid-template-columns: repeat(3, 1fr); }
    .s-grid-3 { grid-template-columns: repeat(2, 1fr); }
    .s-hero { padding: 24px 26px; }
    .hero-deco { font-size: 56px; right: 20px; }
    
    /* Dashboard grid stacks at tablet */
    .dash-grid { grid-template-columns: 1fr !important; }
}

/* Tablets / large phones */
@media (max-width: 768px) {
    .s-grid-4, .s-grid-3, .s-grid-2 { grid-template-columns: 1fr 1fr; gap: 14px; }
    .grid-4, .grid-3 { grid-template-columns: repeat(2, 1fr) !important; }
    .s-hero { padding: 20px 22px; }
    .s-hero h1 { font-size: 22px; }
    .s-hero-stat-num { font-size: 20px; }
    .hg-coin { padding: 6px 10px; font-size: 12px; }
    .hero-deco { top: 10%; right: 10px; font-size: 60px; opacity: 0.6; }
}

/* Small phones */
@media (max-width: 480px) {
    .hg-lt { display: none; }
    .hg-bar { padding: 0 12px; height: 56px; gap: 8px; }
    .hg-chp span:last-child { display: none; }
    .s-main { padding: 16px 12px; }
    .s-grid-4, .s-grid-3, .s-grid-2 { grid-template-columns: 1fr; gap: 12px; }
    .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr !important; gap: 10px; }
    .s-card-body { padding: 14px; }
    .s-hero { padding: 16px; text-align: center; }
    .s-hero h1 { font-size: 20px; }
    .hero-deco { position: static; transform: none; display: block; margin: 0 auto 10px; font-size: 72px; text-align: center; }
    .hero-stats { justify-content: center; gap: 8px; }
    .s-hero-stat { padding: 10px; min-width: 70px; flex: 1 1 45%; max-width: 48%; }
    .s-hero-stat-num { font-size: 18px; }
    .lec-grid { grid-template-columns: 1fr; }
    .slot-time { min-width: 72px; font-size: 11px; }

    /* Mobile Bottom Nav Spacing */
    body { padding-bottom: 75px; }
    
    /* Coin pill compact */
    .gold-pill { padding: 4px 12px; font-size: 13px; }
    .gold-pill .coin-3d { width: 16px; height: 16px; }
    
    /* Dashboard container */
    .dash-container { padding: 16px 12px; }
    .dash-card { padding: 18px; border-radius: 14px; }
    .prof-container { padding: 24px 12px; }
    
    /* Note cards scroll */
    .note-card { min-width: 170px; max-width: 200px; padding: 16px; }
    
    /* Timetable cards */
    .timetable-card { padding: 16px; gap: 16px; flex-wrap: wrap; }
    .time-box { min-width: 70px; }
}

/* Extra small phones (320px-380px) */
@media (max-width: 380px) {
    .hg-bar { gap: 6px; }
    .gold-pill span { font-size: 12px; }
    .hg-bll { width: 36px; height: 36px; }
    .hg-bll svg { width: 20px; height: 20px; }
    .hg-ava { width: 30px !important; height: 30px !important; font-size: 12px !important; }
    .dash-container { padding: 12px 8px; }
    .dash-card { padding: 14px; }
}

/* ── Mobile Bottom Navigation ────────────────────── */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 65px;
    background: #fff;
    border-top: 1.5px solid var(--border);
    z-index: 600;
    justify-content: space-around;
    align-items: center;
    padding: 0 10px;
    box-shadow: 0 -4px 15px rgba(0,0,0,0.05);
}

.bn-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    color: var(--text-light);
    text-decoration: none;
    transition: all 0.2s;
    flex: 1;
}

.bn-item i, .bn-item svg { width: 22px; height: 22px; stroke-width: 2.5; }
.bn-text { font-size: 10px; font-weight: 800; }
.bn-item.active { color: #4DA2FF; }

@media (max-width: 768px) {
    .mobile-bottom-nav { display: flex; }
}

/* ── Attendance Page ─────────────────────────────── */
.att-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 20px; flex-wrap: wrap; gap: 12px; }
.att-header h1 { font-size: 24px; font-weight: 900; margin-bottom: 4px; }
.att-rate-bubble {
    background: linear-gradient(135deg, #4DA2FF, #7c3aed);
    color: #fff;
    border-radius: 20px;
    padding: 14px 22px;
    text-align: center;
    min-width: 100px;
    box-shadow: 0 8px 20px rgba(79,70,229,.25);
}
.att-rate-bubble .rate-num { font-size: 28px; font-weight: 900; }
.att-rate-bubble .rate-lbl { font-size: 10px; font-weight: 800; opacity: .8; text-transform: uppercase; letter-spacing: .7px; margin-top: 2px; }
.rate-green  { background: linear-gradient(135deg, #059669, #10b981); }
.rate-amber  { background: linear-gradient(135deg, #0284c7, #0ea5e9); }
.rate-red    { background: linear-gradient(135deg, #dc2626, #ef4444); }

.stats-grid  { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 24px; }
.stat-card   { background: var(--card); border-radius: var(--r); padding: 20px; box-shadow: var(--sh); border: 1.5px solid var(--border); text-align: center; border-bottom: 4px solid; }
.stat-val    { font-size: 32px; font-weight: 900; line-height: 1; }
.stat-lbl    { font-size: 11px; font-weight: 800; color: var(--text-light); text-transform: uppercase; letter-spacing: .5px; margin-top: 6px; }

.calendar-section { display: grid; grid-template-columns: 1fr 340px; gap: 20px; align-items: start; }
.calendar-card    { background: var(--card); border-radius: var(--r); border: 1.5px solid var(--border); box-shadow: var(--sh); overflow: hidden; }
.cal-header       { display: flex; justify-content: space-between; align-items: center; padding: 18px 22px; border-bottom: 1.5px solid var(--border); background: linear-gradient(135deg, #1e1b4b, #4338ca); color: #fff; }
.month-title      { font-size: 18px; font-weight: 900; }
.cal-nav          { display: flex; align-items: center; gap: 8px; }
.nav-btn          { width: 34px; height: 34px; border-radius: 10px; background: rgba(255,255,255,.18); color: #fff; font-size: 14px; font-weight: 900; display: flex; align-items: center; justify-content: center; cursor: pointer; border: none; transition: background .18s; text-decoration: none; }
.nav-btn:hover    { background: rgba(255,255,255,.3); }

.cal-grid    { display: grid; grid-template-columns: repeat(7, 1fr); padding: 16px; gap: 6px; }
.day-name    { text-align: center; font-size: 11px; font-weight: 800; color: var(--text-light); text-transform: uppercase; padding: 4px 0 8px; }
.day-cell    { display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 14px; font-weight: 800; cursor: pointer; transition: all .15s; position: relative; padding: 4px; color: var(--text); border-radius: 10px; min-height: 60px; border: 1.5px solid rgba(0,0,0,0.02); }
.day-cell:hover { transform: scale(1.05); z-index: 5; box-shadow: var(--sh); }
.other-month { opacity: 0; pointer-events: none; }
.today       { outline: 2.5px solid var(--blue); outline-offset: -2px; }
.selected-date { box-shadow: 0 0 0 3px rgba(79,70,229,.35) !important; }
.status-present  { background: #dcfce7 !important; color: #15803d !important; }
.status-absent   { background: #fee2e2 !important; color: #b91c1c !important; }
.status-late     { background: #fef3c7 !important; color: #92400e !important; }
.status-holiday  { background: #f3e8ff !important; color: #7c3aed !important; }
.status-icon     { font-size: 8px; margin-top: 1px; }
.holiday-name    { font-size: 7px; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; max-width: 100%; margin-top: 1px; }

.legend      { display: flex; gap: 14px; padding: 14px 18px; border-top: 1.5px solid var(--border); flex-wrap: wrap; background: #fafbff; }
.legend-item { display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 700; }
.leg-box     { width: 16px; height: 16px; border-radius: 5px; border: 1.5px solid rgba(0,0,0,.08); }

.records-card    { background: var(--card); border-radius: var(--r); border: 1.5px solid var(--border); box-shadow: var(--sh); overflow: hidden; }
.records-header  { padding: 16px 20px; border-bottom: 1.5px solid var(--border); font-size: 14px; font-weight: 900; display: flex; align-items: center; justify-content: space-between; background: #fafbff; }
.records-list    { max-height: 500px; overflow-y: auto; }
.record-item     { display: flex; align-items: center; gap: 12px; padding: 12px 18px; border-bottom: 1.5px solid #f8fafc; transition: background .15s; }
.record-item:hover { background: #f8fafc; }
.record-item:last-child { border-bottom: none; }
.record-date     { flex-shrink: 0; text-align: center; background: var(--blue-light); border-radius: 12px; padding: 8px 10px; min-width: 50px; }
.rd-day          { font-size: 20px; font-weight: 900; color: var(--blue); display: block; line-height: 1; }
.rd-mon          { font-size: 10px; font-weight: 800; color: var(--text-light); text-transform: uppercase; display: block; }
.record-info     { flex: 1; min-width: 0; }
.ri-name         { font-size: 14px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ri-by           { font-size: 12px; color: var(--text-light); font-weight: 600; margin-top: 3px; }
.ri-status       { padding: 5px 12px; border-radius: 99px; font-size: 12px; font-weight: 800; flex-shrink: 0; }
.badge-green     { background: var(--green-light); color: var(--green); }
.badge-red       { background: #fee2e2; color: var(--red); }
.badge-amber     { background: var(--amber-light); color: #92400e; }
.badge-gray      { background: #f1f5f9; color: var(--text-mid); }
.empty-state     { text-align: center; padding: 36px 16px; color: var(--text-light); }
.empty-state .empty-icon { font-size: 44px; margin-bottom: 12px; }

@media (max-width: 900px) {
    .calendar-section { grid-template-columns: 1fr; }
    .stats-grid { gap: 10px; }
    .records-list { max-height: 300px; }
}
@media (max-width: 480px) {
    .stats-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; }
    .stat-val { font-size: 24px; }
    .cal-grid { gap: 3px; padding: 10px; }
    .day-cell { font-size: 12px; border-radius: 7px; min-height: 48px; border: 1.5px solid rgba(0,0,0,0.04); }
    .att-header { flex-direction: column; align-items: flex-start; }
    .att-rate-bubble { width: 100%; box-sizing: border-box; }
}
.hw-list { display: flex; flex-direction: column; gap: 16px; }
.hw-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.hw-badge { padding: 4px 10px; background: #f1f5f9; color: var(--text-mid); border-radius: 99px; font-size: 11.5px; font-weight: 700; }
.hw-info { flex: 1; }
.hw-desc { font-size: 13.5px; color: var(--text-mid); margin-top: 6px; line-height: 1.5; }
.btn-submit { padding: 10px 16px; border-radius: 14px; background: var(--blue); color: #fff; border: none; font-family: 'Nunito', sans-serif; font-size: 13px; font-weight: 900; cursor: pointer; width: 100%; text-align: center; transition: all .2s; }
.btn-submit:hover { opacity: .88; transform: translateY(-1px); }

/* Modal */
.modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.55); z-index: 800; backdrop-filter: blur(4px); display: none; align-items: center; justify-content: center; }
.modal { 
    display: none; 
    position: relative; 
    width: min(96vw, 520px); 
    max-height: 90vh; 
    display: flex;
    flex-direction: column;
    margin: auto;
    background: #fff; 
    border-radius: 24px; 
    z-index: 801; 
    box-shadow: 0 32px 80px rgba(0,0,0,.22); 
    overflow: hidden;
}
.modal-header { padding: 24px 28px 16px; border-bottom: 1.5px solid var(--border-light); background: #fff; }
.modal-body { padding: 16px 28px 28px; overflow-y: auto; -webkit-overflow-scrolling: touch; flex: 1; }
/* Add this to EOF of assets/css/style.css */

/* Global Motion & UI Polish */
.s-card, .qa-card, .menu-item, .batch-card, .student-card, .dash-card, .stat-card, .ls-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.s-card:hover, .qa-card:hover, .batch-card:hover, .student-card:hover, .dash-card:hover, .stat-card:hover, .ls-card:hover {
    transform: translateY(-3px) scale(1.01) !important;
    box-shadow: 0 12px 24px -8px rgba(0, 0, 0, 0.1) !important;
}

.btn {
    transition: all 0.2s ease !important;
}

.btn:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
}

.btn:active {
    transform: translateY(0) !important;
}

/* ── Animations ────────────────────────────────────── */

/* ── Premium Utilities ──────────────────────────── */
.glass {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.glass-dark {
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.premium-card {
    background: var(--card);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-premium);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.premium-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--sh-hover);
}

/* ── Animations ────────────────────────────────────── */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

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

@keyframes pulse-subtle {
    0% { transform: scale(1); }
    50% { transform: scale(1.02); }
    100% { transform: scale(1); }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes glow-pulse {
    0%, 100% { box-shadow: 0 0 20px rgba(59, 150, 233, 0.2); }
    50% { box-shadow: 0 0 40px rgba(59, 150, 233, 0.4); }
}

.fade-in { animation: fadeInUp 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.slide-in { animation: slideInRight 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.float { animation: float 4s ease-in-out infinite; }

.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }

.hover-glow:hover {
    animation: glow-pulse 2s infinite;
}

/* ── Progress Bar Pulse ──────────────────────────── */
.progress-bar-fill {
    position: relative;
    overflow: hidden;
}
.progress-bar-fill::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.mesh-gradient {
    background: radial-gradient(at 0% 0%, #4338ca 0px, transparent 50%),
                radial-gradient(at 100% 0%, #6d28d9 0px, transparent 50%),
                radial-gradient(at 100% 100%, #1e1b4b 0px, transparent 50%),
                radial-gradient(at 0% 100%, #312e81 0px, transparent 50%);
    background-color: #0f172a;
}

/* ── Horizontal Pill Strip Schedule ──────────────── */
.horizontal-schedule {
    display: flex;
    overflow-x: auto;
    padding: 20px 0;
    gap: 15px;
    scrollbar-width: none; /* Hide scrollbar for clean look */
    -ms-overflow-style: none; /* IE and Edge */
    align-items: center;
}
.horizontal-schedule::-webkit-scrollbar {
    display: none; /* Chrome, Safari and Opera */
}

.date-bubble {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--blue), #6366f1);
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
    box-shadow: 0 10px 20px rgba(59, 150, 233, 0.3);
    border: 3px solid rgba(255, 255, 255, 0.2);
}
.date-bubble .db-day { font-size: 18px; font-weight: 900; line-height: 1; }
.date-bubble .db-mon { font-size: 11px; font-weight: 700; text-transform: uppercase; opacity: 0.9; }

.class-pill {
    min-width: 240px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 50px;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.4);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: default;
}

.class-pill:hover {
    transform: translateY(-6px) scale(1.02);
    background: #ffffff;
    box-shadow: 0 20px 40px rgba(59, 150, 233, 0.15);
    border-color: var(--blue-glow);
}

.class-time {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--blue);
    margin-right: 12px;
}

.class-subject {
    font-weight: 700;
    color: var(--text);
    flex-grow: 1;
}

.class-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-left: 10px;
    background: var(--blue);
}

/* ── Awesome "Stat Pills" (Metric Cards) ─────── */
.stat-pill-row {
    display: flex;
    gap: 20px;
    margin-bottom: 32px;
    flex-wrap: wrap;
}
.stat-pill {
    flex: 1;
    min-width: 180px;
    background: var(--card);
    border: 1.5px solid var(--border);
    border-radius: 24px;
    padding: 24px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: var(--sh);
}
.stat-pill:hover {
    transform: translateY(-5px);
    border-color: var(--brand-color);
    box-shadow: 0 20px 40px -12px var(--brand-glow);
}
.stat-icon-3d {
    font-size: 40px;
    margin-bottom: 12px;
    display: block;
}
.stat-value {
    font-size: 32px;
    font-weight: 900;
    color: var(--text);
    display: block;
    line-height: 1.2;
}
.stat-label {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

/* ── Dynamic Timetable Scroller ───────────────── */
.timetable-scroller {
    display: flex;
    gap: 12px;
    padding: 4px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.timetable-scroller::-webkit-scrollbar { display: none; }

.day-pill {
    padding: 12px 24px;
    border-radius: 99px;
    background: #f8fafc;
    border: 1.5px solid #f1f5f9;
    color: var(--text-mid);
    font-weight: 800;
    font-size: 14px;
    cursor: pointer;
    transition: 0.2s;
    white-space: nowrap;
}
.day-pill:hover {
    background: #f1f5f9;
    color: var(--text);
}
.day-pill.active {
    background: var(--brand-color);
    color: #fff;
    border-color: var(--brand-color);
    box-shadow: 0 8px 16px var(--brand-glow);
}

/* ── Task & Note Cards ────────────────────────── */
.modern-task-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: var(--card);
    border: 1.5px solid var(--border);
    border-radius: 20px;
    margin-bottom: 12px;
    transition: 0.2s;
}
.modern-task-card:hover {
    border-color: var(--brand-color);
    transform: translateX(4px);
}
.task-check {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: var(--green-light);
    color: var(--green);
    display: flex;
    align-items: center;
    justify-content: center;
}
.task-content { flex: 1; }
.task-title { font-weight: 800; font-size: 15px; color: var(--text); }
.task-meta { font-size: 12px; color: var(--text-light); font-weight: 600; }

/* ── Gradient Progress Bar ────────────────────── */
.premium-progress {
    height: 10px;
    background: #f1f5f9;
    border-radius: 99px;
    overflow: hidden;
    position: relative;
}
.premium-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #7c3aed, #4DA2FF);
    border-radius: 99px;
    box-shadow: 0 0 10px var(--brand-glow);
    transition: width 1s ease;
}

/* High Visibility Syllabus Text */
.syllabus-text-fix {
    color: #111111 !important;
    font-weight: 700 !important;
}

/* Awesome Notification Bell */
.hg-bll {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: var(--bg);
    border: 1.5px solid var(--border);
    border-radius: 12px;
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    color: var(--text-mid);
}
.hg-bll:hover { 
    transform: translateY(-2px);
    border-color: var(--brand-color);
    color: var(--brand-color);
    box-shadow: 0 8px 16px rgba(124, 58, 237, 0.1);
}
.hg-bll.has-unread {
    animation: bell-pulse 2s infinite;
}
@keyframes bell-pulse {
    0% { box-shadow: 0 0 0 0 rgba(124, 58, 237, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(124, 58, 237, 0); }
    100% { box-shadow: 0 0 0 0 rgba(124, 58, 237, 0); }
}
.hg-bdg-new {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #ef4444;
    color: #fff;
    font-size: 10px;
    font-weight: 900;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg);
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
}

/* ════════════════════════════════════════════════════
   ATTENDANCE PAGE — Student Portal
   ════════════════════════════════════════════════════ */

/* Header */
.att-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
    gap: 16px;
    flex-wrap: wrap;
}
.att-header h1 {
    font-size: 26px;
    font-weight: 900;
    color: var(--text);
    letter-spacing: -0.5px;
}

/* Rate Bubble */
.att-rate-bubble {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    border: 3px solid transparent;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    flex-shrink: 0;
}
.att-rate-bubble:hover {
    transform: scale(1.06);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}
.rate-num { font-size: 26px; line-height: 1; }
.rate-lbl { font-size: 9px; text-transform: uppercase; letter-spacing: 0.5px; margin-top: 4px; opacity: 0.85; font-weight: 800; }
.rate-green { background: linear-gradient(135deg, #d1fae5, #ecfdf5); color: #059669; border-color: #6ee7b7; }
.rate-amber { background: linear-gradient(135deg, #fef3c7, #fffbeb); color: #0284c7; border-color: #7dd3fc; }
.rate-red   { background: linear-gradient(135deg, #fee2e2, #fff1f2); color: #dc2626; border-color: #fca5a5; }

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-bottom: 28px;
}
.stat-card {
    background: #fff;
    border-radius: 18px;
    padding: 20px;
    text-align: center;
    border: 1.5px solid #f1f5f9;
    border-bottom-width: 4px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}
.stat-val { font-size: 36px; font-weight: 900; letter-spacing: -1px; line-height: 1; }
.stat-lbl { font-size: 12px; font-weight: 700; color: var(--text-mid); margin-top: 8px; }

/* Calendar Section (2-col layout) */
.calendar-section {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 20px;
    margin-bottom: 28px;
}

/* Calendar Card */
.calendar-card {
    background: #fff;
    border-radius: 20px;
    border: 1.5px solid #f1f5f9;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
    padding: 24px;
    overflow: hidden;
}
.cal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}
.month-title {
    font-size: 20px;
    font-weight: 900;
    color: var(--text);
    letter-spacing: -0.5px;
}
.cal-nav {
    display: flex;
    gap: 6px;
    align-items: center;
}
.nav-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    color: var(--text-mid);
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.2s;
}
.nav-btn:hover {
    background: #4DA2FF;
    color: #fff;
    border-color: #4DA2FF;
    transform: translateY(-1px);
}

/* Calendar Grid */
.cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}
.day-name {
    font-size: 11px;
    font-weight: 800;
    color: var(--text-light);
    text-align: center;
    padding: 8px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.day-cell {
    position: relative;
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    color: var(--text);
    transition: all 0.15s ease;
    background: #fafbfc;
    border: 1.5px solid transparent;
}
.day-cell:hover:not(.other-month) {
    transform: scale(1.08);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    z-index: 2;
}
.day-cell.other-month {
    visibility: hidden;
}
.day-cell.today {
    border-color: #4DA2FF;
    box-shadow: 0 0 0 2px rgba(77, 162, 255, 0.2);
    font-weight: 900;
}
.day-cell.selected-date {
    background: #4DA2FF !important;
    color: #fff !important;
    border-color: #4DA2FF;
    box-shadow: 0 4px 14px rgba(77, 162, 255, 0.35);
}
.day-cell.selected-date .status-icon { filter: brightness(10); }
.day-cell.selected-date .holiday-name { color: rgba(255,255,255,0.9) !important; }

/* Status Colors */
.day-cell.status-present { background: #dcfce7; color: #15803d; border-color: #bbf7d0; }
.day-cell.status-absent  { background: #fee2e2; color: #dc2626; border-color: #fecaca; }
.day-cell.status-late    { background: #fef3c7; color: #92400e; border-color: #fde68a; }
.day-cell.status-holiday { background: #e0f2fe; color: #0369a1; border-color: #bae6fd; }

.status-icon {
    font-size: 10px;
    margin-top: 2px;
    line-height: 1;
}
.holiday-name {
    font-size: 7px;
    font-weight: 800;
    color: #0369a1;
    margin-top: 1px;
    text-align: center;
    line-height: 1.1;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Legend */
.legend {
    display: flex;
    gap: 16px;
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1.5px solid #f1f5f9;
    flex-wrap: wrap;
}
.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-mid);
}
.leg-box {
    width: 16px;
    height: 16px;
    border-radius: 5px;
    border: 1.5px solid transparent;
}
.leg-box.status-present { background: #dcfce7; border-color: #bbf7d0; }
.leg-box.status-late    { background: #fef3c7; border-color: #fde68a; }
.leg-box.status-absent  { background: #fee2e2; border-color: #fecaca; }
.leg-box.status-holiday { background: #e0f2fe; border-color: #bae6fd; }

/* Records Sidebar */
.records-card {
    background: #fff;
    border-radius: 20px;
    border: 1.5px solid #f1f5f9;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.records-header {
    padding: 18px 22px;
    border-bottom: 1.5px solid #f1f5f9;
    font-size: 14px;
    font-weight: 800;
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fafbff;
}
.records-list {
    padding: 8px 12px;
    overflow-y: auto;
    max-height: 450px;
    flex: 1;
}

/* Record Item */
.record-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px;
    border-radius: 14px;
    transition: background 0.15s;
    border-bottom: 1px solid #f8fafc;
}
.record-item:last-child { border-bottom: none; }
.record-item:hover { background: #f8fafc; }

.record-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: #f1f5f9;
    flex-shrink: 0;
}
.rd-day { font-size: 18px; font-weight: 900; line-height: 1; color: var(--text); }
.rd-mon { font-size: 9px; font-weight: 800; text-transform: uppercase; color: var(--text-mid); letter-spacing: 0.5px; }

.record-info { flex: 1; min-width: 0; }
.ri-name { font-size: 13px; font-weight: 800; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ri-by { font-size: 11px; color: var(--text-light); font-weight: 600; margin-top: 2px; }

.ri-status {
    padding: 4px 12px;
    border-radius: 99px;
    font-size: 11px;
    font-weight: 800;
    white-space: nowrap;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 3px;
}
.badge-green { background: #dcfce7; color: #15803d; }
.badge-red   { background: #fee2e2; color: #dc2626; }
.badge-amber { background: #fef3c7; color: #92400e; }
.badge-gray  { background: #f1f5f9; color: #64748b; }

/* Empty State */
.empty-state {
    text-align: center;
    padding: 32px 16px;
    color: var(--text-light);
}
.empty-state .empty-icon { font-size: 32px; margin-bottom: 10px; opacity: 0.5; }
.empty-state p { font-size: 13px; font-weight: 600; }

/* ── Attendance Responsive ── */
@media (max-width: 900px) {
    .calendar-section {
        grid-template-columns: 1fr;
    }
    .stats-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .att-rate-bubble {
        width: 80px;
        height: 80px;
    }
    .rate-num { font-size: 20px; }
    .stat-val { font-size: 28px; }
}
@media (max-width: 500px) {
    .att-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .att-rate-bubble {
        align-self: center;
    }
    .day-cell {
        font-size: 12px;
        border-radius: 8px;
    }
    .cal-grid {
        gap: 3px;
    }
    .record-item {
        padding: 10px 8px;
    }
}

/* ── Premium UI Glasses & Meshes ─────────────────── */
.premium-glass-card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 28px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.04), inset 0 0 0 1px rgba(255,255,255,0.2);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
}
body.dark-mode .premium-glass-card {
    background: rgba(30, 41, 59, 0.6);
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 12px 40px rgba(0,0,0,0.3);
}
.premium-glass-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.08), inset 0 0 0 1px rgba(255,255,255,0.4);
    border-color: rgba(255, 255, 255, 0.9);
}
body.dark-mode .premium-glass-card:hover { border-color: rgba(255, 255, 255, 0.2); }

.premium-mesh-bg {
    background: linear-gradient(135deg, #4DA2FF 0%, #7c3aed 100%);
    background-image: 
        radial-gradient(at 0% 0%, hsla(253,16%,7%,1) 0, transparent 50%), 
        radial-gradient(at 50% 0%, hsla(225,39%,30%,1) 0, transparent 50%), 
        radial-gradient(at 100% 0%, hsla(339,49%,30%,1) 0, transparent 50%);
    position: relative;
    overflow: hidden;
    color: #fff !important;
    border-radius: 28px;
    box-shadow: 0 20px 50px rgba(124, 58, 237, 0.3);
    border: 1px solid rgba(255,255,255,0.15);
}
.premium-mesh-bg * { color: #fff; }
.premium-mesh-bg::before {
    content: '';
    position: absolute; width: 150%; height: 150%;
    background: radial-gradient(circle at center, rgba(255,255,255,0.15) 0%, transparent 60%);
    top: -50%; left: -25%; pointer-events: none;
    animation: slowSpin 25s linear infinite;
}
@keyframes slowSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.hover-lift-strong {
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.hover-lift-strong:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 30px 60px -12px rgba(59, 150, 233, 0.3);
}

/* ── Dynamic Stats SVG ────────────────────────────── */
.circular-chart { display: block; margin: 10px auto; max-width: 80%; max-height: 250px; filter: drop-shadow(0 4px 6px rgba(0,0,0,0.05)); }
.circle-bg { fill: none; stroke: #f1f5f9; stroke-width: 3.8; }
body.dark-mode .circle-bg { stroke: #334155; }
.circle { fill: none; stroke-width: 2.8; stroke-linecap: round; animation: progress 2s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; }
@keyframes progress { 0% { stroke-dasharray: 0 100; } }
.percentage { fill: #1e1b4b; font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 900; font-size: 0.5em; text-anchor: middle; dominant-baseline: central; }
body.dark-mode .percentage { fill: #fff; }
.circ-green { stroke: #10b981; filter: drop-shadow(0 0 8px rgba(16,185,129,0.4)); }
.circ-blue { stroke: #4DA2FF; filter: drop-shadow(0 0 8px rgba(77,162,255,0.4)); }
.circ-amber { stroke: #f59e0b; filter: drop-shadow(0 0 8px rgba(245,158,11,0.4)); }
.circ-red { stroke: #ef4444; filter: drop-shadow(0 0 8px rgba(239,68,68,0.4)); }

/* Calendar Premium Cells */
.s-calendar-layout { margin-top:24px; display:grid; grid-template-columns: 1fr; gap: 24px; }
@media(min-width: 900px) { .s-calendar-layout { grid-template-columns: 1fr 320px; } }

.cal-grid-premium { display: grid; grid-template-columns: repeat(7, 1fr); gap: 10px; padding: 24px; }
@media(max-width: 600px) { .cal-grid-premium { gap: 6px; padding: 16px; } }
.cal-cell-glass { 
    background: rgba(255,255,255,0.5); 
    border-radius: 16px; 
    border: 1px solid rgba(255,255,255,0.6);
    display:flex; flex-direction:column; align-items:center; justify-content:center;
    aspect-ratio: 1; position:relative; overflow:hidden;
    transition: all 0.2s; font-weight: 800; font-size: 14px;
}
body.dark-mode .cal-cell-glass { background: rgba(30,41,59,0.4); border-color: rgba(255,255,255,0.05); }
.cal-cell-glass:hover { background: #fff; transform: scale(1.05); box-shadow: 0 10px 20px rgba(0,0,0,0.06); z-index:2; cursor:pointer;}
body.dark-mode .cal-cell-glass:hover { background: #334155; }

.cal-status-dot { width: 6px; height: 6px; border-radius: 50%; margin-top: 4px; box-shadow: 0 0 6px currentColor; }
.dot-present { background: #10b981; color: #10b981; }
.dot-late { background: #f59e0b; color: #f59e0b; }
.dot-absent { background: #ef4444; color: #ef4444; }

.cal-cell-today { background: #4DA2FF !important; color: #fff !important; box-shadow: 0 10px 20px rgba(77,162,255,0.3) !important; border:none !important; }
.cal-cell-other { opacity: 0.3; pointer-events:none; }

/* Theater Mode Video */
.theater-container {
    background: #000;
    border-radius: 28px;
    overflow: hidden;
    position: relative;
    aspect-ratio: 16/9;
    box-shadow: 0 30px 80px rgba(0,0,0,0.6);
    border: 1px solid rgba(255,255,255,0.1);
}
.theater-glow {
    position:absolute; inset:-20px; z-index:-1; filter:blur(40px); opacity:0.6; pointer-events:none; border-radius:50%;
}

/* ── Filter Selects ────────────────────────────── */
.filter-select {
    padding: 12px 20px;
    border-radius: 14px;
    background: #fff;
    border: 1.5px solid var(--border);
    font-weight: 800;
    font-size: 14px;
    color: var(--text-mid);
    outline: none;
    transition: all 0.2s;
    cursor: pointer;
}
.filter-select:hover, .filter-select:focus {
    border-color: var(--brand-color);
    box-shadow: 0 4px 12px rgba(77,162,255,0.1);
}

