/* Inventory Management System - Bright Light Theme */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #14b8a6;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #06b6d4;
    --dark-bg: #f4f8ff;
    --dark-card: #ffffff;
    --dark-border: #dbe5f3;
    --light-text: #0f172a;
    --gray-text: #64748b;
    --sidebar-width: 260px;
    --header-height: 60px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    background: radial-gradient(circle at top left, #eff6ff 0%, #f8fbff 45%, #eefdf7 100%);
}

body {
    background: radial-gradient(circle at top left, #eff6ff 0%, #f8fbff 45%, #eefdf7 100%);
    color: var(--light-text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    scroll-behavior: smooth;
}

/* App Container */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    border-right: 1px solid var(--dark-border);
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    overflow-y: auto;
    z-index: 1000;
    padding-top: 20px;
    box-shadow: 0 18px 45px rgba(37, 99, 235, 0.08);
}

.sidebar-header {
    padding: 0 20px 30px;
    border-bottom: 1px solid var(--dark-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sidebar-header h5 {
    font-size: 22px;
    font-weight: 700;
    color: var(--primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-close-sidebar {
    background: none;
    border: none;
    color: var(--light-text);
    font-size: 20px;
    cursor: pointer;
    display: none;
}

.sidebar-nav {
    list-style: none;
    padding: 20px 0;
}

.sidebar-nav li {
    margin: 0;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--gray-text);
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 15px;
    border-radius: 0 999px 999px 0;
    margin-right: 12px;
}

.sidebar-nav a:hover {
    background: rgba(37, 99, 235, 0.08);
    color: var(--primary);
    padding-left: 24px;
}

.sidebar-nav a.active {
    background: linear-gradient(90deg, rgba(37, 99, 235, 0.16), rgba(20, 184, 166, 0.12));
    color: var(--primary);
    border-right: 3px solid var(--primary);
}

.sidebar-nav i {
    font-size: 18px;
    width: 24px;
    text-align: center;
}

.sidebar-nav span {
    white-space: nowrap;
}

.sidebar-nav .divider {
    margin: 15px 0;
    border-top: 1px solid var(--dark-border);
}

/* BMS-style collapsible sidebar group (Reports, etc.) */
.sidebar-nav-group {
    margin: 0;
}

.sidebar-nav-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    width: calc(100% - 12px);
    padding: 12px 20px;
    color: var(--gray-text);
    background: none;
    border: none;
    text-align: left;
    font-size: 15px;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 0 999px 999px 0;
    margin-right: 12px;
}

.sidebar-nav-toggle:hover,
.sidebar-nav-toggle.active {
    background: rgba(37, 99, 235, 0.08);
    color: var(--primary);
}

.sidebar-nav-toggle.active {
    background: linear-gradient(90deg, rgba(37, 99, 235, 0.16), rgba(20, 184, 166, 0.12));
    border-right: 3px solid var(--primary);
}

.sidebar-nav-chevron {
    margin-left: auto;
    font-size: 11px;
    opacity: 0.7;
    transition: transform 0.25s ease;
}

.sidebar-nav-group.is-open .sidebar-nav-chevron {
    transform: rotate(180deg);
}

.sidebar-nav-sub {
    list-style: none;
    margin: 4px 12px 8px 36px;
    padding: 4px 0 4px 14px;
    border-left: 2px solid var(--dark-border);
    display: none;
}

.sidebar-nav-group.is-open .sidebar-nav-sub {
    display: block;
}

.sidebar-nav-sub li {
    margin: 0;
}

.sidebar-nav-sub a {
    display: block;
    padding: 9px 12px;
    color: var(--gray-text);
    text-decoration: none;
    font-size: 14px;
    border-radius: 8px;
    transition: all 0.2s ease;
    margin-right: 0;
}

.sidebar-nav-sub a:hover {
    color: var(--primary);
    background: rgba(37, 99, 235, 0.06);
    padding-left: 14px;
}

.sidebar-nav-sub a.active {
    color: var(--primary);
    font-weight: 600;
    background: rgba(37, 99, 235, 0.1);
    border-right: none;
}

.btn-install {
    margin: 20px;
    width: calc(100% - 40px);
    padding: 10px;
    background: linear-gradient(135deg, var(--primary), var(--info));
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-install:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(37, 99, 235, 0.22);
}

/* Top Header */
.top-header {
    position: fixed;
    top: 0;
    left: var(--sidebar-width);
    right: 0;
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.82);
    border-bottom: 1px solid var(--dark-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
    z-index: 999;
    backdrop-filter: blur(14px);
}

.btn-menu {
    background: none;
    border: none;
    color: var(--light-text);
    font-size: 20px;
    cursor: pointer;
    display: none;
}

.header-title h4 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: var(--light-text);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.header-notifications {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    color: var(--gray-text);
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.header-notifications i {
    font-size: 18px;
}

.header-notifications:hover {
    color: var(--primary);
    background: rgba(37, 99, 235, 0.08);
    border-color: rgba(37, 99, 235, 0.12);
}

.header-notifications.active {
    color: var(--primary);
    background: rgba(37, 99, 235, 0.12);
    border-color: rgba(37, 99, 235, 0.2);
}

.header-notifications-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--danger);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    box-shadow: 0 0 0 2px #fff;
}

.user-menu {
    position: relative;
}

.user-menu a {
    color: var(--light-text);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.user-menu a:hover {
    color: var(--primary);
}

.user-menu .dropdown-menu {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 8px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.user-menu .dropdown-item {
    color: var(--light-text);
    padding: 10px 15px;
}

.user-menu .dropdown-item:hover {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary);
}

.notification-row-unread {
    background: rgba(37, 99, 235, 0.06);
}

.notification-row-unread td:first-child {
    box-shadow: inset 3px 0 0 var(--primary);
}

/* Main Content */
.main-content {
    margin-left: var(--sidebar-width);
    margin-top: var(--header-height);
    padding: 30px;
    width: calc(100% - var(--sidebar-width));
    min-height: calc(100vh - var(--header-height));
}

.main-content > .container-fluid,
.main-content > .container,
.main-content > .row {
    position: relative;
    z-index: 1;
}

/* Dashboard Cards - Modern Horizontal Layout */
.metric-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 18px 20px;
    padding-bottom: 45px;
    min-height: 150px;
    position: relative;

    cursor: pointer;
    transition: all 0.28s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);

    height: 100%;
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
}

.metric-card:hover {
    transform: translateY(-2px);
    border-color: #82b3ef;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.12);
}

.metric-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.metric-card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    flex-shrink: 0;
    font-size: 20px;
    background: rgba(59, 130, 246, 0.1);
    color: #2563eb;
}

