:root {
    --swan-navy: #000f30;
    --swan-navy-soft: #071b46;
    --swan-gold: #d8b35a;
    --swan-cream: #f7f4ee;
    --swan-card: #ffffff;
    --swan-text: #1f2937;
    --swan-muted: #6b7280;
    --swan-border: #e5e7eb;
    --swan-soft-blue: #eef4ff;
    --swan-danger-soft: #fff1f2;
    --swan-danger: #be123c;
    --swan-success-soft: #ecfdf5;
    --swan-success: #047857;
    --swan-shadow: 0 18px 50px rgba(0, 15, 48, 0.12);
}

* {
    box-sizing: border-box;
}

.skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 1000;
    padding: 10px 14px;
    border-radius: 10px;
    background: #ffffff;
    color: var(--swan-navy);
    font-weight: 850;
    text-decoration: none;
    transform: translateY(-160%);
    box-shadow: var(--swan-shadow);
}

.skip-link:focus {
    transform: translateY(0);
}

:where(a, button, input, textarea, select, [tabindex]):focus-visible {
    outline: 3px solid #b7791f;
    outline-offset: 3px;
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

body {
    margin: 0;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--swan-cream);
    color: var(--swan-text);
}

a {
    color: inherit;
    text-decoration: none;
}

.therapist-app {
    min-height: 100vh;
    display: flex;
}

.therapist-sidebar {
    width: 280px;
    background: var(--swan-navy);
    color: #ffffff;
    padding: 28px 22px;
    display: flex;
    flex-direction: column;
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    z-index: 20;
    overflow-y: auto;
}

.therapist-brand,
.auth-brand {
    display: flex;
    align-items: center;
    gap: 14px;
}

.therapist-brand {
    margin-bottom: 14px;
}

.brand-mark {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    background: linear-gradient(135deg, #ffffff, var(--swan-gold));
    color: var(--swan-navy);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 850;
    letter-spacing: 0.03em;
    flex: 0 0 auto;
}

.brand-mark.logo-mark {
    background: #101b2d;
    border: 1px solid rgba(216, 179, 90, 0.34);
    overflow: hidden;
    padding: 0;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
}

.brand-logo-img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.brand-mark.auth-logo-mark {
    width: 58px;
    height: 58px;
    border-radius: 18px;
}

.brand-title {
    font-size: 1.1rem;
    font-weight: 850;
    color: inherit;
}

.brand-subtitle {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.68);
}

.auth-card .brand-subtitle {
    color: var(--swan-muted);
}

.therapist-sidebar-actions {
    display: flex;
    justify-content: flex-start;
    margin: 0 0 22px;
}

.therapist-sidebar-identity {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    margin: 0 0 22px;
    padding: 14px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.07);
}

.therapist-sidebar-identity strong {
    color: #ffffff;
    line-height: 1.35;
}

.therapist-sidebar-identity span {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.8rem;
}

.therapist-sidebar-identity .therapist-identity-label {
    color: var(--swan-gold);
    font-weight: 800;
}

.therapist-logout-form {
    margin-top: 8px;
}

.therapist-logout-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.10);
    border: 1px solid rgba(255, 255, 255, 0.16);
    color: #ffffff;
    font-size: 0.86rem;
    font-weight: 800;
    transition: 0.18s ease;
}

.therapist-logout-button:hover {
    background: rgba(255, 255, 255, 0.18);
}


.therapist-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.therapist-nav a {
    padding: 12px 14px;
    border-radius: 14px;
    color: rgba(255, 255, 255, 0.78);
    font-weight: 650;
    transition: 0.18s ease;
}

