:root {
    color-scheme: light;
    --paper: #ffffff;
    --ink: #111111;
    --yellow: #ffdd00;
    --yellow-soft: #fff5a8;
    --surface: #f6f6f2;
    --surface-strong: #ecece6;
    --line: #d8d8d1;
    --control-line: #8a8a82;
    --muted: #66665f;
    --focus-ring: #111111;
    --radius-sm: 14px;
    --radius-md: 22px;
    --radius-lg: 32px;
    --radius-xl: 48px;
    --header-height: 76px;
    font-family:
        Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
        sans-serif;
    font-synthesis: none;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    background: var(--paper);
    scroll-behavior: smooth;
    scroll-padding-block-start: calc(var(--header-height) + 16px);
    scroll-padding-block-end: 24px;
}

body {
    min-width: 320px;
    min-height: 100vh;
    min-height: 100dvh;
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-size: 16px;
    line-height: 1.5;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

body.has-modal {
    position: fixed;
    top: var(--post-modal-scroll-top, 0);
    left: var(--post-modal-scroll-left, 0);
    width: 100%;
    overflow: hidden;
}

button,
input,
select,
textarea {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

button {
    min-inline-size: 24px;
    min-block-size: 24px;
    color: inherit;
}

a {
    color: inherit;
}

[hidden] {
    display: none !important;
}

.ui-icon-sprite {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
    pointer-events: none;
}

.ui-icon {
    display: block;
    width: 20px;
    height: 20px;
    flex: 0 0 auto;
    fill: none;
    stroke: currentcolor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
    vector-effect: non-scaling-stroke;
}

::selection {
    background: var(--yellow);
    color: var(--ink);
}

:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: 3px;
}

:where(a, button, input, select, textarea, [tabindex]):focus-visible {
    scroll-margin-block: calc(var(--header-height) + 16px) 24px;
}

.skip-link {
    position: fixed;
    z-index: 1000;
    top: 8px;
    left: 8px;
    max-width: calc(100% - 16px);
    padding: 12px 16px;
    border: 2px solid currentcolor;
    border-radius: var(--radius-sm);
    background: var(--paper);
    color: var(--ink);
    font-weight: 900;
    transform: translateY(calc(-100% - 16px));
}

.skip-link:focus-visible {
    outline-color: var(--focus-ring);
    transform: translateY(0);
}

.app-shell {
    min-height: 100vh;
    min-height: 100dvh;
    overflow-x: clip;
}

.app-header {
    position: sticky;
    z-index: 50;
    top: 0;
    display: flex;
    min-height: var(--header-height);
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 12px clamp(20px, 4vw, 64px);
    border-bottom: 1px solid var(--line);
    background: rgb(255 255 255 / 94%);
    backdrop-filter: blur(18px);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--ink);
    font-size: clamp(1.25rem, 2vw, 1.55rem);
    font-weight: 900;
    letter-spacing: -0.045em;
    text-decoration: none;
}

.brand-mark {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    border: 3px solid var(--line);
    border-radius: 50%;
    background: var(--yellow);
}

.brand-mark span {
    position: absolute;
    display: block;
    border-radius: 50%;
    background: var(--ink);
}

.brand-mark span:nth-child(1) {
    width: 8px;
    height: 8px;
    top: 7px;
    left: 7px;
}

.brand-mark span:nth-child(2) {
    width: 11px;
    height: 11px;
    right: 6px;
    bottom: 6px;
}

.brand-mark span:nth-child(3) {
    width: 5px;
    height: 5px;
    right: 8px;
    top: 8px;
    background: var(--paper);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-search-button,
.header-filter-button,
.header-auth-button,
.header-notifications-button {
    position: relative;
    display: grid;
    width: 42px;
    height: 42px;
    padding: 0;
    place-items: center;
    border: 1px solid var(--control-line);
    border-radius: 50%;
    background: var(--paper);
    color: var(--ink);
    cursor: pointer;
}

.header-search-button .ui-icon,
.header-filter-button .ui-icon,
.header-auth-button .ui-icon,
.header-notifications-button .ui-icon {
    width: 21px;
    height: 21px;
}

.header-search-button:hover,
.header-filter-button:hover,
.header-auth-button:hover,
.header-notifications-button:hover {
    background: var(--yellow-soft);
}

.header-filter-button.is-active,
.header-notifications-button.is-active {
    border-color: var(--control-line);
    background: var(--yellow-soft);
    box-shadow: inset 0 0 0 1px var(--control-line);
}

.header-notifications-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    display: inline-flex;
    min-width: 19px;
    height: 19px;
    padding: 0 5px;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--paper);
    border-radius: 999px;
    background: var(--yellow);
    color: var(--ink);
    font-size: 0.65rem;
    font-weight: 950;
    line-height: 1;
}

.header-filter-button:disabled {
    cursor: wait;
    opacity: 0.45;
}

.mobile-user-menu-button {
    display: none;
    width: 42px;
    height: 42px;
    padding: 0;
    place-items: center;
    border: 1px solid var(--control-line);
    border-radius: 50%;
    background: var(--yellow);
    color: var(--ink);
    cursor: pointer;
}

.mobile-user-avatar {
    font-size: 0.88rem;
    font-weight: 950;
    line-height: 1;
}

.install-action {
    min-height: 40px;
    padding: 0 18px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 2px solid var(--control-line);
    border-radius: 999px;
    background: var(--yellow);
    color: var(--ink);
    cursor: pointer;
    font-size: 0.83rem;
    font-weight: 900;
    transition: transform 160ms ease, background-color 160ms ease;
}

.install-action-icon {
    width: 18px;
    height: 18px;
}

.install-action:hover {
    transform: translateY(-2px);
    background: var(--paper);
}

main {
    min-height: calc(100dvh - var(--header-height));
}

.auth-dialog {
    width: min(1120px, calc(100% - 40px));
    max-width: 100%;
    max-height: calc(100dvh - 40px);
    margin: auto;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--paper);
    color: var(--ink);
}

.auth-dialog::backdrop {
    background: rgb(17 17 17 / 42%);
}

.auth-dialog-surface {
    position: relative;
    max-height: inherit;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.auth-dialog-close {
    position: absolute;
    z-index: 3;
    top: 14px;
    right: 14px;
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    padding: 0;
    border: 1px solid var(--control-line);
    border-radius: 50%;
    background: var(--paper);
    color: var(--ink);
    cursor: pointer;
}

.auth-view {
    position: relative;
    display: grid;
    min-height: 0;
    grid-template-columns: minmax(0, 1fr) minmax(390px, 480px);
    align-items: start;
    gap: clamp(36px, 5vw, 72px);
    padding: clamp(52px, 6vw, 76px) clamp(28px, 5vw, 64px) clamp(36px, 5vw, 60px);
    background:
        linear-gradient(90deg, transparent 0 74%, rgb(255 221 0 / 16%) 74% 100%),
        var(--paper);
}

.auth-intro {
    position: relative;
    isolation: isolate;
    max-width: 780px;
    padding: clamp(10px, 1.5vw, 24px) 0;
}

.eyebrow {
    margin: 0 0 14px;
    color: var(--ink);
    font-size: 0.76rem;
    font-weight: 950;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.auth-intro > .eyebrow,
.auth-intro > .auth-intro-title,
.auth-intro > .intro-copy,
.auth-intro > .flow-list {
    position: relative;
    z-index: 1;
    max-width: 620px;
}

.auth-intro-title,
.section-heading h1,
.section-heading h2 {
    margin: 0;
    color: var(--ink);
    font-weight: 950;
    letter-spacing: -0.055em;
    line-height: 0.98;
}

.auth-intro-title {
    max-width: 700px;
    font-size: clamp(2.75rem, 4.5vw, 5.1rem);
}

.intro-copy {
    margin: 26px 0 0;
    max-width: 560px;
    font-size: clamp(1.05rem, 1.5vw, 1.3rem);
    font-weight: 650;
    line-height: 1.5;
}

.flow-list {
    display: grid;
    max-width: 620px;
    margin: clamp(34px, 6vw, 68px) 0 0;
    padding: 0;
    gap: 0;
    list-style: none;
}

.flow-list li {
    display: grid;
    grid-template-columns: 48px 1fr;
    align-items: center;
    gap: 16px;
    padding: 14px 0;
    border-top: 2px solid var(--line);
    font-size: 0.95rem;
    font-weight: 800;
}

.flow-list li:last-child {
    border-bottom: 2px solid var(--line);
}

.flow-list li > :first-child {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: var(--yellow);
    color: var(--ink);
    font-size: 0.72rem;
    font-weight: 950;
}

.auth-panel {
    position: relative;
    width: 100%;
    max-width: 520px;
    justify-self: end;
    padding: clamp(24px, 4vw, 42px);
    border: 2px solid var(--line);
    border-radius: var(--radius-xl);
    background: var(--paper);
}

.auth-return-notice {
    margin: 0 0 18px;
    padding: 12px 14px;
    border-radius: 16px;
    background: var(--yellow-soft);
    color: var(--ink);
    font-size: 0.82rem;
    font-weight: 800;
}

.auth-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
    margin: 0 0 34px;
    padding: 4px;
    border-radius: 999px;
    background: var(--surface);
}

.auth-tab {
    min-height: 48px;
    padding: 0 18px;
    border: 1px solid transparent;
    border-radius: 999px;
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 900;
    transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.auth-tab:hover {
    color: var(--ink);
}

.auth-tab.is-active {
    border-color: var(--control-line);
    background: var(--yellow);
    color: var(--ink);
}

.google-auth-entry {
    display: grid;
    justify-items: center;
    gap: 8px;
    margin: -18px 0 24px;
}

.google-auth-status {
    margin: 0;
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 800;
}

.google-signin-button {
    display: grid;
    width: 100%;
    min-height: 44px;
    place-items: center;
}

.auth-form-panel {
    animation: panel-in 280ms cubic-bezier(0.2, 0.75, 0.25, 1) both;
}

.registration-topic-field {
    display: grid;
    gap: 10px;
    margin: 0 0 18px;
    padding: 0;
    border: 0;
}

.registration-topic-field legend {
    margin-bottom: 4px;
    color: var(--ink);
    font-size: 0.82rem;
    font-weight: 900;
}

.registration-topic-field .form-hint,
.registration-topic-status {
    margin: 0;
    color: var(--muted);
    font-size: 0.76rem;
    line-height: 1.45;
}

.registration-topic-choices,
.topic-interest-choices {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
}

.topic-choice {
    display: flex;
    min-width: 0;
    min-height: 40px;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border: 1px solid var(--control-line);
    border-radius: 12px;
    background: var(--paper);
    color: var(--ink);
    cursor: pointer;
    font-size: 0.76rem;
    font-weight: 800;
    line-height: 1.2;
}

.topic-choice:has(input:checked) {
    border-color: var(--ink);
    background: var(--yellow-soft);
    box-shadow: inset 0 0 0 1px var(--ink);
}

.topic-choice input {
    width: 17px;
    height: 17px;
    flex: 0 0 17px;
    margin: 0;
    accent-color: var(--yellow);
}

.topic-choice:has(input:focus-visible) {
    outline: 3px solid var(--focus-ring);
    outline-offset: 2px;
}

.topic-choice:has(input:disabled) {
    cursor: not-allowed;
    opacity: 0.52;
}

.section-heading {
    max-width: 760px;
}

.section-heading.compact {
    margin-bottom: 28px;
}

.section-heading h1 {
    font-size: clamp(2.4rem, 5vw, 5.4rem);
}

.section-heading h2 {
    font-size: clamp(2.15rem, 4vw, 4.2rem);
}

.section-heading.compact h2 {
    font-size: clamp(1.6rem, 2.2vw, 2.3rem);
}

.section-heading > p:last-child {
    max-width: 650px;
    margin: 16px 0 0;
    color: var(--muted);
    font-size: 1rem;
    font-weight: 560;
}

form {
    margin: 0;
}

.field {
    display: grid;
    gap: 9px;
    margin-bottom: 18px;
    color: var(--ink);
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.015em;
}

.field input,
.field textarea,
.field select {
    width: 100%;
    min-height: 54px;
    padding: 14px 16px;
    border: 1px solid var(--control-line);
    border-radius: var(--radius-sm);
    outline: none;
    background: var(--surface);
    color: var(--ink);
    font-size: 1rem;
    font-weight: 650;
    letter-spacing: 0;
    transition: border-color 160ms ease, background-color 160ms ease;
}

.field textarea {
    min-height: 132px;
    resize: vertical;
    line-height: 1.55;
}

.field select {
    cursor: pointer;
}

.field select:invalid {
    color: var(--muted);
}

.field input:hover,
.field textarea:hover,
.field select:hover {
    border-color: var(--control-line);
}

.field input:focus,
.field textarea:focus,
.field select:focus {
    border-color: var(--control-line);
    background: var(--paper);
    outline: 3px solid var(--focus-ring);
    outline-offset: 2px;
}

.field input::placeholder,
.field textarea::placeholder,
.global-search-field input::placeholder,
.catalog-filter-form input::placeholder {
    color: var(--muted);
    opacity: 1;
}

.form-hint,
.form-error,
.form-notice {
    margin: 12px 0 0;
    font-size: 0.84rem;
    line-height: 1.5;
}

.form-hint {
    color: var(--muted);
}

.form-error,
.form-notice {
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--yellow-soft);
    color: var(--ink);
    font-weight: 750;
}

.form-assist-row,
.resend-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.password-actions {
    margin: -7px 0 18px;
}

.password-only-action {
    justify-content: flex-end;
}

.resend-row {
    flex-wrap: wrap;
    margin-top: 22px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.88rem;
}

.verification-illustration {
    display: grid;
    width: 76px;
    height: 76px;
    place-items: center;
    margin: 26px 0;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: var(--yellow);
    color: var(--ink);
    font-size: 1.9rem;
}

.primary-action {
    display: flex;
    width: 100%;
    min-height: 56px;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 24px;
    padding: 0 20px;
    border: 2px solid var(--control-line);
    border-radius: 18px;
    background: var(--yellow);
    color: var(--ink);
    cursor: pointer;
    font-size: 1rem;
    font-weight: 950;
    transition: transform 160ms ease, background-color 160ms ease;
}

.primary-action:hover:not(:disabled) {
    transform: translateY(-3px);
    background: var(--paper);
}

.primary-action:active:not(:disabled) {
    transform: translateY(0);
}

.primary-action:disabled,
.icon-action:disabled,
.row-action:disabled {
    cursor: wait;
    opacity: 0.48;
}

.text-action,
.icon-action,
.nav-action,
.row-action {
    border: 0;
    background: transparent;
    cursor: pointer;
    text-decoration: none;
}

.text-action {
    padding: 4px 0;
    color: var(--ink);
    font-size: 0.86rem;
    font-weight: 900;
    text-decoration: underline;
    text-decoration-color: var(--yellow);
    text-decoration-thickness: 4px;
    text-underline-offset: 3px;
}

.text-action:hover {
    text-decoration-color: var(--ink);
}

.back-action {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
}

.workspace-view {
    display: grid;
    width: min(1480px, 100%);
    min-height: calc(100dvh - var(--header-height));
    grid-template-columns: 278px minmax(0, 1fr);
    gap: 24px;
    margin: 0 auto;
    padding: 24px clamp(20px, 4vw, 64px) 80px;
}

.workspace-view.is-anonymous {
    grid-template-columns: minmax(0, 1fr);
}

.workspace-view.is-anonymous .workspace-sidebar {
    display: none;
}

.workspace-sidebar {
    position: sticky;
    top: calc(var(--header-height) + 24px);
    display: flex;
    height: fit-content;
    max-height: calc(100dvh - var(--header-height) - 48px);
    flex-direction: column;
    padding: 20px;
    border: 1px solid var(--control-line);
    border-radius: var(--radius-lg);
    background: var(--paper);
    min-width: 0;
    overflow-x: hidden;
}

.member-summary {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr);
    align-items: center;
    gap: 13px;
    padding: 4px 4px 22px;
    border-bottom: 1px solid var(--line);
}

