/* =====================================================
   SIMASSESS THEME - EXTENDED STYLES
   Dark Mode + Modern Components
===================================================== */

/* ===== TOAST NOTIFICATIONS ===== */
#toast-container {
    position: fixed !important;
    bottom: 1rem;
    right: 1rem;
    z-index: 9999;
}

#toast-container .toast {
    min-width: 320px;
    border-radius: 12px;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
    transform: translateX(400px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#toast-container .toast.showing {
    transform: translateX(0);
    opacity: 1;
}

#toast-container .toast-body {
    font-size: 0.95rem;
    color: #1f2937;
}

html.dark-mode #toast-container .toast {
    background: rgba(30, 41, 59, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #e4e6eb;
}

html.dark-mode #toast-container .toast-body {
    color: #e4e6eb;
}

/* ===== STAT CARDS ===== */
.stat-card {
    position: relative;
    overflow: hidden;
    border: none;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #3b82f6 0%, #8b5cf6 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12);
}

.stat-card:hover::before {
    opacity: 1;
}

.stat-card .card-icon {
    font-size: 3.5rem;
    position: absolute;
    right: -15px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.06;
}

.stat-number {
    font-size: 2.2rem;
    font-weight: 700;
    color: #111827;
    line-height: 1;
}

.stat-label {
    font-size: 0.85rem;
    color: #9ca3af;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Dark Mode */
html.dark-mode .stat-card {
    background: linear-gradient(135deg, #263445 0%, #2a3a4a 100%);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

html.dark-mode .stat-card:hover {
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.4);
}

html.dark-mode .stat-number {
    color: #f1f5f9;
}

html.dark-mode .stat-label {
    color: #94a3b8;
}

/* ===== CHART CARDS ===== */
.chart-card {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.chart-card .card-header {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-bottom: 1px solid #e5e7eb;
    padding: 1.25rem;
}

.chart-wrapper {
    position: relative;
    height: 300px;
    width: 100%;
}

html.dark-mode .chart-card {
    background: #263445;
    border-color: rgba(255, 255, 255, 0.08);
}

html.dark-mode .chart-card .card-header {
    background: rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.08);
}

/* ===== SCHEDULE CARD ===== */
.schedule-item {
    padding: 1rem;
    border-bottom: 1px solid #e5e7eb;
    transition: all 0.2s ease;
}

.schedule-item:last-child {
    border-bottom: none;
}

.schedule-item:hover {
    background: #f9fafb;
    padding-left: 1.25rem;
}

.schedule-time {
    font-size: 0.85rem;
    font-weight: 600;
    color: #3b82f6;
    margin-bottom: 0.25rem;
}

.schedule-title {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

html.dark-mode .schedule-item:hover {
    background: rgba(59, 130, 246, 0.05);
}

html.dark-mode .schedule-title {
    color: #f1f5f9;
}

/* ===== BADGES & LABELS ===== */
.badge-custom {
    padding: 0.375rem 0.875rem;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-block;
    transition: all 0.2s ease;
}

.badge-primary {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.badge-success {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.badge-warning {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
}

.badge-danger {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

html.dark-mode ::-webkit-scrollbar-thumb {
    background: #4b5563;
}

html.dark-mode ::-webkit-scrollbar-thumb:hover {
    background: #6b7280;
}

/* ===== HAMBURGER MENU ===== */
.hamburger {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.hamburger::before,
.hamburger::after,
.hamburger span {
    content: '';
    display: block;
    width: 100%;
    height: 2px;
    background: #1f2937;
    border-radius: 1px;
    transition: all 0.3s ease;
    position: absolute;
}

.hamburger::before {
    top: 4px;
}

.hamburger span {
    top: 11px;
}

.hamburger::after {
    top: 18px;
}

html.dark-mode .hamburger::before,
html.dark-mode .hamburger::after,
html.dark-mode .hamburger span {
    background: #e4e6eb;
}

/* ===== TOOLTIPS ===== */
.tooltip-inner {
    background: #1f2937;
    border-radius: 6px;
    padding: 0.5rem 0.75rem;
    font-size: 0.85rem;
}

html.dark-mode .tooltip-inner {
    background: #ffffff;
    color: #1f2937;
}

/* ===== MODAL ===== */
.modal-content {
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

html.dark-mode .modal-content {
    background: #263445;
    border-color: rgba(255, 255, 255, 0.08);
    color: #e4e6eb;
}

/* ===== SWEETALERT ===== */
.swal2-popup {
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

html.dark-mode .swal2-popup {
    background: #263445;
    color: #e4e6eb;
}

html.dark-mode .swal2-title {
    color: #f1f5f9;
}

html.dark-mode .swal2-html-container {
    color: #cbd5e1;
}

/* ===== DATATABLES ===== */
.dataTables_wrapper {
    color: #1f2937;
}

.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter {
    color: #6b7280;
}

.dataTables_wrapper input,
.dataTables_wrapper select {
    background: #ffffff;
    color: #1f2937;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 0.5rem;
}

.dataTables_wrapper .paginate_button.current {
    background: #3b82f6;
    color: #ffffff;
}

html.dark-mode .dataTables_wrapper {
    color: #e4e6eb;
}

html.dark-mode .dataTables_wrapper input,
html.dark-mode .dataTables_wrapper select {
    background: rgba(255, 255, 255, 0.05);
    color: #e4e6eb;
    border-color: rgba(255, 255, 255, 0.1);
}

html.dark-mode .dataTables_wrapper .dataTables_info,
html.dark-mode .dataTables_wrapper .dataTables_length,
html.dark-mode .dataTables_wrapper .dataTables_filter {
    color: #94a3b8;
}

/* ===== PAGINATION ===== */
.pagination .page-link {
    color: #3b82f6;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    margin: 0 2px;
    transition: all 0.2s ease;
}

.pagination .page-link:hover {
    background: #f3f4f6;
    border-color: #3b82f6;
}

.pagination .page-item.active .page-link {
    background: #3b82f6;
    border-color: #3b82f6;
}

html.dark-mode .pagination .page-link {
    color: #94a3b8;
    border-color: rgba(255, 255, 255, 0.1);
}

html.dark-mode .pagination .page-link:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: #3b82f6;
}

/* ===== UTILITY CLASSES ===== */
.text-primary { color: #3b82f6 !important; }
.text-secondary { color: #8b5cf6 !important; }
.text-success { color: #10b981 !important; }
.text-danger { color: #ef4444 !important; }
.text-warning { color: #f59e0b !important; }
.text-info { color: #06b6d4 !important; }

.bg-primary { background: #3b82f6 !important; }
.bg-secondary { background: #8b5cf6 !important; }
.bg-success { background: #10b981 !important; }
.bg-danger { background: #ef4444 !important; }

html.dark-mode .text-muted {
    color: #94a3b8 !important;
}

html.dark-mode .bg-light {
    background: rgba(0, 0, 0, 0.2) !important;
}

/* ===== ANIMATIONS ===== */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.animate-fade {
    animation: fadeIn 0.3s ease;
}

/* ===== RESPONSIVE TWEAKS ===== */
@media (max-width: 768px) {
    .stat-card .card-icon {
        font-size: 2.5rem;
        right: -10px;
    }

    .chart-wrapper {
        height: 250px;
    }

    .sidebar {
        width: 100% !important;
    }

    #toast-container {
        bottom: 1rem !important;
        right: 1rem !important;
        left: auto !important;
        max-width: calc(100vw - 2rem) !important;
    }
}