/* Shared UI finish, loaded after page styles. Theme colors remain authoritative. */
:root {
    --app-shadow: 0 1px 4px rgba(15, 23, 42, 0.07);
    --app-elevated-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
    --app-radius: 10px;
}

body {
    background: var(--app-bg-a, #f3f6fb) !important;
}

body:is(.shopping-history-page, .reserved-list-page, .stuff-passport-page,
    .shop-page, .item-add-page, .profile-page)::before {
    display: none;
}

/* Page introductions share a modest heading and a simple divider. */
body :is(
    .dashboard-hero, .shop-page-hero, .events-hero, .profile-hero, .settings-topbar,
    .registries-hero, .item-add-hero, .categories-hero, .users-hero,
    .faq-hero, .llm-access-hero, .domain-intel-hero, .reserved-list-hero,
    .shopping-history-hero, .shopping-overview, .stuff-hero, .guest-hero,
    .invite-hero, .forgot-hero, .rank-icon-preview-hero
) {
    min-height: 0 !important;
    min-block-size: 0 !important;
    margin-block: 0 18px;
    padding: 14px 0 18px !important;
    border: 0 !important;
    border-bottom: 1px solid var(--app-border) !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: var(--app-text) !important;
    box-shadow: none !important;
    overflow: visible;
}

body :is(
    .dashboard-hero, .shop-page-hero, .events-hero, .profile-hero,
    .registries-hero, .item-add-hero, .categories-hero, .users-hero,
    .faq-hero, .llm-access-hero, .domain-intel-hero, .reserved-list-hero,
    .shopping-history-hero, .shopping-overview, .stuff-hero, .guest-hero
)::before,
body :is(
    .dashboard-hero, .shop-page-hero, .events-hero, .profile-hero,
    .registries-hero, .item-add-hero, .categories-hero, .users-hero,
    .faq-hero, .llm-access-hero, .domain-intel-hero, .reserved-list-hero,
    .shopping-history-hero, .shopping-overview, .stuff-hero, .guest-hero
)::after {
    display: none !important;
}

body :is(
    .dashboard-hero, .shop-page-hero, .events-hero, .profile-hero,
    .registries-hero, .item-add-hero, .categories-hero, .users-hero,
    .faq-hero, .llm-access-hero, .domain-intel-hero, .reserved-list-hero,
    .shopping-history-hero, .shopping-overview, .stuff-hero, .guest-hero,
    .invite-hero, .forgot-hero, .rank-icon-preview-hero
) h1 {
    max-width: none;
    max-inline-size: none;
    margin: 0 0 6px;
    color: var(--app-title-text) !important;
    font-size: clamp(1.5rem, 2.4vw, 1.875rem) !important;
    font-weight: 650;
    line-height: 1.25 !important;
    letter-spacing: -0.025em;
    text-wrap: balance;
}

body :is(
    .dashboard-hero, .shop-page-hero, .events-hero, .profile-hero,
    .registries-hero, .item-add-hero, .categories-hero, .users-hero,
    .faq-hero, .llm-access-hero, .domain-intel-hero, .reserved-list-hero,
    .shopping-history-hero, .shopping-overview, .stuff-hero, .guest-hero,
    .invite-hero, .forgot-hero
) p {
    margin-block: 4px 0;
    color: var(--app-muted) !important;
    font-size: 0.875rem !important;
    font-weight: 400;
    line-height: 1.55;
}

body .stuff-hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
}

.stuff-hero > [aria-hidden="true"] {
    display: none;
}

body :is(.stuff-kicker, .shopfor-overview-eyebrow, .profile-eyebrow,
    .faq-kicker, .reserved-list-kicker, .shopping-overview-eyebrow,
    .shopping-history-panel-kicker, .users-hero-kicker, .item-add-hero-kicker) {
    display: none;
}

body :is(.stuff-hero-actions, .domain-intel-hero-actions, .llm-access-jumps) {
    margin-top: 12px;
    gap: 8px;
}

/* Quiet surfaces keep content and status, rather than decoration, prominent. */
body :is(.shopfor-overview-section, .shopping-history-panel, .stuff-panel,
    .faq-panel, .reserved-list-panel, .profile-section) {
    border-radius: 10px;
    background: var(--app-surface);
    box-shadow: none;
}

body :is(.shopfor-overview-section, .shopping-history-panel)::before {
    display: none;
}

.topmenu > ul.topmenu-primary-list {
    background: var(--app-surface);
    backdrop-filter: none;
    box-shadow: 0 1px 0 var(--app-border);
}

@media (min-width: 761px) {
    body .topmenu { padding-block-start: 0; }
    body .topmenu > ul.topmenu-primary-list {
        min-height: 56px;
        padding-block: 5px;
        border-radius: 0;
    }
    body .topmenu > ul.topmenu-primary-list > li,
    body .topmenu > ul.topmenu-primary-list > li.menu-home-logo {
        padding-block-end: 0;
    }
}

.topmenu .topmenu-nav-panel,
.mobile-bottom-nav,
.mobile-bottom-nav-popover {
    background: var(--app-surface);
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.sg-mini-window,
.dashboard-page.sr-mobile-swipe-actions .dashboard-items-table > tbody > tr.mobile-card-row > td[data-field="description"]::before,
.dashboard-page.sr-mobile-swipe-actions .dashboard-items-table > tbody > tr.mobile-card-row > td[data-field="description"]::after {
    animation: none !important;
}

.guest-form-note {
    margin: 4px 0;
    color: var(--app-muted);
    font-size: 0.8125rem;
    line-height: 1.5;
}

:is(.guest-commit-form, .foundation-commit-form) label[hidden] {
    display: none !important;
}

body .foundation-fulfillment {
    display: block;
}
body .foundation-fulfillment-meta { margin-bottom: 8px; }
body .foundation-fulfillment-yours {
    margin: 8px 0;
    color: var(--app-text);
    font-size: 0.8125rem;
    font-weight: 600;
}
body .foundation-commit-form {
    width: 100%;
    gap: 8px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--app-border);
}
body .foundation-commit-form .foundation-fulfillment-note {
    flex-basis: 100%;
    font-size: 0.8125rem;
    line-height: 1.5;
}
body .foundation-commit-form .foundation-fulfillment-actions {
    flex-basis: 100%;
    justify-content: flex-start;
}
body .foundation-commit-form label {
    font-size: 0.8125rem;
    font-weight: 500;
    white-space: normal;
}
body .foundation-commit-form :is(input, select) { min-height: 44px; }
body .guest-card,
body .guest-empty {
    padding: 16px;
    border-color: var(--app-border);
    border-radius: 10px;
    background: var(--app-surface);
    box-shadow: none;
}
body .guest-card h2 { color: var(--app-title-text); font-size: 1.125rem; }
body .guest-card button,
body.shop-page .foundation-action-btn {
    min-height: 44px;
    padding: 8px 12px;
    border-color: var(--app-button-border);
    border-radius: 7px;
    background: var(--app-button-b);
    color: var(--app-button-text);
    box-shadow: none;
    font-size: 0.875rem;
    font-weight: 600;
}
body .guest-card button.guest-secondary,
body.shop-page .foundation-action-btn.is-secondary {
    border-color: var(--app-border);
    background: var(--app-surface);
    color: var(--app-link);
}
body .guest-commit-form :is(input, select) {
    border-color: var(--app-input-border);
    background: var(--app-input-bg);
    color: var(--app-text);
    border-radius: 7px;
}

