/* ============================================
   CENTRO DE CONTROLE - DESIGN V2
   Modern, Clean, TDAH-Friendly
   ============================================ */

/* CSS Variables - Premium Dark Theme (Banco Tradicao Design System) */
:root {
    /* Backgrounds - Warmer/bluer dark tones */
    --bg-primary: #0f0f1a;
    --bg-secondary: #1a1a2e;
    --bg-card: rgba(255, 255, 255, 0.03);
    --bg-card-hover: rgba(255, 255, 255, 0.06);
    --bg-glass: rgba(255, 255, 255, 0.03);
    --bg-glass-hover: rgba(255, 255, 255, 0.06);
    
    /* Text - Named colors for consistency */
    --text-primary: #ffffff;
    --text-secondary: #a0aec0;
    --text-muted: #7d8da0;
    
    /* Accent Colors - Rich palette */
    --accent-primary: #6366f1;
    --accent-secondary: #8b5cf6;
    --accent-cyan: #00d4ff;
    --accent-pink: #ec4899;
    --accent-orange: #f59e0b;
    --accent-green: #10b981;
    --accent-red: #ef4444;
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    --gradient-success: linear-gradient(135deg, #10b981 0%, #34d399 100%);
    --gradient-warning: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
    --gradient-danger: linear-gradient(135deg, #ef4444 0%, #f87171 100%);
    --gradient-info: linear-gradient(135deg, #3b82f6 0%, #60a5fa 100%);
    
    /* Border */
    --border-color: rgba(255, 255, 255, 0.08);
    
    /* Status Colors */
    --status-todo: #ef4444;
    --status-doing: #f59e0b;
    --status-done: #10b981;
    
    /* Glow Effects */
    --glow-primary: 0 0 20px rgba(99, 102, 241, 0.3);
    --glow-success: 0 0 20px rgba(16, 185, 129, 0.3);
    --glow-warning: 0 0 20px rgba(245, 158, 11, 0.3);
    --glow-danger: 0 0 20px rgba(239, 68, 68, 0.3);
    
    /* Spacing */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;
    
    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    
    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 4px 24px rgba(99, 102, 241, 0.15);
    
    /* Font */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    
    /* Transitions */
    --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================
   RESET & BASE
   ============================================ */

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

/* Focus states for keyboard accessibility */
:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
}

:focus:not(:focus-visible) {
    outline: none;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-family);
    background: var(--bg-primary);
    background-image: 
        radial-gradient(ellipse at top, rgba(99, 102, 241, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(139, 92, 246, 0.08) 0%, transparent 50%);
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    padding-bottom: 100px;
}

/* ============================================
   HEADER
   ============================================ */

.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: var(--spacing-md) var(--spacing-lg);
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.header-date {
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-family: var(--font-mono);
    padding: var(--spacing-xs) var(--spacing-md);
    background: var(--bg-glass);
    border-radius: var(--radius-full);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Header Navigation */
.header-nav {
    display: none;
}

@media (min-width: 768px) {
    .header-nav {
        display: flex;
        gap: var(--spacing-xs);
        align-items: center;
    }
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    padding: var(--spacing-xs) var(--spacing-md);
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    white-space: nowrap;
}

.nav-link:hover {
    color: var(--text-primary);
    background: var(--bg-glass-hover);
}

.nav-link.active {
    color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.1);
}

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

/* Sync Dropdown */
.sync-dropdown-wrapper {
    position: relative;
}

.sync-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 260px;
    background: #1a1a25;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    z-index: 200;
    overflow: hidden;
}

.sync-dropdown.open {
    display: block;
}

.sync-dropdown-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 12px 16px;
    cursor: pointer;
    transition: background var(--transition-fast);
    color: var(--text-primary);
    font-size: 0.875rem;
}

.sync-dropdown-item:hover {
    background: var(--bg-glass-hover);
}

.sync-dropdown-item small {
    color: var(--text-muted);
    font-size: 0.75rem;
}

.sync-dropdown-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.06);
}

.sync-dropdown-label {
    padding: 8px 16px 4px;
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    font-weight: 600;
}

.sync-source {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
}

.sync-source-icon {
    flex-shrink: 0;
    width: 20px;
    text-align: center;
}

.sync-source-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sync-source-info span {
    font-size: 0.82rem;
    color: var(--text-primary);
}

.sync-ts {
    font-size: 0.68rem;
    color: var(--text-muted);
}

.sync-source-badge {
    flex-shrink: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
}

.sync-source-badge.ok {
    background: var(--accent-green);
    box-shadow: 0 0 6px var(--accent-green);
}

.sync-source-badge.stale {
    background: var(--accent-orange);
    box-shadow: 0 0 6px var(--accent-orange);
}

.sync-source-badge.error {
    background: var(--accent-red);
    box-shadow: 0 0 6px var(--accent-red);
}

.sync-source-badge.never {
    background: rgba(255,255,255,0.15);
}

.sync-dropdown-status {
    padding: 10px 16px;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.sync-status-row {
    display: flex;
    justify-content: space-between;
    padding: 3px 0;
    color: var(--text-secondary);
    font-size: 0.75rem;
}

.sync-status-row.not-synced {
    color: var(--text-muted);
}

.sync-status-row.not-synced span:last-child {
    color: #fbbf24;
}

/* Syncing animation */
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.btn-icon.syncing span {
    display: inline-block;
    animation: spin 1s linear infinite;
}

/* Hero Bar (compact) */
.hero-bar {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    padding: var(--spacing-lg);
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(139, 92, 246, 0.04));
    border: 1px solid rgba(99, 102, 241, 0.15);
    border-radius: var(--radius-lg);
}

@media (min-width: 768px) {
    .hero-bar {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

.hero-bar-left {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.hero-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 1.5rem;
    }
}

.hero-summary {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.hero-bar-right {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    align-items: flex-start;
}

@media (min-width: 768px) {
    .hero-bar-right {
        flex-direction: row;
        align-items: center;
        gap: var(--spacing-md);
    }
}

.hero-actions {
    display: flex;
    gap: var(--spacing-sm);
}

/* Desktop Header Navigation */
.header-nav {
    display: none;
    gap: var(--spacing-xs);
}

@media (min-width: 768px) {
    .header-nav {
        display: flex;
    }
}

.header-nav-item {
    padding: var(--spacing-sm) var(--spacing-md);
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.header-nav-item:hover {
    color: var(--text-primary);
    background: var(--bg-glass);
}

.header-nav-item.active {
    color: var(--text-primary);
    background: var(--gradient-primary);
}

/* ============================================
   PROJECTS BAR - Quick Access
   ============================================ */

.projects-bar {
    display: flex;
    gap: 10px;
    padding: 12px 16px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.projects-bar::-webkit-scrollbar {
    display: none;
}

.project-chip {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--bg-glass);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
    font-size: 13px;
    color: var(--text-secondary);
}

.project-chip:hover {
    background: var(--bg-glass-hover);
    border-color: var(--accent-primary);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.project-chip .chip-icon {
    font-size: 14px;
}

.project-chip .chip-name {
    font-weight: 500;
}

.project-chip.priority-high {
    border-color: rgba(239, 68, 68, 0.3);
}

.project-chip.priority-high:hover {
    border-color: #ef4444;
    box-shadow: 0 0 12px rgba(239, 68, 68, 0.2);
}

.project-chip-add {
    background: transparent;
    border: 1px dashed rgba(255, 255, 255, 0.2);
    color: var(--text-muted);
}

.project-chip-add:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

/* Project chips - Desktop improvements */
@media (min-width: 768px) {
    .projects-bar {
        padding: 16px 24px;
        gap: 12px;
        flex-wrap: wrap;
        justify-content: flex-start;
    }
    
    .project-chip {
        padding: 10px 18px;
        font-size: 14px;
        min-width: auto;
    }
    
    .project-chip .chip-icon {
        font-size: 16px;
    }
    
    .project-chip .chip-name {
        max-width: 200px;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

/* ============================================
   MAIN CONTENT
   ============================================ */

.main-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: var(--spacing-lg);
    display: grid;
    gap: var(--spacing-lg);
}

/* Dashboard page: hero, offline, sidebar-layout must span all columns of .main-content */
.dashboard-page .hero-bar,
.dashboard-page .offline-banner,
.dashboard-page .dashboard-with-sidebar,
.dashboard-page .life-os-mobile {
    grid-column: 1 / -1;
}

@media (min-width: 768px) {
    .main-content {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .card-kanban {
        grid-column: span 2;
    }
}

@media (min-width: 1200px) {
    .main-content {
        grid-template-columns: repeat(3, 1fr);
        max-width: 1400px;
        padding: var(--spacing-xl);
    }
    
    .card-kanban {
        grid-column: span 3;
    }
    
    .header-content {
        max-width: 1400px;
    }
}

/* Extra Large Desktop (1600px+) */
@media (min-width: 1600px) {
    .main-content {
        padding: var(--spacing-2xl);
        gap: var(--spacing-xl);
    }
    
    .card {
        padding: var(--spacing-lg);
    }
    
    .card-header {
        padding: var(--spacing-xl);
    }
    
    .card-body {
        padding: var(--spacing-xl);
    }
    
    .stat-number {
        font-size: 3rem;
    }
    
    .stat-label {
        font-size: 0.875rem;
    }
}

/* Ultra Wide (1920px+) */
@media (min-width: 1920px) {
    .main-content {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .card-kanban {
        grid-column: span 3;
    }
    
    .kanban-board {
        gap: var(--spacing-xl);
    }
    
    .task-card {
        padding: var(--spacing-lg);
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    }
}

/* ============================================
   CARDS - Glass Morphism Style
   ============================================ */

.card {
    background: var(--bg-card);
    border-radius: 20px;
    border: 1px solid var(--border-color);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    transition: all var(--transition-base);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(99, 102, 241, 0.3);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-lg);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(255, 255, 255, 0.02);
}

.card-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.card-body {
    padding: var(--spacing-lg);
}

/* ============================================
   TODAY SECTION - Hero Stats
   ============================================ */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-xl);
}

.stat-item {
    text-align: center;
    padding: var(--spacing-lg);
    border-radius: var(--radius-lg);
    background: var(--bg-glass);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.stat-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.stat-item:hover {
    transform: scale(1.02);
    background: var(--bg-glass-hover);
}

.stat-todo::before { background: var(--gradient-danger); }
.stat-doing::before { background: var(--gradient-warning); }
.stat-done::before { background: var(--gradient-success); }

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 800;
    font-family: var(--font-mono);
    line-height: 1;
    margin-bottom: var(--spacing-xs);
}

.stat-todo .stat-number { color: #ef4444; text-shadow: var(--glow-danger); }
.stat-doing .stat-number { color: #f59e0b; text-shadow: var(--glow-warning); }
.stat-done .stat-number { color: #10b981; text-shadow: var(--glow-success); }

.stat-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

/* Today Events & Urgent */
.today-events,
.urgent-tasks {
    margin-top: var(--spacing-lg);
}

.today-events h3,
.urgent-tasks h3 {
    font-size: 0.8125rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: var(--spacing-md);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.events-list,
.urgent-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.event-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-glass);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.03);
    transition: all var(--transition-fast);
}

.event-item:hover {
    background: var(--bg-glass-hover);
    border-color: rgba(99, 102, 241, 0.2);
}

.event-time {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent-primary);
    min-width: 55px;
    padding: var(--spacing-xs) var(--spacing-sm);
    background: rgba(99, 102, 241, 0.1);
    border-radius: var(--radius-sm);
    text-align: center;
}

.event-title {
    flex: 1;
    font-size: 0.9375rem;
    font-weight: 500;
}

.event-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.event-details .event-title {
    flex: none;
}

.event-location {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.event-item.google-cal {
    border-left: 3px solid var(--accent-primary);
}

.event-item.local {
    border-left: 3px solid var(--status-doing);
}

.urgent-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: rgba(239, 68, 68, 0.08);
    border-left: 3px solid var(--status-todo);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-weight: 500;
}

.urgent-item:hover {
    background: rgba(239, 68, 68, 0.12);
    transform: translateX(4px);
}

.urgent-item::before {
    content: '🔥';
    font-size: 1.125rem;
}

/* ============================================
   KANBAN BOARD - Modern Cards
   ============================================ */

.kanban-board {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-lg);
    min-height: 400px;
}

@media (max-width: 767px) {
    .kanban-board {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
}

.kanban-column {
    background: var(--bg-glass);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md);
    border: 1px solid rgba(255, 255, 255, 0.03);
    min-height: 300px;
}

.column-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-sm) var(--spacing-md);
    margin-bottom: var(--spacing-md);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.02);
}

.column-title {
    font-weight: 600;
    font-size: 0.9375rem;
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.column-count {
    background: var(--bg-secondary);
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-secondary);
}

.column-tasks {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    min-height: 200px;
}

/* Task Card - Premium Style */
.task-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: var(--spacing-md);
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.04);
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.task-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    border-radius: var(--radius-md) 0 0 var(--radius-md);
}

.task-card[data-priority="low"]::before { background: var(--text-muted); }
.task-card[data-priority="normal"]::before { background: var(--gradient-info); }
.task-card[data-priority="high"]::before { background: var(--gradient-warning); }
.task-card[data-priority="urgent"]::before { background: var(--gradient-danger); }

.task-card:hover {
    transform: translateY(-3px) scale(1.01);
    box-shadow: var(--shadow-md), var(--shadow-glow);
    border-color: rgba(99, 102, 241, 0.3);
}

.task-title {
    font-size: 0.9375rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    padding-left: var(--spacing-sm);
}

.task-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    color: var(--text-muted);
    padding-left: var(--spacing-sm);
}

.task-priority {
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: 0.6875rem;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.3px;
}

