/* ═══════════════════════════════════════════════════════════════
   shared.css — AI PMO + Strategy Accelerator
   One file to rule them all.
   ═══════════════════════════════════════════════════════════════ */

/* ── CSS Variables ─────────────────────────────────────────── */
:root {
    --navy:        #1F4E79;
    --navy-light:  #2E75B6;
    --navy-dim:    #e8f0f8;
    --teal:        #0d9488;
    --teal-light:  #e0f2f1;
    --bg:          #f0f2f5;
    --white:       #ffffff;
    --text:        #1a1a2e;
    --text-muted:  #666666;
    --text-faint:  #aaaaaa;
    --border:      #e2e8f0;
    --border-light:#f0f2f5;
    --shadow-sm:   0 1px 4px rgba(0,0,0,0.08);
    --shadow-md:   0 4px 14px rgba(0,0,0,0.12);
    --radius-sm:   7px;
    --radius-md:   10px;
    --radius-lg:   12px;
    --sidebar-w:   220px;
    --font:        'Segoe UI', Arial, sans-serif;
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.5; }
a { color: inherit; }

/* ═══════════════════════════════════════════════════════════════
   SIDEBAR
   ═══════════════════════════════════════════════════════════════ */
.sidebar {
    width: var(--sidebar-w);
    background: var(--navy);
    min-height: 100vh;
    position: fixed; top: 0; left: 0;
    display: flex; flex-direction: column;
    z-index: 100;
}
.sidebar-logo {
    padding: 16px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.15);
    text-align: center;
}
.sidebar-logo img { width: 170px; display: block; margin: 0 auto; }
.sidebar-section {
    padding: 12px 20px 4px;
    font-size: 10px; text-transform: uppercase;
    letter-spacing: 0.8px; color: rgba(255,255,255,0.4);
    margin-top: 4px;
}
.sidebar-spacer { flex: 1; }
.sidebar-divider { border-top: 1px solid rgba(255,255,255,0.15); margin: 4px 0; }

.nav-item {
    display: flex; align-items: center; gap: 10px;
    padding: 11px 20px;
    color: rgba(255,255,255,0.75);
    text-decoration: none; font-size: 14px;
    transition: background 0.2s, color 0.2s;
}
.nav-item:hover,
.nav-item.active { background: rgba(255,255,255,0.12); color: #fff; }
.nav-item .icon  { font-size: 15px; width: 20px; text-align: center; flex-shrink: 0; }

/* ═══════════════════════════════════════════════════════════════
   MAIN LAYOUT
   ═══════════════════════════════════════════════════════════════ */
.main { margin-left: var(--sidebar-w); padding: 32px; }

.page-header { margin-bottom: 24px; }
.page-header h1 { font-size: 24px; color: var(--navy); font-weight: 700; }
.page-header .subtitle { color: var(--text-muted); font-size: 14px; margin-top: 4px; }

/* ═══════════════════════════════════════════════════════════════
   CARDS
   ═══════════════════════════════════════════════════════════════ */
.card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 22px;
    margin-bottom: 20px;
}
.card-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 16px; padding-bottom: 12px;
    border-bottom: 2px solid var(--navy-dim);
}
.card-header h3,
.card-title {
    font-size: 13px; font-weight: 700; color: var(--navy);
    text-transform: uppercase; letter-spacing: 0.5px;
    display: flex; align-items: center; gap: 7px;
}

/* ═══════════════════════════════════════════════════════════════
   STATS ROW
   ═══════════════════════════════════════════════════════════════ */
