/* MODERN PREMIUM CSS DESIGN SYSTEM - DARK GLASSMORPHISM Theme */
:root {
    --bg-base: #060813;
    --panel-bg: rgba(18, 22, 45, 0.65);
    --panel-border: rgba(255, 255, 255, 0.08);
    --panel-glow: rgba(59, 130, 246, 0.03);
    
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --primary-glow: rgba(59, 130, 246, 0.25);
    
    --success: #10b981;
    --success-bg: rgba(16, 185, 129, 0.1);
    --success-border: rgba(16, 185, 129, 0.2);
    
    --danger: #f43f5e;
    --danger-bg: rgba(244, 63, 94, 0.1);
    --danger-border: rgba(244, 63, 94, 0.2);
    
    --warning: #f59e0b;
    --warning-bg: rgba(245, 158, 11, 0.1);
    --warning-border: rgba(245, 158, 11, 0.2);
    
    --text-main: #f3f4f6;
    --text-muted: #9ca3af;
    --text-dark: #6b7280;
    
    --font-primary: 'Outfit', 'Plus Jakarta Sans', system-ui, sans-serif;
    --radius-lg: 16px;
    --radius-md: 10px;
    --radius-sm: 6px;
    
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    background-color: var(--bg-base);
    color: var(--text-main);
    font-family: var(--font-primary);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* GRADIENT BACKDROP */
.gradient-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.g-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.15;
}

.g-1 {
    top: -10%;
    left: 10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, #3b82f6 0%, transparent 80%);
}

.g-2 {
    bottom: -10%;
    right: 15%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, #8b5cf6 0%, transparent 80%);
}

.g-3 {
    top: 30%;
    right: 40%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, #ec4899 0%, transparent 80%);
}

/* GLASSMORPHISM PANELS */
.glassmorphism {
    background: var(--panel-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--panel-border);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
}

.card-panel {
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
    background: var(--panel-bg);
    border: 1px solid var(--panel-border);
    backdrop-filter: blur(12px);
    margin-bottom: 20px;
}

/* BUTTONS */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--font-primary);
    font-weight: 500;
    font-size: 14px;
    padding: 10px 18px;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition-fast);
    border: 1px solid transparent;
}

.btn-primary {
    background-color: var(--primary);
    color: #ffffff;
    box-shadow: 0 4px 14px 0 rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    box-shadow: 0 6px 20px 0 rgba(59, 130, 246, 0.45);
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    border-color: rgba(255, 255, 255, 0.08);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.15);
}

.btn-success {
    background-color: var(--success);
    color: #ffffff;
    box-shadow: 0 4px 14px 0 rgba(16, 185, 129, 0.3);
}

.btn-success:hover {
    background-color: #059669;
    box-shadow: 0 6px 20px 0 rgba(16, 185, 129, 0.45);
}

.btn-full {
    width: 100%;
}

.btn-icon {
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    color: var(--text-main);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.btn-icon:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.btn-icon-compact {
    padding: 6px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.btn-icon-compact:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* LOGIN LAYOUT */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(4, 5, 12, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-normal);
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.login-card {
    width: 460px;
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    text-align: center;
}

.login-header {
    margin-bottom: 30px;
}

.logo-icon {
    width: 54px;
    height: 54px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--primary) 0%, #8b5cf6 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    margin: 0 auto 16px;
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.4);
}

.login-card h2 {
    font-size: 26px;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 6px;
    background: linear-gradient(to right, #ffffff, #9ca3af);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.login-card p {
    color: var(--text-muted);
    font-size: 14px;
}

.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-group label {
    display: block;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 6px;
    font-weight: 500;
}

.input-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon i {
    position: absolute;
    left: 14px;
    color: var(--text-dark);
    font-size: 18px;
}

.input-icon input, .form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 12px 14px 12px 42px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    color: var(--text-main);
    font-family: var(--font-primary);
    font-size: 14px;
    transition: var(--transition-fast);
}

.form-group input:not([placeholder]) {
    padding-left: 14px;
}

.form-group select, .form-group textarea, .scope-builder-row select {
    padding-left: 14px;
}

.input-icon input:focus, .form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

/* Fix dropdown options readability (white-on-white bug) */
select option {
    background-color: #0c0f24;
    color: #f3f4f6;
}

.login-hints {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 12px;
    color: var(--text-dark);
    text-align: left;
}

.login-hints ul {
    list-style: none;
    margin-top: 8px;
}

.login-hints li {
    margin-bottom: 4px;
}

.login-hints code {
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 4px;
    border-radius: 4px;
    color: var(--text-muted);
}