.task-priority.urgent { 
    background: rgba(239, 68, 68, 0.15); 
    color: #f87171;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.2);
}
.task-priority.high { 
    background: rgba(245, 158, 11, 0.15); 
    color: #fbbf24;
}

.task-actions {
    display: flex;
    gap: var(--spacing-xs);
    margin-top: var(--spacing-md);
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.task-action-btn {
    flex: 1;
    padding: var(--spacing-sm);
    border: none;
    border-radius: var(--radius-sm);
    background: var(--bg-glass);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.task-action-btn:hover {
    background: var(--bg-glass-hover);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.task-action-btn.delete:hover {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
}

/* ============================================
   REMINDERS - Clean List
   ============================================ */

.reminders-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.reminder-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-glass);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.03);
    transition: all var(--transition-fast);
}

.reminder-item:hover {
    background: var(--bg-glass-hover);
    border-color: rgba(245, 158, 11, 0.2);
}

.reminder-item[data-priority="urgent"] {
    border-color: rgba(239, 68, 68, 0.3);
    background: rgba(239, 68, 68, 0.05);
}

.reminder-check {
    width: 24px;
    height: 24px;
    border: 2px solid var(--text-muted);
    border-radius: 50%;
    cursor: pointer;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.reminder-check:hover {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.1);
    transform: scale(1.1);
}

.reminder-content {
    flex: 1;
    min-width: 0;
}

.reminder-title {
    font-size: 0.9375rem;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reminder-time {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
    margin-top: 2px;
}

.reminder-delete {
    padding: var(--spacing-sm);
    border: none;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1.125rem;
    transition: all var(--transition-fast);
    border-radius: var(--radius-sm);
}

.reminder-delete:hover {
    color: #f87171;
    background: rgba(239, 68, 68, 0.1);
}

/* ============================================
   NOTES - Card Style
   ============================================ */

.notes-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.note-item {
    padding: var(--spacing-lg);
    background: var(--bg-glass);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.03);
    cursor: pointer;
    transition: all var(--transition-base);
}

.note-item:hover {
    background: var(--bg-glass-hover);
    border-color: rgba(139, 92, 246, 0.2);
    transform: translateX(4px);
}

.note-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--spacing-sm);
    gap: var(--spacing-md);
}

.note-title {
    font-size: 1rem;
    font-weight: 600;
    flex: 1;
}

.note-date {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
    padding: 2px 8px;
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    white-space: nowrap;
}

.note-preview {
    font-size: 0.875rem;
    color: var(--text-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.5;
}

.note-tags {
    display: flex;
    gap: var(--spacing-xs);
    margin-top: var(--spacing-md);
    flex-wrap: wrap;
}

.note-tag {
    padding: 4px 12px;
    background: rgba(139, 92, 246, 0.1);
    border-radius: var(--radius-full);
    font-size: 0.6875rem;
    color: #a78bfa;
    font-weight: 500;
    text-transform: lowercase;
}

/* ============================================
   BOTTOM NAVIGATION - Floating Dock
   ============================================ */

.bottom-nav {
    position: fixed;
    bottom: var(--spacing-lg);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: var(--spacing-xs);
    background: rgba(18, 18, 26, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: var(--spacing-sm);
    border-radius: var(--radius-xl);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: var(--shadow-lg), var(--shadow-glow);
    z-index: 100;
}

@media (min-width: 768px) {
    .bottom-nav {
        display: none;
    }
    
    body {
        padding-bottom: var(--spacing-xl);
    }
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: var(--spacing-sm) var(--spacing-lg);
    border: none;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    transition: all var(--transition-fast);
    border-radius: var(--radius-md);
}

.nav-item.active,
.nav-item:hover {
    color: var(--text-primary);
    background: var(--bg-glass);
}

.nav-item.active {
    background: var(--gradient-primary);
    color: white;
}

.nav-icon {
    font-size: 1.375rem;
}

.nav-label {
    font-size: 0.625rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* ============================================
   MODALS - Glassmorphism
   ============================================ */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    z-index: 200;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-md);
}

.modal.active {
    display: flex;
    animation: fadeIn 0.2s ease-out;
}

.modal-content {
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: var(--shadow-lg), 0 0 60px rgba(99, 102, 241, 0.1);
    animation: slideUp 0.3s ease-out;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-lg);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(255, 255, 255, 0.02);
}

.modal-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.btn-close {
    width: 36px;
    height: 36px;
    border: none;
    background: var(--bg-glass);
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 1.125rem;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-close:hover {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    transform: rotate(90deg);
}

/* ============================================
   FORMS - Clean Inputs
   ============================================ */

form {
    padding: var(--spacing-lg);
}

.form-group {
    margin-bottom: var(--spacing-lg);
}

.form-group label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: var(--spacing-md);
    background: var(--bg-glass);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: var(--font-family);
    font-size: 1rem;
    transition: all var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
    background: var(--bg-glass-hover);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-xl);
    padding-top: var(--spacing-lg);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* ============================================
   BUTTONS - Gradient Style
   ============================================ */

.btn-primary {
    padding: var(--spacing-sm) var(--spacing-lg);
    background: var(--gradient-primary);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.25);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.35);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    padding: var(--spacing-sm) var(--spacing-lg);
    background: var(--bg-glass);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all var(--transition-fast);
}

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

.btn-icon {
    width: 44px;
    height: 44px;
    border: none;
    background: var(--bg-glass);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1rem;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-icon:hover {
    background: var(--bg-glass-hover);
    color: var(--text-primary);
    transform: rotate(180deg);
}

/* ============================================
   PROJECTS CAROUSEL
   ============================================ */

.carousel-controls {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.carousel-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: var(--bg-glass);
    color: var(--text-primary);
    font-size: 1.25rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-btn:hover {
    background: var(--bg-glass-hover);
    border-color: var(--accent-primary);
}

.projects-carousel {
    overflow: hidden;
    margin: 0 calc(0px - var(--spacing-md));
    padding: 0 var(--spacing-md);
}

.projects-track {
    display: flex;
    gap: var(--spacing-md);
    transition: transform 0.3s ease;
    scroll-behavior: smooth;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: var(--spacing-sm) 0;
}

.projects-track::-webkit-scrollbar {
    display: none;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--spacing-lg);
}

.project-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    border: 1px solid rgba(255, 255, 255, 0.05);
    cursor: pointer;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
    min-width: 280px;
    max-width: 320px;
    flex-shrink: 0;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-primary);
    opacity: 0.7;
}

.project-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
    border-color: rgba(99, 102, 241, 0.3);
}

.project-card.status-paused::before {
    background: var(--gradient-warning);
}

.project-card.status-completed::before {
    background: var(--gradient-success);
}

.project-card.priority-high {
    border-color: rgba(239, 68, 68, 0.3);
}

.project-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
}

.project-category {
    font-size: 1.25rem;
}

.project-name {
    flex: 1;
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-primary);
}

.project-badge {
    background: var(--gradient-success);
    color: white;
    font-size: 0.75rem;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-weight: 600;
}

.project-description {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-md);
    line-height: 1.5;
}

.project-progress {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
}

.progress-bar {
    flex: 1;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    transition: width var(--transition-base);
}

.progress-text {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
    min-width: 36px;
    text-align: right;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
    margin-top: var(--spacing-sm);
}

.project-tag {
    font-size: 0.6875rem;
    padding: 2px 8px;
    background: rgba(99, 102, 241, 0.1);
    color: var(--accent-primary);
    border-radius: var(--radius-sm);
    font-weight: 500;
}

.project-actions {
    display: flex;
    justify-content: flex-end;
    gap: var(--spacing-xs);
    margin-top: var(--spacing-md);
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.project-action-btn {
    padding: 4px 10px;
    font-size: 0.75rem;
    background: var(--bg-glass);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.project-action-btn:hover {
    background: var(--bg-glass-hover);
    color: var(--text-primary);
}

.project-action-btn.delete:hover {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
    border-color: rgba(239, 68, 68, 0.3);
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.empty-state {
    text-align: center;
    padding: var(--spacing-2xl);
    color: var(--text-muted);
    font-size: 0.9375rem;
}

.hidden {
    display: none !important;
}

/* ============================================
   SKELETON LOADING
   ============================================ */

.skeleton {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.05) 25%,
        rgba(255, 255, 255, 0.1) 50%,
        rgba(255, 255, 255, 0.05) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-text {
    height: 1em;
    margin-bottom: var(--spacing-xs);
}

.skeleton-text:last-child {
    width: 60%;
}

.skeleton-title {
    height: 1.5em;
    width: 70%;
    margin-bottom: var(--spacing-sm);
}

.skeleton-card {
    padding: var(--spacing-lg);
    background: var(--bg-glass);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-sm);
}

.skeleton-stat {
    height: 3rem;
    width: 3rem;
    margin: 0 auto var(--spacing-xs);
}

.skeleton-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

/* Loading State for Cards */
.card.loading .card-body {
    min-height: 200px;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.card.loading .skeleton-item {
    display: flex;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-glass);
    border-radius: var(--radius-md);
}

.card.loading .skeleton-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    flex-shrink: 0;
}

.card.loading .skeleton-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

/* Quick loading indicator for top of page */
.loading-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--gradient-primary);
    z-index: 1000;
    transform-origin: left;
    animation: loading-bar 2s ease-in-out infinite;
}

@keyframes loading-bar {
    0% { transform: scaleX(0); }
    50% { transform: scaleX(0.7); }
    100% { transform: scaleX(1); opacity: 0; }
}

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { 
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to { 
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.card {
    animation: slideUp 0.4s ease-out;
    animation-fill-mode: both;
}

.card:nth-child(1) { animation-delay: 0s; }
.card:nth-child(2) { animation-delay: 0.1s; }
.card:nth-child(3) { animation-delay: 0.2s; }
.card:nth-child(4) { animation-delay: 0.3s; }

/* ============================================
   SCROLLBAR - Subtle
   ============================================ */

::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

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

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* ============================================
   SELECTION
   ============================================ */

::selection {
    background: rgba(99, 102, 241, 0.3);
    color: white;
}

/* ============================================
   FILE UPLOAD
   ============================================ */

.upload-zone {
    border: 2px dashed rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-lg);
    padding: var(--spacing-xl);
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-fast);
    margin-bottom: var(--spacing-lg);
    background: rgba(255, 255, 255, 0.02);
}

.upload-zone:hover,
.upload-zone.dragover {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.05);
}

.upload-zone.dragover {
    transform: scale(1.01);
}

.upload-icon {
    font-size: 2.5rem;
    margin-bottom: var(--spacing-sm);
}

.upload-text {
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: var(--spacing-xs);
}

.upload-hint {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.upload-progress {
    margin-bottom: var(--spacing-lg);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.upload-progress .progress-bar {
    flex: 1;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.upload-progress .progress-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    transition: width 0.3s ease;
}

#upload-status {
    font-size: 0.8rem;
    color: var(--text-muted);
    min-width: 100px;
}

.files-count {
    font-size: 0.75rem;
    color: var(--text-muted);
    background: var(--bg-glass);
    padding: 2px 8px;
    border-radius: var(--radius-sm);
}

.shared-files-list {
    display: grid;
    gap: var(--spacing-sm);
}

.shared-file-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-card);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    border: 1px solid transparent;
}

.shared-file-item:hover {
    border-color: rgba(255, 255, 255, 0.1);
    background: var(--bg-card-hover);
}

.file-icon {
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-glass);
    border-radius: var(--radius-md);
}

.file-details {
    flex: 1;
    min-width: 0;
}

.file-name {
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.file-actions {
    display: flex;
    gap: var(--spacing-xs);
}

.file-action-btn {
    padding: 6px 10px;
    background: var(--bg-glass);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 0.8rem;
    transition: all var(--transition-fast);
}

.file-action-btn:hover {
    background: var(--bg-glass-hover);
    color: var(--text-primary);
}

.file-action-btn.delete:hover {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

/* ================================================
   GPM Dashboard Styles (migrated from index.html)
   ================================================ */

/* Legacy hero-greeting kept for backward compat */
.hero-greeting {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.05));
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--radius-lg);
    padding: var(--spacing-xl);
    margin-bottom: var(--spacing-xl);
}

.summary-chips {
    display: flex;
    gap: var(--spacing-sm);
    flex-wrap: wrap;
}

.summary-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--bg-glass);
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.summary-chip .chip-number {
    font-weight: 700;
    color: var(--text-primary);
}

