.cb-page {
    --cb-bg: #08141c;
    --cb-bg-soft: #0e202b;
    --cb-panel: rgba(10, 24, 34, 0.9);
    --cb-panel-strong: rgba(13, 30, 41, 0.98);
    --cb-border: rgba(161, 184, 200, 0.14);
    --cb-border-strong: rgba(224, 159, 62, 0.24);
    --cb-text: #f4efe6;
    --cb-muted: #a7b5bf;
    --cb-accent: #e09f3e;
    --cb-accent-strong: #f4b860;
    --cb-accent-soft: rgba(224, 159, 62, 0.14);
    --cb-secondary: #2aa198;
    --cb-secondary-soft: rgba(42, 161, 152, 0.18);
    min-height: 100vh;
    position: relative;
    overflow: hidden;
    color: var(--cb-text);
    background:
        radial-gradient(circle at top left, rgba(42, 161, 152, 0.18), transparent 32%),
        radial-gradient(circle at top right, rgba(224, 159, 62, 0.18), transparent 28%),
        linear-gradient(180deg, #071118 0%, #09161f 42%, #08141c 100%);
}

.cb-atmosphere {
    position: absolute;
    border-radius: 999px;
    pointer-events: none;
    filter: blur(40px);
    opacity: 0.45;
}

.cb-atmosphere-one {
    width: 360px;
    height: 360px;
    right: -80px;
    top: 120px;
    background: rgba(224, 159, 62, 0.16);
}

.cb-atmosphere-two {
    width: 420px;
    height: 420px;
    left: -160px;
    bottom: 140px;
    background: rgba(42, 161, 152, 0.14);
}

.cb-topbar,
.cb-main {
    position: relative;
    z-index: 1;
}

.cb-topbar {
    width: min(1360px, calc(100% - 40px));
    margin: 20px auto 0;
    padding: 18px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border: 1px solid var(--cb-border);
    border-radius: 24px;
    background: rgba(7, 18, 26, 0.78);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.22);
}

.cb-brand {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    color: var(--cb-text);
}

.cb-brand-mark {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: linear-gradient(135deg, #d2841f 0%, #efc06d 100%);
    color: #101010;
    font-weight: 800;
    letter-spacing: 0.06em;
    box-shadow: 0 16px 38px rgba(224, 159, 62, 0.24);
}

.cb-brand-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cb-brand-copy strong {
    font-size: 0.96rem;
    letter-spacing: 0.08em;
}

.cb-brand-copy span {
    color: var(--cb-muted);
    font-size: 0.78rem;
}

.cb-nav {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.cb-nav a {
    color: var(--cb-muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
}

.cb-nav a:hover {
    color: var(--cb-text);
}

.cb-nav-cta {
    padding: 11px 16px;
    border-radius: 999px;
    border: 1px solid rgba(224, 159, 62, 0.28);
    background: rgba(224, 159, 62, 0.08);
    color: var(--cb-text) !important;
}

.cb-main {
    width: min(1360px, calc(100% - 40px));
    margin: 28px auto 40px;
}

.cb-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
    gap: 24px;
    align-items: stretch;
    margin-bottom: 28px;
}

.cb-hero-copy,
.cb-stats-panel,
.cb-results-shell,
.cb-reader-shell {
    border: 1px solid var(--cb-border);
    border-radius: 28px;
    background: var(--cb-panel);
    -webkit-backdrop-filter: blur(18px);
    backdrop-filter: blur(18px);
}

.cb-hero-copy {
    padding: 34px;
}

.cb-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--cb-accent-soft);
    border: 1px solid rgba(224, 159, 62, 0.2);
    color: var(--cb-accent-strong);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.cb-hero h1 {
    margin: 18px 0 14px;
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(2.8rem, 5vw, 4.9rem);
    line-height: 0.94;
    letter-spacing: -0.04em;
}

.cb-hero p {
    max-width: 720px;
    color: var(--cb-muted);
    font-size: 1.02rem;
    line-height: 1.8;
    margin: 0 0 22px;
}

.cb-hero-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 24px;
}

.cb-hero-pills span,
.cb-court-pill,
.cb-tag {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid rgba(161, 184, 200, 0.12);
    background: rgba(255, 255, 255, 0.04);
    color: var(--cb-text);
    font-size: 0.82rem;
    font-weight: 600;
}

.cb-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.cb-btn,
.cb-mini-btn {
    border: none;
    cursor: pointer;
    font: inherit;
}

.cb-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 0 18px;
    border-radius: 16px;
    text-decoration: none;
    font-weight: 700;
    transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.cb-btn:hover,
.cb-mini-btn:hover {
    transform: translateY(-1px);
}