.therapist-nav a:hover,
.therapist-nav a.active {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.therapist-nav-legal {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-top: 2px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.therapist-nav .therapist-nav-legal a {
    padding: 8px 14px;
    font-size: 0.8rem;
    font-weight: 650;
}

.therapist-sidebar-footer {
    margin-top: auto;
    padding-top: 24px;
    color: rgba(255, 255, 255, 0.56);
    font-size: 0.74rem;
    line-height: 1.45;
}

.therapist-sidebar-footer a {
    color: rgba(255, 255, 255, 0.68);
    font-weight: 650;
}

.therapist-main {
    margin-left: 280px;
    width: calc(100% - 280px);
    min-height: 100vh;
}

.therapist-topbar {
    background: #ffffff;
    border-bottom: 1px solid var(--swan-border);
    padding: 26px 38px;
    position: sticky;
    top: 0;
    z-index: 15;
}

.therapist-topbar h1 {
    margin: 0;
    color: var(--swan-navy);
    font-size: 1.9rem;
}

.therapist-topbar p {
    margin: 6px 0 0;
    color: var(--swan-muted);
}

.therapist-content {
    padding: 34px 38px 60px;
}

.therapist-mode-banner {
    background: #fff7e0;
    border: 1px solid rgba(216, 179, 90, 0.55);
    color: #5f4500;
    padding: 12px 18px;
    border-radius: 14px;
    margin: 16px;
    font-weight: 750;
}

.page-heading {
    margin-bottom: 24px;
}

.page-heading h2 {
    margin: 0;
    color: var(--swan-navy);
    font-size: 1.7rem;
}

.page-heading p {
    margin: 7px 0 0;
    color: var(--swan-muted);
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 24px;
}

.stat-card {
    background: var(--swan-card);
    border: 1px solid var(--swan-border);
    border-radius: 22px;
    padding: 24px;
    box-shadow: var(--swan-shadow);
}

.stat-card.gold {
    border-color: rgba(216, 179, 90, 0.65);
}

.stat-card.attention {
    background: var(--swan-danger-soft);
    border-color: rgba(190, 18, 60, 0.2);
}

.stat-label {
    color: var(--swan-muted);
    font-size: 0.88rem;
    font-weight: 700;
}

.stat-value {
    margin-top: 10px;
    color: var(--swan-navy);
    font-size: 2.3rem;
    font-weight: 850;
}

.panel-grid,
.snapshot-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.panel {
    background: var(--swan-card);
    border: 1px solid var(--swan-border);
    border-radius: 24px;
    padding: 26px;
    box-shadow: var(--swan-shadow);
}

.panel h3 {
    margin: 0 0 16px;
    color: var(--swan-navy);
}

.panel p {
    line-height: 1.6;
}

.muted,
.small-muted {
    color: var(--swan-muted);
}

.small-muted {
    font-size: 0.86rem;
}

.soft-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.soft-item {
    background: #f8fafc;
    border: 1px solid var(--swan-border);
    border-radius: 16px;
    padding: 13px 14px;
    line-height: 1.45;
}

.soft-item.split {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.soft-item small {
    display: block;
    margin-top: 4px;
    color: var(--swan-muted);
}

.table-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.responsive-table {
    overflow-x: auto;
}

.swan-table {
    width: 100%;
    border-collapse: collapse;
}

.swan-table th,
.swan-table td {
    padding: 14px 12px;
    border-bottom: 1px solid var(--swan-border);
    text-align: left;
    vertical-align: middle;
}

.swan-table th {
    color: var(--swan-navy);
    font-size: 0.86rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    padding: 7px 10px;
    border-radius: 999px;
    background: var(--swan-soft-blue);
    color: var(--swan-navy);
    font-size: 0.82rem;
    font-weight: 750;
}

.status-pill.status-ready {
    background: var(--swan-success-soft);
    color: var(--swan-success);
}

.status-pill.status-core {
    background: rgba(216, 179, 90, 0.16);
    color: #8a6500;
}

.status-pill.status-progress {
    background: var(--swan-soft-blue);
    color: var(--swan-navy);
}

.status-pill.status-pending {
    background: #f1f5f9;
    color: var(--swan-muted);
}

.status-pill.status-not-started {
    background: #f8fafc;
    color: var(--swan-muted);
}

.status-pill.status-archived {
    background: #e2e8f0;
    color: #475569;
}

.table-subtext {
    margin-top: 5px;
    font-size: 0.78rem;
    color: var(--swan-muted);
    line-height: 1.3;
}

.readiness-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 10px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 800;
    white-space: nowrap;
}

.readiness-pill.ready-complete {
    background: var(--swan-success-soft);
    color: var(--swan-success);
}

.readiness-pill.ready-pending {
    background: #f1f5f9;
    color: var(--swan-muted);
}

.table-action {
    display: inline-flex;
    margin-right: 8px;
    margin-bottom: 6px;
    padding: 8px 10px;
    border-radius: 999px;
    background: var(--swan-navy);
    color: #ffffff;
    font-size: 0.82rem;
    font-weight: 750;
    font-family: inherit;
    border: 0;
    cursor: pointer;
}

.table-action.secondary {
    background: #eef2f7;
    color: var(--swan-navy);
}

.table-action.danger {
    background: var(--swan-danger-soft);
    color: var(--swan-danger);
}

.caseload-actions {
    min-width: 250px;
}

.caseload-toolbar h3 {
    margin-bottom: 5px;
}

.caseload-view-switcher {
    display: inline-flex;
    gap: 4px;
    padding: 4px;
    border-radius: 999px;
    background: #eef2f7;
}

.caseload-view-button {
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--swan-navy);
    padding: 9px 14px;
    font: inherit;
    font-size: 0.86rem;
    font-weight: 800;
    cursor: pointer;
}

.caseload-view-button.active {
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 15, 48, 0.12);
}

