﻿:root {
    --primary-color: #4a90e2;
    --secondary-color: #64b5f6;
    --success-color: #4caf50;
    --danger-color: #f44336;
    --warning-color: #ff9800;
    --dark-color: #2c3e50;
    --light-color: #ecf0f1;
    --text-color: #333;
    --border-color: #ddd;
    --shadow: 0 2px 8px rgba(0,0,0,0.1);
    --shadow-lg: 0 4px 16px rgba(0,0,0,0.15);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: var(--text-color);
}

/* Navbar */
.navbar {
    background: white;
    box-shadow: var(--shadow);
    padding: 1rem 0;
    margin-bottom: 2rem;
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar h1 {
    color: var(--primary-color);
    font-size: 1.5rem;
}

.nav-right {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.user-name {
    font-weight: 600;
    color: var(--dark-color);
}

/* Notifications Bell */
.notification-bell,
.notifications-bell {
    position: relative;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
    font-size: 1.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.notification-bell:hover,
.notifications-bell:hover {
    background: rgba(255, 255, 255, 0.2);
}

.bell-icon {
    font-size: 1.5rem;
    display: block;
    line-height: 1;
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--danger-color);
    color: white;
    border-radius: 10px;
    padding: 0.15rem 0.4rem;
    font-size: 0.7rem;
    font-weight: bold;
    min-width: 18px;
    text-align: center;
}

.notifications-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    width: 350px;
    max-height: 500px;
    overflow: hidden;
    display: none;
    z-index: 1000;
    animation: slideDown 0.3s ease;
}

.notifications-dropdown.show {
    display: block;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.notifications-header {
    padding: 1rem;
    border-bottom: 1px solid #e0e0e0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px 12px 0 0;
    font-weight: 600;
}

.dropdown-header {
    padding: 1rem;
    border-bottom: 1px solid #e0e0e0;
    background: #f8f9fa;
    border-radius: 12px 12px 0 0;
}

.notifications-list {
    max-height: 400px;
    overflow-y: auto;
}

.notifications-list:empty::after {
    content: "No hay notificaciones";
    display: block;
    text-align: center;
    padding: 2rem;
    color: #999;
    font-style: italic;
}

.notification-item {
    padding: 1rem;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s ease;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.notification-item:hover {
    background: #f8f9fa;
}

.notification-item:last-child {
    border-bottom: none;
}

.notification-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
    min-width: 0;
}

.notification-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--dark-color);
    font-size: 0.95rem;
}

.notification-text {
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
}

.notification-item.warning {
    border-left: 4px solid var(--warning-color);
}

.notification-item.danger {
    border-left: 4px solid var(--danger-color);
}

.notification-item.success {
    border-left: 4px solid var(--success-color);
}

.notification-item.info {
    border-left: 4px solid var(--primary-color);
}

.notification-item-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--dark-color);
}

.notification-item-message {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.4;
}

/* User Menu */
.user-menu {
    position: relative;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.user-menu:hover {
    background: rgba(255, 255, 255, 0.2);
}

.user-icon {
    font-size: 1.5rem;
    display: block;
    line-height: 1;
}

.user-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    width: 220px;
    overflow: hidden;
    display: none;
    z-index: 1000;
    animation: slideDown 0.3s ease;
}

.user-dropdown.show {
    display: block;
}

.user-menu-item {
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    transition: background 0.2s ease;
    border-top: 1px solid #f0f0f0;
}

.user-menu-item:hover {
    background: #f8f9fa;
}

.user-menu-item span:first-child {
    font-size: 1.2rem;
}

.user-menu-item span:last-child {
    font-size: 0.95rem;
    color: var(--dark-color);
    font-weight: 500;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem 2rem;
}

/* Login */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 2rem;
    /* Fondo con imagen - Intenta primero la imagen personalizada (.jpg), luego la de respaldo (.svg) */
    background-image: 
        linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
        url('../assets/login-background.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    /* Fallback color si no carga ninguna imagen */
    background-color: #667eea;
}

/* Fallback para cuando no existe login-background.jpg */
@supports not (background-image: url('../assets/login-background.jpg')) {
    .login-container {
        background-image: 
            linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
            url('../assets/login-background.svg');
    }
}

