/* PlayVoice — Professional community theme */

:root,
[data-theme="light"] {
    color-scheme: light;
    --bg: #f7f7f5;
    --surface: #ffffff;
    --surface-muted: #efefec;
    --text: #141414;
    --text-secondary: #5c5c5c;
    --text-tertiary: #8a8a8a;
    --border: #e2e2de;
    --border-strong: #cfcfca;
    --dark: #141414;
    --dark-soft: #2a2a2a;
    --header-bg: rgba(247, 247, 245, 0.92);
    --header-h: 60px;
    --scroll-offset: calc(var(--header-h) + 28px);
    --radius: 6px;
    --radius-lg: 10px;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 8px 24px rgba(0, 0, 0, 0.06);
    --font: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
    --wrap: 1140px;
    --site-gutter: clamp(28px, 4.5vw, 56px);
    --accent: #3b82f6;
}

[data-theme="dark"] {
    color-scheme: dark;
    --bg: #101010;
    --surface: #1a1a1a;
    --surface-muted: #242424;
    --text: #f2f2f0;
    --text-secondary: #b8b8b4;
    --text-tertiary: #8a8a86;
    --border: #2d2d2d;
    --border-strong: #3f3f3f;
    --dark: #141414;
    --dark-soft: #222222;
    --header-bg: rgba(16, 16, 16, 0.92);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.35), 0 8px 24px rgba(0, 0, 0, 0.4);
    --accent: #60a5fa;
}

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: auto;
}

/* Anchor sections — offset for sticky header */
#hero,
#about,
#community,
#features,
#partners,
#leadership,
#join {
    scroll-margin-top: var(--scroll-offset);
}

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    font-size: 0.9375rem;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

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

.wrap {
    width: 100%;
    max-width: var(--wrap);
    margin: 0 auto;
    padding-inline: var(--site-gutter);
    box-sizing: border-box;
}

/* Typography */
.eyebrow {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: 10px;
}

.eyebrow-light {
    color: rgba(255, 255, 255, 0.55);
}

h1, h2, h3 {
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.3;
    color: var(--text);
}

h1 {
    font-size: clamp(1.625rem, 2.8vw, 2rem);
    margin-bottom: 14px;
}

h2 {
    font-size: clamp(1.25rem, 2vw, 1.5rem);
    margin-bottom: 12px;
}

h3 {
    font-size: 0.9375rem;
    font-weight: 600;
    margin-bottom: 6px;
}

.lead {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
    max-width: 44ch;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 10px 18px;
    font-family: var(--font);
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: var(--radius);
    border: 1px solid transparent;
    cursor: pointer;
    transition: background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease);
}

.btn-sm {
    padding: 8px 14px;
    font-size: 0.8125rem;
}

.btn-dark {
    background: var(--dark);
    color: #fff;
    border-color: var(--dark);
}

.btn-dark:hover {
    background: var(--dark-soft);
    border-color: var(--dark-soft);
}

.btn-outline {
    background: transparent;
    color: var(--text);
    border-color: var(--border-strong);
}

.btn-outline:hover {
    border-color: var(--text);
    background: var(--surface);
}

.btn-light {
    background: #fff;
    color: var(--dark);
}

.btn-light:hover {
    background: #f0f0f0;
}

.btn-ghost-light {
    background: transparent;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.35);
}

.btn-ghost-light:hover {
    border-color: rgba(255, 255, 255, 0.7);
    background: rgba(255, 255, 255, 0.06);
}

[data-theme="dark"] .btn-dark {
    background: transparent;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.55);
}

[data-theme="dark"] .btn-dark:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: #fff;
    color: #fff;
}

[data-theme="dark"] .btn-outline {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.45);
}

[data-theme="dark"] .btn-outline:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
}

/* Header */
.header {
    position: sticky;
    top: 0;
    z-index: 100;
    height: var(--header-h);
    background: var(--header-bg);
    backdrop-filter: blur(12px);
}

.header-inner {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
}

.brand-name {
    font-size: 1.0625rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text);
    line-height: 1;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 28px;
    flex-shrink: 0;
    margin-left: auto;
    min-width: 0;
}

.nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 28px;
    flex: 1 1 auto;
    min-width: 0;
}

.nav a {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: color 0.2s;
    white-space: nowrap;
}

.nav a:hover {
    color: var(--text);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.header-cta {
    margin: 0;
    height: 36px;
    padding: 0 12px;
    border-radius: 8px;
    font-size: 0.8125rem;
    font-weight: 500;
    line-height: 1;
    white-space: nowrap;
    flex-shrink: 0;
}

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 1px solid var(--border-strong);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text-secondary);
    cursor: pointer;
    flex-shrink: 0;
    transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.theme-toggle:hover {
    color: var(--text);
    background: var(--surface-muted);
    border-color: var(--border-strong);
}

[data-theme="dark"] .header .header-cta.btn-dark {
    background: var(--text);
    color: var(--bg);
    border-color: var(--text);
}

[data-theme="dark"] .header .header-cta.btn-dark:hover {
    background: #fff;
    color: #101010;
    border-color: #fff;
}

.lang-dropdown {
    position: relative;
    flex-shrink: 0;
}

.lang-dropdown-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 36px;
    padding: 0 12px;
    border: 1px solid var(--border-strong);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.lang-dropdown-toggle:hover,
.lang-dropdown.is-open .lang-dropdown-toggle {
    color: var(--text);
    background: var(--surface-muted);
    border-color: var(--border-strong);
}

.lang-dropdown.is-open .lang-dropdown-toggle {
    background: var(--surface-muted);
}