.cb-btn-primary {
    background: linear-gradient(135deg, #d2841f 0%, #efc06d 100%);
    color: #101010;
    box-shadow: 0 18px 40px rgba(224, 159, 62, 0.18);
}

.cb-btn-secondary,
.cb-btn-ghost {
    border: 1px solid var(--cb-border);
    background: rgba(255, 255, 255, 0.04);
    color: var(--cb-text);
}

.cb-stats-panel {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.cb-stat-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.cb-stat-card {
    min-height: 112px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 22px;
    background: var(--cb-panel-strong);
}

.cb-stat-card-featured {
    min-height: 168px;
    border-color: var(--cb-border-strong);
    background:
        linear-gradient(180deg, rgba(224, 159, 62, 0.08), rgba(255, 255, 255, 0.02)),
        var(--cb-panel-strong);
}

.cb-stat-label {
    color: var(--cb-muted);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 700;
}

.cb-stat-value {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 2.7rem;
    line-height: 1;
    letter-spacing: -0.03em;
}

.cb-stat-note,
.cb-stat-footnote {
    color: var(--cb-muted);
    font-size: 0.92rem;
    line-height: 1.6;
}

.cb-workbench {
    display: grid;
    grid-template-columns: minmax(0, 1.03fr) minmax(360px, 0.97fr);
    gap: 24px;
    align-items: start;
}

.cb-results-shell,
.cb-reader-shell {
    overflow: hidden;
}

.cb-search-panel {
    padding: 24px;
    border-bottom: 1px solid var(--cb-border);
    background: rgba(255, 255, 255, 0.025);
}

.cb-search-row {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) repeat(2, minmax(140px, 0.65fr)) auto;
    gap: 12px;
    align-items: end;
}

.cb-search-label {
    display: block;
    margin-bottom: 8px;
    color: var(--cb-muted);
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.cb-search-input-wrap input,
.cb-filter-wrap select {
    width: 100%;
    min-height: 52px;
    padding: 0 16px;
    border-radius: 16px;
    border: 1px solid var(--cb-border);
    background: rgba(255, 255, 255, 0.05);
    color: var(--cb-text);
    font: inherit;
    outline: none;
}

.cb-search-input-wrap input:focus,
.cb-filter-wrap select:focus {
    border-color: rgba(224, 159, 62, 0.32);
    box-shadow: 0 0 0 4px rgba(224, 159, 62, 0.08);
}

.cb-filter-wrap select {
    appearance: none;
}

.cb-toolbar {
    margin-top: 16px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.cb-result-meta {
    color: var(--cb-muted);
    font-size: 0.92rem;
}

.cb-selection-bar {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 10px 12px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(42, 161, 152, 0.18);
}

.cb-selection-bar span {
    color: var(--cb-text);
    font-size: 0.88rem;
    font-weight: 600;
}

.cb-mini-btn {
    min-height: 38px;
    padding: 0 12px;
    border-radius: 12px;
    background: var(--cb-secondary-soft);
    color: var(--cb-text);
}

.cb-mini-btn:disabled,
.cb-btn:disabled {
    cursor: not-allowed;
    opacity: 0.55;
    transform: none;
}

.cb-mini-btn-accent {
    background: linear-gradient(135deg, rgba(224, 159, 62, 0.2), rgba(244, 184, 96, 0.26));
    border: 1px solid rgba(224, 159, 62, 0.24);
}

.cb-mini-btn-muted {
    background: rgba(255, 255, 255, 0.06);
}

.cb-results-list {
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-height: 540px;
}

.cb-result-card,
.cb-empty-state {
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.02);
}

.cb-result-card {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 16px;
    padding: 18px;
    transition: border-color 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

.cb-result-card:hover,
.cb-result-card.active {
    border-color: rgba(224, 159, 62, 0.22);
    background: rgba(224, 159, 62, 0.05);
    transform: translateY(-1px);
}

.cb-result-select {
    padding-top: 6px;
}

.cb-result-checkbox {
    width: 18px;
    height: 18px;
    accent-color: #d2841f;
}

.cb-result-kicker,
.cb-reader-kicker {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    color: var(--cb-muted);
    font-size: 0.82rem;
}

.cb-result-title {
    margin: 0 0 8px;
    font-size: 1.14rem;
    line-height: 1.4;
}

.cb-result-citation,
.cb-reader-citation {
    color: var(--cb-accent-strong);
    font-weight: 700;
    letter-spacing: 0.02em;
}

.cb-result-preview {
    margin: 12px 0;
    color: var(--cb-muted);
    line-height: 1.7;
    font-size: 0.95rem;
}

.cb-result-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.cb-tag {
    padding: 7px 10px;
    font-size: 0.78rem;
    color: var(--cb-muted);
}

.cb-open-link,
.cb-source-link {
    color: var(--cb-text);
    text-decoration: none;
    font-weight: 700;
}

.cb-open-link {
    min-height: 44px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.cb-results-footer {
    padding: 0 18px 18px;
}

.cb-reader-shell {
    position: sticky;
    top: 16px;
    min-height: 760px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.015));
}

.cb-reader-placeholder,
.cb-reader {
    padding: 28px;
}

.cb-reader-placeholder-mark {
    display: inline-flex;
    margin-bottom: 18px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(42, 161, 152, 0.12);
    color: #7de2d9;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.cb-reader-placeholder h2,
.cb-reader-header h2,
.cb-empty-state h3 {
    margin: 0 0 12px;
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 2rem;
    line-height: 1.02;
}

.cb-reader-placeholder p,
.cb-empty-state p {
    color: var(--cb-muted);
    line-height: 1.8;
}

.cb-reader-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--cb-border);
}

.cb-reader-meta-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding: 18px 0 22px;
}

