/* css/styles.css */

:root {
    /* Base Colors */
    --bg-color: #f8fafc;
    --primary-color: #4f46e5; /* Indigo */
    --primary-hover: #4338ca;
    --success: #10b981;
    --error: #ef4444;
    
    /* Text Colors */
    --text-dark: #1e293b;
    --text-muted: #64748b;
    --text-light: #ffffff;
    
    /* Glass Settings */
    --glass-bg: rgba(255, 255, 255, 0.15);
    --glass-border: rgba(255, 255, 255, 0.3);
    --glass-shadow: 0 8px 32px rgba(31, 38, 135, 0.1);
    --glass-blur: blur(16px);
    
    /* Gradients matching reference */
    --grad-1: #4f46e5; /* Indigo */
    --grad-2: #ec4899; /* Pink */
    --grad-3: #f59e0b; /* Orange */
}

/* Theming for Auth Pages / Roles */
body.theme-teacher {
    --primary-color: #f97316; /* Orange */
    --primary-hover: #ea580c;
    --grad-1: #f97316; 
    --grad-2: #f59e0b; 
    --grad-3: #fbbf24;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-dark);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    line-height: 1.6;
}

/* Base interactive elements */
a { text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* -----------------------------------------
   Glassmorphism Utilities
   ----------------------------------------- */
.glass-panel {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    box-shadow: var(--glass-shadow);
    border-radius: 16px;
    color: var(--text-dark); /* Ensure text is readable on light glass */
}

/* Except when we want light text on dark gradient */
.text-white {
    color: var(--text-light) !important;
}

.glass-panel-sm {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 12px;
}

.glass-btn {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(5px);
    color: var(--text-dark);
    border-radius: 8px;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-weight: 500;
}
.glass-btn:hover {
    background: rgba(255, 255, 255, 0.4);
}

.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 1rem;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}
.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.4);
}
.btn-outline {
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    background: transparent;
}
.btn-outline:hover, .btn-outline:active {
    background: var(--primary-color);
    color: white;
}

.btn:active {
    transform: scale(0.96) !important;
}

.btn-full { width: 100%; }
.btn-lg { padding: 1rem 2rem; font-size: 1.125rem;}
.btn-sm { padding: 0.5rem; border-radius: 8px;}

/* Form inputs (Glass) */
button, a, input, select, textarea {
    -webkit-tap-highlight-color: transparent;
}

.glass-input, .glass-search {
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.5);
    color: var(--text-dark);
    padding: 0.75rem 1rem 0.75rem 2.5rem;
    border-radius: 8px;
    width: 100%;
    outline: none;
    transition: all 0.3s;
}
.glass-input:focus, .glass-search:focus {
    border-color: var(--primary-color);
    background: rgba(255, 255, 255, 0.6);
}
.glass-input::placeholder, .glass-search::placeholder {
    color: var(--text-muted);
}
.input-wrapper, .glass-input-wrapper {
    position: relative;
    width: 100%;
}
.input-wrapper i, .glass-input-wrapper i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}
.input-wrapper input, .glass-input-wrapper input {
    padding-left: 2.5rem !important;
}

/* -----------------------------------------
   Background Blobs / Gradients (Now brighter)
   ----------------------------------------- */
.blob {
    position: fixed;
    border-radius: 50%;
    filter: blur(120px);
    z-index: -1;
    opacity: 0.8;
}
.blob-1 { top: -20%; left: -10%; width: 60vw; height: 60vw; background: radial-gradient(circle, var(--grad-1), transparent); }
.blob-2 { bottom: -20%; right: -10%; width: 70vw; height: 70vw; background: radial-gradient(circle, var(--grad-2), transparent); }
.blob-3 { top: 30%; left: 40%; width: 50vw; height: 50vw; background: radial-gradient(circle, var(--grad-3), transparent); }

.bg-grad {
    position: fixed;
    border-radius: 50%;
    filter: blur(120px);
    z-index: -1;
    opacity: 0.8;
}
.bg-grad-1 { top: -10%; left: -10%; width: 50vw; height: 50vh; background: var(--grad-1); }
.bg-grad-2 { bottom: -10%; left: -10%; width: 60vw; height: 60vh; background: var(--grad-3); }
.bg-grad-3 { top: -10%; right: -10%; width: 60vw; height: 100vh; background: var(--grad-2); }


/* -----------------------------------------
   Landing Page Styles
   ----------------------------------------- */
.landing-page .glass-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.4);
}
.logo {
    font-size: 1.5rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-dark);
}
.logo i { color: var(--primary-color); }

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}
.desktop-nav a:not(.btn) {
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.3s;
}
.desktop-nav a:not(.btn):hover { color: var(--primary-color); }
.mobile-menu-btn { display: none; }

.hero {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    text-align: center;
}
.hero-content {
    max-width: 800px;
    padding: 4rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    background: rgba(255, 255, 255, 0.6); /* Whiter glass for better contrast */
    border-radius: 20px;
}
.badge {
    background: rgba(79, 70, 229, 0.1);
    color: var(--primary-color);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.hero h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: 1.1;
    color: var(--text-dark);
}
.hero p {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}
.feature-card {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    transition: transform 0.3s ease;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 20px;
}
.feature-card:hover {
    transform: translateY(-10px);
}
.glass-icon {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}
.feature-card h3 { font-size: 1.5rem; color: var(--text-dark); }
.feature-card p { color: var(--text-muted); }

/* -----------------------------------------
   Solutions Multi-Tab Section
   ----------------------------------------- */
.solutions-section {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto 4rem auto;
}

.solutions-tabs {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.sol-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.5);
    color: var(--text-dark);
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    backdrop-filter: blur(5px);
}

.sol-tab-btn i { font-size: 1.25rem; }

.sol-tab-btn.active {
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-color: #ffffff;
}