.login-box {
    background: rgba(255, 255, 255, 0.85);
    padding: 3rem;
    border-radius: 20px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4);
    width: 100%;
    max-width: 450px;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.login-box h1 {
    text-align: center;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 2.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.subtitle {
    text-align: center;
    color: #555;
    margin-bottom: 2rem;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.8);
}

.demo-credentials {
    margin-top: 2rem;
    padding: 1rem;
    background: rgba(248, 249, 250, 0.9);
    border-radius: 10px;
    font-size: 0.9rem;
    border: 1px solid rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(5px);
}

.demo-credentials p {
    margin: 0.5rem 0;
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #2c3e50;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.5);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s;
    background: rgba(255, 255, 255, 0.9);
    color: #2c3e50;
    font-weight: 500;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
    transform: translateY(-1px);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-row.three-cols {
    grid-template-columns: 1fr 1fr 1fr;
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    background: linear-gradient(135deg, #4285f4 0%, #357abd 100%);
    color: white;
    width: 100%;
    box-shadow: 0 4px 15px rgba(66, 133, 244, 0.3);
    font-weight: 600;
    letter-spacing: 0.5px;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #357abd 0%, #2a5a99 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(66, 133, 244, 0.4);
}

.btn-secondary {
    background: var(--light-color);
    color: var(--dark-color);
}

.btn-secondary:hover {
    background: #d5d8dc;
}

.btn-success {
    background: var(--success-color);
    color: white;
}

.btn-info {
    background: #00bcd4;
    color: white;
}

.btn-info:hover {
    background: #0097a7;
}

.btn-danger {
    background: var(--danger-color);
    color: white;
}

.btn-warning {
    background: var(--warning-color);
    color: white;
}

.btn-small {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
}

/* Dashboard */
.dashboard {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.dashboard h2 {
    color: var(--dark-color);
    margin-bottom: 2rem;
}

.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.menu-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    color: white;
}

.menu-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.card-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.menu-card h3 {
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
}

.menu-card p {
    opacity: 0.9;
    font-size: 0.95rem;
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.page-header h2 {
    color: var(--dark-color);
}

/* Subjects Grid */
.subjects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.subject-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    transition: all 0.3s;
}

.subject-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.subject-card h3 {
    color: var(--primary-color);
    margin-bottom: 0.75rem;
}

.subject-card p {
    color: #666;
    margin-bottom: 1rem;
}

.subject-actions {
    display: flex;
    gap: 0.5rem;
}

.subject-actions .btn-small {
    min-width: 40px;
    max-width: 40px;
    width: 40px;
    padding: 0.4rem;
    white-space: nowrap;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 2rem;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    box-shadow: var(--shadow-lg);
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover {
    color: var(--dark-color);
}

.modal-content h3 {
    color: var(--dark-color);
    margin-bottom: 1.5rem;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 1.5rem;
}

.modal-actions .btn {
    width: auto;
}

/* Table */
.table-container {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background: var(--light-color);
}

th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: var(--dark-color);
}

td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
}

tr:hover {
    background: #f8f9fa;
}

/* Action buttons in tables */
.action-buttons {
    display: flex;
    gap: 0.5rem;
    flex-wrap: nowrap;
    align-items: center;
}

.action-buttons .btn-small {
    min-width: 40px;
    max-width: 40px;
    width: 40px;
    padding: 0.4rem;
    white-space: nowrap;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Filters */
.filters {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    background: white;
    padding: 1rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.search-input,
.filter-select {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 1rem;
}

.search-input {
    flex: 1;
}

.filter-select {
    min-width: 200px;
}

/* Session Card */
.session-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 1.5rem;
}

/* Grid de sesiones en dos columnas */
.sessions-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

/* Responsive: una columna en pantallas pequeñas */
@media (max-width: 1200px) {
    .sessions-grid {
        grid-template-columns: 1fr;
    }
}

.session-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.session-header h3 {
    color: var(--primary-color);
}

.status-badge {
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.status-pendiente {
    background: #fff3cd;
    color: #856404;
}

.status-en-evaluacion {
    background: #fff3e0;
    color: #e65100;
}

.status-aprobada {
    background: #d4edda;
    color: #155724;
}

.status-vencida {
    background: #f8d7da;
    color: #721c24;
}

.status-draft {
    background: #e0e0e0;
    color: #666;
}

.status-published {
    background: #d1f2eb;
    color: #0c5460;
}

.status-completed {
    background: #d4edda;
    color: #155724;
}

/* Progress Bar */
.progress-container {
    margin: 1rem 0;
}

.progress-bar {
    width: 100%;
    height: 30px;
    background: var(--light-color);
    border-radius: 15px;
    overflow: hidden;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: width 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.85rem;
}

.progress-text {
    margin-top: 0.5rem;
    color: #666;
    font-size: 0.9rem;
}

/* Session Info */
.session-info {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.session-info p {
    margin: 0.5rem 0;
}

.session-details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin: 1rem 0;
}

.detail-item {
    display: flex;
    flex-direction: column;
}

.detail-label {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0.25rem;
}

.detail-value {
    font-weight: 600;
    color: var(--dark-color);
}

/* Time Entries */
.time-entries-list {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

.time-entries-list h4 {
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.time-entry-item {
    background: #f8f9fa;
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.time-entry-info {
    flex: 1;
}

.duration-display {
    background: #e3f2fd;
    padding: 1rem;
    border-radius: 8px;
    text-align: center;
    margin: 1rem 0;
    font-size: 1.1rem;
}

/* Stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    text-align: center;
}

.stat-value {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: #666;
    font-size: 0.95rem;
}

/* History */
.history-item {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 1rem;
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

/* Error/Success Messages */
.error-message {
    background: #f8d7da;
    color: #721c24;
    padding: 0.75rem;
    border-radius: 6px;
    margin-top: 1rem;
}

.success-message {
    background: #d4edda;
    color: #155724;
    padding: 0.75rem;
    border-radius: 6px;
    margin-top: 1rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: #666;
}

.empty-state-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Database Manager */
.db-section {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.db-section h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.db-section p {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.warning-box {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
}

.warning-box strong {
    display: block;
    margin-bottom: 0.5rem;
    color: #856404;
}

.danger-box {
    background: #f8d7da;
    border-left: 4px solid #dc3545;
    padding: 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
}

.danger-box strong {
    display: block;
    margin-bottom: 0.5rem;
    color: #721c24;
}

.file-input-wrapper {
    margin-bottom: 1rem;
}

.file-input-wrapper input[type="file"] {
    display: block;
    width: 100%;
    padding: 0.75rem;
    border: 2px dashed #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.file-input-wrapper input[type="file"]:hover {
    border-color: var(--primary-color);
    background: #f8f9fa;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .form-row.three-cols {
        grid-template-columns: 1fr;
    }
    
    .menu-grid {
        grid-template-columns: 1fr;
    }
    
    .subjects-grid {
        grid-template-columns: 1fr;
    }
    
    .filters {
        flex-direction: column;
    }
    
    .filter-select {
        width: 100%;
    }
    
    .session-details {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .notifications-dropdown {
        width: 300px;
        right: -50px;
    }
    
    /* Login mobile optimization */
    .login-container {
        padding: 1rem;
    }
    
    .login-box {
        padding: 1.5rem;
        max-width: 100%;
    }
    
    .login-box img[src*="logo"] {
        max-width: 250px !important;
    }
    
    .login-box h1 {
        font-size: 1.8rem;
    }
    
    .login-box .btn {
        padding: 12px 16px;
        font-size: 14px;
    }
    
    .login-box input {
        font-size: 16px; /* Evita zoom en iOS */
    }
}

/* ========================================
   DASHBOARD DE MÉTRICAS INTELIGENTES
======================================== */

/* Alertas Inteligentes */
.alerts-container {
    margin-bottom: 2rem;
}

.alert {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    margin-bottom: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border-left: 4px solid;
}

.alert:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.alert-success {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}

.alert-info {
    background: #d1ecf1;
    border-color: #17a2b8;
    color: #0c5460;
}

.alert-warning {
    background: #fff3cd;
    border-color: #ffc107;
    color: #856404;
}

.alert-danger {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}

.alert-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.alert-content {
    flex: 1;
}

.alert-title {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.alert-message {
    font-size: 0.95rem;
    opacity: 0.9;
}

.alert-action {
    font-weight: 600;
    opacity: 0.7;
}

/* Grid de Métricas */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.metric-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: all 0.3s ease;
    border-top: 4px solid var(--primary-color);
}

.metric-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.metric-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.metric-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.metric-label {
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
}

/* Secciones del Dashboard */
.section-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.section-card h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
}

/* Progreso por Materia */
.progress-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.progress-item {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.subject-name {
    font-weight: 600;
    font-size: 1.1rem;
}

.progress-value {
    font-weight: 700;
    font-size: 1.2rem;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
}

.progress-value.high {
    background: #d4edda;
    color: #28a745;
}

.progress-value.medium {
    background: #fff3cd;
    color: #856404;
}

.progress-value.low {
    background: #f8d7da;
    color: #721c24;
}

.progress-bar {
    height: 12px;
    background: #e9ecef;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 0.75rem;
}

.progress-fill {
    height: 100%;
    transition: width 0.5s ease;
}

.progress-fill.high {
    background: linear-gradient(90deg, #28a745, #20c997);
}

.progress-fill.medium {
    background: linear-gradient(90deg, #ffc107, #fd7e14);
}

.progress-fill.low {
    background: linear-gradient(90deg, #dc3545, #c82333);
}

.progress-stats {
    display: flex;
    gap: 1.5rem;
    font-size: 0.9rem;
    color: #666;
}

/* Desempeño de Estudiantes */
.students-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.student-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: #f8f9fa;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.student-item:hover {
    background: #e9ecef;
    transform: translateX(5px);
}

.student-rank {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    min-width: 50px;
}

.student-info {
    flex: 1;
}

.student-name {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.student-stats {
    display: flex;
    gap: 1rem;
    font-size: 0.85rem;
    color: #666;
    flex-wrap: wrap;
}

.student-performance {
    text-align: center;
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    font-weight: 600;
    white-space: nowrap;
}

.performance-excellent {
    background: #d4edda;
    color: #28a745;
}

.performance-good {
    background: #d1ecf1;
    color: #17a2b8;
}

.performance-regular {
    background: #fff3cd;
    color: #856404;
}

.performance-needs-attention {
    background: #f8d7da;
    color: #721c24;
}

.performance-rate {
    font-size: 1.2rem;
    margin-top: 0.25rem;
}

/* Sesiones Críticas */
.critical-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.critical-subtitle {
    color: #666;
    font-size: 1rem;
    margin: 1.5rem 0 1rem 0;
}

.critical-subtitle:first-child {
    margin-top: 0;
}

.critical-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    border-left: 4px solid;
}

.critical-overdue {
    background: #f8d7da;
    border-color: #dc3545;
}

.critical-today {
    background: #fff3cd;
    border-color: #ffc107;
}

.critical-soon {
    background: #d1ecf1;
    border-color: #17a2b8;
}

.critical-info {
    flex: 1;
}

.critical-title {
    font-weight: 600;
    font-size: 1.05rem;
    margin-bottom: 0.25rem;
}

.critical-student {
    font-size: 0.9rem;
    color: #666;
}

.critical-status {
    font-weight: 600;
    text-align: right;
}

/* Gráfico de Tendencias */
.trend-chart {
    padding: 1rem 0;
}

.chart-bars {
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    height: 250px;
    gap: 1rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.chart-bar-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.chart-bar {
    width: 100%;
    min-height: 30px;
    background: linear-gradient(180deg, var(--primary-color), var(--secondary-color));
    border-radius: 8px 8px 0 0;
    position: relative;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 0.5rem;
    transition: all 0.5s ease;
}

.chart-bar:hover {
    opacity: 0.8;
    transform: scaleY(1.05);
}

.chart-value {
    color: white;
    font-weight: 700;
    font-size: 0.9rem;
}

.chart-label {
    font-size: 0.85rem;
    color: #666;
    text-align: center;
}

/* Acceso Rápido */
.quick-actions {
    margin-top: 2rem;
}

.quick-actions h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
}

.quick-actions .menu-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.quick-actions .menu-card h4 {
    font-size: 1rem;
    margin: 0;
}

.quick-actions .menu-card p {
    font-size: 0.85rem;
    margin: 0.5rem 0 0 0;
}

/* Sesiones del Estudiante */
.sessions-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.session-item {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
}

.session-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.session-subject {
    font-weight: 600;
    font-size: 1.1rem;
}

.session-days {
    background: #d1ecf1;
    color: #17a2b8;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.session-days.urgent {
    background: #f8d7da;
    color: #721c24;
}

.session-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: #666;
}

.session-progress {
    font-weight: 700;
    color: var(--primary-color);
}

/* Estado Vacío */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: #999;
    font-style: italic;
}

/* Responsive para Métricas */
@media (max-width: 768px) {
    .metrics-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .student-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .student-performance {
        width: 100%;
    }
    
    .critical-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .critical-status {
        text-align: left;
    }
    
    .chart-bars {
        height: 200px;
        gap: 0.5rem;
    }
    
    .chart-value {
        font-size: 0.75rem;
    }
    
    .chart-label {
        font-size: 0.7rem;
    }
}

@media (max-width: 480px) {
    .metrics-grid {
        grid-template-columns: 1fr;
    }
    
    .alert {
        flex-direction: column;
        text-align: center;
    }
}

/* ===========================
   PANEL DE CONTROL COMPACTO
   =========================== */

.control-panel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    max-width: 1000px;
}

.control-card {
    background: linear-gradient(135deg, var(--primary-color) 0%, #5a67d8 100%);
    color: white;
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    min-height: 180px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.control-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0,0,0,0.2);
}

.control-icon {
    font-size: 3rem;
    margin-bottom: 0.75rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

.control-card h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.control-card p {
    margin: 0;
    font-size: 0.85rem;
    opacity: 0.9;
}

@media (max-width: 768px) {
    .control-panel-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 1rem;
    }
    
    .control-card {
        min-height: 160px;
        padding: 1.25rem;
    }
    
    .control-icon {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
    .control-panel-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Estilos compactos legacy (mantener para compatibilidad) */
.section-card-compact {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}

.section-card-compact h3 {
    font-size: 1rem;
    margin: 0 0 0.75rem 0;
    color: var(--primary-color);
    font-weight: 600;
}

.menu-grid-compact {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 0.75rem;
}

.menu-card-compact {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.menu-card-compact:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    border-color: var(--primary-color);
}

.card-icon-compact {
    font-size: 2rem;
    flex-shrink: 0;
}

.menu-card-compact h4 {
    margin: 0 0 0.25rem 0;
    font-size: 0.95rem;
    color: #333;
}

.menu-card-compact p {
    margin: 0;
    font-size: 0.8rem;
    color: #666;
}

@media (max-width: 768px) {
    .menu-grid-compact {
        grid-template-columns: 1fr;
    }
}

/* ===========================
   DASHBOARD DOS COLUMNAS Y FILTRO
   =========================== */

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    gap: 1rem;
    flex-wrap: wrap;
}

.dashboard-header h2 {
    margin: 0;
    flex: 1;
    min-width: 250px;
}

.student-filter {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: white;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}

.student-filter label {
    font-weight: 600;
    color: #333;
    font-size: 0.9rem;
    white-space: nowrap;
}

.student-filter select {
    padding: 0.5rem 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 0.9rem;
    background: white;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 200px;
}

.student-filter select:hover {
    border-color: var(--primary-color);
}

.student-filter select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

/* Layout de dos columnas */
.dashboard-two-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.dashboard-column {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    min-height: 0; /* Permite que los hijos se ajusten */
}

/* Actualizar section-card-compact para mejor diseño con colores */
.section-card-compact {
    background: white;
    border-radius: 12px;
    padding: 1.25rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border-left: 4px solid var(--primary-color);
    min-height: 400px;
    display: flex;
    flex-direction: column;
}

.section-card-compact h3 {
    font-size: 1.05rem;
    margin: 0 0 1rem 0;
    color: var(--primary-color);
    font-weight: 600;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #f0f0f0;
}

/* Colores específicos para cada tarjeta */
.section-card-compact:nth-child(1) {
    border-left-color: #8b5cf6; /* Violeta para progreso por materia */
    background: linear-gradient(to bottom right, #ffffff 0%, #faf5ff 100%);
}

.section-card-compact:nth-child(2) {
    border-left-color: #3b82f6; /* Azul para tendencia */
    background: linear-gradient(to bottom right, #ffffff 0%, #eff6ff 100%);
}

.section-card-compact:nth-child(1) h3 {
    color: #8b5cf6;
}

.section-card-compact:nth-child(2) h3 {
    color: #3b82f6;
}

/* Para la columna derecha */
.dashboard-column:nth-child(2) .section-card-compact:nth-child(1) {
    border-left-color: #10b981; /* Verde para desempeño */
    background: linear-gradient(to bottom right, #ffffff 0%, #f0fdf4 100%);
}

.dashboard-column:nth-child(2) .section-card-compact:nth-child(1) h3 {
    color: #10b981;
}

.dashboard-column:nth-child(2) .section-card-compact:nth-child(2) {
    border-left-color: #f59e0b; /* Naranja para sesiones críticas */
    background: linear-gradient(to bottom right, #ffffff 0%, #fffbeb 100%);
}

.dashboard-column:nth-child(2) .section-card-compact:nth-child(2) h3 {
    color: #f59e0b;
}

/* Acciones rápidas compactas */
.quick-actions-compact {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}

.quick-actions-compact h3 {
    font-size: 1rem;
    margin: 0 0 0.75rem 0;
    color: var(--primary-color);
    font-weight: 600;
}

.quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.75rem;
}

.quick-btn {
    background: linear-gradient(135deg, var(--primary-color) 0%, #5a67d8 100%);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.quick-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

/* ============================================
   FILTROS DE TABS (MIS SESIONES)
   ============================================ */

.filter-tabs {
    display: flex;
    gap: 0.5rem;
    background: #f8f9fa;
    padding: 0.5rem;
    border-radius: 12px;
    flex-wrap: wrap;
}

.filter-tab {
    padding: 0.75rem 1.5rem;
    border: none;
    background: transparent;
    color: #666;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.filter-tab:hover {
    background: #e9ecef;
    color: #333;
}

.filter-tab.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* ============================================
   MODAL DE HISTORIAL DE SESIONES
   ============================================ */

.modal#historyModal {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal#historyModal .modal-content {
    background-color: #fff;
    margin: 5% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 900px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    padding: 1.5rem 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px 12px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

.close-modal {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.close-modal:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.modal-body {
    padding: 2rem;
    max-height: 70vh;
    overflow-y: auto;
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.history-item {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.2s ease;
}

.history-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #f0f0f0;
}

.history-subject {
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.history-status {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.status-approved {
    background: #d4edda;
    color: #155724;
}

.status-pending {
    background: #fff3cd;
    color: #856404;
}

.status-completed {
    background: #d1ecf1;
    color: #0c5460;
}

.status-none {
    background: #f8d7da;
    color: #721c24;
}

.history-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.history-detail {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.detail-label {
    font-size: 0.85rem;
    color: #666;
    font-weight: 500;
}

.detail-value {
    font-size: 1rem;
    color: #333;
    font-weight: 600;
}

.history-entries {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 2px solid #f0f0f0;
}

.entries-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #666;
    margin-bottom: 0.75rem;
}

.entry-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 0.5rem;
}

.entry-date {
    font-size: 0.9rem;
    color: #666;
    min-width: 100px;
}

.entry-hours {
    font-weight: 600;
    color: #667eea;
    min-width: 50px;
}

.entry-comment {
    font-size: 0.9rem;
    color: #555;
    font-style: italic;
    flex: 1;
}

.empty-state {
    text-align: center;
    padding: 3rem;
    color: #999;
    font-size: 1.1rem;
}

.metric-clickable {
    cursor: pointer;
    position: relative;
}

.metric-clickable:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.metric-hint {
    position: absolute;
    bottom: 0.5rem;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.75rem;
    color: #999;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.metric-clickable:hover .metric-hint {
    opacity: 1;
}

/* Responsive para dashboard */
@media (max-width: 992px) {
    .dashboard-two-columns {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .dashboard-column {
        gap: 1rem;
    }
    
    .student-filter {
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 768px) {
    .dashboard-header {
        flex-direction: column;
        align-items: stretch;
    }
    
    .dashboard-header h2 {
        text-align: center;
    }
    
    .quick-actions-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .quick-actions-grid {
        grid-template-columns: 1fr;
    }
    
    .student-filter {
        flex-direction: column;
        align-items: stretch;
    }
    
    .student-filter select {
        width: 100%;
    }
}

/* ========================================
   LOADING SPINNER
   ======================================== */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    backdrop-filter: blur(3px);
}

.loading-overlay.hidden {
    display: none;
}

.spinner-container {
    text-align: center;
    padding: 3rem 1rem;
}

.spinner {
    width: 50px;
    height: 50px;
    margin: 0 auto 20px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.spinner-container p {
    color: var(--text-color);
    font-size: 1.1rem;
    font-weight: 500;
}

/* Overlay de carga global */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    backdrop-filter: blur(3px);
}

.loading-overlay .spinner-container {
    background: white;
    padding: 2rem 3rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

/* Loader inline para contenido específico */
.inline-loader {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    min-height: 200px;
}

.inline-loader .spinner {
    width: 40px;
    height: 40px;
    border-width: 3px;
}

/* ========================================
   BOTÓN FLOTANTE DE AYUDA Y POPUP
   ======================================== */

/* Botón flotante de ayuda */
.help-floating-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    color: white;
    font-size: 28px;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 9999;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse 2s infinite;
}

.help-floating-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(37, 211, 102, 0.6);
}

@keyframes pulse {
    0% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    }
    50% {
        box-shadow: 0 4px 30px rgba(37, 211, 102, 0.7);
    }
    100% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    }
}

/* Popup de ayuda */
.help-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.help-popup-content {
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 400px;
    width: 90%;
    position: relative;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.help-popup-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    font-size: 24px;
    color: #999;
    cursor: pointer;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.help-popup-close:hover {
    background: #f0f0f0;
    color: #333;
}

.whatsapp-btn {
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    color: white !important;
    text-decoration: none;
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    width: 100%;
    text-align: center;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
    transition: all 0.3s;
}

.whatsapp-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
    background: linear-gradient(135deg, #128C7E 0%, #075E54 100%);
}

/* Responsive para móviles */
@media (max-width: 768px) {
    .help-floating-btn {
        width: 50px;
        height: 50px;
        font-size: 24px;
        bottom: 20px;
        right: 20px;
    }
    
    .help-popup-content {
        margin: 20px;
    }
}

/* ========================================
   BOTÓN Y MODAL DE INFORMACIÓN
   ======================================== */

/* Botón flotante de información */
.info-floating-btn {
    position: fixed;
    bottom: 110px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4285f4 0%, #357abd 100%);
    color: white;
    font-size: 32px;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(66, 133, 244, 0.4);
    z-index: 9999;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: bounce 3s infinite;
}

.info-floating-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(66, 133, 244, 0.6);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* Modal de información */
.info-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
    overflow-y: auto;
}

.info-modal-content {
    background: white;
    border-radius: 24px;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.4s ease;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.3);
}

.info-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.05);
    border: none;
    font-size: 28px;
    color: #666;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
    z-index: 10;
}

.info-modal-close:hover {
    background: rgba(0, 0, 0, 0.1);
    color: #333;
    transform: rotate(90deg);
}

/* Header del modal */
.info-modal-header {
    text-align: center;
    padding: 40px 40px 30px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 24px 24px 0 0;
}

/* Grid de características */
.info-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding: 30px 40px;
}

.info-feature-card {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 16px;
    text-align: center;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.info-feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border-color: #4285f4;
}

.info-feature-icon {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    margin: 0 auto 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.info-feature-card h3 {
    color: #2c3e50;
    font-size: 18px;
    margin: 0 0 10px 0;
    font-weight: 600;
}

.info-feature-card p {
    color: #666;
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
}

/* Footer del modal */
.info-modal-footer {
    text-align: center;
    padding: 30px 40px 40px;
    background: #f8f9fa;
    border-radius: 0 0 24px 24px;
}

.info-cta-btn {
    display: inline-block;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    text-decoration: none;
    padding: 16px 40px;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 600;
    box-shadow: 0 4px 20px rgba(40, 167, 69, 0.3);
    transition: all 0.3s;
}

.info-cta-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 30px rgba(40, 167, 69, 0.4);
    background: linear-gradient(135deg, #20c997 0%, #17a2b8 100%);
}

/* Responsive para móviles */
@media (max-width: 768px) {
    .info-floating-btn {
        width: 50px;
        height: 50px;
        font-size: 26px;
        bottom: 90px;
        right: 20px;
    }
    
    .info-modal-content {
        margin: 10px;
        border-radius: 16px;
    }
    
    .info-modal-header,
    .info-features,
    .info-modal-footer {
        padding: 20px;
    }
    
    .info-features {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .info-modal-header h2 {
        font-size: 22px;
    }
    
    .info-cta-btn {
        padding: 14px 30px;
        font-size: 16px;
    }
    
    .help-floating-btn {
        bottom: 20px;
        right: 20px;
    }
    
    .help-popup-content {
        margin: 20px;
    }
}