.cb-meta-card {
    min-height: 88px;
    padding: 14px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.cb-meta-card span {
    display: block;
    margin-bottom: 7px;
    color: var(--cb-muted);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.cb-meta-card strong,
.cb-meta-card div {
    color: var(--cb-text);
    line-height: 1.7;
}

.cb-reader-sections {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 22px;
}

.cb-reader-section,
.cb-reader-body-section {
    padding: 18px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.cb-section-heading-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.cb-reader-section h3,
.cb-reader-body-section h3 {
    margin: 0;
    font-size: 1rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.cb-reader-section p,
.cb-reader-text {
    margin: 0;
    color: var(--cb-muted);
    line-height: 1.82;
}

.cb-reader-text {
    white-space: pre-wrap;
    font-size: 0.94rem;
}

.cb-loading,
.cb-empty-state {
    padding: 28px;
}

.cb-empty-state {
    text-align: center;
}

.cb-loading {
    color: var(--cb-muted);
}

.cb-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(4, 10, 16, 0.78);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
}

.cb-modal-backdrop[hidden] {
    display: none;
    pointer-events: none;
}

.cb-modal {
    width: min(860px, 100%);
    max-height: min(88vh, 960px);
    overflow: auto;
    padding: 28px;
    border-radius: 28px;
    border: 1px solid var(--cb-border);
    background: rgba(7, 19, 28, 0.96);
    box-shadow: 0 36px 90px rgba(0, 0, 0, 0.34);
}

.cb-modal-header,
.cb-modal-actions {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.cb-modal-header h2 {
    margin: 14px 0 0;
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 2.1rem;
    line-height: 1.02;
}

.cb-modal-close {
    border: 1px solid var(--cb-border);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--cb-text);
    min-height: 42px;
    padding: 0 14px;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
}

.cb-modal-note,
.cb-analysis-status {
    color: var(--cb-muted);
    line-height: 1.8;
}

.cb-analysis-prompt-wrap {
    display: block;
    margin-top: 18px;
}

.cb-analysis-prompt-wrap textarea {
    width: 100%;
    min-height: 132px;
    padding: 16px;
    border-radius: 18px;
    border: 1px solid var(--cb-border);
    background: rgba(255, 255, 255, 0.04);
    color: var(--cb-text);
    font: inherit;
    line-height: 1.6;
    resize: vertical;
    outline: none;
}

.cb-analysis-prompt-wrap textarea:focus {
    border-color: rgba(224, 159, 62, 0.32);
    box-shadow: 0 0 0 4px rgba(224, 159, 62, 0.08);
}

.cb-analysis-quick-prompts {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 16px 0 20px;
}

.cb-modal-actions {
    margin-bottom: 14px;
}

.cb-analysis-output {
    margin-top: 18px;
    padding: 20px;
    border-radius: 24px;
    border: 1px solid rgba(224, 159, 62, 0.14);
    background: rgba(255, 255, 255, 0.03);
}

.cb-analysis-selected-cases {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 16px;
}

.cb-analysis-case-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid rgba(161, 184, 200, 0.12);
    background: rgba(255, 255, 255, 0.03);
    color: var(--cb-text);
    font-size: 0.82rem;
}

.cb-analysis-result {
    white-space: pre-wrap;
    color: var(--cb-text);
    line-height: 1.8;
}

@media (max-width: 1180px) {
    .cb-hero,
    .cb-workbench {
        grid-template-columns: 1fr;
    }

    .cb-reader-shell {
        position: static;
        min-height: 0;
    }
}

@media (max-width: 840px) {
    .cb-topbar,
    .cb-main {
        width: min(100%, calc(100% - 24px));
    }

    .cb-topbar {
        padding: 16px;
        border-radius: 20px;
        flex-direction: column;
        align-items: stretch;
    }

    .cb-nav {
        justify-content: space-between;
    }

    .cb-hero-copy,
    .cb-stats-panel,
    .cb-search-panel,
    .cb-reader,
    .cb-reader-placeholder {
        padding: 22px;
    }

    .cb-search-row {
        grid-template-columns: 1fr;
    }

    .cb-result-card {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .cb-open-link {
        grid-column: 2;
        width: fit-content;
    }

    .cb-reader-meta-grid,
    .cb-stat-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .cb-hero h1 {
        font-size: 2.5rem;
    }

    .cb-nav {
        gap: 10px;
    }

    .cb-nav a {
        font-size: 0.85rem;
    }

    .cb-toolbar,
    .cb-selection-bar,
    .cb-hero-actions,
    .cb-hero-pills,
    .cb-analysis-quick-prompts,
    .cb-result-kicker,
    .cb-result-meta-row,
    .cb-section-heading-row,
    .cb-reader-header,
    .cb-modal-header,
    .cb-modal-actions {
        flex-direction: column;
        align-items: flex-start;
    }

    .cb-btn,
    .cb-mini-btn,
    .cb-open-link,
    .cb-nav-cta {
        width: 100%;
    }
}