.caseload-search {
    margin-bottom: 18px;
}

.caseload-search > label {
    margin-top: 0;
}

.caseload-search-controls {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) auto auto;
    gap: 10px;
    align-items: center;
}

.couple-name-card h3 {
    margin: 0;
}

.button-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: var(--swan-navy);
    color: #ffffff;
    padding: 12px 18px;
    font-weight: 800;
    cursor: pointer;
}

.button-primary:hover,
.table-action:hover {
    filter: brightness(1.08);
}

form label {
    display: block;
    margin: 14px 0 7px;
    color: var(--swan-navy);
    font-weight: 750;
}

input,
select,
textarea {
    width: 100%;
    border: 1px solid var(--swan-border);
    border-radius: 14px;
    padding: 12px 13px;
    font: inherit;
    background: #ffffff;
    color: var(--swan-text);
}

textarea {
    resize: vertical;
}

.save-status {
    margin-top: 14px;
    font-weight: 750;
}

.save-status.success {
    color: var(--swan-success);
}

.save-status.error {
    color: var(--swan-danger);
}

.notes-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.note-card {
    background: #f8fafc;
    border: 1px solid var(--swan-border);
    border-radius: 18px;
    padding: 16px;
}

.note-card h4 {
    margin: 8px 0;
    color: var(--swan-navy);
}

.note-card p {
    white-space: pre-wrap;
    margin-bottom: 0;
}

.note-meta {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    color: var(--swan-muted);
    font-size: 0.82rem;
    text-transform: capitalize;
}

.report-library-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.report-card {
    border: 1px solid var(--swan-border);
    border-radius: 20px;
    padding: 20px;
    background: #f8fafc;
}

.report-card h4 {
    margin: 0 0 8px;
    color: var(--swan-navy);
}

.report-card p {
    margin: 0;
    color: var(--swan-muted);
}

.therapist-report-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.therapist-report-card {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    border: 1px solid var(--swan-border);
    border-radius: 20px;
    padding: 18px;
    background: #f8fafc;
}

.therapist-report-card.available {
    background: #ffffff;
}

.therapist-report-card.pending {
    opacity: 0.78;
}

.report-order {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: var(--swan-navy);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 850;
    font-size: 0.9rem;
}

.report-title-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.report-title-row h4 {
    margin: 0;
    color: var(--swan-navy);
    font-size: 1rem;
}

.report-main p {
    margin: 7px 0 0;
    color: var(--swan-muted);
    line-height: 1.5;
}

.report-action {
    display: flex;
    justify-content: flex-end;
}

.report-unavailable {
    color: var(--swan-muted);
    font-size: 0.84rem;
    font-weight: 750;
}

.therapist-live-report {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.therapist-report-section-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    margin-top: 14px;
}