/* Individual tab active colors to match Reference themes */
.sol-tab-btn[data-target="sol-aluno"].active { color: #8b5cf6; } /* Purple */
.sol-tab-btn[data-target="sol-professor"].active { color: #f97316; } /* Orange */
.sol-tab-btn[data-target="sol-gestor"].active { color: #3b82f6; } /* Blue */
.sol-tab-btn[data-target="sol-familia"].active { color: #eab308; } /* Yellow */

.solutions-content-wrapper {
    position: relative;
    min-height: 500px;
}

.sol-content-panel {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    border-radius: 24px;
    padding: 3rem;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
    animation: fadeIn 0.4s ease forwards;
}

.sol-content-panel.active {
    display: grid;
    position: relative;
}

/* Panel Background Themes with Glassmorphism Overrides */
.sol-content-panel.theme-purple { background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(139, 92, 246, 0.05)); border: 1px solid rgba(139, 92, 246, 0.2); box-shadow: 0 10px 30px rgba(139, 92, 246, 0.1); }
.sol-content-panel.theme-orange { background: linear-gradient(135deg, rgba(249, 115, 22, 0.15), rgba(249, 115, 22, 0.05)); border: 1px solid rgba(249, 115, 22, 0.2); box-shadow: 0 10px 30px rgba(249, 115, 22, 0.1); }
.sol-content-panel.theme-blue { background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(59, 130, 246, 0.05)); border: 1px solid rgba(59, 130, 246, 0.2); box-shadow: 0 10px 30px rgba(59, 130, 246, 0.1); }
.sol-content-panel.theme-yellow { background: linear-gradient(135deg, rgba(234, 179, 8, 0.15), rgba(234, 179, 8, 0.05)); border: 1px solid rgba(234, 179, 8, 0.2); box-shadow: 0 10px 30px rgba(234, 179, 8, 0.1); }

.sol-text-side h2 {
    font-size: 2.25rem;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.sol-text-side > p {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.sol-features-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.sol-features-list li {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.sol-features-list strong {
    font-size: 1.1rem;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sol-features-list strong::before {
    content: '•';
    color: var(--primary-color);
    font-size: 1.5rem;
    line-height: 1;
}

.sol-features-list span {
    font-size: 0.95rem;
    color: var(--text-muted);
    padding-left: 1rem;
}

/* Mockup Visual */
.sol-visual-side {
    display: flex;
    justify-content: center;
    align-items: center;
}

.mockup-card {
    background: rgba(255, 255, 255, 0.7);
    width: 100%;
    max-width: 350px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.mockup-header {
    background: #ffffff;
    padding: 1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.mockup-body {
    padding: 1.5rem;
}

.mockup-badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    background: rgba(79, 70, 229, 0.1);
    color: var(--primary-color);
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.mockup-highlight {
    font-size: 0.95rem;
    line-height: 1.5;
    background: rgba(255,255,255,0.5);
    padding: 1rem;
    border-radius: 8px;
    border-left: 3px solid var(--primary-color);
}

.mockup-stats {
    display: flex;
    gap: 1rem;
}
.stat-item {
    flex: 1;
    background: #ffffff;
    padding: 1rem;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    font-size: 0.8rem;
    color: var(--text-muted);
}
.stat-item span {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-dark);
}

.mt-2 { margin-top: 1rem; }

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

@media (max-width: 900px) {
    .sol-content-panel {
        grid-template-columns: 1fr;
        padding: 2rem;
    }
}

.glass-footer {
    text-align: center;
    padding: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.3);
    margin-top: 4rem;
    color: var(--text-muted);
}


/* -----------------------------------------
   Login Page Styles
   ----------------------------------------- */
.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 1rem;
}
.back-link {
    position: absolute;
    top: 2rem;
    left: 2rem;
}
.login-container {
    width: 100%;
    max-width: 450px;
    padding: 3rem 2rem;
    background: rgba(255, 255, 255, 0.6); /* Whiter glass */
    border-radius: 20px;
}
.login-header {
    text-align: center;
    margin-bottom: 2rem;
}
.login-header .logo { justify-content: center; margin-bottom: 1rem; font-size: 2rem;}
.login-header h2 { font-size: 1.75rem; margin-bottom: 0.5rem; color: var(--text-dark); }
.login-header p { color: var(--text-muted); }

.login-form .form-group { margin-bottom: 1.5rem; }
.login-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-dark);
    font-weight: 500;
}
.forgot-pwd {
    text-align: right;
    margin-top: 0.5rem;
}
.forgot-pwd a {
    font-size: 0.875rem;
    color: var(--primary-color);
    font-weight: 500;
}
.forgot-pwd a:hover { text-decoration: underline; }

.divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 2rem 0;
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Consolidated Calendar System */
.calendar-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 2rem;
    border: 1px solid #f1f5f9;
}

.calendar-grid {
    display: grid !important;
    grid-template-columns: repeat(7, 1fr) !important;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.cal-dow {
    text-align: center;
    font-size: 0.875rem;
    font-weight: 700;
    color: #94a3b8;
    margin-bottom: 0.5rem;
}

.cal-day-v2 {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 8px 4px;
    min-height: 55px;
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 12px;
    background: #f1f5f9;
    color: var(--text-dark);
    font-weight: 500;
}

.cal-day-v2:hover { background: #f8fafc; }
.cal-day-v2.today { background: #eff6ff; color: var(--primary-color); font-weight: 700; border: 1px solid #bfdbfe; }
.cal-day-v2.active { 
    background: var(--primary-color) !important; 
    color: white !important; 
    transform: scale(1.05); 
    box-shadow: 0 10px 15px rgba(79, 70, 229, 0.3); 
    z-index: 10; 
}
.cal-day-v2.has-event { background: rgba(79, 70, 229, 0.1) !important; border: 1px solid rgba(79, 70, 229, 0.2); }
.cal-day-v2.empty { cursor: default; }

.cal-event-markers {
    display: flex;
    gap: 4px;
    justify-content: center;
    width: 100%;
    margin-top: auto; /* Push to bottom of flex container */
    padding-bottom: 2px;
    pointer-events: none;
}
.marker {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.marker.bg-indigo { background: #4f46e5; }
.marker.bg-magenta { background: #ec4899; }
.marker.bg-yellow { background: #f59e0b; }

.btn-cal-nav {
    background: transparent;
    border: none;
    color: white;
    padding: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
}
.btn-cal-nav:hover { background: rgba(255,255,255,0.1); }

/* Modal Helpers */
.color-radio { display: none; }
.color-label {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid transparent;
    transition: all 0.2s;
}
.color-radio:checked + .color-label {
    border-color: white;
    box-shadow: 0 0 0 2px var(--text-muted);
}
.bg-indigo { background: #4f46e5 !important; }
.bg-magenta { background: #ec4899 !important; }
.bg-yellow { background: #f59e0b !important; }

/* Year View Styling */
.year-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
    padding: 0.5rem;
}

.mini-month {
    padding: 1rem;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.mini-month:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}

.mini-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
}

.mini-day {
    aspect-ratio: 1;
    border-radius: 2px;
    background: #f1f5f9;
}

.mini-day.has-event {
    background: var(--primary-color);
}

.mini-day.today {
    background: #ec4899;
}

.mini-day.empty {
    background: transparent;
}

@media (max-width: 1200px) {
    .calendar-page-grid {
        grid-template-columns: 1fr !important;
    }
}
.divider::before, .divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}
.divider span { padding: 0 1rem; }

.oauth-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}
.signup-link { text-align: center; font-size: 0.875rem; color: var(--text-muted); }
.signup-link a { color: var(--primary-color); font-weight: 600;}


/* -----------------------------------------
   Role Selector (Register Page)
   ----------------------------------------- */
.role-selector-group { margin-bottom: 1.5rem; }
.role-selector {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}
.role-option {
    flex: 1;
    cursor: pointer;
}
.role-option input { display: none; }
.role-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.5);
    color: var(--text-dark);
    transition: all 0.3s;
}
.role-card i { font-size: 1.5rem; color: var(--text-muted); }
.role-card span { font-weight: 500; font-size: 0.875rem;}

.role-option input:checked + .role-card {
    background: rgba(255, 255, 255, 0.8);
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.15);
}
.role-option input:checked + .role-card i { color: var(--primary-color); }
.role-option:hover .role-card { background: rgba(255, 255, 255, 0.6); }

/* -----------------------------------------
   Dashboard Layout Structure
   ----------------------------------------- */
.dashboard-page {
    /* Using a fixed colorful gradient for dashboard */
    background: linear-gradient(135deg, #4f46e5 0%, #ec4899 50%, #f59e0b 100%);
}

.layout {
    display: flex;
    height: 100vh;
    overflow: hidden;
}

/* Sidebar (Glassmorphism over gradient, white text) */
.sidebar {
    width: 280px;
    height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 1.5rem 1rem;
    transition: width 0.3s ease;
    flex-shrink: 0;
    margin: 0;
    
    /* Special glass for sidebar with white text */
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-right: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 0;
    backdrop-filter: var(--glass-blur);
    color: var(--text-light);
}

.sidebar .logo {
    color: var(--text-light); /* Override default dark logo */
}
.sidebar .logo i {
    color: var(--text-light); 
}

.sidebar-header { margin-bottom: 2rem; padding: 0 0.5rem; }

.sidebar-nav {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 2rem;
    overflow-y: auto;
}
.sidebar .search-box input {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
    color: var(--text-light);
}
.sidebar .search-box input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}
.sidebar .search-box i {
    color: rgba(255, 255, 255, 0.6);
}

.sidebar .nav-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.7);
    transition: all 0.2s;
    font-weight: 500;
}
.sidebar .nav-item i { font-size: 1.25rem; }
.sidebar .nav-item:hover { background: rgba(255, 255, 255, 0.1); color: var(--text-light); }
.nav-item:hover, .nav-item.active {
    background: rgba(255,255,255,0.12);
    color: var(--primary-color);
}

/* Sidebar Submenu */
.nav-group {
    display: flex;
    flex-direction: column;
}
.nav-toggle .nav-arrow {
    transition: transform 0.3s ease;
    font-size: 1rem;
}
.nav-toggle.open .nav-arrow {
    transform: rotate(90deg);
}
.nav-submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, opacity 0.3s ease;
    opacity: 0;
    padding-left: 1rem;
}
.nav-submenu.open {
    max-height: 300px;
    opacity: 1;
}
.nav-sub-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6rem 1rem 0.6rem 1.5rem;
    color: var(--text-light);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    border-radius: 10px;
    transition: all 0.2s;
}
.nav-sub-item:hover {
    background: rgba(255,255,255,0.1);
    color: var(--primary-color);
}
.nav-sub-item i {
    font-size: 1rem;
}
.sidebar .nav-item.active {
    background: rgba(255, 255, 255, 0.25);
    color: var(--text-light);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.sidebar-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 1rem;
    margin-top: auto;
}
.sidebar .user-profile {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    margin-top: 1rem;
    color: var(--text-light);
    border-radius: 12px;
}
.sidebar .user-info span { color: rgba(255, 255, 255, 0.6); }

/* Main Content (Solid white card overlapping the gradient) */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: calc(100vh - 1rem); /* Slight margin top/bottom */
    margin: 0.5rem 0.5rem 0.5rem 0; /* Margin on right, none on left since sidebar is there */
    border-radius: 20px;
    background: #ffffff;
    box-shadow: -10px 0 30px rgba(0,0,0,0.1);
    overflow-y: auto;
    padding: 2rem;
    color: var(--text-dark);
}