.metric-card.metric-card-indigo {
    border-left: 4px solid #2563eb;
}

.metric-card.metric-card-indigo .metric-card-icon {
    background: linear-gradient(135deg, #dbeafe, #eff6ff);
    color: #2563eb;
}

.metric-card.metric-card-teal {
    border-left: 4px solid #0d9488;
}

.metric-card.metric-card-teal .metric-card-icon {
    background: linear-gradient(135deg, #ccfbf1, #f0fdfa);
    color: #0d9488;
}

.metric-card.metric-card-amber {
    border-left: 4px solid #d97706;
}

.metric-card.metric-card-amber .metric-card-icon {
    background: linear-gradient(135deg, #fef3c7, #fffbeb);
    color: #d97706;
}

.metric-card.metric-card-blue {
    border-left: 4px solid #0284c7;
}

.metric-card.metric-card-blue .metric-card-icon {
    background: linear-gradient(135deg, #cffafe, #f0f9ff);
    color: #0284c7;
}

.metric-card.metric-card-rose {
    border-left: 4px solid #e11d48;
}

.metric-card.metric-card-rose .metric-card-icon {
    background: linear-gradient(135deg, #ffe4e6, #fff1f2);
    color: #e11d48;
}

.metric-card-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 120px;
}

.metric-card-label {
    font-size: 14px;
    font-weight: 600;
    color: #64748b;
    white-space: nowrap;
    line-height: 1.2;
}

.metric-card-value {
    font-size: 24px;
    font-weight: 700;
    color: #0f172a;
    line-height: 1;
}

.metric-card-subtext {
    position: absolute;
    bottom: 14px;
    left: 20px;
    right: 20px;

    font-size: 12px;
    color: #78909c;

    border-top: 1px solid #e2e8f0;
    padding-top: 8px;

    text-align: left;
    line-height: 1.2;
}

@media (max-width: 991px) {
    .metric-card-subtext {
        display: none;
    }
}

@media (max-width: 575px) {
    .metric-card {
        padding: 16px 18px;
        gap: 12px;
    }

    .metric-card-icon {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }

    .metric-card-label {
        font-size: 10px;
    }

    .metric-card-value {
        font-size: 24px;
    }
}

.settings-tile {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1), rgba(96, 165, 250, 0.06));
    border: 1px solid var(--dark-border);
    border-radius: 10px;
    padding: 14px 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
    text-align: center;
    min-height: 96px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.settings-tile:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.12);
}

.settings-tile-danger {
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.12), rgba(248, 113, 113, 0.08));
    border-color: rgba(220, 53, 69, 0.35);
}