.lang-dropdown-current {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.lang-flag-slot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.lang-dropdown-current .lang-flag {
    width: 22px;
    height: 15px;
    border-radius: 2px;
}

.lang-dropdown-current-label {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text);
    white-space: nowrap;
    line-height: 1;
}

.lang-flag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 15px;
    border-radius: 2px;
    overflow: hidden;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1);
    flex-shrink: 0;
}

.lang-flag-svg {
    display: block;
    width: 100%;
    height: 100%;
}

.lang-flag-cs {
    border-radius: 1px;
}

.lang-flag-cs .lang-flag-svg {
    transform: scale(1.04);
    transform-origin: center;
}

.lang-caret-slot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.lang-caret {
    width: 10px;
    height: 10px;
    color: var(--text-tertiary);
    transition: transform 0.2s var(--ease), color 0.2s;
}

.lang-dropdown-toggle:hover .lang-caret,
.lang-dropdown.is-open .lang-caret {
    color: var(--text-secondary);
}

.lang-dropdown.is-open .lang-caret {
    transform: rotate(180deg);
}

.lang-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 120;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 210px;
    max-height: 400px;
    padding: 10px;
    overflow-y: auto;
    border: 1px solid var(--border-strong);
    border-radius: 10px;
    background: var(--surface);
    box-shadow: var(--shadow), 0 16px 40px rgba(0, 0, 0, 0.12);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-4px) scale(0.98);
    transform-origin: top right;
    transition: opacity 0.18s var(--ease), transform 0.18s var(--ease), visibility 0.18s;
}

.lang-dropdown.is-open .lang-dropdown-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
    transform: translateY(0) scale(1);
}

.lang-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 8px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: background 0.15s, color 0.15s;
}

.lang-dropdown-item .lang-flag-slot {
    width: auto;
}

.lang-dropdown-item .lang-flag {
    width: 22px;
    height: 15px;
    border-radius: 2px;
}

.lang-dropdown-label {
    flex: 1;
    white-space: nowrap;
    line-height: 1.2;
}

.lang-dropdown-check {
    width: 16px;
    height: 16px;
    color: var(--accent);
    flex-shrink: 0;
}

.lang-dropdown-item:hover {
    background: var(--surface-muted);
    color: var(--text);
}

.lang-dropdown-item.is-active {
    background: var(--surface-muted);
    color: var(--text);
    font-weight: 600;
    cursor: default;
}

.lang-dropdown-item.is-active:hover {
    background: var(--surface-muted);
}

.lang-dropdown-item.is-active .lang-flag {
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.12);
}

.theme-icon {
    width: 18px;
    height: 18px;
}

.theme-icon-sun {
    display: none;
}

[data-theme="dark"] .theme-icon-moon {
    display: none;
}

[data-theme="dark"] .theme-icon-sun {
    display: block;
}

.menu-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 40px;
    height: 40px;
    background: none;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
    flex-shrink: 0;
}

.menu-btn span {
    display: block;
    width: 18px;
    height: 2px;
    background: var(--text);
    margin: 0 auto;
    transition: transform 0.25s, opacity 0.25s;
}

.menu-btn.is-open span:first-child {
    transform: translateY(4px) rotate(45deg);
}

.menu-btn.is-open span:last-child {
    transform: translateY(-4px) rotate(-45deg);
}

/* Hero */
.hero {
    padding: 40px 0 36px;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.hero-copy {
    padding-right: 16px;
    position: relative;
    z-index: 1;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 22px;
}

.hero-media {
    position: relative;
    aspect-ratio: 4 / 3;
    border-radius: var(--radius-lg);
    overflow: hidden;
    isolation: isolate;
    background: var(--surface-muted);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.hero-video,
.hero-slideshow {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.hero-video {
    object-fit: cover;
}

.hero-slideshow {
    z-index: 0;
}

.hero-slide {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 1.2s ease, visibility 1.2s ease;
}

.hero-slide.is-active {
    opacity: 1;
    visibility: visible;
}

/* Intro band */
.intro-band {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 44px 24px;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: var(--surface);
}

.intro-band-inner {
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
    text-align: center;
}

.intro-band-lead {
    font-size: 1.0625rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
}

.intro-band-sub {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.65;
}

/* Sections */
.section {
    padding: 56px 0;
}

.section-muted {
    background: var(--surface);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.section-muted + .partners {
    border-top: 0;
    padding: 24px 24px 28px;
}

#features {
    padding-bottom: 36px;
}

.section-head {
    max-width: 480px;
    margin-bottom: 28px;
}

.section-head p:last-of-type,
.about-copy > p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* About */
#about.section {
    padding-top: 40px;
}

.about-grid {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 40px;
    align-items: start;
}

.about-grid--reverse {
    grid-template-columns: 1fr 1.05fr;
}

.about-copy h2 {
    margin-top: 0;
}

.about-media {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border);
    background: var(--surface-muted);
}

.about-media img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    object-position: center;
    pointer-events: none;
    -webkit-user-drag: none;
    user-select: none;
}

.about-media--cover {
    aspect-ratio: 4 / 3;
}

.about-media--cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.about-copy p + p {
    margin-top: 12px;
}

/* Features */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.feature-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px 18px;
}

