/* ============================================================
   TeamBees Billing Engine - Premium Design System v2.0
   ============================================================ */

/* --- Base Typography --- */
body { font-family: 'Inter', sans-serif; }
h1, h2, h3, .headline, .font-headline { font-family: 'Plus Jakarta Sans', sans-serif; }

/* --- Glassmorphism --- */
.glass {
    background: rgba(23, 31, 51, 0.55);
    backdrop-filter: blur(20px) saturate(1.3);
    -webkit-backdrop-filter: blur(20px) saturate(1.3);
}

/* --- Custom Scrollbar --- */
.styled-scrollbar::-webkit-scrollbar { width: 5px; height: 5px; }
.styled-scrollbar::-webkit-scrollbar-track { background: transparent; }
.styled-scrollbar::-webkit-scrollbar-thumb { background: rgba(195, 192, 255, 0.12); border-radius: 999px; }
.styled-scrollbar::-webkit-scrollbar-thumb:hover { background: rgba(195, 192, 255, 0.25); }
.styled-scrollbar { scrollbar-width: thin; scrollbar-color: rgba(195, 192, 255, 0.12) transparent; }

.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* --- Sidebar --- */
.sidebar-link {
    color: #8b89a8;
    text-decoration: none;
    font-size: 0.875rem;
    letter-spacing: 0.01em;
    position: relative;
    border-left: 3px solid transparent;
}
.sidebar-link:hover {
    background: rgba(195, 192, 255, 0.04);
    color: #c7c4d8;
    text-decoration: none;
}
.sidebar-link.active {
    color: #c3c0ff;
    background: rgba(79, 70, 229, 0.08);
    border-left-color: #c3c0ff;
}
.sidebar-link.active .material-symbols-outlined {
    font-variation-settings: 'FILL' 1;
}

/* Sidebar section label */
.sidebar-section-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    color: #555370;
    padding: 1.25rem 1.75rem 0.5rem;
}

/* --- Toast Notifications --- */
.toast-notification {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    border-radius: 14px;
    min-width: 320px;
    max-width: 480px;
    font-size: 0.875rem;
    animation: toast-in 0.35s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(70, 69, 85, 0.25);
    box-shadow: 0 8px 32px rgba(0,0,0,0.3), 0 0 0 1px rgba(255,255,255,0.03);
}
.toast-success {
    background: rgba(16, 185, 129, 0.1);
    color: #6ee7b7;
    border-color: rgba(16, 185, 129, 0.15);
}
.toast-danger, .toast-error {
    background: rgba(239, 68, 68, 0.1);
    color: #fca5a5;
    border-color: rgba(239, 68, 68, 0.15);
}
.toast-warning {
    background: rgba(245, 158, 11, 0.1);
    color: #fcd34d;
    border-color: rgba(245, 158, 11, 0.15);
}
.toast-info {
    background: rgba(99, 102, 241, 0.1);
    color: #c3c0ff;
    border-color: rgba(99, 102, 241, 0.15);
}
.toast-icon { font-size: 1.2rem; flex-shrink: 0; }
.toast-body { flex: 1; }
.toast-close {
    background: none;
    border: none;
    color: inherit;
    opacity: 0.5;
    cursor: pointer;
    padding: 2px;
    font-size: 0.75rem;
    transition: opacity 0.15s;
}
.toast-close:hover { opacity: 1; }
.toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    background: currentColor;
    opacity: 0.25;
    animation: toast-progress 4s linear forwards;
}

@keyframes toast-in {
    from { opacity: 0; transform: translateX(60px) scale(0.95); }
    to { opacity: 1; transform: translateX(0) scale(1); }
}
@keyframes toast-out {
    from { opacity: 1; transform: translateX(0) scale(1); }
    to { opacity: 0; transform: translateX(60px) scale(0.95); }
}
@keyframes toast-progress {
    from { width: 100%; }
    to { width: 0%; }
}
.toast-removing { animation: toast-out 0.3s ease-in forwards; }

