body {
    background-color: #f5f7fa;
}

.card-header {
    background-color: #fff;
}

#history-body td {
    font-size: 0.9rem;
}

.call-id {
    font-family: SFMono-Regular, Consolas, "Liberation Mono", monospace;
    font-size: 0.8rem;
    word-break: break-all;
}

.speech-cell {
    max-width: 240px;
    font-style: italic;
    word-break: break-word;
}

.notes-cell {
    max-width: 260px;
    color: #6c757d;
    word-break: break-word;
}

.badge-sim {
    background-color: #6f42c1;
    color: #fff;
}

/* ---------------------------------------------------------------- layout (Phase 2) */

:root {
    --sidebar-width: 248px;
}

.app-shell .min-vw-0 {
    min-width: 0;
}

.sidebar {
    --bs-offcanvas-width: var(--sidebar-width);
}

@media (min-width: 992px) {
    .sidebar {
        width: var(--sidebar-width);
        min-height: 100vh;
        position: sticky;
        top: 0;
        flex-shrink: 0;
        align-self: flex-start;
        height: 100vh;
        overflow-y: auto;
    }
}

.sidebar-brand {
    height: 56px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-heading {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(255, 255, 255, 0.45);
    padding: 0.9rem 0.75rem 0.3rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    color: rgba(255, 255, 255, 0.8);
    border-radius: 0.375rem;
    padding: 0.45rem 0.75rem;
    margin-bottom: 2px;
}

.sidebar-link:hover,
.sidebar-link:focus {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.08);
}

.sidebar-link.active {
    color: #fff;
    background-color: var(--bs-primary);
}

.sidebar-link.disabled {
    color: rgba(255, 255, 255, 0.35);
}

.topbar {
    min-height: 56px;
    z-index: 1020;
    row-gap: 0.25rem;
}

.empty-state i {
    opacity: 0.6;
}

.form-card {
    max-width: 880px;
}

.form-card-narrow {
    max-width: 520px;
}

.settings-number {
    max-width: 240px;
}

/* ---------------------------------------------------------------- login */

.login-page {
    background: linear-gradient(135deg, #1f2937 0%, #334155 100%);
}

.login-card {
    max-width: 420px;
    border: 0;
}

.login-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #fff;
    background-color: var(--bs-primary);
}

/* ---------------------------------------------------------------- jobs and candidates (Phase 3) */

.preserve-lines {
    white-space: pre-line;
}

.avatar-circle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.25rem;
    color: #fff;
    background-color: var(--bs-primary);
}

/* ---------------------------------------------------------------- campaigns and reports (Phase 5) */

/* Progress widths as classes: the Content-Security-Policy forbids inline styles. */
.progress-w-0 { width: 0%; }
.progress-w-5 { width: 5%; }
.progress-w-10 { width: 10%; }
.progress-w-15 { width: 15%; }
.progress-w-20 { width: 20%; }
.progress-w-25 { width: 25%; }
.progress-w-30 { width: 30%; }
.progress-w-35 { width: 35%; }
.progress-w-40 { width: 40%; }
.progress-w-45 { width: 45%; }
.progress-w-50 { width: 50%; }
.progress-w-55 { width: 55%; }
.progress-w-60 { width: 60%; }
.progress-w-65 { width: 65%; }
.progress-w-70 { width: 70%; }
.progress-w-75 { width: 75%; }
.progress-w-80 { width: 80%; }
.progress-w-85 { width: 85%; }
.progress-w-90 { width: 90%; }
.progress-w-95 { width: 95%; }
.progress-w-100 { width: 100%; }

.progress-lg {
    height: 0.9rem;
}

.candidate-picker {
    max-height: 460px;
    overflow-y: auto;
}

.confirm-word {
    width: 8rem;
}

.member-pending { background-color: #e9ecef; color: #495057; }
.member-calling { background-color: var(--bs-primary); color: #fff; }
.member-waiting_retry { background-color: var(--bs-info); color: #000; }
.member-completed { background-color: var(--bs-success); color: #fff; }
.member-failed { background-color: var(--bs-danger); color: #fff; }
.member-skipped, .member-cancelled { background-color: #f8f9fa; color: #6c757d; border: 1px solid #dee2e6; }

.chart-box {
    position: relative;
    height: 300px;
}

.daily-table {
    max-height: 320px;
    overflow-y: auto;
}

.outcome-track {
    height: 10px;
    background-color: #f0efec;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 4px;
}

.outcome-fill {
    height: 100%;
    border-radius: 0 4px 4px 0;
}

.legend-swatch {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 2px;
    margin-right: 6px;
    vertical-align: baseline;
}

/* Outcome colours: validated categorical slots 1-5, fixed order. */
.swatch-1 { background-color: #2a78d6; }
.swatch-2 { background-color: #eb6834; }
.swatch-3 { background-color: #1baf7a; }
.swatch-4 { background-color: #eda100; }
.swatch-5 { background-color: #e87ba4; }

.stat-tile .fs-3 {
    line-height: 1.2;
}

.audit-details {
    max-width: 420px;
    font-family: SFMono-Regular, Consolas, "Liberation Mono", monospace;
    font-size: 0.75rem;
}