.summary-chip.urgent {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.summary-chip.urgent .chip-number {
    color: #ef4444;
}

/* Quick Action Buttons (compact in hero-bar) */
.quick-action {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: var(--accent-primary);
    border: 1px solid var(--accent-primary);
    border-radius: var(--radius-sm);
    color: #fff;
    cursor: pointer;
    transition: all var(--transition-fast);
    white-space: nowrap;
    font-size: 0.8rem;
    font-weight: 600;
}

.quick-action:hover {
    background: var(--accent-primary-hover, #7c6ae8);
    color: #fff;
    border-color: var(--accent-primary-hover, #7c6ae8);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.quick-action-icon {
    padding: 8px 10px;
    font-size: 0.9rem;
    background: var(--bg-card);
    border-color: rgba(255,255,255,0.1);
    color: var(--text-secondary);
    font-weight: 400;
}

.quick-action-icon:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
    border-color: var(--accent-primary);
    transform: none;
    box-shadow: none;
}

/* Update "Ver mais" link */
.update-more {
    text-align: center;
    padding: var(--spacing-sm) 0;
    margin-top: var(--spacing-sm);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* Main Grid Layout - Desktop Optimized */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xl);
}

@media (min-width: 1400px) {
    .dashboard-grid {
        grid-template-columns: 1fr 1fr 1fr;
    }

    .today-column:first-child {
        grid-column: span 2;
    }
}

@media (max-width: 1024px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

/* Desktop: Make cards wider and more readable */
@media (min-width: 1200px) {
    .card {
        padding: var(--spacing-xl);
    }
}

/* Today Column */
.today-column {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.agenda-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border-left: 3px solid var(--accent-primary);
}

.agenda-time {
    font-weight: 600;
    color: var(--accent-primary);
    min-width: 50px;
}

.agenda-title {
    flex: 1;
    color: var(--text-primary);
}

.agenda-project {
    font-size: 0.75rem;
    color: var(--text-muted);
    background: rgba(255,255,255,0.05);
    padding: 2px 8px;
    border-radius: var(--radius-sm);
}

/* Portfolio Section */
.portfolio-grid {
    display: grid;
    gap: var(--spacing-md);
}

.portfolio-card {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md) var(--spacing-lg);
    background: var(--bg-card);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    border-left: 3px solid transparent;
}

.portfolio-card:hover {
    background: var(--bg-card-hover);
    border-left-color: var(--accent-primary);
    transform: translateX(4px);
}

.portfolio-card.high-priority {
    border-left-color: #ef4444;
}

.portfolio-info {
    flex: 1;
}

.portfolio-name {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.portfolio-status {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.portfolio-progress {
    width: 100px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.progress-bar-mini {
    flex: 1;
    height: 6px;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
    overflow: hidden;
}

.progress-fill-mini {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: 3px;
    transition: width 0.3s ease;
}

.progress-text {
    font-size: 0.75rem;
    color: var(--text-muted);
    min-width: 35px;
    text-align: right;
}

/* Updates Feed */
.updates-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    max-height: 400px;
    overflow-y: auto;
}

.update-item {
    display: flex;
    align-items: flex-start;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-card);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.update-item:hover {
    background: var(--bg-card-hover);
}

.update-icon {
    font-size: 1.25rem;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(99, 102, 241, 0.1);
    border-radius: var(--radius-md);
}

.update-content {
    flex: 1;
}

.update-title {
    color: var(--text-primary);
    font-weight: 500;
    margin-bottom: 2px;
}

.update-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Update type differentiation */
.update-item.update-type-meeting {
    border-left: 3px solid #3b82f6;
}

.update-item.update-type-meeting .update-icon {
    background: rgba(59, 130, 246, 0.1);
}

.update-item.update-type-task {
    border-left: 3px solid #f59e0b;
}

.update-item.update-type-task .update-icon {
    background: rgba(245, 158, 11, 0.1);
}

.update-item.update-type-project {
    border-left: 3px solid #8b5cf6;
}

.update-item.update-type-project .update-icon {
    background: rgba(139, 92, 246, 0.1);
}

.update-item.update-type-note {
    border-left: 3px solid #10b981;
}

.update-item.update-type-note .update-icon {
    background: rgba(16, 185, 129, 0.1);
}

.update-item.update-type-deadline {
    border-left: 3px solid #ef4444;
}

.update-item.update-type-deadline .update-icon {
    background: rgba(239, 68, 68, 0.1);
}

/* Styled Empty States */
.empty-state-styled {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md) var(--spacing-lg);
    background: var(--bg-glass);
    border-radius: var(--radius-md);
    color: var(--text-muted);
    font-size: 0.875rem;
}

.empty-state-styled.loading {
    animation: pulse 2s ease-in-out infinite;
}

.empty-state-styled.error {
    background: rgba(239, 68, 68, 0.05);
    border: 1px solid rgba(239, 68, 68, 0.15);
    color: rgba(239, 68, 68, 0.8);
}

.empty-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Sync Badge */
.sync-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 500;
}

.sync-badge.not-synced {
    background: rgba(245, 158, 11, 0.1);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.2);
}

/* Kanban Mini */
.kanban-mini {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-sm);
}

.kanban-mini-col {
    background: var(--bg-glass);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    text-align: center;
}

.kanban-mini-count {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.kanban-mini-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.kanban-mini-col.todo .kanban-mini-count { color: #ef4444; }
.kanban-mini-col.doing .kanban-mini-count { color: #eab308; }
.kanban-mini-col.done .kanban-mini-count { color: #22c55e; }

/* Keyboard Shortcut Hint (removed from UI) */
.keyboard-hint {
    display: none;
}

.keyboard-hint kbd {
    background: rgba(255,255,255,0.1);
    padding: 2px 6px;
    border-radius: 4px;
    margin: 0 2px;
}

@media (min-width: 768px) {
    .keyboard-hint {
        display: block;
    }
}

/* Shortcuts Help Modal */
.shortcuts-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1001;
    animation: fadeIn 0.2s ease;
}

.shortcuts-content {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: var(--spacing-xl);
    max-width: 450px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.shortcuts-content h2 {
    margin-bottom: var(--spacing-lg);
    color: var(--text-primary);
    font-size: 1.25rem;
}

.shortcuts-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.shortcut-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: rgba(255,255,255,0.03);
    border-radius: var(--radius-sm);
}

.shortcut-item kbd {
    background: rgba(99, 102, 241, 0.2);
    color: var(--accent-primary);
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    min-width: 80px;
    text-align: center;
}

.shortcut-item span {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.shortcuts-content button {
    margin-top: var(--spacing-lg);
    width: 100%;
    padding: 12px;
    background: var(--accent-primary);
    border: none;
    border-radius: var(--radius-md);
    color: white;
    cursor: pointer;
    font-weight: 600;
}

.shortcuts-content button:hover {
    background: var(--accent-secondary);
}

/* Toast Notification */
.toast-notification {
    position: fixed;
    bottom: 80px;
    right: 20px;
    background: var(--bg-card);
    color: var(--text-primary);
    padding: 12px 24px;
    border-radius: var(--radius-md);
    border-left: 3px solid var(--accent-primary);
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    transform: translateX(100%);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1002;
}

.toast-notification.show {
    transform: translateX(0);
    opacity: 1;
}

/* Command result selection */
.command-result.selected {
    background: var(--accent-primary);
    color: white;
}

/* Command Palette */
.command-palette {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    padding: 20vh 20px;
}

.command-palette.active {
    display: flex;
    justify-content: center;
}

.command-input-wrapper {
    width: 100%;
    max-width: 600px;
}

.command-input {
    width: 100%;
    padding: 16px 20px;
    font-size: 1.125rem;
    background: var(--bg-card);
    border: 2px solid var(--accent-primary);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    outline: none;
}

.command-input::placeholder {
    color: var(--text-muted);
}

.command-results {
    margin-top: var(--spacing-md);
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    max-height: 300px;
    overflow-y: auto;
}

.command-result {
    padding: var(--spacing-md);
    cursor: pointer;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.command-result:hover,
.command-result.selected {
    background: var(--bg-glass);
}

.command-result-icon {
    font-size: 1.25rem;
}

.command-result-text {
    flex: 1;
}

.command-result-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Section Headers */
.section-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-md);
}

.section-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-action {
    font-size: 0.75rem;
    color: var(--accent-primary);
    text-decoration: none;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    font-family: inherit;
}

.section-action:hover {
    text-decoration: underline;
}

/* ============================================
   HAMBURGER MENU - Mobile
   ============================================ */

.hamburger-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: var(--spacing-xs);
    border-radius: var(--radius-sm);
    transition: background var(--transition-fast);
    line-height: 1;
}

.hamburger-btn:hover {
    background: var(--bg-glass-hover);
}

@media (max-width: 767px) {
    .hamburger-btn {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

/* Mobile Slide-out Menu */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 500;
    opacity: 0;
    transition: opacity var(--transition-base);
}

.mobile-menu-overlay.active {
    display: block;
    opacity: 1;
}

.mobile-menu {
    position: fixed;
    top: 0;
    right: -280px;
    width: 280px;
    height: 100vh;
    background: var(--bg-secondary);
    border-left: 1px solid rgba(255, 255, 255, 0.08);
    z-index: 501;
    transition: right var(--transition-base);
    overflow-y: auto;
    padding: var(--spacing-lg) 0;
}

.mobile-menu.active {
    right: 0;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 var(--spacing-lg) var(--spacing-lg);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: var(--spacing-md);
}

.mobile-menu-header h2 {
    font-size: 1.1rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.mobile-menu-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    padding: var(--spacing-xs);
    border-radius: var(--radius-sm);
    line-height: 1;
}

.mobile-menu-close:hover {
    color: var(--text-primary);
    background: var(--bg-glass);
}

.mobile-menu-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 0 var(--spacing-sm);
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md) var(--spacing-lg);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.mobile-nav-link:hover {
    color: var(--text-primary);
    background: var(--bg-glass-hover);
}

.mobile-nav-link.active {
    color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.1);
}

.mobile-nav-link .mobile-nav-icon {
    font-size: 1.25rem;
    width: 28px;
    text-align: center;
}

/* ============================================
   SKELETON LOADING
   ============================================ */

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.skeleton {
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.03) 25%, 
        rgba(255, 255, 255, 0.08) 50%, 
        rgba(255, 255, 255, 0.03) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius-sm);
}

.skeleton-text {
    height: 14px;
    margin-bottom: 8px;
    width: 80%;
}

.skeleton-text.short { width: 40%; }
.skeleton-text.medium { width: 60%; }

.skeleton-card {
    height: 120px;
    border-radius: var(--radius-lg);
}

/* ============================================
   ERROR STATE
   ============================================ */

.error-state {
    text-align: center;
    padding: var(--spacing-xl);
    color: var(--text-muted);
}

.error-state .error-icon {
    font-size: 2.5rem;
    margin-bottom: var(--spacing-md);
    opacity: 0.5;
}

.error-state .error-message {
    font-size: 0.9rem;
    margin-bottom: var(--spacing-md);
    color: #ef4444;
}

.error-state .error-retry {
    padding: var(--spacing-sm) var(--spacing-lg);
    background: var(--gradient-primary);
    border: none;
    border-radius: var(--radius-full);
    color: white;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.85rem;
    transition: opacity var(--transition-fast);
}

.error-state .error-retry:hover {
    opacity: 0.9;
}

/* ============================================
   EMPTY STATE
   ============================================ */

.empty-state {
    text-align: center;
    padding: var(--spacing-2xl) var(--spacing-lg);
    color: var(--text-muted);
}

.empty-state .empty-icon {
    font-size: 3rem;
    margin-bottom: var(--spacing-md);
    opacity: 0.4;
}

.empty-state .empty-text {
    font-size: 0.9rem;
    line-height: 1.5;
}

/* ============================================
   SKELETON LOADING
   ============================================ */

@keyframes skeleton-pulse {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.8; }
}

.skeleton {
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    animation: skeleton-pulse 1.5s ease-in-out infinite;
}

.skeleton-text {
    height: 14px;
    margin-bottom: 8px;
    border-radius: 4px;
}

.skeleton-text.short { width: 40%; }
.skeleton-text.medium { width: 65%; }
.skeleton-text.long { width: 90%; }

.skeleton-card {
    height: 120px;
    border-radius: var(--radius-md);
}

.skeleton-stat {
    height: 80px;
    border-radius: var(--radius-md);
}

.loading-state {
    text-align: center;
    padding: var(--spacing-xl);
    color: var(--text-muted);
}

/* ============================================
   MOBILE OVERFLOW FIXES
   ============================================ */

/* Prevent horizontal scroll on mobile */
html, body {
    overflow-x: hidden;
}

/* Ensure tables don't break layout on mobile */
table {
    width: 100%;
    overflow-x: auto;
    display: block;
}

@media (max-width: 768px) {
    /* Wrap tables in scrollable container */
    .table-wrapper,
    .report-card,
    .embed-card {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* Prevent fixed-width cards from overflowing */
    .portfolio-card,
    .project-card {
        max-width: 100%;
        min-width: 0;
    }

    /* Ensure stat grids don't overflow */
    .stats-grid,
    .work-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-sm);
    }

    /* Responsive embed iframes */
    .embed-card iframe {
        width: 100%;
        min-height: 300px;
    }

    /* Prevent code/pre blocks from overflowing */
    pre, code {
        overflow-x: auto;
        word-break: break-word;
    }

    /* Bottom nav: constrain to viewport */
    .bottom-nav {
        max-width: calc(100vw - var(--spacing-lg) * 2);
    }
}

/* ============================================
   MOBILE TOUCH TARGETS — WCAG 2.5.5 (min 44x44px)
   ============================================ */

@media (max-width: 767px) {
    /* Quick action buttons in hero bar */
    .quick-action {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
    }

    .quick-action-icon {
        min-width: 44px;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    /* Priority Pulse action links (Ver MBA, Abrir) */
    .pulse-item-action {
        min-height: 44px;
        min-width: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 8px 12px;
        font-size: 0.8rem;
    }

    /* Section action links (Ver detalhes, Atualizar, Ver Kanban, + Novo) */
    .section-action {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        padding: 8px 12px;
        font-size: 0.8rem;
    }

    /* Weekly brief expand button */
    .brief-footer-btn {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        padding: 8px 14px;
    }

    /* Hamburger menu button */
    .hamburger-btn {
        min-width: 44px;
        min-height: 44px;
    }

    /* Back button on project page */
    .project-header .back-btn {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
    }

    /* Main content padding to avoid bottom nav overlap */
    .main-content {
        padding-bottom: 100px !important;
    }
}

/* ============================================
   OFFLINE BANNER
   ============================================ */

.offline-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 8px 16px;
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-md);
    font-size: 0.85rem;
    color: #fbbf24;
}

.offline-banner button {
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(245, 158, 11, 0.4);
    background: rgba(245, 158, 11, 0.1);
    color: #fbbf24;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 600;
    transition: var(--transition-fast);
}

.offline-banner button:hover {
    background: rgba(245, 158, 11, 0.25);
}

/* ============================================
   DASHBOARD WITH SIDEBAR LAYOUT
   ============================================ */

.dashboard-with-sidebar {
    display: flex;
    gap: var(--spacing-lg);
}