.member-avatar {
    display: grid;
    width: 54px;
    height: 54px;
    place-items: center;
    border: 2px solid var(--line);
    border-radius: 50%;
    background: var(--yellow);
    color: var(--ink);
    font-size: 1.15rem;
    font-weight: 950;
}

.member-summary div {
    min-width: 0;
}

.member-summary strong,
.member-summary div span {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.member-summary strong {
    font-size: 0.95rem;
    font-weight: 900;
}

.member-summary div span {
    margin-top: 3px;
    color: var(--muted);
    font-size: 0.76rem;
}

.workspace-nav {
    display: grid;
    min-width: 0;
    margin-top: 18px;
    gap: 5px;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
}

.workspace-nav-shell {
    display: contents;
}

.nav-action {
    display: grid;
    min-height: 48px;
    grid-template-columns: 30px 1fr;
    align-items: center;
    gap: 8px;
    padding: 0 14px;
    border-radius: 999px;
    color: var(--muted);
    text-align: left;
    font-size: 0.86rem;
    font-weight: 850;
    transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
    min-width: 0;
}

.nav-action:hover {
    background: var(--surface);
    color: var(--ink);
}

.nav-action.is-active {
    background: var(--yellow);
    color: var(--ink);
    box-shadow: inset 0 0 0 1px var(--control-line);
    transform: translateX(3px);
}

.nav-action-icon {
    width: 28px;
    height: 28px;
    padding: 5px;
    border-radius: 50%;
    background: var(--paper);
    color: var(--ink);
}

.nav-action > span:last-child {
    min-width: 0;
}

.logout-action {
    align-self: flex-start;
    margin: 20px 6px 2px;
}

.user-settings-dialog {
    width: min(420px, calc(100% - 28px));
    max-width: 100%;
    max-height: min(680px, calc(100dvh - 28px));
    margin: auto;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 26px;
    background: var(--paper);
    color: var(--ink);
}

.user-settings-dialog::backdrop {
    background: rgb(17 17 17 / 42%);
}

.user-settings-surface {
    display: grid;
    max-height: inherit;
    grid-template-rows: auto minmax(0, 1fr);
}

.user-settings-header {
    display: flex;
    min-height: 64px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 12px 14px 12px 22px;
    border-bottom: 1px solid var(--line);
}

.user-settings-header h2 {
    margin: 0;
    font-size: 1.12rem;
    font-weight: 920;
    letter-spacing: -0.025em;
}

.user-settings-close {
    display: grid;
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    place-items: center;
    padding: 0;
    border: 1px solid var(--control-line);
    border-radius: 50%;
    background: var(--paper);
    color: var(--ink);
    cursor: pointer;
}

.user-settings-body {
    display: grid;
    gap: 18px;
    padding: 20px 22px 22px;
    overflow-y: auto;
}

.user-settings-identity {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    align-items: center;
    gap: 13px;
}

.user-settings-avatar {
    display: grid;
    width: 52px;
    height: 52px;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: var(--yellow);
    font-size: 1rem;
    font-weight: 950;
}

.user-settings-identity div {
    min-width: 0;
}

.user-settings-identity strong,
.user-settings-identity div span {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-settings-identity strong {
    font-size: 0.94rem;
    font-weight: 900;
}

.user-settings-identity div span {
    margin-top: 3px;
    color: var(--muted);
    font-size: 0.76rem;
}

.user-settings-actions {
    display: grid;
    border-top: 1px solid var(--line);
}

.user-settings-actions button {
    display: grid;
    min-height: 54px;
    grid-template-columns: 28px minmax(0, 1fr) auto;
    align-items: center;
    gap: 9px;
    padding: 0 2px;
    border-bottom: 1px solid var(--line);
    color: var(--ink);
    cursor: pointer;
    text-align: left;
    font-size: 0.85rem;
    font-weight: 850;
}

.user-settings-action-icon {
    width: 28px;
    height: 28px;
    padding: 5px;
    border-radius: 50%;
    background: var(--surface);
}

.user-settings-action-arrow {
    width: 17px;
    height: 17px;
    color: var(--muted);
}

.user-settings-logout {
    justify-self: start;
}

.user-settings-return {
    display: inline-flex;
    min-height: 44px;
    width: fit-content;
    align-items: center;
    gap: 8px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--paper);
    color: var(--ink);
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 850;
}

.user-settings-return:hover {
    background: var(--yellow-soft);
}

.search-dialog,
.catalog-filter-dialog {
    width: min(760px, calc(100% - 28px));
    max-width: 100%;
    max-height: min(820px, calc(100dvh - 28px));
    margin: auto;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 26px;
    background: var(--paper);
    color: var(--ink);
}

.search-dialog::backdrop,
.catalog-filter-dialog::backdrop {
    background: rgb(17 17 17 / 42%);
}

.search-dialog-surface,
.catalog-filter-dialog-surface {
    display: grid;
    max-height: inherit;
    grid-template-rows: auto minmax(0, 1fr);
}

.search-dialog-header,
.catalog-filter-dialog-header {
    display: flex;
    min-height: 64px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 12px 14px 12px 22px;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
}

.search-dialog-header h2,
.catalog-filter-dialog-header h2 {
    margin: 0;
    font-size: 1.12rem;
    font-weight: 920;
    letter-spacing: -0.025em;
}

.search-dialog-close,
.catalog-filter-dialog-close {
    display: grid;
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    place-items: center;
    padding: 0;
    border: 1px solid var(--control-line);
    border-radius: 50%;
    background: var(--paper);
    color: var(--ink);
    cursor: pointer;
}

.search-dialog-body,
.catalog-filter-dialog-body {
    min-width: 0;
    min-height: 0;
    padding: 20px 22px 24px;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.catalog-filter-dialog {
    width: min(560px, calc(100% - 28px));
}

.global-search-form {
    display: grid;
    gap: 14px;
}

.global-search-scope {
    display: flex;
    min-width: 0;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: 0;
    border: 0;
}

.global-search-scope legend {
    width: 100%;
    margin-bottom: 2px;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 850;
}

.global-search-scope label {
    display: inline-flex;
    min-height: 40px;
    align-items: center;
    gap: 7px;
    padding: 0 13px;
    border: 1px solid var(--control-line);
    border-radius: 999px;
    background: var(--paper);
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 850;
}

.global-search-scope label:has(input:checked) {
    border-color: var(--ink);
    background: var(--yellow-soft);
    box-shadow: inset 0 0 0 1px var(--ink);
}

.global-search-fields {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(150px, 0.42fr) minmax(150px, 0.42fr);
    gap: 10px;
}

.global-search-field {
    display: grid;
    min-width: 0;
    gap: 7px;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 850;
}

.global-search-field input,
.global-search-field select {
    min-width: 0;
    height: 46px;
    padding: 0 13px;
    border: 1px solid var(--control-line);
    border-radius: var(--radius-sm);
    background: var(--paper);
    color: var(--ink);
}

.global-search-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
}

.global-search-submit {
    min-height: 44px;
    padding: 0 18px;
    border: 1px solid var(--control-line);
    border-radius: 999px;
    background: var(--yellow);
    color: var(--ink);
    cursor: pointer;
    font-size: 0.82rem;
    font-weight: 900;
}

.global-search-error,
.global-search-empty {
    margin: 18px 0 0;
    padding: 15px 0 0;
    border-top: 1px solid var(--line);
    color: var(--muted);
}

.global-search-results {
    display: grid;
    gap: 20px;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
}

.global-search-group {
    display: grid;
    gap: 0;
}

.global-search-group h3 {
    margin: 0;
    padding-bottom: 8px;
    color: var(--muted);
    font-size: 0.75rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.global-search-result {
    position: relative;
    display: grid;
    gap: 5px;
    padding: 14px 34px 14px 0;
    border-top: 1px solid var(--line);
    color: var(--ink);
    text-decoration: none;
}

.global-search-result-icon {
    position: absolute;
    top: 50%;
    right: 5px;
    width: 17px;
    height: 17px;
    color: var(--muted);
    transform: translateY(-50%);
}

.global-search-result strong {
    font-size: 0.96rem;
    font-weight: 900;
    line-height: 1.25;
}

.global-search-result-meta {
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 800;
}

.global-search-result p {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.4;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.workspace-main {
    min-width: 0;
}

.workspace-status {
    margin-bottom: 18px;
    padding: 16px 18px;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--yellow-soft);
    color: var(--ink);
    font-weight: 800;
}

.content-list {
    display: grid;
    gap: 14px;
}

.catalog-tabs,
.profile-tabs {
    display: inline-flex;
    width: fit-content;
    max-width: 100%;
    align-items: stretch;
    gap: 4px;
    margin-bottom: 16px;
    padding: 4px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
}

.catalog-tab,
.profile-tab {
    min-height: 42px;
    padding: 8px 18px;
    appearance: none;
    border: 1px solid transparent;
    border-radius: 999px;
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 900;
    line-height: 1.1;
    white-space: nowrap;
    transition: background-color 160ms ease, color 160ms ease;
}

.catalog-tab:hover,
.profile-tab:hover {
    color: var(--ink);
}

.catalog-tab.is-active,
.profile-tab.is-active {
    border-color: var(--control-line);
    background: var(--yellow);
    color: var(--ink);
}

.catalog-tab:focus-visible,
.profile-tab:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: 2px;
}

.content-list.is-catalog {
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 14px;
}

.content-list.is-catalog > * {
    grid-column: 1;
}

.content-list.is-feed {
    max-width: 900px;
}

.community-catalog-back {
    width: fit-content;
    min-height: 44px;
    justify-self: start;
    margin-bottom: 0;
    padding: 8px 4px;
}

.community-catalog-back .ui-icon {
    width: 18px;
    height: 18px;
}

.information-feed-heading {
    display: grid;
    gap: 5px;
    margin-bottom: 4px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--line);
}