.settings-tile-danger:hover {
    border-color: #dc3545;
    box-shadow: 0 8px 20px rgba(220, 53, 69, 0.16);
}

.settings-tile-danger .settings-tile-icon,
.settings-tile-danger .settings-tile-count {
    color: #dc3545;
}

.settings-tile-icon {
    font-size: 20px;
    color: #2563eb;
    line-height: 1;
}

.settings-tile-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--light-text);
    line-height: 1.2;
}

.settings-tile-count {
    font-size: 18px;
    font-weight: 700;
    color: #2563eb;
    line-height: 1;
}

/* Reports hub (BMS-style tile index) */
.reports-hub-section {
    margin-top: 8px;
}

.reports-hub-heading {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    font-weight: 700;
    color: var(--light-text);
    margin-bottom: 14px;
}

.reports-hub-heading i {
    color: var(--primary);
}

.reports-tile {
    border: 1px solid var(--dark-border);
    border-radius: 10px;
    padding: 16px 12px;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
    text-align: center;
    min-height: 148px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    height: 100%;
}

.reports-tile:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.12);
}

.reports-tile-icon {
    font-size: 22px;
    line-height: 1;
    margin-bottom: 2px;
}

.reports-tile-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--light-text);
    line-height: 1.25;
}

.reports-tile-desc {
    font-size: 11px;
    color: var(--gray-text);
    line-height: 1.3;
    min-height: 28px;
}

.reports-tile-count {
    font-size: 22px;
    font-weight: 700;
    line-height: 1;
    margin-top: 4px;
}

.reports-tile-meta {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--gray-text);
}

.reports-tile-indigo {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(99, 102, 241, 0.04));
}
.reports-tile-indigo .reports-tile-icon,
.reports-tile-indigo .reports-tile-count { color: #4f46e5; }

.reports-tile-primary {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(96, 165, 250, 0.06));
}
.reports-tile-primary .reports-tile-icon,
.reports-tile-primary .reports-tile-count { color: #2563eb; }

.reports-tile-success {
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.14), rgba(20, 184, 166, 0.05));
}
.reports-tile-success .reports-tile-icon,
.reports-tile-success .reports-tile-count { color: #0d9488; }

.reports-tile-teal {
    background: linear-gradient(135deg, rgba(13, 148, 136, 0.12), rgba(45, 212, 191, 0.05));
}
.reports-tile-teal .reports-tile-icon,
.reports-tile-teal .reports-tile-count { color: #0f766e; }

.reports-tile-blue {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.12), rgba(59, 130, 246, 0.04));
}
.reports-tile-blue .reports-tile-icon,
.reports-tile-blue .reports-tile-count { color: #2563eb; }

.reports-tile-warning {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.16), rgba(245, 158, 11, 0.05));
}
.reports-tile-warning .reports-tile-icon,
.reports-tile-warning .reports-tile-count { color: #d97706; }

.reports-tile-info {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.14), rgba(6, 182, 212, 0.05));
}
.reports-tile-info .reports-tile-icon,
.reports-tile-info .reports-tile-count { color: #0891b2; }

.dashboard-panel {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 250, 255, 0.96));
    border: 1px solid var(--dark-border);
    border-radius: 22px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.06);
    display: flex;
    flex-direction: column;
}

