/* ─────────────────────────────────────────────────────────────────────────
   Chabok Admin — Custom Overrides
   Brand:  Chabok Orange #F05A00  (mirrors customer + courier mobile apps)
   Design: soft surfaces, 16px radii, warm tints, no indigo accents.
   ───────────────────────────────────────────────────────────────────────── */

:root {
    --chabok-orange: 240 90 0;
    --chabok-orange-dark: 209 77 0;
    --chabok-orange-light: 255 122 43;
    --chabok-orange-50: 255 244 230;
    --chabok-orange-100: 255 232 214;
    --chabok-slate-50: 248 250 252;
    --chabok-slate-100: 241 245 249;
    --chabok-slate-200: 226 232 240;
    --chabok-slate-500: 100 116 139;
    --chabok-slate-900: 15 23 42;
    --chabok-shadow-sm: 0 1px 2px rgb(15 23 42 / 0.04), 0 1px 3px rgb(15 23 42 / 0.04);
    --chabok-shadow-md: 0 4px 6px -1px rgb(15 23 42 / 0.05), 0 2px 4px -2px rgb(15 23 42 / 0.04);
    --chabok-shadow-lg: 0 10px 25px -5px rgb(15 23 42 / 0.08), 0 8px 10px -6px rgb(15 23 42 / 0.04);
}

/* ── Global typography & background ──────────────────────────────────────── */
.fi-body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: "cv11", "ss01", "ss03";
}
.fi-main-ctn,
.fi-main {
    background-color: rgb(var(--chabok-slate-50)) !important;
}
.dark .fi-main-ctn,
.dark .fi-main {
    background-color: #0b0f17 !important;
}

/* ── Brand / Logo area ───────────────────────────────────────────────────── */
.fi-logo {
    font-size: 1.1rem !important;
    font-weight: 800 !important;
    letter-spacing: -0.035em;
    color: rgb(var(--chabok-orange)) !important;
}
.fi-logo::before {
    content: "";
    display: inline-block;
    width: 0.55rem;
    height: 0.55rem;
    margin-right: 0.5rem;
    border-radius: 999px;
    background: linear-gradient(135deg, rgb(var(--chabok-orange-light)), rgb(var(--chabok-orange-dark)));
    vertical-align: 0.05em;
    box-shadow: 0 0 0 3px rgb(var(--chabok-orange) / 0.15);
}

/* ── Sidebar ─────────────────────────────────────────────────────────────── */
.fi-sidebar {
    background-color: #ffffff !important;
    border-right: 1px solid rgb(var(--chabok-slate-200)) !important;
}
.dark .fi-sidebar {
    background-color: #11161f !important;
    border-right: 1px solid rgb(255 255 255 / 0.06) !important;
}

.fi-sidebar-nav {
    padding: 0.5rem 0.5rem !important;
}

.fi-sidebar-group + .fi-sidebar-group {
    margin-top: 0.5rem;
}

.fi-sidebar-group-label {
    font-size: 0.65rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgb(var(--chabok-slate-500)) !important;
    padding: 0.5rem 0.75rem 0.25rem !important;
}

.fi-sidebar-item-button {
    border-radius: 10px !important;
    padding: 0.55rem 0.75rem !important;
    font-weight: 500;
    transition: background-color 150ms ease, color 150ms ease;
}
.fi-sidebar-item-button:hover {
    background-color: rgb(var(--chabok-orange-50)) !important;
}
.dark .fi-sidebar-item-button:hover {
    background-color: rgb(var(--chabok-orange) / 0.08) !important;
}

/* Nav item active — orange-tinted pill */
.fi-sidebar-item-button.fi-active {
    background-color: rgb(var(--chabok-orange-100)) !important;
    color: rgb(var(--chabok-orange-dark)) !important;
    font-weight: 600 !important;
}
.fi-sidebar-item-button.fi-active .fi-sidebar-item-icon,
.fi-sidebar-item-button.fi-active .fi-sidebar-item-label {
    color: rgb(var(--chabok-orange-dark)) !important;
}
.dark .fi-sidebar-item-button.fi-active {
    background-color: rgb(var(--chabok-orange) / 0.16) !important;
    color: rgb(var(--chabok-orange-light)) !important;
}
.dark .fi-sidebar-item-button.fi-active .fi-sidebar-item-icon,
.dark .fi-sidebar-item-button.fi-active .fi-sidebar-item-label {
    color: rgb(var(--chabok-orange-light)) !important;
}

/* ── Top bar ─────────────────────────────────────────────────────────────── */
.fi-topbar {
    background-color: rgb(255 255 255 / 0.85) !important;
    border-bottom: 1px solid rgb(var(--chabok-slate-200)) !important;
    backdrop-filter: blur(12px) saturate(180%);
    -webkit-backdrop-filter: blur(12px) saturate(180%);
}
.dark .fi-topbar {
    background-color: rgb(17 22 31 / 0.85) !important;
    border-bottom: 1px solid rgb(255 255 255 / 0.06) !important;
}

.fi-topbar-item {
    border-radius: 10px !important;
}

/* Global search field in topbar */
.fi-global-search-field input {
    border-radius: 10px !important;
    background-color: rgb(var(--chabok-slate-100)) !important;
    border: 1px solid transparent !important;
    transition: border-color 150ms ease, background-color 150ms ease;
}
.fi-global-search-field input:focus {
    border-color: rgb(var(--chabok-orange)) !important;
    background-color: #ffffff !important;
}
.dark .fi-global-search-field input {
    background-color: rgb(255 255 255 / 0.04) !important;
}
.dark .fi-global-search-field input:focus {
    background-color: rgb(255 255 255 / 0.06) !important;
}