/* APP WRAPPER LAYOUT */
#app-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.app-header {
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
    border-bottom: 1px solid var(--panel-border);
    flex-shrink: 0;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand .logo-icon {
    margin: 0;
    width: 40px;
    height: 40px;
    font-size: 22px;
    border-radius: var(--radius-md);
}

.brand-text h1 {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.brand-text span {
    font-size: 11px;
    color: var(--text-muted);
}

.global-selectors {
    display: flex;
    gap: 20px;
}

.selector-item {
    display: flex;
    flex-direction: column;
}

.selector-item label {
    font-size: 10px;
    color: var(--text-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.selector-item select {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-main);
    font-family: var(--font-primary);
    font-size: 13px;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    min-width: 160px;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 16px;
}

.user-info {
    text-align: right;
    display: flex;
    flex-direction: column;
}

.user-info span:first-child {
    font-weight: 500;
    font-size: 14px;
}

.badge {
    display: inline-block;
    padding: 2px 8px;
    font-size: 10px;
    font-weight: 600;
    border-radius: 20px;
    background-color: var(--primary-glow);
    color: var(--primary);
    border: 1px solid rgba(59, 130, 246, 0.2);
    width: fit-content;
    align-self: flex-end;
}

.badge-danger {
    background-color: var(--danger-bg);
    color: var(--danger);
    border-color: var(--danger-border);
}

.badge-success {
    background-color: var(--success-bg);
    color: var(--success);
    border-color: var(--success-border);
}

.badge-warning {
    background-color: var(--warning-bg);
    color: var(--warning);
    border-color: var(--warning-border);
}

.app-layout {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* SIDEBAR MENU */
.app-sidebar {
    width: 260px;
    display: flex;
    flex-direction: column;
    border-right: 1px solid var(--panel-border);
    padding: 24px 16px;
    flex-shrink: 0;
}

.nav-menu {
    list-style: none;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    border-radius: var(--radius-md);
    color: var(--text-muted);
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition-fast);
    border: 1px solid transparent;
}

.nav-item i {
    font-size: 20px;
}

.nav-item:hover {
    background-color: rgba(255, 255, 255, 0.03);
    color: #ffffff;
}

.nav-item.active {
    background-color: var(--primary-glow);
    color: var(--primary);
    border-color: rgba(59, 130, 246, 0.15);
    font-weight: 600;
}

.sidebar-footer {
    padding-top: 20px;
    border-top: 1px solid var(--panel-border);
}

.system-time {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-dark);
}

/* VIEWPORT CONTENT CONTAINER */
.app-viewport {
    flex: 1;
    overflow-y: auto;
    padding: 30px;
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.viewport-header {
    margin-bottom: 24px;
}

.viewport-header h2 {
    font-size: 24px;
    font-weight: 700;
}

.text-muted {
    color: var(--text-muted);
    font-size: 14px;
}

/* KPI GRID */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

.kpi-card {
    border-radius: var(--radius-lg);
    padding: 22px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.kpi-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.kpi-icon.inflow {
    color: var(--success);
    background-color: var(--success-bg);
}

.kpi-icon.outflow {
    color: var(--danger);
    background-color: var(--danger-bg);
}

.kpi-icon.warning {
    color: var(--warning);
    background-color: var(--warning-bg);
}

.kpi-details {
    display: flex;
    flex-direction: column;
}

.kpi-title {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.kpi-details h3 {
    font-size: 20px;
    font-weight: 700;
    margin: 4px 0;
}

.kpi-subtext {
    font-size: 11px;
    color: var(--text-dark);
}

.warning-border {
    border-color: var(--warning-border) !important;
}

/* CHARTS ROW */
.charts-row {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 20px;
}

.chart-container h4 {
    margin-bottom: 16px;
    font-weight: 600;
    font-size: 16px;
}

.chart-wrapper {
    height: 320px;
    position: relative;
}

/* TABLES STYLING */
.table-panel {
    overflow: hidden;
}

.table-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.responsive-table {
    width: 100%;
    overflow-x: auto;
}

.cashflow-tree-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    text-align: left;
}

.cashflow-tree-table th {
    border-bottom: 2px solid var(--panel-border);
    padding: 14px 16px;
    color: var(--text-muted);
    font-weight: 600;
}

.cashflow-tree-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--panel-border);
}

.cashflow-tree-table th:first-child,
.cashflow-tree-table td:first-child {
    min-width: 320px;
    width: 320px;
    white-space: nowrap;
}

.tree-row-section {
    background-color: rgba(255, 255, 255, 0.02);
    font-weight: 700;
    font-size: 15px;
}

.tree-row-mainline {
    background-color: rgba(255, 255, 255, 0.005);
    font-weight: 600;
    font-size: 14px;
}

.tree-row-subitem {
    font-size: 13.5px;
    color: var(--text-main);
    cursor: pointer;
}

.tree-row-subitem:hover {
    background-color: rgba(59, 130, 246, 0.05);
}

.tree-row-rule {
    font-size: 12.5px;
    color: var(--text-muted);
    font-style: italic;
    background-color: rgba(0, 0, 0, 0.1);
}

.indent-1 {
    padding-left: 32px !important;
}

.indent-2 {
    padding-left: 54px !important;
}

.indent-3 {
    padding-left: 76px !important;
}

/* EXPAND/COLLAPSE ICON */
.toggle-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    margin-right: 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    cursor: pointer;
    transition: var(--transition-fast);
}