.insight-text-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.insight-text-item {
    border-top: 1px solid var(--swan-border);
    padding-top: 12px;
}

.insight-text-item:first-child {
    border-top: 0;
    padding-top: 0;
}

.insight-text-item h4 {
    margin: 0 0 6px;
    color: var(--swan-navy);
    font-size: 0.96rem;
}

.insight-text-item p {
    margin: 0;
    color: var(--swan-muted);
    line-height: 1.55;
}

@media (max-width: 980px) {
    .therapist-report-section-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .therapist-report-card {
        grid-template-columns: 1fr;
        align-items: flex-start;
    }

    .report-action {
        justify-content: flex-start;
    }
}

.therapist-auth-page {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(216, 179, 90, 0.18), transparent 34%),
        linear-gradient(135deg, var(--swan-navy), #071b46);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px;
}

.auth-card {
    width: 100%;
    max-width: 460px;
    background: #ffffff;
    border-radius: 28px;
    padding: 34px;
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.26);
}

.auth-card.wide {
    max-width: 680px;
}

.auth-brand {
    margin-bottom: 24px;
}

.auth-card h1 {
    color: var(--swan-navy);
    margin: 0 0 8px;
}

.auth-error,
.auth-success {
    border-radius: 16px;
    padding: 13px 14px;
    margin: 18px 0;
    font-weight: 700;
}

.auth-error {
    background: var(--swan-danger-soft);
    color: var(--swan-danger);
    border: 1px solid rgba(190, 18, 60, 0.22);
}

.auth-success {
    background: var(--swan-success-soft);
    color: var(--swan-success);
    border: 1px solid rgba(4, 120, 87, 0.22);
}

.auth-button {
    width: 100%;
    margin-top: 22px;
}

.auth-footer {
    margin: 22px 0 0;
    color: var(--swan-muted);
    text-align: center;
}

.auth-footer a {
    color: var(--swan-navy);
    font-weight: 800;
}

.form-two-column {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

@media (max-width: 980px) {
    .therapist-sidebar {
        position: relative;
        width: 100%;
        min-height: auto;
        bottom: auto;
    }

    .therapist-app {
        flex-direction: column;
    }

    .therapist-main {
        margin-left: 0;
        width: 100%;
    }

    .stat-grid,
    .panel-grid,
    .snapshot-grid,
    .report-library-grid {
        grid-template-columns: 1fr;
    }

    .therapist-content,
    .therapist-topbar {
        padding-left: 22px;
        padding-right: 22px;
    }
}

.snapshot-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 22px;
    border-color: rgba(216, 179, 90, 0.55);
}

.eyebrow {
    color: var(--swan-gold);
    font-size: 0.78rem;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 7px;
}

.snapshot-hero h3 {
    font-size: 1.55rem;
    margin-bottom: 8px;
}

.snapshot-status-wrap {
    flex: 0 0 auto;
}

.wide-panel {
    grid-column: 1 / -1;
}

.insight-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.insight-card {
    border: 1px solid var(--swan-border);
    border-radius: 18px;
    padding: 16px;
    background: #f8fafc;
}

.insight-card h4 {
    margin: 0 0 7px;
    color: var(--swan-navy);
    font-size: 1rem;
}

.insight-card p {
    margin: 0;
    color: var(--swan-muted);
    line-height: 1.55;
}

.insight-card.insight-strong {
    background: var(--swan-success-soft);
    border-color: rgba(4, 120, 87, 0.22);
}

.insight-card.insight-caution {
    background: var(--swan-danger-soft);
    border-color: rgba(190, 18, 60, 0.2);
}

.insight-card.insight-neutral {
    background: #f8fafc;
}

.snapshot-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 22px;
}

.button-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--swan-border);
    border-radius: 999px;
    background: #ffffff;
    color: var(--swan-navy);
    padding: 12px 18px;
    font-weight: 800;
    cursor: pointer;
}