.feature-card p {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Partners */
.partners {
    background: var(--surface);
    padding: 32px 24px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: center;
    align-items: center;
}

.partners-inner {
    width: 100%;
    max-width: 820px;
    text-align: center;
}

.partners-inner h2 {
    margin-bottom: 8px;
}

.partners-lead {
    margin: 0 auto 18px;
    max-width: 480px;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.55;
}

.partners-list {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
}

.partner-card {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-width: 180px;
    padding: 12px 20px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--bg);
    color: var(--text);
    text-decoration: none;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.partner-card > * {
    pointer-events: none;
}

.partner-card:hover {
    border-color: rgba(0, 123, 252, 0.35);
    box-shadow: var(--shadow);
}

.partner-logo {
    width: 40px;
    height: 40px;
    object-fit: contain;
    flex-shrink: 0;
    pointer-events: none;
    -webkit-user-drag: none;
    user-select: none;
}

.partner-name {
    font-size: 1.125rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text);
}

.viewer-partners {
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.viewer-partners h3 {
    margin: 0 0 8px;
    font-size: 1.25rem;
}

.viewer-partner-card {
    min-width: 230px;
    min-height: 76px;
    flex: 1 0 230px;
    padding: 14px 22px;
}

.viewer-partners-list {
    flex-wrap: nowrap;
    justify-content: flex-start;
    overflow-x: auto;
    padding: 2px 2px 8px;
    scrollbar-width: thin;
}

.viewer-partner-logo {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    object-fit: contain;
    pointer-events: none;
    -webkit-user-drag: none;
    user-select: none;
}

.viewer-partner-logo--wide {
    width: 170px;
    height: 54px;
}

.viewer-partner-card:nth-child(2) .viewer-partner-logo {
    transform: translateX(-6px);
}

/* Leadership */
.leadership {
    background: var(--bg);
    color: var(--text);
    padding: 56px 24px 64px;
    border-top: 1px solid var(--border);
}

.leadership-inner {
    width: 100%;
    max-width: 1040px;
    margin: 0 auto;
    text-align: center;
}

.leadership-inner h2 {
    margin-bottom: 40px;
    color: var(--text);
    font-size: clamp(1.5rem, 3vw, 1.875rem);
    font-weight: 700;
    letter-spacing: -0.02em;
}

.leadership-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(20px, 4vw, 48px);
}

.leadership-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.leadership-avatar {
    width: clamp(108px, 14vw, 140px);
    height: clamp(108px, 14vw, 140px);
    overflow: hidden;
    background: transparent;
}

.leadership-avatar img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center bottom;
    -webkit-user-drag: none;
    user-select: none;
}

.leadership-name {
    font-size: 1.0625rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1.2;
}

.leadership-role {
    margin: 0;
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-secondary);
    line-height: 1.4;
}

@media (max-width: 860px) {
    .leadership-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 32px 24px;
    }
}

@media (max-width: 480px) {
    .leadership {
        padding: 48px 20px 56px;
    }

    .leadership-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        max-width: 360px;
        margin: 0 auto;
    }
}

/* CTA */
.cta {
    background: var(--dark);
    color: #fff;
    padding: 56px 0;
}

.cta-inner {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 40px;
}

.cta-copy {
    max-width: 480px;
}

.cta-copy h2 {
    color: #fff;
    margin-bottom: 10px;
}

.cta-copy p {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.65);
    line-height: 1.65;
}

.cta-download {
    margin-top: 12px;
}

.cta-download a {
    color: #fff;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.cta-download a:hover {
    color: rgba(255, 255, 255, 0.85);
}

.cta-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex-shrink: 0;
}

/* Footer */
.footer {
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding-top: 36px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 32px;
    padding-bottom: 40px;
}

.footer-brand {
    max-width: 360px;
}

.footer-brand p {
    margin-top: 6px;
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.footer-desc {
    margin-top: 10px;
    line-height: 1.65;
}

.footer-server {
    font-family: ui-monospace, 'Cascadia Code', Consolas, monospace;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--accent);
}

.footer-links,
.footer-social {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links a,
.footer-social a {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    transition: color 0.2s;
}

.footer-links a:hover,
.footer-social a:hover {
    color: var(--text);
}

.footer-bottom {
    padding: 20px 0 28px;
    border-top: 1px solid var(--border);
}

.footer-bottom p {
    font-size: 0.8125rem;
    color: var(--text-tertiary);
}

/* Legal pages — full layout */
.layout-legal {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.layout-legal main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.legal-page {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - var(--header-h));
}

.legal-page-hero {
    background: var(--dark);
    color: #fff;
    padding: 40px 0 36px;
    flex-shrink: 0;
}

.legal-page-hero-inner h1 {
    color: #fff;
    font-size: clamp(1.5rem, 3vw, 2rem);
    margin-bottom: 8px;
}

.legal-back-link {
    display: inline-block;
    font-size: 0.8125rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.55);
    margin-bottom: 20px;
    transition: color 0.2s;
}

.legal-back-link:hover {
    color: #fff;
}

.legal-meta {
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.5);
}

.legal-page-body {
    flex: 1;
    background: var(--bg);
    padding: 40px 0 56px;
}

.legal-page-grid {
    display: grid;
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 56px;
    align-items: start;
}

.legal-sidebar {
    position: sticky;
    top: calc(var(--header-h) + 24px);
}

.legal-toc {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
}

.legal-toc-label {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: 8px;
}

.legal-toc a {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
    padding: 6px 8px;
    border-radius: var(--radius);
    transition: color 0.2s, background 0.2s;
}

.legal-toc a:hover {
    color: var(--text);
    background: var(--bg);
}

.legal-article {
    max-width: 720px;
}