.information-feed-heading h2,
.information-feed-heading p {
    margin: 0;
}

.information-feed-heading h2 {
    font-size: clamp(1.35rem, 2.4vw, 1.8rem);
    font-weight: 930;
    letter-spacing: -0.035em;
}

.information-feed-heading p {
    color: var(--muted);
    font-size: 0.86rem;
}

.information-feed-list {
    display: grid;
    gap: 14px;
}

.information-feed-empty {
    padding: 26px 0;
    border-bottom: 1px solid var(--line);
}

.information-feed-empty h3,
.information-feed-empty p {
    margin: 0;
}

.information-feed-empty h3 {
    font-size: 1.05rem;
}

.information-feed-empty p {
    max-width: 620px;
    margin-top: 7px;
    color: var(--muted);
    line-height: 1.5;
}

.feed-load-more {
    width: fit-content;
    min-height: 42px;
    justify-self: center;
    padding: 0 18px;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: var(--paper);
    color: var(--ink);
    cursor: pointer;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 900;
}

.feed-load-more:hover {
    background: var(--yellow-soft);
}

.feed-interests-required {
    padding: 22px 0 0;
}

.catalog-filter-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    padding: 0;
    border: 0;
    background: transparent;
}

.catalog-filter-form input,
.catalog-filter-form select {
    min-width: 0;
    height: 46px;
    padding: 0 13px;
    border: 1px solid var(--control-line);
    border-radius: var(--radius-sm);
    background: var(--paper);
    color: var(--ink);
    font: inherit;
}

.catalog-filter-footer {
    display: grid;
    gap: 12px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
    color: var(--muted);
}

.catalog-filter-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
}

.catalog-filter-apply {
    width: auto;
    min-height: 44px;
    justify-content: center;
    margin: 0;
    padding: 0 18px;
    border-width: 1px;
    border-radius: 14px;
    font-size: 0.82rem;
}

.catalog-no-results {
    margin: 0;
    padding: 28px;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--paper);
    color: var(--muted);
    text-align: center;
}

.community-card {
    position: relative;
    display: grid;
    min-height: 0;
    grid-template-columns: 216px minmax(0, 1fr);
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--paper);
    transition: transform 180ms ease, border-color 180ms ease;
}

.community-card:has(.community-card-link):hover {
    transform: translateY(-2px);
}

.community-card-media {
    position: relative;
    aspect-ratio: 1;
    overflow: hidden;
}

.community-card-image {
    width: 100%;
    height: 100%;
    min-height: 0;
    object-fit: cover;
}

.community-card-badges {
    position: absolute;
    z-index: 1;
    right: 10px;
    bottom: 10px;
    left: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.community-card-badge {
    display: inline-flex;
    min-height: 28px;
    max-width: 100%;
    align-items: center;
    gap: 5px;
    padding: 4px 8px;
    border: 1px solid rgb(255 255 255 / 72%);
    border-radius: 999px;
    background: rgb(255 255 255 / 92%);
    color: var(--ink);
    font-size: 0.7rem;
    font-weight: 900;
    line-height: 1;
    backdrop-filter: blur(8px);
}

.community-card-badge.is-policy-open {
    border-color: #cbe6d0;
    background: rgb(238 248 240 / 94%);
    color: #245333;
}

.community-card-badge.is-policy-request {
    border-color: #f1d3ab;
    background: rgb(255 243 227 / 94%);
    color: #784715;
}

.community-card-badge-icon {
    width: 14px;
    height: 14px;
    flex: 0 0 14px;
    fill: none;
    stroke: currentcolor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.community-card-body {
    display: flex;
    min-width: 0;
    flex-direction: column;
    padding: 18px 20px;
}

.community-card-body h2 {
    margin: 10px 0 0;
    font-size: clamp(1.2rem, 1.7vw, 1.55rem);
    font-weight: 920;
    letter-spacing: -0.03em;
    line-height: 1.12;
}

.community-card-leaders {
    flex: 1 1 100%;
    min-width: 0;
    color: var(--ink);
    overflow-wrap: anywhere;
}

.community-card-description {
    display: -webkit-box;
    max-width: 660px;
    margin: 8px 0 0;
    overflow: hidden;
    color: var(--muted);
    font-size: 0.9rem;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.community-topic-field {
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.community-topic-field legend {
    margin-bottom: 9px;
    font-weight: 850;
}

.community-topic-choices {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.community-topic-choice {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 12px;
    border: 1px solid var(--control-line);
    border-radius: 999px;
    background: var(--paper);
    color: var(--ink);
    font-weight: 760;
}

.community-topic-choice:has(input:checked) {
    border-color: var(--ink);
    background: var(--yellow-soft);
    box-shadow: inset 0 0 0 1px var(--ink);
}

.community-card .row-actions {
    position: relative;
    z-index: 3;
    max-width: none;
    justify-content: flex-start;
    margin-top: auto;
    padding-top: 14px;
}

.community-card .row-actions:empty {
    display: none;
}

.community-card-link {
    position: absolute;
    z-index: 2;
    inset: 0;
    padding: 0;
    border: 0;
    border-radius: inherit;
    background: transparent;
    cursor: pointer;
}

.community-card-link:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: -4px;
}

.community-profile {
    display: grid;
    grid-template-columns: clamp(136px, 15vw, 156px) minmax(0, 1fr);
    align-items: start;
    gap: 16px;
    padding: 16px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--surface);
}

.community-profile-image {
    width: 100%;
    height: clamp(136px, 15vw, 156px);
    aspect-ratio: 1;
    border-radius: var(--radius-md);
    object-fit: cover;
}

.community-profile-content {
    min-width: 0;
}

.community-profile-content .row-meta {
    gap: 5px 10px;
    margin-bottom: 0;
    font-size: 0.68rem;
}

.community-profile-content h2 {
    margin: 5px 0 0;
    font-size: clamp(1.35rem, 2.1vw, 1.9rem);
    font-weight: 930;
    letter-spacing: -0.04em;
    line-height: 1.06;
}

.community-profile-description {
    max-width: 760px;
    margin: 6px 0 0;
    color: var(--muted);
    font-size: 0.86rem;
    line-height: 1.4;
}

.community-profile-facts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin: 12px 0 0;
}

.community-profile-facts div {
    min-width: 0;
    padding: 7px 0 0;
    border-top: 1px solid var(--line);
}

.community-profile-facts dt {
    color: var(--muted);
    font-size: 0.62rem;
    font-weight: 850;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.community-profile-facts dd {
    margin: 3px 0 0;
    font-size: 0.78rem;
    font-weight: 850;
    line-height: 1.25;
}

.community-profile-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 8px;
}

.share-action {
    gap: 8px;
}

.share-action .ui-icon {
    width: 17px;
    height: 17px;
}

.community-feed {
    scroll-margin-top: calc(var(--header-height) + 24px);
    padding-top: 20px;
}

.community-feed-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
}

.community-feed-title {
    margin: 0;
    font-size: clamp(1.35rem, 2.4vw, 1.8rem);
    font-weight: 930;
    letter-spacing: -0.035em;
}

.publish-open-action {
    width: auto;
    min-height: 42px;
    flex: 0 0 auto;
    gap: 14px;
    margin: 0;
    padding: 0 15px;
    border-width: 1px;
    border-radius: 13px;
    font-size: 0.82rem;
}

.publish-open-icon {
    width: 18px;
    height: 18px;
}

.community-feed-list {
    display: grid;
    gap: 14px;
}

.community-post-preview {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: center;
    gap: 18px;
    padding: 16px 18px 16px 22px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--paper);
    transition: transform 180ms ease, background-color 180ms ease;
}

.community-post-preview.has-media {
    grid-template-columns: minmax(136px, 168px) minmax(0, 1fr);
}

.post-preview-media {
    position: relative;
    min-height: 102px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--surface);
    aspect-ratio: 4 / 3;
}

.post-preview-media img {
    width: 100%;
    height: 100%;
    opacity: 0;
    object-fit: cover;
    transition: opacity 180ms ease;
}

.post-preview-media img.is-loaded {
    opacity: 1;
}

