/* ================================================
   VBassein CRM — Custom Light Theme "Soft Light"
   Inspired by Bitrix24 & Salebot warmth
   ================================================ */

/* === LIGHT THEME OVERRIDES === */
:root {
    /* Backgrounds — warm grays instead of pure white */
    --fi-body-bg: #f5f6f8;

    /* Softer text — not pure black */
    --custom-text: #1e293b;
    --custom-text-muted: #64748b;
}

/* Body background */
.fi-layout {
    background: #f5f6f8 !important;
}

/* Main content area — slightly warmer */
.fi-main {
    background: #f5f6f8 !important;
}

/* Sidebar — subtle differentiation */
.fi-sidebar {
    background: #ffffff !important;
    border-right: 1px solid #e8eaed !important;
}

/* Top bar */
.fi-topbar {
    background: #ffffff !important;
    border-bottom: 1px solid #e8eaed !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.03) !important;
}

/* Cards & sections — soft shadow */
.fi-section,
.fi-ta-ctn,
.fi-wi {
    border-radius: 12px !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05), 0 1px 2px rgba(0,0,0,0.03) !important;
}

/* Stats widgets — warmer background */
.fi-wi-stats-overview-stat {
    border-radius: 12px !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06) !important;
    transition: box-shadow 0.2s, transform 0.2s !important;
}

.fi-wi-stats-overview-stat:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08) !important;
    transform: translateY(-1px) !important;
}

/* Table rows — subtle hover */
.fi-ta-row:hover {
    background: rgba(14,165,233,0.03) !important;
}

/* Buttons — softer corners */
.fi-btn {
    border-radius: 8px !important;
    font-weight: 500 !important;
    transition: all 0.15s !important;
}

/* Input fields — warmer border */
.fi-input-wrp {
    border-radius: 8px !important;
}

/* Navigation items — smoother hover */
.fi-sidebar-item-btn {
    border-radius: 8px !important;
    transition: all 0.15s !important;
}

.fi-sidebar-item-btn:hover {
    background: rgba(14,165,233,0.06) !important;
}

/* Active nav item */
.fi-sidebar-item-active .fi-sidebar-item-btn {
    background: rgba(14,165,233,0.1) !important;
}

/* Page headers */
.fi-page-header-heading {
    font-weight: 700 !important;
    letter-spacing: -0.01em !important;
}

/* Badge improvements */
.fi-badge {
    border-radius: 6px !important;
    font-weight: 500 !important;
}

/* Tabs — cleaner */
.fi-tabs-tab {
    border-radius: 8px 8px 0 0 !important;
    font-weight: 500 !important;
}

/* === DARK THEME — Soft Dark (layered, not flat black) === */
.dark .fi-layout,
.dark .fi-main {
    background: #111827 !important;
}

.dark .fi-sidebar {
    background: #1a2332 !important;
    border-right: 1px solid rgba(255,255,255,0.06) !important;
}

.dark .fi-topbar {
    background: #1a2332 !important;
    border-bottom: 1px solid rgba(255,255,255,0.06) !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.15) !important;
}

/* Cards & sections — slightly elevated from background */
.dark .fi-section,
.dark .fi-ta-ctn,
.dark .fi-wi {
    background: #1e293b !important;
    border: 1px solid rgba(255,255,255,0.04) !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2) !important;
}

/* Stats widgets */
.dark .fi-wi-stats-overview-stat {
    background: #1e293b !important;
    border: 1px solid rgba(255,255,255,0.04) !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2) !important;
}

.dark .fi-wi-stats-overview-stat:hover {
    background: #243346 !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3) !important;
}

/* Table — subtle header differentiation */
.dark .fi-ta-header-cell {
    background: rgba(255,255,255,0.02) !important;
}

.dark .fi-ta-row:hover {
    background: rgba(14,165,233,0.06) !important;
}

/* Table container — softer */
.dark .fi-ta-ctn {
    background: #1a2332 !important;
}

/* Inputs in dark mode */
.dark .fi-input-wrp {
    background: #1e293b !important;
    border-color: rgba(255,255,255,0.08) !important;
}

/* Modals */
.dark .fi-modal-window {
    background: #1e293b !important;
    border: 1px solid rgba(255,255,255,0.06) !important;
}

/* Select dropdowns */
.dark .fi-select-option:hover {
    background: rgba(14,165,233,0.1) !important;
}

/* Native select/option in dark mode (broadcast, kanban bulk, settings) */
.dark select,
.dark .bc-select,
.dark .panel-select {
    background: #1e293b !important;
    color: #e2e8f0 !important;
    border-color: rgba(255,255,255,0.1) !important;
}
.dark select option,
.dark .bc-select option,
.dark .panel-select option {
    background: #1e293b !important;
    color: #e2e8f0 !important;
}

/* Tabs in dark */
.dark .fi-tabs-tab {
    border-color: rgba(255,255,255,0.06) !important;
}

/* === GLOBAL POLISH === */

/* Smooth scrollbars */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(128,128,128,0.2) transparent;
}

*::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

*::-webkit-scrollbar-thumb {
    background: rgba(128,128,128,0.25);
    border-radius: 3px;
}

*::-webkit-scrollbar-thumb:hover {
    background: rgba(128,128,128,0.4);
}

/* Smooth transitions globally */
.fi-sidebar-item-btn,
.fi-btn,
.fi-ta-row,
.fi-wi-stats-overview-stat,
.fi-section {
    transition: all 0.15s ease !important;
}

/* Modal/dialog polish */
.fi-modal-window {
    border-radius: 16px !important;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.15) !important;
}

/* Notification toast polish */
.fi-no {
    border-radius: 12px !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1) !important;
}

/* Loading skeleton pulse */
@keyframes softPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

/* Brand name in sidebar */
.fi-sidebar-header {
    font-weight: 700 !important;
    letter-spacing: -0.02em !important;
}