.dashboard-main-area {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

/* ---- Life OS Sidebar (desktop only) ---- */
.life-os-sidebar {
    display: none; /* hidden on mobile, shown via media query */
}

@media (min-width: 1200px) {
    .life-os-sidebar {
        display: flex;
        flex-direction: column;
        width: 260px;
        min-width: 260px;
        background: var(--bg-card);
        border: 1px solid rgba(139, 92, 246, 0.15);
        border-radius: var(--radius-lg);
        padding: var(--spacing-md);
        align-self: flex-start;
        position: sticky;
        top: calc(var(--spacing-lg) + 64px); /* below header */
        max-height: calc(100vh - 100px);
        overflow-y: auto;
        transition: width var(--transition-base), min-width var(--transition-base), padding var(--transition-base), opacity var(--transition-base);
        order: -1; /* ensure it's on the left */
    }

    .life-os-sidebar.collapsed {
        width: 48px;
        min-width: 48px;
        padding: var(--spacing-sm);
        overflow: hidden;
    }

    .life-os-sidebar.collapsed .sidebar-body {
        opacity: 0;
        visibility: hidden;
        height: 0;
        overflow: hidden;
    }

    .life-os-sidebar.collapsed .sidebar-title {
        writing-mode: vertical-rl;
        text-orientation: mixed;
        font-size: 0.7rem;
        white-space: nowrap;
    }

    .life-os-sidebar.collapsed .sidebar-header {
        flex-direction: column;
        align-items: center;
        gap: var(--spacing-sm);
    }
}

/* Mobile: show the inline Life OS card */
.life-os-mobile {
    display: block;
}

@media (min-width: 1200px) {
    .life-os-mobile {
        display: none;
    }
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    padding-bottom: var(--spacing-sm);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    margin-bottom: var(--spacing-sm);
    user-select: none;
}

.sidebar-title {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--accent-secondary);
    letter-spacing: 0.5px;
}

.sidebar-toggle {
    font-size: 0.65rem;
    color: var(--text-muted);
    transition: var(--transition-fast);
}

.sidebar-header:hover .sidebar-toggle {
    color: var(--accent-primary);
}

.sidebar-body {
    transition: opacity var(--transition-base);
}

/* ---- Life OS Message Items (sidebar & mobile) ---- */
.life-os-msg-item {
    display: flex;
    gap: var(--spacing-sm);
    padding: 6px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    align-items: flex-start;
}

.life-os-msg-item:last-child {
    border-bottom: none;
}

.life-os-msg-item.sent {
    opacity: 0.45;
}

.life-os-msg-time {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-secondary);
    min-width: 38px;
    text-align: center;
    padding-top: 1px;
    font-family: var(--font-mono);
}

.life-os-msg-content {
    flex: 1;
    min-width: 0;
}

.life-os-msg-text {
    font-size: 0.78rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.life-os-msg-meta {
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ============================================
   TOP CONTEXT ROW (Priority Pulse + Weekly Brief)
   ============================================ */

.top-context-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
    overflow: hidden;
}

@media (min-width: 768px) {
    .top-context-row {
        grid-template-columns: 1fr 1fr;
    }
    /* When Priority Pulse is hidden, Weekly Brief spans full width */
    .top-context-row > .priority-pulse[style*="display: none"] ~ .weekly-brief-panel,
    .top-context-row > .priority-pulse[style*="display:none"] ~ .weekly-brief-panel {
        grid-column: 1 / -1;
    }
}

/* ============================================
   PRIORITY PULSE
   ============================================ */

.priority-pulse {
    background: var(--bg-card);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md);
    animation: pulse-fade-in 0.4s ease-out;
    min-width: 0;
    overflow: hidden;
}

/* ============================================
   WEEKLY BRIEF PANEL (stylized, matches Pulse)
   ============================================ */

/* ============================================
   WEEKLY BRIEF v2
   ============================================ */

.weekly-brief-panel {
    background: var(--bg-card);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md);
    animation: pulse-fade-in 0.4s ease-out 0.1s both;
    display: flex;
    flex-direction: column;
    gap: 0;
    min-width: 0;
    overflow: hidden;
}

.weekly-brief-panel .pulse-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-sm);
}

.weekly-brief-panel .pulse-title {
    color: #10b981;
}

.brief-week-range {
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

/* --- Gauges: 3 colored dots inline --- */
.brief-gauges {
    display: flex;
    gap: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    margin-bottom: 8px;
}

.brief-gauge {
    display: flex;
    align-items: center;
    gap: 5px;
}

.brief-gauge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.brief-gauge-green { background: #10b981; box-shadow: 0 0 4px rgba(16, 185, 129, 0.4); }
.brief-gauge-amber { background: #f59e0b; box-shadow: 0 0 4px rgba(245, 158, 11, 0.4); }
.brief-gauge-red   { background: #ef4444; box-shadow: 0 0 4px rgba(239, 68, 68, 0.4); }

.brief-gauge-label {
    font-size: 0.68rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    font-weight: 500;
}

.brief-gauge-val {
    font-size: 0.65rem;
    color: var(--text-muted);
    font-variant-numeric: tabular-nums;
    opacity: 0.7;
}

/* --- Top Actions: pulse-item-like rows --- */
.brief-actions {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 8px;
}

.brief-action-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 8px;
    border-left: 3px solid #ef4444;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    background: rgba(239, 68, 68, 0.05);
    transition: background var(--transition-fast);
}

.brief-action-item:hover {
    background: rgba(239, 68, 68, 0.08);
}

.brief-action-item.brief-action-clear {
    border-left-color: #10b981;
    background: rgba(16, 185, 129, 0.05);
}

.brief-action-item.brief-action-important {
    border-left-color: #f59e0b;
    background: rgba(245, 158, 11, 0.05);
}

.brief-action-item.brief-action-important:hover {
    background: rgba(245, 158, 11, 0.08);
}

.brief-action-item.brief-action-decision {
    border-left-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.05);
}

.brief-action-item.brief-action-decision:hover {
    background: rgba(99, 102, 241, 0.08);
}

.brief-action-text {
    flex: 1;
    min-width: 0;
    font-size: 0.8rem;
    color: var(--text-primary);
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.brief-action-deadline {
    flex-shrink: 0;
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 1px 6px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.04);
}

.brief-action-context {
    flex-shrink: 0;
    font-size: 0.65rem;
    color: var(--text-muted);
    max-width: 120px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- Calendar: compact day rows --- */
.brief-calendar {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    overflow: hidden;
}

.brief-day-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    padding: 3px 6px;
    border-radius: var(--radius-sm);
    font-size: 0.78rem;
    line-height: 1.5;
    color: var(--text-secondary);
    min-width: 0;
}

.brief-day-abbr {
    width: 28px;
    flex-shrink: 0;
    font-weight: 700;
    font-size: 0.7rem;
    letter-spacing: 0.04em;
    color: var(--text-muted);
}

.brief-day-text {
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.brief-today {
    color: var(--accent-primary);
    font-weight: 600;
    background: rgba(99, 102, 241, 0.06);
}

.brief-today .brief-day-abbr {
    color: var(--accent-primary);
}

/* --- Footer: counts + expand button --- */
.brief-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    margin-top: 8px;
}

.brief-footer:empty {
    display: none;
}

.brief-footer-counts {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.brief-footer-btn {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--accent-primary);
    cursor: pointer;
    padding: 3px 10px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(99, 102, 241, 0.2);
    background: none;
    transition: var(--transition-fast);
}

.brief-footer-btn:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.4);
}

/* --- Detail (expanded) --- */
.brief-detail {
    margin-top: var(--spacing-sm);
    font-size: 0.82rem;
}

.brief-detail-section {
    margin-bottom: 8px;
}

.brief-detail-label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 4px;
    padding-top: 4px;
}

.brief-label-urgent { color: #ef4444; }
.brief-label-important { color: #f59e0b; }
.brief-label-decision { color: var(--accent-primary); }
.brief-label-reminder { color: #f59e0b; }

/* Completed items: strikethrough */
.brief-item-completed .brief-action-text {
    text-decoration: line-through;
    opacity: 0.45;
}
.brief-item-completed .brief-action-deadline,
.brief-item-completed .brief-item-link {
    opacity: 0.35;
}
.brief-item-completed .brief-crud-check {
    opacity: 0.3 !important;
    color: #10b981;
}

/* Reminder items accent */
.brief-action-reminder {
    border-left-color: #f59e0b;
}

/* --- Split Calendar: days left + agenda right --- */
.brief-calendar-split {
    display: flex;
    gap: 0;
    min-height: 0;
}

.brief-cal-days {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.brief-cal-agenda {
    flex: 1;
    min-width: 0;
    border-left: 1px solid rgba(255, 255, 255, 0.06);
    padding-left: 10px;
    display: flex;
    flex-direction: column;
    font-size: 0.75rem;
}

.brief-day-row {
    cursor: pointer;
}

.brief-day-selected {
    background: rgba(16, 185, 129, 0.08);
    border-radius: var(--radius-sm);
}

.brief-day-selected .brief-day-abbr {
    color: #10b981;
}

.brief-agenda-header {
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.brief-agenda-event {
    display: flex;
    gap: 6px;
    padding: 2px 0;
    line-height: 1.4;
}

.brief-agenda-time {
    flex-shrink: 0;
    width: 36px;
    font-weight: 600;
    color: var(--accent-secondary);
    font-family: var(--font-mono);
    font-size: 0.7rem;
}

.brief-agenda-title {
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text-secondary);
}

.brief-agenda-loading,
.brief-agenda-empty {
    color: var(--text-muted);
    font-size: 0.72rem;
    padding: 4px 0;
}

/* Mobile: stack calendar vertically */
@media (max-width: 600px) {
    .brief-calendar-split {
        flex-direction: column;
    }
    .brief-cal-agenda {
        border-left: none;
        border-top: 1px solid rgba(255, 255, 255, 0.06);
        padding-left: 0;
        padding-top: 6px;
        margin-top: 4px;
    }
}

/* --- Deep Link Chips --- */
.brief-item-link {
    flex-shrink: 0;
    font-size: 0.62rem;
    font-weight: 600;
    color: var(--accent-primary);
    text-decoration: none;
    padding: 1px 6px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(99, 102, 241, 0.2);
    transition: var(--transition-fast);
    white-space: nowrap;
}

.brief-item-link:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.4);
}

/* --- CRUD Controls --- */
.brief-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 6px;
    margin-bottom: 2px;
}

.brief-crud-add {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    transition: var(--transition-fast);
    opacity: 0.4;
}

.brief-crud-add:hover {
    opacity: 1;
    color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.1);
}

.brief-add-input-wrap {
    margin-bottom: 4px;
}

.brief-add-input {
    width: 100%;
    padding: 4px 8px;
    font-size: 0.78rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    outline: none;
    transition: border-color var(--transition-fast);
}

.brief-add-input:focus {
    border-color: var(--accent-primary);
}

.brief-crud-check,
.brief-crud-remove {
    flex-shrink: 0;
    cursor: pointer;
    font-size: 0.7rem;
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition-fast);
    opacity: 0;
}

.brief-action-item:hover .brief-crud-check,
.brief-action-item:hover .brief-crud-remove {
    opacity: 0.5;
}

.brief-crud-check:hover {
    opacity: 1 !important;
    color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.brief-crud-remove:hover {
    opacity: 1 !important;
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

/* Mobile: always show CRUD buttons */
@media (max-width: 767px) {
    .brief-crud-check,
    .brief-crud-remove {
        opacity: 0.4;
        min-width: 44px;
        min-height: 44px;
    }
    .brief-crud-add {
        min-width: 44px;
        min-height: 44px;
        opacity: 0.6;
    }
}

.priority-pulse.all-clear {
    border-color: rgba(16, 185, 129, 0.2);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.05), var(--bg-card));
}

@keyframes pulse-fade-in {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

.pulse-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-sm);
}

.pulse-title {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
}

.pulse-count {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-secondary);
    padding: 2px 10px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.05);
}

.pulse-items {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pulse-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border-radius: var(--radius-md);
    font-size: 0.82rem;
    transition: var(--transition-fast);
    border-left: 3px solid transparent;
}

.pulse-item:hover {
    background: rgba(255, 255, 255, 0.03);
}

.pulse-item.pulse-overdue {
    border-left-color: #ef4444;
    background: rgba(239, 68, 68, 0.06);
}

.pulse-item.pulse-urgent {
    border-left-color: #f59e0b;
    background: rgba(245, 158, 11, 0.06);
}

.pulse-item.pulse-meeting {
    border-left-color: #6366f1;
    background: rgba(99, 102, 241, 0.06);
}

.pulse-item.pulse-work {
    border-left-color: #a855f7;
    background: rgba(168, 85, 247, 0.06);
}

.pulse-item.pulse-clear {
    border-left-color: #10b981;
    color: var(--text-secondary);
}

.pulse-item-icon {
    font-size: 1rem;
    flex-shrink: 0;
    width: 24px;
    text-align: center;
}

.pulse-item-label {
    flex: 1;
    color: var(--text-primary);
    line-height: 1.3;
}

.pulse-item-action {
    flex-shrink: 0;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-primary);
    text-decoration: none;
    padding: 3px 10px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(99, 102, 241, 0.2);
    background: none;
    font-family: inherit;
    cursor: pointer;
    transition: var(--transition-fast);
    white-space: nowrap;
}

.pulse-item-action:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.4);
}

/* Pulse glow animation for count badge when items > 0 */
.priority-pulse:not(.all-clear) .pulse-count {
    animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% { box-shadow: none; }
    50% { box-shadow: 0 0 8px rgba(99, 102, 241, 0.3); }
}

/* ============================================
   CARD HOVER IMPROVEMENTS
   ============================================ */

.portfolio-card:hover,
.project-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