.dashboard-panel-accent {
    background: linear-gradient(180deg, rgba(238, 242, 255, 0.95), rgba(220, 234, 255, 0.9));
}

.dashboard-panel-title {
    color: #102a43;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 1.2rem;
    font-weight: 600;
}

.dashboard-panel-header {
    margin-bottom: 24px;
}

.dashboard-panel-copy {
    margin: 0;
    font-size: 14px;
    color: rgba(15, 23, 42, 0.75);
}

.chart-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 220px;
    padding: 8px;
    background: rgba(221, 238, 250, 0.85);
    border-radius: 18px;
}

/*.chart-wrapper canvas {
    width: 300px !important;
    height: 300px !important;
    max-width: 300px !important;
    max-height: 300px !important;
}*/

.chart-error {
    text-align: center;
    padding: 28px 16px;
    background: rgba(243, 244, 246, 0.95);
    border-radius: 16px;
    color: rgba(15, 23, 42, 0.8);
    font-size: 15px;
    line-height: 1.6;
    max-width: 420px;
}

.metric-card .metric-card-value {
    color: #071a52;
}

.metric-card .metric-card-subtext {
    color: rgba(15, 23, 42, 0.6);
}

.metric-card-label {
    color: rgba(15, 23, 42, 0.7);
}

@media (max-width: 991px) {
    .dashboard-panel {
        min-height: auto;
    }

    .chart-wrapper {
        min-height: 320px;
    }
}

.surface-indigo {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.14), rgba(96, 165, 250, 0.08));
}

.surface-teal {
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.14), rgba(45, 212, 191, 0.08));
}

.surface-amber {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.16), rgba(251, 191, 36, 0.08));
}

.surface-rose {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.14), rgba(244, 114, 182, 0.08));
}

.surface-sky {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.14), rgba(125, 211, 252, 0.08));
}

.surface-violet {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.14), rgba(196, 181, 253, 0.08));
}

.surface-lime {
    background: linear-gradient(135deg, rgba(132, 204, 22, 0.14), rgba(190, 242, 100, 0.08));
}

.surface-soft {
    border: 1px solid var(--dark-border);
    border-radius: 12px;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.05);
}

.surface-panel {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 250, 255, 0.94));
    border: 1px solid var(--dark-border);
    border-radius: 12px;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.05);
}