.topmenu .topmenu-nav-trigger,
.topmenu .topmenu-account-trigger,
.topmenu > ul.topmenu-primary-list > li.menu-item > a {
    border-radius: 7px;
    box-shadow: none;
}

.topmenu .topmenu-nav-trigger:hover,
.topmenu .topmenu-account-trigger:hover {
    box-shadow: none;
    translate: none;
}

.topmenu .topmenu-disclosure.is-active > .topmenu-nav-trigger,
.topmenu .topmenu-disclosure.is-active > .topmenu-account-trigger,
.topmenu .topmenu-nav-trigger[aria-expanded="true"],
.topmenu .topmenu-account-trigger[aria-expanded="true"] {
    background: var(--app-menu-current-bg-b);
    box-shadow: none;
}

body :is(.smallbut, .stuff-button, .sg-btn) {
    border-radius: 7px;
    box-shadow: none;
}

:where(a, button, input, select, textarea, summary):focus-visible {
    outline: 2px solid var(--app-focus, #2d79d8);
    outline-offset: 3px;
}

.sr-consent-banner {
    border-radius: 10px;
    background: var(--app-surface);
    backdrop-filter: none;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.12);
}
.sr-consent-banner .sr-consent-btn { box-shadow: none; }

/* Account forms start with the task and use the same restrained surfaces. */
body.signup-page .signup-shell { padding-block-start: 24px; }
body.signup-page .signup-card {
    padding: 24px;
    border-radius: 10px;
    background: var(--app-surface);
    box-shadow: none;
}
body.signup-page .signup-heading { text-align: left; }
body.signup-page .signup-kicker { display: none; }
body.signup-page .signup-card h1 { font-size: 1.75rem; line-height: 1.25; }
body.signup-page .signup-heading > p:last-child { margin-top: 10px; line-height: 1.5; }
body.signup-page .signup-benefits { margin-block: 16px 20px; }
body.signup-page .signup-benefits li { padding: 8px; border-radius: 7px; }
body.signup-page .signup-field input { border-radius: 7px; }
body.signup-page :is(.signup-passkey-button, .signup-email-button, .signup-secondary-link),
body.login-page :is(.login-primary-btn, .login-passkey-btn, .login-phone-btn) {
    min-height: 44px;
    border-radius: 7px;
    box-shadow: none;
    transform: none;
    font-weight: 600;
}
body.signup-page .signup-passkey-button,
body.login-page .login-primary-btn {
    background: var(--app-button-b);
    color: var(--app-button-text);
}
body.login-page form[name="login"] > p:first-of-type { margin: 14px 0; }
body.login-page form[name="login"] > p:first-of-type img { width: 185px; height: auto; }
body.login-page form[name="login"] > p:nth-of-type(2) { margin: 0; }
body.login-page form[name="login"] > p > br,
body.login-page form[name="login"] > p:nth-of-type(2) > img,
body.login-page #daystogo { display: none; }

/* Shopping overview is a compact introduction with useful totals. */
body.shopping-history-page .shopping-overview {
    --shopping-hero-ink: var(--app-text);
    --shopping-hero-muted: var(--app-muted);
    grid-template-columns: minmax(0, 1fr) minmax(240px, 0.6fr);
    gap: 16px 32px;
    align-items: center;
}

.shopping-overview-status {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.shopping-overview-progress {
    display: none;
}

.shopping-overview-metrics {
    margin: 0;
    gap: 12px;
}

.shopping-overview-metrics > div {
    padding-inline: 0;
    border: 0;
}

/* Counts already appear in the section links; keep the spending total here. */
body.shopping-history-page .shopping-overview-metrics > div:nth-child(-n + 2) {
    display: none;
}

body.shopping-history-page .shopping-overview-metrics {
    grid-template-columns: minmax(0, 1fr);
}

.shopping-overview-metrics dt {
    color: var(--app-muted);
    font-size: 0.75rem;
    font-weight: 400;
}

.shopping-overview-metrics dd {
    color: var(--app-text);
    font-size: 1.125rem;
    font-weight: 600;
}

.shopping-overview-actions {
    margin-top: 12px;
    gap: 8px;
}

.shopping-overview-primary-action,
.shopping-overview-primary-action:hover {
    border-color: var(--app-button-border);
    border-radius: 7px;
    background: var(--app-button-b);
    color: var(--app-button-text);
    box-shadow: none;
    translate: none;
}

.shopping-overview-jumps a {
    border-color: var(--app-border);
    border-radius: 7px;
    background: var(--app-surface);
    color: var(--app-text);
}

.shopping-overview-jumps a span {
    background: var(--app-row-even);
    color: var(--app-muted);
}

.shopping-overview-primary-action:focus-visible,
.shopping-overview-jumps a:focus-visible {
    outline-color: var(--app-focus);
}

/* Shopping history uses the same readable item layout as gift lists. */
body.shopping-history-page .shopping-history-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 16px;
    margin-bottom: 12px;
}

.shopping-history-panel-title { font-size: 1.125rem; line-height: 1.35; }
.shopping-history-panel-count { margin-inline-start: 4px; color: var(--app-muted); font-size: 0.875rem; font-weight: 400; }
.shopping-history-lane-meta { min-inline-size: 0; }
body .shopping-history-lane-meta strong { font-size: 0.8125rem; font-weight: 500; }
body .shopping-history-panel { border-block-start-width: 1px; scroll-margin-block-start: 12px; }

.shopping-history-sort {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    order: 2;
    margin: 0;
    font-size: 0.8125rem;
}

