/* ═══════════════════════════════════════════════════════════════
   ALESA Skool2U — Enterprise Theme (Light-only, Cheerful & Modern)
   ═══════════════════════════════════════════════════════════════ */

/* ---- Force light mode everywhere ---- */
html.dark, html[data-theme="dark"] { color-scheme: light !important; }
.dark { color-scheme: light !important; }

/* Topbar theme switcher — hide */
.fi-topbar-theme-switcher { display: none !important; }

/* ---- Page body base ---- */
.fi-body {
    background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 50%, #eff6ff 100%) !important;
    background-attachment: fixed;
}

/* ---- Sidebar — cheerful ---- */
.fi-sidebar {
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%) !important;
    border-right: 1px solid #e5e7eb !important;
    box-shadow: 2px 0 12px rgba(16, 185, 129, 0.05);
}
.fi-sidebar-nav-item .fi-sidebar-item-button {
    border-radius: 0.625rem !important;
    margin: 0.125rem 0 !important;
    transition: all 0.2s ease !important;
}
.fi-sidebar-nav-item .fi-sidebar-item-button:hover {
    background: linear-gradient(90deg, #ecfdf5 0%, #f0fdf4 100%) !important;
    transform: translateX(2px);
}
.fi-sidebar-nav-item.fi-active .fi-sidebar-item-button,
.fi-sidebar-nav-item .fi-sidebar-item-button[aria-current="page"] {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
    color: white !important;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}
.fi-sidebar-nav-item.fi-active .fi-sidebar-item-icon,
.fi-sidebar-nav-item .fi-sidebar-item-button[aria-current="page"] .fi-sidebar-item-icon {
    color: white !important;
}
.fi-sidebar-group-label {
    color: #059669 !important;
    font-weight: 700 !important;
    letter-spacing: 0.05em !important;
    text-transform: uppercase;
    font-size: 0.7rem !important;
}
.fi-sidebar-header .fi-logo { font-weight: 800 !important; }

/* ---- Topbar ---- */
.fi-topbar {
    background: white !important;
    border-bottom: 1px solid #e5e7eb !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.fi-topbar-user-menu-trigger-label { font-weight: 600 !important; }

/* ---- Page header ---- */
.fi-header-heading {
    background: linear-gradient(135deg, #047857 0%, #059669 50%, #10b981 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    font-weight: 800 !important;
    letter-spacing: -0.02em !important;
}
.fi-header-subheading { color: #64748b !important; }

/* ---- Filament Sections (cards) ---- */
.fi-section {
    border-radius: 1rem !important;
    border: 1px solid #e5e7eb !important;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.04), 0 1px 3px rgba(0,0,0,0.04) !important;
    background: white !important;
    transition: box-shadow 0.2s;
}
.fi-section:hover {
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.08), 0 2px 6px rgba(0,0,0,0.06) !important;
}
.fi-section-header {
    background: linear-gradient(90deg, #f0fdf4 0%, #ffffff 40%) !important;
    border-bottom: 1px solid #e5e7eb !important;
    border-radius: 1rem 1rem 0 0 !important;
}
.fi-section-header-heading {
    color: #065f46 !important;
    font-weight: 700 !important;
}

/* ---- Stats Overview (dashboard) ---- */
.fi-wi-stats-overview-stat {
    border-radius: 1rem !important;
    border: none !important;
    padding: 1.5rem !important;
    position: relative;
    overflow: hidden;
    transition: all 0.25s ease;
    background: white !important;
    box-shadow: 0 4px 16px rgba(0,0,0,0.04), 0 1px 3px rgba(0,0,0,0.06) !important;
}
.fi-wi-stats-overview-stat:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(0,0,0,0.08), 0 4px 8px rgba(0,0,0,0.04) !important;
}
.fi-wi-stats-overview-stat::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, #10b981, #059669);
}
.fi-wi-stats-overview-stat[data-color="success"]::before,
.fi-wi-stats-overview-stat:has(.fi-color-success)::before { background: linear-gradient(90deg, #10b981, #059669); }
.fi-wi-stats-overview-stat[data-color="warning"]::before,
.fi-wi-stats-overview-stat:has(.fi-color-warning)::before { background: linear-gradient(90deg, #f59e0b, #d97706); }
.fi-wi-stats-overview-stat[data-color="danger"]::before,
.fi-wi-stats-overview-stat:has(.fi-color-danger)::before { background: linear-gradient(90deg, #ef4444, #dc2626); }
.fi-wi-stats-overview-stat[data-color="info"]::before,
.fi-wi-stats-overview-stat:has(.fi-color-info)::before { background: linear-gradient(90deg, #3b82f6, #2563eb); }
.fi-wi-stats-overview-stat-value {
    font-size: 2rem !important;
    font-weight: 800 !important;
    letter-spacing: -0.025em !important;
    background: linear-gradient(135deg, #065f46 0%, #059669 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.fi-wi-stats-overview-stat-label {
    font-size: 0.75rem !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    letter-spacing: 0.06em !important;
    color: #475569 !important;
}
.fi-wi-stats-overview-stat-description {
    color: #64748b !important;
    font-weight: 500 !important;
}

/* ---- Chart widget ---- */
.fi-wi-chart { padding: 0.5rem !important; }
.fi-wi-chart-canvas { border-radius: 0.75rem !important; padding: 1rem !important; background: #fafafa; }

/* ---- Tables ---- */
.fi-ta { border-radius: 1rem !important; }
.fi-ta-header-cell {
    background: linear-gradient(90deg, #f0fdf4 0%, #ecfdf5 100%) !important;
    color: #065f46 !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    letter-spacing: 0.05em !important;
    font-size: 0.7rem !important;
}
.fi-ta-row {
    transition: background 0.15s;
}
.fi-ta-row:hover {
    background: linear-gradient(90deg, #f0fdf4 0%, #ffffff 100%) !important;
}
.fi-ta-cell { padding-top: 0.875rem !important; padding-bottom: 0.875rem !important; }

/* Badge upgrades */
.fi-badge {
    font-weight: 700 !important;
    letter-spacing: 0.02em;
    box-shadow: 0 1px 2px rgba(0,0,0,0.06);
}

/* ---- Buttons ---- */
.fi-btn[data-variant="filled"][data-color="primary"] {
    background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
    border: none !important;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.25) !important;
    transition: all 0.2s !important;
}
.fi-btn[data-variant="filled"][data-color="primary"]:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(5, 150, 105, 0.35) !important;
    filter: brightness(1.05);
}
.fi-btn[data-variant="filled"][data-color="success"] {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
    border: none !important;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25) !important;
}
.fi-btn[data-variant="filled"][data-color="warning"] {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%) !important;
    border: none !important;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.25) !important;
}
.fi-btn[data-variant="filled"][data-color="danger"] {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%) !important;
    border: none !important;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.25) !important;
}

/* ---- Form inputs ---- */
.fi-input {
    border-radius: 0.625rem !important;
    border-color: #d1d5db !important;
    transition: all 0.15s;
}
.fi-input:focus {
    border-color: #10b981 !important;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15) !important;
}
.fi-fo-field-wrp-label { font-weight: 600 !important; color: #374151 !important; }

/* ---- Filters ---- */
.fi-ta-filters {
    background: linear-gradient(90deg, #f0fdf4 0%, #ffffff 100%) !important;
    border-radius: 0.75rem !important;
    padding: 1rem !important;
    margin-bottom: 1rem !important;
}

/* ---- Modal ---- */
.fi-modal-window { border-radius: 1.25rem !important; }
.fi-modal-header {
    background: linear-gradient(135deg, #f0fdf4 0%, #ffffff 100%) !important;
    border-radius: 1.25rem 1.25rem 0 0 !important;
}

/* ---- Page breadcrumbs / tabs ---- */
.fi-tabs-item[aria-selected="true"] {
    color: #065f46 !important;
    border-bottom-color: #10b981 !important;
}

/* ---- Pagination ---- */
.fi-pagination-item[aria-current="page"] {
    background: linear-gradient(135deg, #10b981, #059669) !important;
    color: white !important;
    border: none !important;
}

/* ---- Tooltip ---- */
.fi-tooltip {
    background: #065f46 !important;
    color: white !important;
    font-weight: 600 !important;
    border-radius: 0.5rem !important;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15) !important;
}

/* ---- Enterprise reusable utilities (page-specific blades) ---- */
.ent-hero {
    background: linear-gradient(135deg, #065f46 0%, #047857 40%, #059669 100%);
    color: white;
    padding: 1.75rem 2rem;
    border-radius: 1.25rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 10px 30px rgba(5, 150, 105, 0.25);
    position: relative;
    overflow: hidden;
}
.ent-hero::after {
    content: '';
    position: absolute;
    top: -40%;
    right: -10%;
    width: 380px;
    height: 380px;
    background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 70%);
    border-radius: 50%;
}
.ent-hero h2 {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.625rem;
}
.ent-hero p { opacity: 0.9; margin-top: 0.4rem; font-size: 0.9rem; }
.ent-hero-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: rgba(255,255,255,0.2);
    border: 1px solid rgba(255,255,255,0.3);
    color: white;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    backdrop-filter: blur(6px);
}

.ent-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    background: #ecfdf5;
    color: #047857;
    border: 1px solid #a7f3d0;
}
.ent-chip.amber { background: #fffbeb; color: #b45309; border-color: #fde68a; }
.ent-chip.rose { background: #fff1f2; color: #be123c; border-color: #fecdd3; }
.ent-chip.blue { background: #eff6ff; color: #1d4ed8; border-color: #bfdbfe; }
.ent-chip.indigo { background: #eef2ff; color: #4338ca; border-color: #c7d2fe; }

/* ---- Card-style rank badge ---- */
.rank-badge {
    width: 2rem; height: 2rem; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 0.8rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}
.rank-gold { background: linear-gradient(135deg, #fde047, #eab308); color: #78350f; }
.rank-silver { background: linear-gradient(135deg, #e5e7eb, #9ca3af); color: #1f2937; }
.rank-bronze { background: linear-gradient(135deg, #fbbf24, #d97706); color: #78350f; }
.rank-green { background: linear-gradient(135deg, #d1fae5, #6ee7b7); color: #065f46; }
.rank-rose { background: linear-gradient(135deg, #fee2e2, #fca5a5); color: #991b1b; }

/* ---- Resource EMPTY state ---- */
.fi-ta-empty-state-icon { color: #10b981 !important; }

/* ---- Scrollbar (webkit) ---- */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #6ee7b7, #10b981);
    border-radius: 6px;
}
::-webkit-scrollbar-thumb:hover { background: linear-gradient(180deg, #34d399, #059669); }

/* ---- Mobile polish ---- */
@media (max-width: 768px) {
    .ent-hero { padding: 1.25rem 1.25rem; }
    .ent-hero h2 { font-size: 1.15rem; }
    .fi-wi-stats-overview-stat-value { font-size: 1.5rem !important; }
}