.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 0.5rem;
}
.menu-toggle { display: none; }
.topbar .glass-btn {
    background: #f1f5f9;
    color: var(--text-dark);
    border-color: #e2e8f0;
}
.topbar .glass-btn:hover { background: #e2e8f0; }

.content-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* -----------------------------------------
   Componente Core: Cartão da Questão
   ----------------------------------------- */
.question-stage {
    width: 100%;
    max-width: 800px;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin: 0 auto;
}

.question-card {
    padding: 2.5rem;
    /* Inner card styling different from sidebar glass */
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    border-radius: 16px;
    color: var(--text-dark);
}

.q-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 1rem;
}
.q-meta {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.q-tag {
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}
.q-tag.subject { color: #4f46e5; background: #e0e7ff; }
.q-tag.difficulty { color: #d97706; background: #fef3c7; }
.q-tag.id { color: var(--text-muted); font-family: monospace; background: #f1f5f9;}
.q-source { font-weight: 600; color: var(--text-muted); }

.q-body {
    font-size: 1.125rem;
    line-height: 1.7;
    margin-bottom: 2.5rem;
    word-break: break-word;
    color: var(--text-dark);
}
.q-body p { margin-bottom: 1rem; }
.q-body img { 
    max-width: 100%; 
    border-radius: 8px; 
    margin: 1rem 0; 
    box-shadow: 0 4px 12px rgba(0,0,0,0.1); 
}

.q-alternatives {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.alternative {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.25rem;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    color: var(--text-dark);
    font-size: 1rem;
    line-height: 1.5;
}
.alternative:hover {
    background: #f1f5f9;
    transform: translateX(4px);
    border-color: #cbd5e1;
}
.alternative.selected {
    background: #e0e7ff;
    border-color: var(--primary-color);
}
.alternative.correct {
    background: #d1fae5;
    border-color: var(--success);
}
.alternative.incorrect {
    background: #fee2e2;
    border-color: var(--error);
}

.alt-letter {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: #ffffff;
    border-radius: 50%;
    font-weight: 700;
    flex-shrink: 0;
    border: 1px solid #e2e8f0;
    color: var(--text-dark);
}

.alternative.selected .alt-letter { background: var(--primary-color); color: white; border-color: var(--primary-color); }
.alternative.correct .alt-letter { background: var(--success); color: white; border-color: var(--success); }
.alternative.incorrect .alt-letter { background: var(--error); color: white; border-color: var(--error); }

.alt-text { flex: 1; }

.stage-actions {
    display: flex;
    justify-content: flex-end;
}

/* Feedback Drawer */
.feedback-drawer {
    margin-top: 1.5rem;
    padding: 1.5rem;
    border-left: 4px solid var(--primary-color);
    background: #f8fafc;
    border-radius: 0 12px 12px 0;
    animation: slideDown 0.3s ease-out;
}
.feedback-drawer.success-bd { border-left-color: var(--success); }
.feedback-drawer.error-bd { border-left-color: var(--error); }

.feedback-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    font-size: 1.125rem;
    font-weight: 600;
}
.feedback-content {
    color: var(--text-dark);
    line-height: 1.6;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}


/* -----------------------------------------
   Responsive Adjustments
   ----------------------------------------- */
@media (max-width: 900px) {
    /* Collapse Sidebar */
    .sidebar {
        width: 80px;
        padding: 1.5rem 0.5rem;
    }
    .nav-text, .sidebar .search-box input { display: none; }
    .sidebar .search-box { padding: 0.5rem; display: flex; justify-content: center;}
    .sidebar .search-box i { position: static; transform: none; }
    .sidebar .nav-item { justify-content: center; padding: 0.75rem; }
    .sidebar .nav-item i { margin: 0; }
    
    .sidebar.expanded {
        width: 280px;
        position: absolute;
        z-index: 1000;
        background: rgba(30, 41, 59, 0.9); /* Darker glass for mobile expanded */
        backdrop-filter: blur(20px);
    }
    .sidebar.expanded .nav-text, .sidebar.expanded .search-box input { display: block; }

    /* Show topbar menu toggle */
    .menu-toggle { display: inline-flex; }

    .main-content {
        margin: 0;
        border-radius: 20px 0 0 20px;
    }
    .question-stage { width: 100%; max-width: 100%; padding: 0 1rem; }
}

@media (max-width: 768px) {
    .desktop-nav { display: none; }
    .mobile-menu-btn { display: inline-flex; }
    .hero h1 { font-size: 2.5rem; }
}

/* -----------------------------------------
   New Dashboard Widgets Elements
   ----------------------------------------- */
   
/* Dark mode toggle switch (Removed) */

/* Dashboard Wrapper & Grid */
.dashboard-wrapper {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 2rem;
    margin-top: 1rem;
}
.middle-col { display: flex; flex-direction: column; gap: 2rem; }
.right-col { display: flex; flex-direction: column; gap: 1.5rem; position: relative;}

/* Promo Card */
.promo-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2.5rem;
    background: #ffffff; /* Use pure white for cards to pop against color */
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    overflow: hidden;
    position: relative;
    border: 1px solid #f1f5f9;
    transition: transform 0.3s, box-shadow 0.3s;
    text-decoration: none;
}
.promo-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.08);
}
.promo-info { z-index: 2; }
.promo-info h2 { font-size: 1.75rem; color: var(--text-dark); margin-top: 0.5rem;}
.promo-icon { font-size: 2rem; color: #6b21a8; }
.promo-illustration { position: absolute; right: 2rem; bottom: -1rem; opacity: 0.9;}

.section-title h2 {
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--text-dark);
}

/* 2x2 Feature Grid inside Middle Col */
.q-features-grid {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 1.5rem;
}

.feature-grid-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.feature-card-dash {
    background: #ffffff;
    border-radius: 20px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    border: 1px solid #f1f5f9;
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
    transition: transform 0.2s, box-shadow 0.2s;
}
.feature-card-dash.clickable:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
}
.feature-icon {
    font-size: 1.75rem;
    color: var(--text-dark);
    margin-bottom: 1rem;
    background: #f8fafc;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}
.feature-card-dash .card-title {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 1.1rem;
}

.tall-card { padding: 2rem; justify-content: flex-start;}
.feature-header { text-align: center; margin-bottom: 2rem; }
.empty-state {
    text-align: center;
    color: var(--text-muted);
    margin-top: auto;
    margin-bottom: auto;
}
.empty-state h3 { font-size: 1.5rem; font-weight: 400; color: #94a3b8; margin-top: 0.5rem;}
.pro-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: #e2e8f0;
    color: #64748b;
    font-size: 0.7rem;
    padding: 0.1rem 0.5rem;
    border-radius: 8px;
    font-weight: 700;
    text-transform: uppercase;
}

/* Replaced by consolidated calendar styles above */

.highlight-yellow {
    background: #fef08a; /* Soft yellow */
    color: #854d0e;
}
.highlight-purple {
    background: #e9d5ff; /* Soft purple */
    color: #6b21a8;
}

.events-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin-bottom: 1.5rem;
    color: var(--text-muted);
    font-size: 1.125rem;
    font-weight: 500;
}
.events-divider::before, .events-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e2e8f0;
}
.events-divider span { padding: 0 1rem; }
.event-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #f1f5f9;
}
.event-item:last-child { border-bottom: none; margin-bottom: 0; padding-bottom: 0;}
.event-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}
.bg-yellow { background: #f59e0b; }
.bg-purple { background: #a855f7; }
.event-details { display: flex; flex-direction: column; gap: 0.25rem;}
.event-details strong { font-size: 0.9rem; color: var(--text-dark); line-height: 1.3;}
.event-details span { font-size: 0.75rem; color: var(--text-muted);}

/* Fixed Assistant Button */
.assistant-btn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: white;
    border-radius: 50px;
    padding: 0.5rem 1rem 0.5rem 0.5rem;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    z-index: 100;
    border: none;
    cursor: pointer;
    transition: transform 0.3s;
}
.assistant-btn:hover { transform: scale(1.05); }
.tutor-avatar { width: 40px; height: 40px; border-radius: 50%; }
.tutor-label { font-weight: 600; color: var(--text-dark); margin-right: 0.5rem;}

/* Fix alignment in topbar */
.topbar-actions { display: flex; align-items: center; gap: 1rem; }

/* -----------------------------------------
   Cronogramas Page (Study Schedules)
   ----------------------------------------- */
.crono-board {
    border-radius: 24px;
    padding: 2.5rem;
    overflow: hidden;
    position: relative;
    border: none;
}

/* Designing Unique Premium Boards instead of plain flat magenta boxes */
.premium-board {
    background: linear-gradient(135deg, #4f46e5 0%, #a855f7 100%);
    color: white;
    box-shadow: 0 15px 35px rgba(79, 70, 229, 0.2);
}
.secondary-board {
    background: linear-gradient(135deg, #ec4899 0%, #f43f5e 100%);
    color: white;
    box-shadow: 0 15px 35px rgba(236, 72, 153, 0.2);
}

.board-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 1rem;
}
.board-header h2 { font-size: 1.5rem; font-weight: 600; }
.board-header i { font-size: 2rem; }

.crono-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
}

.crono-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 1.5rem;
    color: var(--text-dark);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s;
    position: relative;
    min-height: 140px;
    text-decoration: none;
}
.crono-card i {
    font-size: 1.75rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}
