/* ============================================================
   Clinical Trials Page – page-specific styles
   Font: Tabler default (Inter / system-ui stack)
   ============================================================ */

body {
    background-color: var(--background-color, #f7fafc);
    color: var(--text-primary, #1a202c);
}

.container {
    max-width: 100%;
    margin: 0 auto;
    padding: 20px;
}

h1 {
    margin-bottom: 20px;
    color: #2563eb;
}

/* ── Main Layout ────────────────────────────────────────── */
.main-layout {
    display: flex;
    gap: 20px;
    min-height: 600px;
}

/* ── Left Sidebar ───────────────────────────────────────── */
.sidebar {
    width: 400px;
    flex-shrink: 0;
    background: white;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    position: relative;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.sidebar h2 {
    font-size: 18px;
    color: #2563eb;
    border-bottom: 2px solid #2563eb;
    padding-bottom: 10px;
}

/* ── Filter Sections ────────────────────────────────────── */
.filter-section {
    margin-bottom: 25px;
}

.card-body{
    padding: 1.2rem !important;
}

.filter-section h3 {
    font-size: 15px;
    margin-bottom: 10px;
    color: #475569;
    font-weight: 600;
}

.filter-option {
    margin-bottom: 8px;
    display: flex;
    align-items: center;
}

.filter-option input[type="checkbox"],
.filter-option input[type="radio"] {
    margin-right: 8px;
    cursor: pointer;
    accent-color: #ad489d;
    width: 15px;
    height: 15px;
    flex-shrink: 0;
}

/* Highlight label when input is checked */
.filter-option input[type="checkbox"]:checked + label,
.filter-option input[type="radio"]:checked + label {
    color: #ad489d;
    font-weight: 600;
}

.filter-option label {
    cursor: pointer;
    font-size: 14px;
}

.filter-section select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
}

/* Prior Treatments dependent filter section */
.filter-section--disabled {
    opacity: 0.45;
    pointer-events: none;
    user-select: none;
}

.filter-section--disabled h3 {
    color: #94a3b8;
}

.filter-section-hint {
    font-size: 12px;
    color: #94a3b8;
    font-style: italic;
    margin: 0 0 8px;
    line-height: 1.4;
}

/* Treatment subheaders for Prostate Cancer (cancerType=2) grouping */
.treatment-subheader {
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    margin: 12px 0 8px;
    padding-top: 8px;
    border-top: 1px solid #e2e8f0;
    line-height: 1.3;
}

.treatment-subheader:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}

/* ── View Details Button ────────────────────────────────── */
.view-details-btn {
    display: inline-block;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 6px;
    background: #e5e7eb;
    color: #4b5563;
    border: none;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.view-details-btn:hover {
    background: #d1d5db;
    color: #4b5563;
    text-decoration: none;
}

/* ── Reset / Copy buttons (match cancer-tab size) ───────── */
.reset-filters-btn {
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 6px;
    white-space: nowrap;
}

.reset-filters-btn {
    background: #e5e7eb;
    color: #4b5563;
    border: none;
}

.reset-filters-btn:hover {
    background: #d1d5db;
}

.copy-link-btn {
    background: #e5e7eb;
    color: #4b5563;
    border: none;
    font-size: 14px;
    font-weight: 500;
    padding: 12px 24px;
    border-radius: 999px;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s ease;
}

.copy-link-btn:hover {
    background: #2563eb;
    color: #fff;
}

/* ── Right Content Area ─────────────────────────────────── */
.content-area {
    flex: 1;
    min-width: 0;
}

/* ── Results Header ─────────────────────────────────────── */
.results-header {
    background: white;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.results-header h2 {
    font-size: 20px;
    color: #1e293b;
}

.results-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ── Grid / Table Layout Toggle ─────────────────────────── */
.layout-toggle {
    display: inline-flex;
    border-radius: 999px;
    background: #e5e7eb;
    padding: 2px;
}

.layout-toggle button {
    border: none;
    background: transparent;
    padding: 4px 10px;
    font-size: 12px;
    border-radius: 999px;
    cursor: pointer;
    color: #4b5563;
}

.layout-toggle button.active {
    background: #2563eb;
    color: #fff;
}

.copy-status {
    font-size: 12px;
    color: #16a34a;
}

/* ── Cancer Type Tabs ───────────────────────────────────── */
.cancer-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.cancer-tab {
    padding: 12px 24px;
    background: #e5e7eb;
    color: #4b5563;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.cancer-tab:hover {
    background: #d1d5db;
}

.cancer-tab.active {
    background: #ad489d;
    color: white;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.3);
}

/* ── Provider Interest Button ───────────────────────────── */
.provider-interest-btn {
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 500;
    background: #2563eb;
    color: white;
    border: none;
    border-radius: 6px;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.2s ease;
    white-space: nowrap;
    margin-left: auto;
}

.provider-interest-btn:hover {
    background: #1d4ed8;
    color: white;
    text-decoration: none;
}

.provider-interest-btn i {
    margin-right: 6px;
}

#results-title {
    color:  #2563eb;
}

/* ── Results Grid ───────────────────────────────────────── */
.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

/* ── Trial Card Meta ────────────────────────────────────── */
.trial-meta {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 0.75rem;
    font-size: 13px;
}

.trial-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.trial-meta-label {
    font-weight: 600;
    color: #475569;
    margin-right: 4px;
}

.trial-meta-value {
    color: #0f172a;
}

.trial-title {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.4;
    text-align: left;
}

/* ── Status Badge ───────────────────────────────────────── */
.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    color: #fff;
}