.shopping-history-sort label { color: var(--app-muted); }
body .shopping-history-lane-meta { order: 3; margin-inline-start: auto; }
.shopping-history-sort select {
    min-width: 0;
    min-height: 44px;
    padding: 8px 28px 8px 10px;
    border: 1px solid var(--app-border);
    border-radius: 7px;
    background-color: var(--app-surface);
    color: var(--app-text);
    font: inherit;
}

.shopping-history-sort button {
    min-height: 44px;
    padding: 8px 12px;
    border: 1px solid var(--app-border);
    border-radius: 7px;
    background: var(--app-surface);
    color: var(--app-text);
    box-shadow: none;
    font: inherit;
    cursor: pointer;
}

.shopping-history-sort :is(select, button):focus-visible {
    outline: 3px solid var(--app-focus);
    outline-offset: 2px;
}

.shopping-history-table-wrap { overflow: visible; border-radius: 8px; }
.shopping-history-table { min-inline-size: 0; table-layout: fixed; }
.shopping-history-recipient-col { width: 20%; }
.shopping-history-item-col { width: 65%; }
.shopping-history-price-col { width: 15%; }
.shopping-history-table.has-followup .shopping-history-item-col { width: 43%; }
.shopping-history-table.has-followup .shopping-history-price-col { width: 12%; }
.shopping-history-followup-col { width: 25%; }
.shopping-history-table th { font-size: 0.75rem; font-weight: 500; letter-spacing: 0; text-transform: none; white-space: normal; }
.shopping-history-table td { vertical-align: top; overflow-wrap: anywhere; }
.shopping-history-price-heading { text-align: end !important; }
.shopping-history-field-label { display: none; }

body .shopping-history-recipient .sr-inline-link-btn {
    max-inline-size: 100%;
    min-block-size: 44px;
    padding: 0;
    border: 0;
    border-radius: 4px;
    background: transparent;
    box-shadow: none;
    translate: none;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.shopping-history-item { display: grid; grid-template-columns: 64px minmax(0, 1fr); align-items: start; gap: 12px; }
.shopping-history-item.shopping-history-item--text { grid-template-columns: minmax(0, 1fr); }
.shopping-history-item-content { min-width: 0; }
body .shopping-history-thumb,
body .shopping-history-thumb-empty { width: 64px; height: 64px; border-radius: 7px; }
.shopping-history-thumb-empty { border: 1px solid var(--app-border); }
body .shopping-history-desc { max-inline-size: none; font-size: 0.875rem; font-weight: 600; line-height: 1.5; overflow-wrap: anywhere; }
body .shopping-history-comment { max-inline-size: none; margin-top: 6px; padding: 0; border: 0; font-size: 0.8125rem; line-height: 1.55; overflow-wrap: anywhere; }
.shopping-history-fulfillment { margin-top: 6px; color: var(--app-muted); font-size: 0.8125rem; line-height: 1.5; }
.shopping-history-item-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-top: 8px; }
body .shopping-history-rank { padding: 0; border: 0; background: transparent; }
.shopping-history-price { font-size: 0.875rem; white-space: normal; }
.shopping-history-followup-cell { min-inline-size: 0; }
.shopping-history-followup-link { min-block-size: 44px; font-size: 0.8125rem; border-radius: 7px; }

/* Guests reach the list before reading session details. */
body.guest-registry-page .guest-hero { margin-bottom: 12px; }
.guest-brand { margin-bottom: 16px; color: var(--app-title-text); font-size: 0.875rem; }
body .guest-brand img { width: 28px; height: 28px; border-radius: 6px; }
body .guest-identity { display: block; margin: 0 0 16px; padding: 0; border: 0; border-radius: 0; background: transparent; overflow-wrap: anywhere; }
body .guest-identity p { margin: 4px 0 0; color: var(--app-muted); font-size: 0.8125rem; line-height: 1.5; }
body .guest-identity .guest-identity-name { color: var(--app-text); }
body .guest-identity strong { color: inherit; }
.guest-card { min-width: 0; }
body .guest-card,
body .guest-empty,
body .guest-price,
body .guest-commit-form label { color: var(--app-text); }
body .guest-comment,
body .guest-progress p { color: var(--app-muted); }
body .guest-empty h2 { color: var(--app-title-text); }
body .guest-commit-form { border-color: var(--app-border); }
body .guest-progress-track { background: var(--app-border); }
body .guest-progress-track span { background: var(--app-link); }
body .guest-type,
body .guest-beneficiary { color: var(--app-metric-text); background: var(--app-metric-bg); font-weight: 600; }
body .guest-yours,
body .guest-fulfilled,
body .guest-yours.is-complete { color: var(--app-text); background: var(--app-row-even); border: 1px solid var(--app-border); font-weight: 600; }
.guest-shell :focus-visible { outline-color: var(--app-focus); }
.guest-card :is(h2, p, span) { overflow-wrap: anywhere; }
.guest-card-head { flex-wrap: wrap; }
.guest-footer { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--app-border); }
.guest-access-note { margin: 0; color: var(--app-muted); font-size: 0.8125rem; line-height: 1.5; overflow-wrap: anywhere; }
body .guest-leave { margin-top: 12px; }
body .guest-leave button { min-height: 44px; padding: 8px 12px; border: 1px solid var(--app-border); border-radius: 7px; background: var(--app-surface); color: var(--app-text); box-shadow: none; font-size: 0.875rem; text-decoration: none; }

@media (max-width: 980px) {
    .shopping-history-sort { order: 3; flex-basis: 100%; }
    body .shopping-history-lane-meta { order: 2; }
    .shopping-history-sort select { flex: 1 1 120px; font-size: 1rem; }
    .shopping-history-table,
    .shopping-history-table > tbody { display: grid !important; width: 100%; gap: 12px; }
    .shopping-history-table :is(thead, colgroup) { display: none; }
    .shopping-history-table-wrap { border: 0; background: transparent; }
    .shopping-history-table > tbody > tr.shopping-history-row { display: grid; min-width: 0; border: 1px solid var(--app-border); border-radius: 8px; background: var(--app-surface); }
    .shopping-history-table > tbody > tr.shopping-history-row > td { display: block; width: auto; min-width: 0; padding: 10px 12px; border: 0; background: transparent; }
    .shopping-history-table > tbody > tr.shopping-history-row > td.shopping-history-recipient { display: flex; align-items: center; gap: 12px; padding-block: 4px; border-bottom: 1px solid var(--app-border); }
    .shopping-history-table > tbody > tr.shopping-history-row > td:is(.shopping-history-price, .shopping-history-followup-cell) { display: grid; grid-template-columns: 90px minmax(0, 1fr); align-items: start; gap: 12px; border-top: 1px solid var(--app-border); text-align: start; }
    .shopping-history-field-label { display: block; flex: 0 0 78px; color: var(--app-muted); font-size: 0.75rem; font-weight: 400; }
    .shopping-history-item { grid-template-columns: 56px minmax(0, 1fr); gap: 10px; }
    body .shopping-history-thumb,
    body .shopping-history-thumb-empty { width: 56px; height: 56px; }
}

