/* ==========================================================================
   الاتحاد النوعي للجمعيات العاملة في مجال التنمية المجتمعية - حكاية وطن
   Hekayet Watan - Official Executive Admin Theme (Gold & Deep Navy)
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;500;600;700;800;900&display=swap');

:root {
    --hw-gold: #d4af37;
    --hw-gold-hover: #b8972e;
    --hw-gold-light: rgba(212, 175, 55, 0.15);
    --hw-navy: #1e293b;
    --hw-navy-dark: #141d2b;
    --hw-navy-surface: #1e293b;
    --hw-card-bg: #ffffff;
    --hw-border-gold: rgba(212, 175, 55, 0.35);
}

/* Global Font Override */
body, .fi-body, .fi-page, .fi-sidebar, .fi-topbar, .fi-ta, .fi-fo, .fi-modal, .fi-widget, .fi-header {
    font-family: 'Cairo', system-ui, -apple-system, sans-serif !important;
}

/* Softer, more comfortable dark background for panel */
.fi-layout, .fi-body, .fi-main {
    background-color: #0f172a !important;
}

/* Luxury Topbar */
.fi-topbar {
    background: linear-gradient(90deg, #162032 0%, #1e293b 100%) !important;
    border-bottom: 2px solid var(--hw-gold) !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25) !important;
}

.fi-topbar nav, .fi-topbar a, .fi-topbar span {
    color: #f8fafc !important;
}

/* Sidebar Branding & Softer Background */
.fi-sidebar {
    background: #141e2e !important;
    border-inline-end: 1px solid var(--hw-border-gold) !important;
    transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.25s ease !important;
}

.fi-sidebar-header {
    background: rgba(15, 23, 42, 0.6) !important;
    border-bottom: 1px solid var(--hw-border-gold) !important;
    padding-block: 1rem !important;
}

/* Sidebar Group Headers - Clearer and larger */
.fi-sidebar-group-btn {
    padding-block: 0.5rem !important;
    cursor: pointer !important;
}

.fi-sidebar-group-label {
    font-size: 0.95rem !important;
    font-weight: 800 !important;
    letter-spacing: 0.3px !important;
    color: #f1c40f !important;
    opacity: 1 !important;
}

/* Sidebar Navigation Items - Readable typography & distinct contrast */
.fi-sidebar-item-btn {
    border-radius: 8px !important;
    transition: all 0.2s ease !important;
    margin-block: 3px !important;
    padding-block: 0.55rem !important;
    padding-inline: 0.85rem !important;
    display: flex !important;
    align-items: center !important;
    gap: 0.75rem !important;
}

.fi-sidebar-item-label {
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    color: #e2e8f0 !important;
    letter-spacing: 0.2px !important;
}

.fi-sidebar-item-btn:hover {
    background: rgba(212, 175, 55, 0.16) !important;
}

.fi-sidebar-item-btn:hover .fi-sidebar-item-label {
    color: #ffffff !important;
    font-weight: 700 !important;
}

.fi-sidebar-item-btn:hover .fi-sidebar-item-icon {
    color: #fbbf24 !important;
}

.fi-sidebar-item-icon {
    width: 1.35rem !important;
    height: 1.35rem !important;
    color: #cbd5e1 !important;
    transition: color 0.2s ease, transform 0.2s ease !important;
    flex-shrink: 0 !important;
}

/* Active Sidebar Item */
.fi-sidebar-item.fi-active .fi-sidebar-item-btn {
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.28) 0%, rgba(212, 175, 55, 0.08) 100%) !important;
    border-inline-start: 4px solid var(--hw-gold) !important;
}

.fi-sidebar-item.fi-active .fi-sidebar-item-label {
    color: #fef08a !important;
    font-weight: 800 !important;
}

.fi-sidebar-item.fi-active .fi-sidebar-item-icon {
    color: #f59e0b !important;
}

/* Fixed Collapsed Sidebar State: hide footer text overflow and center icons */
.fi-sidebar:not(.fi-sidebar-open) .fi-sidebar-footer-slogan {
    display: none !important;
}

.fi-sidebar:not(.fi-sidebar-open) .fi-sidebar-item-btn {
    justify-content: center !important;
    padding-inline: 0 !important;
}

.fi-sidebar:not(.fi-sidebar-open) .fi-sidebar-item-icon {
    margin-inline: auto !important;
    width: 1.5rem !important;
    height: 1.5rem !important;
}

/* Primary Action Buttons */
.fi-btn-primary {
    background: linear-gradient(135deg, #d4af37 0%, #b8972e 100%) !important;
    color: #1a2232 !important;
    font-weight: 800 !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    box-shadow: 0 4px 14px rgba(212, 175, 55, 0.35) !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.fi-btn-primary:hover {
    background: linear-gradient(135deg, #e5c148 0%, #c9a335 100%) !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.5) !important;
}

/* Stats Overview Cards */
.fi-wi-stats-overview-stat {
    background: #ffffff !important;
    border: 1px solid var(--hw-border-gold) !important;
    border-radius: 14px !important;
    box-shadow: 0 4px 16px rgba(15, 22, 36, 0.05) !important;
    transition: transform 0.25s ease, box-shadow 0.25s ease !important;
    position: relative !important;
    overflow: hidden !important;
}

.fi-wi-stats-overview-stat::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #d4af37, #f5e6b3);
}

.fi-wi-stats-overview-stat:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.2) !important;
    border-color: var(--hw-gold) !important;
}

.fi-wi-stats-overview-stat-value {
    color: #1a2232 !important;
    font-weight: 900 !important;
    font-size: 1.85rem !important;
}

.fi-wi-stats-overview-stat-label {
    font-weight: 700 !important;
    color: #64748b !important;
}

/* Charts Containers */
.fi-wi-chart {
    border: 1px solid var(--hw-border-gold) !important;
    border-radius: 14px !important;
    background: #ffffff !important;
    box-shadow: 0 4px 16px rgba(15, 22, 36, 0.05) !important;
    padding: 1.25rem !important;
}

/* Table Containers */
.fi-ta-ctn {
    border: 1px solid var(--hw-border-gold) !important;
    border-radius: 14px !important;
    overflow: hidden !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04) !important;
}

.fi-ta-header-cell {
    font-weight: 800 !important;
    font-size: 0.88rem !important;
    background-color: #f8fafc !important;
    color: #1a2232 !important;
}

.fi-ta-row:hover {
    background-color: rgba(212, 175, 55, 0.04) !important;
}

/* Badges */
.fi-badge {
    font-weight: 700 !important;
    border-radius: 20px !important;
    padding-inline: 0.65rem !important;
}

/* Forms & Inputs */
.fi-fo-field-wrp-label {
    font-weight: 700 !important;
    color: #1a2232 !important;
}

.fi-input, .fi-select-input {
    border-radius: 8px !important;
}

.fi-input:focus, .fi-select-input:focus {
    border-color: var(--hw-gold) !important;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.25) !important;
}

/* Slogan Banner Hook */
.hw-slogan-bar {
    background: linear-gradient(90deg, #d4af37 0%, #aa8320 100%);
    color: #1a2232;
    font-weight: 900;
    text-align: center;
    padding: 6px 12px;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}