.legal-intro {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.75;
    padding-bottom: 28px;
    margin-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.legal-block {
    padding: 28px 0;
    border-bottom: 1px solid var(--border);
}

.legal-block:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.legal-block h2 {
    font-size: 1.0625rem;
    margin-bottom: 12px;
    scroll-margin-top: calc(var(--header-h) + 20px);
}

.legal-sub {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text);
    margin-top: 16px;
    margin-bottom: 8px;
}

.legal-block p {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.75;
}

.legal-block p + p {
    margin-top: 10px;
}

.legal-block ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.legal-block li {
    position: relative;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.65;
    padding: 8px 0 8px 20px;
    border-bottom: 1px solid var(--border);
}

.legal-block li strong {
    color: var(--text);
    font-weight: 600;
}

.legal-block li:last-child {
    border-bottom: none;
}

.legal-block li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 1.1em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--border-strong);
}

.layout-legal .footer {
    margin-top: auto;
    flex-shrink: 0;
}

/* 404 page */
.layout-error {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.layout-error main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.layout-error .footer {
    margin-top: auto;
}

.error-page {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 0 64px;
}

.error-page-inner {
    text-align: center;
    max-width: 440px;
}

.error-code {
    font-size: clamp(3rem, 10vw, 4.5rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1;
    color: var(--text-tertiary);
    margin-bottom: 16px;
}

.error-page-inner h1 {
    margin-bottom: 12px;
}

.error-lead {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 28px;
}

.error-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

/* Resources hub */
.layout-resources {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.layout-resources main {
    flex: 1;
}

.layout-resources .footer {
    margin-top: auto;
}

.resources-hub {
    flex: 1;
}

.resources-hub-hero {
    padding: 36px 0 32px;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
}

.resources-back {
    display: inline-block;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-tertiary);
    margin-bottom: 20px;
    transition: color 0.2s;
}

.resources-back:hover {
    color: var(--text);
}

.resources-hub-lead {
    max-width: 58ch;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-top: 10px;
}

.resources-hub-meta {
    margin-top: 14px;
    font-size: 0.8125rem;
    color: var(--text-tertiary);
}

.resources-hub-meta a {
    color: var(--text);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.hub-empty {
    text-align: center;
    padding: 48px 24px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
}

.hub-empty p {
    margin-bottom: 16px;
    color: var(--text-secondary);
}

.hub-card-media {
    display: block;
    margin: -2px -2px 4px;
    border-radius: calc(var(--radius-lg) - 2px);
    overflow: hidden;
    border-bottom: 1px solid var(--border);
    background: var(--bg);
}

.hub-card-media img {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.hub-card-author {
    font-size: 0.75rem;
    color: var(--text-tertiary);
}

.resources-hub-body {
    padding: 40px 0 56px;
}

.hub-section {
    margin-bottom: 48px;
}

.hub-section:last-child {
    margin-bottom: 0;
}

.hub-section-head {
    margin-bottom: 20px;
}

.hub-section-head h2 {
    margin-bottom: 6px;
}

.hub-section-head p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.6;
    max-width: 60ch;
}

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

.hub-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 100%;
    padding: 18px 18px 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    cursor: pointer;
    position: relative;
    z-index: 1;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.hub-card > * {
    pointer-events: none;
}

.hub-card:hover {
    border-color: var(--border-strong);
    box-shadow: var(--shadow);
    transform: translateY(-1px);
}

.hub-card--static {
    cursor: default;
}

.hub-card--static:hover {
    transform: none;
    box-shadow: none;
}

.hub-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.hub-card-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.35;
}

.hub-card-badge {
    flex-shrink: 0;
    font-size: 0.625rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    padding: 3px 7px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--bg);
}

.hub-card-desc {
    flex: 1;
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.hub-card-link {
    margin-top: auto;
    padding-top: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-tertiary);
    transition: color 0.2s;
}

.hub-card:hover .hub-card-link {
    color: var(--text);
}

/* Shared hub pages */
.page-hub-hero {
    background: var(--surface);
    color: var(--text);
    padding: 40px 0 36px;
    border-bottom: 1px solid var(--border);
}

.page-hub-hero h1 {
    color: var(--text);
}

.page-hub-back {
    display: inline-block;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-tertiary);
    margin-bottom: 20px;
    transition: color 0.2s;
}

.page-hub-back:hover {
    color: var(--text);
}

.page-hub-eyebrow {
    color: var(--text-tertiary);
}