.secondary-board .crono-card i { color: #ec4899; } /* match secondary pink theme */

.crono-card p {
    font-weight: 500;
    line-height: 1.4;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.crono-action-hint {
    margin-top: auto;
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s;
}

.crono-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
}
.crono-card:hover .crono-action-hint {
    opacity: 1;
    transform: translateY(0);
    color: var(--primary-color);
}
.secondary-board .crono-card:hover .crono-action-hint { color: #ec4899; }

/* Right Index Nav */
.crono-index {
    position: sticky;
    top: 2rem;
    padding: 1.5rem;
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
}
.crono-index-list { list-style: none; padding: 0; margin: 0; }
.crono-index-list li { margin-bottom: 1rem; }
.crono-index-list li:last-child { margin-bottom: 0; }
.crono-index-list a {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.4;
    transition: color 0.2s;
}
.crono-index-list a i { color: #cbd5e1; margin-top: 2px;}
.crono-index-list a:hover, .crono-index-list a.active {
    color: var(--primary-color);
    font-weight: 500;
}
.crono-index-list a.active i { color: var(--primary-color); }

/* -----------------------------------------
   Filtros de Questões Page (.filter-builder)
   ----------------------------------------- */
.filter-builder {
    background: #ffffff;
    border-radius: 20px;
    padding: 2.5rem;
    border: 1px solid #f1f5f9;
}
.filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #f1f5f9;
    padding-bottom: 2rem;
    margin-bottom: 2rem;
}
.filter-header-text h1 {
    font-size: 1.5rem;
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.filter-header-text p {
    color: var(--text-dark);
    font-size: 1rem;
    font-weight: 500;
}
.filter-form {
    display: flex;
    flex-direction: column;
}
.filter-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem 3rem;
}
.filter-field {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.filter-field label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-dark);
}

.pseudo-input {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    background: #f8fafc; /* overriding glass slightly for form legibility */
}
.pseudo-input .placeholder { color: var(--text-muted); font-size: 0.95rem; }
.pseudo-input .chev { color: var(--text-muted); font-size: 1.25rem; }
.pseudo-input .badge { margin-left: auto; margin-right: 0.5rem; }

.badge-purple {
    background: #f3e8ff;
    color: var(--primary-color);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.text-search { background: #f8fafc; }

/* Chips */
.chip-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}
.chip input { display: none; }
.chip-label {
    padding: 0.5rem 1.25rem;
    border-radius: 20px;
    background: #f1f5f9;
    color: #64748b;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid transparent;
}
.chip-label:hover { background: #e2e8f0; }
.chip-label.active {
    background: #ffffff;
    border-color: var(--primary-color);
    color: var(--primary-color);
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.1);
}

.filter-actions-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 1.5rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid #f1f5f9;
}
/* specific btn overrides for filter */
.btn-clear { border-color: #f1f5f9; color: #cbd5e1; }
.btn-clear:hover { border-color: #fca5a5; color: #ef4444; background: #fef2f2; }
.btn-submit { padding: 0.75rem 2rem; font-size: 1rem; }

/* -----------------------------------------
   Prática Guiada Page (.pratica-layout)
   ----------------------------------------- */
.pratica-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 2rem;
    margin-top: 1rem;
}

.pratica-col-main {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.pratica-header-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 2.5rem;
    border: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.pratica-text h1 {
    font-size: 1.5rem;
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.pratica-text p {
    color: var(--text-dark);
    font-size: 1rem;
    font-weight: 500;
    max-width: 500px;
}

.subject-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.subject-item {
    background: #ffffff;
    border-radius: 16px;
    padding: 1.25rem 1.5rem;
    border: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    text-decoration: none;
    color: var(--text-dark);
    transition: transform 0.2s, box-shadow 0.2s;
}
.subject-item:hover {
    transform: translateX(8px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    border-color: #e2e8f0;
}
.subject-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #cbd5e1;
    font-size: 1.25rem;
    transition: background 0.2s, color 0.2s;
}
.subject-item:hover .subject-icon {
    background: #e0e7ff;
    color: var(--primary-color);
}
.subject-name {
    font-weight: 600;
    font-size: 1.1rem;
}

/* Provas Accordion */
.prova-accordion-group { display: flex; flex-direction: column; }
.prova-toggle {
    cursor: pointer;
    border: none;
    width: 100%;
    text-align: left;
    font-family: 'Inter', sans-serif;
}
.prova-toggle .prova-arrow {
    transition: transform 0.3s ease;
    font-size: 1.25rem;
}
.prova-toggle.expanded {
    border-color: var(--primary-color);
    background: #f5f3ff;
}
.prova-toggle.expanded .subject-icon {
    background: #e0e7ff;
    color: var(--primary-color);
}
.prova-panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease;
    padding: 0 0.5rem;
}
.prova-panel.open {
    max-height: 2000px;
    padding: 1.25rem 0.5rem;
}
.exam-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 0.75rem;
}
.exam-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    border: 1px solid #f1f5f9;
    transition: transform 0.2s, box-shadow 0.2s;
}
.exam-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.12);
    border-color: #c7d2fe;
}
.exam-card-img {
    width: 60px;
    height: 60px;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.exam-card-img img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.3s;
}
.exam-card:hover .exam-card-img img {
    transform: scale(1.1);
}
.exam-card-name {
    font-size: 0.75rem;
    font-weight: 700;
    color: #334155;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center;
}