@media (max-width: 768px) {
    .priority-pulse {
        padding: var(--spacing-md);
    }
    
    .pulse-item {
        padding: 8px 10px;
        font-size: 0.8rem;
    }
    
    .pulse-item-action {
        font-size: 0.7rem;
        padding: 2px 8px;
    }
}

/* ============================================
   SKIP LINK (Accessibility)
   ============================================ */

.skip-link {
    position: absolute;
    top: -50px;
    left: 0;
    padding: 8px 16px;
    background: var(--accent-primary);
    color: white;
    z-index: 10000;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 0 0 var(--radius-md) 0;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 0;
    outline: 2px solid white;
    outline-offset: 2px;
}

/* ============================================
   KEYBOARD HINT (discoverable shortcuts)
   ============================================ */

.keyboard-hint-float {
    position: fixed;
    bottom: 16px;
    right: 16px;
    display: none;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(18, 18, 26, 0.85);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    font-size: 0.75rem;
    color: var(--text-muted);
    z-index: 50;
    cursor: pointer;
    transition: var(--transition-fast);
}

.keyboard-hint-float:hover {
    color: var(--text-secondary);
    border-color: rgba(99, 102, 241, 0.3);
}

.keyboard-hint-float kbd {
    background: rgba(99, 102, 241, 0.2);
    padding: 1px 5px;
    border-radius: 3px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    color: var(--accent-primary);
}

@media (min-width: 768px) {
    .keyboard-hint-float {
        display: flex;
    }
}

/* ============================================
   TOOLTIP (title-based, enhanced)
   ============================================ */

[data-tooltip] {
    position: relative;
    cursor: help;
}

[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    padding: 6px 10px;
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-size: 0.7rem;
    line-height: 1.4;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.1);
    white-space: normal;
    max-width: 220px;
    width: max-content;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s, visibility 0.15s;
    z-index: 100;
    pointer-events: none;
}

[data-tooltip]:hover::after,
[data-tooltip]:focus::after {
    opacity: 1;
    visibility: visible;
}

/* ============================================
   COLLAPSIBLE CARDS
   ============================================ */

.card[data-collapsible] .section-header-row {
    cursor: pointer;
    user-select: none;
}

.card[data-collapsible] .section-header-row::after {
    content: '▾';
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-left: auto;
    padding-left: 8px;
    transition: transform 0.2s ease;
}

.card[data-collapsible].collapsed .section-header-row::after {
    transform: rotate(-90deg);
}

.card[data-collapsible] .card-body {
    transition: max-height 0.25s ease, opacity 0.2s ease;
    overflow: hidden;
}

.card[data-collapsible].collapsed .card-body {
    max-height: 0 !important;
    opacity: 0;
    margin: 0;
    padding: 0;
}

/* ============================================
   COLLAPSIBLE SECTIONS (Project Page)
   ============================================ */

.collapsible-section {
    overflow: hidden;
}

.collapsible-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-lg);
    cursor: pointer;
    user-select: none;
    transition: background var(--transition-fast);
}

.collapsible-toggle:hover {
    background: rgba(255, 255, 255, 0.02);
}

.collapsible-toggle h2 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.collapse-indicator {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease;
    color: var(--text-muted);
    flex-shrink: 0;
}

.collapse-indicator::before {
    content: '';
    border: solid var(--text-muted);
    border-width: 0 2px 2px 0;
    display: inline-block;
    padding: 3px;
    transform: rotate(-45deg);
    transition: transform 0.2s ease;
}

.collapse-indicator.open::before {
    transform: rotate(45deg);
}

.collapsible-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    padding: 0 var(--spacing-lg);
}

.collapsible-body.open {
    max-height: 3000px;
    padding: 0 var(--spacing-lg) var(--spacing-lg);
    overflow: visible;
}

/* Work project header stats (inline chips) */
.work-header-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: var(--spacing-lg);
}

.header-chip {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 500;
    background: rgba(99, 102, 241, 0.1);
    color: #a5b4fc;
    border: 1px solid rgba(99, 102, 241, 0.15);
}

.header-chip-muted {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-muted);
    border-color: rgba(255, 255, 255, 0.08);
}

/* ============================================
   HEALTH DOT & REPORT CARD COMPONENTS
   ============================================ */

/* Health dot (inline circle in portfolio cards) */
.health-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 6px;
    flex-shrink: 0;
    vertical-align: middle;
}

/* Portfolio card meta line (meetings, sprint, risks) */
.portfolio-preview {
    font-size: 0.7rem;
    color: var(--text-secondary);
    margin-top: 4px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.progress-fill-gradient {
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-green));
}

.portfolio-meta {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 4px;
    line-height: 1.3;
    opacity: 0.85;
}

/* Health badge (in report card header) */
.health-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 10px;
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* Report Card section styling — primary visual emphasis */
.report-card-section {
    border-left: 3px solid var(--accent-primary);
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.04), rgba(139, 92, 246, 0.02));
}

/* Intelligence section — secondary emphasis */
.intel-section {
    border-left: 3px solid rgba(16, 185, 129, 0.5);
}

/* Reference sections divider (visual grouping) */
.collapsible-section.reference-section {
    border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.rc-block {
    padding: var(--spacing-md) 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.rc-block:last-child {
    border-bottom: none;
}

.rc-block-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: var(--spacing-sm);
}

/* Report card meeting items */
.rc-meetings-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rc-meeting-item {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px;
    padding: 6px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.rc-meeting-item:last-child {
    border-bottom: none;
}

.rc-meeting-date {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
    flex-shrink: 0;
    min-width: 75px;
}

.rc-meeting-title {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
}

.rc-meeting-summary {
    flex-basis: 100%;
    font-size: 0.75rem;
    color: var(--text-secondary);
    line-height: 1.5;
    padding-left: 83px;
}

@media (max-width: 767px) {
    .rc-meeting-summary {
        padding-left: 0;
    }
}

/* Confluence chip row */
.rc-confluence-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.rc-chip {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 500;
    background: rgba(99, 102, 241, 0.12);
    color: #a5b4fc;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.rc-chip-done {
    background: rgba(34, 197, 94, 0.12);
    color: #86efac;
    border-color: rgba(34, 197, 94, 0.2);
}

.rc-chip-risk {
    background: rgba(234, 179, 8, 0.12);
    color: #fde047;
    border-color: rgba(234, 179, 8, 0.2);
}

.rc-chip-bug {
    background: rgba(239, 68, 68, 0.12);
    color: #fca5a5;
    border-color: rgba(239, 68, 68, 0.2);
}

/* Intelligence section */
.intel-section {
    border-left: 3px solid #8b5cf6;
}

.intel-source {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
    margin-bottom: var(--spacing-sm);
}

.intel-summary {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ============================================
   EXECUTIVE BRIEF
   ============================================ */

.exec-brief-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
}

.exec-brief-sources {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.exec-source-chip {
    font-size: 0.65rem;
    padding: 2px 8px;
    border-radius: 999px;
    background: rgba(255,255,255,0.06);
    color: var(--text-muted);
    border: 1px solid rgba(255,255,255,0.08);
}

.exec-block {
    margin-bottom: var(--spacing-md);
}

.exec-block-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-sm);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.exec-brief-summary {
    font-size: 0.9rem;
    line-height: 1.7;
    color: var(--text-primary);
    background: rgba(255,255,255,0.03);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    border-left: 3px solid var(--accent-primary, #6366f1);
}

/* KPI row */
.exec-kpi-row {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: var(--spacing-sm);
}

.exec-kpi-card {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-md);
    padding: var(--spacing-sm) var(--spacing-md);
    text-align: center;
}

.exec-kpi-card.exec-kpi-critical {
    border-color: rgba(239, 68, 68, 0.4);
    background: rgba(239, 68, 68, 0.06);
}

.exec-kpi-card.exec-kpi-ok {
    border-color: rgba(34, 197, 94, 0.4);
    background: rgba(34, 197, 94, 0.06);
}

.exec-kpi-metric {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 4px;
}

.exec-kpi-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.exec-kpi-target {
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-top: 2px;
}

/* Risks */
.exec-risks {
    list-style: none;
    padding: 0;
    margin: 0;
}

.exec-risk-item {
    padding: 6px 10px;
    margin-bottom: 4px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    background: rgba(239, 68, 68, 0.06);
    border-left: 3px solid rgba(239, 68, 68, 0.5);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* Meetings */
.exec-meetings {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.exec-meeting-item {
    display: flex;
    align-items: baseline;
    gap: 8px;
    font-size: 0.85rem;
    padding: 6px 10px;
    background: rgba(255,255,255,0.03);
    border-radius: var(--radius-sm);
}

.exec-meeting-title {
    font-weight: 600;
    color: var(--text-primary);
}

.exec-meeting-date {
    font-size: 0.75rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.exec-meeting-insight {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Actions */
.exec-actions {
    list-style: none;
    padding: 0;
    margin: 0;
}

.exec-action-item {
    padding: 6px 10px;
    margin-bottom: 4px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    background: rgba(99, 102, 241, 0.06);
    border-left: 3px solid rgba(99, 102, 241, 0.4);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* People */
.exec-people {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.exec-person {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-md);
    min-width: 90px;
}

.exec-person-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-primary);
}

.exec-person-role {
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-top: 2px;
}

/* Challenges */
.exec-challenges {
    list-style: none;
    padding: 0;
    margin: 0;
}

.exec-challenge-item {
    padding: 6px 10px;
    margin-bottom: 4px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    background: rgba(245, 158, 11, 0.06);
    border-left: 3px solid rgba(245, 158, 11, 0.4);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

@media (max-width: 600px) {
    .exec-kpi-row { grid-template-columns: repeat(2, 1fr); }
    .exec-meeting-item { flex-direction: column; gap: 2px; }
}

/* ============================================
   PROJECT PAGE — HERO CARD (v2)
   ============================================ */

.proj-hero {
    background: var(--bg-glass);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md) var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
    position: relative;
}

.ph-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.ph-back {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: color var(--transition-fast);
}
.ph-back:hover { color: var(--text-primary); }

.ph-health { flex-shrink: 0; }

.ph-health-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 12px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
}

.ph-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.ph-main-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--spacing-md);
}

.ph-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    line-height: 1.3;
}

.ph-right {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    flex-shrink: 0;
}

/* Sprint Expandable */
.ph-sprint-wrap { position: relative; }

.ph-sprint-btn {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--text-secondary);
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-family: inherit;
}
.ph-sprint-btn:hover { background: rgba(255,255,255,0.1); color: var(--text-primary); }

.ph-sprint-drawer {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 220px;
    background: var(--bg-card);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: var(--radius-md);
    padding: var(--spacing-sm);
    z-index: 50;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}
.ph-sprint-drawer--open { display: block; }

.ph-sd-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 8px;
    font-size: 0.8rem;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.ph-sd-row:last-child { border-bottom: none; }
.ph-sd-label { color: var(--text-muted); }
.ph-sd-val { color: var(--text-primary); font-weight: 500; }
.ph-sd-row--red .ph-sd-val { color: #f87171; }

/* Non-work meta (for MBA/regular projects) */
.ph-meta {
    display: flex;
    gap: var(--spacing-sm);
    color: var(--text-muted);
    font-size: 0.8rem;
    flex-wrap: wrap;
    margin-top: 6px;
    align-items: center;
}
.ph-meta .badge { padding: 2px 10px; border-radius: var(--radius-full); font-size: 0.7rem; font-weight: 600; }
.ph-desc { color: var(--text-secondary); font-size: 0.85rem; margin: 4px 0 0; }

/* Project Switcher */
.ph-switcher {
    display: flex;
    gap: 6px;
    margin-top: var(--spacing-sm);
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(255,255,255,0.05);
}

.ph-switch-pill {
    font-size: 0.72rem;
    padding: 3px 12px;
    border-radius: var(--radius-full);
    background: rgba(255,255,255,0.04);
    color: var(--text-muted);
    text-decoration: none;
    transition: all var(--transition-fast);
    border: 1px solid rgba(255,255,255,0.06);
}
.ph-switch-pill:hover { background: rgba(99,102,241,0.15); color: var(--accent-primary); border-color: rgba(99,102,241,0.3); }

/* Hero chips (kept for non-work) */
.proj-hero-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: var(--spacing-sm);
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(255,255,255,0.06);
}

/* ============================================
   PROJECT PAGE — COMMON STYLES
   ============================================ */

.badge-active { background: rgba(34, 197, 94, 0.2); color: #22c55e; }
.badge-paused { background: rgba(234, 179, 8, 0.2); color: #eab308; }
.badge-high { background: rgba(239, 68, 68, 0.2); color: #ef4444; }

.project-progress-large {
    margin: 0 0 var(--spacing-lg) 0;
}

.progress-bar-large {
    height: 12px;
    background: rgba(255,255,255,0.1);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: 8px;
}

.progress-fill-large {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    transition: width 0.5s ease;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.project-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-xl);
}

.stat-card {
    background: var(--bg-glass);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    text-align: center;
    border: 1px solid rgba(255,255,255,0.05);
}

.stat-card .number {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-card .label {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 4px;
}

.project-sections {
    display: grid;
    gap: var(--spacing-xl);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-md);
}

.section-header h2 {
    font-size: 1.125rem;
}

/* Task items */
.task-item-project {
    background: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-sm);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    border-left: 3px solid var(--accent-primary);
}

.task-item-project.status-done {
    opacity: 0.6;
    border-left-color: #22c55e;
}

.task-item-project.status-doing {
    border-left-color: #eab308;
}

.task-checkbox {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    border: 2px solid var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.task-checkbox.checked {
    background: #22c55e;
    border-color: #22c55e;
}

.task-checkbox.checked::after {
    content: '✓';
    color: white;
    font-size: 12px;
}

.task-info { flex: 1; }
.task-title { font-weight: 500; }
.task-meta { font-size: 0.75rem; color: var(--text-muted); margin-top: 2px; }

.btn-delete-subtle {
    background: none;
    border: none;
    cursor: pointer;
    opacity: 0.4;
    font-size: 1rem;
    transition: opacity var(--transition-fast);
}

.btn-delete-subtle:hover {
    opacity: 0.8;
}

/* Document items */
.doc-item {
    background: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-sm);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.doc-icon { font-size: 1.5rem; }
.doc-info { flex: 1; }
.doc-title { font-weight: 500; color: var(--accent-primary); }
.doc-title a { color: inherit; text-decoration: none; }
.doc-title a:hover { text-decoration: underline; }
.doc-desc { font-size: 0.8rem; color: var(--text-secondary); margin-top: 4px; line-height: 1.4; }

/* Note items */
.note-item {
    background: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-sm);
}

.note-header { display: flex; justify-content: space-between; margin-bottom: 8px; }
.note-title { font-weight: 600; }
.note-date { font-size: 0.75rem; color: var(--text-muted); }
.note-content { font-size: 0.875rem; color: var(--text-secondary); line-height: 1.5; }

/* Empty section */
.empty-section {
    text-align: center;
    padding: var(--spacing-xl);
    color: var(--text-muted);
}

/* Add forms */
.add-form {
    background: var(--bg-glass);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-md);
    display: none;
}