.toggle-icon:hover {
    background: rgba(255, 255, 255, 0.12);
}

.val-cell {
    text-align: right;
    font-family: monospace;
    font-size: 14px;
}

.val-positive {
    color: var(--success);
}

.val-negative {
    color: var(--danger);
}

.val-variance-pct {
    font-size: 11px;
    color: var(--text-dark);
}

/* EDITABLE GRID SHEET */
.editable-cell {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #ffffff;
    font-family: monospace;
    font-size: 14px;
    text-align: right;
    padding: 6px 10px;
    border-radius: var(--radius-sm);
    width: 100px;
    transition: var(--transition-fast);
}

.editable-cell:focus {
    outline: none;
    border-color: var(--primary) !important;
    background: rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 0 0 2px var(--primary-glow);
}

/* GRID LAYOUTS */
.grid-2col {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.grid-3col {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 20px;
}

.grid-2col-compact {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.col-span-1 {
    grid-column: span 1;
}

.col-span-2 {
    grid-column: span 2;
}

/* DROPZONE AREA actuals upload */
.dropzone-area {
    border: 2px dashed rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-lg);
    padding: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-normal);
    background: rgba(255, 255, 255, 0.01);
}

.dropzone-area:hover {
    border-color: var(--primary);
    background: rgba(59, 130, 246, 0.02);
}

.upload-large-icon {
    font-size: 48px;
    color: var(--text-dark);
    margin-bottom: 12px;
}

/* SCROLL PANELS */
.scroll-panel {
    max-height: 280px;
    overflow-y: auto;
}

.scroll-panel-large {
    max-height: 480px;
    overflow-y: auto;
}

/* STANDARD TABLES */
.standard-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13.5px;
    text-align: left;
}

.standard-table th {
    border-bottom: 2px solid var(--panel-border);
    padding: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

.standard-table td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--panel-border);
}

.standard-table tr:hover {
    background-color: rgba(255, 255, 255, 0.01);
}

/* AI DECK CARDS */
.grid-card-deck {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.ai-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: var(--transition-fast);
}

.ai-card:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.08);
    transform: translateY(-2px);
}

.ai-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.ai-card-title h4 {
    font-weight: 600;
    font-size: 14px;
}

.ai-card-title span {
    font-size: 11px;
    color: var(--text-dark);
}

.ai-card-confidence {
    font-size: 12px;
    font-weight: 700;
    color: var(--primary);
}

.ai-card-body {
    flex: 1;
}

.ai-card-amount {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
    font-family: monospace;
}

.ai-card-explanation {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
}

