/**
 * LGU-BATIS v2.0 Stylesheet
 * Budget, Accounting & Treasury Integrated System
 * SPSEC Pagadian Motion Theme - Clean, Proportional Government UI
 * Built on top of Bootstrap 5.3
 */

/* ============================================================
 CSS VARIABLES - SPSEC Pagadian Palette
   ============================================================ */
:root {
/* Brand Colors - SPSEC Pagadian */
    --primary: #2563eb;
    --primary-light: #60a5fa;
    --primary-lighter: #bfdbfe;
    --primary-dark: #1d4ed8;
    --primary-bg: #eaf2ff;

    /* Secondary */
    --secondary: #64748b;
    --secondary-light: #94a3b8;

    /* Status Colors */
    --success: #28a745;
    --success-light: #5cb85c;
    --success-bg: #eaf7ed;
    --warning: #ffc107;
    --warning-light: #ffdb4d;
    --warning-bg: #fff9e6;
    --danger: #dc3545;
    --danger-light: #e4606d;
    --danger-bg: #fdf0f1;
    --info: #17a2b8;
    --info-light: #3fc5d9;
    --info-bg: #e8f8fb;

    /* Neutrals - Cool Tones */
    --white: #ffffff;
    --bg: #edf4ff;
    --bg-card: #ffffff;
    --text: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --border: #d6e4ff;
    --border-light: #eff6ff;
    --dark: #0f172a;

    /* Sidebar - Animated Blue Gradient */
    --sidebar-width: 250px;
    --sidebar-text: rgba(255,255,255,0.9);
    --sidebar-hover: rgba(191, 219, 254, 0.18);
    --sidebar-active: rgba(255,255,255,0.22);
    --sidebar-active-text: #ffffff;
    --sidebar-section: rgba(255,255,255,0.6);

    /* Navbar */
    --navbar-height: 56px;
    --navbar-bg: #ffffff;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -2px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1);

    /* Radius */
    --radius: 8px;
    --radius-sm: 6px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;

    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.8125rem;
    --font-size-base: 0.875rem;
    --font-size-lg: 1rem;
    --font-size-xl: 1.125rem;
    --font-size-2xl: 1.375rem;
    --font-size-3xl: 1.75rem;

    /* Transitions */
    --transition: all 0.2s ease;
    --transition-slow: all 0.3s ease;
}

/* ============================================================
   GLOBAL RESETS & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: 1.6;
    color: var(--text);
    background-color: var(--bg);
    overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary-dark); }

:focus-visible {
    outline: 2px solid var(--primary-light);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

/* Custom Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #93c5fd; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #60a5fa; }

/* ============================================================
   LAYOUT STRUCTURE
   ============================================================ */
.main-wrapper {
    position: relative;
    display: block;
    min-height: 100vh;
    background:
        radial-gradient(circle at top right, rgba(96, 165, 250, 0.12), transparent 18%),
        radial-gradient(circle at bottom left, rgba(59, 130, 246, 0.1), transparent 22%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.72) 0%, rgba(237, 244, 255, 0.96) 100%);
    isolation: isolate;
}

.main-wrapper::before,
.main-wrapper::after {
    content: "";
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
    filter: blur(10px);
    animation: pageAura 18s ease-in-out infinite;
}

.main-wrapper::before {
    width: 240px;
    height: 240px;
    top: 88px;
    right: 5vw;
    background: rgba(96, 165, 250, 0.14);
}

.main-wrapper::after {
    width: 180px;
    height: 180px;
    bottom: 48px;
    left: calc(var(--sidebar-width) + 3vw);
    background: rgba(37, 99, 235, 0.12);
    animation-delay: 7s;
}

@keyframes sidebarAurora {
    0%, 100% { background-position: 0% 0%; }
    50% { background-position: 0% 100%; }
}

@keyframes sidebarPulse {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-12px) scale(1.03); }
}

@keyframes pageAura {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); opacity: 0.7; }
    50% { transform: translate3d(0, -10px, 0) scale(1.08); opacity: 1; }
}

/* --- Sidebar (Animated Blue Gradient) --- */
.sidebar-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: linear-gradient(180deg, #0f172a 0%, #173ea7 46%, #2563eb 78%, #38bdf8 100%);
    background-size: 100% 180%;
    color: var(--sidebar-text);
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 1040;
    transition: var(--transition-slow);
    border-right: 1px solid rgba(255,255,255,0.1);
    box-shadow: 18px 0 40px rgba(15, 23, 42, 0.14);
    animation: sidebarAurora 18s ease-in-out infinite;
}

.sidebar-wrapper.collapsed { transform: translateX(calc(var(--sidebar-width) * -1)); }

.sidebar-wrapper::before,
.sidebar-wrapper::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    background: rgba(191, 219, 254, 0.1);
    filter: blur(12px);
    pointer-events: none;
    animation: sidebarPulse 12s ease-in-out infinite;
}

.sidebar-wrapper::before {
    width: 136px;
    height: 136px;
    top: 24px;
    right: -44px;
}

.sidebar-wrapper::after {
    width: 120px;
    height: 120px;
    bottom: 48px;
    left: -34px;
    animation-delay: 5s;
}

/* Sidebar Brand */
.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 16px 14px;
    border-bottom: 1px solid rgba(255,255,255,0.14);
    margin-bottom: 10px;
}
.sidebar-brand-icon {
    width: 42px;
    height: 42px;
    background: linear-gradient(180deg, rgba(255,255,255,0.24), rgba(255,255,255,0.14));
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1rem;
    flex-shrink: 0;
    overflow: hidden;
    padding: 0;
    line-height: 0;
    border: 1px solid rgba(255,255,255,0.18);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.18);
}
.sidebar-brand-icon img,
.sidebar-brand-icon > img {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
    border-radius: inherit;
    display: block;
    flex: 0 0 auto;
}
.sidebar-brand-text {
    font-size: 0.9375rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.01em;
}
.sidebar-brand-subtext {
    font-size: 0.6875rem;
    color: rgba(255,255,255,0.82);
    margin-top: 0;
}

/* Sidebar Navigation */
.sidebar-nav {
    list-style: none;
    padding: 0 8px;
    margin: 0;
}

.sidebar-section-title {
    display: block;
    font-size: 0.625rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: rgba(255,255,255,0.74);
    padding: 16px 12px 4px;
    margin: 0;
}

.sidebar-nav-item { margin-bottom: 1px; }

.sidebar-nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 42px;
    padding: 9px 12px;
    color: rgba(255,255,255,0.94);
    font-size: var(--font-size-sm);
    font-weight: 600;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    cursor: pointer;
    text-decoration: none;
    position: relative;
    border: 1px solid transparent;
}
.sidebar-nav-link:hover {
    background: linear-gradient(135deg, rgba(255,255,255,0.16), rgba(191, 219, 254, 0.12));
    color: #fff;
    border-color: rgba(255,255,255,0.12);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
    transform: translateX(2px);
}
.sidebar-nav-link.active {
    background: linear-gradient(135deg, rgba(255,255,255,0.2), rgba(191, 219, 254, 0.18));
    color: var(--sidebar-active-text);
    border-color: rgba(255,255,255,0.18);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 10px 24px rgba(15, 23, 42, 0.14);
}
.sidebar-nav-link span {
    flex: 1 1 auto;
    min-width: 0;
}
.sidebar-nav-link i:first-child {
    width: 18px;
    text-align: center;
    font-size: 0.875rem;
    opacity: 0.96;
    flex-shrink: 0;
}
.sidebar-nav-link.active i:first-child { opacity: 1; }

