﻿/* dashboard.css - Dashboard, enhanced dashboard, financial ledger, smart insights */

/* ==================== DASHBOARD STYLES ==================== */
.dashboard-content {
    padding: 2rem;
    background: #eef0f3;
    display: flex;
    flex-direction: column;
}

.stats-card {
    background: #fff;
    border: none;
    border-radius: 16px;
    padding: 1.25rem 1.5rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    transition: var(--eff-transition);
    position: relative;
    overflow: hidden;
    border: 1px solid #f0f0f0;
}

.stats-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.08);
    border-color: #e0e0e0;
}

.stats-card::before {
    display: none;
}

.stats-card-content {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.stats-card-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.stats-card-icon.deceased { background: #F4F0E9; color: #1E6332; }
.stats-card-icon.claims { background: #F4F0E9; color: #1E6332; }
.stats-card-icon.pending { background: #fef3e2; color: #e67e22; }
.stats-card-icon.funded { background: #F4F0E9; color: #1E6332; }

.stats-card-info {
    flex: 1;
    text-align: left;
}

.stats-card h3 {
    font-size: 1.85rem;
    font-weight: 700;
    color: #212529;
    margin-bottom: 0.15rem;
    line-height: 1.1;
}

.stats-card p {
    color: #6c757d;
    margin: 0;
    font-size: 0.85rem;
    font-weight: 400;
}

.stats-card-trend {
    font-size: 0.8rem;
    margin-top: 0.5rem;
    font-weight: 500;
}

.stats-card-trend.up { color: #1E6332; }
.stats-card-trend.down { color: #dc3545; }

/* Quick Actions */
.quick-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.quick-action-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    background: #fff;
    border: 1px solid #dee2e6;
    color: #212529;
    text-decoration: none;
    font-weight: 500;
    transition: var(--eff-transition);
}

.quick-action-btn:hover {
    border-color: var(--eff-primary);
    color: var(--eff-primary);
    background: #f0fff4;
}

.quick-action-btn i {
    font-size: 1.1rem;
}

/* Activity Feed */
.activity-feed {
    background: #fff;
    border-radius: 12px;
    box-shadow: var(--eff-shadow);
    overflow: hidden;
}

.activity-feed-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #dee2e6;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.activity-feed-header h5 {
    margin: 0;
    font-weight: 600;
}

.activity-item {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    gap: 12px;
    transition: background 0.2s;
}

.activity-item:hover {
    background: #f8f9fa;
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.875rem;
}

.activity-icon.new { background: #F4F0E9; color: #1E6332; }
.activity-icon.update { background: #cfe2ff; color: #084298; }
.activity-icon.approved { background: #F4F0E9; color: #214A3E; }
.activity-icon.denied { background: #f8d7da; color: #842029; }

.activity-content {
    flex: 1;
}

.activity-content p {
    margin: 0;
    font-size: 0.9rem;
}

.activity-content .activity-time {
    font-size: 0.8rem;
    color: #6c757d;
    margin-top: 0.25rem;
}

/* Welcome Banner */
.welcome-banner {
    background: linear-gradient(135deg, #1E6332 0%, #2F8542 100%);
    border-radius: 12px;
    padding: 1.5rem 2rem;
    color: #fff;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.welcome-banner h2 {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.welcome-banner p {
    opacity: 0.9;
    margin: 0;
}

.welcome-banner .btn {
    background: rgba(255,255,255,0.2);
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
}

.welcome-banner .btn:hover {
    background: rgba(255,255,255,0.3);
}

.welcome-banner-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* ==================== ENHANCED DASHBOARD ==================== */
.welcome-banner-enhanced {
    background: linear-gradient(135deg, #1E6332 0%, #214A3E 50%, #214A3E 100%);
    border-radius: 16px;
    padding: 1.75rem 2rem;
    color: #fff;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 20px rgba(30, 99, 50, 0.3);
}

.welcome-left {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.welcome-greeting h2 {
    font-size: 1.75rem;
    font-weight: 700;
    margin: 0;
}

.welcome-date {
    opacity: 0.85;
    font-size: 0.9rem;
    margin: 0;
}

.welcome-summary {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: rgba(255,255,255,0.1);
    padding: 0.75rem 1.25rem;
    border-radius: 10px;
}

.summary-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.summary-number {
    font-size: 1.5rem;
    font-weight: 700;
}

.summary-label {
    font-size: 0.75rem;
    opacity: 0.85;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.summary-divider {
    width: 1px;
    height: 35px;
    background: rgba(255,255,255,0.3);
}

.welcome-right {
    display: flex;
    align-items: center;
}

.welcome-actions-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.welcome-action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.85rem 1.25rem;
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 10px;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 100px;
    position: relative;
}

.welcome-action-btn i {
    font-size: 1.1rem;
}

.welcome-action-btn:hover {
    background: rgba(255,255,255,0.25);
    transform: translateY(-2px);
}

.welcome-action-btn.primary {
    background: #fff;
    color: #1E6332;
    border-color: #fff;
}

.welcome-action-btn.primary:hover {
    background: #f8f9fa;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.action-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    background: #dc3545;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}

/* Compact Welcome Banner */
.welcome-banner-compact {
    background: #fff;
    border-radius: 12px;
    padding: 1rem 1.5rem;
    color: #231F20;
    margin-bottom: 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.welcome-main {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.welcome-greeting-compact h2 {
    font-size: 1.35rem;
    font-weight: 600;
    margin: 0;
}

.welcome-greeting-compact .welcome-date {
    color: #475453;
    font-size: 0.8rem;
    margin: 0.15rem 0 0 0;
}

.welcome-stats-inline {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stat-pill {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255,255,255,0.15);
    padding: 0.4rem 0.85rem;
    border-radius: 20px;
    font-size: 0.8rem;
}

.stat-pill .stat-number {
    font-weight: 700;
    font-size: 1rem;
}

.stat-pill .stat-label {
    opacity: 0.9;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}


/* Welcome banner right-side group */
.welcome-right-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

/* ==================== Dashboard Customize ==================== */
.dash-customize-btn {
    background: none;
    border: 1px solid #e5e1da;
    border-radius: 8px;
    padding: 0.4rem 0.6rem;
    color: #8a8580;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.15s ease;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.dash-customize-btn:hover {
    color: #1E6332;
    border-color: #1E6332;
    background: #F4F0E9;
}

.dash-customize-panel {
    background: #fafaf8;
    border-radius: 0 0 12px 12px;
    border-top: 1px solid #eae7e2;
    margin-bottom: 1.25rem;
    overflow: hidden;
    animation: dashCustSlideIn 0.2s ease;
}

/* When customize panel is open, merge with welcome banner as one card */
.welcome-banner-compact.customize-open {
    border-radius: 12px 12px 0 0;
    margin-bottom: 0;
}

@keyframes dashCustSlideIn {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

.dash-customize-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.45rem 1.25rem;
    background: transparent;
    border-bottom: 1px solid #f0ede8;
    font-size: 0.75rem;
    font-weight: 600;
    color: #8a8580;
}

.dash-customize-header i {
    margin-right: 0.35rem;
    color: #8a8580;
}

.dash-customize-header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dash-customize-header button {
    background: none;
    border: none;
    color: #8a8580;
    cursor: pointer;
    font-size: 0.85rem;
    padding: 2px 6px;
    border-radius: 4px;
}

.dash-customize-header button:hover {
    color: #231F20;
    background: #e5e1da;
}

/* Default Home toggle row */
.dash-default-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.65rem 1rem;
    border-bottom: 1px solid #f0ede8;
    background: linear-gradient(135deg, #f8fdf9, #f0faf4);
}

.dash-default-left {
    display: flex;
    align-items: center;
    gap: 0.55rem;
}

.dash-default-icon {
    color: #1E6332;
    font-size: 0.9rem;
}

.dash-default-text {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.dash-default-label {
    font-size: 0.8rem;
    font-weight: 700;
    color: #1a1a1a;
}

.dash-default-hint {
    font-size: 0.65rem;
    color: #8a8580;
    font-style: italic;
}

/* ON/OFF toggle button */
.dash-default-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px 4px 8px;
    border-radius: 20px;
    border: 1.5px solid #d5d0c8;
    background: #f5f4f2;
    color: #8a8580;
    font-size: 0.72rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.25s ease;
    letter-spacing: 0.03em;
}

.dash-default-btn-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ccc;
    transition: background 0.25s ease;
}

.dash-default-btn.active {
    border-color: #1E6332;
    background: linear-gradient(135deg, #ecfdf5, #d1fae5);
    color: #1E6332;
}

.dash-default-btn.active .dash-default-btn-dot {
    background: #1E6332;
    box-shadow: 0 0 0 2px rgba(30, 99, 50, 0.2);
}

.dash-default-btn:hover {
    transform: scale(1.03);
}

/* Save row */
.dash-save-row {
    padding: 0.6rem 1rem;
    border-top: 1px solid #f0ede8;
}

.dash-save-btn {
    width: 100%;
    padding: 8px 16px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #1E6332, #28a745);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: -0.01em;
}

.dash-save-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(30, 99, 50, 0.3);
}

.dash-save-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Sortable widget list — drag & drop */
.dash-customize-sort-list {
    padding: 0.5rem 0;
}

.dash-sort-item {
    display: flex;
    align-items: center;
    padding: 0.55rem 1rem;
    border-bottom: 1px solid #f0ece6;
    transition: background 0.12s ease, box-shadow 0.15s ease;
    cursor: grab;
    user-select: none;
}

.dash-sort-item:last-child {
    border-bottom: none;
}

.dash-sort-item:hover {
    background: #faf9f7;
}

.dash-sort-item-left {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex: 1;
    min-width: 0;
}

.dash-sort-grip {
    color: #c0b8ae;
    font-size: 0.8rem;
    cursor: grab;
    padding: 2px 4px;
    transition: color 0.12s ease;
}

.dash-sort-item:hover .dash-sort-grip {
    color: #1E6332;
}

.dash-sort-toggle {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.8rem;
    color: #3d3a37;
    cursor: pointer;
}

.dash-sort-toggle input[type="checkbox"] {
    accent-color: #1E6332;
    width: 16px;
    height: 16px;
    cursor: pointer;
    flex-shrink: 0;
}

.dash-sort-toggle i {
    color: #8a8580;
    width: 16px;
    text-align: center;
    font-size: 0.75rem;
}

/* Column toggle (L / R) buttons */
.dash-sort-col-toggle {
    display: flex;
    gap: 0;
    margin-left: auto;
    flex-shrink: 0;
}

.dash-col-btn {
    padding: 2px 8px;
    font-size: 0.65rem;
    font-weight: 600;
    border: 1px solid #d5d0ca;
    background: #fff;
    color: #8a8580;
    cursor: pointer;
    transition: all 0.15s ease;
    line-height: 1.4;
}

.dash-col-btn:first-child {
    border-radius: 4px 0 0 4px;
}

.dash-col-btn:last-child {
    border-radius: 0 4px 4px 0;
    border-left: none;
}

.dash-col-btn.active {
    background: #1E6332;
    color: #fff;
    border-color: #1E6332;
}

.dash-col-btn:not(.active):hover {
    background: #f0faf4;
    border-color: #1E6332;
    color: #1E6332;
}

.dash-col-btn i {
    font-size: 0.55rem;
}

/* Drag visual feedback */
.dash-sort-dragging {
    opacity: 0.35;
    background: #f0faf4;
}

.dash-sort-drop-above {
    box-shadow: 0 -2.5px 0 0 #1E6332;
}

.dash-sort-drop-below {
    box-shadow: 0 2.5px 0 0 #1E6332;
}

/* Floating clone for touch drag */
.dash-sort-clone {
    position: fixed;
    z-index: 99999;
    pointer-events: none;
    background: #fff;
    border: 1.5px solid #1E6332;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(30, 99, 50, 0.18);
    opacity: 0.92;
    padding: 0.55rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}


/* ==================== Announcement Banners (persistent top strip) ==================== */
.ann-banner-strip {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
}

/* ── Banner card ── */
.ann-banner-item {
    display: flex;
    align-items: stretch;
    border-radius: 14px;
    background: var(--ann-banner-bg, linear-gradient(135deg, #f0fdf4 0%, #dcfce7 50%, #f0fdf4 100%));
    border: 2px solid var(--ann-banner-border, rgba(30, 99, 50, 0.2));
    cursor: pointer;
    transition: all 0.25s ease;
    overflow: hidden;
    position: relative;
    box-shadow: 0 2px 12px color-mix(in srgb, var(--ann-banner-color, #1E6332) 12%, transparent);
}
.ann-banner-item:hover {
    box-shadow: 0 6px 24px color-mix(in srgb, var(--ann-banner-color, #1E6332) 22%, transparent);
    border-color: var(--ann-banner-color, #1E6332);
    transform: translateY(-1px);
}
/* Animated shimmer border */
.ann-banner-item::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 16px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        transparent 40%,
        color-mix(in srgb, var(--ann-banner-color, #1E6332) 40%, transparent) 50%,
        transparent 60%,
        transparent 100%
    );
    background-size: 250% 100%;
    animation: annBannerShimmer 4s ease-in-out infinite;
    pointer-events: none;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    padding: 2px;
    opacity: 0.6;
}
@keyframes annBannerShimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
.ann-banner-item:hover::after {
    opacity: 0;
}

/* Left colored accent bar */
.ann-banner-accent {
    width: 6px;
    flex-shrink: 0;
    background: linear-gradient(to bottom, var(--ann-banner-color, #1E6332), color-mix(in srgb, var(--ann-banner-color, #1E6332) 70%, #000));
    border-radius: 14px 0 0 14px;
}

/* Main content: horizontal layout — icon | body | meta+chevron */
.ann-banner-content {
    flex: 1;
    min-width: 0;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 14px;
}

/* Icon circle with glow ring */
.ann-banner-megaphone {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--ann-banner-color, #1E6332);
    color: #fff;
    font-size: 15px;
    flex-shrink: 0;
    box-shadow:
        0 2px 8px color-mix(in srgb, var(--ann-banner-color, #1E6332) 30%, transparent),
        0 0 0 4px color-mix(in srgb, var(--ann-banner-color, #1E6332) 10%, transparent);
}

/* Body: title line + preview underneath */
.ann-banner-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* Top row inside body: title + category + priority */
.ann-banner-top {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.ann-banner-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: #1a1a1a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}

/* Category chip */
.ann-banner-cat {
    font-size: 0.6rem;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 6px;
    border: 1px solid;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    flex-shrink: 0;
}

/* Priority badge */
.ann-banner-pri {
    font-size: 0.58rem;
    font-weight: 800;
    padding: 2.5px 9px;
    border-radius: 6px;
    flex-shrink: 0;
    white-space: nowrap;
}
.ann-banner-pri.urgent {
    color: #fff;
    background: linear-gradient(135deg, #dc2626, #ef4444);
    animation: annBannerPulse 2s ease-in-out infinite;
}
.ann-banner-pri.important {
    color: #92400e;
    background: linear-gradient(135deg, #fde68a, #fcd34d);
}
@keyframes annBannerPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Preview text below title */
.ann-banner-preview {
    font-size: 0.8rem;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
    line-height: 1.3;
}

/* Right side: meta + ack + chevron */
.ann-banner-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.ann-banner-meta {
    font-size: 0.72rem;
    color: #9ca3af;
    white-space: nowrap;
}

/* Ack action chip */
.ann-banner-ack {
    font-size: 0.6rem;
    font-weight: 700;
    color: #0d9488;
    background: #f0fdfa;
    border: 1px solid #99f6e4;
    padding: 3px 10px;
    border-radius: 6px;
    white-space: nowrap;
    transition: all 0.15s;
}
.ann-banner-item:hover .ann-banner-ack {
    background: #ccfbf1;
}

/* Chevron */
.ann-banner-chevron {
    font-size: 12px;
    color: #b0b0b0;
    transition: transform 0.2s, color 0.2s;
}
.ann-banner-item:hover .ann-banner-chevron {
    color: var(--ann-banner-color, #1E6332);
    transform: translateX(3px);
}

/* ==================== Announcement Board ==================== */
/* ====== Global Announcements Board — Premium ====== */
/* Inline Announcement Trigger (inside welcome bar) */
.ann-inline-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(30, 99, 50, 0.08), rgba(30, 99, 50, 0.03));
    border: 1.5px solid rgba(30, 99, 50, 0.18);
    cursor: pointer;
    user-select: none;
    transition: all 0.2s ease;
    white-space: nowrap;
    animation: annTriggerPulse 2.5s ease-in-out infinite;
    box-shadow: 0 0 0 0 rgba(30, 99, 50, 0.15);
}
@keyframes annTriggerPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(30, 99, 50, 0.15); }
    50% { box-shadow: 0 0 0 6px rgba(30, 99, 50, 0); }
}
.ann-inline-trigger:hover {
    background: linear-gradient(135deg, rgba(30, 99, 50, 0.12), rgba(30, 99, 50, 0.06));
    border-color: rgba(30, 99, 50, 0.3);
    animation: none;
}
.ann-inline-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: linear-gradient(145deg, #1E6332, #28804a);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    flex-shrink: 0;
}
.ann-inline-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: #4a4540;
}
.ann-inline-chevron {
    color: #8a8580;
    font-size: 0.65rem;
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.ann-popover-anchor.expanded .ann-inline-chevron { transform: rotate(180deg); }

.ann-board-badge {
    background: linear-gradient(135deg, #dc2626, #ef4444);
    color: #fff;
    font-size: 0.6rem;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    line-height: 1.3;
}
.ann-board-badge.amber {
    background: linear-gradient(135deg, #d97706, #f59e0b);
}

/* Popover Anchor */
.ann-popover-anchor {
    position: relative;
}

/* Floating Popover */
.ann-popover {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 580px;
    background: #fff;
    border-radius: 14px;
    border: 1px solid rgba(30, 99, 50, 0.12);
    box-shadow: 0 12px 40px rgba(0,0,0,0.12), 0 2px 8px rgba(0,0,0,0.06);
    z-index: 1050;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.ann-popover-arrow {
    position: absolute;
    top: -7px;
    right: 48px;
    transform: rotate(45deg);
    width: 14px;
    height: 14px;
    background: #fff;
    border-left: 1px solid rgba(30, 99, 50, 0.12);
    border-top: 1px solid rgba(30, 99, 50, 0.12);
    z-index: 1;
}
.ann-popover-scroll {
    overscroll-behavior: contain;
}
.ann-popover-scroll::-webkit-scrollbar { width: 4px; }
.ann-popover-scroll::-webkit-scrollbar-track { background: transparent; }
.ann-popover-scroll::-webkit-scrollbar-thumb { background: #d5d0c8; border-radius: 2px; }

/* Compact cards inside popover */
.ann-popover .ann-card {
    border-radius: 10px;
    padding: 0.85rem 1rem;
    margin-bottom: 6px;
}
.ann-popover .ann-card:hover {
    transform: none;
}
.ann-popover .ann-feed {
    padding: 10px;
}
.ann-popover .ann-section-action {
    padding: 0 10px;
}
.ann-popover .ann-section-label {
    padding: 10px 10px 4px;
}

/* Sections */
.ann-section { padding: 0; }

.ann-section-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.7rem 1.75rem;
    color: #dc2626;
    background: linear-gradient(135deg, #fef2f2 0%, #fff5f5 50%, #fef8f8 100%);
    border-bottom: 1px solid #fecaca;
    position: relative;
}

.ann-section-label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(to bottom, #dc2626, #ef4444);
}

.ann-section-label i { font-size: 0.68rem; }

/* Feed */
.ann-feed {
    max-height: 650px;
    overflow-y: auto;
    padding: 0.65rem;
}

.ann-feed::-webkit-scrollbar { width: 5px; }
.ann-feed::-webkit-scrollbar-track { background: transparent; }
.ann-feed::-webkit-scrollbar-thumb { background: #d5d0c8; border-radius: 3px; }
.ann-feed::-webkit-scrollbar-thumb:hover { background: #1E6332; }

/* ── Individual Card — Premium Design ── */
.ann-card {
    position: relative;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 16px;
    padding: 1.15rem 1.35rem;
    margin-bottom: 0.6rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
}

.ann-card:last-child { margin-bottom: 0; }

.ann-card:hover {
    transform: translateY(-3px);
    box-shadow:
        0 8px 30px rgba(0, 0, 0, 0.08),
        0 2px 8px rgba(0, 0, 0, 0.04);
    border-color: color-mix(in srgb, var(--ann-cat-color, #1E6332) 35%, transparent);
}

/* Category color accent — left bar + subtle top gradient */
.ann-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(to bottom, var(--ann-cat-color, #1E6332), color-mix(in srgb, var(--ann-cat-color, #1E6332) 60%, #000));
    border-radius: 16px 0 0 16px;
    transition: width 0.2s ease;
}

.ann-card:hover::before {
    width: 5px;
}

.ann-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--ann-cat-color, #1E6332) 0%, color-mix(in srgb, var(--ann-cat-color, #1E6332) 40%, transparent) 50%, transparent 80%);
    opacity: 0.5;
}

/* Unseen highlight */
.ann-card.ann-unseen {
    background: linear-gradient(135deg, #f8fffe 0%, #f0fdf4 40%, #f6fef8 100%);
    border-color: rgba(30, 99, 50, 0.15);
    box-shadow: 0 2px 12px rgba(30, 99, 50, 0.06), inset 0 0 0 1px rgba(30, 99, 50, 0.04);
}

.ann-card.ann-unseen:hover {
    box-shadow: 0 8px 30px rgba(30, 99, 50, 0.12), inset 0 0 0 1px rgba(30, 99, 50, 0.06);
}

/* Urgent card */
.ann-card.ann-urgent {
    border-color: rgba(220, 38, 38, 0.15);
    background: linear-gradient(135deg, #fff 0%, #fef8f8 40%, #fff5f5 100%);
    box-shadow: 0 2px 12px rgba(220, 38, 38, 0.06);
}

.ann-card.ann-urgent::before {
    width: 5px;
    background: linear-gradient(to bottom, #dc2626, #b91c1c);
    animation: annUrgentPulse 2s ease-in-out infinite;
}

.ann-card.ann-urgent::after {
    background: linear-gradient(90deg, #dc2626 0%, rgba(220, 38, 38, 0.3) 40%, transparent 70%);
    opacity: 0.25;
}

@keyframes annUrgentPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* Staggered entrance animation */
.ann-card { animation: annCardSlideIn 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) both; }
.ann-card:nth-child(1) { animation-delay: 0ms; }
.ann-card:nth-child(2) { animation-delay: 60ms; }
.ann-card:nth-child(3) { animation-delay: 120ms; }
.ann-card:nth-child(4) { animation-delay: 180ms; }
.ann-card:nth-child(5) { animation-delay: 240ms; }
.ann-card:nth-child(6) { animation-delay: 300ms; }

@keyframes annCardSlideIn {
    from { opacity: 0; transform: translateY(16px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ── Card Layout ── */
.ann-card-layout {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

/* Category icon circle */
.ann-card-cat-icon {
    width: 44px;
    height: 44px;
    border-radius: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
    transition: all 0.25s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 0 2px 8px color-mix(in srgb, var(--ann-cat-color, #1E6332) 15%, transparent);
    position: relative;
}

.ann-card:hover .ann-card-cat-icon {
    transform: scale(1.1) rotate(-3deg);
    box-shadow: 0 4px 14px color-mix(in srgb, var(--ann-cat-color, #1E6332) 25%, transparent);
}

.ann-card-body {
    flex: 1;
    min-width: 0;
}

/* Top meta row */
.ann-card-meta {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    margin-bottom: 0.4rem;
    flex-wrap: wrap;
}

.ann-cat-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.63rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 3px 9px;
    border-radius: 6px;
    color: var(--ann-cat-color, #1E6332);
    background: var(--ann-cat-bg, #f0fdf4);
    border: 1px solid color-mix(in srgb, var(--ann-cat-color, #1E6332) 18%, transparent);
}

.ann-cat-chip i {
    font-size: 0.6rem;
}

.ann-priority-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.58rem;
    font-weight: 800;
    text-transform: uppercase;
    padding: 2.5px 8px;
    border-radius: 6px;
    letter-spacing: 0.05em;
}

.ann-priority-badge i { font-size: 0.58rem; }

.ann-priority-badge.priority-important {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #b45309;
    border: 1px solid rgba(180, 83, 9, 0.18);
    box-shadow: 0 1px 4px rgba(180, 83, 9, 0.1);
}

.ann-priority-badge.priority-urgent {
    background: linear-gradient(135deg, #fef2f2 0%, #fecaca 100%);
    color: #dc2626;
    border: 1px solid rgba(220, 38, 38, 0.18);
    animation: annUrgentPulse 2s ease-in-out infinite;
    box-shadow: 0 1px 4px rgba(220, 38, 38, 0.1);
}

.ann-new-badge {
    font-size: 0.54rem;
    font-weight: 800;
    text-transform: uppercase;
    padding: 2.5px 7px;
    border-radius: 6px;
    background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%);
    color: #16a34a;
    letter-spacing: 0.05em;
    box-shadow: 0 1px 4px rgba(22, 163, 74, 0.15);
}

.ann-card-time {
    font-size: 0.7rem;
    color: #aaa5a0;
    margin-left: auto;
    font-weight: 500;
}

/* Title */
.ann-card-title {
    font-weight: 800;
    font-size: 0.95rem;
    color: #1a1a1a;
    margin-bottom: 0.25rem;
    line-height: 1.35;
    letter-spacing: -0.01em;
}

/* Content preview */
.ann-card-content {
    font-size: 0.84rem;
    color: #555;
    line-height: 1.6;
    word-break: break-word;
}

/* Inline media thumbnail on card */
.ann-card-media-thumb {
    margin-top: 0.6rem;
    border-radius: 10px;
    overflow: hidden;
    max-height: 160px;
    position: relative;
}

.ann-card-media-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    max-height: 160px;
}

.ann-card-media-thumb::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 10px;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.06);
    pointer-events: none;
}

/* Rich content styles */
.ann-rich-content h1 { font-size: 1.15rem; font-weight: 700; margin: 0.3em 0; }
.ann-rich-content h2 { font-size: 1.05rem; font-weight: 700; margin: 0.3em 0; }
.ann-rich-content h3 { font-size: 0.95rem; font-weight: 700; margin: 0.3em 0; }
.ann-rich-content p { margin: 0 0 0.4em; }
.ann-rich-content img { max-width: 100%; border-radius: 10px; margin: 6px 0; }
.ann-rich-content video, .ann-rich-content iframe { max-width: 100%; border-radius: 10px; margin: 6px 0; }
.ann-rich-content a { color: #1E6332; text-decoration: underline; }
.ann-rich-content hr { border: none; border-top: 1px solid #e5e1da; margin: 0.6em 0; }
.ann-rich-content ul, .ann-rich-content ol { margin: 0 0 0.4em; padding-left: 1.3em; }
.ann-rich-content blockquote { border-left: 3px solid #1E6332; margin: 0.4em 0; padding: 0.3em 0.6em; background: #f0fdf4; border-radius: 0 8px 8px 0; }

/* Attachment chips */
.ann-card-attachments {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 0.55rem;
}

.ann-att-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.68rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 8px;
    background: #f8f9fa;
    color: #3d3a37;
    border: 1px solid #e5e7eb;
    cursor: pointer;
    transition: all 0.2s ease;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ann-att-chip:hover {
    background: #e8f5ee;
    border-color: #1E6332;
    color: #1E6332;
    transform: translateY(-2px);
    box-shadow: 0 3px 10px rgba(30, 99, 50, 0.12);
}

.ann-att-chip i {
    font-size: 0.72rem;
    flex-shrink: 0;
}

.ann-card-content.ann-collapsed {
    max-height: 3.5em;
    overflow: hidden;
    position: relative;
}

.ann-card-content.ann-collapsed::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1.5em;
    background: linear-gradient(transparent, #fff);
}

.ann-card.ann-unseen .ann-card-content.ann-collapsed::after {
    background: linear-gradient(transparent, #f6fef8);
}

.ann-read-more {
    font-size: 0.74rem;
    color: #1E6332;
    font-weight: 700;
    cursor: pointer;
    margin-top: 0.25rem;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.ann-read-more:hover { text-decoration: underline; }

/* Footer: author + ack + open */
.ann-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 0.75rem;
    padding-top: 0.6rem;
    border-top: 1px solid #f0ece6;
    gap: 0.5rem;
}

.ann-card-footer-left {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.ann-card-author {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.74rem;
    color: #8a8580;
    font-weight: 500;
}

.ann-card-author-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: linear-gradient(145deg, #C08B3E, #9a6b2e);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.52rem;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(192, 139, 62, 0.3);
}

.ann-card-att-count {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.68rem;
    color: #aaa5a0;
    font-weight: 500;
}

.ann-card-att-count i { font-size: 0.64rem; }

/* Open detail link */
.ann-card-open-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.74rem;
    font-weight: 700;
    color: #1E6332;
    opacity: 0;
    transition: opacity 0.25s, transform 0.25s;
    transform: translateX(-6px);
}

.ann-card:hover .ann-card-open-link {
    opacity: 1;
    transform: translateX(0);
}

.ann-card-open-link i {
    font-size: 0.62rem;
    transition: transform 0.2s;
}

.ann-card:hover .ann-card-open-link i {
    transform: translateX(2px);
}

/* Ack button on cards */
.ann-ack-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.95rem;
    border-radius: 9px;
    font-size: 0.74rem;
    font-weight: 700;
    cursor: pointer;
    border: 1.5px solid #1E6332;
    background: #fff;
    color: #1E6332;
    transition: all 0.25s ease;
    white-space: nowrap;
}

.ann-ack-btn:hover {
    background: linear-gradient(135deg, #1E6332, #2a8745);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(30, 99, 50, 0.3);
    border-color: transparent;
}

.ann-ack-btn:active { transform: translateY(0); }

.ann-ack-btn.ann-acked {
    border-color: #c8e6d0;
    color: #16a34a;
    background: linear-gradient(135deg, #f0fdf4, #dcfce7);
    cursor: default;
    pointer-events: none;
}

.ann-ack-btn.ann-acked i { color: #16a34a; }

.ann-ack-required-tag {
    font-size: 0.62rem;
    font-weight: 700;
    color: #dc2626;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* ── Announcement Detail Modal — Premium ── */
.ann-detail-overlay {
    position: fixed;
    inset: 0;
    z-index: 99998;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(12px) saturate(1.2);
    -webkit-backdrop-filter: blur(12px) saturate(1.2);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 24px;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.ann-detail-overlay.active { opacity: 1; }

.ann-detail-modal {
    background: #fff;
    border-radius: 24px;
    width: 100%;
    max-width: 740px;
    max-height: 88vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.1),
        0 24px 80px rgba(0, 0, 0, 0.3),
        0 8px 32px rgba(0, 0, 0, 0.15);
    transform: translateY(28px) scale(0.96);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.ann-detail-overlay.active .ann-detail-modal {
    transform: translateY(0) scale(1);
}

/* Modal header with category gradient */
.ann-detail-header {
    position: relative;
    padding: 32px 36px 24px;
    color: #fff;
    overflow: hidden;
    flex-shrink: 0;
}

.ann-detail-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 15% 85%, rgba(255,255,255,0.1) 0%, transparent 55%),
        radial-gradient(ellipse at 85% 15%, rgba(255,255,255,0.06) 0%, transparent 45%),
        radial-gradient(ellipse at 50% 50%, rgba(0,0,0,0.05) 0%, transparent 70%);
    pointer-events: none;
}

.ann-detail-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 5%, rgba(255,255,255,0.15) 50%, transparent 95%);
}

.ann-detail-close {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,0.12);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255,255,255,0.15);
    color: #fff;
    font-size: 0.88rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    z-index: 1;
}

.ann-detail-close:hover {
    background: rgba(255,255,255,0.25);
    transform: rotate(90deg);
}

.ann-detail-header-top {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
    position: relative;
}

.ann-detail-cat-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 0.74rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 5px 14px;
    border-radius: 9px;
    background: rgba(255,255,255,0.16);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255,255,255,0.12);
}

.ann-detail-cat-badge i { font-size: 0.78rem; }

.ann-detail-pri-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    padding: 4px 12px;
    border-radius: 7px;
    background: rgba(255,255,255,0.18);
    border: 1px solid rgba(255,255,255,0.1);
}

.ann-detail-pri-badge i { font-size: 0.7rem; }

.ann-detail-title {
    font-size: 1.4rem;
    font-weight: 800;
    line-height: 1.3;
    margin: 0;
    position: relative;
    letter-spacing: -0.02em;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.ann-detail-author-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
    font-size: 0.82rem;
    opacity: 0.9;
    position: relative;
}

.ann-detail-author-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    border: 1px solid rgba(255,255,255,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.64rem;
}

.ann-detail-time {
    margin-left: auto;
    font-size: 0.76rem;
    opacity: 0.7;
    font-weight: 500;
}

/* Modal body */
.ann-detail-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 32px 36px;
}

.ann-detail-body::-webkit-scrollbar { width: 5px; }
.ann-detail-body::-webkit-scrollbar-track { background: transparent; }
.ann-detail-body::-webkit-scrollbar-thumb { background: #d5d0c8; border-radius: 3px; }

/* Rich content in modal — full-size rendering */
.ann-detail-content { }

.ann-detail-content h1 { font-size: 1.5rem; font-weight: 800; margin: 0.5em 0 0.3em; color: #1a1a1a; letter-spacing: -0.02em; }
.ann-detail-content h2 { font-size: 1.25rem; font-weight: 700; margin: 0.5em 0 0.3em; color: #1a1a1a; }
.ann-detail-content h3 { font-size: 1.1rem; font-weight: 700; margin: 0.5em 0 0.3em; color: #1a1a1a; }
.ann-detail-content p { margin: 0 0 0.7em; font-size: 0.94rem; line-height: 1.75; color: #3d3a37; }
.ann-detail-content img { max-width: 100%; max-height: 420px; object-fit: contain; border-radius: 14px; margin: 14px 0; box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08); }
.ann-detail-content video, .ann-detail-content iframe { max-width: 100%; max-height: 420px; border-radius: 14px; margin: 14px 0; }
.ann-detail-content a { color: #1E6332; font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.ann-detail-content hr { border: none; border-top: 2px solid #eae6e0; margin: 1.2em 0; }
.ann-detail-content ul, .ann-detail-content ol { margin: 0 0 0.7em; padding-left: 1.5em; font-size: 0.94rem; line-height: 1.75; }
.ann-detail-content blockquote { border-left: 4px solid #1E6332; margin: 0.6em 0; padding: 0.6em 1.2em; background: linear-gradient(135deg, #f0fdf4, #f8fffe); border-radius: 0 12px 12px 0; font-style: italic; }

/* Attachments in modal */
.ann-detail-attachments {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid #eae6e0;
}

.ann-detail-att-label {
    font-size: 0.74rem;
    font-weight: 800;
    color: #8a8580;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.ann-detail-att-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 10px;
}

.ann-detail-att-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: #faf9f7;
    border: 1px solid #e5e1da;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.ann-detail-att-item:hover {
    background: linear-gradient(135deg, #f0fdf4, #f8fffe);
    border-color: #1E6332;
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(30, 99, 50, 0.1);
}

.ann-detail-att-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.ann-detail-att-icon.pdf   { background: linear-gradient(135deg, #fef2f2, #fecaca); color: #dc2626; }
.ann-detail-att-icon.image { background: linear-gradient(135deg, #f0fdf4, #bbf7d0); color: #22c55e; }
.ann-detail-att-icon.video { background: linear-gradient(135deg, #eff6ff, #bfdbfe); color: #3b82f6; }
.ann-detail-att-icon.doc   { background: linear-gradient(135deg, #eff6ff, #bfdbfe); color: #2563eb; }
.ann-detail-att-icon.other { background: linear-gradient(135deg, #f3f4f6, #e5e7eb); color: #6b7280; }

.ann-detail-att-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: #1a1a1a;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
    min-width: 0;
}

.ann-detail-att-size {
    font-size: 0.68rem;
    color: #b0a8a0;
    flex-shrink: 0;
    font-weight: 500;
}

/* Modal footer */
.ann-detail-footer {
    padding: 18px 36px;
    border-top: 1px solid #eae6e0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    background: linear-gradient(135deg, #faf9f7, #f5f4f2);
    flex-shrink: 0;
}

.ann-detail-ack-section {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ann-detail-ack-btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 11px 28px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(145deg, #1E6332 0%, #28804a 50%, #1E6332 100%);
    background-size: 200% 200%;
    color: #fff;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 16px rgba(30, 99, 50, 0.35);
}

.ann-detail-ack-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(30, 99, 50, 0.45);
    background-position: 100% 0;
}

.ann-detail-ack-btn.acked {
    background: linear-gradient(135deg, #d1e7dd, #bbf7d0);
    color: #1E6332;
    box-shadow: none;
    pointer-events: none;
}

.ann-detail-ack-label {
    font-size: 0.74rem;
    color: #dc2626;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Empty state */
.ann-empty {
    padding: 3.5rem 2rem;
    text-align: center;
}

.ann-empty-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(145deg, #f0fdf4, #dcfce7);
    color: #1E6332;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin: 0 auto 1rem;
    box-shadow: 0 4px 16px rgba(30, 99, 50, 0.12);
}

.ann-empty-title {
    font-weight: 800;
    font-size: 0.96rem;
    color: #1a1a1a;
    margin-bottom: 0.3rem;
    letter-spacing: -0.01em;
}

.ann-empty-text {
    font-size: 0.8rem;
    color: #8a8580;
}

/* Mobile detail modal */
@media (max-width: 768px) {
    .ann-detail-overlay {
        padding: 0 !important;
        align-items: stretch !important;
    }
    .ann-detail-modal {
        max-width: 100% !important;
        width: 100% !important;
        max-height: 100dvh !important;
        height: 100dvh !important;
        border-radius: 0 !important;
        margin: 0 !important;
    }
    .ann-detail-header {
        padding: 18px 16px 14px !important;
        min-height: auto !important;
    }
    .ann-detail-header::before,
    .ann-detail-header::after {
        display: none !important;
    }
    .ann-detail-close {
        top: 12px !important;
        right: 12px !important;
        width: 34px !important;
        height: 34px !important;
        font-size: 1rem !important;
    }
    .ann-detail-header-top {
        gap: 6px !important;
        margin-bottom: 6px !important;
    }
    .ann-detail-cat-badge {
        font-size: 0.65rem !important;
        padding: 3px 8px !important;
    }
    .ann-detail-pri-badge {
        font-size: 0.6rem !important;
        padding: 2px 7px !important;
    }
    .ann-detail-title {
        font-size: 1.05rem !important;
        margin: 4px 0 !important;
        padding-right: 36px !important;
    }
    .ann-detail-author-row {
        font-size: 0.75rem !important;
        gap: 6px !important;
        margin-top: 4px !important;
    }
    .ann-detail-body {
        padding: 16px !important;
        flex: 1 !important;
        min-height: 0 !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
        overscroll-behavior: contain !important;
    }
    .ann-detail-content p {
        font-size: 0.85rem !important;
        line-height: 1.65 !important;
    }
    .ann-detail-content h1 { font-size: 1.2rem !important; }
    .ann-detail-content h2 { font-size: 1.05rem !important; }
    .ann-detail-content h3 { font-size: 0.95rem !important; }
    .ann-detail-content img {
        max-height: 260px !important;
        border-radius: 10px !important;
    }
    .ann-detail-attachments {
        margin-top: 12px !important;
    }
    .ann-detail-att-grid {
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }
    .ann-detail-att-item {
        padding: 10px 12px !important;
    }
    .ann-detail-footer {
        padding: 12px 16px !important;
        padding-bottom: calc(12px + env(safe-area-inset-bottom)) !important;
    }
    .ann-detail-ack-btn {
        padding: 10px 20px !important;
        font-size: 0.8rem !important;
    }
}

/* Responsive compact banner */
@media (max-width: 992px) {
    .welcome-banner-compact {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }

    .welcome-main {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    .welcome-stats-inline {
        flex-wrap: wrap;
        justify-content: center;
    }

}

@media (max-width: 576px) {
    .stat-pill {
        padding: 0.3rem 0.6rem;
        font-size: 0.75rem;
    }

    .stat-pill .stat-number {
        font-size: 0.9rem;
    }

    .stat-pill .stat-label {
        font-size: 0.65rem;
    }
}

/* Dashboard Stats Row */
.dashboard-stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.dash-stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid #e9ecef;
}

.dash-stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
    border-color: #1E6332;
}

.dash-stat-card.highlight {
    background: linear-gradient(135deg, #1E6332 0%, #2F8542 100%);
    color: #fff;
    border: none;
}

.dash-stat-card.highlight:hover {
    box-shadow: 0 6px 25px rgba(30, 99, 50, 0.4);
}

.dash-stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.dash-stat-icon.green { background: #F4F0E9; color: #1E6332; }
.dash-stat-icon.blue { background: #cfe2ff; color: #0d6efd; }
.dash-stat-icon.orange { background: #fff3cd; color: #fd7e14; }
.dash-stat-icon.white { background: rgba(255,255,255,0.2); color: #fff; }

.dash-stat-info {
    flex: 1;
}

.dash-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
}

.dash-stat-label {
    font-size: 0.8rem;
    color: #6c757d;
    margin-top: 2px;
}

.dash-stat-card.highlight .dash-stat-label {
    color: rgba(255,255,255,0.85);
}

.dash-stat-trend {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 6px;
}

.dash-stat-trend.up {
    background: #F4F0E9;
    color: #1E6332;
}

.dash-stat-trend.down {
    background: #f8d7da;
    color: #dc3545;
}

.dash-stat-progress {
    width: 60px;
}

.mini-progress-bar {
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    overflow: hidden;
}

.mini-progress-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.3s ease;
}

.mini-progress-fill.orange { background: #fd7e14; }
.mini-progress-fill.green { background: #1E6332; }

.dash-stat-badge {
    font-size: 0.75rem;
    background: rgba(255,255,255,0.2);
    padding: 4px 10px;
    border-radius: 20px;
}

/* Main Dashboard Layout - 50/50 Split */
.dashboard-main-layout {
    display: flex;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
    align-items: flex-start;
}

.dashboard-left-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-width: 0;
}

.dashboard-right-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-width: 0;
}

.dashboard-left-bottom {
    display: flex;
    gap: 1rem;
    flex: none;
}

/* Left stack: Claims Overview + KPIs */
.dashboard-left-stack {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    flex: 1;
}

.dashboard-left-stack .claims-overview {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.dashboard-left-stack .claims-overview .dash-card-body {
    display: flex;
    flex-direction: column;
}

.dashboard-left-stack .claims-overview .mini-bar-chart {
    min-height: 150px;
    max-height: 180px;
}

/* ── Recent Messages Panel (below Claims Overview) ────────── */
.recent-messages-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.recent-messages-card .dash-card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.recent-messages-list {
    flex: 1;
    overflow-y: auto;
    min-height: 0;
}

.recent-msg-item {
    display: flex;
    align-items: center;
    padding: 0.7rem 1rem;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: background 0.15s ease;
    gap: 0.7rem;
    position: relative;
}

.recent-msg-item:hover {
    background: #f8fdf9;
}

.recent-msg-item:last-child {
    border-bottom: none;
}

.recent-msg-item.has-unread {
    background: #F4F0E9;
}

.recent-msg-item.has-unread:hover {
    background: #e5f5eb;
}

.msg-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.72rem;
    flex-shrink: 0;
    letter-spacing: 0.02em;
}

.msg-avatar.me {
    background: #dbeafe;
    color: #2563eb;
}

.msg-avatar.staff {
    background: #F4F0E9;
    color: #1E6332;
}

.recent-msg-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.recent-msg-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.recent-msg-claim {
    font-weight: 600;
    font-size: 0.8rem;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.recent-msg-time {
    font-size: 0.68rem;
    color: #9ca3af;
    white-space: nowrap;
    flex-shrink: 0;
}

.recent-msg-preview {
    font-size: 0.75rem;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.4;
}

.recent-msg-sender {
    font-weight: 600;
    color: #4b5563;
}

.recent-msg-text {
    color: #6b7280;
}

.msg-unread-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #1E6332;
    flex-shrink: 0;
}

.recent-msg-empty,
.recent-msg-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    color: #9ca3af;
    gap: 0.5rem;
}

.recent-msg-loading-spinner {
    width: 28px;
    height: 28px;
    border: 3px solid rgba(30, 99, 50, 0.2);
    border-top-color: #1E6332;
    border-radius: 50%;
    animation: progressSpin 0.8s linear infinite;
}

.recent-msg-loading span {
    font-size: 0.8rem;
    color: #1E6332;
}

.recent-msg-empty i {
    font-size: 1.5rem;
    opacity: 0.5;
}

.recent-msg-empty span {
    font-size: 0.8rem;
}

/* AI Insights + Recent Claims panels (column-agnostic — can be in either column) */
.dashboard-main-layout .smart-insights-panel {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.dashboard-main-layout .smart-insights-panel .smart-insights-list {
    flex: 1;
    overflow-y: auto;
    min-height: 0;
}

.dashboard-main-layout .recent-claims-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.dashboard-main-layout .recent-claims-card .dash-card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.dashboard-main-layout .recent-claims-card .recent-claims-list {
    flex: 1;
    overflow-y: auto;
    min-height: 0;
}

/* ========== Financial Ledger Style ========== */
.financial-ledger-wrapper {
    background: #fff;
    border-radius: 12px;
    padding: 1rem 1.25rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    border: 1px solid #e9ecef;
    flex: none;
    display: flex;
    flex-direction: column;
}

.financial-ledger-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid #f0f0f0;
}

.financial-ledger-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: #1f2937;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0;
}

.financial-ledger-title i {
    color: #1E6332;
}

.financial-ledger {
    max-width: 100%;
    font-size: 0.9rem;
}

.fl-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem 0;
    border-bottom: 1px dashed #e5e7eb;
}

.fl-label {
    color: #4b5563;
}

.fl-value {
    font-weight: 600;
    color: #1f2937;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    font-size: 1rem;
}

.fl-row.fl-subtract {
    color: #dc2626;
}

.fl-row.fl-subtract .fl-label {
    color: #9ca3af;
}

.fl-row.fl-subtract .fl-value {
    color: #dc2626;
}

.fl-row.fl-total {
    border-bottom: none;
    border-top: 1px solid #e5e7eb;
    margin-top: 0.35rem;
    padding-top: 0.75rem;
    font-weight: 600;
}

.fl-row.fl-total .fl-label {
    color: #1E6332;
    font-weight: 600;
}

.fl-row.fl-total .fl-value {
    color: #1E6332;
    font-size: 1.15rem;
}

/* Claims Overview inline (merged into the ledger wrapper) */
.claims-overview-inline {
    margin-top: 1rem;
    padding-top: 0.75rem;
    border-top: 2px solid #1E6332;
}

.claims-overview-inline .claims-overview-stats {
    margin-bottom: 0.75rem;
}

.claims-overview-inline .mini-bar-chart {
    min-height: 160px;
    max-height: 210px;
    margin-top: 0.75rem;
    padding-top: 1.25rem;
    border-top: 1px solid #f0f0f0;
    overflow: hidden;
}

/* Financial Summary Row (legacy - kept for compatibility) */
.financial-summary-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #fff 100%);
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
    border: 1px solid #e9ecef;
    width: 100%;
}

.financial-summary-card {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 0.8rem;
    background: #fff;
    border-radius: 8px;
    flex: 1;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
    border: 1px solid #e9ecef;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.financial-summary-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.financial-summary-card.gross {
    border-left: 3px solid #0d6efd;
}

.financial-summary-card.fees {
    border-left: 3px solid #fd7e14;
}

.financial-summary-card.net {
    border-left: 3px solid var(--eff-primary);
}

.financial-summary-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.financial-summary-card.gross .financial-summary-icon {
    background: rgba(13,110,253,0.1);
    color: #0d6efd;
}

.financial-summary-card.fees .financial-summary-icon {
    background: rgba(253,126,20,0.1);
    color: #fd7e14;
}

.financial-summary-card.net .financial-summary-icon {
    background: var(--eff-primary-light);
    color: var(--eff-primary);
}

.financial-summary-content {
    flex: 1;
    min-width: 0;
}

.financial-summary-value {
    font-size: 1rem;
    font-weight: 700;
    color: #212529;
    line-height: 1.2;
    white-space: nowrap;
}

.financial-summary-card.net .financial-summary-value {
    color: var(--eff-primary);
}

.financial-summary-label {
    font-size: 0.7rem;
    color: #495057;
    font-weight: 600;
}

.financial-summary-sublabel {
    font-size: 0.6rem;
    color: #6c757d;
    display: none;
}

.financial-summary-divider {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    color: #6c757d;
    flex-shrink: 0;
}

/* Smart Insights Panel - White/Green Branding */
.smart-insights-panel {
    flex: none;
    background: #fff;
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
    border: 1px solid #e9ecef;
    overflow: hidden;
}

.smart-insights-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #e9ecef;
    flex-shrink: 0;
}

.smart-insights-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: #1f2937;
    font-weight: 700;
    font-size: 1rem;
}

.smart-insights-title i {
    color: var(--eff-primary);
    font-size: 1.1rem;
}

.smart-insights-badge-wrapper {
    position: relative;
}

.smart-insights-badge {
    background: linear-gradient(135deg, var(--eff-primary), #2F8542);
    color: #fff;
    font-size: 0.55rem;
    font-weight: 700;
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.3s ease;
}

.smart-insights-badge:hover {
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(47, 133, 66, 0.4);
}

/* AI Tooltip */
.ai-tooltip {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 320px;
    background: linear-gradient(145deg, #1f2937 0%, #111827 100%);
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255,255,255,0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    overflow: hidden;
}

.ai-tooltip::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 12px;
    width: 16px;
    height: 16px;
    background: linear-gradient(135deg, #1f2937 50%, transparent 50%);
    transform: rotate(45deg);
    border-radius: 3px 0 0 0;
}

.smart-insights-badge-wrapper:hover .ai-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.ai-tooltip-header {
    background: linear-gradient(135deg, var(--eff-primary), #059669);
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #fff;
}

.ai-tooltip-header i {
    font-size: 1.5rem;
    animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% { opacity: 1; filter: drop-shadow(0 0 2px rgba(255,255,255,0.3)); }
    50% { opacity: 0.8; filter: drop-shadow(0 0 8px rgba(255,255,255,0.6)); }
}

.ai-tooltip-header span {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.ai-tooltip-body {
    padding: 1rem 1.25rem;
    color: #e5e7eb;
}

.ai-tooltip-intro {
    font-size: 0.8rem;
    line-height: 1.5;
    color: #9ca3af;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.ai-tooltip-section {
    margin-bottom: 0.875rem;
}

.ai-tooltip-section:last-of-type {
    margin-bottom: 0;
}

.ai-tooltip-section-title {
    font-size: 0.7rem;
    font-weight: 600;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ai-tooltip-section-title i {
    color: var(--eff-primary);
    font-size: 0.75rem;
}

.ai-tooltip-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ai-tooltip-section li {
    font-size: 0.7rem;
    color: #9ca3af;
    padding: 0.25rem 0;
    padding-left: 1rem;
    position: relative;
}

.ai-tooltip-section li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 4px;
    background: var(--eff-primary);
    border-radius: 50%;
}

.ai-tooltip-footer {
    margin-top: 1rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.65rem;
    color: #6b7280;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ai-tooltip-footer i {
    color: var(--eff-primary);
    animation: progressSpin 3s linear infinite;
}

/* Enhanced Insight Item Subtexts */
.smart-insight-subtext {
    font-size: 0.65rem;
    color: #6b7280;
    line-height: 1.4;
    margin-top: 0.2rem;
    margin-bottom: 0.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.smart-insight-subtext span {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.smart-insight-subtext i {
    font-size: 0.6rem;
    width: 12px;
    text-align: center;
    flex-shrink: 0;
}

.insight-docs-needed {
    color: #dc2626;
    font-weight: 500;
}

.insight-docs-needed i {
    color: #dc2626;
}

.insight-notary-warning {
    color: #f59e0b;
}

.insight-notary-warning i {
    color: #f59e0b;
}

.insight-waiting {
    color: #6b7280;
}

.insight-waiting i {
    color: #6b7280;
}

.insight-status {
    color: #f59e0b;
}

.insight-status i {
    color: #f59e0b;
}

.insight-signature {
    color: #7c3aed;
}

.insight-signature i {
    color: #7c3aed;
}

.insight-esign {
    color: var(--eff-primary);
}

.insight-esign i {
    color: var(--eff-primary);
}

.insight-wet-sign {
    color: #f59e0b;
}

.insight-wet-sign i {
    color: #f59e0b;
}

.insight-stage {
    color: #3b82f6;
}

.insight-stage i {
    color: #3b82f6;
}

.insight-estimate {
    color: var(--eff-primary);
}

.insight-estimate i {
    color: var(--eff-primary);
}

.insight-action-hint {
    color: var(--eff-primary);
    font-weight: 500;
    font-style: italic;
}

.insight-action-hint i {
    color: var(--eff-primary);
}

.smart-insights-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    overflow-y: auto;
    overflow-x: hidden;
    flex: 1;
    padding-right: 0.5rem;
}

/* Insight Category Groups */
.insight-category {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

/* Grid layout for action items — single column to fit compact panel */
.insight-category .insight-items-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.85rem;
}

.insight-items-grid .smart-insight-item {
    height: 100%;
    margin: 0;
}

/* insight-items-grid is already 1-column — no breakpoint override needed */

.insight-category-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #6b7280;
    padding: 0.5rem 0 0.25rem 0;
    margin-top: 0;
    border-bottom: 1px solid #e5e7eb;
}

.insight-category-header:first-child {
    margin-top: 0;
    padding-top: 0;
}

.insight-category-header i {
    font-size: 0.7rem;
}

.insight-category-header.action-needed {
    color: #dc2626;
    border-bottom-color: rgba(220, 38, 38, 0.2);
}

.insight-category-header.financial {
    color: var(--eff-primary);
    border-bottom-color: rgba(30, 99, 50, 0.2);
}

.insight-category-header.tips {
    color: #6b7280;
    border-bottom-color: #e5e7eb;
}

.smart-insight-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: #f9fafb;
    border-radius: 10px;
    border-left: 4px solid;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.smart-insight-item:hover {
    background: #f3f4f6;
    transform: translateX(2px);
}

.smart-insight-item.urgent {
    border-left-color: #ef4444;
    background: #fef2f2;
}

.smart-insight-item.warning {
    border-left-color: #f59e0b;
    background: #fffbeb;
}

.smart-insight-item.info {
    border-left-color: var(--eff-primary);
    background: var(--eff-primary-light);
}

.smart-insight-item.success {
    border-left-color: var(--eff-primary);
    background: var(--eff-primary-light);
}

.smart-insight-item.tip {
    border-left-color: #6b7280;
    background: #f9fafb;
}

.smart-insight-item.attention {
    border-left-color: #3b82f6;
    background: #eff6ff;
}

.smart-insight-icon {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    flex-shrink: 0;
}

.smart-insight-item.urgent .smart-insight-icon {
    background: rgba(239,68,68,0.15);
    color: #ef4444;
}

.smart-insight-item.warning .smart-insight-icon {
    background: rgba(245,158,11,0.15);
    color: #f59e0b;
}

.smart-insight-item.info .smart-insight-icon {
    background: rgba(47, 133, 66,0.15);
    color: var(--eff-primary);
}

.smart-insight-item.success .smart-insight-icon {
    background: rgba(47, 133, 66,0.15);
    color: var(--eff-primary);
}

.smart-insight-item.tip .smart-insight-icon {
    background: rgba(107,114,128,0.15);
    color: #6b7280;
}

.smart-insight-item.attention .smart-insight-icon {
    background: rgba(59,130,246,0.15);
    color: #3b82f6;
}

.smart-insight-content {
    flex: 1;
    min-width: 0;
}

.smart-insight-text {
    color: #374151;
    font-size: 0.8rem;
    line-height: 1.5;
    margin-bottom: 0.35rem;
}

.smart-insight-text strong {
    color: #1f2937;
    font-weight: 600;
}

.smart-insight-meta {
    font-size: 0.7rem;
    color: #9ca3af;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 0.25rem;
}

.smart-insight-action {
    color: var(--eff-primary);
    font-size: 0.7rem;
    text-decoration: none;
    cursor: pointer;
    font-weight: 600;
    padding: 0.2rem 0.5rem;
    background: rgba(30, 99, 50, 0.1);
    border-radius: 4px;
    transition: all 0.2s ease;
}

.smart-insight-action:hover {
    color: #fff;
    background: var(--eff-primary);
    text-decoration: none;
}

@media (max-width: 1200px) {
    .dashboard-main-layout {
        flex-direction: column;
    }
    .dashboard-left-column {
        flex: none;
        width: 100%;
    }
    .dashboard-right-column {
        flex: none;
        width: 100%;
    }
    .dashboard-left-bottom {
        flex-direction: column;
    }
    .dashboard-left-stack,
    .dashboard-right-stack {
        flex: none;
    }
    .financial-summary-divider {
        display: none;
    }
}

@media (max-width: 768px) {
    .financial-summary-row {
        flex-direction: column;
        align-items: stretch;
    }
    .financial-summary-card {
        max-width: none;
    }
    .smart-insights-list {
        flex-direction: column;
    }
    .smart-insight-item {
        flex: none;
    }
}

.dash-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    border: 1px solid #e9ecef;
    overflow: hidden;
}

.dash-card-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dash-card-header h5 {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #333;
}

.dash-card-header h5 i {
    color: #1E6332;
}

.view-all-link {
    font-size: 0.8rem;
    color: #1E6332;
    text-decoration: none;
    font-weight: 500;
}

.view-all-link:hover {
    text-decoration: underline;
}

.dash-card-body {
    padding: 1.25rem;
}

.dash-card-body.no-padding {
    padding: 0;
}

.dash-card-footer {
    padding: 0.75rem 1.25rem;
    border-top: 1px solid #f0f0f0;
    background: #fafbfc;
}

.dash-card-footer a {
    font-size: 0.8rem;
    color: #1E6332;
    text-decoration: none;
    font-weight: 500;
}

.dash-card-footer a:hover {
    text-decoration: underline;
}

.dash-period-select {
    font-size: 0.8rem;
    padding: 0.35rem 0.75rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background: #fff;
    color: #495057;
    cursor: pointer;
}

/* Claims Overview */
.claims-overview-stats {
    display: flex;
    justify-content: space-around;
    margin-bottom: 1.5rem;
    padding: 0.5rem 0;
}

.overview-stat {
    text-align: center;
}

.overview-stat-value {
    font-size: 2rem;
    font-weight: 700;
}

.overview-stat-label {
    font-size: 0.8rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 0.25rem;
}

.mini-bar-chart {
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    min-height: 200px;
    gap: 0;
    padding: 1.5rem 1rem 0.75rem 1rem;
    background:
        linear-gradient(to bottom, transparent 0%, rgba(30, 99, 50, 0.03) 100%),
        repeating-linear-gradient(
            to top,
            transparent,
            transparent 49px,
            rgba(0, 0, 0, 0.04) 49px,
            rgba(0, 0, 0, 0.04) 50px
        );
    border-radius: 12px;
    margin: 0 -0.5rem;
    position: relative;
}

.mini-bar-chart::before {
    content: '';
    position: absolute;
    bottom: 32px;
    left: 1rem;
    right: 1rem;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(30, 99, 50, 0.2), transparent);
}

.mini-bar-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    height: 100%;
    max-width: 90px;
    padding: 0 0.5rem;
}

.mini-bar-value {
    font-size: 0.9rem;
    font-weight: 700;
    color: #1E6332;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.9);
    padding: 2px 8px;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.mini-bar {
    width: 100%;
    max-width: 70px;
    background: linear-gradient(180deg, #1E6332 0%, #2F8542 50%, #18A74B 100%);
    border-radius: 8px 8px 0 0;
    min-height: 15px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    box-shadow: 0 -4px 12px rgba(30, 99, 50, 0.3);
    position: relative;
}

.mini-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(180deg, rgba(255,255,255,0.2) 0%, transparent 100%);
    border-radius: 8px 8px 0 0;
}

.mini-bar:hover {
    filter: brightness(1.1);
    transform: scaleY(1.05) translateY(-2px);
    box-shadow: 0 -6px 20px rgba(30, 99, 50, 0.4);
}

/* Highlight for the best/highest bar */
.mini-bar-wrapper.best-week .mini-bar {
    background: linear-gradient(180deg, #214A3E 0%, #1E6332 50%, #18A74B 100%);
    box-shadow: 0 -6px 20px rgba(30, 99, 50, 0.5);
}

.mini-bar-wrapper.best-week .mini-bar-value {
    background: linear-gradient(135deg, #1E6332, #18A74B);
    color: #fff;
    font-weight: 700;
}

.mini-bar-wrapper.best-week .mini-bar-label {
    color: #1E6332;
    font-weight: 600;
}

.mini-bar-label {
    font-size: 0.8rem;
    color: #4b5563;
    margin-top: 10px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    font-weight: 500;
}

/* Recent Claims List */
.recent-claims-list {
    max-height: none;
    overflow-y: auto;
}

.recent-claim-item {
    display: flex;
    align-items: flex-start;
    padding: 0.85rem 1.25rem;
    margin: 0 0.75rem;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: background 0.15s ease;
    gap: 0.85rem;
}

.recent-claim-item:hover {
    background: #f8fdf9;
}

.recent-claim-item:last-child {
    border-bottom: none;
}

.claim-avatar {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: #F4F0E9;
    color: #1E6332;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.8rem;
    flex-shrink: 0;
    margin-top: 2px;
}
.claim-avatar.claim-avatar-ic {
    background: #fff;
    border: 1px solid #e5e7eb;
    padding: 4px;
}
.claim-avatar.claim-avatar-ic img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.claim-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

/* Top row: claim name + amount */
.claim-item-top {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
}

.claim-name {
    font-weight: 600;
    font-size: 0.85rem;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.claim-item-top .claim-amount {
    font-weight: 700;
    font-size: 0.9rem;
    color: #1E6332;
    white-space: nowrap;
    flex-shrink: 0;
    margin-left: 0;
    padding-left: 0;
}

/* Detail rows with icons */
.claim-detail-rows {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.claim-detail-row {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    color: #6b7280;
    line-height: 1.3;
}

.claim-detail-row i {
    width: 12px;
    text-align: center;
    font-size: 0.6rem;
    color: #9ca3af;
    flex-shrink: 0;
}

.claim-detail-row span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Bottom row: date + status */
.claim-item-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-top: 0.1rem;
}

.claim-date {
    font-size: 0.68rem;
    color: #9ca3af;
}

.claim-date i {
    font-size: 0.6rem;
    margin-right: 0.2rem;
}

.claim-item-bottom .status-badge {
    font-size: 0.6rem;
    padding: 0.15rem 0.5rem;
    flex-shrink: 0;
}

/* Legacy (keep for compatibility) */
.claim-meta {
    font-size: 0.75rem;
    color: #6c757d;
    display: flex;
    gap: 0.75rem;
}

.claim-amount {
    font-weight: 700;
    font-size: 0.95rem;
    color: #1E6332;
    margin-left: auto;
    padding-left: 1rem;
}

.claim-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-left: 0.5rem;
}

.claim-status-dot.funded { background: #1E6332; }
.claim-status-dot.in-process { background: #f59e0b; }
.claim-status-dot.closed { background: #3b82f6; }
.claim-status-dot.withdrawn { background: #dc3545; }

/* Right Column */
.dash-right-column {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.attention-card .dash-card-header {
    background: #fff8e6;
}

.attention-card .dash-card-header h5 i {
    color: #fd7e14;
}

.attention-count {
    background: #fd7e14;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
}

.attention-list {
    max-height: 140px;
    overflow-y: auto;
}

.attention-item {
    display: flex;
    align-items: center;
    padding: 0.65rem 1.25rem;
    border-bottom: 1px solid #f5f5f5;
    cursor: pointer;
    transition: background 0.15s ease;
}

.attention-item:hover {
    background: #fffbf5;
}

.attention-item:last-child {
    border-bottom: none;
}

.attention-icon {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    margin-right: 0.75rem;
    flex-shrink: 0;
}

.attention-icon.doc { background: #fff3cd; color: #856404; }
.attention-icon.pending { background: #cfe2ff; color: #0d6efd; }
.attention-icon.urgent { background: #f8d7da; color: #dc3545; }

.attention-text {
    flex: 1;
    font-size: 0.8rem;
    color: #495057;
    line-height: 1.3;
}

.attention-text strong {
    color: #333;
}

/* Activity List */
.activity-list {
    max-height: 200px;
    overflow-y: auto;
}

.activity-item-new {
    display: flex;
    align-items: flex-start;
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid #f5f5f5;
}

.activity-item-new:last-child {
    border-bottom: none;
}

.activity-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 0.75rem;
    margin-top: 4px;
    flex-shrink: 0;
}

.activity-dot.success { background: #1E6332; }
.activity-dot.info { background: #0dcaf0; }
.activity-dot.warning { background: #fd7e14; }
.activity-dot.danger { background: #dc3545; }

.activity-content-new {
    flex: 1;
}

.activity-title {
    font-size: 0.8rem;
    color: #333;
    margin-bottom: 2px;
}

.activity-time-new {
    font-size: 0.7rem;
    color: #adb5bd;
}

/* (Bottom Stats Row — removed, KPIs moved to top stats row) */

/* Responsive Dashboard */
@media (max-width: 1200px) {
    .dashboard-grid {
        grid-template-columns: 1fr 1fr;
    }
    .dash-right-column {
        grid-column: span 2;
        flex-direction: row;
    }
    .dash-right-column .dash-card {
        flex: 1;
    }
}

@media (max-width: 992px) {
    .dashboard-stats-row {
        grid-template-columns: repeat(2, 1fr);
    }
    .dashboard-bottom-row {
        grid-template-columns: repeat(2, 1fr);
    }
    .welcome-banner-enhanced {
        flex-direction: column;
        gap: 1.25rem;
        text-align: center;
    }
    .welcome-summary {
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    .dash-right-column {
        flex-direction: column;
        grid-column: span 1;
    }
    .welcome-actions-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Documents Needed Header Button - Grid Version - RED for urgency */
.welcome-actions-grid .docs-header-btn {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.85rem 1.25rem;
    background: rgba(220, 38, 38, 0.35);
    border: 1px solid rgba(220, 38, 38, 0.5);
    border-radius: 10px;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 100px;
}

.welcome-actions-grid .docs-header-btn i {
    font-size: 1.1rem;
}

.welcome-actions-grid .docs-header-btn:hover {
    background: rgba(220, 38, 38, 0.5);
    transform: translateY(-2px);
}

.welcome-actions-grid .docs-header-btn .docs-count {
    position: absolute;
    top: -6px;
    right: -6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: #fff;
    color: #dc2626;
    font-size: 0.65rem;
    font-weight: 700;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Legacy Documents Button - RED for urgency */
.docs-header-btn {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 0.5rem;
    color: #fff;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.docs-header-btn:hover {
    background: rgba(255,255,255,0.25);
}

.docs-header-btn.has-docs {
    background: rgba(220, 38, 38, 0.4);
    border-color: rgba(220, 38, 38, 0.6);
}

.docs-header-btn.has-docs:hover {
    background: rgba(220, 38, 38, 0.55);
}

.docs-header-btn .docs-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 0.4rem;
    background: #fff;
    color: #dc2626;
    font-size: 0.7rem;
    font-weight: 700;
    border-radius: 1rem;
}

.docs-header-btn.no-docs .docs-count {
    background: #18A74B;
    color: #fff;
}

.docs-header-btn.no-docs .docs-count::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

/* Pulse Animation - RED */
.docs-header-btn.has-docs::before {
    content: '';
    position: absolute;
    top: -3px;
    right: -3px;
    width: 12px;
    height: 12px;
    background: #ef4444;
    border-radius: 50%;
    animation: docsPulse 1.5s ease-in-out infinite;
}

@keyframes docsPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7);
    }
    50% {
        transform: scale(1.3);
        opacity: 0.8;
        box-shadow: 0 0 0 10px rgba(239, 68, 68, 0);
    }
}

/* Documents Dropdown Popup */
.docs-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 360px;
    background: #fff;
    border-radius: 0.75rem;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.25s ease;
    color: #333;
}

/* Dropdown in welcome grid - position to the left */
.welcome-actions-grid .docs-dropdown {
    right: auto;
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
}

.welcome-actions-grid .docs-dropdown.show {
    transform: translateX(-50%) translateY(0);
}

.docs-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.docs-dropdown::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 20px;
    width: 16px;
    height: 16px;
    background: #fff;
    transform: rotate(45deg);
    border-top: 1px solid #e2e8f0;
    border-left: 1px solid #e2e8f0;
}

.docs-dropdown-header {
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    border-radius: 0.75rem 0.75rem 0 0;
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.docs-dropdown-header.no-docs {
    background: linear-gradient(135deg, #18A74B 0%, #2F8542 100%);
}

.docs-dropdown-header h6 {
    margin: 0;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.docs-dropdown-close {
    width: 28px;
    height: 28px;
    border: none;
    background: rgba(255,255,255,0.2);
    border-radius: 0.375rem;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.docs-dropdown-close:hover {
    background: rgba(255,255,255,0.3);
}

.docs-dropdown-body {
    max-height: 320px;
    overflow-y: auto;
}

.docs-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
    transition: all 0.15s ease;
}

.docs-dropdown-item:hover {
    background: #fffbeb;
}

.docs-dropdown-item:last-child {
    border-bottom: none;
}

.docs-item-priority {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.docs-item-priority.urgent { background: #ef4444; }
.docs-item-priority.high { background: #f59e0b; }
.docs-item-priority.medium { background: #3b82f6; }
.docs-item-priority.low { background: #18A74B; }

.docs-item-content {
    flex: 1;
    min-width: 0;
}

.docs-item-name {
    font-weight: 600;
    color: #1f2937;
    font-size: 0.875rem;
}

.docs-item-meta {
    font-size: 0.75rem;
    color: #6b7280;
    margin-top: 0.125rem;
}

.docs-item-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}

.docs-item-claim {
    font-size: 0.7rem;
    color: #6b7280;
    background: #f3f4f6;
    padding: 2px 6px;
    border-radius: 4px;
}

.docs-required-section {
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-radius: 6px;
    padding: 8px 10px;
    margin-top: 4px;
}

.docs-required-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: #92400e;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.docs-required-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 0;
    font-size: 0.8rem;
    color: #1f2937;
    border-bottom: 1px dashed #fcd34d;
}

.docs-required-item:last-child {
    border-bottom: none;
}

.docs-required-item i {
    color: #f59e0b;
    font-size: 0.75rem;
}

/* Document Request Banner for Claim Detail */
.docs-request-banner {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 1px solid #fbbf24;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 16px;
    display: none;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.15);
}

.docs-request-banner.show {
    display: block;
}

.docs-request-banner-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(245, 158, 11, 0.2);
}

.docs-request-banner-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.docs-request-banner-title {
    font-weight: 700;
    color: #92400e;
    font-size: 1rem;
}

.docs-request-banner-subtitle {
    font-size: 0.8rem;
    color: #b45309;
    margin-top: 2px;
}

.docs-request-list {
    background: #fff;
    border-radius: 10px;
    padding: 4px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.docs-request-list-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: #fffbeb;
    border-radius: 8px;
    border: 1px solid #fef3c7;
    transition: all 0.2s ease;
}

.docs-request-list-item:hover {
    background: #fef3c7;
}

.docs-request-list-item-icon {
    width: 28px;
    height: 28px;
    background: #fef3c7;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.docs-request-list-item-icon i {
    font-size: 0.8rem;
    color: #f59e0b;
}

.docs-request-list-item-content {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
    min-width: 0;
}

.docs-request-list-item-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: #1f2937;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.docs-request-list-item-content .doc-status-badge {
    align-self: flex-start;
}

/* Status badges for document items */
.doc-status-badge {
    font-size: 0.55rem;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    white-space: nowrap;
    flex-shrink: 0;
}

.doc-status-badge.pending {
    background: #fef3c7;
    color: #d97706;
    border: 1px solid #fde68a;
}

.doc-status-badge.missing {
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.docs-request-list-item button.upload-doc-btn {
    padding: 5px 10px;
    font-size: 0.7rem;
    font-weight: 600;
    background: linear-gradient(135deg, var(--eff-primary) 0%, #2F8542 100%);
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.docs-request-list-item button.upload-doc-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(47, 133, 66, 0.3);
}

.docs-request-list-item button.upload-doc-btn i {
    font-size: 0.7rem;
}

.docs-item-actions {
    display: flex;
    gap: 0.375rem;
}

.docs-item-btn {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 0.375rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
    font-size: 0.85rem;
}

.docs-item-btn.upload {
    background: #F4F0E9;
    color: #2F8542;
}

.docs-item-btn.upload:hover {
    background: #2F8542;
    color: #fff;
}

.docs-item-btn.info {
    background: #e0f2fe;
    color: #0284c7;
}

.docs-item-btn.info:hover {
    background: #0284c7;
    color: #fff;
}

.docs-dropdown-footer {
    padding: 0.75rem 1.25rem;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    border-radius: 0 0 0.75rem 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.docs-dropdown-footer .help-text {
    font-size: 0.75rem;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.docs-dropdown-footer .help-text i {
    color: #1E6332;
}

/* No Documents Message */
.docs-no-items {
    padding: 2rem 1.5rem;
    text-align: center;
}

.docs-no-items i {
    font-size: 2.5rem;
    color: #18A74B;
    margin-bottom: 0.75rem;
}

.docs-no-items h6 {
    margin: 0 0 0.25rem 0;
    color: #1f2937;
    font-weight: 600;
}

.docs-no-items p {
    margin: 0;
    font-size: 0.85rem;
    color: #6b7280;
}

/* ==================== DASHBOARD LOADING INDICATORS ==================== */
/* Inline spinner next to KPI values while historical data loads */
.dash-loading-spinner {
    display: inline-block;
    width: 12px;
    height: 12px;
    border: 2px solid rgba(30, 99, 50,0.2);
    border-top-color: #1E6332;
    border-radius: 50%;
    animation: progressSpin 0.8s linear infinite;
    margin-left: 6px;
    vertical-align: middle;
}

/* Subtle shimmer underline on partial KPI values */
.dash-partial-indicator {
    position: relative;
}
.dash-partial-indicator::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #1E6332, transparent);
    background-size: 200% 100%;
    animation: dashShimmer 1.8s ease-in-out infinite;
    border-radius: 1px;
}
@keyframes dashShimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* "Loading historical claims..." label below financial section */
.financial-loading-label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 0 4px;
    font-size: 12px;
    color: #1E6332;
    font-weight: 500;
}
.financial-loading-label .dash-loading-spinner {
    margin-left: 0;
}

/* ==================== MANDATORY ACK MODAL OVERLAY ==================== */
.ann-ack-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(12px) saturate(1.2);
    -webkit-backdrop-filter: blur(12px) saturate(1.2);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.35s ease;
    padding: 24px;
}

.ann-ack-overlay.active {
    opacity: 1;
}

.ann-ack-modal {
    background: #fff;
    border-radius: 24px;
    width: fit-content;
    min-width: 480px;
    max-width: 80vw;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.08),
        0 24px 80px rgba(0, 0, 0, 0.35),
        0 8px 32px rgba(0, 0, 0, 0.15);
    transform: translateY(30px) scale(0.95);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    overflow: hidden;
}

.ann-ack-overlay.active .ann-ack-modal {
    transform: translateY(0) scale(1);
}

.ann-ack-modal-header {
    background: linear-gradient(145deg, #1E6332 0%, #28804a 40%, #1a5a2c 100%);
    color: #fff;
    padding: 40px 44px 34px;
    text-align: center;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.ann-ack-modal-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 15% 85%, rgba(255,255,255,0.1) 0%, transparent 55%),
        radial-gradient(ellipse at 85% 15%, rgba(255,255,255,0.06) 0%, transparent 45%),
        radial-gradient(ellipse at 50% 50%, rgba(0,0,0,0.04) 0%, transparent 70%);
    pointer-events: none;
}

.ann-ack-modal-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 5%, rgba(255,255,255,0.12) 50%, transparent 95%);
}

.ann-ack-modal-icon {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
    font-size: 1.85rem;
    animation: annAckBellPulse 2.5s ease-in-out infinite;
}

@keyframes annAckBellPulse {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(255,255,255,0.3); }
    50% { transform: scale(1.08); box-shadow: 0 0 0 14px rgba(255,255,255,0); }
}

.ann-ack-modal-header h3 {
    margin: 0 0 10px;
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.01em;
}

.ann-ack-modal-header p {
    margin: 0;
    font-size: 0.95rem;
    opacity: 0.85;
    font-weight: 400;
}

.ann-ack-modal-body {
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 28px 36px 34px;
    display: flex;
    flex-direction: column;
    gap: 22px;
    min-height: 0;
}

.ann-ack-modal-body::-webkit-scrollbar { width: 5px; }
.ann-ack-modal-body::-webkit-scrollbar-track { background: transparent; }
.ann-ack-modal-body::-webkit-scrollbar-thumb { background: #d5d0c8; border-radius: 3px; }

.ann-ack-modal-card {
    border: 1.5px solid rgba(0, 0, 0, 0.06);
    border-radius: 16px;
    padding: 0;
    background: #fff;
    transition: all 0.4s ease;
    position: relative;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.ann-ack-modal-card-header {
    background: linear-gradient(145deg, #1E6332 0%, #28804a 40%, #1a5a2c 100%);
    padding: 20px 24px 18px;
    flex-shrink: 0;
}

.ann-ack-modal-card.acked {
    opacity: 0.45;
    border-color: rgba(30, 99, 50, 0.15);
    background: linear-gradient(135deg, #f0fdf4, #f8fffe);
    transform: scale(0.97);
}

.ann-ack-modal-card.acked::after {
    content: '\f058';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    top: 16px;
    right: 18px;
    font-size: 1.4rem;
    color: #1E6332;
    opacity: 0.6;
}

.ann-ack-modal-card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.ann-ack-modal-time {
    font-size: 0.74rem;
    color: rgba(255, 255, 255, 0.7);
    margin-left: auto;
    font-weight: 500;
}

.ann-ack-modal-title {
    font-size: 1.2rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 0;
    line-height: 1.35;
    letter-spacing: -0.01em;
}

.ann-ack-modal-content {
    font-size: 0.95rem;
    color: #4a4540;
    line-height: 1.65;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 22px 24px 0;
    margin-bottom: 0;
}

.ann-ack-modal-content img,
.ann-ack-modal-content video,
.ann-ack-modal-content iframe {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

.ann-ack-modal-content::-webkit-scrollbar {
    width: 4px;
}

.ann-ack-modal-content::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

.ann-ack-modal-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 24px 18px;
    border-top: 1px solid #f0ece6;
    gap: 14px;
    flex-shrink: 0;
    margin-top: auto;
}

.ann-ack-modal-author {
    font-size: 0.85rem;
    color: #8a8580;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
}

.ann-ack-modal-author i {
    font-size: 0.88rem;
    color: #1E6332;
}

.ann-ack-modal-btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 12px 32px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(145deg, #1E6332 0%, #28804a 50%, #1E6332 100%);
    background-size: 200% 200%;
    color: #fff;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    box-shadow: 0 4px 14px rgba(30, 99, 50, 0.3);
}

.ann-ack-modal-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(30, 99, 50, 0.4);
    background-position: 100% 0;
}

.ann-ack-modal-btn:active {
    transform: translateY(0);
}

.ann-ack-modal-btn.acked {
    background: linear-gradient(135deg, #d1e7dd, #bbf7d0);
    color: #1E6332;
    box-shadow: none;
    cursor: default;
    pointer-events: none;
}

.ann-ack-modal-btn i {
    font-size: 0.92rem;
}

/* Mobile ack modal */
@media (max-width: 768px) {
    .ann-ack-overlay {
        padding: 0;
        align-items: flex-end;
    }

    .ann-ack-modal {
        width: 100%;
        min-width: 0;
        max-width: 100%;
        max-height: 85vh;
        border-radius: 24px 24px 0 0;
    }

    .ann-ack-modal-header {
        padding: 24px 22px 20px;
    }

    .ann-ack-modal-icon {
        width: 52px;
        height: 52px;
        font-size: 1.25rem;
        margin-bottom: 12px;
    }

    .ann-ack-modal-header h3 {
        font-size: 1.15rem;
    }

    .ann-ack-modal-body {
        padding: 18px;
        gap: 14px;
    }

    .ann-ack-modal-card {
        padding: 0;
    }

    .ann-ack-modal-card-footer {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .ann-ack-modal-btn {
        justify-content: center;
        padding: 13px;
        font-size: 0.88rem;
    }
}