@media (max-width: 760px) {
    .caseload-toolbar,
    .caseload-search-controls {
        align-items: stretch;
        grid-template-columns: 1fr;
        flex-direction: column;
    }

    .caseload-view-switcher {
        align-self: flex-start;
    }

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

@media (max-width: 640px) {
    .form-two-column {
        grid-template-columns: 1fr;
    }

    .auth-card {
        padding: 26px;
        border-radius: 24px;
    }

    .soft-item.split {
        align-items: flex-start;
        flex-direction: column;
    }
}

.report-workspace {
    align-items: start;
    margin-top: 22px;
}

.report-content-panel {
    min-height: 420px;
}

.report-notes-panel {
    position: static;
}

.soft-divider {
    border: 0;
    border-top: 1px solid var(--swan-border);
    margin: 24px 0;
}

.note-context {
    margin-top: 7px;
    color: var(--swan-muted);
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: capitalize;
}

@media (min-width: 981px) {
    .report-workspace {
        height: calc(100vh - 300px);
        min-height: 480px;
    }

    .report-content-panel,
    .report-notes-panel {
        height: 100%;
        overflow-y: auto;
        overscroll-behavior: contain;
        scrollbar-gutter: stable;
    }

    .session-notes-workspace {
        align-items: start;
    }

    .session-note-editor {
        position: sticky;
        top: 116px;
    }

    .session-note-history .notes-list {
        max-height: calc(100vh - 300px);
        overflow-y: auto;
        overscroll-behavior: contain;
        scrollbar-gutter: stable;
        padding-right: 6px;
    }
}
/* Therapist home triage refinements */
.stat-grid.stat-grid-three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stat-detail {
    margin-top: 8px;
    color: var(--swan-muted);
    font-size: 0.84rem;
    line-height: 1.45;
}

.panel-heading-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.panel-heading-row h3 {
    margin-bottom: 6px;
}

.panel-heading-row p {
    margin: 0;
}

.needs-attention-panel {
    border-color: rgba(216, 179, 90, 0.42);
}

.triage-list {
    gap: 12px;
}

.attention-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
}

.attention-item.attention-caution {
    background: #fff7e0;
    border-color: rgba(216, 179, 90, 0.5);
}

.attention-item.attention-neutral {
    background: #f8fafc;
}

.attention-main strong {
    color: var(--swan-navy);
}

.attention-main p,
.attention-empty p {
    margin: 6px 0 0;
    color: var(--swan-muted);
    line-height: 1.5;
}

.attention-couple {
    margin-bottom: 5px;
    color: var(--swan-gold);
    font-size: 0.78rem;
    font-weight: 850;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.attention-action {
    margin: 0;
    white-space: nowrap;
}

@media (max-width: 980px) {
    .stat-grid.stat-grid-three {
        grid-template-columns: 1fr;
    }

    .attention-item,
    .panel-heading-row {
        grid-template-columns: 1fr;
        flex-direction: column;
        align-items: flex-start;
    }
}


.page-top-actions {
    margin: -6px 0 22px;
}

.page-top-actions + .panel,
.page-top-actions + input + .snapshot-hero {
    margin-top: 0;
}

.couple-access-panel {
    margin-bottom: 22px;
    border-color: rgba(216, 179, 90, 0.34);
}

.couple-access-request-history {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--swan-border);
}

.couple-access-request-history h4 {
    margin: 0 0 12px;
    color: var(--swan-navy);
}

.couple-access-request-state {
    display: flex;
    align-items: flex-end;
    flex-direction: column;
    gap: 5px;
    text-align: right;
}

.status-approved {
    background: var(--swan-success-soft);
    color: var(--swan-success);
}

.status-declined,
.status-revoked {
    background: var(--swan-danger-soft);
    color: var(--swan-danger);
}

.note-form-actions,
.note-card-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.note-card-actions {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--swan-border);
}

.snapshot-activity-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.snapshot-activity-heading h3,
.snapshot-activity-heading p {
    margin-bottom: 0;
}

@media (max-width: 640px) {
    .couple-access-request-state {
        align-items: flex-start;
        text-align: left;
    }

    .snapshot-activity-heading {
        align-items: flex-start;
        flex-direction: column;
    }
}