.add-form.active { display: block; }

.add-form input, .add-form textarea, .add-form select {
    width: 100%;
    padding: 10px;
    background: var(--bg-card);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    margin-bottom: 10px;
}

.add-form .form-row { display: flex; gap: 10px; }

.add-form-textarea {
    width: 100%;
    padding: 10px;
    background: var(--bg-card);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    margin-bottom: 10px;
    resize: vertical;
}

/* File items */
.file-item {
    background: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-sm);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    border-left: 3px solid transparent;
}

.file-item:hover {
    background: var(--bg-card-hover);
    border-left-color: var(--accent-primary);
}

.file-item.type-epic { border-left-color: #f59e0b; background: rgba(245,158,11,0.05); }
.file-item.type-draft { border-left-color: #8b5cf6; }
.file-icon { font-size: 1.25rem; width: 30px; text-align: center; }
.file-info { flex: 1; }
.file-name { font-weight: 500; color: var(--text-primary); }
.file-meta { font-size: 0.75rem; color: var(--text-muted); }

/* Document preview */
.doc-preview-wrapper { position: relative; }

.doc-preview-content {
    background: var(--bg-glass);
    padding: var(--spacing-lg);
    border-radius: var(--radius-md);
    max-height: 70vh;
    overflow-y: auto;
    font-family: var(--font-family);
    line-height: 1.8;
    scrollbar-width: thin;
    scrollbar-color: rgba(99,102,241,0.4) transparent;
}

.doc-preview-content::-webkit-scrollbar { width: 8px; }
.doc-preview-content::-webkit-scrollbar-track { background: transparent; }
.doc-preview-content::-webkit-scrollbar-thumb { background: rgba(99,102,241,0.4); border-radius: 4px; }
.doc-preview-content::-webkit-scrollbar-thumb:hover { background: rgba(99,102,241,0.6); }

.doc-preview-wrapper::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 40px;
    background: linear-gradient(transparent, var(--bg-card));
    pointer-events: none;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    opacity: 0;
    transition: opacity 0.3s;
}

.doc-preview-wrapper.has-scroll::after { opacity: 1; }

/* Fullscreen overlay */
.fullscreen-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.95);
    z-index: 1000;
    padding: 20px;
    overflow-y: auto;
}

.fullscreen-overlay.active { display: block; }

.fullscreen-content {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
}

.fullscreen-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.fullscreen-header h2 { font-size: 1.5rem; color: var(--text-primary); }

.fullscreen-close {
    background: var(--bg-glass);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.fullscreen-close:hover { background: var(--bg-glass-hover); color: var(--text-primary); }

.preview-actions { display: flex; gap: 8px; }

.btn-icon {
    background: var(--bg-glass);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--text-secondary);
    padding: 8px 12px;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 0.875rem;
}

.btn-icon:hover { background: var(--bg-glass-hover); color: var(--text-primary); }

/* Markdown content rendering */
.doc-preview-content h1 { font-size: 1.5rem; margin: 1em 0 0.5em; color: var(--text-primary); }
.doc-preview-content h2 { font-size: 1.25rem; margin: 1em 0 0.5em; color: var(--text-primary); border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 0.3em; }
.doc-preview-content h3 { font-size: 1.1rem; margin: 1em 0 0.5em; color: var(--text-secondary); }
.doc-preview-content p { margin: 0.5em 0; color: var(--text-secondary); }
.doc-preview-content ul, .doc-preview-content ol { margin: 0.5em 0; padding-left: 1.5em; color: var(--text-secondary); }
.doc-preview-content li { margin: 0.25em 0; }
.doc-preview-content code { background: rgba(0,0,0,0.3); padding: 2px 6px; border-radius: 4px; font-family: 'JetBrains Mono', monospace; font-size: 0.9em; }
.doc-preview-content pre { background: rgba(0,0,0,0.3); padding: 1em; border-radius: 8px; overflow-x: auto; margin: 1em 0; }
.doc-preview-content pre code { background: none; padding: 0; }
.doc-preview-content table { width: 100%; border-collapse: collapse; margin: 1em 0; }
.doc-preview-content th, .doc-preview-content td { border: 1px solid rgba(255,255,255,0.1); padding: 8px 12px; text-align: left; }
.doc-preview-content th { background: rgba(255,255,255,0.05); }
.doc-preview-content blockquote { border-left: 3px solid var(--accent-primary); padding-left: 1em; margin: 1em 0; color: var(--text-muted); font-style: italic; }
.doc-preview-content hr { border: none; border-top: 1px solid rgba(255,255,255,0.1); margin: 1.5em 0; }
.doc-preview-content input[type="checkbox"] { margin-right: 8px; }

/* Work project view: overview grid */
.overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-lg);
}

.overview-card {
    background: var(--bg-glass);
    padding: var(--spacing-lg);
    border-radius: var(--radius-md);
    border-left: 3px solid var(--accent-primary);
}

.overview-card.full-width { grid-column: 1 / -1; }
.overview-card h3 { font-size: 0.875rem; color: var(--text-muted); margin-bottom: var(--spacing-sm); font-weight: 600; }
.overview-card p { color: var(--text-secondary); font-size: 0.9rem; line-height: 1.6; }

/* Documentation sections grid */
.sections-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--spacing-md);
}

.section-item {
    background: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    border-left: 3px solid transparent;
}

.section-item:hover {
    background: var(--bg-card-hover);
    border-left-color: var(--accent-primary);
    transform: translateX(4px);
}

.section-item .section-name { font-weight: 600; color: var(--text-primary); margin-bottom: 4px; }
.section-item .section-summary { font-size: 0.8rem; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Meeting items */
.meeting-item {
    background: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
    border-left: 3px solid #3b82f6;
}

.meeting-item:hover { background: var(--bg-card-hover); transform: translateX(4px); }
.meeting-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.meeting-title { font-weight: 600; color: var(--text-primary); }
.meeting-date { font-size: 0.75rem; color: var(--accent-primary); background: rgba(99,102,241,0.1); padding: 2px 8px; border-radius: var(--radius-full); }
.meeting-preview { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Case items */
.case-item {
    background: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
    border-left: 3px solid #f59e0b;
}

.case-item:hover { background: var(--bg-card-hover); }

/* ============================================
   TAB BAR
   ============================================ */

.sp-tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    margin-bottom: var(--spacing-lg);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.sp-tab {
    background: none;
    border: none;
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 12px 20px;
    cursor: pointer;
    white-space: nowrap;
    position: relative;
    transition: color var(--transition-fast);
    border-bottom: 2px solid transparent;
}

.sp-tab:hover { color: var(--text-secondary); }
.sp-tab:focus-visible { outline: 2px solid var(--accent-primary); outline-offset: -2px; border-radius: 4px; }
.sp-tab--active { color: var(--accent-primary); border-bottom-color: var(--accent-primary); }

.sp-tab-badge {
    font-size: 0.7rem;
    background: rgba(255,255,255,0.08);
    color: var(--text-muted);
    padding: 1px 7px;
    border-radius: var(--radius-full);
    margin-left: 4px;
    vertical-align: middle;
}
.sp-tab--active .sp-tab-badge { background: rgba(99,102,241,0.2); color: var(--accent-primary); }

/* ============================================
   PANELS
   ============================================ */

.sp-panel { animation: sp-fadeIn 0.2s ease; }
.sp-panel--hidden { display: none !important; }
@keyframes sp-fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }

.sp-text-muted { color: var(--text-muted); font-style: italic; font-size: 0.85rem; }
.sp-empty-state { text-align: center; padding: var(--spacing-xl) var(--spacing-lg); color: var(--text-muted); font-size: 0.9rem; }

/* ============================================
   THIS-WEEK MEETINGS BAR (above exec brief)
   ============================================ */

.sp-week-bar {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 10px var(--spacing-md);
    margin-bottom: var(--spacing-md);
    border: 1px solid rgba(255,255,255,0.06);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    overflow-x: auto;
}

.sp-week-bar-label {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    white-space: nowrap;
    flex-shrink: 0;
}

.sp-week-bar-list {
    display: flex;
    gap: 8px;
    flex-wrap: nowrap;
    overflow-x: auto;
}

.sp-week-pill {
    font-size: 0.78rem;
    color: var(--text-secondary);
    padding: 4px 12px;
    border-radius: var(--radius-full);
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.06);
    white-space: nowrap;
    flex-shrink: 0;
}

.sp-week-pill-date {
    color: var(--text-muted);
    font-size: 0.7rem;
    margin-right: 4px;
}

/* ============================================
   EXECUTIVE BRIEF (unified card)
   ============================================ */

.eb-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    border: 1px solid rgba(255,255,255,0.06);
    border-left: 3px solid #6366f1;
}

.eb-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-md);
}

.eb-title {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin: 0;
}

.eb-sources { display: flex; gap: 4px; flex-wrap: wrap; }
.eb-source-chip {
    font-size: 0.65rem;
    background: rgba(99,102,241,0.15);
    color: #a5b4fc;
    padding: 1px 8px;
    border-radius: var(--radius-full);
}

/* Summary */
.eb-summary {
    font-size: 0.92rem;
    line-height: 1.7;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-md);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.eb-summary p { margin: 0 0 8px 0; }
.eb-summary p:last-child { margin-bottom: 0; }
.eb-summary strong { color: var(--text-primary); font-weight: 600; }
.eb-summary ul, .eb-summary ol { margin: 4px 0 8px 0; padding-left: 20px; }
.eb-summary li { margin-bottom: 4px; }

/* KPIs (inline row inside brief) */
.eb-kpis {
    display: flex;
    gap: var(--spacing-sm);
    overflow-x: auto;
    padding-bottom: var(--spacing-md);
    margin-bottom: var(--spacing-md);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    -webkit-overflow-scrolling: touch;
}