.sidebar-office-link {
    margin: 0 8px 4px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(219, 234, 254, 0.94));
    color: #1d4ed8 !important;
    border: 1px solid rgba(147, 197, 253, 0.36);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.18);
}

.sidebar-office-link:hover,
.sidebar-office-link.active {
    background: linear-gradient(135deg, rgba(255, 255, 255, 1), rgba(224, 242, 254, 0.98));
    color: #1e3a8a !important;
}

.sidebar-office-link small {
    color: rgba(30, 64, 175, 0.92);
    font-weight: 600;
}

/* Submenu Arrow */
.submenu-arrow {
    margin-left: auto;
    font-size: 0.625rem !important;
    transition: transform 0.2s ease;
    opacity: 0.4 !important;
    width: auto !important;
}
.sidebar-nav-link.has-submenu:not(.collapsed) .submenu-arrow { transform: rotate(90deg); }

/* Submenus */
.sidebar-submenu {
    list-style: none;
    padding: 2px 0 4px 0;
    margin: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
}
.sidebar-submenu.show { max-height: 600px; }

/* ============================================================
   Budget Preparation Center
   ============================================================ */
.prep-hero-card {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1.5rem;
    padding: 1.5rem;
    background: linear-gradient(135deg, #eef4ff 0%, #ffffff 52%, #eff6ff 100%);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.prep-hero-copy h2 {
    margin-bottom: 0.5rem;
}

.prep-eyebrow {
    display: inline-block;
    margin-bottom: 0.5rem;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--primary-dark);
}

.prep-hero-copy p {
    max-width: 820px;
    margin-bottom: 0;
    color: var(--text-secondary);
}

.prep-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: flex-end;
}