.post-preview-video {
    display: grid;
    place-items: center;
    isolation: isolate;
    color: var(--muted);
}

.post-preview-media img.post-preview-video-poster {
    opacity: 1;
}

.post-preview-play {
    position: absolute;
    z-index: 1;
    top: 50%;
    left: 50%;
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 14px;
    background: var(--yellow);
    color: var(--ink);
    transform: translate(-50%, -50%);
}

.post-preview-play svg {
    width: 25px;
    height: 21px;
}

.post-preview-media-summary {
    position: absolute;
    z-index: 2;
    right: 8px;
    bottom: 8px;
    left: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.post-preview-media-badge {
    display: inline-flex;
    min-height: 24px;
    align-items: center;
    padding: 4px 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgb(255 255 255 / 92%);
    color: var(--ink);
    font-size: 0.62rem;
    font-weight: 900;
    line-height: 1;
    backdrop-filter: blur(8px);
}

.post-preview-media-badge.is-video {
    gap: 3px;
    background: rgb(255 216 0 / 94%);
}

.post-preview-media-badge svg {
    width: 13px;
    height: 11px;
}

.community-post-preview::before {
    position: absolute;
    top: 18px;
    bottom: 18px;
    left: 0;
    width: 4px;
    border-radius: 0 4px 4px 0;
    background: var(--yellow);
    content: "";
}

.community-post-preview:hover {
    transform: translateY(-2px);
    background: var(--surface);
}

.community-post-preview-content {
    min-width: 0;
}

.post-preview-community-chip {
    display: inline-flex;
    min-width: 0;
    max-width: min(44%, 260px);
    min-height: 28px;
    flex: 1 1 auto;
    align-items: center;
    gap: 6px;
    padding: 1px 8px 1px 1px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    color: var(--ink);
}

.post-preview-community-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.post-preview-community-image {
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    border-radius: 50%;
    object-fit: cover;
}

.post-preview-discovery {
    display: inline-flex;
    min-height: 24px;
    align-items: center;
    padding: 3px 8px;
    border-radius: 999px;
    background: var(--yellow-soft);
    color: var(--ink);
    font-size: 0.66rem;
    font-weight: 900;
}

.post-preview-meta {
    display: flex;
    min-width: 0;
    flex-wrap: nowrap;
    align-items: center;
    gap: 6px;
    overflow: hidden;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 800;
    white-space: nowrap;
}

.post-preview-date,
.post-preview-meta-separator {
    flex: 0 0 auto;
}

.post-preview-meta-separator {
    color: var(--line-strong);
    font-weight: 700;
}

.post-preview-type {
    min-width: 0;
    flex: 0 0 auto;
    overflow: hidden;
    color: var(--muted);
    font-weight: 900;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.post-publication-type {
    display: inline-flex;
    align-items: center;
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--yellow);
    color: var(--ink);
    font-size: 0.74rem;
    font-weight: 900;
}

.post-publication-compact {
    display: none;
}

.community-post-preview p {
    display: -webkit-box;
    margin: 8px 0 0;
    overflow: hidden;
    color: var(--muted);
    font-size: 0.9rem;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.community-post-preview .post-preview-excerpt {
    margin-top: 9px;
    color: var(--ink);
    font-size: 0.98rem;
    font-weight: 650;
    line-height: 1.5;
    -webkit-line-clamp: 2;
}

.community-post-preview-link {
    position: absolute;
    inset: 0;
    padding: 0;
    border: 0;
    border-radius: inherit;
    background: transparent;
    cursor: pointer;
}

.community-post-preview-link:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: -4px;
}

.community-feed-no-results {
    margin: 0;
    padding: 28px;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--surface);
    color: var(--muted);
    text-align: center;
}

.community-feed-empty,
.community-feed-access {
    display: grid;
    min-height: 150px;
    place-items: start;
    align-content: center;
    gap: 12px;
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--surface);
}

.community-feed-empty h3,
.community-feed-empty p,
.community-feed-access p {
    margin: 0;
}

.community-feed-empty p,
.community-feed-access p {
    color: var(--muted);
}

.community-feed-access .row-actions {
    justify-content: flex-start;
}

.content-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 24px;
    padding: clamp(20px, 3vw, 30px);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--paper);
    animation: row-in 300ms cubic-bezier(0.2, 0.75, 0.25, 1) both;
    transition: border-color 160ms ease, transform 160ms ease;
}

.content-row:hover {
    border-color: var(--line);
    transform: translateY(-2px);
}

.row-content {
    min-width: 0;
}

.row-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    margin-bottom: 10px;
    color: var(--muted);
    font-size: 0.74rem;
    font-weight: 850;
    letter-spacing: 0.025em;
}

.row-content h2 {
    margin: 0;
    color: var(--ink);
    font-size: clamp(1.25rem, 2vw, 1.65rem);
    font-weight: 920;
    letter-spacing: -0.035em;
    line-height: 1.1;
}

.row-content p {
    max-width: 760px;
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 0.94rem;
    line-height: 1.55;
}

.row-actions {
    display: flex;
    max-width: 360px;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.row-action {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--paper);
    color: var(--ink);
    font-size: 0.8rem;
    font-weight: 900;
    transition: transform 160ms ease, background-color 160ms ease;
}

.row-action:hover:not(:disabled),
.row-action.is-selected {
    transform: translateY(-2px);
    background: var(--yellow);
}

.row-action.is-muted {
    border-color: var(--control-line);
    color: var(--muted);
}

.row-action.is-muted:hover:not(:disabled),
.row-action.is-muted.is-selected {
    color: var(--ink);
}

.status-label {
    display: inline-flex;
    min-height: 26px;
    align-items: center;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--paper);
    color: var(--ink);
    font-size: 0.7rem;
    font-weight: 900;
}

.status-label.is-pending,
.status-label.is-unread,
.status-label.is-approved {
    background: var(--yellow);
}

.status-label.is-rejected {
    background: var(--surface-strong);
}

.session-control,
.preferences-panel,
.profile-data-panel,
.community-application-submission,
.community-application-history,
.leader-aggregate {
    margin-bottom: 18px;
    padding: clamp(20px, 3vw, 30px);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--surface);
}

.session-control {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.session-control p {
    max-width: 680px;
    margin: 0;
    color: var(--muted);
}

.session-row .row-content h2,
.community-application-row .row-content h2 {
    font-size: 1.12rem;
}

.notification-row {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--paper);
    animation: row-in 300ms cubic-bezier(0.2, 0.75, 0.25, 1) both;
    transition: background-color 160ms ease, border-color 160ms ease;
}

.notification-row:hover,
.notification-row:focus-within {
    background: var(--surface);
}

.notification-row.is-unread {
    border-left: 4px solid var(--yellow);
}

.notification-row-toggle {
    display: block;
    width: 100%;
    padding: clamp(20px, 3vw, 30px);
    border: 0;
    background: transparent;
    color: var(--ink);
    cursor: pointer;
    text-align: left;
}

.notification-row-toggle:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: -5px;
}

.notification-row-title {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    font-size: 1.12rem;
    font-weight: 920;
    letter-spacing: -0.025em;
    line-height: 1.2;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.notification-row.is-expanded .notification-row-title {
    display: block;
    overflow: visible;
    -webkit-line-clamp: unset;
}

.profile-section-intro {
    display: grid;
    gap: 6px;
    margin-bottom: 18px;
}

.profile-section-intro h2,
.profile-section-intro p {
    margin: 0;
}

.profile-section-intro h2 {
    font-size: clamp(1.12rem, 2vw, 1.35rem);
    font-weight: 920;
}

.profile-section-intro p {
    max-width: 680px;
    color: var(--muted);
    font-size: 0.9rem;
}

.profile-data-list {
    display: grid;
    margin: 0;
    border-top: 1px solid var(--line);
}

.profile-data-field {
    display: grid;
    grid-template-columns: minmax(150px, 0.42fr) minmax(0, 1fr);
    gap: 18px;
    padding: 16px 0;
    border-bottom: 1px solid var(--line);
}

.profile-data-field:last-child {
    border-bottom: 0;
}

.profile-data-field dt {
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.profile-data-field dd {
    min-width: 0;
    margin: 0;
    overflow-wrap: anywhere;
    font-size: 0.95rem;
    font-weight: 850;
}

.topic-interests-editor {
    display: grid;
    gap: 14px;
    margin-top: 10px;
    padding-top: 22px;
    border-top: 1px solid var(--line);
}

.topic-interests-heading {
    display: grid;
    gap: 5px;
}

.topic-interests-heading h3,
.topic-interests-heading p {
    margin: 0;
}

.topic-interests-heading h3 {
    font-size: 1rem;
    font-weight: 920;
}

.topic-interests-heading p {
    max-width: 680px;
    color: var(--muted);
    font-size: 0.84rem;
    line-height: 1.45;
}

.topic-interests-form {
    display: grid;
    gap: 14px;
}

.topic-interests-submit {
    width: fit-content;
    min-width: 220px;
    margin: 0;
}

.preferences-form {
    display: grid;
    gap: 18px;
}

.preference-group {
    margin: 0;
    padding: 0;
    border: 0;
}

.preference-group + .preference-group {
    padding-top: 22px;
    border-top: 1px solid var(--line);
}

.preference-group legend {
    margin-bottom: 14px;
    padding: 0;
    font-size: 1.12rem;
    font-weight: 920;
}

.preference-note {
    margin: -4px 0 16px;
    color: var(--muted);
    font-size: 0.86rem;
}

.preference-option {
    display: flex;
    min-height: 62px;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
    cursor: pointer;
}

.preference-option:last-child {
    border-bottom: 0;
}

.preference-copy strong {
    font-size: 0.95rem;
}

.switch-control {
    position: relative;
    flex: 0 0 auto;
}

.switch-control input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.switch-track {
    position: relative;
    display: block;
    width: 54px;
    height: 32px;
    border: 2px solid var(--control-line);
    border-radius: 999px;
    background: var(--paper);
    transition: background-color 160ms ease;
}

.switch-track::after {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--ink);
    content: "";
    transition: transform 180ms cubic-bezier(0.2, 0.75, 0.25, 1);
}

.switch-control input:checked + .switch-track {
    background: var(--yellow);
}

.switch-control input:checked + .switch-track::after {
    transform: translateX(22px);
}

.switch-control input:focus-visible + .switch-track {
    outline: 3px solid var(--focus-ring);
    outline-offset: 3px;
}

.preferences-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-top: 18px;
}

.preferences-updated-at {
    color: var(--muted);
    font-size: 0.82rem;
}

.preferences-save {
    width: auto;
    min-width: 180px;
    margin: 0;
}

.community-application-submission-intro h2,
.community-application-history-heading h2,
.community-application-detail-description h2,
.community-application-decision h2 {
    margin: 0;
    font-size: clamp(1.45rem, 2.6vw, 2.15rem);
    font-weight: 930;
    letter-spacing: -0.035em;
}

.community-application-submission-intro p {
    max-width: 720px;
    margin: 10px 0 0;
    color: var(--muted);
}

.community-application-guidance {
    margin-top: 20px;
    padding: 18px 0;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.community-application-guidance h3,
.community-application-guidance h4 {
    margin: 0;
}

.community-application-guidance h3 {
    font-size: 1rem;
    font-weight: 920;
}

.community-application-guidance-intro {
    max-width: 820px;
    margin: 7px 0 0;
    color: var(--muted);
    font-size: 0.88rem;
}

.community-application-guidance-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    margin-top: 16px;
}