.page-hub-lead {
    max-width: 58ch;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.page-hub-meta {
    margin-top: 14px;
    font-size: 0.8125rem;
    color: var(--text-tertiary);
    line-height: 1.6;
}

.page-hub-meta a {
    color: var(--text);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.page-hub-body {
    background: var(--bg);
}

.page-hub-cta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 8px;
    padding-top: 28px;
    border-top: 1px solid var(--border);
}

.status-hub-hero.page-hub-hero,
.streams-hub-hero.page-hub-hero,
.remember-hub-hero.page-hub-hero {
    background: var(--surface);
    color: var(--text);
}

.status-hub-hero.page-hub-hero h1,
.streams-hub-hero.page-hub-hero h1,
.remember-hub-hero.page-hub-hero h1,
.status-panel h2,
.status-usage h2,
.status-community h2 {
    color: var(--text);
}

.status-hub-hero.page-hub-hero .eyebrow,
.status-hub-hero.page-hub-hero .page-hub-eyebrow,
.streams-hub-hero.page-hub-hero .eyebrow,
.streams-hub-hero.page-hub-hero .page-hub-eyebrow,
.remember-hub-hero.page-hub-hero .eyebrow,
.remember-hub-hero.page-hub-hero .page-hub-eyebrow,
.status-hub-hero.page-hub-hero .page-hub-back,
.streams-hub-hero.page-hub-hero .page-hub-back,
.remember-hub-hero.page-hub-hero .page-hub-back {
    color: var(--text-tertiary);
}

.status-hub-hero.page-hub-hero .page-hub-back:hover,
.streams-hub-hero.page-hub-hero .page-hub-back:hover,
.remember-hub-hero.page-hub-hero .page-hub-back:hover {
    color: var(--text);
}

.status-hub-hero.page-hub-hero .page-hub-lead,
.status-hub-hero.page-hub-hero .page-hub-meta,
.streams-hub-hero.page-hub-hero .page-hub-lead,
.streams-hub-hero.page-hub-hero .page-hub-meta,
.remember-hub-hero.page-hub-hero .page-hub-lead,
.remember-hub-hero.page-hub-hero .page-hub-meta {
    color: var(--text-secondary);
}

.status-hub-hero.page-hub-hero .page-hub-meta a,
.streams-hub-hero.page-hub-hero .page-hub-meta a {
    color: var(--text);
}

.status-panel {
    color: var(--text);
}

.status-list-label {
    color: var(--text-secondary);
}

.status-list-value,
.status-copy-btn {
    color: var(--text);
}

/* Status page */
.layout-status {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: clip;
}

.layout-status main {
    flex: 1;
    min-width: 0;
}

.layout-status .footer {
    margin-top: auto;
}

.status-hub {
    flex: 1;
    min-width: 0;
}

.status-hub-hero,
.streams-hub-hero {
    border-bottom: none;
}

.status-back {
    display: inline-block;
}

.status-hub-lead,
.status-hub-meta {
    max-width: none;
}

.status-hub-body {
    padding: 32px 0 56px;
}

.status-hub-body .wrap {
    min-width: 0;
}

.status-empty {
    text-align: center;
    padding: 48px 24px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
}

.status-empty p {
    margin-bottom: 16px;
    color: var(--text-secondary);
}

.status-empty-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.status-highlight-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
}

.status-highlight-card {
    padding: 18px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    min-width: 0;
    box-shadow: var(--shadow);
}

.status-highlight-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: 8px;
}

.status-highlight-value {
    display: block;
    font-size: clamp(1.125rem, 2vw, 1.375rem);
    font-weight: 700;
    color: var(--text);
    line-height: 1.2;
    word-break: break-word;
}

.status-capacity {
    margin-top: 16px;
    padding: 20px 22px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
}

.status-capacity-head,
.status-capacity-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.status-capacity-head h2 {
    margin: 0 0 3px;
    font-size: 1rem;
}

.status-capacity-head p,
.status-capacity-meta {
    color: var(--text-secondary);
    font-size: 0.8125rem;
}

.status-capacity-head strong {
    color: var(--text);
    font-size: 1.125rem;
    white-space: nowrap;
}

.status-capacity-meta {
    margin-top: 16px;
    margin-bottom: 7px;
}

.status-capacity-track {
    height: 10px;
    overflow: hidden;
    border-radius: 999px;
    background: var(--surface-muted);
}

.status-capacity-fill {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #22c55e;
    transition: width 0.35s var(--ease);
}

.status-capacity-fill.is-medium {
    background: #f59e0b;
}

.status-capacity-fill.is-high {
    background: #ef4444;
}

.status-panels {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
}

.status-panel {
    padding: 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    min-width: 0;
    box-shadow: var(--shadow);
}

.status-panel h2 {
    font-size: 1rem;
    margin-bottom: 14px;
}

.status-list {
    display: flex;
    flex-direction: column;
}

.status-list-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 11px 0;
    border-bottom: 1px solid var(--border);
}