.status-open {
    background: #16a34a;
}

.status-closed {
    background: #9ca3af;
}

/* ── Match Score Circle ─────────────────────────────────── */

/* Flex wrapper that holds [circle] [title text] side-by-side */
.trial-title-cell {
    display: inline;
    font-weight: 500;
    line-height: 1.4;
}

/* Stacks status badge above the title text inside the title column */
.trial-title-stack {
    display: inline-flex;
    flex-direction: column;
    gap: 3px;
    align-items: flex-start;
}

.trial-status-line {
    display: block;
}

.trial-status-subtext {
    font-size: 11px;
    padding: 1px 7px;
}



/* ── Results Table ──────────────────────────────────────── */
.results-table-wrapper {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 0;
}

.results-table-wrapper table {
    margin-bottom: 0;
    border-collapse: separate;
    border-spacing: 0 6px;
}

.results-table-wrapper thead th {
    padding: 14px 20px;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 2px solid #e5e7eb;
}

.results-table-wrapper tbody td {
    padding: 28px 24px;
    vertical-align: top;
    border-bottom: 1px solid #f3f4f6;
}

.results-table-wrapper tbody tr {
    border-top: 8px solid transparent;
}

.results-table-wrapper tbody tr:last-child td {
    border-bottom: none;
}

/* ── Offcanvas body font size ───────────────────────────── */
.offcanvas-body {
    font-size: 1rem;
}

/* ── Offcanvas close button ─────────────────────────────── */
.offcanvas-close-btn {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background-color: #0d6efd;
    opacity: 1;
}


.trial-detail-row {
    font-size: 13px;
    line-height: 1.5;
    color: #374151;
}

.trial-detail-row + .trial-detail-row {
    margin-top: 2px;
}

.trial-detail-label {
    font-weight: 600;
    color: #6b7280;
    margin-right: 4px;
}

/* ── Available Locations block ──────────────────────────── */
.available-locations-block {
    padding-top: 0;
    margin-top: 0;
}

.available-locations-label {
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.07em;
    color: #9ca3af;
    font-weight: 600;
    margin-bottom: 10px;
}

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

/* Card-style location pill with Connect button */
.location-card {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 13px;
    color: #1e293b;
    font-weight: 500;
    min-width: 220px;
    justify-content: space-between;
}