.community-application-guidance-step {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    align-items: start;
    gap: 10px;
}

.community-application-guidance-number {
    display: grid;
    width: 30px;
    height: 30px;
    place-items: center;
    border-radius: 50%;
    background: var(--yellow);
    font-size: 0.68rem;
    font-weight: 920;
}

.community-application-guidance-step h4 {
    font-size: 0.88rem;
    font-weight: 900;
}

.community-application-guidance-step p {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 0.8rem;
    line-height: 1.48;
}

.community-application-guidance-boundary {
    margin: 16px 0 0;
    padding: 10px 12px;
    border-left: 3px solid var(--yellow);
    background: var(--paper);
    color: var(--muted);
    font-size: 0.78rem;
}

.community-application-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 18px;
    margin-top: 24px;
}

.community-application-form .field > label,
.community-application-address-field > label {
    display: grid;
    gap: 9px;
}

.field-label-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.field-help-action,
.community-application-address-suggestion {
    width: fit-content;
    padding: 0;
    border: 0;
    border-bottom: 3px solid var(--yellow);
    background: transparent;
    color: var(--ink);
    cursor: pointer;
    font-size: 0.76rem;
    font-weight: 900;
}

.community-application-address-status,
.community-application-address-path,
.community-application-address-advisory {
    margin: 0;
    font-size: 0.76rem;
    letter-spacing: 0;
}

.community-application-address-status {
    color: var(--muted);
    font-weight: 760;
}

.community-application-address-status.is-generated_available,
.community-application-address-status.is-custom_available {
    color: #28603a;
}

.community-application-address-status.is-taken,
.community-application-address-status.is-reserved,
.community-application-address-status.is-invalid {
    color: #8a431b;
}

.community-application-address-path {
    width: fit-content;
    padding: 5px 9px;
    border-radius: 9px;
    background: var(--paper);
    color: var(--ink);
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    font-weight: 760;
}

.community-application-address-suggestion {
    justify-self: start;
}

.community-type-help-dialog {
    width: min(700px, calc(100% - 28px));
    max-width: 100%;
    max-height: min(820px, calc(100dvh - 28px));
    margin: auto;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 26px;
    background: var(--paper);
    color: var(--ink);
}

.community-type-help-dialog::backdrop {
    background: rgb(17 17 17 / 42%);
}

.community-type-help-surface {
    display: grid;
    max-height: inherit;
    grid-template-rows: auto minmax(0, 1fr);
}

.community-type-help-header {
    display: flex;
    min-height: 64px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 12px 14px 12px 22px;
    border-bottom: 1px solid var(--line);
}

.community-type-help-header h2 {
    margin: 0;
    font-size: 1.12rem;
    font-weight: 920;
}

.community-type-help-close {
    display: grid;
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    place-items: center;
    padding: 0;
    border: 1px solid var(--control-line);
    border-radius: 50%;
    background: var(--paper);
    cursor: pointer;
}

.community-type-help-close .ui-icon {
    width: 18px;
    height: 18px;
}

.community-type-help-body {
    min-height: 0;
    padding: 20px 22px 24px;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.community-type-help-intro {
    margin: 0;
    color: var(--muted);
    font-size: 0.88rem;
}

.community-type-help-list {
    display: grid;
    gap: 0;
    margin: 18px 0 0;
}

.community-type-help-item {
    padding: 14px 0;
    border-top: 1px solid var(--line);
}

.community-type-help-item dt {
    font-weight: 900;
}

.community-type-help-item dd {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 0.84rem;
}

.publish-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
}

.community-application-form .field:first-child,
.community-application-form .community-topic-field,
.community-application-description-field,
.community-application-description-hint,
.community-application-form-error,
.community-application-submit,
.publish-type-field,
.publish-body-field,
.publish-media-grid,
.publish-footer {
    grid-column: 1 / -1;
}

.publish-media-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
    gap: 14px;
}

.publish-form .field {
    min-width: 0;
    align-content: start;
    gap: 6px;
    margin-bottom: 0;
    font-size: 0.76rem;
}

.publish-type-field {
    width: 100%;
    max-width: 420px;
}

.publish-type-field select {
    max-width: none;
    min-height: 42px;
    padding: 8px 12px;
    background: var(--paper);
    font-size: 0.86rem;
}

.publish-reaction-preview {
    max-width: none;
    margin-top: 0;
    font-size: 0.68rem;
    font-weight: 650;
    line-height: 1.35;
}

.publish-editor {
    position: relative;
    overflow: visible;
    border: 1px solid var(--control-line);
    border-radius: var(--radius-sm);
    background: var(--paper);
}

.publish-editor:focus-within {
    outline: 3px solid var(--focus-ring);
    outline-offset: 2px;
}

.publish-editor-toolbar {
    display: flex;
    min-height: 38px;
    align-items: center;
    gap: 5px;
    padding: 5px 7px;
    border-bottom: 1px solid var(--line);
}

.publish-editor-action,
.publish-emoji-option {
    display: grid;
    width: 30px;
    height: 28px;
    place-items: center;
    padding: 0;
    border: 1px solid var(--control-line);
    border-radius: 8px;
    background: var(--surface);
    color: var(--ink);
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 800;
}

.publish-editor-action:hover,
.publish-emoji-option:hover {
    background: var(--yellow);
}

.publish-editor-action.is-bold {
    font-weight: 950;
}

.publish-editor-action.is-italic {
    font-style: italic;
}

.publish-editor-action.is-underline {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.publish-emoji-toggle {
    margin-left: auto;
    font-size: 1rem;
}

.publish-emoji-picker {
    position: absolute;
    z-index: 3;
    top: 42px;
    right: 7px;
    display: grid;
    grid-template-columns: repeat(6, 30px);
    gap: 5px;
    padding: 7px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--paper);
}

.publish-emoji-option {
    background: var(--paper);
    font-size: 1rem;
}

.field .publish-editor textarea,
.field .publish-editor textarea:hover,
.field .publish-editor textarea:focus {
    min-height: 108px;
    padding: 12px 14px;
    border: 0;
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
    outline: 0;
    background: var(--paper);
    font-size: 0.94rem;
    font-weight: 600;
    line-height: 1.5;
}

.publish-video-field input {
    min-height: 42px;
    padding: 8px 12px;
    background: var(--paper);
    font-size: 0.86rem;
}

.publish-media-field,
.publish-video-field {
    min-width: 0;
    align-self: start;
    align-content: start;
}

.field-hint {
    display: block;
    margin-top: 7px;
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 650;
}

.publish-media-field input[type="file"] {
    min-height: 42px;
    padding: 6px;
    border: 1px solid var(--control-line);
    border-radius: var(--radius-sm);
    background: var(--paper);
    font-size: 0.76rem;
}

.publish-media-field input[type="file"]::file-selector-button {
    margin-right: 8px;
    padding: 6px 10px;
    border: 1px solid var(--control-line);
    border-radius: 999px;
    background: var(--paper);
    color: var(--ink);
    font-weight: 800;
    cursor: pointer;
}

.publish-image-preview {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(52px, 1fr));
    gap: 8px;
    margin-top: 12px;
}

.publish-image-preview:empty {
    display: none;
}

.publish-image-item {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface);
    aspect-ratio: 1;
}

.publish-image-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.publish-image-item span {
    position: absolute;
    right: 6px;
    bottom: 6px;
    display: grid;
    width: 22px;
    height: 22px;
    place-items: center;
    border-radius: 50%;
    background: var(--yellow);
    color: var(--ink);
    font-size: 0.7rem;
    font-weight: 900;
}

.community-application-description-hint {
    margin-top: -8px;
}

.community-application-submit,
.publish-form .primary-action {
    justify-self: start;
    width: min(100%, 320px);
}

.publish-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
}

.publish-footer .form-error {
    flex: 1 1 auto;
    margin: 0;
}

.publish-form .primary-action {
    width: 190px;
    min-height: 42px;
    justify-self: auto;
    margin: 0;
    padding: 0 14px;
    border-width: 1px;
    border-radius: 13px;
    font-size: 0.86rem;
}

.community-application-history-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 20px;
}

.community-application-history-heading span {
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--yellow);
    font-size: 0.75rem;
    font-weight: 900;
}

.community-application-list {
    display: grid;
    gap: 12px;
}

.community-application-empty,
.empty-state {
    display: grid;
    min-height: 280px;
    place-items: center;
    align-content: center;
    padding: 36px 20px;
    border: 1px dashed var(--line);
    border-radius: var(--radius-lg);
    background: var(--surface);
    text-align: center;
}

.community-application-empty h3,
.empty-state h2 {
    margin: 16px 0 0;
    font-size: clamp(1.35rem, 3vw, 2rem);
    font-weight: 930;
    letter-spacing: -0.035em;
}

.community-application-empty p,
.empty-state p {
    max-width: 520px;
    margin: 8px 0 0;
    color: var(--muted);
}

.empty-mark {
    display: grid;
    width: 68px;
    height: 68px;
    place-items: center;
    border: 2px solid var(--line);
    border-radius: 50%;
    background: var(--yellow);
    font-size: 2rem;
}

.community-application-detail,
.post-detail {
    animation: detail-in 300ms cubic-bezier(0.2, 0.75, 0.25, 1) both;
}

.community-application-facts,
.community-application-decision-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    margin: 24px 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--line);
}

.community-application-fact {
    min-width: 0;
    padding: 18px;
    background: var(--paper);
}

.community-application-fact dt {
    margin-bottom: 7px;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.community-application-fact dd {
    margin: 0;
    overflow-wrap: anywhere;
    font-weight: 820;
}

.community-public-id {
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    font-size: 0.84rem;
}

.community-application-detail-description,
.community-application-decision {
    margin-top: 18px;
    padding: clamp(20px, 3vw, 30px);
    border-radius: var(--radius-md);
    background: var(--surface);
}

.community-application-detail-description p,
.community-application-pending-note {
    margin: 12px 0 0;
    color: var(--muted);
    white-space: pre-wrap;
}

.publish-denied {
    margin: 18px 0 0;
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--yellow-soft);
    font-weight: 750;
}

.publish-modal-dialog {
    position: fixed;
    inset: 0;
    width: min(760px, calc(100vw - 40px));
    max-width: none;
    max-height: calc(100vh - 40px);
    max-height: calc(100dvh - 40px);
    margin: auto;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: var(--paper);
    color: var(--ink);
}

.publish-modal-dialog::backdrop {
    background: rgb(23 23 20 / 42%);
    backdrop-filter: blur(5px);
}

.publish-modal-surface {
    display: grid;
    width: 100%;
    min-width: 0;
    min-height: 0;
    max-height: calc(100vh - 40px);
    max-height: calc(100dvh - 40px);
    grid-template-rows: auto minmax(0, 1fr);
}

.publish-modal-header {
    position: sticky;
    z-index: 2;
    top: 0;
    display: flex;
    min-height: 62px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 10px 14px 10px 22px;
    border-bottom: 1px solid var(--line);
    background: rgb(255 255 255 / 96%);
    backdrop-filter: blur(12px);
}

.publish-modal-header h2 {
    margin: 0;
    font-size: clamp(1.08rem, 2vw, 1.3rem);
    font-weight: 930;
    letter-spacing: -0.025em;
}