.eb-kpi {
    flex: 1 1 0;
    min-width: 110px;
    background: rgba(255,255,255,0.03);
    border-radius: var(--radius-md);
    padding: 10px var(--spacing-md);
    border-top: 3px solid rgba(255,255,255,0.08);
    text-align: center;
}
.eb-kpi--green { border-top-color: #22c55e; }
.eb-kpi--red { border-top-color: #ef4444; }

.eb-kpi-label {
    font-size: 0.66rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    margin-bottom: 2px;
}
.eb-kpi-value {
    font-size: 1.15rem;
    font-weight: 700;
    font-family: 'JetBrains Mono', monospace;
    color: var(--text-primary);
}
.eb-kpi-target { font-size: 0.65rem; color: var(--text-muted); margin-top: 1px; }

/* Two-column: Risks | Actions */
.eb-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-md);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.eb-col-title {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin: 0 0 var(--spacing-sm) 0;
    display: flex;
    align-items: center;
    gap: 6px;
}
.eb-col-title--red { color: #f87171; }
.eb-col-title--indigo { color: #a5b4fc; }

.eb-col-count {
    font-size: 0.68rem;
    font-weight: 600;
    padding: 1px 7px;
    border-radius: var(--radius-full);
    background: rgba(255,255,255,0.08);
    color: var(--text-muted);
}

.eb-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.eb-list-item {
    padding: 6px 0;
    border-bottom: 1px solid rgba(255,255,255,0.03);
    font-size: 0.84rem;
    color: var(--text-secondary);
    line-height: 1.5;
    position: relative;
    padding-left: 14px;
}
.eb-list-item:last-child { border-bottom: none; }

.eb-list-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 13px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(255,255,255,0.15);
}
.eb-list-item--red::before { background: #f87171; }
.eb-list-item--indigo::before { background: #818cf8; }
.eb-list-item--amber::before { background: #fbbf24; }

/* People (inline) */
.eb-section { margin-bottom: var(--spacing-md); }
.eb-section:last-child { margin-bottom: 0; }

.eb-section-title {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin: 0 0 var(--spacing-sm) 0;
}

.eb-people {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.eb-person {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255,255,255,0.04);
    padding: 4px 12px 4px 4px;
    border-radius: var(--radius-full);
    font-size: 0.82rem;
    color: var(--text-primary);
    border: 1px solid rgba(255,255,255,0.06);
}

.eb-person-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: linear-gradient(135deg, #06b6d4, #818cf8);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.6rem;
    font-weight: 700;
    color: white;
}

.eb-person-role {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-left: 2px;
}

/* Executive Brief v2 — New Sections */

.eb-updated {
    font-size: 0.7rem;
    color: var(--text-muted);
    opacity: 0.7;
}

.eb-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-sm);
}
.eb-section-header .eb-section-title { margin-bottom: 0; }

.eb-link-btn {
    background: none;
    border: none;
    color: #818cf8;
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    transition: background var(--transition-fast);
}
.eb-link-btn:hover { background: rgba(129,140,248,0.12); }

/* Status text */
.eb-status-text {
    font-size: 0.92rem;
    line-height: 1.7;
    color: var(--text-secondary);
}
.eb-status-text p { margin: 0 0 6px 0; }
.eb-status-text p:last-child { margin-bottom: 0; }
.eb-status-text strong { color: var(--text-primary); font-weight: 600; }

/* Important Dates */
.eb-dates-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.eb-date-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}
.eb-date-badge {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    background: rgba(245,158,11,0.12);
    color: #fbbf24;
    white-space: nowrap;
}
.eb-date-type {
    font-size: 0.68rem;
    padding: 1px 6px;
    border-radius: var(--radius-full);
    background: rgba(255,255,255,0.05);
    color: var(--text-muted);
}

/* Meeting Cards (in brief) */
.eb-meetings-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.eb-meeting-card {
    background: rgba(255,255,255,0.03);
    border-radius: var(--radius-md);
    padding: 10px 14px;
    border-left: 3px solid rgba(99,102,241,0.35);
}
.eb-meeting-header {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 4px;
}
.eb-meeting-date {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.72rem;
    color: var(--text-muted);
    white-space: nowrap;
}
.eb-meeting-title {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
}
.eb-meeting-brief {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 6px;
}
.eb-meeting-people {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}
.eb-person--sm { font-size: 0.72rem; padding: 2px 8px 2px 2px; }
.eb-person-avatar--sm { width: 20px; height: 20px; font-size: 0.5rem; }

/* Carousel wrapper with arrows */
.carousel-wrapper {
    display: flex;
    align-items: center;
    gap: 0;
    position: relative;
    margin-bottom: 12px;
}
.carousel-arrow {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-subtle);
    border-radius: 50%;
    background: var(--bg-card);
    color: var(--text-secondary);
    font-size: 1.2rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    z-index: 2;
}
.carousel-arrow:hover {
    background: var(--accent-primary);
    color: #fff;
    border-color: var(--accent-primary);
}

/* Horizontal Meeting/Doc Tabs — Carousel */
.eb-meeting-tabs {
    display: flex;
    flex-wrap: nowrap;
    flex: 1;
    min-width: 0;
    gap: 6px;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    padding: 0 8px 4px;
}
.eb-meeting-tabs::-webkit-scrollbar { display: none; }
.eb-meeting-tab {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    padding: 8px 14px;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    background: rgba(255,255,255,0.02);
    cursor: pointer;
    transition: all var(--transition-fast);
    text-align: left;
    min-width: 120px;
    max-width: 200px;
    scroll-snap-align: start;
}
.eb-meeting-tab:hover { background: rgba(99,102,241,0.06); border-color: rgba(99,102,241,0.3); }
.eb-meeting-tab--active {
    background: rgba(99,102,241,0.1);
    border-color: var(--accent-primary);
    box-shadow: 0 2px 8px rgba(99,102,241,0.15);
}
.eb-mt-date {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    color: var(--text-muted);
}
.eb-meeting-tab--active .eb-mt-date { color: var(--accent-primary); }
.eb-mt-title {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 170px;
}
.eb-meeting-tab--active .eb-mt-title { color: var(--text-primary); }

/* Meeting Detail Panel */
.eb-meeting-detail {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 16px 18px;
}
.eb-md-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 4px;
}
.eb-md-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.eb-md-notion-link {
    color: var(--accent-primary);
    text-decoration: none;
    font-size: 0.72rem;
}
.eb-md-notion-link:hover { text-decoration: underline; }
.eb-md-section { margin-bottom: 12px; }
.eb-md-label {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 6px;
}
.eb-md-people { display: flex; flex-wrap: wrap; gap: 6px; }
.eb-md-list {
    margin: 0;
    padding-left: 18px;
    font-size: 0.82rem;
    line-height: 1.6;
    color: var(--text-secondary);
}
.eb-md-list--indigo li { border-left: 2px solid rgba(99,102,241,0.35); padding-left: 8px; margin-bottom: 4px; list-style: none; }
.eb-md-content { font-size: 0.82rem; color: var(--text-secondary); line-height: 1.6; }
.eb-md-content p { margin: 0 0 6px; }
.eb-md-rationale { font-size: 0.72rem; color: var(--text-muted); font-style: italic; }
.eb-md-empty { font-size: 0.8rem; color: var(--text-muted); padding: 12px 0; }

/* (eb-todo-check removed — project todos now use brief-crud-check from dashboard) */

/* Decisions */
.eb-decision-date {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-right: 6px;
}
.eb-decision-source {
    font-size: 0.68rem;
    color: var(--text-muted);
    margin-left: 4px;
    opacity: 0.7;
}

/* To-do priority badges */
.eb-todo-priority {
    font-size: 0.66rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 1px 6px;
    border-radius: var(--radius-full);
    margin-right: 6px;
}
.eb-todo-priority--high {
    background: rgba(239,68,68,0.15);
    color: #f87171;
}
.eb-todo-priority--urgent {
    background: rgba(239,68,68,0.25);
    color: #ef4444;
}
.eb-todo-priority--normal {
    background: rgba(255,255,255,0.06);
    color: var(--text-muted);
}
.eb-todo-priority--low {
    background: rgba(255,255,255,0.04);
    color: var(--text-muted);
    opacity: 0.7;
}

.reminder-check--done {
    background: rgba(34,197,94,0.2) !important;
    border-color: #22c55e !important;
}
.reminder-check--done::after {
    content: '\2713';
    color: #22c55e;
    font-size: 0.7rem;
    font-weight: bold;
}
.reminder-title--done {
    text-decoration: line-through;
    opacity: 0.5;
}

/* Upcoming Meetings */
.eb-upcoming-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.eb-upcoming-item {
    padding: 8px 12px;
    background: rgba(255,255,255,0.03);
    border-radius: var(--radius-md);
    border-left: 3px solid rgba(34,197,94,0.35);
}
.eb-upcoming-header {
    display: flex;
    align-items: baseline;
    gap: 10px;
}
.eb-upcoming-date {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.72rem;
    color: #22c55e;
    white-space: nowrap;
}
.eb-upcoming-title {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
}
.eb-upcoming-prep {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 4px;
    padding-left: 2px;
    font-style: italic;
}

/* ============================================
   MEETINGS TAB — UPCOMING PREP
   ============================================ */

.mt-upcoming { margin-bottom: var(--spacing-lg); }

.mt-prep-card {
    background: var(--bg-card);
    border: 1px solid rgba(99,102,241,0.2);
    border-left: 3px solid #6366f1;
    border-radius: var(--radius-lg);
    padding: var(--spacing-md) var(--spacing-lg);
    margin-bottom: var(--spacing-sm);
}

.mt-prep-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    flex-wrap: wrap;
}

.mt-prep-badge {
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    background: rgba(99,102,241,0.2);
    color: #a5b4fc;
}

.mt-prep-date {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
}

.mt-prep-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
}

.mt-prep-details { margin-top: var(--spacing-sm); }

.mt-prep-toggle {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--accent-primary);
    cursor: pointer;
    padding: 4px 0;
    list-style: none;
    user-select: none;
}
.mt-prep-toggle::-webkit-details-marker { display: none; }
.mt-prep-toggle::before {
    content: '▸ ';
    display: inline;
}
details[open] > .mt-prep-toggle::before { content: '▾ '; }

.mt-prep-body {
    margin-top: var(--spacing-sm);
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(255,255,255,0.05);
}

.mt-prep-context {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: var(--spacing-md);
    padding: var(--spacing-sm) var(--spacing-md);
    background: rgba(255,255,255,0.02);
    border-radius: var(--radius-sm);
    border-left: 2px solid rgba(255,255,255,0.08);
}

.mt-prep-section { margin-bottom: var(--spacing-md); }

