/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f8fafc;
    min-height: 100vh;
    color: #1e293b;
    overflow-x: hidden;
    line-height: 1.6;
}

/* Dashboard Container */
.dashboard-container {
    display: flex;
    min-height: 100vh;
    background: #f8fafc;
}

/* Sidebar */
.sidebar {
    width: 280px;
    background: #ffffff;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.08);
    border-right: 1px solid #e2e8f0;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none !important;
    transition: all 0.3s ease;
    cursor: pointer;
    padding: 0.5rem;
    margin: -0.5rem;
    border-radius: 8px;
}

.logo:hover {
    background: #f8fafc;
    text-decoration: none !important;
}

.logo:focus {
    outline: none;
    text-decoration: none !important;
}

.logo:active {
    text-decoration: none !important;
}

.logo:visited {
    text-decoration: none !important;
}

.logo:hover .logo-text h2 {
    color: #3b82f6;
}

.logo i {
    font-size: 2rem;
    color: #3b82f6;
    transition: transform 0.3s ease;
}

.logo:hover i {
    transform: scale(1.05);
}

.logo-text {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.logo-text h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
    line-height: 1.2;
    transition: color 0.3s ease;
    text-decoration: none !important;
}

.logo-text span {
    font-size: 0.75rem;
    color: #64748b;
    font-weight: 500;
    line-height: 1;
    text-decoration: none !important;
}

.sidebar-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.25rem;
    color: #64748b;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.sidebar-toggle:hover {
    background: #f1f5f9;
    color: #3b82f6;
}

.sidebar-nav {
    flex: 1;
    padding: 1rem 0;
    overflow-y: auto;
}

.nav-section {
    margin-bottom: 2rem;
}

.nav-section-title {
    font-size: 0.75rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 1.5rem 0.75rem;
}

.nav-list {
    list-style: none;
}

.nav-item {
    margin: 0.25rem 0;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    color: #64748b;
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
    font-weight: 500;
    font-size: 0.875rem;
}

.nav-link:hover {
    background: #f8fafc;
    color: #1e293b;
    border-left-color: #3b82f6;
}

.nav-item.active .nav-link {
    background: #eff6ff;
    color: #3b82f6;
    border-left-color: #3b82f6;
    font-weight: 600;
}

.nav-link i {
    width: 20px;
    text-align: center;
    font-size: 1rem;
}