/* Account and Support page scaffolding */
.settings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.settings-panel-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.settings-panel-heading h3 {
    margin-bottom: 0;
}

.settings-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 14px 0;
}

.settings-row {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    padding: 12px 0;
    border-bottom: 1px solid var(--swan-border);
}

.settings-row:last-child {
    border-bottom: 0;
}

.settings-row span {
    color: var(--swan-muted);
    font-weight: 700;
}

.settings-row strong {
    color: var(--swan-navy);
    text-align: right;
}

.settings-row.muted-row strong {
    color: var(--swan-muted);
}

.settings-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

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

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

.support-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    margin-bottom: 22px;
    border-color: rgba(216, 179, 90, 0.5);
}

.support-hero h3 {
    margin-bottom: 8px;
}

.support-urgent-notice,
.support-alert {
    margin-bottom: 22px;
    padding: 18px 20px;
}

.support-urgent-notice {
    border-color: rgba(216, 179, 90, 0.6);
    background: #fffaf0;
}

.support-urgent-notice p,
.support-alert p {
    margin: 6px 0 0;
}

.support-urgent-notice a,
.support-privacy-note a {
    color: #174ea6;
    font-weight: 800;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.support-alert {
    border: 1px solid var(--swan-border);
    border-radius: 16px;
}

.support-alert-success {
    color: var(--swan-success);
    border-color: rgba(4, 120, 87, 0.32);
    background: var(--swan-success-soft);
}

.support-alert-error {
    color: var(--swan-danger);
    border-color: rgba(190, 18, 60, 0.28);
    background: var(--swan-danger-soft);
}

.support-alert ul {
    margin: 8px 0 0;
    padding-left: 22px;
}

.support-reference {
    font-weight: 900;
    letter-spacing: 0.04em;
}

.support-request-panel {
    margin-bottom: 22px;
    border-color: rgba(0, 15, 48, 0.2);
}

.support-account-identity {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 8px 18px;
    margin: 18px 0;
    padding: 14px 16px;
    border: 1px solid var(--swan-border);
    border-radius: 14px;
    background: #f8fafc;
}

.support-account-identity span {
    color: var(--swan-muted);
    font-weight: 700;
}

.support-request-form {
    display: grid;
    gap: 18px;
}

.support-form-field {
    display: grid;
    gap: 7px;
}

.support-form-field label {
    color: var(--swan-navy);
    font-weight: 850;
}

.support-form-field select,
.support-form-field textarea {
    width: 100%;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    background: #ffffff;
    color: var(--swan-text);
    padding: 12px 13px;
    font: inherit;
}

.support-form-field textarea {
    min-height: 180px;
    resize: vertical;
}

.support-form-field select:focus-visible,
.support-form-field textarea:focus-visible,
.support-request-form .button-primary:focus-visible,
.support-hero .button-primary:focus-visible {
    outline: 3px solid #b7791f;
    outline-offset: 3px;
}

.support-field-hint,
.support-privacy-note {
    color: var(--swan-muted);
    font-size: 0.93rem;
    line-height: 1.5;
}

.support-privacy-note {
    margin: 0;
}

.support-honeypot {
    position: absolute !important;
    left: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

.support-link-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 16px;
}

.support-link {
    width: 100%;
    text-align: left;
    border: 1px solid var(--swan-border);
    border-radius: 14px;
    background: #f8fafc;
    color: var(--swan-navy);
    padding: 12px 14px;
    font: inherit;
    font-weight: 800;
}

.support-link:not(.disabled-button):hover {
    background: #eef2f7;
}

.report-guide-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
}

.report-guide-list div {
    border: 1px solid var(--swan-border);
    border-radius: 14px;
    background: #f8fafc;
    padding: 13px 14px;
}

.report-guide-list strong {
    display: block;
    color: var(--swan-navy);
    margin-bottom: 4px;
}

.report-guide-list span {
    display: block;
    color: var(--swan-muted);
    line-height: 1.45;
}

.caution-panel {
    border-color: rgba(216, 179, 90, 0.55);
}