/* ── Page header ─────────────────────────────────────────────────────────── */
.fi-page {
    padding-top: 1.5rem !important;
}
.fi-header-heading {
    font-size: 1.5rem !important;
    font-weight: 800 !important;
    letter-spacing: -0.025em !important;
    color: rgb(var(--chabok-slate-900));
}
.dark .fi-header-heading {
    color: #f1f5f9;
}
.fi-header-subheading {
    color: rgb(var(--chabok-slate-500)) !important;
    font-size: 0.875rem !important;
    margin-top: 0.25rem !important;
}

/* ── Section / Card wrappers ─────────────────────────────────────────────── */
.fi-section,
.fi-wi-chart,
.fi-wi-account {
    border-radius: 20px !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 1px 3px rgba(15,23,42,0.04), 0 1px 2px rgba(15,23,42,0.03) !important;
    background-color: #ffffff !important;
    transition: box-shadow 300ms ease, transform 300ms ease;
}
.fi-section:hover,
.fi-wi-chart:hover {
    box-shadow: 0 8px 24px rgba(15,23,42,0.06), 0 2px 8px rgba(15,23,42,0.04) !important;
    transform: translateY(-2px);
}
.dark .fi-section,
.dark .fi-wi-chart,
.dark .fi-wi-account {
    background-color: #11161f !important;
    border-color: rgba(255,255,255,0.06) !important;
    box-shadow: none !important;
}

.fi-section-header {
    padding: 1.1rem 1.25rem 0.875rem !important;
}

.fi-section-header-heading {
    font-size: 0.95rem !important;
    font-weight: 700 !important;
    letter-spacing: -0.01em !important;
    color: rgb(var(--chabok-slate-900));
}
.dark .fi-section-header-heading {
    color: #f1f5f9;
}

.fi-section-header-description {
    color: rgb(var(--chabok-slate-500)) !important;
    font-size: 0.8rem !important;
}