/* --- Loading Spinner --- */
.loading-spinner {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 0;
}
.loading-spinner::after {
    content: '';
    width: 2rem;
    height: 2rem;
    border: 3px solid rgba(195, 192, 255, 0.15);
    border-top-color: #c3c0ff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* --- Premium Tables --- */
.stitch-table {
    width: 100%;
    text-align: left;
    border-collapse: separate;
    border-spacing: 0;
}
.stitch-table thead tr {
    background: rgba(10, 16, 32, 0.6);
}
.stitch-table th {
    padding: 0.875rem 1.25rem;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: #6b6a82;
    border-bottom: 1px solid rgba(70, 69, 85, 0.12);
}
.stitch-table td {
    padding: 1rem 1.25rem;
    font-size: 0.8125rem;
    color: #b8b6d0;
}
.stitch-table tbody tr {
    border-bottom: 1px solid rgba(70, 69, 85, 0.06);
    transition: background 0.2s ease, transform 0.15s ease;
}
.stitch-table tbody tr:hover {
    background: rgba(79, 70, 229, 0.04);
}
.stitch-table th.sortable { cursor: pointer; user-select: none; }
.stitch-table th.sortable:hover { color: #c3c0ff; }

/* --- Status Badges --- */
.badge-success {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 9999px;
    background: rgba(16, 185, 129, 0.08);
    color: #34d399;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.badge-processing {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 9999px;
    background: rgba(79, 70, 229, 0.12);
    color: #c3c0ff;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.badge-error {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 9999px;
    background: rgba(239, 68, 68, 0.08);
    color: #ffb4ab;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.badge-warning {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 9999px;
    background: rgba(245, 158, 11, 0.08);
    color: #fcd34d;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* --- Form Inputs --- */
input[type="text"],
input[type="email"],
input[type="number"],
input[type="tel"],
input[type="month"],
input[type="date"],
input[type="password"],
input[type="search"],
select,
textarea {
    background: rgba(34, 42, 61, 0.7) !important;
    border: 1px solid rgba(70, 69, 85, 0.25) !important;
    border-radius: 0.625rem;
    padding: 0.625rem 0.875rem;
    color: #dae2fd !important;
    font-size: 0.8125rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    width: 100%;
}
input[type="text"]:focus,
input[type="email"]:focus,
input[type="number"]:focus,
input[type="tel"]:focus,
input[type="month"]:focus,
input[type="date"]:focus,
input[type="password"]:focus,
input[type="search"]:focus,
select:focus,
textarea:focus {
    outline: none !important;
    border-color: rgba(195, 192, 255, 0.5) !important;
    box-shadow: 0 0 0 3px rgba(195, 192, 255, 0.08), 0 0 20px rgba(79, 70, 229, 0.1) !important;
    color: #dae2fd !important;
    background: rgba(34, 42, 61, 0.9) !important;
}

input::placeholder, textarea::placeholder {
    color: #5a5876 !important;
    opacity: 1;
}

/* Browser autofill override */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active,
select:-webkit-autofill,
textarea:-webkit-autofill {
    -webkit-text-fill-color: #dae2fd !important;
    -webkit-box-shadow: 0 0 0 1000px #222a3d inset !important;
    box-shadow: 0 0 0 1000px #222a3d inset !important;
    border-color: rgba(70, 69, 85, 0.25) !important;
    transition: background-color 5000s ease-in-out 0s;
}

input[type="date"]::-webkit-calendar-picker-indicator,
input[type="month"]::-webkit-calendar-picker-indicator {
    filter: invert(0.6);
    cursor: pointer;
}

select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b6a82' d='M6 8L1 3h10z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 0.75rem center !important;
    background-size: 12px !important;
    padding-right: 2.25rem !important;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

input[type="file"] {
    color: #8b89a8;
    font-size: 0.8125rem;
}
input[type="file"]::file-selector-button {
    background: rgba(45, 52, 73, 0.8);
    color: #c7c4d8;
    border: 1px solid rgba(70, 69, 85, 0.25);
    border-radius: 0.5rem;
    padding: 0.375rem 0.75rem;
    margin-right: 0.75rem;
    cursor: pointer;
    font-size: 0.8125rem;
    transition: background 0.15s ease;
}
input[type="file"]::file-selector-button:hover {
    background: rgba(61, 69, 96, 0.8);
}

/* --- Premium Buttons --- */
.btn-primary {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #a78bfa 100%);
    color: #ffffff;
    font-weight: 700;
    padding: 0.625rem 1.5rem;
    border-radius: 0.75rem;
    border: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.22, 1, 0.36, 1);
    font-size: 0.8125rem;
    box-shadow: 0 2px 12px rgba(79, 70, 229, 0.2), 0 0 0 1px rgba(255,255,255,0.05) inset;
    letter-spacing: 0.02em;
}
.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(79, 70, 229, 0.35), 0 0 0 1px rgba(255,255,255,0.08) inset;
    filter: brightness(1.08);
}
.btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 1px 6px rgba(79, 70, 229, 0.2);
}

