/* ══════════════════════════════════════════════════════════════
   Invoice Reminder Tracker — Premium Dark Mode Styles
   Colors: Primary #10B981, Accent #EF4444, BG #0F172A
   ══════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ── CSS Variables ── */
:root {
    --primary: #10B981;
    --primary-light: #34D399;
    --primary-dim: rgba(16, 185, 129, 0.15);
    --accent: #EF4444;
    --accent-light: #F87171;
    --accent-dim: rgba(239, 68, 68, 0.15);
    --bg: #0F172A;
    --bg-card: rgba(30, 41, 59, 0.6);
    --bg-card-hover: rgba(30, 41, 59, 0.85);
    --bg-input: rgba(15, 23, 42, 0.8);
    --bg-modal: rgba(15, 23, 42, 0.97);
    --border: rgba(148, 163, 184, 0.12);
    --border-focus: rgba(16, 185, 129, 0.5);
    --text: #F1F5F9;
    --text-secondary: #94A3B8;
    --text-dim: #64748B;
    --blue: #3B82F6;
    --blue-dim: rgba(59, 130, 246, 0.15);
    --yellow: #F59E0B;
    --yellow-dim: rgba(245, 158, 11, 0.15);
    --glass: rgba(255, 255, 255, 0.04);
    --glass-border: rgba(255, 255, 255, 0.08);
    --radius: 14px;
    --radius-sm: 8px;
    --radius-lg: 20px;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.5);
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: hidden;
}

/* ── Background Ambience ── */
body::before {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at 20% 20%, rgba(16, 185, 129, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(59, 130, 246, 0.04) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* ── Layout ── */
.app {
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
    padding: 24px;
}

/* ── Header ── */
.header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.header__brand {
    display: flex;
    align-items: center;
    gap: 14px;
}

.header__icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--primary), #059669);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    box-shadow: 0 4px 16px rgba(16, 185, 129, 0.3);
}

.header__title {
    font-size: 24px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--text), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header__subtitle {
    font-size: 13px;
    color: var(--text-dim);
    font-weight: 400;
}

.header__actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.btn--primary {
    background: linear-gradient(135deg, var(--primary), #059669);
    color: #fff;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
}

.btn--primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.35);
}

.btn--secondary {
    background: var(--glass);
    color: var(--text);
    border: 1px solid var(--border);
    backdrop-filter: blur(8px);
}

.btn--secondary:hover {
    background: var(--bg-card);
    border-color: var(--primary);
}

.btn--danger {
    background: var(--accent-dim);
    color: var(--accent-light);
}

.btn--danger:hover {
    background: var(--accent);
    color: #fff;
}

.btn--small {
    padding: 6px 12px;
    font-size: 12px;
}

.btn--icon {
    padding: 8px;
    width: 36px;
    height: 36px;
    justify-content: center;
}

/* ── Stats Cards ── */
.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 28px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    backdrop-filter: blur(16px);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

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

.stat-card--outstanding::before {
    background: linear-gradient(90deg, var(--blue), #60A5FA);
}

.stat-card--paid::before {
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
}

.stat-card--overdue::before {
    background: linear-gradient(90deg, var(--accent), var(--accent-light));
}

.stat-card--total::before {
    background: linear-gradient(90deg, var(--yellow), #FBBF24);
}

.stat-card:hover {
    transform: translateY(-2px);
    border-color: var(--glass-border);
    box-shadow: var(--shadow);
}

.stat-card__label {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.stat-card__value {
    font-size: 28px;
    font-weight: 800;
}

.stat-card--outstanding .stat-card__value {
    color: var(--blue);
}

.stat-card--paid .stat-card__value {
    color: var(--primary);
}

.stat-card--overdue .stat-card__value {
    color: var(--accent);
}

.stat-card--total .stat-card__value {
    color: var(--yellow);
}

.stat-card__count {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* ── Tabs ── */
.tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 24px;
    background: var(--glass);
    border-radius: var(--radius);
    padding: 4px;
    border: 1px solid var(--border);
    overflow-x: auto;
}

.tab {
    padding: 10px 20px;
    border: none;
    background: transparent;
    color: var(--text-dim);
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 10px;
    transition: var(--transition);
    white-space: nowrap;
}

.tab:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.04);
}

.tab--active {
    background: var(--primary-dim);
    color: var(--primary-light);
    font-weight: 600;
}

/* ── Toolbar ── */
.toolbar {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.toolbar__search {
    flex: 1;
    min-width: 200px;
    position: relative;
}

.toolbar__search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-dim);
    font-size: 14px;
    pointer-events: none;
}

.toolbar__search input {
    width: 100%;
    padding: 10px 14px 10px 40px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: inherit;
    font-size: 14px;
    transition: var(--transition);
}

.toolbar__search input:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px var(--primary-dim);
}

.toolbar__search input::placeholder {
    color: var(--text-dim);
}