/* Modal accent variants */
.modal-accent-indigo .modal-content,
.modal-accent .modal-content {
    background: linear-gradient(180deg, #ffffff, #eff6ff);
    border: 1px solid rgba(37, 99, 235, 0.08);
}

.modal-accent-teal .modal-content {
    background: linear-gradient(180deg, #ffffff, #ecfeff);
    border: 1px solid rgba(20, 184, 166, 0.08);
}

.modal-accent-amber .modal-content {
    background: linear-gradient(180deg, #ffffff, #fffbeb);
    border: 1px solid rgba(245, 158, 11, 0.08);
}

.modal-accent-rose .modal-content {
    background: linear-gradient(180deg, #ffffff, #fff1f2);
    border: 1px solid rgba(239, 68, 68, 0.08);
}

/* Table surface variants */
.table-surface {
    background: linear-gradient(180deg, #ffffff, #fbfdff);
    border: 1px solid var(--dark-border);
    border-radius: 10px;
    overflow: hidden;
}

.table-surface thead {
    background: linear-gradient(90deg, rgba(37,99,235,0.06), rgba(6,182,212,0.04));
}

.table-surface tbody td {
    color: var(--light-text);
}

/* Badges */
.badge {
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.badge-primary {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.badge-success {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
}

.badge-warning {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
}

.badge-danger {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

/* Tables */
.table {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.05);
}

.table thead {
    background: linear-gradient(90deg, rgba(37, 99, 235, 0.1), rgba(20, 184, 166, 0.08));
    border-bottom: 1px solid var(--dark-border);
}

.table thead th {
    color: var(--light-text);
    font-weight: 600;
    padding: 15px;
    border: none;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
}

.table tbody td {
    padding: 12px 15px;
    border: none;
    border-bottom: 1px solid rgba(51, 65, 85, 0.3);
    color: var(--light-text);
}

.table tbody tr:hover {
    background: rgba(37, 99, 235, 0.04);
}

/* Modals */
.modal-content {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 12px;
    box-shadow: 0 30px 80px rgba(15, 23, 42, 0.18);
}

.modal-header {
    border-bottom: 1px solid var(--dark-border);
    background: linear-gradient(90deg, rgba(37, 99, 235, 0.06), rgba(20, 184, 166, 0.06));
}

.modal-header .btn-close {
    filter: none;
}

.modal-title {
    color: var(--light-text);
    font-weight: 600;
}

/* Forms */
.form-label {
    color: var(--light-text);
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 14px;
}

.form-control,
.form-select {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    color: var(--light-text);
    border-radius: 8px;
    padding: 10px 12px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.03);
}

.form-control:focus,
.form-select:focus {
    background: #ffffff;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
    color: var(--light-text);
}

.form-control::placeholder {
    color: var(--gray-text);
}

/* Buttons */
.btn {
    border-radius: 8px;
    font-weight: 600;
    padding: 10px 16px;
    transition: all 0.3s ease;
    border: none;
    font-size: 14px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--info));
    color: white;
    box-shadow: 0 10px 24px rgba(37, 99, 235, 0.22);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(37, 99, 235, 0.28);
    color: white;
}

.btn-success {
    background: linear-gradient(135deg, #14b8a6, #10b981);
    color: white;
    box-shadow: 0 10px 24px rgba(20, 184, 166, 0.18);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(20, 184, 166, 0.26);
    color: white;
}

.btn-info {
    background: linear-gradient(135deg, #06b6d4, #2563eb);
    color: white;
    box-shadow: 0 10px 24px rgba(6, 182, 212, 0.18);
}

.btn-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(6, 182, 212, 0.24);
    color: white;
}

.btn-warning {
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: white;
    box-shadow: 0 10px 24px rgba(245, 158, 11, 0.18);
}

.btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(245, 158, 11, 0.24);
    color: white;
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444, #f43f5e);
    color: white;
    box-shadow: 0 10px 24px rgba(239, 68, 68, 0.18);
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(239, 68, 68, 0.24);
    color: white;
}

.btn-purple {
    background: linear-gradient(135deg, #7c3aed, #a855f7);
    color: white;
    box-shadow: 0 10px 24px rgba(124, 58, 237, 0.18);
}

.btn-purple:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(124, 58, 237, 0.24);
    color: white;
}

.btn-close-action {
    padding: 0.55rem 1rem;
    font-size: 0.95rem;
}

.btn-outline-primary {
    border: 1px solid var(--primary);
    color: var(--primary);
}

.btn-outline-primary:hover {
    background: rgba(37, 99, 235, 0.08);
}

.btn-outline-success {
    border: 1px solid #10b981;
    color: #059669;
}

.btn-outline-success:hover {
    background: rgba(16, 185, 129, 0.08);
    color: #047857;
}

.btn-outline-info {
    border: 1px solid #06b6d4;
    color: #0891b2;
}

.btn-outline-info:hover {
    background: rgba(6, 182, 212, 0.08);
    color: #0e7490;
}

.btn-outline-warning {
    border: 1px solid #f59e0b;
    color: #d97706;
}

.btn-outline-warning:hover {
    background: rgba(245, 158, 11, 0.08);
    color: #b45309;
}

.btn-outline-danger {
    border: 1px solid #ef4444;
    color: #dc2626;
}

.btn-outline-danger:hover {
    background: rgba(239, 68, 68, 0.08);
    color: #b91c1c;
}

/* Alerts */
.alert {
    border-radius: 8px;
    border: none;
    padding: 12px 16px;
    margin-bottom: 20px;
}

.alert-info {
    background: rgba(6, 182, 212, 0.08);
    color: #0e7490;
    border: 1px solid rgba(6, 182, 212, 0.2);
}

.alert-success {
    background: rgba(20, 184, 166, 0.08);
    color: #0f766e;
    border: 1px solid rgba(20, 184, 166, 0.2);
}

.alert-warning {
    background: rgba(245, 158, 11, 0.08);
    color: #92400e;
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.alert-danger {
    background: rgba(239, 68, 68, 0.08);
    color: #b91c1c;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Responsive */
@media (max-width: 992px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .top-header {
        left: 0;
    }

    .main-content {
        margin-left: 0;
        width: 100%;
        padding: 20px;
    }

    .btn-menu {
        display: block;
    }

    .btn-close-sidebar {
        display: block;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
    }

    .top-header {
        padding: 0 15px;
    }

    .header-title h4 {
        font-size: 18px;
    }

    .main-content {
        padding: 15px;
    }

    .metric-card {
        padding: 15px;
    }

    .metric-card-value {
        font-size: 24px;
    }
}

@media (max-width: 480px) {
    :root {
        --header-height: 56px;
    }

    .metric-card-icon {
        font-size: 24px;
    }

    .metric-card-value {
        font-size: 20px;
    }

    .table {
        font-size: 12px;
    }

    .table thead th,
    .table tbody td {
        padding: 8px 10px;
    }
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.3s ease-out;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(circle at top right, rgba(59, 130, 246, 0.10), transparent 28%),
        radial-gradient(circle at 12% 20%, rgba(20, 184, 166, 0.08), transparent 22%),
        radial-gradient(circle at bottom left, rgba(245, 158, 11, 0.08), transparent 22%);
    z-index: 0;
}

/* Page headers (dashboard + reports) */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 28px;
    flex-wrap: wrap;
}

.page-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 4px;
    color: var(--light-text);
}

.page-subtitle {
    color: var(--gray-text);
    margin: 0;
    font-size: 15px;
}

/* Dashboard chart cards */
.dashboard-chart-card {
    padding: 24px;
    min-height: 420px;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.dashboard-chart-card .chart-wrapper {
    flex: 1 1 auto;
    min-height: 300px;
}

.dashboard-system-info,
.dashboard-quick-actions,
.reports-panel {
    padding: 24px;
}

.dashboard-info-list,
.reports-highlights {
    list-style: none;
    padding: 0;
    margin: 16px 0 0;
}

.dashboard-info-list li,
.reports-highlights li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 12px 0;
    border-bottom: 1px solid var(--dark-border);
}

.dashboard-info-list li:last-child,
.reports-highlights li:last-child {
    border-bottom: none;
}

.dashboard-quick-actions .row {
    margin-top: 16px;
}

/* Reports page */
.reports-link-grid {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.reports-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.reports-link:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
    text-decoration: none;
}

.reports-link-primary {
    background: rgba(37, 99, 235, 0.1);
    color: #1d4ed8;
}

.reports-link-success {
    background: rgba(20, 184, 166, 0.12);
    color: #0f766e;
}

.reports-link-warning {
    background: rgba(245, 158, 11, 0.14);
    color: #b45309;
}

.reports-link-info {
    background: rgba(6, 182, 212, 0.12);
    color: #0e7490;
}

/* Reports date filter bar */
.reports-filter-bar {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px 24px;
    margin-bottom: 24px;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06);
}

.reports-filter-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.reports-filter-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 15px;
    color: var(--light-text);
}

.reports-filter-title i {
    color: var(--primary);
}

.reports-filter-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    color: #047857;
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    border-radius: 999px;
    padding: 4px 12px;
}

.reports-filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    align-items: end;
}