.mt-prep-label {
    display: block;
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.mt-prep-people { display: flex; flex-wrap: wrap; gap: 6px; }

.mt-prep-actions, .mt-prep-risks {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mt-prep-action, .mt-prep-risk {
    font-size: 0.8rem;
    color: var(--text-secondary);
    padding: 4px 0;
    padding-left: 14px;
    position: relative;
}
.mt-prep-action::before, .mt-prep-risk::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
}
.mt-prep-action::before { background: #818cf8; }
.mt-prep-risk::before { background: #f87171; }

.mt-prep-docs {
    margin-top: var(--spacing-sm);
}
.mt-prep-docs a {
    font-size: 0.8rem;
    color: var(--accent-primary);
    text-decoration: none;
}
.mt-prep-docs a:hover { text-decoration: underline; }

/* ============================================
   MEETINGS TAB — KEY INSIGHTS
   ============================================ */

.mt-insights {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md) var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
    border: 1px solid rgba(255,255,255,0.06);
    border-left: 3px solid #f59e0b;
}

.mt-insights-title {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin: 0 0 var(--spacing-sm) 0;
}

.mt-insights-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.mt-insight-item {
    display: flex;
    gap: var(--spacing-sm);
    align-items: baseline;
    font-size: 0.84rem;
    line-height: 1.5;
}

.mt-insight-topic {
    font-weight: 600;
    color: var(--text-primary);
    flex-shrink: 0;
    white-space: nowrap;
}

.mt-insight-topic::after { content: ' —'; color: var(--text-muted); }

.mt-insight-text {
    color: var(--text-secondary);
}

/* ============================================
   TIMELINE (Meetings Tab)
   ============================================ */

.sp-timeline { position: relative; }

.sp-week-group { margin-bottom: var(--spacing-xl); }

.sp-week-header {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    padding-bottom: 8px;
    margin-bottom: var(--spacing-sm);
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.sp-timeline-item {
    display: flex;
    gap: var(--spacing-md);
    padding: 12px 0;
    position: relative;
    border-left: 2px solid rgba(255,255,255,0.06);
    margin-left: 5px;
    padding-left: var(--spacing-lg);
}
.sp-timeline-item--clickable { cursor: pointer; }
.sp-timeline-item--clickable:hover .sp-timeline-title { color: var(--accent-primary); }

.sp-timeline-dot {
    position: absolute;
    left: -5px;
    top: 18px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent-primary);
    border: 2px solid var(--bg-primary);
}

.sp-timeline-content { flex: 1; min-width: 0; }
.sp-timeline-date { font-size: 0.72rem; color: var(--text-muted); font-weight: 500; margin-bottom: 2px; }
.sp-timeline-title { font-size: 0.9rem; font-weight: 500; color: var(--text-primary); transition: color var(--transition-fast); }
.sp-timeline-insight { font-size: 0.8rem; color: var(--text-muted); margin-top: 4px; line-height: 1.5; }

/* ============================================
   DOCS LIST (replaces tile grid)
   ============================================ */

.dl-section { margin-bottom: var(--spacing-xl); }

.dl-heading {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 var(--spacing-md) 0;
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.dl-count {
    font-size: 0.68rem;
    background: rgba(255,255,255,0.08);
    color: var(--text-muted);
    padding: 1px 7px;
    border-radius: var(--radius-full);
}

.dl-list { display: flex; flex-direction: column; gap: 2px; }

.dl-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: 12px var(--spacing-md);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    border-left: 3px solid transparent;
}
.dl-item:hover {
    background: rgba(255,255,255,0.03);
    border-left-color: var(--accent-primary);
}

.dl-icon { font-size: 1.1rem; flex-shrink: 0; }

.dl-item-body { flex: 1; min-width: 0; }

.dl-item-name {
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.dl-item-summary {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dl-arrow {
    font-size: 1.2rem;
    color: var(--text-muted);
    flex-shrink: 0;
    opacity: 0;
    transition: opacity var(--transition-fast);
}
.dl-item:hover .dl-arrow { opacity: 1; }

/* Project Identity (kept for Docs tab) */
.sp-identity {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
}

.sp-id-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: var(--spacing-md);
    border: 1px solid rgba(255,255,255,0.06);
}

.sp-id-label {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.sp-id-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.6;
}
.sp-id-text p { margin: 0 0 6px 0; }
.sp-id-text p:last-child { margin-bottom: 0; }
.sp-id-text strong { color: var(--text-primary); font-weight: 600; }

/* ============================================
   WORK PROJECT PAGE — RESPONSIVE
   ============================================ */

@media (max-width: 767px) {
    .sp-tabs { gap: 0; overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .sp-tab { padding: 10px 14px; font-size: 0.82rem; min-height: 44px; white-space: nowrap; }
    .sp-identity { grid-template-columns: 1fr; }
    .eb-columns { grid-template-columns: 1fr; gap: var(--spacing-md); }
    .eb-kpis { flex-wrap: nowrap; }
    .eb-kpi { min-width: 100px; }
    .ph-main-row { flex-direction: column; align-items: flex-start; gap: 8px; }
    .ph-title { font-size: 1.25rem; }
    .ph-sprint-drawer { right: auto; left: 0; }
    .sp-week-bar { flex-direction: column; align-items: flex-start; }
    .eb-header { flex-direction: column; align-items: flex-start; gap: 6px; }
    .eb-people { gap: 6px; }
    .eb-person { font-size: 0.78rem; }
    .mt-insight-item { flex-direction: column; gap: 2px; }
    .mt-prep-card { padding: var(--spacing-md); }
    .mt-prep-header { flex-direction: column; align-items: flex-start; gap: 4px; }
    .eb-meeting-tab { min-height: 44px; padding: 8px 14px; }
    .eb-card { padding: var(--spacing-md); }
    .eb-section { padding: var(--spacing-sm) 0; }
    .brief-crud-check, .brief-crud-remove { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; }
    .ph-switcher { overflow-x: auto; -webkit-overflow-scrolling: touch; flex-wrap: nowrap; padding-bottom: 4px; }
    .ph-switch-pill { min-height: 36px; white-space: nowrap; }
}

@media (min-width: 768px) and (max-width: 1199px) {
    .eb-columns { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 1200px) {
    .eb-columns { grid-template-columns: 1fr 1fr; }
}

/* ============================================
   PROJECT PAGE — RESPONSIVE (non-work)
   ============================================ */

@media (max-width: 767px) {
    .proj-hero { padding: var(--spacing-sm) var(--spacing-md); }
    .project-stats { grid-template-columns: repeat(2, 1fr); }
    .project-sections { gap: var(--spacing-md); }
    .task-item-project { flex-wrap: wrap; gap: var(--spacing-sm); }
    .task-item-project .task-info { min-width: 0; flex: 1; }
    .doc-item, .note-item, .file-item { flex-direction: column; align-items: flex-start; }
    .section-header h2 { font-size: 1rem; }
    .markdown-content { overflow-x: auto; word-break: break-word; }
    .markdown-content pre { overflow-x: auto; max-width: calc(100vw - 48px); }
    .markdown-content table { display: block; overflow-x: auto; }
}

@media (min-width: 768px) {
    .project-sections { grid-template-columns: repeat(2, 1fr); }
    .project-sections > section:first-child { grid-column: span 2; }
    .project-stats { grid-template-columns: repeat(5, 1fr); }
    .task-item-project, .file-item, .doc-item, .note-item { padding: var(--spacing-lg); }
}

@media (min-width: 1200px) {
    .project-sections { grid-template-columns: repeat(3, 1fr); }
    .project-sections > section:first-child { grid-column: span 3; }
}

/* ============================================
   GLOBAL FOOTER
   ============================================ */

.site-footer {
    text-align: center;
    padding: 20px;
    color: var(--text-muted);
    font-size: 0.75rem;
}

.site-footer kbd {
    background: rgba(255, 255, 255, 0.06);
    padding: 1px 5px;
    border-radius: 3px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
}

/* Bottom nav on mobile -- support 6 items */
@media (max-width: 767px) {
    .bottom-nav .nav-item {
        padding: var(--spacing-sm) var(--spacing-md);
    }
    
    .nav-label {
        font-size: 0.55rem;
    }
}

/* ============================================
   BANCO TRADICAO DESIGN SYSTEM — Shared Patterns
   ============================================ */

/* --- Section Headers (centered, BT-style) --- */

.section-header-centered {
    text-align: center;
    margin-bottom: 48px;
}

.section-label {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent-cyan);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 12px;
}

.section-title-lg {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.section-description {
    font-size: 1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* --- Utility Grid Classes --- */

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

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

@media (max-width: 1200px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }
}

/* --- Metric / Progress Bars (gradient fill) --- */

.metric-bar {
    margin-bottom: 20px;
}

.metric-bar-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.metric-bar-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.metric-bar-value {
    font-size: 0.9rem;
    font-weight: 600;
    font-family: var(--font-mono);
}

.metric-bar-track {
    height: 10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    overflow: hidden;
}

.metric-bar-fill {
    height: 100%;
    border-radius: 5px;
    transition: width 1s ease-out;
}

.fill-green   { background: linear-gradient(90deg, #10b981, #059669); }
.fill-cyan    { background: linear-gradient(90deg, #00d4ff, #0891b2); }
.fill-purple  { background: linear-gradient(90deg, #7c3aed, #6d28d9); }
.fill-orange  { background: linear-gradient(90deg, #f59e0b, #d97706); }
.fill-red     { background: linear-gradient(90deg, #ef4444, #dc2626); }
.fill-pink    { background: linear-gradient(90deg, #ec4899, #db2777); }
.fill-indigo  { background: linear-gradient(90deg, #6366f1, #4f46e5); }

/* --- Card Icon Containers --- */

.card-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.card-icon.cyan    { background: rgba(0, 212, 255, 0.2); }
.card-icon.purple  { background: rgba(124, 58, 237, 0.2); }
.card-icon.green   { background: rgba(16, 185, 129, 0.2); }
.card-icon.orange  { background: rgba(245, 158, 11, 0.2); }
.card-icon.red     { background: rgba(239, 68, 68, 0.2); }
.card-icon.pink    { background: rgba(236, 72, 153, 0.2); }
.card-icon.indigo  { background: rgba(99, 102, 241, 0.2); }

/* --- Highlight Stat Cards --- */

.highlight-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 24px;
}

.highlight-stat {
    text-align: center;
    padding: 20px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 15px;
    border: 1px solid var(--border-color);
    transition: all var(--transition-base);
}

.highlight-stat:hover {
    background: rgba(255, 255, 255, 0.04);
    transform: translateY(-2px);
}

.highlight-stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-primary);
    font-family: var(--font-mono);
}

.highlight-stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 5px;
}

@media (max-width: 1200px) {
    .highlight-stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .highlight-stats { grid-template-columns: 1fr; }
}

/* --- Risk / List Items (side color indicator) --- */

.risk-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    margin-bottom: 10px;
    transition: background var(--transition-fast);
}

.risk-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.risk-level {
    width: 4px;
    height: 40px;
    border-radius: 4px;
    flex-shrink: 0;
}

.risk-level.critical { background: var(--accent-red); }
.risk-level.high     { background: var(--accent-orange); }
.risk-level.medium   { background: #eab308; }
.risk-level.low      { background: var(--accent-green); }

.risk-content {
    flex: 1;
}

.risk-title {
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--text-primary);
}

.risk-mitigation {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.risk-badge {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    white-space: nowrap;
}

/* --- Accent Top-bar on Cards --- */

.card-accent-top {
    position: relative;
    overflow: hidden;
}

.card-accent-top::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    z-index: 1;
}

.card-accent-top.accent-green::before  { background: var(--accent-green); }
.card-accent-top.accent-red::before    { background: var(--accent-red); }
.card-accent-top.accent-orange::before { background: var(--accent-orange); }
.card-accent-top.accent-cyan::before   { background: var(--accent-cyan); }
.card-accent-top.accent-purple::before { background: var(--accent-secondary); }
.card-accent-top.accent-pink::before   { background: var(--accent-pink); }
.card-accent-top.accent-indigo::before { background: var(--accent-primary); }

/* --- Persona / Quote Callout --- */

.persona-quote {
    font-style: italic;
    color: var(--text-secondary);
    padding: 15px;
    background: rgba(255, 255, 255, 0.03);
    border-left: 3px solid var(--accent-secondary);
    border-radius: 0 10px 10px 0;
    margin: 16px 0;
    line-height: 1.5;
}

/* --- Pill Tags (colored) --- */

.pill-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 500;
}

.pill-tag.green   { background: rgba(16, 185, 129, 0.2); color: var(--accent-green); }
.pill-tag.red     { background: rgba(239, 68, 68, 0.2); color: var(--accent-red); }
.pill-tag.orange  { background: rgba(245, 158, 11, 0.2); color: var(--accent-orange); }
.pill-tag.cyan    { background: rgba(0, 212, 255, 0.2); color: var(--accent-cyan); }
.pill-tag.purple  { background: rgba(124, 58, 237, 0.2); color: var(--accent-secondary); }
.pill-tag.pink    { background: rgba(236, 72, 153, 0.2); color: var(--accent-pink); }
.pill-tag.indigo  { background: rgba(99, 102, 241, 0.2); color: var(--accent-primary); }

/* --- Pain List Items --- */

.pain-list {
    list-style: none;
}

.pain-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.pain-list li:last-child {
    border-bottom: none;
}

.pain-list .icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

/* --- Insight / Callout Box --- */

.insight-box {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.1) 100%);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 20px;
    padding: 32px;
    text-align: center;
}

.insight-box h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--accent-primary);
}

.insight-box p {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* --- Flow Diagram Steps --- */

.flow-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    padding: 32px 0;
}

.flow-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.flow-box {
    width: 120px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 10px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 2px solid;
    color: var(--text-primary);
}

.flow-box.start      { background: rgba(16, 185, 129, 0.2); border-color: var(--accent-green); }
.flow-box.process    { background: rgba(0, 212, 255, 0.1); border-color: var(--accent-cyan); }
.flow-box.decision   { background: rgba(245, 158, 11, 0.2); border-color: var(--accent-orange); }
.flow-box.bottleneck { background: rgba(239, 68, 68, 0.2); border-color: var(--accent-red); }
.flow-box.end-step   { background: rgba(124, 58, 237, 0.2); border-color: var(--accent-secondary); }

.flow-time {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.flow-arrow {
    font-size: 1.5rem;
    color: var(--text-muted);
}

/* ===============================================
   UX FIXES — Feb 2026 (from UX evaluation reports)
   =============================================== */

/* Toast notification */
.ux-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: var(--card-bg);
    color: var(--text-primary);
    border: 1px solid var(--accent-green);
    padding: 10px 24px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s, transform 0.25s;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}
.ux-toast--visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

/* Status paragraph truncation */
.eb-status-truncated {
    max-height: 4.5em;
    overflow: hidden;
    position: relative;
    line-height: 1.5;
    transition: max-height 0.3s ease;
}
.eb-status-truncated::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2em;
    background: linear-gradient(transparent, var(--card-bg));
    pointer-events: none;
    transition: opacity 0.3s;
}
.eb-status-truncated.eb-status-expanded {
    max-height: none;
}
.eb-status-truncated.eb-status-expanded::after {
    opacity: 0;
}
.eb-status-expand {
    background: none;
    border: none;
    color: var(--accent-primary);
    font-size: 0.75rem;
    cursor: pointer;
    padding: 4px 0;
    margin-top: 4px;
    font-weight: 500;
    display: block;
}
.eb-status-expand:hover {
    text-decoration: underline;
}

/* Collapsible sections (Decisions, Key People) */
.eb-collapsible .eb-collapse-toggle {
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    gap: 6px;
}
.eb-collapse-icon {
    font-size: 0.6rem;
    transition: transform 0.2s;
    opacity: 0.5;
}
.eb-collapsed .eb-collapse-icon {
    transform: rotate(-90deg);
}
.eb-collapsed .eb-collapse-body {
    display: none;
}

/* Footer for project page */
.footer {
    text-align: center;
    padding: 24px 16px 80px;
    color: var(--text-muted);
    font-size: 0.75rem;
    border-top: 1px solid var(--border-color);
    margin-top: 48px;
}

/* Skip link (reuse from dashboard) */
.skip-link {
    position: absolute;
    top: -100px;
    left: 16px;
    z-index: 10000;
    background: var(--accent-primary);
    color: #fff;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 0.85rem;
    text-decoration: none;
    transition: top 0.2s;
}
.skip-link:focus {
    top: 8px;
}

/* ============================================ */
/* SPRINT TAB                                   */
/* ============================================ */

.sprint-view { display: flex; flex-direction: column; gap: 20px; }

.sprint-info-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 16px 20px;
}
.sprint-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}
.sprint-info-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}
.sprint-info-dates {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.78rem;
    color: var(--text-muted);
}
.sprint-info-stats {
    display: flex;
    gap: 12px;
}
.sprint-stat {
    font-size: 0.78rem;
    color: var(--text-secondary);
    padding: 4px 10px;
    background: rgba(255,255,255,0.04);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-subtle);
}

.sprint-section-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin: 0 0 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border-subtle);
}

.sprint-epic-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 14px;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,0.02);
    margin-bottom: 6px;
    transition: all var(--transition-fast);
}
.sprint-epic-card:hover {
    background: rgba(99,102,241,0.04);
    border-color: rgba(99,102,241,0.2);
}
.sprint-epic-card--next { opacity: 0.8; }

.sprint-epic-status {
    width: 4px;
    min-height: 28px;
    border-radius: 2px;
    flex-shrink: 0;
    margin-top: 2px;
}
.sprint-epic-body { flex: 1; min-width: 0; }
.sprint-epic-title {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 4px;
}
.sprint-epic-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    font-size: 0.72rem;
}
.sprint-epic-jira {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.68rem;
    color: var(--accent-primary);
    text-decoration: none;
    padding: 1px 5px;
    border-radius: 3px;
    background: rgba(99,102,241,0.08);
}
.sprint-epic-jira:hover { background: rgba(99,102,241,0.15); }
.sprint-epic-id {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.68rem;
    color: var(--text-muted);
}
.sprint-epic-size {
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--text-muted);
    padding: 1px 5px;
    border: 1px solid var(--border-subtle);
    border-radius: 3px;
}
.sprint-epic-status-label {
    font-size: 0.68rem;
    font-weight: 500;
}
.sprint-epic-initiative {
    display: block;
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 2px;
}
.sprint-epic-sprint-tag {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    color: var(--accent-tertiary);
    padding: 1px 5px;
    border-radius: 3px;
    background: rgba(16,185,129,0.08);
}

.sprint-risk-card, .sprint-bug-card {
    padding: 10px 14px;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    margin-bottom: 6px;
    background: rgba(255,255,255,0.02);
}
.sprint-risk-card { border-left: 3px solid #f59e0b; }
.sprint-bug-card { border-left: 3px solid #ef4444; }
.sprint-risk-title, .sprint-bug-title {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 4px;
}
.sprint-risk-meta, .sprint-bug-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.72rem;
    color: var(--text-muted);
}
.sprint-risk-gut {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    font-weight: 600;
    color: #f59e0b;
    padding: 1px 5px;
    border: 1px solid rgba(245,158,11,0.3);
    border-radius: 3px;
}
.sprint-bug-priority {
    font-size: 0.65rem;
    font-weight: 600;
    color: #ef4444;
    padding: 1px 5px;
    border: 1px solid rgba(239,68,68,0.3);
    border-radius: 3px;
}

@media (max-width: 600px) {
    .sprint-info-row { flex-direction: column; align-items: flex-start; }
    .sprint-info-stats { flex-wrap: wrap; }
}