.status-list-row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.status-list-label {
    flex: 1 1 52%;
    min-width: 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.status-list-value {
    flex: 0 1 48%;
    min-width: 0;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.5;
    text-align: right;
    word-break: break-word;
}

.status-copy-btn {
    background: none;
    border: none;
    padding: 0;
    font: inherit;
    cursor: pointer;
    transition: color 0.2s;
}

.status-copy-btn:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.status-copy-btn.is-copied {
    color: #166534;
}

.status-state-value.is-online {
    color: #16a34a;
}

.status-state-value.is-offline {
    color: #dc2626;
}

.status-usage {
    margin-bottom: 24px;
    padding: 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.status-viewer {
    margin-bottom: 24px;
    padding: 0;
    background: #0a0a0a;
    border: 1px solid #1f1f1f;
    border-radius: var(--radius-lg);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
    min-width: 0;
    overflow: hidden;
}

.ts-viewer {
    position: relative;
    min-height: 520px;
    max-height: min(80vh, 900px);
    overflow: auto;
    background: #0a0a0a;
    color: #e8e8e4;
    scrollbar-color: #333333 #0a0a0a;
    scrollbar-width: thin;
}

.ts-viewer-loading,
.ts-viewer-error {
    display: grid;
    place-items: center;
    min-height: 280px;
    padding: 24px;
    color: #9a9a96;
    text-align: center;
}

.ts-viewer-loading[hidden],
.ts-viewer-error[hidden],
.viewer-container[hidden] {
    display: none !important;
}

.ts-viewer-error p {
    margin: 0;
}

.viewer-container {
    padding: 16px 20px 24px;
    font-size: 14px;
    line-height: 1.45;
    color: #e8e8e4;
}

.viewer-container:not(.is-loaded) {
    opacity: 0.72;
}

.viewer-container .channel-container:not(.is-server),
.viewer-container .client-container {
    margin-left: 1.4em;
}

.viewer-container .channel-container:not(.is-spacer) .channel,
.viewer-container .client-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.viewer-container .channel-container:not(.is-spacer) > .channel > .channel-name,
.viewer-container .channel-container:not(.is-spacer) > .channel > .channel-icons,
.viewer-container .client-name,
.viewer-container .client-icons {
    display: flex;
    align-items: center;
}

.viewer-container .channel-container:not(.is-spacer) > .channel > .channel-name,
.viewer-container .client-name {
    min-width: 0;
    word-break: break-word;
}

.viewer-container .client-icons {
    flex-wrap: wrap;
    justify-content: flex-end;
}

.viewer-container .client-icons .icon,
.viewer-container .client-icons .icon-flag,
.viewer-container .channel-icons .icon {
    margin-left: 0.5em;
}

.viewer-container .channel-container:not(.is-spacer) .channel,
.viewer-container .client-container {
    position: relative;
    z-index: 0;
    cursor: default;
}

.viewer-container .channel-container:not(.is-spacer) .channel {
    cursor: pointer;
}

.viewer-container .channel-container:not(.is-spacer) .channel::after,
.viewer-container .client-container::after {
    content: "";
    z-index: -1;
    position: absolute;
    top: -3px;
    left: -10px;
    bottom: -3px;
    right: -10px;
    border-radius: 4px;
    background-color: rgba(255, 255, 255, 0.08);
    opacity: 0;
    transition: opacity ease 200ms;
}

.viewer-container .channel-container:not(.is-spacer) .channel:hover::after,
.viewer-container .client-container:hover::after,
.viewer-container .channel-container:not(.is-spacer) .channel:focus::after,
.viewer-container .client-container:focus::after {
    opacity: 1;
}

.viewer-container .channel-container:not(.is-spacer) .channel:focus,
.viewer-container .client-container:focus {
    outline: none;
}

.viewer-container .channel-name .icon,
.viewer-container .client-name .icon {
    margin-right: 0.5em;
}

.viewer-container .icon {
    height: 16px;
    max-width: 16px;
}

.viewer-container .channel-container.is-server > .channel > .channel-name {
    font-weight: 600;
    color: #ffffff;
}

.viewer-container .channel-container.spacer-left > .channel {
    text-align: left;
}

.viewer-container .channel-container.spacer-center > .channel {
    text-align: center;
    color: #d4d4d0;
}

.viewer-container .channel-container.spacer-right > .channel {
    text-align: right;
    color: #8f8f8b;
}

.viewer-container .channel-container.spacer-repeat > .channel {
    overflow: hidden;
    white-space: nowrap;
    color: #3a3a3a;
}

.viewer-container .client-name {
    color: #d7d7d3;
}

.ts-client-popover {
    position: fixed;
    z-index: 1200;
    min-width: 220px;
    max-width: min(320px, calc(100vw - 24px));
    border: 1px solid #2f2f2f;
    border-radius: var(--radius);
    background: #141414;
    color: #f2f2f0;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
    pointer-events: none;
}

.ts-client-popover-header {
    padding: 10px 12px;
    border-bottom: 1px solid #2a2a2a;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.35;
    word-break: break-word;
}

.ts-client-popover-body {
    padding: 10px 12px 12px;
    font-size: 0.8125rem;
}

.ts-client-popover-table {
    width: 100%;
    border-collapse: collapse;
}

.ts-client-popover-table th,
.ts-client-popover-table td {
    padding: 4px 0;
    vertical-align: top;
    text-align: left;
}

.ts-client-popover-table th {
    padding-right: 12px;
    color: #b8b8b4;
    font-weight: 600;
    white-space: nowrap;
}

.ts-client-popover-table td {
    color: #f2f2f0;
}

.ts-client-popover-loading,
.ts-client-popover-error {
    margin: 0;
    color: #9a9a96;
}

.status-usage-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.status-usage h2 {
    font-size: 1rem;
    margin: 0;
}

.status-usage-select {
    appearance: none;
    min-width: 160px;
    padding: 8px 32px 8px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface-muted) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%235c5c5c' d='M1 1l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 12px center;
    color: var(--text);
    font: inherit;
    font-size: 0.875rem;
    cursor: pointer;
}

.status-usage-chart-wrap {
    position: relative;
    height: 320px;
    min-width: 0;
}

.status-usage-chart-loading {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.status-usage-chart-loading[hidden] {
    display: none !important;
}

.status-ping-history {
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.status-ping-history h3 {
    margin-bottom: 14px;
}

.status-uptime {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.status-uptime-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 14px;
}

.status-uptime h3 {
    margin: 0;
    font-size: 0.9375rem;
    color: var(--text);
}

.status-uptime-current {
    margin: 0;
    text-align: right;
}

.status-uptime-current-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-tertiary);
    margin-bottom: 4px;
}

.status-uptime-current strong {
    font-size: 0.9375rem;
    color: var(--text);
    font-variant-numeric: tabular-nums;
}

.status-uptime-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.status-uptime-meta strong {
    color: var(--text);
    font-size: 0.875rem;
}

.status-uptime-bar {
    display: flex;
    gap: 2px;
    align-items: stretch;
    height: 30px;
    width: 100%;
    min-width: 0;
}

.status-uptime-segment {
    flex: 1 1 0;
    min-width: 1px;
    border-radius: 2px;
    cursor: crosshair;
}

.status-uptime-tooltip {
    position: fixed;
    z-index: 200;
    pointer-events: none;
    padding: 8px 12px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    color: var(--text);
    font-size: 0.8125rem;
    line-height: 1.4;
    white-space: nowrap;
}

.status-uptime-tooltip strong {
    display: block;
    font-size: 0.875rem;
    margin-bottom: 2px;
}

.status-uptime-tooltip span {
    color: var(--text-secondary);
}

.status-uptime-segment.is-up {
    background: #22c55e;
}

.status-uptime-segment.is-down {
    background: #ef4444;
}

.status-uptime-legend {
    display: flex;
    gap: 16px;
    margin-top: 10px;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.status-uptime-legend span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.status-uptime-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 2px;
}

.status-uptime-dot.is-up {
    background: #22c55e;
}

.status-uptime-dot.is-down {
    background: #ef4444;
}

.status-community {
    margin-bottom: 24px;
}

.status-community h2 {
    margin-bottom: 14px;
}

.status-community-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}