.publish-modal-body {
    min-width: 0;
    min-height: 0;
    padding: 18px 22px 22px;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.post-modal-dialog {
    position: fixed;
    inset: 0;
    width: min(860px, calc(100vw - 40px));
    max-width: none;
    max-height: calc(100vh - 40px);
    max-height: calc(100dvh - 40px);
    margin: auto;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 28px;
    background: var(--paper);
    color: var(--ink);
}

.post-modal-dialog::backdrop {
    background: rgb(23 23 20 / 42%);
    backdrop-filter: blur(5px);
}

.post-modal-surface {
    display: grid;
    width: 100%;
    min-width: 0;
    min-height: 0;
    max-height: calc(100vh - 40px);
    max-height: calc(100dvh - 40px);
    grid-template-rows: auto minmax(0, 1fr) auto;
}

.post-modal-header {
    position: sticky;
    z-index: 2;
    top: 0;
    display: flex;
    min-height: 64px;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    min-width: 0;
    padding: 10px 14px 10px 24px;
    border-bottom: 1px solid var(--line);
    background: rgb(255 255 255 / 94%);
    backdrop-filter: blur(12px);
}

.post-modal-context {
    display: flex;
    min-width: 0;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 13px;
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 800;
    line-height: 1.25;
}

.post-modal-header-actions {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
}

.post-modal-share {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    gap: 7px;
    padding: 0 13px;
    border: 1px solid var(--control-line);
    border-radius: 999px;
    background: var(--surface);
    color: var(--ink);
    cursor: pointer;
    font: inherit;
    font-size: 0.75rem;
    font-weight: 900;
}

.post-modal-share:hover:not(:disabled) {
    background: var(--yellow);
}

.post-modal-share:disabled {
    cursor: wait;
    opacity: 0.42;
}

.post-modal-share .ui-icon {
    width: 17px;
    height: 17px;
}

.post-modal-primary-context {
    display: flex;
    min-width: 0;
    flex-wrap: nowrap;
    align-items: center;
    gap: 13px;
}

.post-modal-view-state {
    position: relative;
    padding-left: 13px;
}

.post-modal-view-state::before {
    position: absolute;
    top: 50%;
    left: 0;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--line);
    content: "";
    transform: translateY(-50%);
}

.post-modal-view-retry {
    padding: 4px 9px;
    border: 1px solid var(--control-line);
    border-radius: 999px;
    background: var(--surface);
    color: var(--muted);
    font: inherit;
    font-weight: 850;
    cursor: pointer;
}

.post-modal-view-retry:hover {
    background: var(--yellow-soft);
    color: var(--ink);
}

.post-modal-close {
    display: grid;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    place-items: center;
    padding: 0;
    border: 1px solid var(--control-line);
    border-radius: 50%;
    background: var(--surface);
    color: var(--ink);
}

.post-modal-close .ui-icon {
    width: 20px;
    height: 20px;
}

.post-modal-close:hover {
    background: var(--yellow);
}

.share-fallback-dialog {
    width: min(520px, calc(100% - 32px));
    max-width: 100%;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--paper);
    color: var(--ink);
}

.share-copy-probe {
  position: fixed;
  inset: 0 auto auto -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.share-fallback-dialog::backdrop {
    background: rgb(23 23 20 / 42%);
    backdrop-filter: blur(4px);
}

.share-fallback-surface {
    display: grid;
    gap: 18px;
    padding: 24px;
}

.share-fallback-surface h2 {
    margin: 0;
    font-size: 1.15rem;
}

.share-fallback-url {
    width: 100%;
    min-height: 48px;
    padding: 0 13px;
    border: 1px solid var(--control-line);
    border-radius: 12px;
    background: var(--surface);
    color: var(--ink);
    font: inherit;
}

.post-modal-body {
    min-width: 0;
    min-height: 0;
    padding: 28px 32px 36px;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.post-modal-reaction-dock {
    position: sticky;
    z-index: 2;
    bottom: 0;
    min-width: 0;
    padding: 12px 40px max(12px, env(safe-area-inset-bottom));
    border-top: 1px solid var(--line);
    background: rgb(255 255 255 / 96%);
    backdrop-filter: blur(12px);
}

.reaction-access-prompt {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.reaction-access-copy {
    display: grid;
    gap: 3px;
}

.reaction-access-copy span,
.reaction-access-message {
    color: var(--muted);
    font-size: 0.9rem;
}

.reaction-access-message {
    margin: 0;
    font-weight: 800;
}

.reaction-access-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 0 0 auto;
}

.post-modal-loading,
.post-modal-error {
    margin: 0;
    color: var(--muted);
}

.post-modal-error + .row-action {
    margin-top: 16px;
}

.post-detail .back-action {
    margin-bottom: 28px;
}

.post-detail h2 {
    max-width: 880px;
    margin: 18px 0 0;
    font-size: clamp(2rem, 5vw, 3.8rem);
    font-weight: 950;
    letter-spacing: -0.055em;
    line-height: 1;
}

.post-body {
    max-width: 780px;
    margin-top: 24px;
    color: var(--ink);
    font-size: clamp(1rem, 1.4vw, 1.15rem);
    line-height: 1.75;
    overflow-wrap: anywhere;
    white-space: pre-wrap;
}

.post-body u {
    text-decoration-thickness: 0.08em;
    text-underline-offset: 0.16em;
}

.post-media-region {
    display: grid;
    min-width: 0;
    gap: 20px;
    margin-top: 24px;
}

.post-image-gallery {
    --gallery-row: clamp(118px, 18vw, 170px);
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    grid-auto-rows: var(--gallery-row);
    gap: 4px;
    overflow: hidden;
    border-radius: 18px;
}

.post-image-gallery.count-1 {
    grid-template-columns: minmax(0, 1fr);
    grid-auto-rows: clamp(280px, 52vw, 520px);
}

.post-image-gallery.count-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: clamp(220px, 35vw, 380px);
}

.post-image-gallery.count-3 .post-gallery-item:first-child {
    grid-column: span 3;
    grid-row: span 2;
}

.post-image-gallery.count-3 .post-gallery-item:not(:first-child),
.post-image-gallery.count-4 .post-gallery-item {
    grid-column: span 3;
}

.post-image-gallery.count-5 .post-gallery-item:nth-child(-n + 2) {
    grid-column: span 3;
}

.post-image-gallery.count-5 .post-gallery-item:nth-child(n + 3),
.post-image-gallery.count-6 .post-gallery-item {
    grid-column: span 2;
}

.post-gallery-item {
    position: relative;
    min-width: 0;
    min-height: 0;
    margin: 0;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background: var(--surface);
    cursor: zoom-in;
}

.post-gallery-item:focus-visible {
    z-index: 2;
    outline: 3px solid transparent;
    outline-offset: -3px;
    box-shadow:
        inset 0 0 0 3px var(--paper),
        inset 0 0 0 6px var(--focus-ring);
}

.post-gallery-item img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: inherit;
    opacity: 0;
    object-fit: cover;
    transition: opacity 180ms ease, transform 180ms ease;
}

.post-gallery-item img.is-loaded {
    opacity: 1;
}

.post-gallery-item:hover img.is-loaded {
    transform: scale(1.015);
}

.post-gallery-more {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background: rgb(58 58 54 / 66%);
    color: #fff;
    font-size: clamp(1.45rem, 5vw, 2.25rem);
    font-weight: 900;
    letter-spacing: -0.04em;
}

.post-photo-viewer {
    position: absolute;
    z-index: 12;
    inset: 0;
    display: grid;
    height: 100%;
    min-width: 0;
    grid-template-rows: auto minmax(0, 1fr);
    overflow: hidden;
    background: rgb(240 240 236 / 98%);
    color: var(--ink);
}

.post-photo-viewer:fullscreen {
    width: 100vw;
    height: 100dvh;
    background: rgb(232 232 227);
}

.post-photo-viewer-toolbar {
    position: relative;
    z-index: 2;
    display: flex;
    min-height: 58px;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 8px 10px 8px 18px;
    border-bottom: 1px solid var(--line);
    background: rgb(255 255 255 / 94%);
    backdrop-filter: blur(12px);
}

.post-photo-viewer-counter {
    font-size: 0.78rem;
    font-weight: 850;
}

.post-photo-viewer-actions {
    display: flex;
    gap: 7px;
}

.post-photo-viewer-control,
.post-photo-viewer-nav {
    display: grid;
    place-items: center;
    padding: 0;
    border: 1px solid var(--control-line);
    background: rgb(255 255 255 / 94%);
    color: var(--ink);
    cursor: pointer;
}

.post-photo-viewer-control {
    width: 40px;
    height: 40px;
    border-radius: 13px;
}

.post-photo-viewer-close {
    padding: 0;
}

.post-photo-viewer-control .ui-icon {
    width: 20px;
    height: 20px;
}

.post-photo-viewer-control:hover,
.post-photo-viewer-nav:hover {
    background: var(--yellow);
}

.post-photo-viewer-stage {
    position: relative;
    display: grid;
    min-height: 0;
    place-items: center;
    padding: 0;
    overflow: hidden;
    background: var(--surface-strong);
}

.post-photo-viewer-stage img {
    position: absolute;
    inset: 18px 72px;
    display: block;
    width: calc(100% - 144px);
    height: calc(100% - 36px);
    max-width: none;
    max-height: none;
    opacity: 0;
    object-fit: contain;
    transition: opacity 160ms ease;
}

.post-photo-viewer-stage img.is-loaded {
    opacity: 1;
}

.post-photo-viewer-nav {
    position: absolute;
    z-index: 3;
    top: 50%;
    width: 46px;
    height: 58px;
    border-radius: 15px;
    transform: translateY(-50%);
}

.post-photo-viewer-nav .ui-icon {
    width: 22px;
    height: 22px;
}

.post-photo-viewer-nav.is-previous {
    left: 14px;
}

.post-photo-viewer-nav.is-next {
    right: 14px;
}

.post-media-load-error {
    display: grid;
    min-height: 120px;
    place-items: center;
    padding: 20px;
    color: var(--muted);
    text-align: center;
}

.post-external-video {
    display: grid;
    justify-items: start;
    gap: 10px;
}

.post-video-stage {
    position: relative;
    isolation: isolate;
    width: 100%;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: var(--surface);
    aspect-ratio: 16 / 9;
}

.post-external-video.is-vertical .post-video-stage {
    width: min(100%, 390px);
    aspect-ratio: 9 / 16;
}

.post-video-stage iframe {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: var(--surface);
    opacity: 0;
    transition: opacity 180ms ease;
}

.post-video-stage iframe.is-ready {
    opacity: 1;
}

.post-video-poster {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-video-prompt {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(246, 246, 242, 0.08);
}

.post-video-play {
    display: grid;
    width: 76px;
    height: 76px;
    place-items: center;
    padding: 0;
    border: 1px solid var(--control-line);
    border-radius: 26px;
    background: var(--yellow);
    color: var(--ink);
    cursor: pointer;
    transition: transform 160ms ease, background-color 160ms ease;
}

.post-video-play:hover {
    background: var(--yellow-soft);
    transform: scale(1.06);
}

.post-video-play:active {
    transform: scale(0.97);
}

.post-video-play svg {
    width: 38px;
    height: 32px;
    transform: translateX(2px);
}

.post-video-external {
    font-size: 0.82rem;
}

.reaction-form {
    width: 100%;
    margin: 0;
}

.reaction-title,
.post-modal-reaction-title {
    margin: 0 0 9px;
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.01em;
}

.leader-aggregate h3 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.aggregate-description {
    margin: 8px 0 0;
    color: var(--muted);
    font-size: 0.82rem;
}

.reaction-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 8px;
    margin: 0;
}