.reports-filter-field .form-label {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--gray-text);
    margin-bottom: 6px;
}

.reports-filter-field .form-control {
    min-height: 42px;
}

.reports-filter-search {
    min-width: 220px;
}

.reports-filter-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
    padding-bottom: 2px;
}

.reports-filter-actions .btn {
    min-height: 42px;
    padding-left: 16px;
    padding-right: 16px;
}

.reports-filter-presets {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px dashed #e2e8f0;
}

.reports-filter-presets-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--gray-text);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-right: 4px;
}

.reports-filter-presets .btn {
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
}

.reports-filter-active {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    padding: 10px 14px;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    font-size: 13px;
    color: #1e40af;
}

.reports-filter-active i {
    opacity: 0.85;
}

.reports-summary-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.reports-summary-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    font-size: 13px;
    color: var(--gray-text);
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.04);
}

.reports-summary-chip strong {
    color: var(--light-text);
    font-weight: 700;
}

/* Empty state — before filters applied */
.reports-empty-state {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 250, 255, 0.96));
    border: 1px dashed var(--dark-border);
    border-radius: 16px;
    padding: 56px 32px;
    text-align: center;
    margin-top: 8px;
}

.reports-empty-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 20px;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: var(--primary);
}

.reports-empty-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--light-text);
    margin-bottom: 10px;
}