/* Exam Modal Navigation Grid */
.exam-nav-header {
    background: #f8fafc;
    padding: 1rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    border: 1px solid #e2e8f0;
}

.question-nav-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.nav-q-item {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s;
}

.nav-q-item:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: #f5f3ff;
}

.nav-q-item.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
}

.nav-q-item.correct {
    background: #10b981;
    color: white;
    border-color: #10b981;
}

.nav-q-item.incorrect {
    background: #ef4444;
    color: white;
    border-color: #ef4444;
}

.exam-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #f1f5f9;
}

.pratica-col-side {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* PRO Ad Card */
.pro-ad-card {
    border-radius: 20px;
    padding: 2.5rem 1.5rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}
.pro-ad-content {
    margin-bottom: 2rem;
    z-index: 2;
}
.pro-ad-content h3 {
    font-size: 1.5rem;
    font-style: italic;
    font-weight: 800;
    margin-bottom: 1rem;
    text-shadow: 0 2px 10px rgba(0,0,0,0.2);
    letter-spacing: 1px;
}
.pro-ad-content p {
    font-weight: 500;
}
.btn-pro-action {
    background: #ffffff;
    color: var(--primary-color);
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: transform 0.2s, box-shadow 0.2s;
    z-index: 2;
}
.btn-pro-action:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

/* Sidebar Events Widget */
.events-widget {
    background: #ffffff;
    border-radius: 20px;
    padding: 1.5rem;
    border: 1px solid #f1f5f9;
}
.events-widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}
.events-widget-header h4 {
    font-size: 0.85rem;
    color: var(--primary-color);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.btn-outline-sm {
    border: 1px solid #e2e8f0;
    background: transparent;
    color: #64748b;
    padding: 0.25rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    transition: all 0.2s;
}
.btn-outline-sm:hover {
    background: #f8fafc;
    color: var(--text-dark);
}

.mini-event-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.mini-event-item {
    display: flex;
    align-items: stretch;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f8fafc;
}
.mini-event-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}
.mini-event-date {
    padding: 0.5rem 0.75rem;
    color: white;
    font-weight: 700;
    font-size: 0.8rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.bg-indigo { background: #4f46e5; }
.bg-magenta { background: #ec4899; }
.mini-event-desc {
    font-size: 0.9rem;
    color: var(--text-dark);
    font-weight: 500;
    display: flex;
    align-items: center;
    line-height: 1.3;
}

/* -----------------------------------------
   Simulados Page (.simulados-layout)
   ----------------------------------------- */
.simulados-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.simulado-card {
    background: #ffffff;
    border-radius: 24px;
    padding: 2.5rem 2rem;
    border: 1px solid #f1f5f9;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s;
    min-height: 380px;
    position: relative;
    overflow: hidden;
}
.simulado-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.06);
    border-color: #e2e8f0;
}

.simulado-card-title {
    font-size: 1.75rem;
    color: #475569;
    font-weight: 300;
    line-height: 1.3;
    z-index: 2;
    margin-bottom: auto;
}

.simulado-card-image {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    margin-top: 2rem;
    z-index: 1;
}
.simulado-card-image img {
    max-height: 220px;
    object-fit: contain;
    transition: transform 0.5s ease;
}
.simulado-card:hover .simulado-card-image img {
    transform: scale(1.05);
}

/* -----------------------------------------
   Desempenho Page (.desempenho-layout)
   ----------------------------------------- */
.desempenho-section-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 2rem 2.5rem;
    border: 1px solid #f1f5f9;
    margin-bottom: 2rem;
}
.section-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}
.section-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: #334155;
}
.date-filter-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #64748b;
}
.date-input {
    padding: 0.4rem 0.6rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.85rem;
    font-family: 'Inter', sans-serif;
    color: #334155;
    background: #f8fafc;
}
.btn-filter-apply {
    padding: 0.4rem 1rem;
    border: none;
    background: var(--primary-color);
    color: #fff;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.2s;
}
.btn-filter-apply:hover { background: #4338ca; }

/* Highlight Row */
.highlight-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

/* Donut Card */
.donut-card {
    background: #f8fafc;
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.donut-label {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1rem;
}
.donut-wrapper {
    position: relative;
    width: 120px;
    height: 120px;
    margin-bottom: 1rem;
}
.donut-svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}
.donut-bg {
    fill: none;
    stroke: #e2e8f0;
    stroke-width: 3.5;
}
.donut-fill {
    fill: none;
    stroke: var(--primary-color);
    stroke-width: 3.5;
    stroke-linecap: round;
    transition: stroke-dasharray 1s ease-out;
}
.donut-center-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.5rem;
    font-weight: 700;
    color: #334155;
}
.donut-sub {
    font-size: 0.8rem;
    color: #94a3b8;
    font-style: italic;
    line-height: 1.4;
}