.support-caution-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 18px;
}

.support-caution-grid p {
    margin: 6px 0 0;
    color: var(--swan-muted);
}

/* Batch 8 therapist resource center and complete guides */
.guide-resource-hero .button-primary,
.guide-support-callout .button-secondary {
    flex: 0 0 auto;
}

.faq-panel {
    margin-bottom: 30px;
}

.faq-heading,
.guide-library-heading,
.guide-support-callout,
.guide-finish {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 22px;
}

.faq-heading h3,
.guide-library-heading h3,
.guide-support-callout h3,
.guide-finish h3 {
    margin: 4px 0 0;
}

.faq-search {
    display: grid;
    gap: 8px;
    margin: 22px 0 18px;
    padding: 18px;
    border: 1px solid var(--swan-border);
    border-radius: 18px;
    background: #f8fafc;
}

.faq-search label {
    color: var(--swan-navy);
    font-weight: 850;
}

.faq-search-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.faq-search-control input {
    min-width: 0;
    flex: 1;
    border: 1px solid #cbd5e1;
    border-radius: 13px;
    background: #ffffff;
    color: var(--swan-text);
    padding: 13px 14px;
    font: inherit;
}

.faq-search-status {
    min-height: 1.4em;
    margin: 0;
    color: var(--swan-muted);
    font-size: 0.9rem;
}

.faq-list {
    display: grid;
    gap: 10px;
}

.faq-item {
    overflow: hidden;
    border: 1px solid var(--swan-border);
    border-radius: 16px;
    background: #ffffff;
}

.faq-item summary {
    position: relative;
    padding: 17px 50px 17px 18px;
    color: var(--swan-navy);
    cursor: pointer;
    font-weight: 850;
    line-height: 1.4;
    list-style: none;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: '+';
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #8a6513;
    font-size: 1.45rem;
    font-weight: 700;
}

.faq-item[open] summary::after {
    content: '−';
}

.faq-item[open] summary {
    background: #f8fafc;
}

.faq-answer {
    padding: 0 18px 17px;
    border-top: 1px solid var(--swan-border);
}

.faq-answer p {
    margin: 14px 0 0;
    color: var(--swan-muted);
}

.faq-empty {
    padding: 22px;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    background: #f8fafc;
    text-align: center;
}

.faq-empty strong {
    color: var(--swan-navy);
}

.faq-empty p {
    margin: 6px 0 0;
    color: var(--swan-muted);
}

.guide-library {
    margin: 36px 0 30px;
}

.guide-library-heading {
    margin-bottom: 18px;
}

.guide-library-heading p {
    max-width: 460px;
    margin: 0;
    color: var(--swan-muted);
    line-height: 1.55;
    text-align: right;
}

.guide-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.guide-card {
    display: flex;
    align-items: flex-start;
    flex-direction: column;
    min-height: 100%;
    border-color: rgba(0, 15, 48, 0.16);
}

.guide-card-icon,
.guide-section-number {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(216, 179, 90, 0.52);
    border-radius: 14px;
    background: #fff8e7;
    color: #73520a;
    font-weight: 900;
}

.guide-card .eyebrow {
    margin-top: 18px;
}

.guide-card h3 {
    margin: 7px 0 10px;
}

.guide-card p,
.guide-card li {
    color: var(--swan-muted);
    line-height: 1.55;
}

.guide-card ul {
    margin: 2px 0 20px;
    padding-left: 20px;
}

.guide-card li + li {
    margin-top: 6px;
}

.guide-card .button-primary {
    margin-top: auto;
}

.guide-support-callout {
    align-items: center;
    border-color: rgba(216, 179, 90, 0.5);
    background: #fffaf0;
}

.guide-support-callout p,
.guide-finish p {
    margin: 8px 0 0;
    color: var(--swan-muted);
}

.guide-detail-heading {
    max-width: 880px;
    margin-bottom: 24px;
}

.guide-back-link {
    display: inline-flex;
    margin-bottom: 20px;
    color: #174ea6;
    font-weight: 800;
}