.reaction-choice {
    position: relative;
    cursor: pointer;
}

.reaction-choice input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.reaction-choice span {
    display: flex;
    min-height: 48px;
    align-items: center;
    justify-content: center;
    padding: 10px 14px;
    border: 1px solid var(--control-line);
    border-radius: 18px;
    background: var(--paper);
    font-size: 0.9rem;
    font-weight: 820;
    line-height: 1.2;
    text-align: center;
    transition: border-color 160ms ease, background-color 160ms ease, transform 160ms ease;
}

.reaction-choice:hover span {
    border-color: var(--control-line);
    transform: translateY(-2px);
}

.reaction-choice input:checked + span {
    border-color: var(--ink);
    background: var(--yellow);
    box-shadow: inset 0 0 0 1px var(--ink);
}

.reaction-choice input:focus-visible + span {
    outline: 3px solid var(--focus-ring);
    outline-offset: 3px;
}

.consent-field {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 18px;
    color: var(--muted);
    cursor: pointer;
    font-size: 0.86rem;
}

.consent-field input {
    width: 20px;
    height: 20px;
    margin: 2px 0 0;
    accent-color: var(--yellow);
}

.reaction-status {
    min-height: 1.2em;
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 0.8rem;
    font-weight: 750;
}

.reaction-status.is-saved {
    color: var(--ink);
}

.leader-aggregate {
    max-width: 880px;
    margin-top: 18px;
    padding: 14px 16px;
    border-radius: 18px;
}

.aggregate-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.aggregate-access {
    padding: 5px 8px;
    border-radius: 999px;
    background: var(--surface-strong);
    color: var(--muted);
    font-size: 0.66rem;
    font-weight: 850;
    line-height: 1;
    text-transform: uppercase;
}

.aggregate-summary {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 14px;
    margin-top: 12px;
}

.aggregate-total {
    display: grid;
    min-width: 84px;
    min-height: 54px;
    place-items: center;
    align-content: center;
    padding: 7px 12px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--yellow);
}

.aggregate-total span {
    font-size: 0.6rem;
    font-weight: 900;
    text-transform: uppercase;
}

.aggregate-total strong {
    font-size: 1.3rem;
    line-height: 1;
}

.aggregate-privacy {
    margin: 0;
    color: var(--muted);
    font-size: 0.76rem;
}

.aggregate-rows {
    display: grid;
    gap: 11px;
    margin-top: 16px;
}

.aggregate-row-heading {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 6px;
    font-size: 0.8rem;
    font-weight: 800;
}

.aggregate-track {
    height: 8px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--paper);
}

.aggregate-fill {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--yellow);
    transform-origin: left center;
    animation: aggregate-fill-in 620ms cubic-bezier(0.2, 0.75, 0.25, 1) both;
}

.aggregate-suppressed {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 8px;
    margin-top: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    background: var(--yellow-soft);
    font-size: 0.78rem;
    line-height: 1.35;
}

.aggregate-suppressed span {
    color: var(--muted);
}

.toast {
    position: fixed;
    z-index: 100;
    right: max(18px, env(safe-area-inset-right));
    bottom: max(18px, env(safe-area-inset-bottom));
    max-width: min(440px, calc(100vw - 36px));
    padding: 15px 18px;
    border: 2px solid var(--line);
    border-radius: 18px;
    background: var(--yellow);
    color: var(--ink);
    font-size: 0.9rem;
    font-weight: 850;
    animation: toast-in 220ms ease both;
}

noscript {
    display: block;
    padding: 18px;
    background: var(--yellow);
    color: var(--ink);
    text-align: center;
    font-weight: 900;
}

@keyframes panel-in {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.99);
    }
}

@keyframes row-in {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
}

@keyframes detail-in {
    from {
        opacity: 0;
        transform: translateX(12px);
    }
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }
}

@keyframes aggregate-fill-in {
    from {
        transform: scaleX(0);
    }
}

@media (max-width: 1040px) {
    .auth-view {
        grid-template-columns: minmax(0, 1fr) minmax(360px, 470px);
        gap: 40px;
        padding-inline: 34px;
    }

    .auth-intro-title {
        font-size: clamp(2.7rem, 5.4vw, 4.3rem);
    }

    .workspace-view {
        grid-template-columns: 240px minmax(0, 1fr);
        gap: 30px;
    }

    .workspace-sidebar {
        padding: 16px;
    }

    .nav-action {
        padding-inline: 10px;
        font-size: 0.78rem;
    }
}