/* Highlight Stat Cards (green / red) */
.highlight-stat {
    border-radius: 16px;
    padding: 1.5rem 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #fff;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s;
}
.highlight-stat:hover { transform: translateY(-4px); }
.highlight-stat.green { background: linear-gradient(135deg, #10b981, #34d399); }
.highlight-stat.red   { background: linear-gradient(135deg, #ef4444, #f87171); }
.highlight-stat h2 { font-size: 2.5rem; font-weight: 800; margin-bottom: 0.25rem; }
.highlight-stat span { font-size: 0.95rem; font-weight: 600; }
.highlight-icon {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 2.5rem;
    opacity: 0.3;
}

/* Info Cards Row */
.info-cards-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}
.info-card {
    background: #f8fafc;
    border-radius: 14px;
    padding: 1.25rem;
    border: 1px solid #f1f5f9;
}
.info-card-label {
    font-size: 0.8rem;
    color: #64748b;
    font-weight: 600;
    display: block;
    margin-bottom: 0.5rem;
}
.info-card-value {
    font-size: 1.15rem;
    color: #334155;
}

/* Review Table */
.review-table-wrapper { overflow-x: auto; }
.review-table {
    width: 100%;
    border-collapse: collapse;
}
.review-table th {
    text-align: left;
    padding: 0.75rem 1rem;
    border-bottom: 2px solid #e2e8f0;
    font-size: 0.85rem;
    color: #64748b;
    font-weight: 700;
    font-style: italic;
}
.review-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.9rem;
    color: #334155;
}
.empty-table-msg {
    text-align: center;
    color: #94a3b8;
    font-style: italic;
    padding: 2rem 0;
    font-size: 0.9rem;
}

/* Essay Grid */
.essay-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}
.essay-card {
    background: #f8fafc;
    border-radius: 16px;
    padding: 1.5rem;
    border: 1px solid #f1f5f9;
}
.essay-card h4 {
    font-size: 0.95rem;
    color: #334155;
    font-weight: 600;
    margin-bottom: 1.5rem;
    text-align: center;
}
.essay-chart-placeholder {
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.empty-state-text {
    color: #94a3b8;
    font-style: italic;
    font-size: 0.9rem;
}

.desempenho-header {
    background: #ffffff;
    border-radius: 20px;
    padding: 2.5rem;
    border: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}
.desempenho-text h1 {
    font-size: 1.75rem;
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.desempenho-text p {
    color: var(--text-dark);
    font-size: 1.05rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}
.stat-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 1.5rem;
    border: 1px solid #f1f5f9;
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
    transition: transform 0.2s, box-shadow 0.2s;
}
.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
}
.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}
.bg-success-light { background: #d1fae5; }
.bg-error-light { background: #fee2e2; }
.bg-primary-light { background: #e0e7ff; }
.bg-warning-light { background: #fef3c7; }

.stat-info { display: flex; flex-direction: column; }
.stat-label { font-size: 0.85rem; color: #64748b; font-weight: 600; margin-bottom: 0.25rem;}
.stat-value { font-size: 1.5rem; font-weight: 700; color: #334155; margin-bottom: 0.5rem;}
.stat-perc { font-size: 0.75rem; font-weight: 600; display: flex; align-items: center; gap: 0.25rem;}
.stat-perc.positive { color: #10b981; }
.stat-perc.negative { color: #ef4444; }
.stat-perc.neutral { color: #64748b; }

.performance-bottom-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}
.panel-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #334155;
    margin-bottom: 1.5rem;
}
.subject-performance, .activity-chart {
    background: #ffffff;
    border-radius: 20px;
    padding: 2rem;
    border: 1px solid #f1f5f9;
}

.subject-progress-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}
.progress-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.progress-info {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: #475569;
    font-weight: 600;
}
.progress-bar-bg {
    width: 100%;
    height: 8px;
    background: #f1f5f9;
    border-radius: 4px;
    overflow: hidden;
}
.progress-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 1s ease-out;
}

.panel-header-split {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}
.pseudo-select {
    padding: 0.25rem 0.75rem;
    background: #f8fafc;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chart-mockup {
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    height: 200px;
    padding-top: 1rem;
    border-bottom: 2px solid #f1f5f9;
    margin-bottom: 1rem;
}
.chart-bar {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    height: 100%;
    justify-content: flex-end;
    color: #94a3b8;
    font-size: 0.8rem;
    font-weight: 600;
}
.bar-fill {
    width: 32px;
    background: #cbd5e1;
    border-radius: 6px 6px 0 0;
    transition: height 1s ease-out, background 0.3s;
}
.chart-bar:hover .bar-fill {
    background: var(--primary-color);
}
/* -----------------------------------------
   Temas / Redações Page
   ----------------------------------------- */
.temas-layout {
    padding: 1rem 2rem 3rem;
}
.temas-page-title {
    font-size: 2rem;
    font-weight: 400;
    color: var(--text-dark);
    margin-bottom: 1.5rem;
}

/* Hero: Tema da Semana */
.tema-hero {
    margin-bottom: 2rem;
    border-radius: 20px;
    overflow: hidden;
}
.tema-hero-inner {
    position: relative;
    width: 100%;
    height: 340px;
    background-size: cover;
    background-position: center;
    border-radius: 20px;
    display: flex;
    align-items: flex-end;
}
.tema-hero-overlay {
    width: 100%;
    padding: 2.5rem 3rem;
    background: linear-gradient(transparent, rgba(0,0,0,0.75));
    border-radius: 0 0 20px 20px;
}
.tema-hero-label {
    font-size: 2.5rem;
    font-weight: 900;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
}
.tema-hero-title {
    font-size: 1.15rem;
    color: rgba(255,255,255,0.9);
    font-weight: 500;
    font-style: italic;
}

/* Toolbar */
.temas-toolbar {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}
.search-box {
    display: flex;
    flex: 1;
    min-width: 200px;
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
}
.tema-search-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 0.7rem 1rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    color: #334155;
}
.tema-search-input::placeholder { color: #94a3b8; }
.tema-search-btn {
    border: none;
    background: none;
    padding: 0 1rem;
    color: #64748b;
    font-size: 1.1rem;
    cursor: pointer;
    transition: color 0.2s;
}
.tema-search-btn:hover { color: var(--primary-color); }
.filter-select-wrapper {
    position: relative;
}
.tema-select {
    appearance: none;
    padding: 0.7rem 2.5rem 0.7rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #ffffff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") no-repeat right 1rem center;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    color: #334155;
    cursor: pointer;
    min-width: 160px;
}
.tema-select:focus { outline: 2px solid var(--primary-color); border-color: transparent; }

/* Section Title */
.temas-section-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: #334155;
    margin-bottom: 1.5rem;
}

/* Themes Grid */
.temas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}
.tema-card {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    text-decoration: none;
    aspect-ratio: 3 / 4;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}
.tema-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(99, 102, 241, 0.18);
}
.tema-card-img {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transition: transform 0.4s;
}
.tema-card:hover .tema-card-img {
    transform: scale(1.08);
}
.tema-card-content {
    position: relative;
    z-index: 1;
    padding: 1.25rem;
    background: linear-gradient(transparent, rgba(0,0,0,0.78));
}
.tema-card-title {
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 0.5rem;
}
.tema-card-stars i {
    color: #fbbf24;
    font-size: 0.9rem;
}
.tema-card-stars {
    display: flex;
    gap: 2px;
}

/* Pagination (placeholder styling) */
.temas-pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}
.temas-pagination button {
    padding: 0.5rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #fff;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: all 0.2s;
}
.temas-pagination button.active,
.temas-pagination button:hover {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}
/* -----------------------------------------
   Minhas Redações Page
   ----------------------------------------- */
.redacoes-layout { padding: 1rem 2rem 3rem; }

.redacoes-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}
.redacoes-page-title {
    font-size: 2rem;
    font-weight: 700;
    color: #334155;
}
.redacoes-page-desc {
    color: #64748b;
    font-size: 0.95rem;
    margin-top: 0.25rem;
}
.btn-nova-redacao {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.7rem 1.5rem;
    background: var(--primary-color);
    color: #fff;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: background 0.2s, transform 0.2s;
}
.btn-nova-redacao:hover { background: #4338ca; transform: translateY(-2px); }

/* Stats Cards */
.redacoes-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}
.redacao-stat-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border: 1px solid #f1f5f9;
}
.redacao-stat-card i {
    font-size: 1.75rem;
}
.stat-num {
    display: block;
    font-size: 1.5rem;
    font-weight: 800;
    color: #334155;
}
.stat-lbl {
    font-size: 0.8rem;
    color: #94a3b8;
    font-weight: 600;
}