.status-community-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 18px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    min-width: 0;
    box-shadow: var(--shadow);
}

.status-community-card strong {
    font-size: 1.125rem;
    color: var(--text);
    line-height: 1.2;
}

.status-community-card span {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Remember page */
.layout-remember {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: clip;
}

.layout-remember main {
    flex: 1;
    min-width: 0;
}

.layout-remember .footer {
    margin-top: auto;
}

.remember-hub {
    flex: 1;
    min-width: 0;
}

.remember-hub-body {
    padding: 32px 0 56px;
}

.remember-wrap {
    max-width: 1040px;
}

.remember-empty {
    padding: 40px 24px;
    text-align: center;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
    color: var(--text-secondary);
}

.remember-section + .remember-section,
.remember-empty + .remember-faq,
.remember-section + .remember-faq {
    margin-top: 48px;
    padding-top: 48px;
    border-top: 1px solid var(--border);
}

.remember-section-head {
    margin-bottom: 28px;
    text-align: center;
}

.remember-section-head h2 {
    margin: 0 0 10px;
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    color: var(--text);
}

.remember-section-head p {
    margin: 0 auto;
    max-width: 52ch;
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.65;
}

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

.remember-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 14px;
    height: 100%;
    padding: 28px 20px 24px;
    overflow: visible;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.remember-section--memoriam .remember-card {
    border-color: var(--border);
}

.remember-avatar-wrap {
    flex-shrink: 0;
    margin-top: 10px;
}

.remember-section--memoriam .remember-avatar {
    width: 72px;
    height: 96px;
    border-radius: 0;
    background: transparent;
    border: none;
    box-shadow: none;
}

.remember-section--memoriam .remember-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.12));
}

[data-theme="dark"] .remember-section--memoriam .remember-avatar img {
    filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.28)) drop-shadow(0 2px 8px rgba(0, 0, 0, 0.35));
}

.remember-avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--surface-muted);
    border: 2px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
}

.remember-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.remember-avatar-fallback {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-secondary);
    letter-spacing: 0.04em;
}

.remember-card-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    width: 100%;
}

.remember-name {
    margin: 0;
    font-size: 1.0625rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1.3;
}

.remember-role {
    margin: 0;
    min-height: 1.05em;
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    line-height: 1.4;
}

.remember-role.is-empty {
    visibility: hidden;
}

.remember-years {
    margin: 0;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.remember-note {
    margin: 8px 0 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.55;
}

.remember-faq-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 720px;
    margin: 0 auto;
}

.remember-faq-item {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.remember-faq-item summary {
    list-style: none;
    cursor: pointer;
    padding: 16px 18px;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.45;
}

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

.remember-faq-item summary::after {
    content: '+';
    float: right;
    font-size: 1.125rem;
    font-weight: 500;
    color: var(--text-tertiary);
    line-height: 1.2;
}

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

.remember-faq-item[open] summary {
    border-bottom: 1px solid var(--border);
}

.remember-faq-answer {
    padding: 14px 18px 18px;
}

.remember-faq-answer p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.65;
}

@media (max-width: 768px) {
    .remember-grid {
        grid-template-columns: 1fr;
    }
}

/* Streams page */
.layout-streams {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: clip;
}

.layout-streams main {
    flex: 1;
    min-width: 0;
}

.layout-streams .footer {
    margin-top: auto;
}

.streams-hub {
    flex: 1;
    min-width: 0;
}

.streams-back {
    display: inline-block;
}

.streams-hub-body {
    padding: 32px 0 56px;
}

.streams-section {
    margin-bottom: 40px;
}

.streams-section:last-child {
    margin-bottom: 0;
}

.streams-section-head {
    margin-bottom: 18px;
}

.streams-section-head h2 {
    margin-bottom: 0;
}

.streams-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 14px;
}

.streams-grid--live {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.stream-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.stream-card:hover {
    border-color: var(--border-strong);
    box-shadow: var(--shadow);
    transform: translateY(-1px);
}

.stream-card--live {
    border-color: #bbf7d0;
}

.stream-card-media {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    overflow: hidden;
}

.stream-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.stream-card-live-tag {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #fff;
    background: #dc2626;
}

.stream-card-body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 18px;
    min-width: 0;
}

.stream-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.stream-card-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.stream-card-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid var(--border);
}