.toolbar select {
    padding: 10px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: inherit;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2394A3B8' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}

.toolbar select:focus {
    outline: none;
    border-color: var(--border-focus);
}

/* ── Invoice List ── */
.invoice-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.invoice-row {
    display: grid;
    grid-template-columns: 120px 1.5fr 1fr 100px 120px 60px;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    backdrop-filter: blur(8px);
    transition: var(--transition);
    cursor: pointer;
}

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

.invoice-row__number {
    font-weight: 700;
    font-size: 14px;
    color: var(--primary-light);
}

.invoice-row__client {
    font-weight: 500;
    font-size: 14px;
}

.invoice-row__client span {
    display: block;
    font-size: 12px;
    color: var(--text-dim);
    margin-top: 2px;
}

.invoice-row__amount {
    font-weight: 700;
    font-size: 16px;
    text-align: right;
}

.invoice-row__status {
    text-align: center;
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-badge--draft {
    background: rgba(100, 116, 139, 0.2);
    color: #94A3B8;
}

.status-badge--sent {
    background: var(--blue-dim);
    color: #60A5FA;
}

.status-badge--paid {
    background: var(--primary-dim);
    color: var(--primary-light);
}

.status-badge--overdue {
    background: var(--accent-dim);
    color: var(--accent-light);
}

.invoice-row__due {
    font-size: 13px;
    color: var(--text-secondary);
    text-align: center;
}

.invoice-row__actions {
    display: flex;
    gap: 4px;
    justify-content: flex-end;
}

/* ── Empty State ── */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: var(--text-dim);
}

.empty-state__icon {
    font-size: 56px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state__title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.empty-state__text {
    font-size: 14px;
    max-width: 400px;
    margin: 0 auto 20px;
}

/* ── Modal / Drawer ── */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    z-index: 100;
    display: flex;
    justify-content: flex-end;
    animation: fadeIn 0.2s ease;
}

.modal {
    width: 580px;
    max-width: 100%;
    height: 100vh;
    background: var(--bg-modal);
    border-left: 1px solid var(--border);
    padding: 28px;
    overflow-y: auto;
    animation: slideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

@keyframes slideIn {
    from {
        transform: translateX(100%);
    }

    to {
        transform: translateX(0);
    }
}

.modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.modal__title {
    font-size: 20px;
    font-weight: 700;
}

.modal__close {
    width: 36px;
    height: 36px;
    border: none;
    background: var(--glass);
    color: var(--text-secondary);
    border-radius: 8px;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.modal__close:hover {
    background: var(--accent-dim);
    color: var(--accent);
}

/* ── Forms ── */
.form-group {
    margin-bottom: 18px;
}

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

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: inherit;
    font-size: 14px;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px var(--primary-dim);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

/* ── Line Items ── */
.line-items {
    margin-bottom: 18px;
}

.line-items__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.line-items__header h3 {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
}

.line-item {
    display: grid;
    grid-template-columns: 1fr 70px 100px 36px;
    gap: 8px;
    margin-bottom: 8px;
    align-items: start;
}

.line-item input {
    padding: 8px 10px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    font-family: inherit;
    font-size: 13px;
    transition: var(--transition);
}

.line-item input:focus {
    outline: none;
    border-color: var(--border-focus);
}

.line-item__remove {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: var(--text-dim);
    cursor: pointer;
    border-radius: 6px;
    font-size: 16px;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.line-item__remove:hover {
    background: var(--accent-dim);
    color: var(--accent);
}

/* ── Totals in form ── */
.form-totals {
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 16px;
    margin-bottom: 20px;
}

.form-totals__row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 14px;
    color: var(--text-secondary);
}

.form-totals__row--grand {
    border-top: 1px solid var(--border);
    margin-top: 8px;
    padding-top: 12px;
    font-size: 18px;
    font-weight: 800;
    color: var(--primary-light);
}

/* ── Chart Section ── */
.chart-section {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    margin-bottom: 28px;
    backdrop-filter: blur(8px);
}

.chart-section__title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.chart {
    display: flex;
    align-items: flex-end;
    gap: 16px;
    height: 180px;
    padding: 0 8px;
}

.chart__bar-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    height: 100%;
    justify-content: flex-end;
}

.chart__bars {
    display: flex;
    gap: 4px;
    align-items: flex-end;
    width: 100%;
    justify-content: center;
    flex: 1;
}

.chart__bar {
    width: 24px;
    min-height: 4px;
    border-radius: 4px 4px 0 0;
    transition: height 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.chart__bar--paid {
    background: linear-gradient(to top, var(--primary), var(--primary-light));
}

.chart__bar--outstanding {
    background: linear-gradient(to top, var(--blue), #60A5FA);
}

.chart__label {
    font-size: 11px;
    color: var(--text-dim);
    text-align: center;
    white-space: nowrap;
}

.chart__legend {
    display: flex;
    gap: 20px;
    margin-top: 16px;
    justify-content: center;
}

.chart__legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-secondary);
}

.chart__legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 3px;
}

/* ── Clients List ── */
.client-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: var(--transition);
    margin-bottom: 10px;
}