.sidebar-footer {
    padding: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.user-avatar {
    width: 40px;
    height: 40px;
    background: #3b82f6;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
}

.user-info {
    flex: 1;
}

.user-name {
    display: block;
    font-weight: 600;
    color: #1e293b;
    font-size: 0.875rem;
}

.user-role {
    display: block;
    font-size: 0.75rem;
    color: #64748b;
}

/* Main Content */
.main-content {
    margin-left: 280px;
    flex: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
.header {
    background: white;
    padding: 1.5rem 2rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid #e2e8f0;
}

.header-left {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.breadcrumb {
    font-size: 0.75rem;
    color: #64748b;
    font-weight: 500;
}

.page-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.action-btn {
    position: relative;
    background: none;
    border: none;
    font-size: 1.125rem;
    color: #64748b;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.action-btn:hover {
    background: #f1f5f9;
    color: #3b82f6;
}

.notification-badge {
    position: absolute;
    top: 0.25rem;
    right: 0.25rem;
    background: #ef4444;
    color: white;
    font-size: 0.625rem;
    font-weight: 600;
    padding: 0.125rem 0.375rem;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}

.user-menu {
    position: relative;
}

.user-menu-btn {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.user-menu-btn:hover {
    background: #f1f5f9;
}

.user-avatar-small {
    width: 32px;
    height: 32px;
    background: #3b82f6;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.875rem;
}

.user-menu-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    min-width: 200px;
    padding: 0.5rem 0;
    display: none;
    z-index: 1000;
}

.user-menu:hover .user-menu-dropdown {
    display: block;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: #64748b;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.875rem;
}

.dropdown-item:hover {
    background: #f8fafc;
    color: #1e293b;
}

.dropdown-item.logout-btn:hover {
    background: #fef2f2;
    color: #dc2626;
}

.dropdown-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 0.5rem 0;
}

/* Dashboard Content */
.dashboard-content {
    padding: 2rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Welcome Section */
.welcome-section {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
}

.welcome-card {
    background: white;
    border-radius: 20px;
    padding: 4rem 3rem;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
    text-align: center;
    max-width: 600px;
    border: 1px solid #e2e8f0;
}

.welcome-icon {
    font-size: 5rem;
    color: #3b82f6;
    margin-bottom: 2rem;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

.welcome-content h2 {
    color: #1e293b;
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 1rem 0;
}

.welcome-content p {
    color: #64748b;
    font-size: 1.125rem;
    line-height: 1.6;
    margin: 0;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.stat-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}

.stat-card:nth-child(1) .stat-icon { background: #3b82f6; }
.stat-card:nth-child(2) .stat-icon { background: #10b981; }
.stat-card:nth-child(3) .stat-icon { background: #f59e0b; }
.stat-card:nth-child(4) .stat-icon { background: #8b5cf6; }

.stat-content {
    flex: 1;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 0.25rem 0;
}

.stat-label {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0 0 0.5rem 0;
}

.stat-change {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
}

.stat-change.positive {
    color: #10b981;
}

.stat-change i {
    font-size: 0.625rem;
}

/* Charts Grid */
.charts-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
}

.chart-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    overflow: hidden;
}

.card-header {
    padding: 1.5rem 1.5rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
}

.card-header h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
}

.chart-actions {
    display: flex;
    gap: 0.5rem;
}

.chart-action-btn {
    background: none;
    border: none;
    color: #64748b;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.chart-action-btn:hover {
    background: #f1f5f9;
    color: #3b82f6;
}

.card-content {
    padding: 1.5rem;
}

/* Activity Section */
.activity-section {
    grid-column: 1 / -1;
}

.activity-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    overflow: hidden;
}

.view-all-btn {
    color: #3b82f6;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.view-all-btn:hover {
    color: #1d4ed8;
}

.activity-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.activity-item:hover {
    background: #f8fafc;
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: white;
    flex-shrink: 0;
}

.activity-item:nth-child(1) .activity-icon { background: #3b82f6; }
.activity-item:nth-child(2) .activity-icon { background: #10b981; }
.activity-item:nth-child(3) .activity-icon { background: #f59e0b; }

.activity-content {
    flex: 1;
}

.activity-title {
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 0.25rem 0;
    font-size: 0.875rem;
}

.activity-description {
    color: #64748b;
    margin: 0 0 0.5rem 0;
    font-size: 0.75rem;
}

.activity-time {
    color: #94a3b8;
    font-size: 0.75rem;
    font-weight: 500;
}

/* Quick Actions */
.quick-actions h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 1.5rem 0;
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.action-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    text-decoration: none;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
}

.action-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-color: #3b82f6;
}

.action-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    background: #eff6ff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #3b82f6;
}

.action-card h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
}

.action-card p {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0;
}

/* Chat Button */
.chat-button {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background: #3b82f6;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.3);
    transition: all 0.3s ease;
    z-index: 1000;
}

.chat-button:hover {
    transform: scale(1.1);
    background: #1d4ed8;
    box-shadow: 0 6px 25px rgba(59, 130, 246, 0.4);
}

/* Summary Cards */
.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.summary-card {
    background: #ffffff;
}

.card-header {
    padding: 1.5rem 1.5rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
}

.card-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #374151;
    margin: 0;
}

.card-header i {
    font-size: 1.5rem;
    color: #1F6F8B;
}

.card-content {
    padding: 1.5rem;
}

.big-number {
    font-size: 3rem;
    font-weight: 700;
    color: #0C2A3E;
    margin-bottom: 1rem;
    text-align: center;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    width: 100%;
    justify-content: center;
}

.btn-primary {
    background: #1F6F8B;
    color: white;
}

.btn-primary:hover {
    background: #0C2A3E;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(31, 111, 139, 0.3);
}

/* Charts Section */
.charts-section {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
}

.chart-card {
    background: white;
    min-height: 400px;
}

.chart-card.full-width {
    grid-column: 1 / -1;
}

.chart-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 0.5rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #64748b;
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
}

.legend-color.kit { background: #0C2A3E; }
.legend-color.otros { background: #1F6F8B; }
.legend-color.reparo { background: #21BF73; }
.legend-color.tc { background: #F9B934; }
.legend-color.td { background: #1F6F8B; }
.legend-color.pack { background: #0C2A3E; }
.legend-color.todos { background: #E8F1F5; }

/* Status Legend */
.status-legend {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 1rem;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.status-color {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: inline-block;
}

.status-item.completed .status-color {
    background: #21BF73;
}

.status-item.pending .status-color {
    background: #F9B934;
}

/* Delivery Status Legend */
.delivery-status-legend {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.status-legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #64748b;
}

.status-legend-color {
    width: 12px;
    height: 12px;
    border-radius: 3px;
    display: inline-block;
}

.status-legend-color.on-time { background: #21BF73; }
.status-legend-color.before-schedule { background: #F9B934; }
.status-legend-color.after-schedule { background: #1F6F8B; }
.status-legend-color.not-performed { background: #0C2A3E; }

/* Chat Button */
.chat-button {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background: #1F6F8B;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(31, 111, 139, 0.3);
    transition: all 0.3s ease;
    z-index: 1000;
}

.chat-button:hover {
    transform: scale(1.1);
    background: #0C2A3E;
    box-shadow: 0 6px 25px rgba(31, 111, 139, 0.4);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar-toggle {
        display: block;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .charts-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
}

@media (max-width: 768px) {
    .header {
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .header-right {
        width: 100%;
        justify-content: space-between;
    }
    
    .dashboard-content {
        padding: 1rem;
    }
    
    .page-title {
        font-size: 1.5rem;
    }
    
    .stat-number {
        font-size: 1.75rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .actions-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .sidebar {
        width: 100%;
    }
    
    .dashboard-content {
        padding: 0.5rem;
    }
    
    .card-header {
        padding: 1rem;
    }
    
    .card-content {
        padding: 1rem;
    }
    
    .stat-card {
        padding: 1rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .action-card {
        padding: 1rem;
    }
}

/* Animation Classes */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card {
    animation: fadeInUp 0.6s ease forwards;
}

.card:nth-child(1) { animation-delay: 0.1s; }
.card:nth-child(2) { animation-delay: 0.2s; }
.card:nth-child(3) { animation-delay: 0.3s; }
.card:nth-child(4) { animation-delay: 0.4s; }

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* ===== AUTH PAGES ===== */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.auth-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="50" cy="10" r="0.5" fill="rgba(255,255,255,0.05)"/><circle cx="10" cy="60" r="0.5" fill="rgba(255,255,255,0.05)"/><circle cx="90" cy="40" r="0.5" fill="rgba(255,255,255,0.05)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.auth-card {
    background: white;
    border-radius: 24px;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    max-width: 480px;
    width: 100%;
    animation: slideUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 1;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.auth-header {
    background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
    color: white;
    padding: 50px 40px;
    text-align: center;
    position: relative;
}

.auth-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255,255,255,0.1) 0%, transparent 50%, rgba(255,255,255,0.05) 100%);
}

.auth-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
    position: relative;
    z-index: 1;
}

.auth-logo i {
    font-size: 2.5rem;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 16px;
    backdrop-filter: blur(10px);
}

.auth-logo-text h1 {
    font-size: 2.2rem;
    font-weight: 800;
    margin: 0;
    color: white;
    letter-spacing: -0.5px;
}

.auth-logo-text span {
    font-size: 0.9rem;
    opacity: 0.8;
    font-weight: 500;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.auth-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0 0 10px 0;
    color: white;
    position: relative;
    z-index: 1;
}

.auth-header p {
    font-size: 1rem;
    opacity: 0.9;
    margin: 0;
    font-weight: 400;
    position: relative;
    z-index: 1;
}

.auth-body {
    padding: 50px 40px;
}

.form-group {
    margin-bottom: 28px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #0C2A3E;
    font-size: 0.95rem;
    letter-spacing: 0.2px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper i {
    position: absolute;
    left: 18px;
    color: #64748b;
    font-size: 1rem;
    z-index: 2;
}

.form-control {
    width: 100%;
    padding: 16px 20px 16px 50px;
    border: 2px solid #e2e8f0;
    border-radius: 14px;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: #f8fafc;
    font-family: inherit;
    color: #1e293b;
}

.form-control:focus {
    outline: none;
    border-color: #3b82f6;
    background: white;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
    transform: translateY(-1px);
}

.form-control.error {
    border-color: #ef4444;
    background: #fef2f2;
}

.form-control.success {
    border-color: #10b981;
    background: #f0fdf4;
}

.password-toggle {
    position: absolute;
    right: 18px;
    cursor: pointer;
    color: #64748b;
    font-size: 1rem;
    z-index: 2;
    padding: 5px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.password-toggle:hover {
    color: #3b82f6;
    background: rgba(59, 130, 246, 0.1);
}

.error-message {
    color: #ef4444;
    font-size: 0.85rem;
    margin-top: 8px;
    display: none;
    font-weight: 500;
}

.success-message {
    color: #10b981;
    font-size: 0.85rem;
    margin-top: 8px;
    display: none;
    font-weight: 500;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}

.checkbox-wrapper {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.9rem;
    color: #64748b;
}

.checkbox-wrapper input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    margin-right: 10px;
    position: relative;
    transition: all 0.3s ease;
    background: white;
}

.checkbox-wrapper input[type="checkbox"]:checked + .checkmark {
    background: #3b82f6;
    border-color: #3b82f6;
}

.checkbox-wrapper input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.checkbox-label {
    font-weight: 500;
}

.forgot-password {
    color: #3b82f6;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.forgot-password:hover {
    color: #1e40af;
    text-decoration: underline;
}

.terms-link {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 600;
}

.terms-link:hover {
    text-decoration: underline;
}

.btn-primary {
    width: 100%;
    padding: 18px 24px;
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.3px;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 35px rgba(59, 130, 246, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.btn-primary.loading .spinner {
    display: inline-block;
}

.btn-primary.loading .btn-text {
    opacity: 0.7;
}

.btn-text {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-text i {
    font-size: 1.1rem;
}

.spinner {
    display: none;
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.auth-footer {
    padding: 25px 40px;
    text-align: center;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
}

.auth-footer p {
    margin: 0;
    color: #64748b;
    font-size: 0.95rem;
    font-weight: 500;
}

.auth-footer a {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.2s ease;
}

.auth-footer a:hover {
    color: #1e40af;
    text-decoration: underline;
}

.alert {
    padding: 18px 24px;
    border-radius: 14px;
    margin-bottom: 25px;
    display: none;
    align-items: center;
    gap: 12px;
    font-weight: 500;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert.show {
    display: flex;
}

.alert-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

.alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
}

.alert i {
    font-size: 1.3rem;
    flex-shrink: 0;
}

/* ===== IMÁGENES DE PRUEBA ===== */
.image-item {
    margin-bottom: 20px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.image-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.image-preview {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.image-preview:hover img {
    transform: scale(1.05);
}

.image-preview.no-image {
    background: #f1f5f9;
    color: #64748b;
    font-size: 0.9rem;
    font-weight: 500;
}

.image-label {
    padding: 12px 16px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    font-size: 0.85rem;
    font-weight: 600;
    color: #475569;
}

.image-info {
    padding: 16px;
    background: #f0f9ff;
    border-top: 1px solid #e0f2fe;
    font-size: 0.9rem;
    line-height: 1.5;
    color: #0c4a6e;
}

.image-info strong {
    color: #075985;
}

/* Card de observaciones */
.observation-card {
    grid-column: 1 / -1; /* Ocupa toda la fila */
    background: #f0f9ff;
    border: 2px solid #0ea5e9;
}

.observation-card .image-info {
    background: transparent;
    border-top: none;
    padding: 20px;
    font-size: 1rem;
    line-height: 1.6;
}

/* Grid de imágenes */
.images-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

/* Responsive Auth */
@media (max-width: 768px) {
    .auth-container {
        padding: 15px;
    }
    
    .auth-card {
        max-width: 100%;
        border-radius: 20px;
    }
    
    .auth-header {
        padding: 40px 25px;
    }
    
    .auth-header h2 {
        font-size: 1.6rem;
    }
    
    .auth-logo-text h1 {
        font-size: 1.8rem;
    }
    
    .auth-body {
        padding: 40px 25px;
    }
    
    .auth-footer {
        padding: 20px 25px;
    }
    
    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
    
    .images-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .image-preview {
        height: 150px;
    }
}

@media (max-width: 480px) {
    .auth-header {
        padding: 30px 20px;
    }
    
    .auth-body {
        padding: 30px 20px;
    }
    
    .auth-footer {
        padding: 15px 20px;
    }
    
    .form-control {
        padding: 14px 18px 14px 45px;
    }
    
    .input-wrapper i {
        left: 15px;
    }
    
    .password-toggle {
        right: 15px;
    }
    
    .image-preview {
        height: 120px;
    }
    
    .image-label {
        padding: 10px 12px;
        font-size: 0.8rem;
    }
}