.location-icon {
    color: #6b7280;
    font-size: 14px;
    flex-shrink: 0;
}

.location-name {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.location-connect-btn {
    flex-shrink: 0;
    padding: 4px 14px;
    font-size: 12px;
    font-weight: 600;
    background: #0d6efd;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s ease;
    white-space: nowrap;
}

.location-connect-btn:hover {
    background: #0b5ed7;
}

/* Inactive location card */
.location-card--inactive {
    background: #f3f4f6;
    border-color: #e5e7eb;
    opacity: 0.7;
}

.location-card--inactive .location-icon {
    color: #9ca3af;
}

.location-card--inactive .location-name {
    color: #6b7280;
}

.location-connect-btn--disabled {
    background: #d1d5db;
    color: #6b7280;
    cursor: not-allowed;
    pointer-events: none;
}

.location-connect-btn--disabled:hover {
    background: #d1d5db;
}

/* ── Closed trial row (table layout) ────────────────────── */
tr.tr--closed td {
    opacity: 0.55;
    background: #f9fafb;
}

tr.tr--closed .trial-title-cell {
    color: #6b7280;
}

tr.tr--closed .trial-detail-row {
    color: #9ca3b8;
}

/* Closed trial card (grid layout) */
.card--closed {
    opacity: 0.6;
    background: #f9fafb;
    pointer-events: none; /* block all interaction on the card */
}

/* Re-enable pointer events for buttons inside so disabled attr tooltip still works */
.card--closed button {
    pointer-events: auto;
}

/* Disabled View Details button */
.view-details-btn--disabled {
    background: #d1d5db !important;
    color: #6b7280 !important;
    cursor: not-allowed;
}

.view-details-btn--disabled:hover {
    background: #d1d5db !important;
}
.locations-full-row td {
    padding: 0 24px 20px 24px !important;
    border-bottom: 1px solid #e5e7eb;
    background: #f9fafb;
}

.locations-full-row:last-child td {
    border-bottom: none;
}

/* ── Pagination ─────────────────────────────────────────── */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 30px;
    padding: 20px;
    background: white;
    border-radius: 8px;
}

.pagination button {
    padding: 8px 16px;
    border: 1px solid #ddd;
    background: white;
    cursor: pointer;
    border-radius: 4px;
    font-size: 14px;
}

.pagination button:hover:not(:disabled) {
    background: #f1f5f9;
}

.pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination .page-info {
    font-size: 14px;
    color: #64748b;
}

/* ── Loading State ──────────────────────────────────────── */
.loading {
    text-align: center;
    padding: 60px 20px;
    color: #64748b;
}

.spinner {
    border: 3px solid #f3f4f6;
    border-top: 3px solid #2563eb;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0%   { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ── Empty State ────────────────────────────────────────── */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 8px;
}

.empty-state h3 {
    color: #843177;
    margin-bottom: 10px;
}

.empty-state p {
    color:#843177;
}

/* ── Error State ────────────────────────────────────────── */
.error-state {
    background: #fee;
    border: 1px solid #fcc;
    padding: 20px;
    border-radius: 8px;
    color: #c00;
}

/* ============================================================
   Mobile Filter Toggle Button (hidden on desktop)
   ============================================================ */
.mobile-filter-toggle {
    display: none;
    width: 100%;
    padding: 10px 16px;
    background: #2563eb;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    margin-bottom: 12px;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.mobile-filter-toggle:hover {
    background: #1d4ed8;
}

/* ============================================================
   Responsive Breakpoints
   ============================================================ */

/* ── Tablet (≤ 1024px) ──────────────────────────────────── */
@media (max-width: 1024px) {
    .sidebar {
        width: 300px;
    }

    .results-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }

    .copy-link-btn,
    .cancer-tab {
        padding: 10px 18px;
    }
}

