/* Shared action/information hierarchy. Screen only: clinical printouts stay unchanged. */
@media screen {
    :root {
        --ui-action-focus: #4338ca;
        --ui-info-line: var(--line, var(--website-line, #d8e0e9));
        --ui-info-text: var(--text, var(--website-navy, #18343d));
    }

    html[data-theme="dark"] { --ui-action-focus: #a5b4fc; }

    /* Preserve semantic button colors, dimensions, disabled states and group seams. */
    html body :is(.btn, .website-btn):not(.rounded-circle) {
        border-radius: 8px;
        box-shadow: none;
    }

    html body .btn-primary {
        background-image: none;
        background-color: var(--portal-primary, var(--primary, #4f46e5));
    }

    html body .website-btn-primary {
        background: #087e83;
        color: #fff;
    }

    html body .website-btn-primary:hover { background: #06686d; }
    html body .website-btn-outline { border-color: currentColor; }

    /* The language link shares the legacy class; only customer login is an action button. */
    html body.website-body .website-nav-actions .website-nav-login:not([hreflang]) {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 34px;
        padding: 0 11px;
        border: 1px solid #6d8699;
        border-radius: 8px;
        background: #e9f1f7;
        color: #12324b;
        font-size: .74rem;
        font-weight: 800;
        text-decoration: none;
        cursor: pointer;
        transition: background-color .15s ease, border-color .15s ease;
    }
    html body.website-body .website-nav-actions .website-nav-login:not([hreflang]):hover {
        background: #dbe8f1;
        border-color: #12324b;
    }
    html body.website-body .website-nav-actions .website-nav-login:not([hreflang]):focus-visible {
        outline: 3px solid var(--ui-action-focus);
        outline-offset: 3px;
    }

    html body :is(.btn, .website-btn):not(:disabled):not(.disabled):not([aria-disabled="true"]) {
        cursor: pointer;
    }

    html body :is(.btn, .website-btn):focus-visible {
        outline: 3px solid var(--ui-action-focus);
        outline-offset: 3px;
    }

    html body .btn-group > .btn:not(:first-child):not(:last-child) { border-radius: 0; }
    html body .btn-group > .btn:first-child:not(:last-child) {
        border-start-end-radius: 0;
        border-end-end-radius: 0;
    }
    html body .btn-group > .btn:last-child:not(:first-child) {
        border-start-start-radius: 0;
        border-end-start-radius: 0;
    }

    /* Large content surfaces still group forms and tables, without button-like shadows. */
    html body :is(.glass-card, .glass-subtle, .section-card, .form-card,
        .website-panel, .website-feature-card, .website-pricing-card,
        .website-showcase-card, .website-login-card):not(a, button, [role], [onclick], [tabindex], .btn, .modal-content, .sidebar) {
        border-radius: 12px;
        box-shadow: none;
    }

    /* Read-only totals and facts have a side rule, not an enclosing control outline. */
    html body :is(.stat-card, .chart-summary-card, .document-summary-card,
        .specialty-metric-card, .specialty-stat, .revenue-copilot-metric,
        .future-plan-summary-card, .clinical-resource-summary__item,
        .detail-box, .portal-detail-item, .portal-money-row,
        .website-showcase-stat, .website-proof-item):not(a, button, [role], [onclick], [tabindex], [data-bs-toggle], .btn) {
        background: transparent;
        border: 0;
        border-inline-start: 2px solid var(--ui-info-line);
        border-radius: 0;
        box-shadow: none;
    }

    html body .chart-summary-card.chart-summary-accent:not(a, button, [role], [onclick], [tabindex]) {
        color: var(--ui-info-text);
        border-inline-start-color: var(--ui-action-focus);
    }
    html body .chart-summary-card.chart-summary-accent :is(span, strong) { color: inherit; }
    html body .future-plan-summary-card > :is(span, small) { color: var(--muted, #64748b); }

    html body :is(.stat-card, .document-summary-card) .stat-icon,
    html body .chart-summary-card > i {
        background: none;
        color: var(--ui-action-focus);
        border-radius: 0;
        box-shadow: none;
    }

    /* State labels retain their clinical/financial colors; interactive chips are excluded. */
    html body :is(span, small, div):is(.badge, .badge-soft, .status-pill, .consent-status,
        .task-pill, .risk-pill, .story-type-pill, .consent-scope-badge,
        .clinical-resource-status, .clinical-resource-type-badge, .appointment-resource-status,
        .website-mini-pill, .website-plan-badge, .intake-badge):not([role], [onclick], [tabindex], [data-bs-toggle], .btn) {
        border-radius: 3px;
        box-shadow: none;
        align-self: center;
    }

    html body :is(span, small, div):is(.status-pill, .consent-status, .badge-soft):not([role], [onclick], [tabindex], [data-bs-toggle], .btn) {
        padding: .18rem .45rem;
    }

    html[data-theme="dark"] body .status-pill:is(.confirmed, .done, .paid, .accepted) { color: #6ee7b7; }
    html[data-theme="dark"] body .status-pill:is(.pending, .planned, .unpaid) { color: #fcd34d; }
    html[data-theme="dark"] body .status-pill:is(.completed, .partiallypaid, .inprogress, .in-progress, .submitted) { color: #7dd3fc; }
    html[data-theme="dark"] body .status-pill:is(.cancelled, .noshow, .rejected, .failed) { color: #fda4af; }
    html[data-theme="dark"] body .status-pill.draft { color: #cbd5e1; }

    html[data-theme="dark"] body .btn-outline-danger {
        --bs-btn-color: #fda4af;
        --bs-btn-border-color: #fda4af;
        --bs-btn-hover-color: #07111f;
        --bs-btn-hover-bg: #fda4af;
        --bs-btn-hover-border-color: #fda4af;
        --bs-btn-active-color: #07111f;
        --bs-btn-active-bg: #fda4af;
        --bs-btn-active-border-color: #fda4af;
        --bs-btn-disabled-color: #fda4af;
        --bs-btn-disabled-border-color: #fda4af;
    }

    html body .consent-summary-card {
        border-radius: 0;
        box-shadow: none;
    }

    html body :is(.feature-line, .auth-helper-pill, .portal-note-box, .portal-lab-card):not(a, button, [role], [onclick], [tabindex]) {
        background: transparent;
        border: 0;
        border-block-end: 1px solid var(--ui-info-line);
        border-radius: 0;
        box-shadow: none;
    }

    html body .auth-kicker {
        padding-inline: 0;
        border: 0;
        border-radius: 0;
        background: none;
        box-shadow: none;
    }

    /* The same distinction applies to public pages beyond the free-trial page. */
    html body.website-body .website-kicker {
        padding-inline: 0;
        border: 0;
        border-radius: 0;
        background: none;
        box-shadow: none;
    }

    html body.website-body :is(.website-training-card, .website-security-card,
        .website-proof-card, .website-testimonial-card, .website-timeline-item):not(a, button, [role], [onclick], [tabindex]) {
        background: transparent;
        border: 0;
        border-block-start: 1px solid var(--ui-info-line);
        border-radius: 0;
        box-shadow: none;
    }

    html body.website-body :is(.website-training-card, .website-security-card,
        .website-feature-card, .website-timeline-item) > i {
        background: none;
        border-radius: 0;
    }

    html body.website-body :is(.website-hero-flow-steps, .website-trust-strip,
        .website-video-consultation-benefits, .website-ai-feature-metrics) > span {
        background: transparent;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    /* Contact information is editorial; only form controls and links look actionable. */
    html body.website-body .website-contact-hero { padding-top: 18px; }
    html body.website-body .website-contact-main-grid {
        max-width: 920px;
        align-items: start;
        justify-content: center;
        gap: 20px;
    }
    @media (min-width: 992px) {
        html body.website-body .website-contact-main-grid {
            grid-template-columns: minmax(0, 560px) minmax(0, 300px);
        }
    }

    html body.website-body .website-contact-form-card {
        width: 100%;
        max-width: 560px;
        justify-self: center;
        padding: 18px;
        border-radius: 12px;
        background: rgba(255, 255, 255, .92);
        box-shadow: none;
    }
    html body.website-body .website-contact-form-heading {
        text-align: start;
        margin-bottom: 12px;
    }
    html body.website-body .website-contact-form-heading h1 {
        margin: 4px 0 6px;
        font-size: 20px;
        line-height: 1.5;
    }
    html body.website-body .website-contact-form-heading .website-mini-pill {
        padding: 0;
        border: 0;
        background: none;
    }
    html body.website-body .website-contact-hero :is(p, label, input, textarea, select),
    html body.website-body .website-contact-info-fill,
    html body.website-body .website-contact-support-grid :is(p, strong) {
        font-size: 14px;
        line-height: 1.7;
    }
    html body.website-body .website-contact-form-card .website-form-stack { margin-top: 0; gap: 10px; }
    html body.website-body .website-contact-form-grid { gap: 10px 12px; }
    html body.website-body .website-contact-form-card .phone-input-control {
        grid-template-columns: minmax(108px, 42%) minmax(0, 1fr);
    }
    html body.website-body .website-contact-form-card .phone-input-country {
        width: 100%;
        min-width: 0;
        max-width: none;
    }
    html body.website-body .website-contact-form-card .website-field { gap: 4px; }
    html body.website-body .website-contact-form-card label { margin-bottom: 0; }
    html body.website-body .website-contact-hero :is(input.form-control, select) {
        min-height: 36px;
        padding-block: 5px;
    }
    html body.website-body .website-contact-hero .form-control { border-radius: 6px; }
    html body.website-body .website-contact-form-card textarea.form-control {
        height: 80px;
        min-height: 80px;
        padding: 7px 10px;
        resize: vertical;
    }
    html body.website-body .website-contact-hero button[type="submit"] {
        width: auto !important;
        justify-self: start;
        min-height: 38px;
        padding: 6px 16px;
        font-size: 14px;
    }
    html body.website-body .website-contact-card,
    html body.website-body .website-contact-info-fill > div,
    html body.website-body .website-contact-support-grid .website-panel {
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
    }
    html body.website-body .website-contact-card { padding: 16px; }
    html body.website-body .website-contact-card-head { gap: 10px; margin-bottom: 16px; }
    html body.website-body .website-contact-card-head strong,
    html body.website-body .website-contact-support-grid h2 { font-size: 17px; }
    html body.website-body .website-contact-info-fill { margin-top: 0; padding-top: 0; gap: 0; }
    html body.website-body .website-contact-info-fill > div {
        grid-template-columns: 28px minmax(0, 1fr);
        padding: 14px 0;
        border-block-end: 1px solid var(--ui-info-line);
    }
    html body.website-body .website-contact-card-head > span,
    html body.website-body .website-contact-info-fill i,
    html body.website-body .website-contact-support-grid .website-panel > i {
        width: 28px;
        height: 28px;
        flex: 0 0 28px;
        font-size: 20px;
        color: var(--website-primary-dark);
        background: none;
        border-radius: 0;
        box-shadow: none;
    }
    html body.website-body .website-contact-info-fill .website-contact-note :is(strong, p),
    html body.website-body .website-contact-support-grid .website-panel-quote :is(strong, p) {
        color: var(--website-navy);
    }
    html body.website-body .website-contact-support-grid .website-panel {
        padding: 20px 0;
        border-block-start: 1px solid var(--ui-info-line);
        gap: 10px;
    }
    html body.website-body .website-contact-support-grid .website-btn {
        align-self: start;
        border: 1px solid currentColor;
        background: transparent;
        color: var(--website-primary-dark);
    }
    @media (max-width: 767px) {
        html body.website-body .website-contact-form-card { padding: 14px; }
        html body.website-body .website-contact-form-heading h1 { font-size: 20px; }
        html body.website-body .website-contact-card { padding: 12px 0; }
    }

    /* Real linked cards keep a visible action boundary and keyboard focus. */
    html body a:is(.glass-card, .stat-card, .chart-summary-card, .portal-link-card,
        .website-feature-card, .website-training-card) {
        border: 1px solid var(--ui-action-focus);
        border-radius: 8px;
        cursor: pointer;
    }
    html body a:is(.glass-card, .stat-card, .chart-summary-card, .portal-link-card,
        .website-feature-card, .website-training-card):focus-visible {
        outline: 3px solid var(--ui-action-focus);
        outline-offset: 3px;
    }
}