.prep-stat-card,
.prep-source-card,
.prep-domain-card {
    height: 100%;
    padding: 1rem 1.125rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.prep-stat-card strong {
    display: block;
    font-size: 1.7rem;
    line-height: 1.1;
    color: var(--dark);
}

.prep-stat-label {
    display: inline-block;
    margin-bottom: 0.35rem;
    color: var(--text-secondary);
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.prep-source-title {
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.prep-source-card p {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.prep-flow-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.prep-flow-step {
    position: relative;
    min-height: 100%;
    padding: 1rem;
    background: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.prep-flow-phase {
    display: inline-flex;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    background: var(--primary-bg);
    color: var(--primary-dark);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.prep-flow-step h5 {
    margin: 0.75rem 0 0.45rem;
    font-size: 1rem;
}

.prep-flow-step p {
    margin-bottom: 0.85rem;
    color: var(--text-secondary);
    font-size: 0.84rem;
}

.prep-flow-link {
    font-weight: 600;
}

.prep-domain-head {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.prep-domain-head i {
    width: 2rem;
    height: 2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--primary-bg);
    color: var(--primary-dark);
}

.prep-domain-head h5 {
    margin: 0;
}

.prep-domain-list {
    margin: 0;
    padding-left: 1rem;
    color: var(--text-secondary);
}

.prep-domain-list li + li {
    margin-top: 0.45rem;
}

@media (max-width: 992px) {
    .prep-hero-card {
        flex-direction: column;
    }

    .prep-hero-actions {
        justify-content: flex-start;
    }
}

.prep-workbench-card {
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.prep-workbench-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.prep-workbench-section {
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}

.prep-inline-metric {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    background: #f8fafc;
    border: 1px solid var(--border);
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.prep-table-shell {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.prep-table-shell thead th {
    background: #f8fafc;
    white-space: nowrap;
}

.prep-side-stack {
    display: grid;
    gap: 1rem;
}

.prep-detail-card {
    padding: 1rem 1.1rem;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.prep-detail-label {
    display: inline-block;
    margin-bottom: 0.5rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--primary-dark);
}

.prep-logic-stack {
    display: grid;
    gap: 0.75rem;
}

.prep-logic-step {
    padding: 0.9rem;
    background: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
    border: 1px solid #bfdbfe;
    border-radius: var(--radius);
}

.prep-logic-phase {
    display: inline-flex;
    padding: 0.18rem 0.55rem;
    margin-bottom: 0.55rem;
    border-radius: 999px;
    background: #dbeafe;
    color: #1d4ed8;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
}

.prep-logic-step h6 {
    margin-bottom: 0.35rem;
}

.prep-logic-step p {
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.84rem;
}

.prep-checklist {
    margin: 0;
    padding-left: 1rem;
    color: var(--text-secondary);
}

.prep-checklist li + li {
    margin-top: 0.5rem;
}

.prep-empty-note {
    color: var(--text-muted);
    font-size: 0.84rem;
}

.prep-badge-list {
    display: grid;
    gap: 0.75rem;
}

.prep-badge-chip {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    background: #dbeafe;
    border: 1px solid #bfdbfe;
    color: #1d4ed8;
    font-size: 0.78rem;
    font-weight: 700;
}

.prep-target-chip {
    display: block;
    padding: 0.85rem 0.95rem;
    background: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
    border: 1px solid #bfdbfe;
    border-radius: var(--radius);
    text-decoration: none;
    box-shadow: var(--shadow-sm);
}

.prep-target-chip:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

.prep-target-chip-disabled {
    pointer-events: none;
    opacity: 0.75;
}

.prep-target-label {
    display: block;
    margin-bottom: 0.2rem;
    color: var(--dark);
    font-size: 0.84rem;
    font-weight: 700;
}

.prep-target-desc {
    display: block;
    color: var(--text-secondary);
    font-size: 0.8rem;
    line-height: 1.45;
}

.prep-research-card {
    padding: 1.15rem 1.2rem;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.prep-research-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.prep-timeline {
    display: grid;
    gap: 0.85rem;
}

.prep-timeline-item {
    display: grid;
    grid-template-columns: minmax(98px, 120px) 1fr;
    gap: 0.9rem;
    align-items: flex-start;
    padding: 0.9rem;
    border: 1px solid #bfdbfe;
    border-radius: var(--radius);
    background: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
}

.prep-timeline-item p {
    margin-bottom: 0;
    color: var(--text-secondary);
    font-size: 0.84rem;
}

.prep-timeline-date {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2rem;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    background: #dbeafe;
    color: #1d4ed8;
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.prep-research-table {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.prep-research-table thead th {
    background: #f8fafc;
    white-space: nowrap;
}

.prep-rule-card {
    height: 100%;
    padding: 0.95rem 1rem;
    background: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
    border: 1px solid #bfdbfe;
    border-radius: var(--radius);
}

.prep-rule-title {
    margin-bottom: 0.4rem;
    color: var(--dark);
    font-weight: 700;
}

.prep-rule-card p {
    margin-bottom: 0.55rem;
    color: var(--text-secondary);
    font-size: 0.84rem;
}

.prep-draft-list {
    display: grid;
    gap: 0.75rem;
}

.prep-draft-item {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.85rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: #fcfcfd;
}

.prep-draft-item.active {
    border-color: #60a5fa;
    background: #eef4ff;
}

.prep-draft-copy {
    min-width: 0;
}

.prep-draft-copy strong {
    display: block;
    margin-bottom: 0.15rem;
}

.prep-draft-actions {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

@media (max-width: 768px) {
    .prep-draft-item {
        flex-direction: column;
    }

    .prep-draft-actions {
        flex-direction: row;
    }

    .prep-timeline-item {
        grid-template-columns: 1fr;
    }
}

.sidebar-submenu li a {
    display: block;
    padding: 5px 12px 5px 40px;
    color: rgba(255,255,255,0.88);
    font-size: 0.79rem;
    font-weight: 500;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    text-decoration: none;
    opacity: 1;
}
.sidebar-submenu li a:hover {
    opacity: 1;
    background: rgba(191, 219, 254, 0.16);
    color: #fff;
    transform: translateX(2px);
}
.sidebar-submenu li a.active {
    opacity: 1;
    color: var(--sidebar-active-text);
    background: linear-gradient(135deg, rgba(255,255,255,0.18), rgba(191, 219, 254, 0.14));
    font-weight: 600;
}

/* --- Content Area --- */
.content-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    width: calc(100% - var(--sidebar-width));
    max-width: calc(100% - var(--sidebar-width));
    transition: var(--transition-slow);
}
.content-wrapper.expanded {
    margin-left: 0;
    width: 100%;
    max-width: 100%;
}

/* --- Navbar --- */
.navbar-wrapper {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid var(--border);
    z-index: 1030;
    height: var(--navbar-height);
    box-shadow: var(--shadow-sm);
    width: 100%;
    flex-shrink: 0;
    backdrop-filter: blur(16px);
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: nowrap;
    height: 100%;
    padding: 0 20px;
    gap: 12px;
}

.navbar-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    min-width: 0;
}

.navbar-toggle {
    display: none;
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 1.125rem;
    cursor: pointer;
    transition: var(--transition);
}
.navbar-toggle:hover { background: var(--bg); }

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    font-size: var(--font-size-lg);
    color: var(--text);
}
.navbar-brand-icon { font-size: 1.25rem; }
.navbar-brand-seal {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.18);
}

.navbar-center {
    text-align: center;
    flex: 1 1 auto;
    min-width: 0;
    padding: 0 8px;
}
.navbar-lgu-name {
    font-size: var(--font-size-sm);
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.navbar-fiscal-info {
    font-size: var(--font-size-xs);
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    min-width: 0;
}

.navbar-bell {
    position: relative;
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
}
.navbar-bell:hover { background: var(--bg); color: var(--text); }
.navbar-bell-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 16px;
    height: 16px;
    background: var(--danger);
    color: #fff;
    font-size: 0.625rem;
    font-weight: 700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* User Dropdown */
.navbar-user-dropdown { position: relative; }
.navbar-user-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 10px 4px 4px;
    border: 1px solid var(--border);
    background: var(--white);
    border-radius: 24px;
    cursor: pointer;
    transition: var(--transition);
    max-width: 100%;
}
.navbar-user-toggle:hover { border-color: var(--primary-lighter); background: var(--primary-bg); }
.navbar-user-avatar {
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
}
.navbar-user-name {
    font-size: var(--font-size-sm);
    font-weight: 500;
    color: var(--text);
    max-width: 160px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.navbar-user-menu {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    width: 220px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    z-index: 1060;
    max-width: min(220px, calc(100vw - 24px));
}
.navbar-user-dropdown.show .navbar-user-menu { display: block; }

.navbar-user-menu-item {
    display: flex;
    align-items: center;
    padding: 10px 16px;
    font-size: var(--font-size-sm);
    color: var(--text);
    transition: var(--transition);
    text-decoration: none;
}
.navbar-user-menu-item:hover { background: var(--bg); color: var(--primary); }

/* --- Main Content (Phase 3: Bigger Padding) --- */
.main-content {
    flex: 1;
    padding: 28px 32px;
    overflow-y: auto;
    width: 100%;
    min-width: 0;
}

/* ============================================================
   BOOTSTRAP OVERRIDES - Cards, Forms, Tables, Buttons
   ============================================================ */

/* --- Cards --- */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    margin-bottom: 24px;
    overflow: hidden;
}
.card-header {
    background: transparent;
    border-bottom: 1px solid var(--border-light);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.card-title {
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: var(--text);
    margin: 0;
}
.card-body { padding: 20px; }
.card-footer {
    background: var(--bg);
    border-top: 1px solid var(--border-light);
    padding: 12px 20px;
}

/* --- Forms (Phase 3: BIGGER, PROPORTIONAL, HARMONIOUS) --- */
.form-label {
    font-size: var(--font-size-base);
    font-weight: 600;
    color: var(--text);
    margin-bottom: 6px;
    display: block;
}

.form-control,
.form-select {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    padding: 12px 16px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    background-color: var(--white);
    color: var(--text);
    transition: var(--transition);
    width: 100%;
    height: auto;
    min-height: 46px;
}
.form-control,
.form-select,
.input-group,
.select2-container {
    max-width: 100%;
}
.form-control:focus,
.form-select:focus {
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
    outline: none;
}
.form-control::placeholder { color: var(--text-muted); font-weight: 400; }

.form-control-sm {
    padding: 6px 10px;
    font-size: var(--font-size-sm);
    min-height: 34px;
}
.form-control-lg {
    padding: 14px 18px;
    font-size: var(--font-size-lg);
    min-height: 52px;
}

/* Form groups spacing */
.mb-3 { margin-bottom: 1rem !important; }
.mb-4 { margin-bottom: 1.5rem !important; }

/* Required field indicator */
.form-label .text-danger,
.required-star { color: var(--danger); }

/* Input group */
.input-group .form-control { border-radius: 0; }
.input-group .form-control:first-child { border-top-left-radius: var(--radius); border-bottom-left-radius: var(--radius); }
.input-group .form-control:last-child { border-top-right-radius: var(--radius); border-bottom-right-radius: var(--radius); }
.input-group-text {
    background: var(--bg);
    border: 1.5px solid var(--border);
    color: var(--text-secondary);
    font-size: var(--font-size-sm);
}

/* Select2 fix */
.select2-container { width: 100% !important; }
.select2-container .select2-selection--single {
    min-height: 46px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    padding: 8px 12px;
}

/* --- Buttons (Clean, Proportional) --- */
.btn {
    font-family: var(--font-family);
    font-size: var(--font-size-sm);
    font-weight: 500;
    padding: 9px 18px;
    border-radius: var(--radius);
    border: 1.5px solid transparent;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    line-height: 1.4;
    max-width: 100%;
    white-space: nowrap;
}
.btn:focus { box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15); }

.btn-primary {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }

.btn-success { background: var(--success); border-color: var(--success); color: #fff; }
.btn-success:hover { background: #218838; border-color: #218838; color: #fff; }

.btn-warning { background: var(--warning); border-color: var(--warning); color: #2E3A4E; }
.btn-warning:hover { background: #e0a800; border-color: #e0a800; color: #2E3A4E; }

.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-danger:hover { background: #c82333; border-color: #c82333; color: #fff; }

.btn-secondary { background: var(--secondary); border-color: var(--secondary); color: #fff; }
.btn-secondary:hover { background: #556275; border-color: #556275; color: #fff; }

.btn-info { background: var(--info); border-color: var(--info); color: #fff; }

.btn-outline-primary {
    background: transparent;
    border-color: var(--primary);
    color: var(--primary);
}
.btn-outline-primary:hover { background: var(--primary); color: #fff; }

.btn-outline-success { background: transparent; border-color: var(--success); color: var(--success); }
.btn-outline-success:hover { background: var(--success); color: #fff; }

.btn-outline-secondary { background: transparent; border-color: var(--border); color: var(--text-secondary); }
.btn-outline-secondary:hover { background: var(--bg); color: var(--text); }

.btn-sm { padding: 5px 10px; font-size: var(--font-size-xs); border-radius: var(--radius-sm); }
.btn-lg { padding: 12px 24px; font-size: var(--font-size-lg); }

.btn-close {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    opacity: 0.6;
}
.btn-close:hover { opacity: 1; }

/* --- Tables (Clean, Readable) --- */
.table {
    font-size: var(--font-size-sm);
    margin-bottom: 0;
    width: 100%;
}
.table > thead > tr > th {
    font-weight: 600;
    font-size: var(--font-size-xs);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-secondary);
    padding: 10px 12px;
    border-bottom: 2px solid var(--border);
    background: var(--bg);
    white-space: nowrap;
}
.table > tbody > tr > td {
    padding: 10px 12px;
    vertical-align: middle;
    border-bottom: 1px solid var(--border-light);
    color: var(--text);
}
.table > tbody > tr:last-child > td { border-bottom: none; }
.table-hover > tbody > tr:hover > td { background: rgba(37, 99, 235, 0.04); }

.table-sm > thead > tr > th { padding: 8px 10px; }
.table-sm > tbody > tr > td { padding: 8px 10px; }

/* --- Badges --- */
.badge {
    font-family: var(--font-family);
    font-size: 0.6875rem;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: 20px;
    letter-spacing: 0.02em;
}
.badge.bg-success, .badge-success { background: var(--success-bg) !important; color: var(--success) !important; }
.badge.bg-warning, .badge-warning { background: var(--warning-bg) !important; color: var(--warning) !important; }
.badge.bg-danger, .badge-danger { background: var(--danger-bg) !important; color: var(--danger) !important; }
.badge.bg-info, .badge-info { background: var(--info-bg) !important; color: var(--info) !important; }
.badge.bg-primary, .badge-primary { background: var(--primary-bg) !important; color: var(--primary) !important; }
.badge.bg-secondary { background: #eff6ff !important; color: var(--secondary) !important; }

/* --- Modals (Bigger, Cleaner) --- */
.modal-content {
    border: none;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}
.modal-header {
    padding: 18px 24px;
    border-bottom: 1px solid var(--border-light);
    background: var(--white);
}
.modal-header .modal-title,
.modal-header h5 {
    font-size: var(--font-size-xl);
    font-weight: 600;
    color: var(--text);
    margin: 0;
}
.modal-body {
    padding: 24px;
    max-height: 70vh;
    overflow-y: auto;
}
.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-light);
    background: var(--bg);
    gap: 8px;
}
.modal-lg { max-width: 720px; }
.modal-xl { max-width: 960px; }

/* Modal form layout - proportional grid */
.modal-body .row { margin-left: -8px; margin-right: -8px; }
.modal-body .row > [class*="col-"] { padding-left: 8px; padding-right: 8px; }

/* ============================================================
   DASHBOARD WIDGETS (KPI Cards) - Phase 3: Bigger
   ============================================================ */
.widget-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 22px 24px;
    position: relative;
    overflow: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}
.widget-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}
.widget-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
}
.widget-card.primary::before { background: linear-gradient(90deg, var(--primary), var(--primary-light)); }
.widget-card.success::before { background: linear-gradient(90deg, var(--success), var(--success-light)); }
.widget-card.warning::before { background: linear-gradient(90deg, var(--warning), var(--warning-light)); }
.widget-card.danger::before { background: linear-gradient(90deg, var(--danger), var(--danger-light)); }
.widget-card.info::before { background: linear-gradient(90deg, var(--info), var(--info-light)); }

.widget-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    margin-bottom: 12px;
}
.widget-card.primary .widget-icon { background: var(--primary-bg); color: var(--primary); }
.widget-card.success .widget-icon { background: var(--success-bg); color: var(--success); }
.widget-card.warning .widget-icon { background: var(--warning-bg); color: var(--warning); }
.widget-card.danger .widget-icon { background: var(--danger-bg); color: var(--danger); }

.widget-label {
    font-size: var(--font-size-xs);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    margin-bottom: 4px;
}
.widget-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1.2;
}

/* ============================================================
   PAGE HEADER
   ============================================================ */
.page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.page-title {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    color: var(--text);
    margin: 0;
    line-height: 1.3;
}
.page-subtitle {
    font-size: var(--font-size-sm);
    color: #64748b;
    margin: 2px 0 0;
}

.nav-tabs,
.nav-pills {
    gap: 0.5rem;
    border-bottom: none;
}

.nav-tabs .nav-link,
.nav-pills .nav-link {
    border: 1px solid var(--border);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    color: #334155;
    font-weight: 600;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.nav-tabs .nav-link:hover,
.nav-pills .nav-link:hover {
    border-color: rgba(96, 165, 250, 0.6);
    background: #eff6ff;
    color: var(--primary-dark);
    transform: translateY(-1px);
}

.nav-tabs .nav-link.active,
.nav-tabs .nav-item.show .nav-link,
.nav-pills .nav-link.active,
.nav-pills .show > .nav-link {
    color: #fff;
    border-color: transparent;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    box-shadow: 0 12px 28px rgba(37, 99, 235, 0.24);
}

.tab-content {
    margin-top: 1rem;
}
.page-header-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* ============================================================
   BREADCRUMB
   ============================================================ */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 6px;
    list-style: none;
    padding: 0;
    margin: 0 0 16px;
    font-size: var(--font-size-sm);
    color: var(--text-muted);
}
.breadcrumb-item + .breadcrumb-item::before {
    content: '/';
    margin-right: 6px;
    color: var(--text-muted);
}
.breadcrumb-item a { color: var(--text-secondary); }
.breadcrumb-item a:hover { color: var(--primary); }
.breadcrumb-item.active { color: var(--text); font-weight: 500; }

/* ============================================================
   FILTER BAR
   ============================================================ */
.filter-bar {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 16px 20px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-sm);
}

/* ============================================================
   TOAST NOTIFICATIONS
   ============================================================ */
.toast-container {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 1100;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.toast {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px 18px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-width: 320px;
    max-width: 440px;
    animation: slideInRight 0.3s ease;
    border-left: 4px solid var(--primary);
}
.toast.toast-success { border-left-color: var(--success); }
.toast.toast-error { border-left-color: var(--danger); }
.toast.toast-warning { border-left-color: var(--warning); }
.toast.toast-info { border-left-color: var(--info); }

.toast-title {
    font-size: var(--font-size-sm);
    font-weight: 600;
    color: var(--text);
}
.toast-message {
    font-size: var(--font-size-xs);
    color: var(--text-secondary);
    margin-top: 2px;
}
.toast-close {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0;
    margin-left: auto;
    font-size: 1rem;
}

/* ============================================================
   LOADING OVERLAY
   ============================================================ */
.loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.85);
    z-index: 1090;
    backdrop-filter: blur(2px);
    justify-content: center;
    align-items: center;
}
.loading-overlay.active { display: flex; }

.spinner-text {
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
    font-weight: 500;
}

.loading-spinner {
    display: none;
    text-align: center;
    padding: 40px;
}
.loading-spinner.active { display: block; }

/* ============================================================
   EMPTY STATE
   ============================================================ */
.empty-state {
    text-align: center;
    padding: 48px 24px;
}
.empty-state-icon {
    width: 64px;
    height: 64px;
    background: var(--bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    color: var(--text-muted);
    font-size: 1.5rem;
}
.empty-state-title {
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}
.empty-state-text {
    font-size: var(--font-size-sm);
    color: var(--text-muted);
}

/* ============================================================
   REPORT STYLES (Print-Ready)
   ============================================================ */
.report-container {
    background: var(--white);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.report-header {
    text-align: center;
    padding: 24px 32px 16px;
    border-bottom: 2px solid var(--text);
}
.report-header .republic { font-size: 0.8125rem; margin-bottom: 2px; }
.report-header .lgu-name { font-size: 1.125rem; font-weight: 700; text-transform: uppercase; }
.report-header .office-name { font-size: 0.875rem; color: var(--text-secondary); }
.report-header .report-title {
    font-size: 1.0625rem;
    font-weight: 700;
    margin-top: 12px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.report-header .report-period { font-size: 0.8125rem; color: var(--text-secondary); }

.report-params {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    padding: 16px 32px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    font-size: var(--font-size-sm);
}
.report-params label { font-weight: 600; margin-right: 4px; }

.report-body { padding: 0; }

.report-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}
.report-table th {
    background: var(--bg);
    border: 1px solid var(--border);
    padding: 8px 10px;
    font-weight: 600;
    text-align: center;
    font-size: 0.75rem;
    text-transform: uppercase;
}
.report-table td {
    border: 1px solid var(--border);
    padding: 6px 10px;
    vertical-align: top;
}
.report-table .text-end,
.report-table .text-right { text-align: right; }
.report-table .total-row {
    font-weight: 700;
    background: var(--bg);
    border-top: 2px solid var(--text);
}
.report-table .sub-total { font-weight: 600; background: var(--primary-bg); }
.report-table .indent-1 { padding-left: 24px; }
.report-table .indent-2 { padding-left: 48px; }

.report-footer {
    padding: 24px 32px;
    border-top: 1px solid var(--border);
}
.report-signatories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 32px;
    margin-top: 48px;
}
.signatory-block { text-align: center; }
.signatory-line {
    border-top: 1px solid var(--text);
    margin: 0 16px;
    padding-top: 4px;
}
.signatory-name { font-weight: 600; font-size: var(--font-size-sm); }
.signatory-title { font-size: var(--font-size-xs); color: var(--text-secondary); }

/* Report action bar */
.report-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    gap: 12px;
    flex-wrap: wrap;
}

/* ============================================================
   PRINT STYLES
   ============================================================ */
@media print {
    /* Hide non-print elements */
    .sidebar-wrapper,
    .navbar-wrapper,
    .breadcrumb,
    .page-header-actions,
    .filter-bar,
    .report-actions,
    .btn,
    .toast-container,
    .loading-overlay,
    .no-print { display: none !important; }

    /* Reset layout */
    body {
        background: white !important;
        color: black !important;
        font-size: 10pt;
        margin: 0;
        padding: 0;
    }
    .main-wrapper { display: block; }
    .content-wrapper {
        margin-left: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    .main-content { padding: 0 !important; }

    /* Report styles for print */
    .report-container {
        border: none !important;
        box-shadow: none !important;
        border-radius: 0 !important;
    }
    .report-header { border-bottom: 2px solid black; }
    .report-table { font-size: 9pt; }
    .report-table th, .report-table td { border: 1px solid #333; padding: 4px 6px; }
    .report-signatories { margin-top: 60px; }

    .card { border: none !important; box-shadow: none !important; }
    .table { font-size: 9pt; }

    /* Page breaks */
    .page-break-before { page-break-before: always; }
    .page-break-after { page-break-after: always; }
    .no-page-break { page-break-inside: avoid; }

    @page {
        margin: 0.5in;
        size: letter;
    }
}

/* ============================================================
   UTILITY CLASSES
   ============================================================ */
.text-muted { color: var(--text-muted) !important; }
.text-end { text-align: right !important; }
.text-center { text-align: center !important; }
.fw-bold { font-weight: 700 !important; }
.fw-semibold { font-weight: 600 !important; }

.gap-2 { gap: 0.5rem !important; }
.gap-3 { gap: 1rem !important; }

.currency-value { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }

/* ============================================================
   FINANCE MODERNIZATION UI COMPONENTS
   ============================================================ */
.finance-modernization-card {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background:
        radial-gradient(circle at top right, rgba(96, 165, 250, 0.18) 0, rgba(96, 165, 250, 0) 42%),
        linear-gradient(135deg, #f8fbff 0%, #ffffff 62%);
    box-shadow: var(--shadow-sm);
}

.finance-modernization-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.finance-modernization-header h3 {
    margin-bottom: 0.35rem;
    font-size: 1.125rem;
}

.finance-pill-list {
    display: flex;
    gap: 0.35rem;
    flex-wrap: wrap;
    align-items: flex-start;
}

.finance-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.72rem;
    font-weight: 600;
    color: #1e3a8a;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 999px;
    padding: 0.22rem 0.55rem;
    white-space: nowrap;
}

.finance-gauge-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.9rem;
    margin-bottom: 1rem;
}

.finance-gauge-card {
    border: 1px solid var(--border-light);
    border-radius: var(--radius);
    background: #fff;
    padding: 0.85rem;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    min-height: 208px;
}

.finance-gauge-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
}

.finance-gauge-title {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    margin: 0;
}

.finance-gauge-ring {
    --gauge-pct: 0;
    --gauge-color: var(--success);
    width: 86px;
    height: 86px;
    border-radius: 50%;
    margin: 0 auto;
    background: conic-gradient(var(--gauge-color) calc(var(--gauge-pct) * 1%), #eceff3 0);
    position: relative;
}

.finance-gauge-ring::before {
    content: "";
    position: absolute;
    inset: 8px;
    border-radius: 50%;
    background: #fff;
}

.finance-gauge-value {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: 700;
    color: #334155;
    z-index: 1;
}

.finance-gauge-meta {
    font-size: 0.74rem;
    color: var(--text-secondary);
    line-height: 1.45;
}

.finance-gauge-meta strong {
    font-weight: 700;
    color: #2f435c;
}

.finance-link-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.65rem;
}

.finance-link-chip {
    border: 1px solid #bfdbfe;
    border-radius: var(--radius-sm);
    background: #f8fbff;
    padding: 0.6rem 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    color: #1d4ed8;
    text-decoration: none;
    font-size: 0.78rem;
    font-weight: 600;
}

.finance-link-chip:hover {
    background: #eff6ff;
    color: #1e40af;
}

.audience-message-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.9rem;
}

.audience-message-card {
    border: 1px solid var(--border-light);
    border-radius: var(--radius);
    background: #fff;
    padding: 0.85rem;
}

.audience-message-card h4 {
    font-size: 0.95rem;
    margin-bottom: 0.45rem;
}

.audience-message-card p {
    margin: 0;
    font-size: 0.79rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.audience-message-card.executive h4 { color: #1e3a8a; }
.audience-message-card.staff h4 { color: #0369a1; }
.audience-message-card.citizen h4 { color: #23663f; }

.mockup-split-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
}

.mockup-pane {
    border: 1px solid var(--border-light);
    border-radius: var(--radius);
    background: #fff;
    padding: 0.75rem;
}

.mockup-pane.before {
    background: linear-gradient(180deg, #fff8f8 0%, #fff 100%);
}

.mockup-pane.after {
    background: linear-gradient(180deg, #f4fffb 0%, #fff 100%);
}

.mockup-pane h5 {
    font-size: 0.84rem;
    font-weight: 700;
    margin-bottom: 0.45rem;
}

.mockup-list {
    margin: 0;
    padding-left: 1rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.mockup-list li { margin-bottom: 0.28rem; }

.payment-journey {
    counter-reset: payment-step;
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.7rem;
}

.payment-journey li {
    position: relative;
    border: 1px solid #d3e8dc;
    border-radius: var(--radius-sm);
    background: #f8fffb;
    padding: 0.65rem 0.6rem 0.6rem 2rem;
    font-size: 0.75rem;
    color: #2b5940;
    line-height: 1.45;
}

.payment-journey li::before {
    counter-increment: payment-step;
    content: counter(payment-step);
    position: absolute;
    top: 0.58rem;
    left: 0.55rem;
    width: 1.1rem;
    height: 1.1rem;
    border-radius: 50%;
    background: #1e9a5a;
    color: #fff;
    font-size: 0.69rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.journey-cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-top: 0.7rem;
}

.journey-cta-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border: 1px dashed #b6d8c5;
    color: #1f5b3e;
    background: #effaf4;
    border-radius: 999px;
    padding: 0.2rem 0.5rem;
    font-size: 0.69rem;
    font-weight: 600;
}

.workflow-guide-card {
    border: 1px solid var(--border-light);
    border-radius: var(--radius);
    background: linear-gradient(180deg, #fffdf9 0%, #fff 100%);
    padding: 0.85rem;
}

.workflow-guide-card h6 {
    font-size: 0.82rem;
    margin-bottom: 0.45rem;
}

.workflow-guide-card p {
    font-size: 0.76rem;
    color: var(--text-secondary);
    margin-bottom: 0.55rem;
}

.workflow-checklist {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.workflow-checklist li {
    border: 1px solid #e6edf3;
    border-radius: var(--radius-sm);
    background: #fbfdff;
    padding: 0.42rem 0.55rem;
    font-size: 0.72rem;
    color: #4b5563;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.workflow-checklist li i {
    width: 1rem;
    text-align: center;
}

.workflow-checklist li.ok {
    border-color: #b8e8cd;
    background: #f2fcf6;
    color: #1e6b44;
}

.workflow-checklist li.pending {
    border-color: #f8ddb2;
    background: #fff9ef;
    color: #8a5a23;
}

.validation-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 0.18rem 0.45rem;
    white-space: nowrap;
}

.validation-chip.valid {
    color: #1e6b44;
    background: #e8faef;
}

.validation-chip.invalid {
    color: #92400e;
    background: #fff5df;
}

.approval-lane {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.45rem;
    margin-top: 0.55rem;
}

.approval-lane.three-steps {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.approval-lane .lane-step {
    border: 1px solid #e4e9ef;
    border-radius: var(--radius-sm);
    padding: 0.42rem 0.45rem;
    text-align: center;
    font-size: 0.69rem;
    font-weight: 600;
    color: #64748b;
    background: #f8fafc;
}

.approval-lane .lane-step.done {
    border-color: #b8e8cd;
    background: #eefcf4;
    color: #1e6b44;
}

.approval-lane .lane-step.current {
    border-color: #93c5fd;
    background: #eff6ff;
    color: #1d4ed8;
}

.service-clarity-note {
    border: 1px dashed #b7d7c6;
    border-radius: var(--radius-sm);
    background: #f3fcf7;
    font-size: 0.73rem;
    color: #1f5d3f;
    padding: 0.55rem 0.65rem;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes slideInRight {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto !important;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .sidebar-nav-link:hover,
    .sidebar-submenu li a:hover,
    .nav-tabs .nav-link:hover,
    .nav-pills .nav-link:hover,
    .widget-card:hover {
        transform: none !important;
    }
}

/* ============================================================
   RESPONSIVE DESIGN
   ============================================================ */
@media (max-width: 991.98px) {
    .sidebar-wrapper {
        transform: translateX(calc(var(--sidebar-width) * -1));
        box-shadow: none;
    }
    .sidebar-wrapper.show {
        transform: translateX(0);
        box-shadow: var(--shadow-lg);
    }
    .content-wrapper { margin-left: 0 !important; }
    .navbar-toggle { display: flex; align-items: center; justify-content: center; }
    .navbar-brand { display: flex; }

    /* Sidebar overlay */
    .sidebar-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0,0,0,0.4);
        z-index: 1035;
    }
    .sidebar-overlay.show { display: block; }
}

@media (min-width: 992px) {
    .navbar-brand { display: none; }
    .navbar-toggle { display: none; }
}

@media (max-width: 767.98px) {
    .main-content { padding: 16px; }

    .page-header { flex-direction: column; }
    .page-header-actions { width: 100%; }
    .page-header-actions .btn { flex: 1; justify-content: center; }
    .navbar { padding: 0 12px; gap: 8px; }
    .navbar-right { gap: 6px; }
    .navbar-user-toggle {
        padding-right: 8px;
        max-width: 180px;
    }
    .navbar-user-name { max-width: 96px; }

    .page-title { font-size: var(--font-size-xl); }

    /* Stack filters vertically */
    .row.mb-3 > [class*="col-"] { margin-bottom: 8px; }

    /* Modal full width on mobile */
    .modal-dialog { margin: 8px; max-width: calc(100% - 16px); }
    .modal-body { padding: 16px; }

    /* Report adjustments */
    .report-header { padding: 16px; }
    .report-table { font-size: 0.7rem; }
    .report-table th, .report-table td { padding: 4px 6px; }
    .report-signatories { grid-template-columns: 1fr 1fr; gap: 16px; }
}

@media (max-width: 575.98px) {
    .main-content { padding: 12px; }
    .widget-value { font-size: 1.25rem; }
    .navbar-user-name { display: none; }
    .navbar-center { display: none; }
    .navbar-user-menu {
        right: 0;
        left: auto;
        width: min(220px, calc(100vw - 24px));
    }
    .d-flex.gap-2,
    .d-flex.gap-3 {
        flex-wrap: wrap;
    }
    .btn {
        white-space: normal;
        text-align: center;
        justify-content: center;
    }
    .card-footer .btn,
    .d-flex.gap-2 .btn,
    .d-flex.gap-3 .btn {
        flex: 1 1 100%;
    }

    .finance-gauge-grid,
    .finance-link-grid,
    .audience-message-grid,
    .mockup-split-grid,
    .payment-journey {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 991.98px) {
    .card-footer .d-flex,
    .card-footer.d-flex,
    .modal-footer {
        flex-wrap: wrap;
    }
    .card-footer .btn,
    .modal-footer .btn {
        width: 100%;
        justify-content: center;
    }

    .finance-gauge-grid,
    .audience-message-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .finance-link-grid,
    .payment-journey {
        grid-template-columns: 1fr;
    }

    .mockup-split-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================================
   GLASSMORPHISM CARDS & ENHANCED UI v2.5
   ============================================================ */
.glass-card {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: var(--radius-lg);
    box-shadow: 0 8px 32px rgba(37, 99, 235, 0.08);
    transition: var(--transition);
}
.glass-card:hover {
    box-shadow: 0 12px 40px rgba(37, 99, 235, 0.14);
    transform: translateY(-2px);
}

/* Stat Cards - Enhanced KPI */
.stat-card {
    position: relative;
    padding: 20px 24px;
    border-radius: var(--radius-lg);
    background: var(--bg-card);
    border: 1px solid var(--border);
    overflow: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}
.stat-card::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    opacity: 0;
    transition: opacity 0.3s ease;
}
.stat-card:hover::after { opacity: 1; }
.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}
.stat-card-icon {
    width: 48px; height: 48px;
    border-radius: var(--radius);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.25rem;
    margin-bottom: 14px;
}
.stat-card-value {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1.15;
    font-variant-numeric: tabular-nums;
}
.stat-card-label {
    font-size: var(--font-size-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-top: 4px;
}
.stat-card-change {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: var(--font-size-xs);
    font-weight: 600;
    margin-top: 8px;
    padding: 2px 8px;
    border-radius: 999px;
}
.stat-card-change.up { color: #16a34a; background: #f0fdf4; }
.stat-card-change.down { color: #dc2626; background: #fef2f2; }

/* Progress Bars - Enhanced */
.progress-enhanced {
    height: 8px;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
    position: relative;
}
.progress-enhanced-bar {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}
.progress-enhanced-bar::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: shimmer 2s infinite;
}
@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}
.progress-enhanced.success .progress-enhanced-bar { background: linear-gradient(90deg, #16a34a, #22c55e); }
.progress-enhanced.warning .progress-enhanced-bar { background: linear-gradient(90deg, #d97706, #f59e0b); }
.progress-enhanced.danger .progress-enhanced-bar { background: linear-gradient(90deg, #dc2626, #ef4444); }

/* Data Table Enhancements */
.table-enhanced {
    border-collapse: separate;
    border-spacing: 0;
}
.table-enhanced > thead > tr > th {
    background: linear-gradient(180deg, #f8fafc, #f1f5f9);
    border-bottom: 2px solid var(--primary-lighter);
    position: sticky;
    top: 0;
    z-index: 10;
}
.table-enhanced > tbody > tr {
    transition: var(--transition);
}
.table-enhanced > tbody > tr:hover {
    background: rgba(37, 99, 235, 0.04);
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.table-enhanced > tbody > tr:hover > td:first-child {
    border-left: 3px solid var(--primary);
    padding-left: 9px;
}

/* Status Pipeline Badges */
.status-pipeline {
    display: flex; gap: 4px; align-items: center;
}
.status-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.status-dot.active {
    background: #16a34a;
    box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.2);
    animation: pulse-dot 2s infinite;
}
.status-dot.pending { background: #f59e0b; }
.status-dot.inactive { background: #94a3b8; }
@keyframes pulse-dot {
    0%, 100% { box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.2); }
    50% { box-shadow: 0 0 0 6px rgba(22, 163, 74, 0.1); }
}

/* Deposit Module Enhanced Styles */
.deposit-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}
.deposit-summary-card {
    padding: 20px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    background: var(--bg-card);
    position: relative;
    overflow: hidden;
}
.deposit-summary-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
}
.deposit-summary-card.gold::before { background: linear-gradient(90deg, #d97706, #f59e0b); }
.deposit-summary-card.blue::before { background: linear-gradient(90deg, var(--primary), var(--primary-light)); }
.deposit-summary-card.green::before { background: linear-gradient(90deg, #16a34a, #22c55e); }
.deposit-summary-card.red::before { background: linear-gradient(90deg, #dc2626, #ef4444); }

/* Quick Action Buttons */
.quick-actions {
    display: flex; flex-wrap: wrap; gap: 8px;
}
.quick-action-btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 10px 18px;
    border-radius: var(--radius);
    border: 1.5px solid var(--border);
    background: var(--bg-card);
    color: var(--text);
    font-size: var(--font-size-sm);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.quick-action-btn:hover {
    border-color: var(--primary-light);
    background: var(--primary-bg);
    color: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}
.quick-action-btn i {
    width: 20px; text-align: center;
    color: var(--primary);
}

/* Activity Timeline */
.activity-timeline {
    position: relative;
    padding-left: 28px;
}
.activity-timeline::before {
    content: '';
    position: absolute;
    left: 10px; top: 0; bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--primary-lighter), transparent);
}
.activity-timeline-item {
    position: relative;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-light);
}
.activity-timeline-item:last-child { border-bottom: none; }
.activity-timeline-item::before {
    content: '';
    position: absolute;
    left: -22px; top: 18px;
    width: 10px; height: 10px;
    border-radius: 50%;
    background: var(--primary);
    border: 2px solid var(--bg-card);
    z-index: 1;
}
.activity-timeline-time {
    font-size: var(--font-size-xs);
    color: var(--text-muted);
    margin-bottom: 2px;
}
.activity-timeline-text {
    font-size: var(--font-size-sm);
    color: var(--text);
}

/* Office Theme Variants */
.theme-budget { --theme-color: #2563eb; --theme-bg: #eef4ff; --theme-border: #bfdbfe; }
.theme-accounting { --theme-color: #059669; --theme-bg: #ecfdf5; --theme-border: #a7f3d0; }
.theme-treasury { --theme-color: #d97706; --theme-bg: #fffbeb; --theme-border: #fde68a; }
.theme-gso { --theme-color: #7c3aed; --theme-bg: #f5f3ff; --theme-border: #c4b5fd; }

[class*="theme-"] .stat-card-icon { background: var(--theme-bg); color: var(--theme-color); }
[class*="theme-"] .stat-card::after { background: linear-gradient(90deg, var(--theme-color), color-mix(in srgb, var(--theme-color), white 30%)); }

/* Fade-in animation for page load */
.fade-in-up {
    animation: fadeIn 0.4s ease-out both;
}
.fade-in-up:nth-child(2) { animation-delay: 0.05s; }
.fade-in-up:nth-child(3) { animation-delay: 0.1s; }
.fade-in-up:nth-child(4) { animation-delay: 0.15s; }
.fade-in-up:nth-child(5) { animation-delay: 0.2s; }
.fade-in-up:nth-child(6) { animation-delay: 0.25s; }

/* Skeleton Loading Placeholder */
.skeleton {
    background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: var(--radius-sm);
}
@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
.skeleton-text { height: 14px; margin-bottom: 8px; }
.skeleton-heading { height: 24px; width: 60%; margin-bottom: 12px; }
.skeleton-card { height: 120px; }

/* Enhanced Scrollbar for Content Areas */
.main-content::-webkit-scrollbar { width: 8px; }
.main-content::-webkit-scrollbar-track { background: transparent; }
.main-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}
.main-content::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* ============================================================
   LEGACY COMPATIBILITY
   ============================================================ */
/* Support for modules using old class names */
.container-fluid {
    width: 100%;
    max-width: 100%;
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}
.table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ============================================================
   SPSEC VISUAL SYSTEM OVERRIDES (Shell + Branding)
   ============================================================ */
:root {
    --primary: #7f1024;
    --primary-light: #b11f38;
    --primary-lighter: #efc6cd;
    --primary-dark: #5d0d1a;
    --primary-bg: #fff0f2;

    --secondary: #234064;
    --secondary-light: #436486;

    --bg: #f5f1eb;
    --bg-card: #fffdfa;
    --text: #1e232b;
    --text-secondary: #555f6f;
    --text-muted: #727b88;
    --border: #e6d7ca;
    --border-light: #f1e7de;
    --dark: #151820;
}

body {
    font-family: 'Source Sans 3', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background:
        radial-gradient(circle at 11% 11%, rgba(127, 16, 36, 0.13), transparent 22%),
        radial-gradient(circle at 87% 6%, rgba(35, 64, 100, 0.14), transparent 24%),
        radial-gradient(circle at 76% 88%, rgba(200, 161, 75, 0.12), transparent 20%),
        var(--bg);
}

h1, h2, h3, h4, h5, h6,
.navbar-lgu-name,
.sidebar-brand-text {
    font-family: 'Manrope', 'Inter', sans-serif;
}

.main-wrapper {
    background:
        radial-gradient(circle at top right, rgba(127, 16, 36, 0.1), transparent 22%),
        radial-gradient(circle at bottom left, rgba(35, 64, 100, 0.08), transparent 20%),
        linear-gradient(180deg, rgba(255, 253, 250, 0.78) 0%, rgba(245, 241, 235, 0.96) 100%);
}

.sidebar-wrapper {
    background: linear-gradient(180deg, #2b0812 0%, #591222 42%, #1f3553 100%);
    border-right: 1px solid rgba(255, 236, 224, 0.12);
    box-shadow: 16px 0 38px rgba(20, 10, 5, 0.24);
}

.sidebar-wrapper::before,
.sidebar-wrapper::after {
    background: rgba(246, 207, 173, 0.12);
}

.sidebar-brand {
    border-bottom: 1px solid rgba(255, 241, 231, 0.17);
}

.sidebar-brand-icon {
    border: 1px solid rgba(255, 244, 234, 0.34);
    box-shadow: 0 12px 24px rgba(27, 10, 7, 0.3);
}

.sidebar-brand-subtext {
    color: rgba(255, 233, 218, 0.82);
}

.sidebar-section-title {
    color: rgba(255, 225, 206, 0.8);
}

.sidebar-nav-link {
    color: rgba(255, 244, 235, 0.92);
}

.sidebar-nav-link:hover {
    background: linear-gradient(135deg, rgba(255, 238, 225, 0.16), rgba(250, 192, 151, 0.12));
    border-color: rgba(255, 229, 208, 0.2);
    transform: translateX(2px);
}

.sidebar-nav-link.active {
    background: linear-gradient(135deg, rgba(200, 161, 75, 0.28), rgba(177, 31, 56, 0.24));
    border-color: rgba(240, 205, 159, 0.42);
    color: #fffdf9;
}

.sidebar-submenu li a {
    color: rgba(255, 244, 235, 0.86);
}

.sidebar-submenu li a:hover,
.sidebar-submenu li a.active {
    background: rgba(255, 230, 212, 0.16);
}

.navbar-wrapper {
    border-bottom: 1px solid rgba(127, 16, 36, 0.14);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(255, 250, 245, 0.82));
}

.navbar {
    min-height: 60px;
}

.navbar-brand-seal {
    box-shadow: 0 8px 18px rgba(37, 14, 10, 0.24);
}

.navbar-system-link {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    padding: 0.42rem 0.7rem;
    border-radius: 999px;
    border: 1px solid rgba(127, 16, 36, 0.18);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(255, 243, 238, 0.96));
    color: var(--primary);
    font-size: 0.74rem;
    font-weight: 700;
    box-shadow: 0 8px 18px rgba(127, 16, 36, 0.08);
}

.navbar-system-link:hover {
    color: var(--primary-dark);
    border-color: rgba(127, 16, 36, 0.34);
    transform: translateY(-1px);
    box-shadow: 0 10px 22px rgba(127, 16, 36, 0.16);
}

.navbar-office-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: linear-gradient(135deg, #fff9f3, #ffefe4);
    color: #6e4120;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.35rem 0.66rem;
    border-radius: 999px;
    border: 1px solid rgba(198, 161, 86, 0.4);
    box-shadow: 0 8px 18px rgba(80, 46, 9, 0.1);
}

.navbar-user-toggle {
    border-color: rgba(127, 16, 36, 0.2);
}

.navbar-user-toggle:hover {
    background: #fff4ef;
    border-color: rgba(127, 16, 36, 0.34);
}

.navbar-user-avatar {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
}

.navbar-user-chevron {
    font-size: 0.64rem;
    color: var(--text-muted);
}

.navbar-user-menu {
    border: 1px solid var(--border);
    box-shadow: 0 18px 36px rgba(28, 13, 6, 0.15);
}

.navbar-user-meta {
    padding: 0.75rem 0.95rem;
    border-bottom: 1px solid var(--border-light);
}

.navbar-user-meta-name {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text);
}

.navbar-user-meta-role {
    margin-top: 0.16rem;
    font-size: 0.71rem;
    color: var(--text-muted);
}

.navbar-user-meta-office {
    margin-top: 0.24rem;
    font-size: 0.72rem;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.navbar-user-menu-item i {
    width: 0.95rem;
    margin-right: 0.48rem;
    text-align: center;
}

.navbar-user-menu-item-danger {
    color: #b91c1c;
}

.main-content {
    padding: 1.2rem 1.25rem 1.35rem;
}

.card,
.widget-card,
.module-card {
    border-color: var(--border);
}

.app-footer {
    margin-top: auto;
    padding: 0.84rem 1rem;
    background: rgba(255, 252, 248, 0.76);
    border-top: 1px solid var(--border-light);
    backdrop-filter: blur(8px);
}

.app-footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
    font-size: 0.74rem;
    color: var(--text-muted);
}

.app-footer-inner strong {
    color: var(--text-secondary);
}

.loading-overlay.active,
.loading-overlay.show {
    display: flex;
}

.theme-gso {
    --theme-color: #8a4b12;
    --theme-bg: #fff3e2;
    --theme-border: #f3d3af;
}

body.sidebar-open {
    overflow: hidden;
}

@media (max-width: 767.98px) {
    .navbar-system-link {
        display: none;
    }

    .navbar-office-badge {
        display: none;
    }
}