@media (max-width: 840px) {
    :root {
        --header-height: 66px;
    }

    html {
        scroll-padding-block-end: calc(104px + env(safe-area-inset-bottom));
    }

    :where(a, button, input, select, textarea, [tabindex]):focus-visible {
        scroll-margin-block-end: calc(104px + env(safe-area-inset-bottom));
    }

    .app-header {
        padding: 10px 18px;
    }

    .brand-name {
        display: none;
    }

    .mobile-user-menu-button {
        display: grid;
    }

    .auth-dialog {
        width: min(620px, calc(100% - 28px));
    }

    .auth-view {
        display: block;
        padding: 60px 20px 28px;
        background: var(--paper);
    }

    .auth-dialog .auth-intro {
        display: none;
    }

    .community-card {
        grid-template-columns: minmax(0, 1fr);
    }

    .community-card-media {
        width: 100%;
        aspect-ratio: 16 / 9;
    }

    .community-profile {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
        padding: 0;
    }

    .community-profile-image {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
        border-radius: 0;
    }

    .community-profile-content {
        width: 100%;
        padding: 18px;
    }

    .community-card-image {
        height: 100%;
        min-height: 0;
    }

    .intro-copy {
        max-width: 480px;
        font-size: 1rem;
    }

    .flow-list {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-top: 32px;
    }

    .flow-list li {
        display: grid;
        min-width: 0;
        grid-template-columns: auto;
        align-content: start;
        gap: 10px;
        padding: 14px;
        border: 1px solid var(--line);
        border-radius: 18px;
        background: rgb(255 255 255 / 88%);
        font-size: 0.75rem;
    }

    .flow-list li:last-child {
        border-bottom: 1px solid var(--line);
    }

    .auth-panel {
        max-width: 620px;
        margin: 0 auto;
        justify-self: auto;
    }

    .workspace-view {
        display: block;
        padding: 22px 18px calc(120px + env(safe-area-inset-bottom));
    }

    .workspace-view.is-anonymous {
        padding-bottom: max(40px, env(safe-area-inset-bottom));
    }

    .workspace-sidebar {
        position: static;
        display: grid;
        max-height: none;
        grid-template-columns: minmax(0, 1fr);
        align-items: center;
        margin-bottom: 0;
        padding: 0;
        border: 0;
        background: transparent;
    }

    .member-summary,
    .logout-action {
        display: none;
    }

    .workspace-nav-shell {
        position: fixed;
        z-index: 60;
        right: 12px;
        bottom: max(12px, env(safe-area-inset-bottom));
        left: 12px;
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 5px;
        padding: 6px;
        border: 1px solid var(--line);
        border-radius: 24px;
        background: var(--paper);
    }

    .workspace-nav {
        position: static;
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        grid-column: 1;
        grid-row: 1;
        width: 100%;
        margin: 0;
        padding: 0;
        gap: 5px;
        overflow: visible;
        border: 0;
        border-radius: 18px;
        background: transparent;
    }

    .nav-action {
        display: grid;
        min-width: 0;
        min-height: 60px;
        grid-template-columns: 1fr;
        place-items: center;
        align-content: center;
        gap: 3px;
        padding: 5px 7px;
        border-radius: 17px;
        color: var(--ink);
        text-align: center;
        font-size: 0.58rem;
        line-height: 1.1;
    }

    .nav-action:hover {
        background: var(--yellow-soft);
        color: var(--ink);
    }

    .nav-action.is-active {
        background: var(--yellow);
        color: var(--ink);
        transform: none;
    }

    .nav-action-icon {
        width: 27px;
        height: 27px;
        padding: 5px;
    }

    .nav-action > span:last-child {
        overflow-wrap: anywhere;
    }

    .post-modal-primary-context {
        min-width: 0;
        flex-wrap: nowrap;
        gap: 6px;
        white-space: nowrap;
    }

    .post-preview-meta {
        gap: 4px;
        font-size: 0.58rem;
    }

    .post-preview-community-chip {
        max-width: 34%;
        min-height: 24px;
        gap: 4px;
        padding-right: 5px;
    }

    .post-preview-community-image {
        width: 20px;
        height: 20px;
        flex-basis: 20px;
    }

    .post-publication-type {
        min-width: 0;
        flex: 0 1 auto;
        overflow: hidden;
        padding: 0;
        border-radius: 0;
        background: transparent;
        color: var(--muted);
        font-size: 0.56rem;
        line-height: 1.2;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .post-publication-full {
        display: none;
    }

    .post-publication-compact {
        display: inline;
        flex: 0 0 auto;
        color: var(--muted);
        font-size: 0.58rem;
        font-weight: 800;
        line-height: 1.2;
        white-space: nowrap;
    }

    .post-modal-context {
        align-items: flex-start;
    }

    .community-post-preview.has-media {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
        padding: 0;
    }

    .community-post-preview.has-media .post-preview-media {
        width: 100%;
        min-height: 0;
        grid-column: 1 / -1;
        border-width: 0 0 1px;
        border-radius: 0;
        aspect-ratio: 16 / 9;
    }

    .community-post-preview.has-media .community-post-preview-content {
        padding: 16px 18px 18px 20px;
    }

    .community-post-preview.has-media::before {
        top: 0;
        bottom: 0;
    }

    .catalog-tabs,
    .profile-tabs {
        display: grid;
        width: 100%;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 3px;
        margin-bottom: 12px;
        padding: 3px;
        border-radius: 18px;
    }

    .catalog-tab,
    .profile-tab {
        min-width: 0;
        min-height: 44px;
        padding: 7px 5px;
        border-radius: 15px;
        font-size: 0.72rem;
        white-space: normal;
    }

    .workspace-main {
        padding-top: 0;
    }

    .section-heading h1 {
        font-size: clamp(2.55rem, 10vw, 5rem);
    }

    .toast {
        bottom: calc(100px + env(safe-area-inset-bottom));
    }
}

@media (max-width: 580px) {
    .registration-topic-choices,
    .topic-interest-choices {
        grid-template-columns: minmax(0, 1fr);
    }

    .topic-interests-submit,
    .feed-load-more {
        width: 100%;
        min-width: 0;
    }

    .profile-data-field {
        grid-template-columns: minmax(0, 1fr);
        gap: 6px;
    }

    .brand {
        gap: 8px;
        font-size: 1.18rem;
    }

    .brand-mark {
        width: 36px;
        height: 36px;
        flex-basis: 36px;
    }

    .app-header {
        padding-inline: 10px;
    }

    .header-actions {
        gap: 5px;
    }

    .header-search-button,
    .header-filter-button,
    .header-auth-button,
    .header-notifications-button,
    .mobile-user-menu-button {
        width: 36px;
        height: 36px;
    }

    .header-search-button .ui-icon,
    .header-filter-button .ui-icon,
    .header-auth-button .ui-icon,
    .header-notifications-button .ui-icon {
        width: 19px;
        height: 19px;
    }

    .install-action {
        width: 36px;
        min-height: 36px;
        padding: 0;
        justify-content: center;
        border-radius: 50%;
    }

    .install-action-label {
        display: none;
    }

    .auth-dialog,
    .search-dialog,
    .catalog-filter-dialog,
    .community-type-help-dialog {
        width: 100%;
        height: 100vh;
        height: 100dvh;
        max-height: 100vh;
        max-height: 100dvh;
        margin: 0;
        border: 0;
        border-radius: 0;
    }

    .auth-dialog-surface,
    .search-dialog-surface,
    .catalog-filter-dialog-surface,
    .community-type-help-surface {
        height: 100%;
        max-height: 100%;
    }

    .auth-dialog-close {
        top: max(10px, env(safe-area-inset-top));
        right: max(12px, env(safe-area-inset-right));
    }

    .search-dialog-header,
    .catalog-filter-dialog-header,
    .community-type-help-header {
        padding: max(10px, env(safe-area-inset-top)) max(14px, env(safe-area-inset-right))
            10px max(18px, env(safe-area-inset-left));
    }

    .search-dialog-body,
    .catalog-filter-dialog-body,
    .community-type-help-body {
        padding: 16px max(14px, env(safe-area-inset-right))
            max(22px, env(safe-area-inset-bottom)) max(14px, env(safe-area-inset-left));
    }

    .global-search-fields {
        grid-template-columns: 1fr;
    }

    .global-search-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .catalog-filter-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .catalog-filter-apply {
        width: 100%;
    }

    .global-search-actions .text-action,
    .global-search-submit {
        width: 100%;
        text-align: center;
    }

    .auth-view {
        min-height: 100%;
        padding: max(64px, calc(env(safe-area-inset-top) + 54px))
            max(14px, env(safe-area-inset-right))
            max(24px, env(safe-area-inset-bottom))
            max(14px, env(safe-area-inset-left));
    }

    .flow-list {
        grid-template-columns: 1fr;
    }

    .flow-list li {
        grid-template-columns: 38px 1fr;
        align-items: center;
        background: var(--paper);
    }

    .auth-panel {
        padding: 0;
        border: 0;
        border-radius: 0;
    }

    .auth-tabs {
        margin-bottom: 28px;
    }

    .google-auth-entry {
        margin-top: -14px;
    }

    .auth-tab {
        min-height: 44px;
        padding-inline: 10px;
        font-size: 0.8rem;
    }

    .section-heading.compact h2 {
        font-size: 1.9rem;
    }

    .community-card {
        grid-template-columns: minmax(0, 1fr);
        border-radius: var(--radius-md);
    }

    .community-profile {
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
        padding-bottom: 14px;
    }

    .community-profile-image {
        width: 100%;
    }

    .community-profile-content h2 {
        font-size: 1.25rem;
    }

    .community-profile-facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px 10px;
        margin-top: 10px;
    }

    .community-card-body {
        padding: 13px 14px;
    }

    .community-card-body .row-meta {
        gap: 5px 8px;
        margin-bottom: 6px;
        font-size: 0.65rem;
    }

    .community-card-body h2 {
        margin-top: 6px;
        font-size: 1.05rem;
    }

    .community-card-description {
        margin-top: 6px;
        font-size: 0.78rem;
        line-height: 1.35;
    }

    .community-card-badges {
        right: 6px;
        bottom: 6px;
        left: 6px;
        gap: 4px;
    }

    .community-card-badge {
        min-height: 23px;
        gap: 3px;
        padding: 3px 6px;
        font-size: 0.62rem;
    }

    .community-card-badge-icon {
        width: 12px;
        height: 12px;
        flex-basis: 12px;
    }

    .community-card .row-actions {
        padding-top: 9px;
    }

    .community-card .row-action {
        min-height: 36px;
        padding-inline: 11px;
        font-size: 0.7rem;
    }

    .community-post-preview {
        gap: 12px;
        padding: 18px 16px 18px 20px;
    }

    .community-post-preview.has-media {
        grid-template-columns: minmax(0, 1fr);
    }

    .post-preview-media {
        min-height: 0;
        border-radius: 12px;
    }

    .post-modal-dialog,
    .publish-modal-dialog {
        width: 100%;
        max-width: 100%;
        height: 100vh;
        height: 100dvh;
        max-height: 100vh;
        max-height: 100dvh;
        margin: 0;
        border: 0;
        border-radius: 0;
    }

    .post-modal-surface,
    .publish-modal-surface {
        height: 100%;
        max-height: 100%;
    }

    .post-modal-header,
    .publish-modal-header {
        padding: max(10px, env(safe-area-inset-top)) max(14px, env(safe-area-inset-right))
            10px max(18px, env(safe-area-inset-left));
    }

    .post-modal-header {
        gap: 8px;
    }

    .post-modal-share {
        min-height: 40px;
        padding-inline: 10px;
    }

    .post-modal-share > span {
        display: none;
    }

    .post-modal-body {
        padding: 22px max(18px, env(safe-area-inset-right)) 28px
            max(18px, env(safe-area-inset-left));
    }

    .publish-modal-body {
        padding: 16px max(14px, env(safe-area-inset-right))
            max(18px, env(safe-area-inset-bottom)) max(14px, env(safe-area-inset-left));
    }

    .post-modal-reaction-dock {
        padding: 10px max(18px, env(safe-area-inset-right))
            max(10px, env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left));
    }

    .community-feed-header {
        align-items: stretch;
        flex-direction: column;
    }

    .publish-open-action {
        width: 100%;
        justify-content: center;
    }

    .reaction-access-prompt {
        align-items: stretch;
        flex-direction: column;
        gap: 10px;
    }

    .reaction-access-actions .row-action {
        flex: 1;
    }

    .post-image-gallery {
        --gallery-row: clamp(96px, 28vw, 126px);
    }

    .post-image-gallery.count-1 {
        grid-auto-rows: clamp(260px, 82vw, 420px);
    }

    .post-image-gallery.count-2 {
        grid-auto-rows: clamp(190px, 55vw, 280px);
    }

    .post-photo-viewer-stage {
        padding: 0;
    }

    .post-photo-viewer-stage img {
        inset: 12px 52px;
        width: calc(100% - 104px);
        height: calc(100% - 24px);
    }

    .post-photo-viewer-toolbar {
        padding: max(8px, env(safe-area-inset-top)) max(10px, env(safe-area-inset-right))
            8px max(18px, env(safe-area-inset-left));
    }

    .post-photo-viewer-nav {
        width: 38px;
        height: 50px;
        border-radius: 12px;
    }

    .post-photo-viewer-nav.is-previous {
        left: 8px;
    }

    .post-photo-viewer-nav.is-next {
        right: 8px;
    }

    .publish-image-preview {
        grid-template-columns: repeat(4, minmax(56px, 1fr));
    }

    .publish-media-grid {
        grid-template-columns: 1fr;
    }

    .form-assist-row,
    .resend-row {
        align-items: flex-start;
    }

    .workspace-view {
        padding-inline: 14px;
    }

    .member-summary {
        grid-template-columns: 46px minmax(0, 1fr);
    }

    .member-avatar {
        width: 46px;
        height: 46px;
    }

    .content-row {
        grid-template-columns: 1fr;
        gap: 18px;
        padding: 20px;
    }

    .notification-row-toggle {
        padding: 18px 16px;
    }

    .notification-row .row-meta {
        gap: 6px 9px;
        margin-bottom: 8px;
        font-size: 0.65rem;
    }

    .notification-row-title {
        font-size: 1rem;
    }

    .content-row:hover {
        transform: none;
    }

    .row-actions {
        width: 100%;
        max-width: none;
        justify-content: flex-start;
    }

    .row-action {
        flex: 1 1 auto;
    }

    .session-control {
        align-items: flex-start;
        flex-direction: column;
    }

    .session-control .row-action {
        width: 100%;
    }

    .preferences-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .preferences-save {
        width: 100%;
    }

    .community-application-form,
    .publish-form,
    .community-application-facts,
    .community-application-decision-facts {
        grid-template-columns: 1fr;
    }

    .community-application-guidance-steps {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .community-application-form .field,
    .publish-form .field {
        grid-column: 1;
    }

    .publish-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .community-application-submit,
    .publish-form .primary-action {
        width: 100%;
    }

    .community-application-history-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .reaction-options {
        grid-auto-flow: row;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        overflow: visible;
    }

    .reaction-choice span {
        min-height: 44px;
        padding: 8px 9px;
        font-size: 0.78rem;
    }

    .aggregate-summary {
        grid-template-columns: 1fr;
    }

    .post-detail h2 {
        font-size: clamp(2.4rem, 13vw, 4.2rem);
    }

    .toast {
        right: 12px;
        left: 12px;
        max-width: none;
    }
}

@media (max-height: 580px) and (orientation: landscape) {
    .post-modal-dialog,
    .publish-modal-dialog {
        width: 100%;
        max-width: 100%;
        height: 100vh;
        height: 100dvh;
        max-height: 100vh;
        max-height: 100dvh;
        margin: 0;
        border: 0;
        border-radius: 0;
    }

    .post-modal-surface,
    .publish-modal-surface {
        height: 100%;
        max-height: 100%;
    }

    .post-modal-header,
    .publish-modal-header,
    .post-photo-viewer-toolbar {
        min-height: 50px;
        padding-top: max(6px, env(safe-area-inset-top));
        padding-bottom: 6px;
    }

    .post-modal-body {
        padding-top: 16px;
        padding-bottom: 18px;
    }

    .publish-modal-body {
        padding-top: 12px;
        padding-bottom: 14px;
    }
}

@media (display-mode: standalone) {
    .app-header {
        padding-top: max(10px, env(safe-area-inset-top));
    }

    .install-action {
        display: none !important;
    }
}

@media (forced-colors: active) {
    :root {
        --paper: Canvas;
        --ink: CanvasText;
        --surface: Canvas;
        --surface-strong: Canvas;
        --line: CanvasText;
        --control-line: CanvasText;
        --muted: CanvasText;
        --focus-ring: Highlight;
    }

    :focus-visible,
    .field input:focus,
    .field textarea:focus,
    .field select:focus,
    .publish-editor:focus-within,
    .topic-choice:has(input:focus-visible),
    .switch-control input:focus-visible + .switch-track,
    .reaction-choice input:focus-visible + span {
        outline: 3px solid Highlight !important;
    }

    .auth-tab[aria-selected="true"],
    .nav-action.is-active,
    .catalog-tab.is-active,
    .profile-tab.is-active,
    .topic-choice:has(input:checked),
    .reaction-choice input:checked + span,
    .switch-control input:checked + .switch-track {
        border: 2px solid Highlight;
        forced-color-adjust: none;
        background: Highlight;
        color: HighlightText;
    }

    .switch-control input:checked + .switch-track::after {
        background: HighlightText;
    }

    .skip-link {
        border-color: CanvasText;
        background: Canvas;
        color: CanvasText;
    }
}

@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;
    }
}