/* Filter Bar */
.redacoes-filter-bar {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}
.redacao-filter-btn {
    padding: 0.5rem 1.25rem;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #ffffff;
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.2s;
}
.redacao-filter-btn:hover { border-color: var(--primary-color); color: var(--primary-color); }
.redacao-filter-btn.active {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

/* Essay Cards List */
.redacoes-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.redacao-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 1.5rem 2rem;
    border: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    transition: transform 0.2s, box-shadow 0.2s;
}
.redacao-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.06);
}
.redacao-card-left { flex: 1; }
.redacao-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.3rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}
.status-corrected { background: #d1fae5; color: #059669; }
.status-pending { background: #fef3c7; color: #d97706; }
.redacao-card-title {
    font-size: 1.05rem;
    font-weight: 600;
    color: #334155;
    margin-bottom: 0.4rem;
}
.redacao-card-date {
    font-size: 0.8rem;
    color: #94a3b8;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}
.redacao-card-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.75rem;
}
.redacao-nota {
    font-size: 2rem;
    font-weight: 800;
    color: #334155;
}
.redacao-nota small { font-size: 0.9rem; color: #94a3b8; font-weight: 500; }
.redacao-nota.pending { color: #cbd5e1; font-size: 1.5rem; }
.btn-ver-correcao {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 1rem;
    border: 1px solid var(--primary-color);
    border-radius: 10px;
    background: transparent;
    color: var(--primary-color);
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.btn-ver-correcao:hover { background: var(--primary-color); color: #fff; }

/* Empty State */
.redacoes-empty {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    text-align: center;
    color: #94a3b8;
}
.redacoes-empty i { font-size: 3rem; margin-bottom: 1rem; }
.redacoes-empty h3 { color: #64748b; margin-bottom: 0.5rem; }

/* ===== Correction Modal ===== */
.correcao-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(4px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}
.correcao-modal {
    background: #ffffff;
    border-radius: 24px;
    padding: 2.5rem;
    max-width: 600px;
    width: 100%;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    animation: modalSlide 0.3s ease;
}
@keyframes modalSlide {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
.correcao-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    border: none;
    background: #f1f5f9;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}
.correcao-close:hover { background: #e2e8f0; color: #334155; }
.correcao-header h2 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #334155;
    margin-bottom: 0.25rem;
    padding-right: 2rem;
}
.correcao-date { font-size: 0.8rem; color: #94a3b8; }
.correcao-nota-row {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
    margin: 1.5rem 0;
}
.nota-final-circle {
    font-size: 3rem;
    font-weight: 900;
    color: var(--primary-color);
}
.nota-max {
    font-size: 1.1rem;
    color: #94a3b8;
    font-weight: 500;
}

/* Competencies */
.competencias-grid {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.competencia-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.35rem;
}
.competencia-info span { font-size: 0.8rem; color: #64748b; }
.competencia-info strong { font-size: 0.8rem; color: #334155; }
.competencia-bar-bg {
    height: 8px;
    background: #f1f5f9;
    border-radius: 4px;
    overflow: hidden;
}
.competencia-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.6s ease;
}

/* Comments */
.correcao-comments {
    background: #f8fafc;
    border-radius: 14px;
    padding: 1.25rem;
    border: 1px solid #f1f5f9;
}
.correcao-comments h4 {
    font-size: 0.9rem;
    font-weight: 700;
    color: #334155;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.correcao-comments p {
    font-size: 0.85rem;
    color: #475569;
    line-height: 1.6;
}

/* -----------------------------------------
   Study Hub (Cronogramas)
   ----------------------------------------- */
.study-hub-layout { padding: 1rem 2rem 3rem; }
.study-hub-header { margin-bottom: 1.5rem; }
.study-hub-title { font-size: 2rem; font-weight: 700; color: #334155; }
.study-hub-desc { color: #64748b; font-size: 0.95rem; margin-top: 0.25rem; }

/* Stats */
.study-stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}
.study-stat {
    background: #fff;
    border-radius: 16px;
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border: 1px solid #f1f5f9;
}
.study-stat i { font-size: 1.75rem; }

/* Tabs */
.study-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid #f1f5f9;
    padding-bottom: 0;
}
.study-tab {
    padding: 0.75rem 1.5rem;
    border: none;
    background: none;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    color: #94a3b8;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    transition: color 0.2s, border-color 0.2s;
}
.study-tab:hover { color: #334155; }
.study-tab.active { color: var(--primary-color); border-bottom-color: var(--primary-color); }
.study-tab-content { display: none; }
.study-tab-content.active { display: block; }

/* Weekly Planner */
.weekly-planner {
    background: #fff;
    border-radius: 20px;
    padding: 2rem;
    border: 1px solid #f1f5f9;
    margin-bottom: 2rem;
}
.planner-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}
.planner-header h2 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.planner-week {
    font-size: 0.85rem;
    color: #94a3b8;
    font-weight: 500;
}

/* Day Tabs */
.day-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    overflow-x: auto;
}
.day-tab {
    flex: 1;
    min-width: 70px;
    padding: 0.75rem 0.5rem;
    border: 1px solid #f1f5f9;
    border-radius: 14px;
    background: #fff;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}
.day-tab:hover { border-color: #c7d2fe; }
.day-tab.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
}
.day-name { font-weight: 700; font-size: 0.8rem; }
.day-date { font-size: 0.7rem; opacity: 0.75; }
.day-progress { font-size: 0.65rem; opacity: 0.6; }
.day-tab.active .day-name,
.day-tab.active .day-date,
.day-tab.active .day-progress { color: #fff; opacity: 1; }

/* Task Items */
.day-tasks { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 1rem; }
.task-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    transition: all 0.2s;
}
.task-item.done { opacity: 0.55; }
.task-item.done .task-text { text-decoration: line-through; }
.task-check {
    border: none;
    background: none;
    font-size: 1.25rem;
    color: #cbd5e1;
    cursor: pointer;
    padding: 0;
    transition: color 0.2s;
}
.task-item.done .task-check { color: #10b981; }
.task-text { font-size: 0.9rem; color: #334155; font-weight: 500; }
.empty-day { text-align: center; color: #94a3b8; padding: 1.5rem; font-size: 0.9rem; }
.btn-add-task {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1rem;
    border: 1px dashed #cbd5e1;
    border-radius: 10px;
    background: none;
    color: #94a3b8;
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
    width: 100%;
    justify-content: center;
}
.btn-add-task:hover { border-color: var(--primary-color); color: var(--primary-color); }

/* Section Label */
.section-label {
    font-size: 1.15rem;
    font-weight: 700;
    color: #334155;
    margin-bottom: 1rem;
}

/* Pre-made Schedule Grid */
.premade-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}
.premade-card {
    background: #fff;
    border-radius: 16px;
    padding: 1.25rem;
    border: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
}
.premade-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.06);
}
.premade-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}
.premade-info h4 { font-size: 0.9rem; font-weight: 700; color: #334155; margin-bottom: 0.15rem; }
.premade-info p { font-size: 0.78rem; color: #94a3b8; line-height: 1.3; }
.premade-arrow { font-size: 1.25rem; color: #cbd5e1; margin-left: auto; flex-shrink: 0; }

/* Subject Cards */
.materias-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1rem;
}
.materia-card {
    background: #fff;
    border-radius: 18px;
    padding: 1.5rem;
    border: 1px solid #f1f5f9;
    transition: transform 0.2s, box-shadow 0.2s;
}
.materia-card:hover { transform: translateY(-3px); box-shadow: 0 8px 25px rgba(0,0,0,0.05); }
.materia-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}
.materia-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}
.materia-name { font-size: 1rem; font-weight: 700; color: #334155; }
.materia-count { font-size: 0.78rem; color: #94a3b8; }
.materia-pct { margin-left: auto; font-size: 1.25rem; font-weight: 800; }
.materia-bar-bg {
    height: 8px;
    background: #f1f5f9;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 1rem;
}
.materia-bar-fill { height: 100%; border-radius: 4px; transition: width 0.6s ease; }
.materia-topics { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.topic-chip {
    padding: 0.3rem 0.7rem;
    background: #f1f5f9;
    border-radius: 8px;
    font-size: 0.72rem;
    font-weight: 600;
    color: #64748b;
}

/* -----------------------------------------
   Suporte Page
   ----------------------------------------- */
.suporte-layout { padding: 1rem 2rem 3rem; }
.suporte-page-header { margin-bottom: 2rem; }
.suporte-page-header h1 { font-size: 2rem; font-weight: 700; color: #334155; }
.suporte-page-header p { color: #64748b; font-size: 0.95rem; margin-top: 0.25rem; }

/* Quick Actions */
.suporte-quick-actions {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}
.quick-action {
    background: #fff;
    border-radius: 18px;
    padding: 1.5rem;
    border: 1px solid #f1f5f9;
    cursor: pointer;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}
.quick-action:hover { transform: translateY(-4px); box-shadow: 0 10px 30px rgba(0,0,0,0.06); }
.quick-action i { font-size: 2rem; margin-bottom: 0.75rem; display: block; }
.quick-action h4 { font-size: 0.95rem; font-weight: 700; color: #334155; margin-bottom: 0.25rem; }
.quick-action p { font-size: 0.78rem; color: #94a3b8; line-height: 1.35; }

/* Form Section */
.suporte-form-section {
    background: #fff;
    border-radius: 20px;
    padding: 2rem;
    border: 1px solid #f1f5f9;
    margin-bottom: 2rem;
}
.suporte-form-section h2 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}
.suporte-form { display: flex; flex-direction: column; gap: 1rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group { display: flex; flex-direction: column; gap: 0.35rem; }
.form-group label {
    font-size: 0.82rem;
    font-weight: 600;
    color: #475569;
}
.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.7rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    color: #334155;
    background: #f8fafc;
    transition: border-color 0.2s, box-shadow 0.2s;
    resize: vertical;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: #94a3b8; }
.btn-enviar-suporte {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 2rem;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    align-self: flex-start;
}
.btn-enviar-suporte:hover { background: #4338ca; transform: translateY(-2px); }

/* Success */
.suporte-success {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 2rem;
}
.suporte-success i { font-size: 3rem; color: #10b981; margin-bottom: 1rem; }
.suporte-success h3 { font-size: 1.15rem; color: #334155; margin-bottom: 0.5rem; }
.suporte-success p { color: #64748b; font-size: 0.9rem; }

/* FAQ */
.suporte-faq { margin-bottom: 2rem; }
.suporte-faq h2 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}
.faq-list { display: flex; flex-direction: column; gap: 0.5rem; }
.faq-item {
    background: #fff;
    border-radius: 14px;
    border: 1px solid #f1f5f9;
    overflow: hidden;
}
.faq-question {
    width: 100%;
    padding: 1rem 1.25rem;
    border: none;
    background: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    text-align: left;
}
.faq-arrow { font-size: 1.25rem; color: #94a3b8; transition: transform 0.3s; }
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, padding 0.35s ease;
    padding: 0 1.25rem;
}
.faq-answer.open {
    max-height: 200px;
    padding: 0 1.25rem 1rem;
}
.faq-answer p { font-size: 0.85rem; color: #64748b; line-height: 1.6; }

/* Tickets */
.suporte-tickets {
    background: #fff;
    border-radius: 20px;
    padding: 2rem;
    border: 1px solid #f1f5f9;
}
.suporte-tickets h2 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}
.tickets-list { display: flex; flex-direction: column; gap: 0.5rem; }
.ticket-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.85rem 1.25rem;
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #f1f5f9;
}
.ticket-left { display: flex; align-items: center; gap: 1rem; }
.ticket-id { font-size: 0.78rem; font-weight: 700; color: #94a3b8; min-width: 70px; }
.ticket-subject { font-size: 0.9rem; font-weight: 600; color: #334155; }
.ticket-right { display: flex; align-items: center; gap: 1rem; }
.ticket-date { font-size: 0.78rem; color: #94a3b8; }
.ticket-status {
    padding: 0.25rem 0.7rem;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
}
.ticket-status.status-resolved { background: #d1fae5; color: #059669; }
.ticket-status.status-open { background: #fef3c7; color: #d97706; }
.empty-tickets { text-align: center; color: #94a3b8; padding: 1.5rem; font-size: 0.9rem; }

/* -----------------------------------------
   Credits Counter Widget
   ----------------------------------------- */
.credits-counter {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    cursor: help;
    margin-right: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(5px);
    transition: all 0.3s;
    color: var(--text-dark);
    position: relative; /* Added for tooltip */
}
.credits-counter::after {
    content: attr(data-tooltip);
    position: absolute;
    top: 130%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: rgba(30, 41, 59, 0.95);
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.credits-counter::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    border-width: 6px;
    border-style: solid;
    border-color: transparent transparent rgba(30, 41, 59, 0.95) transparent;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
    z-index: 1000;
}
.credits-counter:hover::after,
.credits-counter:hover::before {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}
.credits-counter:hover {
    background: rgba(255, 255, 255, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(251, 191, 36, 0.2);
}
.credits-icon {
    color: #fbbf24; /* Amber/Gold */
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.credits-text {
    font-size: 0.95rem;
}

/* Responsive Dashboard updates */
@media (max-width: 1200px) {
    .dashboard-wrapper, .crono-layout { grid-template-columns: 1fr; }
    .q-features-grid { grid-template-columns: 1fr; }
    .redacoes-stats { grid-template-columns: repeat(2, 1fr); }
    .redacao-card { flex-direction: column; text-align: center; }
    .redacao-card-right { align-items: center; }
    .study-stats-row { grid-template-columns: repeat(2, 1fr); }
    .premade-grid { grid-template-columns: 1fr; }
    .materias-grid { grid-template-columns: 1fr; }
    .suporte-quick-actions { grid-template-columns: repeat(2, 1fr); }
    .form-row { grid-template-columns: 1fr; }
    .ticket-item { flex-direction: column; gap: 0.5rem; text-align: center; }
    .ticket-left, .ticket-right { justify-content: center; }
}