.guide-detail-heading h2 {
    margin: 7px 0 9px;
    color: var(--swan-navy);
    font-size: clamp(1.8rem, 4vw, 2.7rem);
    line-height: 1.12;
}

.guide-detail-heading p {
    margin: 0;
    color: var(--swan-muted);
    font-size: 1.02rem;
    line-height: 1.65;
}

.guide-detail-layout {
    display: grid;
    grid-template-columns: minmax(210px, 250px) minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.guide-toc {
    position: sticky;
    top: 116px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 18px;
}

.guide-toc strong {
    margin: 0 8px 8px;
    color: var(--swan-navy);
}

.guide-toc a {
    padding: 9px 8px;
    border-radius: 9px;
    color: var(--swan-muted);
    font-size: 0.9rem;
    font-weight: 700;
}

.guide-toc a:hover {
    background: var(--swan-soft-blue);
    color: var(--swan-navy);
}

.guide-article {
    display: grid;
    gap: 18px;
}

.guide-section {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 18px;
    scroll-margin-top: 118px;
}

.guide-section h3 {
    margin: 3px 0 8px;
}

.guide-section p,
.guide-section li {
    color: var(--swan-muted);
    line-height: 1.62;
}

.guide-section p {
    margin: 8px 0 0;
}

.guide-section ul,
.guide-section ol {
    margin: 12px 0 0;
    padding-left: 21px;
}

.guide-section li + li {
    margin-top: 7px;
}

.guide-section .button-secondary {
    margin-top: 15px;
}

.guide-callout {
    margin-top: 16px;
    padding: 15px 16px;
    border: 1px solid rgba(4, 120, 87, 0.24);
    border-radius: 14px;
    background: var(--swan-success-soft);
}

.guide-callout.caution {
    border-color: rgba(216, 179, 90, 0.5);
    background: #fffaf0;
}

.guide-callout strong {
    color: var(--swan-navy);
}

.guide-callout p {
    margin-top: 5px;
}

.report-purpose-grid,
.guide-pattern-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 11px;
    margin-top: 16px;
}

.report-purpose-grid > div,
.guide-pattern-list > div {
    padding: 14px;
    border: 1px solid var(--swan-border);
    border-radius: 14px;
    background: #f8fafc;
}

.report-purpose-grid strong,
.guide-pattern-list strong {
    color: var(--swan-navy);
}

.report-purpose-grid p,
.guide-pattern-list p {
    margin-top: 5px;
}

.guide-language-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.guide-language-grid > div {
    padding: 16px;
    border: 1px solid var(--swan-border);
    border-radius: 14px;
}

.guide-language-use {
    background: var(--swan-success-soft);
}

.guide-language-avoid {
    background: var(--swan-danger-soft);
}

.guide-language-grid p {
    margin-top: 7px;
}

.guide-session-map {
    display: grid;
    gap: 9px;
}

.guide-session-map li {
    padding-left: 5px;
}

.guide-finish {
    align-items: center;
    border-color: rgba(216, 179, 90, 0.55);
}

.guide-finish .button-primary {
    flex: 0 0 auto;
}

@media (max-width: 980px) {
    .settings-grid,
    .support-caution-grid {
        grid-template-columns: 1fr;
    }

    .support-hero,
    .support-account-identity,
    .settings-panel-heading,
    .settings-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .settings-row strong {
        text-align: left;
    }

    .faq-heading,
    .guide-library-heading,
    .guide-support-callout,
    .guide-finish {
        flex-direction: column;
        align-items: flex-start;
    }

    .guide-library-heading p {
        max-width: none;
        text-align: left;
    }

    .guide-card-grid,
    .guide-detail-layout {
        grid-template-columns: 1fr;
    }

    .guide-toc {
        position: static;
    }
}

@media (max-width: 640px) {
    .faq-search-control,
    .guide-section {
        align-items: stretch;
        grid-template-columns: 1fr;
    }

    .faq-search-control {
        display: grid;
    }

    .guide-section-number {
        width: 38px;
        height: 38px;
    }

    .report-purpose-grid,
    .guide-pattern-list,
    .guide-language-grid {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