/* ── Mobile (≤ 768px) ───────────────────────────────────── */
@media (max-width: 768px) {

    /* Container padding */
    .container {
        padding: 12px;
    }

    h1 {
        font-size: 22px;
        margin-bottom: 14px;
    }

    /* Stack sidebar above content on mobile */
    .main-layout {
        flex-direction: column;
        gap: 12px;
        min-height: unset;
    }

    /* Sidebar becomes collapsible */
    .sidebar {
        width: 100%;
        max-height: none;
        overflow-y: visible;
        padding: 12px;
    }

    /* Show mobile filter toggle button */
    .mobile-filter-toggle {
        display: flex;
    }

    /* Hide filter body by default on mobile; shown via JS toggle */
    #filters-body {
        display: none;
    }

    #filters-body.open {
        display: block;
    }

    /* Sidebar header adjustments */
    .sidebar-header {
        margin-bottom: 0;
    }

    .sidebar h2 {
        font-size: 16px;
    }

    /* Cancer tabs: scroll horizontally */
    .cancer-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 4px;
        gap: 8px;
        scrollbar-width: none;
    }

    .cancer-tabs::-webkit-scrollbar {
        display: none;
    }

    .cancer-tab {
        flex-shrink: 0;
        padding: 9px 16px;
        font-size: 13px;
    }

    /* Results header: stack vertically */
    .results-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding: 12px;
    }

    .results-header h2 {
        font-size: 16px;
    }

    .results-actions {
        width: 100%;
        flex-wrap: wrap;
        gap: 8px;
    }

    .copy-link-btn {
        flex: 1;
        text-align: center;
        padding: 10px 16px;
        font-size: 13px;
    }

    .layout-toggle {
        flex-shrink: 0;
    }

    /* Grid: single column on mobile */
    .results-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    /* Table: allow horizontal scroll */
    .results-table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .results-table-wrapper table {
        min-width: 600px;
    }

    /* Cards */
    .card-body {
        padding: 1rem !important;
    }

    .trial-title {
        font-size: 14px;
    }

    .view-details-btn {
        text-align: center;
        display: inline-block;
    }

    /* Pagination */
    .pagination {
        padding: 12px;
        gap: 8px;
    }

    .pagination button {
        padding: 6px 12px;
        font-size: 13px;
    }
}

/* ── Small Mobile (≤ 480px) ─────────────────────────────── */
@media (max-width: 480px) {

    h1 {
        font-size: 18px;
    }

    .results-header h2 {
        font-size: 14px;
    }

    .cancer-tab {
        padding: 8px 12px;
        font-size: 12px;
    }

    .copy-link-btn {
        font-size: 12px;
        padding: 9px 14px;
    }

    .trial-meta {
        font-size: 12px;
    }

    .status-badge {
        font-size: 11px;
    }
}

/* ============================================================
   Connect Role Modal
   ============================================================ */

.connect-modal-dialog {
    max-width: 480px;
}

.connect-modal-content {
    border: none;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    background: #ffffff;
    position: relative;
    overflow: hidden;
}

/* Close (×) button in top-right corner */
.connect-modal-close {
    position: absolute;
    top: 14px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: #f3f4f6;
    color: #6b7280;
    font-size: 18px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: background 0.15s ease, color 0.15s ease;
}

.connect-modal-close:hover {
    background: #e5e7eb;
    color: #111827;
}

.connect-modal-body {
    padding: 40px 36px 32px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.connect-modal-title {
    font-size: 20px;
    font-weight: 700;
    color: #111827;
    margin: 0;
    line-height: 1.3;
}

.connect-modal-subtitle {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
    line-height: 1.5;
}

/* Role selection cards */
.connect-role-card {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 16px 18px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    background: #ffffff;
    cursor: pointer;
    text-align: left;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.connect-role-card:hover {
    border-color: #0d6efd;
    background: #f0f6ff;
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.12);
}

/* Active/selected card highlight */
.connect-role-card--active {
    border-color: #0d6efd;
    background: #f0f6ff;
}

.connect-role-icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #e0ecff;
    color: #0d6efd;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.connect-role-card--active .connect-role-icon {
    background: #0d6efd;
    color: #ffffff;
}