/* ── Stats overview cards ────────────────────────────────────────────────── */
.fi-wi-stats-overview-stat {
    padding: 1.25rem 1.5rem !important;
    position: relative;
    overflow: hidden;
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 20px !important;
    box-shadow: 0 1px 3px rgba(15,23,42,0.04), 0 1px 2px rgba(15,23,42,0.03) !important;
    transition: box-shadow 300ms ease, transform 300ms ease;
}
.fi-wi-stats-overview-stat:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(15,23,42,0.06), 0 2px 8px rgba(15,23,42,0.04) !important;
}
.dark .fi-wi-stats-overview-stat {
    background: #11161f !important;
    border-color: rgba(255,255,255,0.06) !important;
}
.fi-wi-stats-overview-stat-label {
    font-size: 0.7rem !important;
    font-weight: 600 !important;
    color: #94a3b8 !important;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}
.fi-wi-stats-overview-stat-value {
    font-weight: 800 !important;
    letter-spacing: -0.04em !important;
    font-size: 1.85rem !important;
    line-height: 1.1 !important;
    color: #0f172a !important;
    margin-top: 0.35rem !important;
}
.dark .fi-wi-stats-overview-stat-value {
    color: #f8fafc !important;
}
.fi-wi-stats-overview-stat-description {
    font-size: 0.8rem !important;
    font-weight: 500 !important;
    color: #64748b !important;
    margin-top: 0.5rem !important;
}
.dark .fi-wi-stats-overview-stat-description {
    color: #94a3b8 !important;
}
.fi-wi-stats-overview-stat-icon {
    color: #f05a00 !important;
    width: 2.5rem !important;
    height: 2.5rem !important;
    padding: 0.5rem;
    background: #fff7ed;
    border-radius: 12px;
}
.dark .fi-wi-stats-overview-stat-icon {
    background: rgba(240,90,0,0.1);
}

/* ── Tables ──────────────────────────────────────────────────────────────── */
.fi-ta {
    border-radius: 16px !important;
    overflow: hidden;
}
.fi-ta-header {
    border-radius: 16px 16px 0 0 !important;
    padding: 1rem 1.25rem !important;
    border-bottom: 1px solid rgb(var(--chabok-slate-200)) !important;
}
.dark .fi-ta-header {
    border-bottom-color: rgb(255 255 255 / 0.06) !important;
}

.fi-ta-header-cell {
    background-color: rgb(var(--chabok-slate-50)) !important;
    border-bottom: 1px solid rgb(var(--chabok-slate-200)) !important;
}
.dark .fi-ta-header-cell {
    background-color: rgb(255 255 255 / 0.02) !important;
    border-bottom-color: rgb(255 255 255 / 0.06) !important;
}

.fi-ta-header-cell-label {
    font-size: 0.7rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgb(var(--chabok-slate-500)) !important;
}

.fi-ta-cell {
    font-size: 0.875rem !important;
    padding: 0.75rem 1rem !important;
}

/* Row hover — warm orange tint (replaces old indigo) */
.fi-ta-row:hover td,
.fi-ta-row:hover {
    background-color: rgb(var(--chabok-orange) / 0.04) !important;
}
.dark .fi-ta-row:hover td,
.dark .fi-ta-row:hover {
    background-color: rgb(var(--chabok-orange) / 0.08) !important;
}

/* Selected row */
.fi-ta-row[aria-selected="true"] td {
    background-color: rgb(var(--chabok-orange) / 0.06) !important;
}

/* ── Badges ──────────────────────────────────────────────────────────────── */
.fi-badge {
    font-weight: 600 !important;
    font-size: 0.7rem !important;
    letter-spacing: 0.015em;
    border-radius: 999px !important;
    padding: 0.25rem 0.6rem !important;
}

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.fi-btn {
    font-weight: 600 !important;
    border-radius: 10px !important;
    transition: transform 100ms ease, box-shadow 150ms ease, background-color 150ms ease;
}
.fi-btn:active {
    transform: translateY(1px);
}

/* Primary button — gradient orange */
.fi-btn-color-primary[type="submit"],
button.fi-btn-color-primary,
.fi-ac-btn-action.fi-btn-color-primary {
    background-image: linear-gradient(135deg, rgb(var(--chabok-orange-light)), rgb(var(--chabok-orange))) !important;
    box-shadow: 0 1px 2px rgb(var(--chabok-orange) / 0.25), 0 4px 12px rgb(var(--chabok-orange) / 0.15) !important;
    border: 0 !important;
    color: #ffffff !important;
}
.fi-btn-color-primary[type="submit"]:hover,
button.fi-btn-color-primary:hover,
.fi-ac-btn-action.fi-btn-color-primary:hover {
    box-shadow: 0 2px 4px rgb(var(--chabok-orange) / 0.3), 0 8px 20px rgb(var(--chabok-orange) / 0.22) !important;
}

/* ── Form inputs ─────────────────────────────────────────────────────────── */
.fi-input,
.fi-select-input,
.fi-textarea {
    border-radius: 10px !important;
    transition: border-color 150ms ease, box-shadow 150ms ease;
}
.fi-input:focus,
.fi-select-input:focus,
.fi-textarea:focus {
    box-shadow: 0 0 0 4px rgb(var(--chabok-orange) / 0.12) !important;
    border-color: rgb(var(--chabok-orange)) !important;
}

.fi-fo-field-wrp-label {
    font-size: 0.8rem !important;
    font-weight: 600 !important;
    color: rgb(var(--chabok-slate-900));
}
.dark .fi-fo-field-wrp-label {
    color: #e2e8f0;
}

/* ── Filters / Search bar ────────────────────────────────────────────────── */
.fi-ta-search-field input {
    border-radius: 10px !important;
}
.fi-ta-filters-form {
    border-radius: 14px !important;
}

/* ── Charts ──────────────────────────────────────────────────────────────── */
.fi-wi-chart {
    padding: 1.25rem !important;
}
.fi-wi-chart-header-heading,
.fi-wi-stats-overview-header-heading {
    font-size: 0.95rem !important;
    font-weight: 700 !important;
    letter-spacing: -0.01em;
}

/* ── Pagination ──────────────────────────────────────────────────────────── */
.fi-pagination {
    padding: 0.875rem 1rem !important;
}
.fi-pagination-item.fi-active,
.fi-pagination-item[aria-current="page"] {
    background-color: rgb(var(--chabok-orange)) !important;
    color: #ffffff !important;
    border-color: rgb(var(--chabok-orange)) !important;
}

/* ── Dashboard welcome card ──────────────────────────────────────────────── */
.fi-wi-account {
    padding: 1.25rem 1.5rem !important;
    background-image: linear-gradient(135deg, rgb(var(--chabok-orange-light) / 0.10), rgb(var(--chabok-orange) / 0.04)) !important;
    border-color: rgb(var(--chabok-orange) / 0.18) !important;
}
.dark .fi-wi-account {
    background-image: linear-gradient(135deg, rgb(var(--chabok-orange) / 0.16), rgb(var(--chabok-orange-dark) / 0.08)) !important;
    border-color: rgb(var(--chabok-orange) / 0.24) !important;
}
.fi-wi-account-name {
    font-weight: 800 !important;
    font-size: 1.15rem !important;
    letter-spacing: -0.02em;
    color: rgb(var(--chabok-slate-900)) !important;
}
.dark .fi-wi-account-name {
    color: #f8fafc !important;
}

/* ── Modals ──────────────────────────────────────────────────────────────── */
.fi-modal-window {
    border-radius: 18px !important;
    box-shadow: var(--chabok-shadow-lg) !important;
}

/* ── Tabs ────────────────────────────────────────────────────────────────── */
.fi-tabs {
    border-radius: 12px !important;
    background-color: rgb(var(--chabok-slate-100)) !important;
    padding: 0.25rem !important;
}
.dark .fi-tabs {
    background-color: rgb(255 255 255 / 0.04) !important;
}
.fi-tabs-item.fi-active {
    background-color: #ffffff !important;
    color: rgb(var(--chabok-orange-dark)) !important;
    box-shadow: var(--chabok-shadow-sm) !important;
}
.dark .fi-tabs-item.fi-active {
    background-color: rgb(255 255 255 / 0.08) !important;
    color: rgb(var(--chabok-orange-light)) !important;
}

/* ── Dropdown menus ──────────────────────────────────────────────────────── */
.fi-dropdown-panel {
    border-radius: 14px !important;
    box-shadow: var(--chabok-shadow-lg) !important;
    border: 1px solid rgb(var(--chabok-slate-200)) !important;
}
.dark .fi-dropdown-panel {
    border-color: rgb(255 255 255 / 0.06) !important;
}
.fi-dropdown-list-item {
    border-radius: 8px !important;
}

/* ── Notifications (toasts) ──────────────────────────────────────────────── */
.fi-no-notification {
    border-radius: 14px !important;
    box-shadow: var(--chabok-shadow-lg) !important;
}

/* ── Scrollbar polish ────────────────────────────────────────────────────── */
.fi-sidebar-nav::-webkit-scrollbar,
.fi-main::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
.fi-sidebar-nav::-webkit-scrollbar-thumb,
.fi-main::-webkit-scrollbar-thumb {
    background-color: rgb(var(--chabok-slate-200));
    border-radius: 999px;
}
.fi-sidebar-nav::-webkit-scrollbar-thumb:hover,
.fi-main::-webkit-scrollbar-thumb:hover {
    background-color: rgb(var(--chabok-slate-500) / 0.5);
}

/* ── Empty states ────────────────────────────────────────────────────────── */
.fi-ta-empty-state,
.fi-empty-state {
    padding: 2.5rem 1rem !important;
}
.fi-ta-empty-state-icon,
.fi-empty-state-icon {
    color: rgb(var(--chabok-orange) / 0.4) !important;
}

/* ── Login page polish ───────────────────────────────────────────────────── */
.fi-simple-layout {
    background:
        radial-gradient(at 20% 0%, rgb(var(--chabok-orange) / 0.10) 0px, transparent 50%),
        radial-gradient(at 80% 100%, rgb(var(--chabok-orange-light) / 0.10) 0px, transparent 50%),
        rgb(var(--chabok-slate-50)) !important;
}
.dark .fi-simple-layout {
    background:
        radial-gradient(at 20% 0%, rgb(var(--chabok-orange) / 0.12) 0px, transparent 50%),
        radial-gradient(at 80% 100%, rgb(var(--chabok-orange-dark) / 0.12) 0px, transparent 50%),
        #0b0f17 !important;
}
.fi-simple-main {
    border-radius: 20px !important;
    box-shadow: var(--chabok-shadow-lg) !important;
    border: 1px solid rgb(var(--chabok-slate-200)) !important;
}
.dark .fi-simple-main {
    border-color: rgb(255 255 255 / 0.06) !important;
}

/* ═════════════════════════════════════════════════════════════════════════
   v3 polish — Linear / Stripe / Notion-inspired refinements
   ═════════════════════════════════════════════════════════════════════════ */

/* ── Sidebar: Linear-style 3px left accent on active item ────────────────── */
.fi-sidebar-item-button {
    position: relative;
    height: 36px;
}
.fi-sidebar-item-button.fi-active::before {
    content: "";
    position: absolute;
    left: -0.5rem;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 22px;
    border-radius: 2px;
    background-color: rgb(var(--chabok-orange));
}
.fi-sidebar-item-icon {
    width: 1.05rem !important;
    height: 1.05rem !important;
}

/* ── Sidebar collapse icon size consistency ──────────────────────────────── */
.fi-sidebar-collapse-btn {
    border-radius: 8px !important;
}

/* ── Stat cards: Stripe-style monospace numerics + tight metric strip ────── */
.fi-wi-stats-overview {
    gap: 0.875rem !important;
}
.fi-wi-stats-overview-stat-value {
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum" 1, "cv11" 1;
}
.fi-wi-stats-overview-stat-description-icon {
    width: 0.85rem !important;
    height: 0.85rem !important;
}
/* When stat description is positive (text-success), use a tinted pill */
.fi-wi-stats-overview-stat-description.text-success-600,
.fi-wi-stats-overview-stat-description .text-success-600 {
    color: rgb(16 185 129) !important;
}
.fi-wi-stats-overview-stat-description.text-danger-600,
.fi-wi-stats-overview-stat-description .text-danger-600 {
    color: rgb(239 68 68) !important;
}

/* ── Tables: sticky header + tabular numerics on numeric columns ─────────── */
.fi-ta-table {
    table-layout: auto;
}
.fi-ta-header-row th,
.fi-ta-header-cell {
    position: sticky;
    top: 0;
    z-index: 5;
}
/* Apply tabular numerics to any cell containing a numeric badge or money */
.fi-ta-text-item,
.fi-ta-cell {
    font-variant-numeric: tabular-nums;
}
/* Right-align numeric-looking columns (cells with .fi-ta-record-currency etc.) */
.fi-ta-cell.fi-align-end,
.fi-ta-cell[data-align="end"],
.fi-ta-cell.text-end {
    text-align: right;
}
.fi-ta-header-cell.fi-align-end {
    text-align: right;
}

/* Compact row option (denser data view) */
.fi-ta-row .fi-ta-cell {
    padding-top: 0.65rem !important;
    padding-bottom: 0.65rem !important;
}

/* ── Shimmer skeleton loader (replaces spinner where possible) ───────────── */
@keyframes chabok-shimmer {
    0%   { background-position: -400px 0; }
    100% { background-position: 400px 0; }
}
.fi-skeleton,
[wire\:loading].fi-skeletonable {
    background: linear-gradient(
        90deg,
        rgb(var(--chabok-slate-100)) 0%,
        rgb(var(--chabok-slate-200)) 50%,
        rgb(var(--chabok-slate-100)) 100%
    );
    background-size: 800px 100%;
    animation: chabok-shimmer 1.4s linear infinite;
    border-radius: 8px;
    color: transparent !important;
}
.dark .fi-skeleton {
    background: linear-gradient(
        90deg,
        rgb(255 255 255 / 0.04) 0%,
        rgb(255 255 255 / 0.08) 50%,
        rgb(255 255 255 / 0.04) 100%
    );
    background-size: 800px 100%;
}

/* Loading spinner — use brand orange */
.fi-loading-indicator {
    color: rgb(var(--chabok-orange)) !important;
}

/* ── Card hover: Linear-style — border-only, no transform ────────────────── */
.fi-section:hover,
.fi-wi-chart:hover {
    border-color: rgb(var(--chabok-slate-500) / 0.25) !important;
    transition: border-color 200ms ease;
}
.dark .fi-section:hover,
.dark .fi-wi-chart:hover {
    border-color: rgb(255 255 255 / 0.12) !important;
}

/* ── Global search: Linear-style keyboard hint chip (Cmd+K) ──────────────── */
.fi-topbar-global-search-field {
    position: relative;
}
.fi-topbar-global-search-field input {
    padding-right: 4.5rem !important;
}
.fi-topbar-global-search-field::after {
    content: "⌘K";
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.7rem;
    font-weight: 600;
    color: rgb(var(--chabok-slate-500));
    background-color: #ffffff;
    border: 1px solid rgb(var(--chabok-slate-200));
    border-radius: 6px;
    padding: 0.15rem 0.4rem;
    pointer-events: none;
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
    letter-spacing: 0.02em;
}
.dark .fi-topbar-global-search-field::after {
    background-color: rgb(255 255 255 / 0.06);
    border-color: rgb(255 255 255 / 0.10);
    color: #cbd5e1;
}

/* ── Focus ring: WCAG-grade, brand-tinted, applied universally ───────────── */
.fi-btn:focus-visible,
.fi-input:focus-visible,
.fi-select-input:focus-visible,
.fi-textarea:focus-visible,
.fi-sidebar-item-button:focus-visible,
.fi-link:focus-visible {
    outline: 2px solid rgb(var(--chabok-orange)) !important;
    outline-offset: 2px !important;
}

/* ── Inline banners (replace modal-style errors with inline strips) ──────── */
.fi-section.fi-color-success {
    background-color: rgb(16 185 129 / 0.06) !important;
    border-color: rgb(16 185 129 / 0.25) !important;
}
.fi-section.fi-color-danger {
    background-color: rgb(239 68 68 / 0.06) !important;
    border-color: rgb(239 68 68 / 0.25) !important;
}
.fi-section.fi-color-warning {
    background-color: rgb(245 158 11 / 0.06) !important;
    border-color: rgb(245 158 11 / 0.25) !important;
}
.fi-section.fi-color-info {
    background-color: rgb(var(--chabok-orange) / 0.05) !important;
    border-color: rgb(var(--chabok-orange) / 0.20) !important;
}

/* ── Filter chips (Filament filter pills) — Linear-style ─────────────────── */
.fi-ta-filter-indicators {
    gap: 0.5rem !important;
}
.fi-badge[data-filter-indicator] {
    background-color: rgb(var(--chabok-orange-100)) !important;
    color: rgb(var(--chabok-orange-dark)) !important;
    border: 1px solid rgb(var(--chabok-orange) / 0.20);
}
.dark .fi-badge[data-filter-indicator] {
    background-color: rgb(var(--chabok-orange) / 0.16) !important;
    color: rgb(var(--chabok-orange-light)) !important;
    border-color: rgb(var(--chabok-orange) / 0.30);
}

/* ── Resource header action buttons: stronger hierarchy ──────────────────── */
.fi-header-actions {
    gap: 0.5rem !important;
}
.fi-header .fi-btn-color-gray {
    background-color: #ffffff !important;
    border: 1px solid rgb(var(--chabok-slate-200)) !important;
}
.dark .fi-header .fi-btn-color-gray {
    background-color: rgb(255 255 255 / 0.04) !important;
    border-color: rgb(255 255 255 / 0.08) !important;
}

/* ── Breadcrumbs ─────────────────────────────────────────────────────────── */
.fi-breadcrumbs {
    margin-bottom: 0.5rem !important;
}
.fi-breadcrumbs-item-label {
    font-size: 0.8rem !important;
    color: rgb(var(--chabok-slate-500)) !important;
}
.fi-breadcrumbs-item:last-child .fi-breadcrumbs-item-label {
    color: rgb(var(--chabok-slate-900)) !important;
    font-weight: 600 !important;
}

/* ── Action buttons row (table rows) ─────────────────────────────────────── */
.fi-ta-actions {
    gap: 0.25rem !important;
}
.fi-icon-btn {
    width: 2rem !important;
    height: 2rem !important;
    border-radius: 8px !important;
    transition: background-color 150ms ease;
}
.fi-icon-btn:hover {
    background-color: rgb(var(--chabok-orange) / 0.08) !important;
    color: rgb(var(--chabok-orange-dark)) !important;
}
.dark .fi-icon-btn:hover {
    background-color: rgb(var(--chabok-orange) / 0.14) !important;
    color: rgb(var(--chabok-orange-light)) !important;
}

/* ── Toggle / Switch — brand orange when on ──────────────────────────────── */
.fi-toggle.fi-checked,
input[type="checkbox"][role="switch"]:checked {
    background-color: rgb(var(--chabok-orange)) !important;
}

/* ── Checkbox & Radio — brand orange ─────────────────────────────────────── */
.fi-checkbox-input:checked,
input[type="checkbox"]:checked,
input[type="radio"]:checked {
    background-color: rgb(var(--chabok-orange)) !important;
    border-color: rgb(var(--chabok-orange)) !important;
}

/* ── Code & kbd elements (Notion-style) ──────────────────────────────────── */
code, kbd, samp, pre {
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
}
kbd {
    background-color: rgb(var(--chabok-slate-100));
    border: 1px solid rgb(var(--chabok-slate-200));
    border-radius: 4px;
    padding: 0.1rem 0.35rem;
    font-size: 0.75rem;
    color: rgb(var(--chabok-slate-900));
}
.dark kbd {
    background-color: rgb(255 255 255 / 0.06);
    border-color: rgb(255 255 255 / 0.10);
    color: #f1f5f9;
}

/* ── Page transitions (subtle fade) ──────────────────────────────────────── */
.fi-main > * {
    animation: chabok-page-in 240ms ease-out;
}
@keyframes chabok-page-in {
    from { opacity: 0; transform: translateY(2px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Tooltip (Filament default) — softer, brand-aligned ──────────────────── */
.fi-tooltip,
[role="tooltip"] {
    border-radius: 8px !important;
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    background-color: rgb(var(--chabok-slate-900)) !important;
    color: #ffffff !important;
    padding: 0.4rem 0.6rem !important;
    box-shadow: var(--chabok-shadow-md) !important;
}

/* ── Dashboard widget grid — generous gutters ────────────────────────────── */
.fi-dashboard-page > div,
.fi-dashboard > div {
    gap: 1rem !important;
}

/* ── Chart heading row alignment ─────────────────────────────────────────── */
.fi-wi-chart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

/* ── Avatar / user circle in topbar ──────────────────────────────────────── */
.fi-avatar {
    border: 2px solid rgb(var(--chabok-orange) / 0.20) !important;
}

/* ── Section divider (between collapsed groups in sidebar) ───────────────── */
.fi-sidebar-group:not(:last-child)::after {
    content: "";
    display: block;
    height: 1px;
    margin: 0.5rem 0.75rem 0;
    background-color: rgb(var(--chabok-slate-200));
}
.dark .fi-sidebar-group:not(:last-child)::after {
    background-color: rgb(255 255 255 / 0.04);
}

/* ── User menu trigger ───────────────────────────────────────────────────── */
.fi-user-menu-trigger {
    border-radius: 999px !important;
    padding: 2px !important;
}

/* ═════════════════════════════════════════════════════════════════════════
   Clean & Modern Enhancements  (v7 — inspired by PatientPop dashboard)
   ═════════════════════════════════════════════════════════════════════════ */

/* ── Buttons: subtle orange glow, clean press ─────────────────────────── */
.fi-btn-color-primary[type="submit"],
button.fi-btn-color-primary,
.fi-ac-btn-action.fi-btn-color-primary {
    box-shadow: 0 2px 8px rgb(var(--chabok-orange) / 0.2) !important;
}
.fi-btn-color-primary[type="submit"]:hover,
button.fi-btn-color-primary:hover,
.fi-ac-btn-action.fi-btn-color-primary:hover {
    box-shadow: 0 4px 14px rgb(var(--chabok-orange) / 0.25) !important;
    transform: translateY(-1px);
}

/* ── Clean topbar ──────────────────────────────────────────────────────── */
.fi-topbar {
    background: rgba(255, 255, 255, 0.9) !important;
    backdrop-filter: blur(12px) saturate(150%);
    -webkit-backdrop-filter: blur(12px) saturate(150%);
    border-bottom: 1px solid #e2e8f0 !important;
}
.dark .fi-topbar {
    background: rgba(17, 22, 31, 0.9) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}

/* ── Sidebar soft shadow ──────────────────────────────────────────────── */
.fi-sidebar {
    box-shadow: 2px 0 12px rgba(15, 23, 42, 0.03) !important;
}
.dark .fi-sidebar {
    box-shadow: 2px 0 12px rgba(0, 0, 0, 0.15) !important;
}

/* ── Clean dropdowns ─────────────────────────────────────────────────── */
.fi-dropdown-panel {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 10px 40px rgba(15, 23, 42, 0.1) !important;
}
.dark .fi-dropdown-panel {
    background: #11161f !important;
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* ── Clean modal ─────────────────────────────────────────────────────── */
.fi-modal-window {
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.12) !important;
}
.dark .fi-modal-window {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35) !important;
}

/* ── Avatar subtle ring ──────────────────────────────────────────────── */
.fi-avatar {
    box-shadow: 0 0 0 2px rgb(var(--chabok-orange) / 0.2) !important;
}

/* ── Clean focus states ──────────────────────────────────────────────── */
.fi-input:focus,
.fi-select-input:focus,
.fi-textarea:focus {
    box-shadow: 0 0 0 3px rgb(var(--chabok-orange) / 0.1) !important;
}

/* ── Reduce motion respect ─────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* ═════════════════════════════════════════════════════════════════════════
   v8 — Pro-grade refinements (Outfit font, richer stat cards, branded
   sidebar header, gradient hero login, dashboard polish)
   ═════════════════════════════════════════════════════════════════════════ */

/* ── Load Outfit + Work Sans (matches mobile apps & download page) ──────── */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800;900&family=Work+Sans:wght@400;500;600;700&display=swap');

.fi-body {
    font-family: 'Work Sans', ui-sans-serif, system-ui, sans-serif !important;
}
.fi-header-heading,
.fi-wi-stats-overview-stat-value,
.fi-sidebar-item-label,
.fi-wi-stats-overview-stat-label,
.fi-section-header-heading,
.fi-wi-chart-header-heading,
.fi-logo {
    font-family: 'Outfit', ui-sans-serif, system-ui, sans-serif !important;
}

/* ── Sidebar: branded top header strip ──────────────────────────────────── */
.fi-sidebar::before {
    content: '';
    display: block;
    height: 4px;
    background: linear-gradient(90deg, #E84E00 0%, #FF7A2B 50%, #FF9956 100%);
    border-radius: 0;
    flex-shrink: 0;
}

/* Sidebar brand name: bigger, more weight */
.fi-logo {
    font-size: 1.2rem !important;
    font-weight: 900 !important;
    letter-spacing: -0.04em !important;
}
.fi-logo::before {
    width: 0.65rem;
    height: 0.65rem;
    box-shadow: 0 0 0 4px rgb(240 90 0 / 0.12), 0 2px 6px rgb(240 90 0 / 0.35);
}

/* ── Stat cards: colored gradient top accent per position ───────────────── */
.fi-wi-stats-overview-stat {
    border-top: 3px solid transparent !important;
    background-clip: padding-box !important;
    position: relative;
    overflow: hidden;
}
.fi-wi-stats-overview-stat::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #E84E00, #FF7A2B);
    border-radius: 2px 2px 0 0;
}
/* Alternate colors for 2nd, 3rd, 4th stat cards */
.fi-wi-stats-overview-stat:nth-child(2)::before {
    background: linear-gradient(90deg, #3B82F6, #60A5FA);
}
.fi-wi-stats-overview-stat:nth-child(3)::before {
    background: linear-gradient(90deg, #10B981, #34D399);
}
.fi-wi-stats-overview-stat:nth-child(4)::before {
    background: linear-gradient(90deg, #8B5CF6, #A78BFA);
}
.fi-wi-stats-overview-stat:nth-child(5)::before {
    background: linear-gradient(90deg, #F59E0B, #FCD34D);
}
.fi-wi-stats-overview-stat:nth-child(6)::before {
    background: linear-gradient(90deg, #EC4899, #F9A8D4);
}

/* Stat icon: match color to accent */
.fi-wi-stats-overview-stat:nth-child(2) .fi-wi-stats-overview-stat-icon {
    color: #3B82F6 !important;
    background: rgba(59,130,246,0.10) !important;
}
.fi-wi-stats-overview-stat:nth-child(3) .fi-wi-stats-overview-stat-icon {
    color: #10B981 !important;
    background: rgba(16,185,129,0.10) !important;
}
.fi-wi-stats-overview-stat:nth-child(4) .fi-wi-stats-overview-stat-icon {
    color: #8B5CF6 !important;
    background: rgba(139,92,246,0.10) !important;
}

/* ── Stat card value: larger, tabular, Outfit ───────────────────────────── */
.fi-wi-stats-overview-stat-value {
    font-size: 2rem !important;
    font-weight: 900 !important;
    letter-spacing: -0.05em !important;
    line-height: 1 !important;
    margin-top: 0.5rem !important;
}

/* ── Dashboard header: add gradient band behind it ──────────────────────── */
.fi-page-header {
    background: linear-gradient(135deg, rgba(240,90,0,0.05) 0%, rgba(255,122,43,0.02) 100%);
    border-radius: 16px;
    padding: 1rem 1.25rem !important;
    margin-bottom: 1.25rem !important;
    border: 1px solid rgba(240,90,0,0.08);
}
.dark .fi-page-header {
    background: linear-gradient(135deg, rgba(240,90,0,0.10) 0%, rgba(255,122,43,0.04) 100%);
    border-color: rgba(240,90,0,0.15);
}

/* ── Account widget: bolder gradient ────────────────────────────────────── */
.fi-wi-account {
    background: linear-gradient(135deg, #FFF4E6 0%, #FFF9F5 100%) !important;
    border-color: rgba(240,90,0,0.20) !important;
    position: relative;
    overflow: hidden;
}
.fi-wi-account::after {
    content: '';
    position: absolute;
    right: -20px; top: -20px;
    width: 120px; height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(240,90,0,0.12) 0%, transparent 70%);
    pointer-events: none;
}
.dark .fi-wi-account {
    background: linear-gradient(135deg, rgba(240,90,0,0.14) 0%, rgba(240,90,0,0.06) 100%) !important;
    border-color: rgba(240,90,0,0.22) !important;
}

/* ── Topbar: slightly taller, elevated brand feel ───────────────────────── */
.fi-topbar {
    min-height: 56px !important;
    box-shadow: 0 1px 0 rgba(15,23,42,0.06), 0 2px 8px rgba(15,23,42,0.03) !important;
}
.dark .fi-topbar {
    box-shadow: 0 1px 0 rgba(255,255,255,0.05) !important;
}

/* ── Tables: more visual separation between rows ─────────────────────────── */
.fi-ta-row:nth-child(even) td {
    background-color: rgba(248,250,252,0.6) !important;
}
.dark .fi-ta-row:nth-child(even) td {
    background-color: rgba(255,255,255,0.015) !important;
}

/* Row hover: stronger feedback */
.fi-ta-row:hover td {
    background-color: rgb(240 90 0 / 0.05) !important;
}
.dark .fi-ta-row:hover td {
    background-color: rgb(240 90 0 / 0.09) !important;
}

/* ── Charts: subtle inner glow on hover ─────────────────────────────────── */
.fi-wi-chart {
    transition: box-shadow 200ms ease, border-color 200ms ease !important;
}
.fi-wi-chart:hover {
    box-shadow: 0 8px 30px rgba(240,90,0,0.08), 0 2px 8px rgba(15,23,42,0.04) !important;
    border-color: rgba(240,90,0,0.18) !important;
}
.dark .fi-wi-chart:hover {
    box-shadow: 0 8px 30px rgba(240,90,0,0.12) !important;
    border-color: rgba(240,90,0,0.22) !important;
}

/* ── Login page: branded hero gradient ──────────────────────────────────── */
.fi-simple-layout {
    background:
        radial-gradient(ellipse 800px 500px at 50% -10%, rgba(240,90,0,0.16) 0%, transparent 65%),
        radial-gradient(ellipse 500px 400px at 80% 100%, rgba(255,122,43,0.10) 0%, transparent 65%),
        #F8FAFC !important;
    min-height: 100vh;
}
.dark .fi-simple-layout {
    background:
        radial-gradient(ellipse 800px 500px at 50% -10%, rgba(240,90,0,0.18) 0%, transparent 65%),
        radial-gradient(ellipse 500px 400px at 80% 100%, rgba(240,90,0,0.10) 0%, transparent 65%),
        #080C12 !important;
}

/* Login card: glassmorphism */
.fi-simple-main {
    background: rgba(255,255,255,0.92) !important;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid rgba(255,255,255,0.6) !important;
    box-shadow: 0 0 0 1px rgba(240,90,0,0.08), 0 24px 60px rgba(15,23,42,0.10), 0 8px 20px rgba(15,23,42,0.06) !important;
}
.dark .fi-simple-main {
    background: rgba(17,22,31,0.88) !important;
    border-color: rgba(255,255,255,0.07) !important;
    box-shadow: 0 0 0 1px rgba(240,90,0,0.12), 0 24px 60px rgba(0,0,0,0.35) !important;
}

/* Login heading */
.fi-simple-main .fi-header-heading {
    font-size: 1.6rem !important;
    font-weight: 900 !important;
    letter-spacing: -0.04em !important;
    background: linear-gradient(135deg, #E84E00, #FF7A2B);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.dark .fi-simple-main .fi-header-heading {
    background: linear-gradient(135deg, #FF7A2B, #FFAA6B);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Navigation group labels: sharper ───────────────────────────────────── */
.fi-sidebar-group-label {
    font-family: 'Outfit', sans-serif !important;
    font-size: 0.62rem !important;
    letter-spacing: 0.14em !important;
}

/* ── Section headers: more breathing room ───────────────────────────────── */
.fi-section-header-heading {
    font-size: 1rem !important;
    font-weight: 700 !important;
}

/* ── Empty state: branded illustration ──────────────────────────────────── */
.fi-ta-empty-state-icon,
.fi-empty-state-icon {
    color: rgb(240 90 0 / 0.35) !important;
    width: 2.5rem !important;
    height: 2.5rem !important;
}
.fi-ta-empty-state-heading,
.fi-empty-state-heading {
    font-family: 'Outfit', sans-serif !important;
    font-weight: 700 !important;
}

/* ── Pagination: pill style ──────────────────────────────────────────────── */
.fi-pagination-item button {
    border-radius: 8px !important;
    font-family: 'Outfit', sans-serif !important;
    font-weight: 600 !important;
    font-size: 0.82rem !important;
    min-width: 34px !important;
    min-height: 34px !important;
}
.fi-pagination-item.fi-active button,
.fi-pagination-item[aria-current="page"] button {
    background: linear-gradient(135deg, #E84E00, #FF7A2B) !important;
    box-shadow: 0 3px 10px rgba(240,90,0,0.30) !important;
    border: none !important;
    color: #fff !important;
}

/* ── Badges: more contrast & variety ────────────────────────────────────── */
.fi-badge {
    font-family: 'Outfit', sans-serif !important;
    font-size: 0.68rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.02em !important;
    padding: 0.28rem 0.65rem !important;
}

/* ── Section cards: slightly more depth ─────────────────────────────────── */
.fi-section {
    box-shadow: 0 2px 4px rgba(15,23,42,0.04), 0 1px 2px rgba(15,23,42,0.03) !important;
    transition: box-shadow 200ms ease, border-color 200ms ease, transform 200ms ease !important;
}
.fi-section:hover {
    box-shadow: 0 6px 20px rgba(15,23,42,0.06), 0 2px 6px rgba(15,23,42,0.04) !important;
    border-color: rgba(240,90,0,0.12) !important;
    transform: translateY(-1px) !important;
}
.dark .fi-section:hover {
    border-color: rgba(240,90,0,0.18) !important;
}

/* ── Page transitions: smooth fade-slide ────────────────────────────────── */
.fi-main > * {
    animation: chabok-page-in 200ms cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes chabok-page-in {
    from { opacity: 0; transform: translateY(4px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Input focus: tighter glow ───────────────────────────────────────────── */
.fi-input:focus,
.fi-select-input:focus,
.fi-textarea:focus {
    border-color: #F05A00 !important;
    box-shadow: 0 0 0 3px rgba(240,90,0,0.12) !important;
    outline: none !important;
}

/* ── Notifications / toasts: cleaner ────────────────────────────────────── */
.fi-no-notification {
    border-left: 3px solid #F05A00 !important;
    border-radius: 12px !important;
}
.fi-no-notification-icon[data-status="success"] {
    border-left-color: #10B981 !important;
}
.fi-no-notification-icon[data-status="danger"] {
    border-left-color: #EF4444 !important;
}
.fi-no-notification-icon[data-status="warning"] {
    border-left-color: #F59E0B !important;
}

/* ═══════════════════════════════════════════════════════════════════════════
   v9 — Award-polish refinement layer
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Glass topbar ────────────────────────────────────────────────────────── */
.fi-topbar nav,
.fi-topbar {
    background-color: rgba(255, 255, 255, 0.82) !important;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border-bottom: 1px solid rgba(226, 232, 240, 0.7) !important;
}
.dark .fi-topbar nav,
.dark .fi-topbar {
    background-color: rgba(11, 15, 23, 0.82) !important;
    border-bottom-color: rgba(255, 255, 255, 0.06) !important;
}

/* ── Sidebar active item: accent rail ────────────────────────────────────── */
.fi-sidebar-item-button.fi-active {
    position: relative;
}
.fi-sidebar-item-button.fi-active::before {
    content: "";
    position: absolute;
    inset-inline-start: -0.5rem;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 60%;
    border-radius: 999px;
    background: linear-gradient(180deg, rgb(var(--chabok-orange-light)), rgb(var(--chabok-orange)));
    box-shadow: 0 0 8px rgb(var(--chabok-orange) / 0.45);
}

/* ── Table header: subtle uppercase labels ───────────────────────────────── */
.fi-ta-header-cell-label {
    font-size: 0.7rem !important;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 700 !important;
    color: rgb(var(--chabok-slate-500)) !important;
}

/* ── Widgets: hover lift ─────────────────────────────────────────────────── */
.fi-wi-stats-overview-stat {
    transition: transform 200ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 200ms ease;
}
.fi-wi-stats-overview-stat:hover {
    transform: translateY(-2px);
    box-shadow: var(--chabok-shadow-lg) !important;
}

/* ── Keyboard focus: visible ring everywhere ─────────────────────────────── */
.fi-body :is(a, button, [role="button"]):focus-visible {
    outline: 2px solid rgb(var(--chabok-orange)) !important;
    outline-offset: 2px;
    border-radius: 8px;
}

/* ── Modals: deeper radius + shadow ──────────────────────────────────────── */
.fi-modal-window {
    border-radius: 20px !important;
    box-shadow: 0 24px 64px -16px rgba(15, 23, 42, 0.25) !important;
}

/* ── Badges: pill consistency ────────────────────────────────────────────── */
.fi-badge {
    border-radius: 999px !important;
    font-weight: 600 !important;
}

/* ── Reduced motion ──────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .fi-body *,
    .fi-body *::before,
    .fi-body *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}