.reports-empty-text {
    max-width: 480px;
    margin: 0 auto;
    color: var(--gray-text);
    font-size: 15px;
    line-height: 1.6;
}

@media (max-width: 576px) {
    .reports-filter-actions {
        width: 100%;
    }
    .reports-filter-actions .btn {
        flex: 1;
    }
}

.print-only {
    display: none;
}

.indent-list-print {
    display: none;
}

@media print {
    @page {
        size: A4 portrait;
        margin: 10mm 12mm;
    }

    html,
    body {
        background: #fff !important;
        width: 100% !important;
        font-size: 11px;
        line-height: 1.35;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .app-container {
        display: block !important;
        min-height: auto !important;
    }

    .sidebar,
    .top-header,
    .no-print,
    .export-toolbar,
    .btn-menu,
    .alert-messages-container {
        display: none !important;
    }

    .sidebar {
        width: 0 !important;
        overflow: hidden !important;
    }

    .main-content {
        margin: 0 !important;
        padding: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        min-height: auto !important;
    }

    .print-page,
    .container-fluid,
    .container,
    .reports-page,
    .indent-detail-page {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .print-only {
        display: block !important;
    }

    .print-page-header {
        text-align: center;
        border-bottom: 1px solid #333;
        margin: 0 0 10px;
        padding-bottom: 6px;
    }

    .print-page-header h2 {
        font-size: 16px;
        font-weight: 700;
        margin: 0 0 2px;
    }

    .print-page-header p {
        font-size: 10px;
        margin: 0;
        color: #444;
    }

    .page-header {
        margin-bottom: 8px !important;
        flex-wrap: wrap;
    }

    .page-title {
        font-size: 16px !important;
    }

    .page-subtitle {
        font-size: 10px !important;
    }

    .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .print-cols-2 {
        display: flex !important;
        flex-wrap: nowrap !important;
        gap: 10px;
    }

    .print-cols-2 > [class*="col-"] {
        flex: 1 1 50% !important;
        max-width: 50% !important;
        width: 50% !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .card,
    .dashboard-panel,
    .reports-panel,
    .surface-panel,
    .surface-soft {
        box-shadow: none !important;
        border: 1px solid #ccc !important;
        page-break-inside: avoid;
        margin-bottom: 8px !important;
    }

    .card-header,
    .dashboard-panel-header {
        padding: 4px 8px !important;
        background: #eee !important;
    }

    .card-body {
        padding: 6px 8px !important;
    }

    .table-responsive {
        overflow: visible !important;
    }

    table {
        width: 100% !important;
        font-size: 10px;
        border-collapse: collapse !important;
    }

    th,
    td {
        padding: 4px 6px !important;
        border: 1px solid #ccc !important;
        vertical-align: top !important;
    }

    .badge {
        background: transparent !important;
        color: #000 !important;
        border: none !important;
        padding: 0 !important;
        font-weight: 600;
    }

    .screen-only-col {
        display: none !important;
    }

    .actions-col {
        display: none !important;
    }

    .page-header,
    .indent-print-header-row,
    .indent-status-badges,
    .indent-requested-date {
        display: none !important;
    }

    .indent-detail-page .card-header .badge {
        display: none !important;
    }

    .indent-list-screen,
    .indent-filters,
    .modal {
        display: none !important;
    }

    .indent-list-print {
        display: block !important;
    }

    .requisition-screen-header {
        display: none !important;
    }

    .settings-panel-table tr > th:last-child,
    .settings-panel-table tr > td:last-child {
        display: none !important;
    }

    a[href]:after {
        content: none !important;
    }

    .metric-card {
        min-height: auto !important;
        padding: 8px !important;
        page-break-inside: avoid;
    }

    table.d-none,
    #reportsExportTable.d-none {
        display: table !important;
        width: 100% !important;
    }

    #reportsExportTable.d-none tr {
        display: table-row !important;
    }

    #reportsExportTable.d-none th,
    #reportsExportTable.d-none td {
        display: table-cell !important;
    }
}