.connect-role-card:hover .connect-role-icon {
    background: #0d6efd;
    color: #ffffff;
}

.connect-role-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.connect-role-name {
    font-size: 15px;
    font-weight: 600;
    color: #111827;
}

.connect-role-desc {
    font-size: 13px;
    color: #6b7280;
}

/* "Learn more" link at the bottom */
.connect-learn-more {
    display: block;
    text-align: center;
    font-size: 13px;
    color: #6b7280;
    text-decoration: none;
    margin-top: 4px;
    transition: color 0.15s ease;
}

.connect-learn-more:hover {
    color: #0d6efd;
    text-decoration: underline;
}

@media (max-width: 480px) {
    .connect-modal-dialog {
        margin: 16px;
        max-width: calc(100vw - 32px);
    }

    .connect-modal-body {
        padding: 32px 20px 24px;
    }
}

/* ── Provider Connect Form ───────────────────────────────── */
.provider-form-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.provider-form-label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
}

.provider-form-input {
    padding: 9px 12px;
    border: 1.5px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    color: #111827;
    background: #fff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    outline: none;
    width: 100%;
}

.provider-form-input:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.12);
}

.provider-form-textarea {
    resize: vertical;
    min-height: 72px;
}

.provider-submit-btn {
    width: 100%;
    padding: 11px;
    background: #0d6efd;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
    margin-top: 4px;
}

.provider-submit-btn:hover:not(:disabled) {
    background: #0b5ed7;
}

.provider-submit-btn:disabled {
    background: #93c5fd;
    cursor: not-allowed;
}

.provider-form-error {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    color: #b91c1c;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 13px;
}

.provider-form-success {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
    padding: 16px 0 8px;
}

.provider-form-success .bi-check-circle-fill {
    font-size: 48px;
    color: #16a34a;
}

.provider-form-success p {
    font-size: 15px;
    color: #374151;
    margin: 0;
}

/* ============================================================
   Cohort Tabs & Criteria Panel
   ============================================================ */
.cohort-section {
    margin-top: 8px;
}

.cohort-section-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .07em;
    color: #64748b;
    text-transform: uppercase;
    margin-bottom: 6px;
}

/* Tab strip */
.cohort-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.cohort-tab {
    display: inline-flex;
    align-items: center;
    padding: 4px 14px;
    border: 1.5px solid #cbd5e1;
    border-radius: 999px;
    background: #f8fafc;
    color: #475569;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s, border-color .15s, color .15s;
    white-space: nowrap;
}

.cohort-tab:hover {
    background: #f1f5f9;
    border-color: #ad489d;
    color: #ad489d;
}

.cohort-tab--active {
    background: #ad489d;
    border-color: #ad489d;
    color: #fff;
}

/* Criteria panel */
.cohort-panels {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 10px 14px;
}

.cohort-criteria-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cohort-criteria-list li {
    font-size: 13px;
    color: #374151;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.cohort-crit-label {
    font-weight: 600;
    color: #1e293b;
    min-width: max-content;
}

/* ── Flat cohort criteria list (matches image design) ───────────────── */
.cohort-section--flat {
    margin-top: 10px;
    margin-bottom: 6px;
}

.cohort-flat-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
}

/* Each row: label and value sit inline on the same line */
.cohort-flat-item {
    font-size: 13.5px;
    color: #374151;
    display: block;
}

.cohort-flat-label {
    font-weight: 700;
    color: #1e293b;
    /* colon is rendered inside the span via JS; one space gap before value */
    margin-right: 3px;
}

.cohort-flat-value {
    font-weight: 400;
    color: #374151;
}

/* Excluded row — same appearance as all other rows to match image */
.cohort-flat-item--excluded .cohort-flat-label {
    font-weight: 700;
    color: #1e293b;
}

.cohort-flat-item--excluded .cohort-flat-value {
    font-weight: 400;
    color: #374151;
}