.stats-row {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 16px; margin-bottom: 24px;
}
.stat-card {
    background: var(--white); border-radius: var(--radius-md);
    padding: 18px 16px; box-shadow: var(--shadow-sm); text-align: center;
}
.stat-card .value,
.stat-card .num  { font-size: 22px; font-weight: 700; color: var(--navy); line-height: 1; }
.stat-card .label,
.stat-card .lbl  { font-size: 11px; color: #888; margin-top: 6px; text-transform: uppercase; letter-spacing: 0.5px; }
.stat-card .hint { font-size: 11px; color: #aaa; margin-top: 4px; }
.stat-card.teal  .value,
.stat-card.teal  .num { color: var(--teal); }
.stat-card.critical .num { color: #c62828; }
.stat-card.warning  .num { color: #f57f17; }
.stat-card.info     .num { color: #1565c0; }

/* ═══════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════ */
.btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 9px 18px; border-radius: var(--radius-sm);
    font-size: 13px; font-weight: 600; font-family: var(--font);
    border: none; cursor: pointer; text-decoration: none;
    transition: opacity .15s, transform .1s;
    white-space: nowrap;
}
.btn:hover:not(:disabled) { opacity: .88; transform: translateY(-1px); }
.btn:disabled { opacity: .4; cursor: not-allowed; transform: none; }

.btn-primary   { background: var(--navy);  color: #fff; }
.btn-secondary { background: var(--white); color: #374151; border: 1px solid #d1d5db; }
.btn-success   { background: var(--teal);  color: #fff; }
.btn-danger    { background: #dc2626;       color: #fff; }
.btn-ghost     { background: transparent;  color: var(--navy); border: 1px solid var(--navy); }
.btn-sm        { padding: 5px 12px; font-size: 12px; }
.btn-lg        { padding: 13px 32px; font-size: 15px; font-weight: 700; }

/* ═══════════════════════════════════════════════════════════════
   FORMS
   ═══════════════════════════════════════════════════════════════ */
.form-group { margin-bottom: 18px; }
.form-label { display: block; font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 6px; }
.form-hint  { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.form-input,
.form-select,
.form-textarea {
    width: 100%; padding: 9px 12px;
    border: 1.5px solid var(--border); border-radius: var(--radius-sm);
    font-size: 14px; font-family: var(--font); color: var(--text);
    background: var(--white); transition: border-color .2s, box-shadow .2s;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--navy);
    box-shadow: 0 0 0 3px rgba(31,78,121,0.1);
}
.form-textarea { resize: vertical; min-height: 90px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ═══════════════════════════════════════════════════════════════
   BADGES & PILLS
   ═══════════════════════════════════════════════════════════════ */
.badge {
    display: inline-block; padding: 3px 9px;
    border-radius: 10px; font-size: 11px; font-weight: 700;
}
.badge-critical, .badge-red    { background: #ffebee; color: #c62828; }
.badge-warning,  .badge-yellow { background: #fff8e1; color: #f57f17; }
.badge-info,     .badge-blue   { background: #e3f2fd; color: #1565c0; }
.badge-success,  .badge-green  { background: #e8f5e9; color: #2e7d32; }
.badge-navy                    { background: var(--navy-dim); color: var(--navy); }
.badge-teal                    { background: var(--teal-light); color: #00695c; }
.badge-opt                     { background: var(--navy-dim); color: var(--navy); border: 1px solid #bfdbfe; }
.badge-req                     { background: #fff7ed; color: #9a3412; border: 1px solid #fed7aa; }

.pill {
    display: inline-block; padding: 3px 10px;
    border-radius: 999px; font-size: 11px; font-weight: 500;
    background: var(--navy-dim); color: var(--navy);
}
.status-pill {
    font-size: 12px; font-weight: 600;
    padding: 4px 12px; border-radius: 999px;
}
.pill-saved { background: #e8f5e9; color: #2e7d32; border: 1px solid #c8e6c9; }
.pill-draft { background: #fff8e1; color: #f57f17; border: 1px solid #ffe082; }
.pill-none  { background: #f5f5f5; color: #aaa;    border: 1px solid #e0e0e0; }

/* ═══════════════════════════════════════════════════════════════
   ALERTS
   ═══════════════════════════════════════════════════════════════ */
.alert {
    border-radius: var(--radius-sm); padding: 12px 16px;
    font-size: 13px; margin-bottom: 16px; display: none;
}
.alert.show    { display: block; }
.alert-warning { background: #fffbeb; border: 1px solid #fcd34d; color: #92400e; }
.alert-info    { background: #eff6ff; border: 1px solid #bfdbfe; color: #1e40af; }
.alert-success { background: #f0fdf4; border: 1px solid #86efac; color: #166534; }
.alert-error   { background: #ffebee; border: 1px solid #ef9a9a; color: #c62828; }

/* ═══════════════════════════════════════════════════════════════
   TABLES
   ═══════════════════════════════════════════════════════════════ */
table { width: 100%; border-collapse: collapse; font-size: 13px; }
thead th {
    background: var(--navy); color: #fff;
    padding: 10px 14px; text-align: left;
    font-size: 12px; text-transform: uppercase; letter-spacing: 0.4px;
}
tbody tr { border-bottom: 1px solid var(--border-light); transition: background 0.1s; }
tbody tr:hover { background: #f8f9ff; }
tbody td { padding: 10px 14px; vertical-align: middle; }

/* ═══════════════════════════════════════════════════════════════
   TABS / FILTER TABS
   ═══════════════════════════════════════════════════════════════ */
.filter-tabs { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.tab {
    padding: 7px 16px; border-radius: 20px;
    font-size: 13px; font-weight: 600; cursor: pointer;
    border: 2px solid transparent; transition: all 0.15s;
    background: var(--navy-dim); color: var(--navy);
    font-family: var(--font);
}
.tab.active         { background: var(--navy); color: #fff; }
.tab:hover:not(.active) { border-color: var(--navy); }

/* ═══════════════════════════════════════════════════════════════
   MODALS
   ═══════════════════════════════════════════════════════════════ */
.modal-overlay {
    display: none; position: fixed; inset: 0;
    background: rgba(0,0,0,0.5); z-index: 999;
    align-items: center; justify-content: center;
}
.modal-overlay.show { display: flex; }
.modal {
    background: var(--white); border-radius: var(--radius-lg);
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
    padding: 28px; max-width: 560px; width: 90%; max-height: 90vh; overflow-y: auto;
}
.modal h3     { font-size: 18px; font-weight: 700; color: var(--navy); margin-bottom: 6px; }
.modal p      { font-size: 14px; color: var(--text-muted); margin-bottom: 20px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }

/* ═══════════════════════════════════════════════════════════════
   STEP PIPELINE (Strategy dashboard)
   ═══════════════════════════════════════════════════════════════ */
.pipeline {
    background: var(--white); border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm); display: flex;
    overflow: hidden; margin-bottom: 24px;
}
.pipe-step {
    flex: 1; display: flex; align-items: center; justify-content: center;
    gap: 7px; padding: 13px 8px;
    font-size: 12px; font-weight: 500; color: #bbb;
    border-right: 1px solid var(--border-light);
}
.pipe-step:last-child  { border-right: none; }
.pipe-step.active      { background: var(--navy-dim); color: var(--navy); font-weight: 700; }
.pipe-step.done        { color: var(--teal); }
.pipe-num {
    width: 22px; height: 22px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 700; flex-shrink: 0;
}
.pipe-step.active   .pipe-num { background: var(--navy); color: #fff; }
.pipe-step.done     .pipe-num { background: var(--teal);  color: #fff; }
.pipe-step.upcoming .pipe-num { background: #e8e8e8; color: #bbb; }

/* ═══════════════════════════════════════════════════════════════
   STEP TRAIL BREADCRUMB
   ═══════════════════════════════════════════════════════════════ */
.step-trail {
    display: flex; align-items: center; gap: 6px;
    margin-bottom: 20px; flex-wrap: wrap;
}
.step-trail a, .step-trail span {
    font-size: 12px; font-weight: 600;
    padding: 4px 10px; border-radius: 5px; text-decoration: none;
}
.step-trail a           { background: var(--navy-dim); color: var(--navy); }
.step-trail a:hover     { background: #d0e2f3; }
.step-trail .current    { background: var(--navy); color: #fff; }
.step-trail .locked     { background: #f0f0f0; color: #bbb; }
.step-trail .sep        { color: #ccc; font-size: 11px; padding: 0; background: none; }

/* ═══════════════════════════════════════════════════════════════
   CTA BANNER
   ═══════════════════════════════════════════════════════════════ */
.cta-banner {
    background: var(--navy); border-radius: var(--radius-lg);
    padding: 24px 28px;
    display: flex; align-items: center; justify-content: space-between;
    gap: 20px; margin-bottom: 24px; color: #fff;
}
.cta-banner h2 { font-size: 18px; font-weight: 700; margin-bottom: 6px; }
.cta-banner p  { font-size: 13px; color: rgba(255,255,255,0.75); }
.btn-cta {
    background: #fff; color: var(--navy); border: none;
    padding: 11px 24px; border-radius: var(--radius-sm);
    font-size: 14px; font-weight: 700; cursor: pointer;
    white-space: nowrap; text-decoration: none; transition: background 0.2s;
    font-family: var(--font);
}
.btn-cta:hover { background: var(--navy-dim); }

/* ═══════════════════════════════════════════════════════════════
   LAUNCH PANEL (PMO run page)
   ═══════════════════════════════════════════════════════════════ */
.launch-panel {
    display: flex; align-items: center; gap: 32px;
    padding: 28px;
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
    border-radius: var(--radius-lg); margin-bottom: 24px; color: #fff;
}
.launch-icon { font-size: 52px; }
.launch-text h2 { font-size: 20px; font-weight: 700; margin-bottom: 6px; }
.launch-text p  { font-size: 14px; color: rgba(255,255,255,0.8); line-height: 1.5; }
.btn-run {
    margin-left: auto; background: #fff; color: var(--navy);
    border: none; padding: 14px 36px; border-radius: var(--radius-sm);
    font-size: 16px; font-weight: 700; cursor: pointer; font-family: var(--font);
    transition: transform 0.1s, box-shadow 0.2s; white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}
.btn-run:hover   { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,0.25); }
.btn-run:disabled { opacity: .5; cursor: not-allowed; transform: none; }

/* ═══════════════════════════════════════════════════════════════
   SPINNER
   ═══════════════════════════════════════════════════════════════ */
@keyframes spin { to { transform: rotate(360deg); } }
.spinner {
    border: 4px solid rgba(255,255,255,0.3);
    border-top-color: #fff; border-radius: 50%;
    width: 36px; height: 36px;
    animation: spin 0.8s linear infinite;
    display: none; margin-left: auto;
}
.spinner.show { display: block; }
.spinner-inline {
    display: inline-block; width: 14px; height: 14px;
    border: 2px solid var(--navy-dim); border-top-color: var(--navy);
    border-radius: 50%; animation: spin 0.7s linear infinite;
    vertical-align: middle; margin-right: 6px;
}
.spinner-inline.spinner-dark { border-color: rgba(255,255,255,0.3); border-top-color: #fff; }

/* ═══════════════════════════════════════════════════════════════
   GENERATION PROGRESS PANEL (bright — used in Strategy pages)
   ═══════════════════════════════════════════════════════════════ */
.gen-panel {
    display: none;
    background: var(--white); border: 1px solid var(--border);
    border-radius: var(--radius-lg); box-shadow: var(--shadow-sm);
    padding: 22px 24px; margin-bottom: 20px;
}
.gen-panel.active { display: block; }
.gen-header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.gen-spinner {
    width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0;
    border: 3px solid var(--navy-dim); border-top-color: var(--navy);
    animation: spin 0.9s linear infinite;
}
.gen-spinner.done { border-color: var(--teal); animation: none; }
.gen-title    { font-size: 14px; font-weight: 700; color: var(--navy); }
.gen-subtitle { font-size: 12px; color: #888; margin-top: 2px; }
.gen-progress-bar {
    height: 4px; background: var(--navy-dim); border-radius: 2px;
    margin-bottom: 16px; overflow: hidden;
}
@keyframes progress-pulse { 0%,100% { opacity:1; } 50% { opacity:0.6; } }
.gen-progress-fill {
    height: 100%; background: var(--navy); border-radius: 2px;
    width: 0%; transition: width 0.4s ease;
    animation: progress-pulse 2s ease-in-out infinite;
}
.gen-progress-fill.done { animation: none; opacity: 1; background: var(--teal); width: 100% !important; }
.gen-text-area {
    background: #f8fafc; border: 1px solid var(--border); border-radius: var(--radius-sm);
    padding: 14px 16px; font-size: 12.5px; color: #374151;
    line-height: 1.7; max-height: 300px; overflow-y: auto;
    white-space: pre-wrap; font-family: var(--font);
}
.gen-word-count { text-align: right; font-size: 11px; color: #aaa; margin-top: 6px; }

/* ═══════════════════════════════════════════════════════════════
   CONTROL BAR
   ═══════════════════════════════════════════════════════════════ */
.control-bar {
    display: flex; gap: 10px; align-items: center;
    flex-wrap: wrap; margin-bottom: 20px;
}
.control-bar .status-pill { margin-left: auto; }

/* ═══════════════════════════════════════════════════════════════
   SUMMARY BAR
   ═══════════════════════════════════════════════════════════════ */
.summary-bar {
    background: var(--white); border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm); display: none; margin-bottom: 20px; overflow: hidden;
}
.summary-bar.show { display: flex; }
.sum-item {
    flex: 1; padding: 14px 16px; text-align: center;
    border-right: 1px solid var(--border-light);
}
.sum-item:last-child { border-right: none; }
.sum-value { font-size: 22px; font-weight: 700; color: var(--navy); line-height: 1; }
.sum-label { font-size: 11px; color: #888; margin-top: 5px; text-transform: uppercase; letter-spacing: 0.5px; }

/* ═══════════════════════════════════════════════════════════════
   PROJECT CARDS (Step 4)
   ═══════════════════════════════════════════════════════════════ */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 16px;
}
.project-card {
    background: var(--white); border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm); border: 1.5px solid transparent;
    padding: 18px; display: flex; flex-direction: column; gap: 10px;
    transition: box-shadow 0.2s, border-color 0.2s;
}
.project-card:hover { box-shadow: var(--shadow-md); border-color: #bfdbfe; }
.card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.card-num {
    width: 26px; height: 26px; min-width: 26px; border-radius: 50%;
    background: var(--navy); color: #fff; font-size: 11px; font-weight: 700;
    display: flex; align-items: center; justify-content: center;
}
.card-top .card-title { flex: 1; font-size: 14px; font-weight: 700; color: var(--text); line-height: 1.3; }
.card-remove {
    background: none; border: none; cursor: pointer;
    color: #ccc; font-size: 16px; line-height: 1; padding: 0; transition: color 0.15s;
}
.card-remove:hover { color: #dc2626; }
.priority-tag {
    display: inline-block; background: var(--navy-dim); color: var(--navy);
    font-size: 11px; font-weight: 700; padding: 3px 9px;
    border-radius: 999px; border: 1px solid #bfdbfe;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%;
}
.card-desc { font-size: 13px; color: #555; line-height: 1.55; }
.card-badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badge-effort     { background: #f0fdf4; color: #166534; border: 1px solid #bbf7d0; }
.badge-complexity { background: #fff7ed; color: #9a3412; border: 1px solid #fed7aa; }
.card-outcome {
    font-size: 12px; color: #777; border-top: 1px solid var(--border-light);
    padding-top: 10px; line-height: 1.5;
}
.card-outcome strong { color: var(--text); }

/* ═══════════════════════════════════════════════════════════════
   CHECKLIST (Strategy dashboard)
   ═══════════════════════════════════════════════════════════════ */
.checklist { list-style: none; display: flex; flex-direction: column; gap: 11px; }
.check-item { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; }
.check-icon {
    width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0; margin-top: 1px;
    display: flex; align-items: center; justify-content: center; font-size: 11px;
}
.check-item.done    .check-icon { background: #e8f5e9; color: #2e7d32; border: 1px solid #c8e6c9; }
.check-item.active  .check-icon { background: var(--navy); color: #fff; }
.check-item.pending .check-icon { background: #f5f5f5; color: #ccc; border: 1px solid #e0e0e0; }
.check-item.done    .check-label { color: #aaa; text-decoration: line-through; }
.check-item.active  .check-label { color: var(--text); font-weight: 600; }
.check-item.pending .check-label { color: #aaa; }

/* ═══════════════════════════════════════════════════════════════
   HOW IT WORKS (Strategy dashboard)
   ═══════════════════════════════════════════════════════════════ */
.how-list { display: flex; flex-direction: column; gap: 13px; }
.how-item { display: flex; gap: 12px; font-size: 13px; }
.how-num {
    width: 24px; height: 24px; border-radius: 50%;
    background: var(--navy-dim); color: var(--navy);
    font-weight: 700; font-size: 11px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
}
.how-text strong { display: block; font-weight: 600; color: var(--text); margin-bottom: 2px; }
.how-text span   { color: #888; font-size: 12px; }

/* ═══════════════════════════════════════════════════════════════
   CONTENT GRID
   ═══════════════════════════════════════════════════════════════ */
.content-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }

/* ═══════════════════════════════════════════════════════════════
   CONTEXT PILLS (Generate Strategy page)
   ═══════════════════════════════════════════════════════════════ */
.context-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.context-pill {
    display: flex; align-items: center; gap: 6px;
    background: var(--navy-dim); border: 1px solid #bfdbfe;
    border-radius: 999px; padding: 5px 12px; font-size: 12px; color: var(--navy);
}
.context-pill .pill-label { color: #888; font-weight: 400; margin-right: 2px; }
.context-pill .pill-value { font-weight: 600; }

/* ═══════════════════════════════════════════════════════════════
   OUTPUT CARD (Generate Strategy page)
   ═══════════════════════════════════════════════════════════════ */
.output-card {
    background: var(--white); border: 1.5px solid var(--border);
    border-radius: var(--radius-lg); overflow: hidden; margin-bottom: 20px;
    box-shadow: var(--shadow-sm);
}
.output-card-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 18px; background: var(--navy-dim);
    border-bottom: 1px solid var(--border); font-size: 12px;
    font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--navy);
}
#output-area {
    padding: 28px 32px; min-height: 200px;
    font-size: 14px; line-height: 1.8; color: var(--text);
}
#output-area.empty {
    display: flex; align-items: center; justify-content: center;
    min-height: 240px; color: #bbb; font-size: 14px;
}
#output-area h1, #output-area h2 { color: var(--navy); margin: 20px 0 8px; font-size: 17px; }
#output-area h3 { color: var(--navy); margin: 16px 0 6px; font-size: 15px; }
#output-area p  { margin-bottom: 12px; }
#output-area ul, #output-area ol { margin: 8px 0 12px 20px; }
#output-area li { margin-bottom: 4px; }
#output-area strong { color: var(--navy); }
#output-area table  { margin: 16px 0; }

.approve-section {
    display: flex; align-items: center; justify-content: space-between;
    gap: 16px; padding: 16px 18px;
    border-top: 1px solid var(--border); background: #fafbfc;
}
.approve-hint { font-size: 13px; color: #555; }

/* ═══════════════════════════════════════════════════════════════
   STATUS BANNER (approved strategy)
   ═══════════════════════════════════════════════════════════════ */
.status-banner {
    display: flex; align-items: flex-start; gap: 12px;
    background: #f0fdf4; border: 1.5px solid #86efac;
    border-radius: var(--radius-md); padding: 14px 18px; margin-bottom: 20px;
    font-size: 13px; color: #166534;
}
.status-banner .icon { font-size: 20px; }
.status-banner .meta { font-size: 12px; color: #6b7280; margin-top: 3px; }

/* ═══════════════════════════════════════════════════════════════
   CONTINUE FOOTER
   ═══════════════════════════════════════════════════════════════ */
.continue-footer {
    background: var(--navy-dim); border: 1px solid #bfdbfe;
    border-radius: var(--radius-md); padding: 16px 20px;
    display: flex; align-items: center; justify-content: space-between;
    margin-top: 20px;
}

/* ═══════════════════════════════════════════════════════════════
   FIELD ROWS (detail / settings pages)
   ═══════════════════════════════════════════════════════════════ */
.field-row   { display: flex; align-items: flex-start; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border-light); }
.field-label { font-size: 12px; color: #888; min-width: 140px; padding-top: 2px; }
.field-value,
.field-val   { font-size: 13px; color: var(--text); flex: 1; }
.field-grid  { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }

/* ═══════════════════════════════════════════════════════════════
   EMPTY STATE
   ═══════════════════════════════════════════════════════════════ */
.empty, .empty-state {
    text-align: center; padding: 48px 20px; color: #aaa;
}
.empty .icon, .empty-state .icon { font-size: 40px; margin-bottom: 12px; }
.empty p, .empty-state p { font-size: 14px; line-height: 1.6; }
.empty-state strong { color: var(--navy); }

/* ═══════════════════════════════════════════════════════════════
   PROGRESS BAR (PMO dashboard)
   ═══════════════════════════════════════════════════════════════ */
.progress-wrap { background: #e8e8e8; border-radius: 4px; height: 6px; overflow: hidden; }
.progress-fill { height: 100%; border-radius: 4px; background: var(--navy); transition: width 0.3s; }
.progress-fill.on-budget  { background: #2e7d32; }
.progress-fill.over-budget { background: #c62828; }

/* ═══════════════════════════════════════════════════════════════
   RESEARCH PAGE SPECIFIC
   ═══════════════════════════════════════════════════════════════ */
.context-card {
    background: var(--navy-dim); border: 1px solid #bfdbfe;
    border-radius: var(--radius-md); padding: 14px 18px; margin-bottom: 20px;
    font-size: 13px;
}
.source-card {
    background: var(--white); border: 1px solid var(--border);
    border-radius: var(--radius-sm); padding: 12px 14px; margin-bottom: 8px;
}
.source-card a { color: var(--navy); font-weight: 600; text-decoration: none; }
.source-card a:hover { text-decoration: underline; }

/* ═══════════════════════════════════════════════════════════════
   SETUP PAGE — COMPANY SIZE RADIO
   ═══════════════════════════════════════════════════════════════ */
.size-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.size-radio { display: none; }
.size-label {
    display: flex; flex-direction: column; align-items: center;
    border: 2px solid var(--border); border-radius: var(--radius-sm);
    padding: 12px 8px; cursor: pointer; font-size: 12px; text-align: center;
    transition: border-color 0.2s, background 0.2s;
}
.size-label:hover { border-color: var(--navy); background: var(--navy-dim); }
.size-radio:checked + .size-label { border-color: var(--navy); background: var(--navy-dim); color: var(--navy); font-weight: 600; }
.size-emoji { font-size: 22px; margin-bottom: 4px; }
.size-text  { font-weight: 600; }

/* ═══════════════════════════════════════════════════════════════
   HELP PAGE
   ═══════════════════════════════════════════════════════════════ */
.help-intro  { font-size: 14px; color: var(--text-muted); line-height: 1.7; margin-bottom: 20px; }
.help-section { margin-bottom: 28px; }
.tip-box {
    background: var(--navy-dim); border-left: 3px solid var(--navy);
    padding: 12px 16px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    font-size: 13px; margin-top: 8px;
}
.chat-wrap { display: flex; flex-direction: column; height: 400px; }
.chat-messages { flex: 1; overflow-y: auto; padding: 16px; background: #fafbfc; border: 1px solid var(--border); border-radius: var(--radius-sm) var(--radius-sm) 0 0; }
.chat-input-row { display: flex; border: 1px solid var(--border); border-top: none; border-radius: 0 0 var(--radius-sm) var(--radius-sm); overflow: hidden; }
.chat-input { flex: 1; padding: 10px 14px; border: none; font-size: 13px; font-family: var(--font); outline: none; }
.chat-send  { background: var(--navy); color: #fff; border: none; padding: 10px 18px; cursor: pointer; font-size: 13px; font-weight: 600; font-family: var(--font); }

/* ═══════════════════════════════════════════════════════════════
   LAYOUT HELPERS
   ═══════════════════════════════════════════════════════════════ */
.layout-two { display: grid; grid-template-columns: 280px 1fr; gap: 24px; align-items: start; }
.layout-three { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }
.mb-4  { margin-bottom: 4px; }
.mb-8  { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mt-auto { margin-top: auto; }
.text-muted { color: var(--text-muted); }
.text-sm    { font-size: 12px; }
.text-xs    { font-size: 11px; }
.font-bold  { font-weight: 700; }
.text-navy  { color: var(--navy); }
.text-teal  { color: var(--teal); }

/* ── Pill sub-labels (Generate Strategy context pills) ── */
.pill .pill-label { color: #888; font-size: 11px; margin-right: 3px; }
.pill .pill-value { font-weight: 600; font-size: 12px; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }

/* ── Error toast ── */
#error-toast {
    display: none; position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
    background: #dc2626; color: #fff; padding: 12px 20px; border-radius: var(--radius-sm);
    font-size: 14px; font-weight: 600; gap: 8px; align-items: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3); z-index: 9999;
}
#error-toast.show { display: flex; }