.btn-secondary {
    background: rgba(34, 42, 61, 0.6);
    color: #b8b6d0;
    font-weight: 600;
    padding: 0.625rem 1.25rem;
    border-radius: 0.75rem;
    border: 1px solid rgba(70, 69, 85, 0.15);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.8125rem;
}
.btn-secondary:hover {
    background: rgba(45, 52, 73, 0.8);
    border-color: rgba(70, 69, 85, 0.3);
    color: #dae2fd;
}

.btn-danger {
    background: rgba(239, 68, 68, 0.1);
    color: #ffb4ab;
    font-weight: 600;
    padding: 0.625rem 1.25rem;
    border-radius: 0.75rem;
    border: 1px solid rgba(239, 68, 68, 0.12);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.8125rem;
}
.btn-danger:hover {
    background: rgba(239, 68, 68, 0.18);
    border-color: rgba(239, 68, 68, 0.25);
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
}

/* Button focus */
.btn-primary:focus-visible,
.btn-secondary:focus-visible,
.btn-danger:focus-visible {
    outline: 2px solid #c3c0ff;
    outline-offset: 2px;
}

/* --- Upload Zone --- */
.upload-zone {
    border: 2px dashed rgba(70, 69, 85, 0.2);
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.25s ease;
    background: rgba(19, 27, 46, 0.2);
}
.upload-zone:hover, .upload-zone.dragover {
    border-color: rgba(195, 192, 255, 0.35);
    background: rgba(79, 70, 229, 0.04);
    box-shadow: 0 0 30px rgba(79, 70, 229, 0.06);
}

/* --- Premium Cards --- */
.card {
    background: rgba(23, 31, 51, 0.6);
    border: 1px solid rgba(70, 69, 85, 0.06);
    border-radius: 1rem;
    overflow: hidden;
    backdrop-filter: blur(8px);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
    border-color: rgba(70, 69, 85, 0.12);
}
.card-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(70, 69, 85, 0.08);
    background: rgba(34, 42, 61, 0.3);
}

/* --- Stat Cards (Dashboard) --- */
.stat-card {
    background: rgba(23, 31, 51, 0.5);
    border: 1px solid rgba(70, 69, 85, 0.06);
    border-radius: 1rem;
    padding: 1.5rem;
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}
.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(195, 192, 255, 0.15), transparent);
}
.stat-card:hover {
    border-color: rgba(195, 192, 255, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(195, 192, 255, 0.05);
}
.stat-card .stat-glow {
    position: absolute;
    top: -30px;
    right: -30px;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    filter: blur(40px);
    opacity: 0.15;
    transition: opacity 0.3s ease;
}
.stat-card:hover .stat-glow {
    opacity: 0.25;
}

/* --- Quick Action Cards --- */
.action-card {
    background: rgba(23, 31, 51, 0.4);
    border: 1px solid rgba(70, 69, 85, 0.06);
    border-radius: 1rem;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    cursor: pointer;
    text-decoration: none;
}
.action-card:hover {
    background: rgba(79, 70, 229, 0.06);
    border-color: rgba(195, 192, 255, 0.12);
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}
.action-card .action-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.75rem;
    transition: transform 0.3s ease;
}
.action-card:hover .action-icon {
    transform: scale(1.1);
}

/* --- Sort Icons --- */
.sort-icon {
    font-size: 12px;
    opacity: 0.3;
    vertical-align: middle;
    margin-left: 4px;
}
.sort-icon.active { opacity: 1; }