@media (max-width: 980px) {
    body.shopping-history-page .shopping-overview { grid-template-columns: minmax(0, 1fr) auto; gap: 8px 12px; align-items: start; }
    .shopping-overview-copy { display: contents; }
    .shopping-overview-copy h1 { grid-column: 1; grid-row: 1; }
    .shopping-overview-status { grid-column: 2; grid-row: 1; text-align: end; }
    body .shopping-overview-metrics > div:nth-child(3) { padding: 0; border: 0; }
    .shopping-overview-metrics dd { font-size: 1rem; }
    .shopping-overview-actions { grid-column: 1 / -1; grid-row: 2; margin-top: 4px; }
}

@media (min-width: 981px) {
    body.shopping-history-page .shopping-overview { grid-template-columns: minmax(0, 1fr) auto auto; gap: 16px 24px; }
    .shopping-overview-copy { display: contents; }
    .shopping-overview-copy h1 { grid-column: 1; margin-bottom: 0; }
    .shopping-overview-actions { grid-column: 2; grid-row: 1; margin: 0; }
    .shopping-overview-status { grid-column: 3; grid-row: 1; text-align: end; }
}

/* Public pages use the same restrained scale without a decorative mock app. */
body.sg-page {
    background: var(--app-bg-a, #f3f6fb) !important;
}

body.sg-page .sg-browser {
    border: 0;
    border-radius: 0;
    background: var(--app-surface, #fff);
    box-shadow: none;
}

body.sg-page .sg-nav {
    padding: 14px 24px;
    background: var(--app-surface, #fff);
    border-bottom: 1px solid var(--app-border);
}

body.sg-page .sg-nav-links a,
body.sg-page .sg-nav-link-btn {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
}

body.sg-page .sg-main {
    padding: 24px;
}

body.sg-page .sg-hero {
    display: block;
    min-height: 0;
    padding: 8px 0 24px !important;
    margin: 0;
    border: 0 !important;
    border-bottom: 1px solid var(--app-border) !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

body.sg-page .sg-hero::before,
body.sg-page .sg-hero::after,
body.sg-page .sg-hero-visual,
body.sg-page .sg-eyebrow {
    display: none !important;
}

body.sg-page .sg-hero h1 {
    max-width: 38ch;
    margin: 0;
    color: var(--app-title-text, #162234) !important;
    font-size: clamp(1.5rem, 2.5vw, 2rem) !important;
    font-weight: 650;
    line-height: 1.3 !important;
    letter-spacing: -0.025em;
}

body.sg-page .sg-hero p {
    max-width: 68ch;
    margin-block: 10px 0;
    color: var(--app-muted, #5b6a80) !important;
    font-size: 0.9375rem !important;
    line-height: 1.6;
}

body.sg-page .sg-start-invite-gate {
    max-width: 480px;
    margin-top: 18px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
}

body.sg-page .sg-actions--hero {
    margin-top: 12px;
}

body.sg-page :is(.sg-benefit-card, .sg-use-case-card, .sg-faq-card,
    .sg-summary-step, .sg-pricing-card) {
    border-radius: 8px;
    background: var(--app-surface, #fff);
    box-shadow: none;
}

/* Forms stay readable when mobile browsers focus an input. */
.settings-nav-tabs { display: contents; }
.settings-nav-flyout-menu[hidden] { display: none !important; }
body.profile-page .settings-shell { padding-top: 12px; }
body.profile-page .settings-topbar {
    padding: 10px 0 16px;
    margin-bottom: 16px;
    border: 0;
    border-bottom: 1px solid var(--app-border);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}
body.profile-page .settings-topbar h1 {
    margin: 0;
    font-size: clamp(24px, 2.4vw, 30px);
    line-height: 1.3;
    font-weight: 650;
    padding-block: 0;
}
body.profile-page .settings-topbar { backdrop-filter: none; -webkit-backdrop-filter: none; }
body.profile-page .settings-nav {
    border-radius: 8px;
    background: var(--app-surface);
    box-shadow: none;
    backdrop-filter: none;
}
body.profile-page .settings-nav::before { display: none; }
body.profile-page :is(.settings-nav-btn, .settings-nav-toggle, .settings-nav-flyout-item) {
    min-height: 44px;
    border-radius: 6px;
    background: transparent;
    box-shadow: none;
    transform: none;
    font-weight: 500;
}
body.profile-page .settings-nav-btn.is-active {
    background: var(--app-row-even);
    box-shadow: none;
    font-weight: 600;
}
body.profile-page .settings-nav-btn:hover { background: var(--app-row-even); }
body.profile-page .settings-nav-flyout-menu {
    background: var(--app-surface);
    border-radius: 8px;
    box-shadow: var(--app-elevated-shadow);
    backdrop-filter: none;
}
body.profile-page .settings-section-card {
    border-radius: 8px;
    background: var(--app-surface);
    box-shadow: none;
}
body.profile-page .settings-section-head h2 { font-size: 18px; font-weight: 650; }
body.profile-page .settings-shell :is(.settings-save-btn, .settings-nav-drawer-open) {
    min-height: 44px;
    border-radius: 6px;
    background: var(--app-button-b) !important;
    box-shadow: none;
    font-weight: 600;
}

/* Registry names and list choices carry information, so they wrap in full. */
body.registries-page :is(.registry-switch-item-name, .registry-license-text,
    .registry-switch-item-license, .registry-switch-item-cta-lines > span) {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    overflow-wrap: anywhere;
    line-height: 1.4;
}
body.registries-page :is(.registry-switch-item-text, .registry-switch-item-main) {
    min-width: 0;
}
body.registries-page .registry-switch-item-identity { align-items: flex-start; }
body.registries-page .registry-switch-item-row { container-type: inline-size; }
@container (max-width: 420px) {
    body.registries-page .registry-switch-item-primary { grid-template-columns: minmax(0, 1fr) !important; }
    body.registries-page .registry-switch-item-cta-submit {
        justify-self: end;
        min-height: 44px;
        margin-top: 8px;
    }
}
body.registries-page .registries-hero-kicker { display: none; }
body.registries-page .panel {
    border-radius: 10px;
    background: var(--app-surface);
    box-shadow: none;
}
body.registries-page .panel::before { display: none; }

body.item-add-page .item-add-hero-grid.has-tip {
    grid-template-columns: minmax(0, 1fr) minmax(0, 360px);
    align-items: center;
}
body.item-add-page .item-add-hero-tip {
    min-width: 0;
    max-width: 100%;
    margin: 0;
    padding: 0 !important;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}
body.item-add-page .item-add-hero-tip :is(strong, span, .dashboard-shortcut-title) {
    white-space: normal;
    overflow-wrap: anywhere;
    font-size: 12px;
    line-height: 1.5;
}
body.item-add-page .item-add-hero-tip .dashboard-shortcut-inline {
    flex-wrap: wrap;
    min-width: 0;
}
body.item-add-page .item-form-shell-modern {
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}
body.item-add-page .item-form-section {
    padding: 16px;
    border-radius: 8px;
    background: var(--app-surface);
    box-shadow: none;
}
body.item-add-page .item-form-section h2 {
    margin: 0 0 14px;
    font-size: 18px;
    line-height: 1.35;
    font-weight: 650;
    color: var(--app-title-text);
}
body.item-add-page .item-form-section-kicker { display: none; }
body.item-add-page .item-list-card {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    overflow: visible;
}
body.item-add-page .item-list-choice {
    grid-template-columns: 20px minmax(0, 1fr);
    grid-template-areas: "radio title" "radio note";
    gap: 4px 10px;
    min-height: 0;
    padding: 12px;
    border-radius: 8px;
    background: var(--app-surface);
    box-shadow: none;
    overflow: visible;
    transform: none;
}
body.item-add-page .item-list-choice input[type="radio"] {
    grid-area: radio;
    position: static;
    width: 18px;
    height: 18px;
    margin: 2px 0 0;
    opacity: 1;
    pointer-events: auto;
    accent-color: var(--app-link);
}
body.item-add-page .item-list-choice:is(.is-selected, :has(input:checked), :hover) {
    border-color: var(--app-link);
    background: var(--app-row-even);
    box-shadow: none;
    transform: none;
}
body.item-add-page .item-list-choice:has(input:focus-visible) {
    outline: 2px solid var(--app-focus);
    outline-offset: 2px;
    box-shadow: none;
    transform: none;
}
body.item-add-page :is(.item-list-choice-icon, .item-list-choice-selected-badge) {
    display: none !important;
}
body.item-add-page .item-list-choice-title {
    min-width: 0;
    color: var(--app-text);
    font-size: 14px;
    line-height: 1.4;
    font-weight: 600;
    overflow-wrap: anywhere;
}
body.item-add-page .item-list-choice-note {
    min-width: 0;
    padding: 0;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.5;
    overflow-wrap: anywhere;
}
body.mobile-device.item-add-page .item-list-choice-registry .item-list-choice {
    grid-template-columns: 20px minmax(0, 1fr);
    gap: 4px 10px;
    padding: 12px;
}
body.mobile-device.item-add-page .item-list-choice .item-list-choice-title {
    font-size: 14px;
}
body.item-add-page .item-form-actions-modern {
    border-radius: 8px;
    background: var(--app-surface);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
}
body.item-add-page .item-form-submit {
    min-height: 44px;
    border-radius: 7px;
    background: var(--app-button-b);
    box-shadow: none;
    font-weight: 600;
}
body.item-page .item-form-error-summary {
    margin: 0 0 16px;
    padding: 14px 16px;
    border: 1px solid var(--app-danger, #b42318);
    border-radius: 8px;
    background: var(--app-surface);
    scroll-margin-top: 24px;
}
body.item-page .item-form-error-summary h2 {
    margin: 0 0 6px;
    color: var(--app-text);
    font-size: 18px;
    line-height: 1.4;
}
body.item-page .item-form-error-summary p { margin: 0 0 6px; }
body.item-page .item-form-error-summary ul { margin: 0; padding-left: 20px; }
body.item-page .item-form-error-summary li { margin-block: 4px; }
body.item-page [aria-invalid="true"] { scroll-margin-block: 24px 100px; }

/* A gift list uses one item column and a clear set of actions. */
body.shop-page .shop-page-hero { align-items: center; }
body.shop-page .shop-page-hero-photo {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    box-shadow: none;
}
body.shop-page .shop-page-hero-main { align-items: center; }
body.shop-page .shop-page-metrics {
    max-width: none;
    gap: 6px 12px;
    font-size: 12px;
}
body.shop-page .shop-page-metrics > span {
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}
body.shop-page .shop-page-card {
    padding: 16px;
    border-color: var(--app-border);
    border-radius: 10px;
    background: var(--app-surface);
    box-shadow: none;
    overflow: visible;
}
body.shop-page .shop-page-card-head h2 { font-size: 18px; font-weight: 650; }
body.shop-page .shop-page-card-titlebar { flex-wrap: wrap; }
body.shop-page .shop-page-card-actions { flex: 1; min-width: 0; }
body.shop-page .shop-page-toolbar { min-width: 0; }
body.shop-page .shop-enhanced-controls { flex-wrap: wrap; }
body.shop-page .shop-layout-separator { display: none; }
body.shop-page .shop-layout-link:focus-visible {
    outline: 2px solid var(--app-focus);
    outline-offset: 2px;
}
body.shop-page .shop-enhanced-availability {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}
body.shop-page .shop-enhanced-availability-pills { border-radius: 6px; }
body.shop-page .shop-enhanced-availability-btn { white-space: normal; }
body.shop-page .shop-enhanced-availability-btn.is-active {
    background: var(--app-button-b);
    box-shadow: none;
}
body.shop-page .shop-page-card-actions .shop-page-toolbar {
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
}
body.shop-page .shop-page-table-wrap {
    border-color: var(--app-border);
    border-radius: 8px;
    box-shadow: none;
    overflow: visible;
}
body.shop-page :is(.shop-layout-link, .shop-layout-btn, .shop-enhanced-availability-btn) {
    min-height: 44px;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    box-shadow: none;
}
body.shop-page .shop-layout-link.is-active {
    background: var(--app-row-even);
    text-decoration: none;
}
body.shop-page .shop-list-sort-form { display: flex; flex-wrap: wrap; }
body.shop-page .shop-list-table {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
    border-collapse: collapse;
    margin: 0;
    color: var(--app-text);
    font-size: 14px;
    line-height: 1.5;
}
body.shop-page .shop-list-table th {
    padding: 10px 12px;
    border-bottom: 1px solid var(--app-border);
    background: var(--app-row-even);
    color: var(--app-muted);
    font-size: 12px;
    font-weight: 600;
    text-align: left;
    text-transform: none;
    letter-spacing: 0;
}
body.shop-page .shop-list-table th:nth-child(1) { width: 44%; }
body.shop-page .shop-list-table th:nth-child(2) { width: 8%; }
body.shop-page .shop-list-table th:nth-child(3) { width: 16%; }
body.shop-page .shop-list-table th:nth-child(4) { width: 32%; }
body.shop-page .shop-list-table td {
    padding: 14px 12px;
    border-bottom: 1px solid var(--app-border);
    vertical-align: top;
    white-space: normal;
    overflow-wrap: anywhere;
    background: var(--app-surface);
}
body.shop-page .shop-list-table tr:last-child td { border-bottom: 0; }
body.shop-page .shop-list-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-width: 0;
}
body.shop-page .shop-list-item-content { flex: 1; min-width: 0; }
body.shop-page .shop-list-thumb {
    display: block;
    flex: 0 0 64px;
    width: 64px;
    height: 64px;
    border: 1px solid var(--app-border);
    border-radius: 6px;
    background: var(--app-row-even);
    box-shadow: none;
}
body.shop-page .shop-list-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: inherit;
}
body.shop-page .shop-list-thumb-empty {
    display: grid;
    place-items: center;
    height: 100%;
    text-align: center;
    color: var(--app-muted);
    font-size: 10px;
    line-height: 1.4;
}
body.shop-page :is(.shop-list-description, .shop-list-note) {
    display: block;
    height: auto;
    max-height: none;
    overflow: visible;
    white-space: normal;
    text-overflow: clip;
    -webkit-line-clamp: unset;
    overflow-wrap: anywhere;
    line-height: 1.5;
}
body.shop-page .shop-list-description {
    color: var(--app-link);
    font-size: 14px;
    font-weight: 600;
}
body.shop-page .shop-list-note {
    margin: 8px 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--app-muted);
    font-size: 13px;
}
body.shop-page .shop-list-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 12px;
    margin-top: 8px;
    color: var(--app-muted);
    font-size: 12px;
}
body.shop-page .shop-list-meta > span { min-width: 0; overflow-wrap: anywhere; }
body.shop-page .shop-list-price { font-variant-numeric: tabular-nums; font-weight: 600; }
body.shop-page .shop-list-field-label { display: none; }
body.shop-page .shop-list-status-value {
    max-width: none;
    border: 0;
    border-radius: 0;
    padding: 0;
    background: transparent;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: 0;
    text-transform: none;
}
body.shop-page .shop-list-row.is-unavailable :is(.shop-list-description, .shop-list-note) {
    color: var(--app-muted);
}
body.shop-page .shop-list-actions :is(.foundation-fulfillment, .foundation-commit-form) {
    min-width: 0;
    flex-wrap: wrap;
    white-space: normal;
}
body.shop-page .shop-list-actions .foundation-commit-form {
    margin-top: 8px;
    padding-top: 8px;
}
body.shop-page .shop-list-actions :is(.foundation-action-btn, .smallbut, .shop-copy-link-btn) {
    min-height: 44px;
    padding: 8px 10px;
    font-size: 13px;
    white-space: normal;
}
body.shop-page .shop-list-actions .shop-action-form { margin: 0 0 6px; }
body.shop-page .shop-list-actions .shop-action-form--copy { margin: 8px 0 0; }
body.shop-page .shop-enhanced-card {
    border-radius: 10px;
    background: var(--app-surface);
    box-shadow: none;
    transform: none;
}
body.shop-page .shop-enhanced-card[hidden],
body.shop-page .shop-enhanced-filter-empty[hidden] { display: none !important; }
body.shop-page .shop-enhanced-status {
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
    box-shadow: none;
    backdrop-filter: none;
}
body.shop-page :is(.shop-enhanced-title, .shop-enhanced-comment) {
    max-height: none;
    overflow: visible;
    -webkit-line-clamp: unset;
    overflow-wrap: anywhere;
}

/* Let desktop gifts take only the space their details and actions need. */
@media (min-width: 981px) {
    body.shop-page .shop-page-hero {
        padding-block: 8px 12px !important;
        margin-bottom: 12px;
    }
    body.shop-page .shop-page-card { padding: 14px; }
    body.shop-page .shop-page-card-head { margin-bottom: 12px; }
    body.shop-page .shop-enhanced-grid {
        grid-template-columns: repeat(auto-fill, minmax(min(100%, 275px), 1fr));
        align-items: start;
        gap: 12px;
    }
    body.shop-page .shop-enhanced-card {
        --shop-control-height: 44px;
        height: auto;
        border-color: var(--app-border);
        backdrop-filter: none;
    }
    body.shop-page .shop-enhanced-card:is(:hover, :focus-within) {
        translate: none;
        scale: none;
        box-shadow: none;
    }
    body.shop-page .shop-enhanced-card::before,
    body.shop-page .shop-enhanced-media::after { display: none; }
    body.shop-page .shop-enhanced-media {
        height: 120px;
        grid-template-rows: minmax(0, 1fr);
        background: var(--app-row-even);
        border-color: var(--app-border);
    }
    body.shop-page .shop-enhanced-media > a { min-height: 0; }
    body.shop-page .shop-enhanced-media img { max-height: 100%; scale: none; }
    body.shop-page .shop-enhanced-rank {
        border-radius: 6px;
        background: var(--app-surface);
        box-shadow: none;
        backdrop-filter: none;
    }
    body.shop-page .shop-enhanced-content {
        display: flex;
        flex: 0 0 auto;
        gap: 8px;
    }
    body.shop-page .shop-enhanced-title {
        font-size: 16px;
        font-weight: 650;
        line-height: 1.35;
    }
    body.shop-page .shop-enhanced-price {
        padding: 0;
        border: 0;
        background: transparent;
        font-size: 20px;
        font-weight: 650;
        line-height: 1.25;
    }
    body.shop-page .shop-enhanced-meta > span {
        padding: 0;
        border: 0;
        background: transparent;
    }
    body.shop-page .shop-enhanced-meta { gap: 4px 10px; }
    body.shop-page .shop-enhanced-actions {
        margin-top: 0;
        padding-block: 10px;
        border-color: var(--app-border);
        background: var(--app-surface);
    }
    body.shop-page :is(.shop-list-actions, .shop-enhanced-actions) .foundation-fulfillment {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        margin: 0;
    }
    body.shop-page .foundation-fulfillment :is(.foundation-fulfillment-meta, .foundation-fulfillment-yours) {
        flex-basis: 100%;
        margin: 0;
    }
    body.shop-page :is(.shop-list-actions, .shop-enhanced-actions) .foundation-commit-form {
        flex: 1 1 100%;
        gap: 8px;
        margin: 0;
        padding: 0;
        border: 0;
    }
    body.shop-page .foundation-commit-form .foundation-fulfillment-actions {
        flex: 1 1 auto;
        justify-content: flex-start;
    }
    body.shop-page .foundation-commit-form .foundation-fulfillment-note {
        order: 1;
        font-size: 12px;
        line-height: 1.4;
    }
    body.shop-page .foundation-fulfillment-actions { gap: 6px; }
    body.shop-page .shop-enhanced-actions .foundation-fulfillment-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
    }
    body.shop-page .shop-enhanced-actions .foundation-transition-form { min-width: 0; }
    body.shop-page .shop-enhanced-actions .foundation-action-btn {
        width: 100%;
        min-width: 0;
        white-space: normal;
        line-height: 1.35;
    }
    body.shop-page :is(.shop-enhanced-copy, .shop-list-copy) .shop-copy-link-btn {
        width: auto;
        min-height: 44px;
        border: 0;
        border-radius: 6px;
        background: transparent;
        box-shadow: none;
        justify-content: flex-start;
        text-align: start;
        font-size: 12px;
    }
    body.shop-page :is(.shop-enhanced-copy, .shop-list-copy) .shop-copy-link-btn:hover {
        background: var(--app-row-even);
        box-shadow: none;
    }
    body.shop-page .shop-enhanced-copy { flex-basis: 100%; }
    body.shop-page .shop-list-table th:nth-child(1) { width: 44%; }
    body.shop-page .shop-list-table th:nth-child(2) { width: 8%; }
    body.shop-page .shop-list-table th:nth-child(3) { width: 12%; }
    body.shop-page .shop-list-table th:nth-child(4) { width: 36%; }
    body.shop-page .shop-list-table td { padding-block: 12px; }
    body.shop-page .shop-list-meta { margin-top: 6px; gap: 4px 10px; }
    body.shop-page .shop-list-actions .shop-action-form--copy { margin-top: 4px; }
}

/* Keep fully claimed gifts visibly distinct in both layouts and every theme. */
body.shop-page .shop-enhanced-card.is-unavailable,
body.shop-page .shop-list-row.is-unavailable > td {
    background: color-mix(in srgb, var(--app-surface) 78%, var(--app-muted) 22%);
}
body.shop-page .shop-enhanced-card.is-unavailable,
body.shop-page .shop-list-row.is-unavailable > td:first-child {
    border-inline-start: 4px solid var(--app-muted);
}
body.shop-page .shop-enhanced-card.is-unavailable :is(.shop-enhanced-media, .shop-enhanced-actions) {
    background: transparent;
}
body.shop-page .shop-enhanced-card.is-unavailable .shop-enhanced-media img,
body.shop-page .shop-list-row.is-unavailable .shop-list-thumb img {
    filter: grayscale(1);
    opacity: 0.6;
}
body.shop-page .shop-enhanced-card.is-unavailable .shop-item-link,
body.shop-page .shop-list-row.is-unavailable .shop-list-description {
    color: var(--app-text);
}
body.shop-page .shop-list-row.is-unavailable .shop-list-status-value,
body.shop-page .shop-enhanced-card.is-unavailable .shop-enhanced-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 8px;
    border: 1px solid var(--app-muted);
    border-radius: 6px;
    background: var(--app-surface);
    color: var(--app-text);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
}
body.shop-page .shop-page-note {
    padding: 12px 14px;
    border-inline-start: 4px solid var(--app-muted);
    border-radius: 6px;
    background: var(--app-row-even);
    color: var(--app-text);
    font-size: 13px;
    line-height: 1.5;
}

@media (min-width: 981px) and (hover: hover) and (pointer: fine) {
    body.shop-page .shop-enhanced-card { --shop-control-height: 36px; }
    body.shop-page :is(.foundation-action-btn, .shop-layout-link, .shop-layout-btn,
        .shop-enhanced-availability-btn, .shop-list-actions .smallbut) {
        min-height: 36px;
        padding: 6px 10px;
        font-size: 13px;
    }
    body.shop-page .foundation-commit-form :is(input, select) { min-height: 36px; }
    body.shop-page :is(.shop-enhanced-copy, .shop-list-copy) .shop-copy-link-btn {
        min-height: 32px;
        padding: 4px 6px;
    }
}

body.shopfor-overview-page .shopfor-overview-section {
    border-color: var(--app-border);
    border-radius: 10px;
    background: var(--app-surface);
    box-shadow: none;
}
body.shopfor-overview-page .shopfor-overview-section-head h2 { font-size: 18px; }
body.shopfor-overview-page .shopfor-overview-hero {
    padding-block: 10px 14px !important;
    align-items: center;
}
body.shopfor-overview-page .shopfor-overview-hero .dashboard-metrics { display: none; }
.shoppee-mobile-summary, .shoppee-action-label { display: none; }

@media (min-width: 981px) {
    body.shopfor-overview-page .shopfor-overview-primary .shopfor-people-table--active {
        inline-size: 100%;
        min-inline-size: 0;
        table-layout: fixed;
    }
    body.shopfor-overview-page .shopfor-people-table--active .shoppees-colhead-row th {
        padding-inline: 4px;
    }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-colhead-name { width: 26%; min-width: 0; }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-colhead-updated { width: 15%; }
    body.shopfor-overview-page .shopfor-people-table--active :is(.shoppee-colhead-items, .shoppee-colhead-open) { width: 8%; }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-colhead-reserved { width: 10%; }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-colhead-bought { width: 9%; }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-action-head { width: 8%; }
    body.shopfor-overview-page .shopfor-people-table--active :is(.shoppee-name-form, .shoppee-name-link, .shoppee-name-static) {
        max-inline-size: 100%;
        min-inline-size: 0;
        white-space: normal;
    }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-name-copy {
        min-inline-size: 0;
        white-space: normal;
        overflow-wrap: anywhere;
    }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-avatar { flex-shrink: 0; }
}

@media (max-width: 980px) {
    body.shop-page .shop-list-table { display: block; }
    body.shop-page .shop-list-table thead { display: none; }
    body.shop-page .shop-list-table tbody { display: grid; gap: 12px; }
    body.shop-page .shop-list-table tr {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
        border: 1px solid var(--app-border);
        border-radius: 8px;
        overflow: visible;
    }
    body.shop-page .shop-list-table td {
        display: block;
        min-width: 0;
        border: 0;
        padding: 12px;
        background: transparent;
    }
    body.shop-page .shop-list-item-cell { grid-column: 1 / -1; }
    body.shop-page .shop-list-table .shop-list-status { padding-left: 0; }
    body.shop-page .shop-list-table .shop-list-actions {
        grid-column: 1 / -1;
        border-top: 1px solid var(--app-border);
    }
    body.shop-page .shop-list-field-label {
        display: block;
        margin-bottom: 4px;
        color: var(--app-muted);
        font-size: 12px;
        font-weight: 400;
    }
    body.shop-page .shop-list-sort-form { display: flex; }
    body.shop-page .shop-page-table-wrap { border: 0; }
    body.shopfor-overview-page .shopfor-people-table :is(.shoppee-name-form,
        .shoppee-name-link, .shoppee-name-static, .shoppee-person-stack) {
        min-width: 0;
        max-width: 100%;
        white-space: normal;
    }
    body.shopfor-overview-page .shopfor-people-table .shoppee-name-copy {
        min-width: 0;
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
        overflow-wrap: anywhere;
    }
    body.shopfor-overview-page .shoppee-avatar { flex-shrink: 0; }
    body.shopfor-overview-page .shopfor-overview-primary .dashboard-table-scroll {
        overflow: visible;
        padding: 0;
    }
    body.shopfor-overview-page .shopfor-overview-primary .shopfor-people-table--active {
        display: block;
        width: 100%;
        min-width: 0;
        border: 0;
        box-shadow: none;
    }
    body.shopfor-overview-page .shopfor-people-table--active > tbody {
        display: grid;
        gap: 10px;
    }
    body.shopfor-overview-page .shopfor-people-table--active .shoppees-colhead-row {
        display: none;
    }
    body.shopfor-overview-page .shopfor-people-table--active .shopfor-people-row {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        border: 1px solid var(--app-border);
        border-radius: 8px;
        background: var(--app-surface);
    }
    body.shopfor-overview-page .shopfor-overview-primary .shopfor-people-table--active .shoppee-person-cell {
        display: block !important;
        grid-column: 1 / -1;
        width: auto !important;
        padding: 12px;
        border: 0;
        background: transparent;
    }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-name-link {
        display: flex;
        width: 100%;
        min-height: 44px;
        padding: 0;
        border: 0;
        border-radius: 0;
        background: transparent;
        text-align: left;
        box-shadow: none;
    }
    body.shopfor-overview-page .shopfor-people-table--active :is(.shoppee-updated-cell, .shoppee-metric-cell) {
        display: none !important;
    }
    body.shopfor-overview-page .shopfor-overview-primary .shopfor-people-table--active td.shoppee-action-cell {
        display: flex !important;
        justify-content: center;
        align-items: center;
        width: auto !important;
        max-width: none !important;
        min-width: 0;
        padding: 8px 4px;
        border: 0;
        border-top: 1px solid var(--app-border);
        background: transparent;
    }
    body.shopfor-overview-page .shopfor-overview-primary .shopfor-people-table--active :is(.shoppee-action-btn, .shoppee-action-disabled) {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        min-width: 0;
        width: 100% !important;
        max-width: none;
        height: auto;
        min-height: 44px;
        padding: 8px 4px;
        border: 0;
        border-radius: 6px;
        background: transparent;
        box-shadow: none;
        font-size: 12px;
        line-height: 1.4;
        white-space: normal;
        color: var(--app-link);
    }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-action-disabled {
        color: var(--app-muted);
    }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-action-cell img { flex-shrink: 0; }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-action-label { display: inline; }
    body.shopfor-overview-page .shopfor-people-table--active .shoppee-mobile-summary {
        display: block;
        margin: 4px 0 0;
        color: var(--app-muted);
        font-size: 12px;
        line-height: 1.5;
        white-space: normal;
    }
}

@media (max-width: 760px) {
    body.registries-page .registry-switch-item-primary { grid-template-columns: minmax(0, 1fr) !important; }
    body.registries-page .registry-switch-item-cta-submit {
        justify-self: end;
        min-height: 44px;
        margin-top: 8px;
    }
    body.item-add-page .item-add-hero-grid.has-tip { grid-template-columns: minmax(0, 1fr); }
    body.item-add-page .item-add-hero-tip { justify-self: start; width: 100%; }
    body.item-add-page .item-list-choice-registry.has-local,
    body.item-add-page .item-list-choice-registry { grid-template-columns: minmax(0, 1fr); gap: 8px; }
    body.shop-page .shop-page-card { padding: 12px; }
    body.shop-page .shop-page-card-titlebar { flex-direction: row; align-items: flex-start; }
    body.shop-page .shop-page-card-actions { flex-basis: 100%; justify-content: flex-start; }
    body.shop-page .shop-page-card-actions .shop-page-toolbar { width: 100%; }
    body.shop-page .shop-enhanced-controls { align-items: stretch; }
    body.shop-page :is(.shop-enhanced-sort-form, .shop-enhanced-availability) { flex: 1 1 100%; }
    body.shop-page .shop-enhanced-availability-label { display: none; }
    .sr-consent-banner-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .sr-consent-banner-actions .sr-consent-btn {
        width: 100%;
        min-width: 0;
        padding: 8px;
        white-space: normal;
        border-radius: 6px;
    }

    .sr-consent-banner-actions .sr-consent-btn-ghost {
        grid-column: 1 / -1;
        border: 0;
        background: transparent;
        color: var(--app-link);
    }

    :is(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
        select, textarea) {
        font-size: max(16px, 1rem) !important;
    }

    .shopping-overview-actions { flex-wrap: wrap; }

    .shopping-overview-primary-action { width: auto; }

    body.sg-page .sg-main { padding: 16px; }

    body.sg-page .sg-nav { padding: 8px 16px; gap: 8px; }

    body.sg-page .sg-nav-links { gap: 10px; }

    body.sg-page .sg-brand-nameplate { max-width: 180px; height: 32px; }

    body.sg-page .sg-brand-logo { width: 36px; height: 36px; border-radius: 6px; box-shadow: none; }

    body.sg-page .sg-hero { padding-top: 4px !important; }

    body.sg-page .sg-hero h1 { font-size: 1.5rem !important; }

    body.sg-page .sg-start-invite-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
    }
    body.sg-page .sg-start-invite-row .sg-btn { width: auto; }
}

@media (prefers-reduced-motion: reduce) {
    .home-dashboard-page .dashboard-items-table tr[data-itemid] > td {
        transition: none;
    }
}

@media (forced-colors: active) {
    .home-items-workspace #tabs > ul.ui-tabs-nav li a[aria-selected="true"] {
        border-color: Highlight;
        color: Highlight;
    }
}