.ai-card-override {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.override-row {
    display: flex;
    gap: 8px;
}

.override-row input {
    flex: 1;
    padding: 6px 10px;
    font-size: 12px;
}

/* WORKFLOW approvals inbox */
.workflow-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.workflow-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 16px;
    border-radius: var(--radius-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.workflow-item-details h4 {
    font-size: 14px;
    font-weight: 600;
}

.workflow-item-details p {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* COMPACT TABS SUBADMIN */
.tab-nav-compact {
    display: flex;
    gap: 10px;
    border-bottom: 1px solid var(--panel-border);
    padding-bottom: 8px;
}

.tab-btn-compact {
    background: none;
    border: none;
    color: var(--text-muted);
    font-family: var(--font-primary);
    font-size: 13.5px;
    padding: 6px 12px;
    cursor: pointer;
    font-weight: 500;
    border-radius: var(--radius-sm);
    transition: var(--transition-fast);
}

.tab-btn-compact.active {
    background-color: rgba(255, 255, 255, 0.05);
    color: #ffffff;
    font-weight: 600;
}

.subtab-content {
    display: none;
}

.subtab-content.active {
    display: block;
}

/* SCOPE BADGES */
.scope-builder-row {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

.scope-builder-row select {
    flex: 1;
}

.scope-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    font-size: 12px;
    color: var(--text-muted);
    margin-right: 6px;
    margin-bottom: 6px;
}

.scope-badge i {
    cursor: pointer;
    color: var(--danger);
}

/* DRILLDOWN MODAL CARD */
.modal-card {
    width: 800px;
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    overflow: hidden;
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--panel-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    font-weight: 700;
    font-size: 18px;
}

.btn-close-modal {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 24px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.btn-close-modal:hover {
    color: #ffffff;
}

.modal-body {
    padding: 24px;
}

.lineage-breadcrumbs {
    display: flex;
    gap: 6px;
    font-size: 12px;
    color: var(--text-dark);
}

.lineage-breadcrumbs span:after {
    content: " /";
    margin-left: 6px;
}

.lineage-breadcrumbs span:last-child:after {
    content: "";
}

.lineage-breadcrumbs strong {
    color: var(--primary);
}

/* ALERT MESSAGES */
.alert-message {
    padding: 12px 16px;
    border-radius: var(--radius-md);
    font-size: 13.5px;
    margin-bottom: 20px;
    border: 1px solid transparent;
}

.alert-message.error {
    background-color: var(--danger-bg);
    color: var(--danger);
    border-color: var(--danger-border);
}

/* HELPERS */
.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.hide { display: none !important; }
.show { display: block !important; }
.flex-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.status-msg {
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.col-span-1 { grid-column: span 1; }
.col-span-2 { grid-column: span 2; }
.admin-only {
    /* Shown only if active user has Admin role */
}

/* ANALYSIS KPI GRID (3 columns) */
.analysis-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

/* HIGHLIGHTS & RECOMMENDATIONS PANELS */
.highlights-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 24px;
}

.insight-panel {
    padding: 22px;
    border-radius: var(--radius-lg);
}

.insight-panel h3 {
    margin-bottom: 14px;
    font-size: 16px;
    font-weight: 600;
}

.insight-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.insight-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 13.5px;
    line-height: 1.5;
}

.insight-item i {
    font-size: 20px;
    flex-shrink: 0;
    margin-top: 1px;
}

.insight-item.highlight i {
    color: var(--success);
}

.insight-item.recommendation i {
    color: var(--primary);
}

.insight-item.warning i {
    color: var(--warning);
}

.insight-item.danger i {
    color: var(--danger);
}

.insight-item.info i {
    color: #60a5fa;
}

/* ACTIVITY BREAKDOWN */
.activity-breakdown {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 12px;
}

.activity-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.activity-label {
    display: flex;
    justify-content: space-between;
    font-size: 13.5px;
}

.activity-progress-bg {
    height: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 5px;
    overflow: hidden;
}

.activity-progress-bar {
    height: 100%;
    border-radius: 5px;
    width: 0;
    transition: width 0.6s ease;
}

.activity-progress-bar.operating {
    background: linear-gradient(90deg, #10b981, #059669);
}

.activity-progress-bar.investing {
    background: linear-gradient(90deg, #3b82f6, #2563eb);
}

.activity-progress-bar.financing {
    background: linear-gradient(90deg, #f59e0b, #d97706);
}

/* AI CARD PERIOD BADGE */
.badge-period {
    background-color: rgba(59, 130, 246, 0.1);
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.2);
    margin-left: 8px;
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 4px;
    vertical-align: middle;
    font-weight: 500;
}

/* VALIDATION FIELD HIGHLIGHTS */
.validation-error {
    border-color: var(--danger) !important;
    background-color: rgba(244, 63, 94, 0.1) !important;
    box-shadow: 0 0 0 2px rgba(244, 63, 94, 0.2) !important;
}

.validation-warning {
    border-color: var(--warning) !important;
    background-color: rgba(245, 158, 11, 0.1) !important;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.2) !important;
}

/* TREE FILTER BAR STYLES */
.tree-filter-bar {
    display: flex;
    gap: 15px;
    align-items: center;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.tree-filter-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 180px;
    flex: 1;
}

.tree-filter-item label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-dark);
    font-weight: 600;
}

.tree-filter-item select, .tree-filter-item input {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    color: var(--text-main);
    font-size: 13px;
    padding: 8px 12px;
    transition: var(--transition-fast);
    width: 100%;
}

.tree-filter-item select:focus, .tree-filter-item input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
}