.client-card:hover {
    border-color: var(--primary);
    transform: translateX(4px);
}

.client-card__info {
    display: flex;
    align-items: center;
    gap: 14px;
}

.client-card__avatar {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--primary-dim), var(--blue-dim));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    color: var(--primary-light);
}

.client-card__name {
    font-weight: 600;
    font-size: 15px;
}

.client-card__email {
    font-size: 13px;
    color: var(--text-dim);
}

.client-card__actions {
    display: flex;
    gap: 6px;
}

/* ── Settings Section ── */
.settings-section {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    backdrop-filter: blur(8px);
}

.settings-section__title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 20px;
}

/* ── Toast Notifications ── */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 200;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    padding: 14px 20px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    backdrop-filter: blur(16px);
    animation: toastIn 0.3s ease, toastOut 0.3s ease 2.7s forwards;
    max-width: 360px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: var(--shadow);
}

.toast--success {
    background: rgba(16, 185, 129, 0.9);
    color: #fff;
}

.toast--error {
    background: rgba(239, 68, 68, 0.9);
    color: #fff;
}

.toast--warning {
    background: rgba(245, 158, 11, 0.9);
    color: #fff;
}

@keyframes toastIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes toastOut {
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* ── Invoice Preview Modal ── */
.preview-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(6px);
    z-index: 150;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease;
}

.preview-modal {
    width: 700px;
    max-width: 95%;
    max-height: 90vh;
    background: #fff;
    border-radius: var(--radius);
    overflow-y: auto;
    animation: slideUp 0.3s ease;
    color: #1E293B;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.preview-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    border-bottom: 1px solid #E2E8F0;
}

.preview-modal__body {
    padding: 24px;
}

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

/* ── Invoice Template (inside preview) ── */
.invoice-template__header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 28px;
}

.invoice-template__title {
    font-size: 26px;
    font-weight: 700;
    color: #1E293B;
}

.invoice-template__number {
    font-size: 22px;
    font-weight: 600;
    text-align: right;
    color: #1E293B;
}

.invoice-template__meta {
    text-align: right;
}

.invoice-template__status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    margin-top: 4px;
}

.invoice-template__info {
    color: #64748B;
    font-size: 13px;
    margin-top: 4px;
}

.invoice-template__client {
    margin-bottom: 24px;
    padding: 16px;
    background: #F8FAFC;
    border-radius: 8px;
}

.invoice-template__client h3 {
    font-size: 11px;
    text-transform: uppercase;
    color: #94A3B8;
    margin-bottom: 4px;
}

.invoice-template__client-name {
    font-size: 17px;
    font-weight: 600;
    color: #1E293B;
}

.invoice-template__table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.invoice-template__table th {
    text-align: left;
    padding: 10px 12px;
    border-bottom: 2px solid #E2E8F0;
    font-size: 11px;
    text-transform: uppercase;
    color: #64748B;
}

.invoice-template__table td {
    padding: 10px 12px;
    border-bottom: 1px solid #F1F5F9;
    color: #1E293B;
}

.invoice-template__table th:last-child,
.invoice-template__table td:last-child {
    text-align: right;
}

.invoice-template__table th:nth-child(2),
.invoice-template__table td:nth-child(2),
.invoice-template__table th:nth-child(3),
.invoice-template__table td:nth-child(3) {
    text-align: center;
}

.invoice-template__totals {
    margin-left: auto;
    width: 260px;
}

.invoice-template__total-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 14px;
    color: #475569;
}

.invoice-template__total-row--grand {
    border-top: 2px solid #1E293B;
    font-size: 18px;
    font-weight: 700;
    padding-top: 10px;
    margin-top: 8px;
    color: #1E293B;
}

.invoice-template__notes {
    margin-top: 28px;
    padding: 16px;
    background: #F8FAFC;
    border-radius: 8px;
}

.invoice-template__notes h4 {
    font-size: 11px;
    text-transform: uppercase;
    color: #94A3B8;
    margin-bottom: 6px;
}

.invoice-template__notes p {
    color: #475569;
    font-size: 13px;
}

/* ── Hidden sections ── */
.section {
    display: none;
}

.section--active {
    display: block;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .app {
        padding: 16px;
    }

    .header {
        flex-direction: column;
        align-items: flex-start;
    }

    .stats {
        grid-template-columns: 1fr 1fr;
    }

    .invoice-row {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        padding: 14px;
    }

    .invoice-row__due {
        display: none;
    }

    .invoice-row__actions {
        display: none;
    }

    .modal {
        width: 100%;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .chart__bar {
        width: 16px;
    }
}

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

    .tabs {
        flex-wrap: nowrap;
    }

    .tab {
        padding: 8px 14px;
        font-size: 13px;
    }

    .invoice-row {
        grid-template-columns: 1fr;
    }
}

/* ── Scrollbar ── */
::-webkit-scrollbar {
    width: 6px;
}

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

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-dim);
}

/* ── Focus visible ── */
:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}