/* --- Page Transitions --- */
.fade-in {
    animation: fadeIn 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Stagger children animation */
.stagger-in > * {
    opacity: 0;
    animation: staggerFadeIn 0.4s ease forwards;
}
.stagger-in > *:nth-child(1) { animation-delay: 0.05s; }
.stagger-in > *:nth-child(2) { animation-delay: 0.1s; }
.stagger-in > *:nth-child(3) { animation-delay: 0.15s; }
.stagger-in > *:nth-child(4) { animation-delay: 0.2s; }
.stagger-in > *:nth-child(5) { animation-delay: 0.25s; }
.stagger-in > *:nth-child(6) { animation-delay: 0.3s; }
@keyframes staggerFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Modal Scroll Lock --- */
body.modal-open { overflow: hidden; }

/* --- Tab Styles --- */
.tab-btn {
    color: #6b6a82;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    transition: all 0.2s ease;
}
.tab-btn:hover { color: #b8b6d0; }
.tab-btn.active {
    color: #c3c0ff;
    border-bottom-color: #c3c0ff;
    background: rgba(79, 70, 229, 0.04);
}

/* --- Inline Table Inputs --- */
.stitch-table td input[type="text"],
.stitch-table td input[type="number"],
.stitch-table td select {
    padding: 0.375rem 0.5rem;
    font-size: 0.8125rem;
}

/* --- Filter Selects --- */
select.w-auto {
    width: auto !important;
    min-width: 8rem;
}

/* --- Dropdown Menus --- */
.quote-dropdown,
.sow-dropdown {
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* --- Reminders Table --- */
.reminder-cell-stack {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.reminder-cell-title {
    color: #e6e4fb;
    font-weight: 600;
}

.reminder-amount {
    color: #e6e4fb;
    font-weight: 700;
    white-space: nowrap;
}

.reminder-status-card {
    min-width: 10rem;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    padding: 0.8rem 0.9rem;
    border-radius: 0.9rem;
    background: linear-gradient(180deg, rgba(34, 42, 61, 0.84), rgba(24, 31, 48, 0.84));
    border: 1px solid rgba(104, 104, 132, 0.16);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.reminder-status-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.reminder-meta-line {
    font-size: 0.72rem;
    color: #9e9bb7;
    line-height: 1.4;
}

.reminder-meta-label {
    display: block;
    margin-bottom: 0.15rem;
    color: #d5d3ec;
    font-size: 0.64rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.reminder-compact-select {
    min-width: 0;
}

.reminder-email-wrap {
    min-width: 0;
}

.reminder-email-pill {
    display: inline-flex;
    align-items: center;
    max-width: 14rem;
    padding: 0.8rem 1rem;
    border-radius: 1rem;
    background: rgba(34, 42, 61, 0.7);
    border: 1px solid rgba(104, 104, 132, 0.14);
    color: #d9d7ef;
    font-size: 0.84rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reminder-email-empty {
    color: #9794b4;
}

.reminder-action-row {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.reminder-action-trigger {
    width: 3rem;
    height: 3rem;
    justify-content: center;
    padding: 0;
    border-radius: 1rem;
}

.reminder-action-trigger .material-symbols-outlined {
    color: inherit;
}

.reminder-action-sheet-btn {
    width: 100%;
    display: grid;
    grid-template-columns: 1.4rem 1fr;
    gap: 0.9rem;
    align-items: start;
    padding: 1rem 1.05rem;
    border: 1px solid rgba(104, 104, 132, 0.14);
    border-radius: 1rem;
    background: rgba(27, 35, 54, 0.72);
    color: #dddaf3;
    text-align: left;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.reminder-action-sheet-btn:hover {
    background: rgba(36, 45, 67, 0.88);
    border-color: rgba(195, 192, 255, 0.16);
    transform: translateY(-1px);
}

.reminder-action-sheet-btn .material-symbols-outlined {
    font-size: 1.15rem;
    margin-top: 0.05rem;
    color: #c8c5e7;
}

.reminder-action-sheet-btn strong {
    display: block;
    color: #f1efff;
    font-size: 0.88rem;
    font-weight: 700;
}

.reminder-action-sheet-btn small {
    display: block;
    margin-top: 0.2rem;
    color: #a4a1bf;
    font-size: 0.74rem;
    line-height: 1.4;
}

.reminder-action-sheet-btn-danger {
    border-color: rgba(239, 68, 68, 0.14);
    background: rgba(63, 30, 38, 0.5);
}

.reminder-action-sheet-btn-danger .material-symbols-outlined,
.reminder-action-sheet-btn-danger strong {
    color: #ffb4ab;
}

.reminder-action-sheet-btn-danger small {
    color: #d9a6a1;
}

/* --- Clean Table Pills / Action Sheets --- */
.entity-pill {
    display: inline-flex;
    align-items: center;
    max-width: 15rem;
    padding: 0.6rem 0.9rem;
    border-radius: 9999px;
    background: rgba(34, 42, 61, 0.66);
    border: 1px solid rgba(104, 104, 132, 0.14);
    color: #d8d6ef;
    font-size: 0.8rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.entity-pill-strong {
    color: #f3f1ff;
    font-weight: 700;
}

.table-amount-pill {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0.55rem 0.8rem;
    border-radius: 9999px;
    background: rgba(28, 37, 56, 0.72);
    color: #f0eefc;
    font-weight: 700;
    white-space: nowrap;
}

.table-action-trigger {
    width: 3rem;
    height: 3rem;
    justify-content: center;
    padding: 0;
    border-radius: 1rem;
}

.action-sheet-btn {
    width: 100%;
    display: grid;
    grid-template-columns: 1.4rem 1fr;
    gap: 0.9rem;
    align-items: start;
    padding: 1rem 1.05rem;
    border: 1px solid rgba(104, 104, 132, 0.14);
    border-radius: 1rem;
    background: rgba(27, 35, 54, 0.72);
    color: #dddaf3;
    text-align: left;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.action-sheet-btn:hover {
    background: rgba(36, 45, 67, 0.88);
    border-color: rgba(195, 192, 255, 0.16);
    transform: translateY(-1px);
}

.action-sheet-btn .material-symbols-outlined {
    font-size: 1.15rem;
    margin-top: 0.05rem;
    color: #c8c5e7;
}

.action-sheet-btn strong {
    display: block;
    color: #f1efff;
    font-size: 0.88rem;
    font-weight: 700;
}

.action-sheet-btn small {
    display: block;
    margin-top: 0.2rem;
    color: #a4a1bf;
    font-size: 0.74rem;
    line-height: 1.4;
}

.action-sheet-btn-danger {
    border-color: rgba(239, 68, 68, 0.14);
    background: rgba(63, 30, 38, 0.5);
}

.action-sheet-btn-danger .material-symbols-outlined,
.action-sheet-btn-danger strong {
    color: #ffb4ab;
}

.action-sheet-btn-danger small {
    color: #d9a6a1;
}

/* --- Purchase Order Progress --- */
.po-progress-track {
    position: relative;
    width: 100%;
    height: 1.35rem;
    overflow: hidden;
    border-radius: 9999px;
    background: rgba(34, 42, 61, 0.88);
    border: 1px solid rgba(104, 104, 132, 0.14);
}

.po-progress-fill {
    position: absolute;
    inset: 0 auto 0 0;
    height: 100%;
    min-width: 0;
    border-radius: 9999px;
    transition: width 0.25s ease;
}

.po-progress-fill-safe {
    background: linear-gradient(90deg, #15803d, #22c55e);
}

.po-progress-fill-warning {
    background: linear-gradient(90deg, #d97706, #f59e0b);
}

.po-progress-fill-danger {
    background: linear-gradient(90deg, #dc2626, #ef4444);
}

.po-progress-label {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
    pointer-events: none;
}

/* --- Responsive Sidebar --- */
@media (max-width: 767px) {
    #sidebar.open { transform: translateX(0); }
    #sidebar-overlay.show { display: block !important; }
}

/* --- Section Labels --- */
.section-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: #555370;
}

/* --- Pulse animation for live indicators --- */
@keyframes pulse-glow {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}
.pulse-glow {
    animation: pulse-glow 2s ease-in-out infinite;
}

/* --- Gradient text --- */
.gradient-text {
    background: linear-gradient(135deg, #c3c0ff, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --- Divider with gradient --- */
.gradient-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(70, 69, 85, 0.15), transparent);
}

/* --- Number counter animation --- */
@keyframes countUp {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}
.count-up {
    animation: countUp 0.5s ease-out;
}