.stream-card-ident {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.stream-card-name {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.3;
}

.stream-card-platform {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.stream-platform--kick {
    color: #3f6212;
    background: #ecfccb;
}

.stream-platform--twitch {
    color: #5b21b6;
    background: #ede9fe;
}

.stream-card-status {
    flex-shrink: 0;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-tertiary);
}

.stream-card-status.is-live {
    color: #166534;
}

.stream-card-title,
.stream-card-desc {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.stream-card-title {
    color: var(--text);
    font-weight: 500;
}

.stream-card-meta {
    font-size: 0.8125rem;
    color: var(--text-tertiary);
}

.stream-card-link {
    margin-top: auto;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.stream-card:hover .stream-card-link {
    color: var(--text);
}

/* Responsive */
@media (max-width: 960px) {
    .hero-grid,
    .about-grid,
    .cta-inner {
        grid-template-columns: 1fr;
        display: grid;
    }

    .hero-copy {
        padding-right: 0;
    }

    .hero-media {
        order: -1;
    }

    .about-grid--reverse .about-media {
        order: -1;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .cta-actions {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .legal-page-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .hub-grid {
        grid-template-columns: 1fr;
    }

    .legal-sidebar {
        position: static;
    }

    .legal-toc {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 6px;
    }

    .legal-toc-label {
        width: 100%;
        margin-bottom: 4px;
    }

    .legal-toc a {
        padding: 5px 10px;
        background: var(--bg);
        border: 1px solid var(--border);
    }
}

@media (max-width: 1180px) {
    .header-right {
        gap: 18px;
    }

    .nav {
        gap: 20px;
    }

    .lang-dropdown-current-label {
        display: none;
    }

    .lang-dropdown-toggle {
        padding: 0 10px;
        gap: 6px;
    }
}

@media (max-width: 1100px) {
    .header-right {
        gap: 14px;
    }

    .nav {
        gap: 18px;
    }

    .header-cta {
        padding: 0 10px;
        font-size: 0.75rem;
    }
}

@media (max-width: 960px) {
    .header-inner {
        justify-content: space-between;
    }

    .brand {
        margin-right: 0;
    }

    .nav {
        position: fixed;
        top: var(--header-h);
        left: 0;
        right: 0;
        flex: none;
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
        gap: 0;
        background: var(--surface);
        border-bottom: 1px solid var(--border);
        padding: 12px 4vw 20px;
        transform: translateY(-110%);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: transform 0.25s var(--ease), opacity 0.25s, visibility 0.25s;
    }

    .nav.is-open {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
        pointer-events: all;
    }

    .nav a {
        width: 100%;
        padding: 12px 0;
        border-bottom: 1px solid var(--border);
    }

    .header-cta {
        display: none;
    }

    .header-actions {
        gap: 8px;
    }

    .header-right {
        gap: 10px;
    }

    .menu-btn {
        display: flex;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .cta-actions {
        flex-direction: column;
        width: 100%;
    }

    .cta-actions .btn {
        width: 100%;
    }

    .status-list-row {
        grid-template-columns: 1fr;
        gap: 4px;
    }
}

@media (max-width: 720px) {
    .status-list-row {
        flex-direction: column;
        gap: 4px;
    }

    .status-list-value {
        text-align: left;
    }

    .page-hub-cta .btn {
        width: 100%;
    }

    .staff-apply-grid {
        grid-template-columns: 1fr;
    }
}

/* Staff application */
.layout-staff-apply {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.layout-staff-apply main {
    flex: 1;
}

.layout-staff-apply .footer {
    margin-top: auto;
}

.staff-apply-hub {
    flex: 1;
}

.staff-apply-hero {
    padding: 36px 0 32px;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
}

.staff-apply-lead {
    max-width: 58ch;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-top: 10px;
}

.staff-apply-note {
    margin-top: 14px;
    font-size: 0.8125rem;
    color: var(--text-tertiary);
}

.staff-apply-body {
    padding: 32px 0 56px;
}

.staff-apply-form {
    max-width: 720px;
}

.staff-apply-honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.staff-apply-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 20px;
}

.staff-apply-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.staff-apply-field--full {
    grid-column: 1 / -1;
}

.staff-apply-field label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}

.staff-apply-required {
    color: #c0392b;
}

.staff-apply-field input[type="text"],
.staff-apply-field input[type="email"],
.staff-apply-field input[type="url"],
.staff-apply-field input[type="number"],
.staff-apply-field select,
.staff-apply-field textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--text);
    font: inherit;
    line-height: 1.5;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.staff-apply-field textarea {
    resize: vertical;
    min-height: 120px;
}

.staff-apply-field input:focus,
.staff-apply-field select:focus,
.staff-apply-field textarea:focus {
    outline: none;
    border-color: var(--text-tertiary);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--text) 8%, transparent);
}

.staff-apply-field.has-error input,
.staff-apply-field.has-error select,
.staff-apply-field.has-error textarea {
    border-color: #c0392b;
}

.staff-apply-hint {
    font-size: 0.8125rem;
    color: var(--text-tertiary);
    margin: 0;
}

.staff-apply-error {
    font-size: 0.8125rem;
    color: #c0392b;
    margin: 0;
}

.staff-apply-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    line-height: 1.6;
    cursor: pointer;
}

.staff-apply-checkbox input {
    margin-top: 4px;
    flex-shrink: 0;
}

.staff-apply-privacy {
    margin: 20px 0 0;
    font-size: 0.8125rem;
    color: var(--text-tertiary);
    max-width: 58ch;
}

.staff-apply-actions {
    margin-top: 24px;
}

.staff-apply-alert {
    max-width: 720px;
    margin-bottom: 20px;
    padding: 14px 16px;
    border: 1px solid #c0392b;
    border-radius: var(--radius);
    background: color-mix(in srgb, #c0392b 8%, var(--surface));
    color: var(--text);
    font-size: 0.875rem;
}

.staff-apply-success {
    max-width: 56ch;
    padding: 32px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
}

.staff-apply-success h2 {
    margin-bottom: 10px;
}

.staff-apply-success p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 20px;
}
