/* module: 01-tokens.css */
@font-face {
    font-family: "IBM Plex Sans";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("fonts/ibm-plex-sans-400.woff2") format("woff2");
}
@font-face {
    font-family: "IBM Plex Sans";
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url("fonts/ibm-plex-sans-500.woff2") format("woff2");
}
@font-face {
    font-family: "IBM Plex Sans";
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url("fonts/ibm-plex-sans-600.woff2") format("woff2");
}
@font-face {
    font-family: "JetBrains Mono";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("fonts/jetbrains-mono-400.woff2") format("woff2");
}
@font-face {
    font-family: "JetBrains Mono";
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url("fonts/jetbrains-mono-500.woff2") format("woff2");
}
@font-face {
    font-family: "JetBrains Mono";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("fonts/jetbrains-mono-700.woff2") format("woff2");
}

:root {
    --bg: #0a0e16;
    --bg-elev: #0d121c;
    --bg-2: var(--bg-elev);
    --surface: #111722;
    --surface-2: #161e2e;
    --elev: #1c2535;
    --border: #1f2937;
    --border-strong: #2c3a52;
    --line: var(--border);
    --line-2: var(--border-strong);
    --text: #e6edf3;
    --text-2: #94a3b8;
    --muted: var(--text-2);
    --faint: #778698; /* WCAG AA (>=4.5:1 on --bg dark) for small hint/timestamp text; headroom for elevated surfaces */
    --phosphor: #39ff14;
    --accent: var(--phosphor);
    --accent-2: #fb7185;
    --warn: #fbbf24;
    --danger: #fb7185;
    --good: var(--phosphor);
    --blue: #7dd3fc;
    --purple: #a78bfa;
    --cyan: #5eead4;
    --shadow: 0 18px 46px rgba(0, 0, 0, 0.3);
    --radius: 14px;
    --radius-sm: 8px;
    --easing: cubic-bezier(0.2, 0.7, 0.2, 1);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --mobile-tabbar-h: 68px;
    --font-ui: "IBM Plex Sans", ui-sans-serif, system-ui, sans-serif;
    --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
    --font-display: Georgia, Cambria, "Times New Roman", serif;
    --serif: var(--font-display);
    --sans: var(--font-ui);
    --mono: var(--font-mono);
    --color-danger: var(--danger);
    --color-muted: var(--muted);
    --color-error: var(--danger);
    --c-top: var(--text);
    --c-kernel: var(--phosphor);
    --c-security: var(--danger);
    --c-distros: var(--warn);
    --c-desktop: var(--blue);
    --c-homelab: var(--cyan);
    --c-hardware: color-mix(in srgb, var(--warn) 55%, var(--danger) 45%);
    --c-linux-hardware: var(--c-hardware);
    --c-jobs: var(--purple);
    --c-gaming: var(--purple);
    --c-self-hosting: var(--cyan);
    --c-open-source-ai: var(--blue);
    --c-local-llm: var(--purple);
    --c-ai-hardware: var(--c-hardware);
    --c-robotics: var(--cyan);
    --c-storage: var(--cyan);
    --c-server: var(--good);
    --c-networking: var(--blue);
    --c-privacy: var(--purple);
    --c-developer-tools: var(--blue);
    --panel-bg: color-mix(in srgb, var(--surface) 94%, var(--bg));
    --panel-inset: var(--fill-subtle);
    --surface-glass: rgba(17, 23, 34, 0.72);
    --surface-glass-soft: rgba(17, 23, 34, 0.5);
    --surface-glass-muted: rgba(17, 23, 34, 0.45);
    --surface-glass-panel: rgba(13, 18, 28, 0.92);
    --surface-glass-dispatch: rgba(13, 18, 28, 0.5);
    --header-bg: rgba(10, 10, 12, 0.88);
    --header-border: rgba(38, 42, 54, 0.84);
    --nav-hover-bg: var(--fill-muted);
    --button-bg: var(--fill-muted);
    --button-hover-bg: rgba(255, 255, 255, 0.08);
    --input-bg: rgba(255, 255, 255, 0.045);
    --chip-bg: rgba(255, 255, 255, 0.035);
    --tag-bg: var(--fill-muted);
    --overlay-bg: rgba(8, 10, 12, 0.72);
    --tabbar-bg: rgba(10, 10, 12, 0.9);
    --modal-border: rgba(255, 255, 255, 0.08);
    --modal-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
    --accent-on: var(--bg);
    --selection-bg: var(--accent);
    --selection-fg: var(--accent-on);
    --why-box-bg: var(--accent-surface);
    --dotgrid-color: rgba(57, 255, 20, 0.06);
    --dotgrid-opacity: 0.55;
    --body-glow-a: rgba(227, 242, 39, 0.13);
    --body-glow-b: rgba(255, 87, 34, 0.1);
    --notice-fg: #ffd99a;
    --notice-bg: var(--warn-surface);
    --notice-border: var(--warn-line);
    --logo-grad-a: var(--accent-ring);
    --logo-grad-b: rgba(255, 87, 34, 0.05);
    --badge-green-border: var(--accent-line);
    --tag-hover-border: var(--accent-line);
    /* Semantic fills — derive from theme (consistent in light + dark) */
    --fill-subtle: color-mix(in srgb, var(--text) 3%, transparent);
    --fill-muted: color-mix(in srgb, var(--text) 5%, transparent);
    --fill-hover: color-mix(in srgb, var(--text) 6%, transparent);
    --accent-surface: color-mix(in srgb, var(--accent) 5.5%, transparent);
    --accent-surface-strong: color-mix(in srgb, var(--accent) 12%, transparent);
    --accent-ring: color-mix(in srgb, var(--accent) 18%, transparent);
    --accent-line: color-mix(in srgb, var(--accent) 36%, transparent);
    --accent-line-strong: color-mix(in srgb, var(--accent) 55%, transparent);
    --warn-surface: color-mix(in srgb, var(--warn) 8%, transparent);
    --warn-line: color-mix(in srgb, var(--warn) 32%, transparent);
    --danger-surface: color-mix(in srgb, var(--danger) 8%, transparent);
    --danger-line: color-mix(in srgb, var(--danger) 40%, transparent);
    --blue-line: color-mix(in srgb, var(--blue) 36%, transparent);
    --cyan-line: color-mix(in srgb, var(--cyan) 38%, transparent);
    --good-line: color-mix(in srgb, var(--good) 36%, transparent);
    --pre-bg: color-mix(in srgb, var(--surface) 90%, var(--bg));
    --code-inline-bg: color-mix(in srgb, var(--text) 5%, transparent);
    --card-hover-bg: color-mix(in srgb, var(--surface-2) 92%, var(--elev));
    --hero-shade: linear-gradient(
        0deg,
        color-mix(in srgb, var(--bg) 98%, transparent) 0%,
        color-mix(in srgb, var(--bg) 72%, transparent) 40%,
        color-mix(in srgb, var(--bg) 12%, transparent) 68%,
        transparent 100%
    );
    --rank-pill-bg: color-mix(in srgb, var(--bg) 72%, transparent);
    --featured-card-bg: linear-gradient(
        180deg,
        color-mix(in srgb, var(--text) 5.5%, transparent),
        color-mix(in srgb, var(--text) 2%, transparent)
    ), var(--panel-bg);
    --sponsor-warn-bg: linear-gradient(180deg, var(--warn-surface), var(--panel-bg));
    --sponsor-drill-bg: linear-gradient(
        180deg,
        color-mix(in srgb, var(--cyan) 9%, transparent),
        var(--panel-bg)
    );
    --sponsor-tribe-bg: linear-gradient(180deg, var(--warn-surface), var(--panel-bg));
    --job-featured-bg: linear-gradient(180deg, var(--accent-surface), var(--panel-bg));
    --skeleton-shine: color-mix(in srgb, var(--text) 5%, transparent);
    --skeleton-shine-mid: color-mix(in srgb, var(--text) 11%, transparent);
    --image-scrim: linear-gradient(
        180deg,
        transparent 48%,
        color-mix(in srgb, var(--bg) 18%, transparent)
    );
    --art-overlay: linear-gradient(
        180deg,
        color-mix(in srgb, var(--text) 4%, transparent),
        transparent 34%
    );
    --art-shine: radial-gradient(
        circle at 30% 18%,
        color-mix(in srgb, var(--text) 10%, transparent),
        transparent 24%
    );
    --comment-thread-line: color-mix(in srgb, var(--accent) 26%, transparent);
    --card-shadow-rest: 0 1px 2px color-mix(in srgb, #000 25%, transparent);
    --card-shadow-hover: 0 10px 26px color-mix(in srgb, #000 30%, transparent);
    --art-cover-accent: var(--topic-accent, var(--accent));
}

:root[data-theme="light"] {
    --bg: #f4f6f0;
    --bg-elev: #ecefe6;
    --bg-2: var(--bg-elev);
    --surface: #ffffff;
    --surface-2: #f0f3eb;
    --elev: #e4e9de;
    --border: #d5dccf;
    --border-strong: #b8c4ae;
    --line: var(--border);
    --line-2: var(--border-strong);
    --text: #141a12;
    --text-2: #3d4a38;
    --muted: #5a6654;
    --faint: #7a8774;
    --phosphor: #1a7a14;
    --accent: var(--phosphor);
    --accent-2: #c53030;
    --warn: #9a6700;
    --danger: #b42318;
    --good: var(--phosphor);
    --blue: #0b6e99;
    --purple: #5b21b6;
    --cyan: #0d7a6f;
    --shadow: 0 12px 32px rgba(20, 30, 15, 0.1);
    --panel-bg: rgba(255, 255, 255, 0.96);
    --panel-inset: rgba(255, 255, 255, 1);
    --surface-glass: rgba(255, 255, 255, 0.94);
    --surface-glass-soft: rgba(255, 255, 255, 0.9);
    --surface-glass-muted: rgba(244, 247, 240, 0.98);
    --surface-glass-panel: rgba(255, 255, 255, 0.98);
    --surface-glass-dispatch: rgba(240, 245, 235, 0.95);
    --header-bg: rgba(244, 246, 240, 0.94);
    --header-border: rgba(200, 210, 195, 0.92);
    --nav-hover-bg: rgba(20, 26, 18, 0.06);
    --button-bg: rgba(255, 255, 255, 0.92);
    --button-hover-bg: #ffffff;
    --input-bg: #ffffff;
    --chip-bg: rgba(20, 26, 18, 0.04);
    --tag-bg: rgba(20, 26, 18, 0.05);
    --overlay-bg: rgba(244, 246, 240, 0.98);
    --tabbar-bg: rgba(244, 246, 240, 0.96);
    --modal-border: rgba(20, 26, 18, 0.1);
    --modal-shadow: 0 20px 50px rgba(20, 30, 15, 0.14);
    --accent-on: #f8faf4;
    --why-box-bg: var(--accent-surface);
    --dotgrid-color: rgba(26, 122, 20, 0.14);
    --dotgrid-opacity: 0.35;
    --body-glow-a: rgba(26, 122, 20, 0.09);
    --body-glow-b: rgba(255, 87, 34, 0.05);
    --notice-fg: #7a4f00;
    --notice-border: rgba(154, 103, 0, 0.32);
    --logo-grad-a: rgba(26, 122, 20, 0.14);
    --logo-grad-b: rgba(13, 122, 111, 0.06);
    --badge-green-border: var(--good-line);
    --tag-hover-border: var(--accent-line);
    --selection-bg: rgba(26, 122, 20, 0.22);
    --selection-fg: var(--text);
    --card-shadow-rest: 0 1px 2px color-mix(in srgb, var(--text) 8%, transparent);
    --card-shadow-hover: 0 10px 26px color-mix(
        in srgb,
        var(--text) 12%,
        transparent
    );
    --notice-bg: var(--warn-surface);
    --notice-border: var(--warn-line);
    color-scheme: light;
}

* {
    box-sizing: border-box;
}
html {
    color-scheme: dark;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-ui);
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}
body {
    margin: 0;
    min-height: 100vh;
    overflow-x: hidden;
    background:
        radial-gradient(circle at 18% -12%, var(--body-glow-a), transparent 30rem),
        radial-gradient(circle at 88% 0%, var(--body-glow-b), transparent 28rem),
        var(--bg);
}
body.has-mobile-tabs {
    padding-bottom: 0;
}
body.search-open {
    overflow: hidden;
}
::selection {
    background: var(--selection-bg, var(--accent));
    color: var(--selection-fg, var(--accent-on));
}
a {
    color: inherit;
    text-decoration: none;
}
a:hover {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}
button,
input,
select,
textarea {
    font: inherit;
}
button {
    cursor: pointer;
    color: inherit;
}
img,
svg {
    max-width: 100%;
}
code {
    font-family: var(--mono);
    color: var(--accent);
}
:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

.container {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}
.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    border-bottom: 1px solid var(--header-border);
    background: var(--header-bg);
    backdrop-filter: blur(18px) saturate(140%);
}
.header-inner {
    min-height: 74px;
    display: flex;
    align-items: center;
    gap: 20px;
    justify-content: space-between;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--text);
}
.brand:hover {
    text-decoration: none;
}
.logo-mark {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line-2);
    border-radius: 8px;
    background: linear-gradient(145deg, var(--logo-grad-a), var(--logo-grad-b));
    font-family: var(--mono);
    color: var(--accent);
    font-weight: 700;
    letter-spacing: -0.05em;
}
.brand-title {
    display: block;
    font-family: var(--serif);
    font-style: italic;
    font-weight: 700;
    letter-spacing: -0.045em;
    font-size: 24px;
    line-height: 0.9;
}
.brand-subtitle {
    display: block;
    color: var(--faint);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-top: 5px;
}
.nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 4px;
}
.nav a {
    color: var(--muted);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.04em;
    padding: 8px 10px;
    border-radius: 8px;
    border: 1px solid transparent;
}
.nav a:hover,
.nav a.active {
    color: var(--text);
    background: var(--nav-hover-bg);
    border-color: var(--line);
    text-decoration: none;
}
.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.icon-btn {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--text);
    transition:
        transform 0.14s ease,
        background 0.14s ease,
        border-color 0.14s ease;
    position: relative;
}
.icon-btn:hover {
    background: var(--surface-2);
    border-color: var(--line-2);
}
.icon-btn:active {
    transform: scale(0.94);
}
.icon-btn svg {
    width: 17px;
    height: 17px;
}
.icon-btn[data-count]:not([data-count="0"])::after {
    content: attr(data-count);
    position: absolute;
    top: -7px;
    right: -7px;
    min-width: 19px;
    padding: 2px 5px;
    border-radius: 999px;
    border: 2px solid var(--bg);
    background: var(--accent-2);
    color: var(--text);
    font-family: var(--mono);
    font-size: 10px;
    line-height: 1.1;
}

/* module: 02-components.css */
/* Shared typography and controls */
.eyebrow {
    color: var(--accent);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}
h1,
h2,
h3 {
    margin: 0;
    letter-spacing: -0.035em;
}
h1 {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 600;
    font-size: clamp(42px, 7vw, 80px);
    line-height: 0.94;
}
h2 {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 600;
    font-size: clamp(27px, 4vw, 44px);
    line-height: 1;
}
h3 {
    font-family: var(--serif);
    font-weight: 600;
    font-size: 20px;
    line-height: 1.17;
}
p {
    color: var(--muted);
    line-height: 1.62;
}
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid var(--line);
    color: var(--text);
    background: var(--button-bg);
    padding: 11px 15px;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition:
        transform 0.14s ease,
        background 0.14s ease,
        border-color 0.14s ease;
}
.button:hover {
    text-decoration: none;
    background: var(--button-hover-bg);
    border-color: var(--line-2);
}
.button:active {
    transform: scale(0.97);
}
.button.primary {
    background: var(--accent);
    color: var(--accent-on);
    border-color: var(--accent);
}
.button.secondary {
    background: var(--surface-2);
    color: var(--text);
    border-color: var(--line-2);
}
.button.tertiary {
    background: transparent;
    color: var(--muted);
}
.button.icon {
    width: 38px;
    height: 38px;
    padding: 0;
}
.button.destructive {
    background: var(--danger-surface);
    color: var(--danger);
    border-color: var(--danger-line);
}
.button.small {
    padding: 8px 11px;
    font-size: 13px;
}
.button.ghost {
    background: transparent;
}
.button:disabled,
.button.loading {
    opacity: 0.6;
    pointer-events: none;
}
.button.loading {
    position: relative;
    color: transparent !important;
}
.button.loading::after {
    content: "";
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
}
.button.loading::after {
    content: "";
    width: 18px;
    height: 18px;
    border: 2px solid var(--muted);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    margin: auto;
}
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}
.panel,
.card,
.story-card,
.topic-card,
.source-card,
.job-card,
.package-card {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--panel-bg);
    box-shadow: 0 1px 0 var(--panel-inset) inset;
}
.panel.pad,
.card,
.story-card,
.topic-card,
.source-card,
.job-card,
.package-card {
    padding: 18px;
}
.panel.pad h2 {
    font-size: 30px;
    line-height: 1.08;
}
.card h2,
.story-card h2,
.topic-card h2,
.source-card h2,
.job-card h2,
.package-card h2 {
    font-size: 24px;
    line-height: 1.12;
    letter-spacing: -0.02em;
}
.card h3,
.story-card h3,
.topic-card h3,
.source-card h3,
.job-card h3,
.package-card h3 {
    font-size: 18px;
    line-height: 1.16;
    letter-spacing: -0.015em;
}
.notice {
    padding: 12px 14px;
    border: 1px solid var(--notice-border);
    border-radius: 8px;
    color: var(--notice-fg);
    background: var(--notice-bg);
    font-size: 13px;
    line-height: 1.45;
}
hr {
    border: 0;
    border-top: 1px solid var(--line);
    margin: 20px 0;
}
.input,
input,
select,
textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--input-bg);
    color: var(--text);
    padding: 12px 13px;
    outline: none;
}
input::placeholder,
textarea::placeholder {
    color: var(--faint);
}
textarea {
    min-height: 120px;
    resize: vertical;
}
.form-grid {
    display: grid;
    gap: 12px;
}
.turnstile-host {
    position: fixed;
    right: max(16px, env(safe-area-inset-right, 0px));
    bottom: max(16px, calc(var(--safe-bottom) + 16px));
    z-index: 120;
    max-width: min(320px, calc(100vw - 32px));
}
.turnstile-host:empty {
    display: none;
}
.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}
.field-label {
    color: var(--muted);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.check-grid {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px;
    display: grid;
    gap: 9px;
    color: var(--muted);
}
.check-grid legend {
    color: var(--text);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0 6px;
}
.check-grid label,
.check-line {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    line-height: 1.4;
    color: var(--muted);
    font-size: 13px;
}
.check-grid input,
.check-line input {
    width: auto;
    margin-top: 2px;
    accent-color: var(--accent);
}
.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px 8px;
    color: var(--muted);
    background: var(--chip-bg);
    font-family: var(--mono);
    font-size: 11px;
}
.badge.green {
    border-color: var(--badge-green-border);
    color: var(--accent);
}
.badge.blue {
    border-color: var(--blue-line);
    color: var(--blue);
}
.badge.warn {
    border-color: var(--warn-line);
    color: var(--warn);
}
.badge.danger {
    border-color: var(--danger-line);
    color: var(--danger);
}
.tags {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
}
.tag {
    color: var(--muted);
    background: var(--tag-bg);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px 8px;
    font-size: 12px;
}
.tag:hover {
    color: var(--text);
    border-color: var(--tag-hover-border);
    text-decoration: none;
}
.badge,
.tag,
.chip {
    white-space: nowrap;
}
.inline-icon,
.button svg,
.pill-btn svg,
.subscribe-pill svg {
    width: 1em;
    height: 1em;
    flex: none;
}
.story-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
    color: var(--faint);
    font-family: var(--mono);
    font-size: 11px;
}
.story-summary {
    margin: 0;
    color: var(--muted);
}
.why-box {
    border-left: 3px solid var(--accent);
    padding: 11px 13px;
    background: var(--why-box-bg);
    color: var(--text);
    border-radius: 0 12px 12px 0;
}
.section {
    padding: 34px 0;
}
.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}
.section-head p {
    margin: 8px 0 0;
    max-width: 690px;
}
.layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 22px;
}
.sidebar {
    display: grid;
    gap: 14px;
    align-content: start;
}
.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}
.filter-bar {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 20px 0;
}
.kpi {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 16px;
    background: var(--fill-subtle);
}
.kpi strong {
    display: block;
    font-size: 25px;
    letter-spacing: -0.04em;
}
.kpi span {
    display: block;
    color: var(--faint);
    font-size: 12px;
    margin-top: 4px;
}

/* module: 03-publication.css */
/* Signal Desk static publication surfaces */
.signal-hero {
    padding-top: 44px;
}
.signal-hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(400px, 500px);
    gap: 36px;
    align-items: start;
}
.signal-hero-grid > *,
.signal-desk-grid > *,
.layout > * {
    min-width: 0;
}
.signal-hero-copy {
    min-height: 0;
    padding-top: 160px;
    display: grid;
    align-content: start;
    gap: 18px;
}
.signal-beta {
    width: max-content;
    margin: 0;
    color: var(--accent);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    border: 1px solid var(--accent-line);
    border-radius: 8px;
    padding: 6px 8px;
    background: var(--accent-surface);
}
.signal-hero h1 {
    max-width: 560px;
    font-size: 56px;
    line-height: 1;
    letter-spacing: -0.025em;
    overflow-wrap: normal;
}
.signal-hero h1 .hero-line {
    display: inline-block;
    max-width: 100%;
    white-space: nowrap;
}
.signal-hero .dek {
    max-width: 610px;
    overflow-wrap: anywhere;
}
.hero-cta-row,
.source-action-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 9px;
}
.signal-stat-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
    color: var(--muted);
    font-family: var(--mono);
    font-size: 11px;
}
.signal-stat-row span {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 7px 9px;
    background: var(--fill-subtle);
}
.signal-stat-row strong {
    color: var(--text);
}
.today-signal-card,
.featured-story-card {
    position: relative;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--featured-card-bg);
    box-shadow: var(--shadow);
}
.today-signal-card {
    padding: 22px;
    display: grid;
    gap: 16px;
    min-width: 0;
    align-self: start;
}
.signal-panel-head,
.rail-card-head,
.topic-lane-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}
.signal-panel-head h2 {
    font-size: clamp(24px, 3vw, 34px);
    overflow-wrap: anywhere;
}
.signal-count {
    margin: 0;
    color: var(--faint);
    font-family: var(--mono);
    font-size: 11px;
    overflow-wrap: anywhere;
}
.signal-list {
    display: grid;
    gap: 0;
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: signal;
}
.signal-item {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 12px;
    padding: 15px 0;
    border-top: 1px solid var(--line);
}
.signal-item > * {
    min-width: 0;
}
.signal-item:first-child {
    border-top: 0;
    padding-top: 0;
}
.signal-index {
    color: var(--topic-accent, var(--accent));
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 700;
}
.signal-item h3 {
    font-family: var(--serif);
    font-size: 18px;
    line-height: 1.12;
    overflow-wrap: anywhere;
}
.signal-item p {
    margin: 7px 0;
    line-height: 1.45;
    overflow-wrap: anywhere;
}
.signal-desk {
    padding-top: 12px;
}
.signal-desk-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 22px;
    align-items: start;
}
.signal-main {
    min-width: 0;
}
.signal-rail {
    display: grid;
    gap: 14px;
    position: sticky;
    top: 96px;
}
.compact-head {
    margin-bottom: 12px;
}
.compact-head h2 {
    font-size: clamp(24px, 3vw, 34px);
}
.latest-head {
    margin-top: 22px;
}
.featured-story-card {
    padding: 24px;
    overflow: hidden;
    border-left: 4px solid var(--topic-accent, var(--accent));
}
.featured-story-card h2 {
    max-width: 900px;
    margin: 14px 0 10px;
}
.featured-story-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
    color: var(--faint);
    font-family: var(--mono);
    font-size: 11px;
}
.source-action-row {
    margin-top: 16px;
}
.source-action-row.compact {
    margin-top: 2px;
}
.editorial-story-card,
.topic-lane,
.source-card,
.job-card,
.package-card {
    border-left: 3px solid var(--topic-accent, transparent);
}
.rail-card {
    display: grid;
    gap: 12px;
}
.rail-list {
    display: grid;
    gap: 0;
    margin: 0;
    padding: 0;
    list-style: none;
}
.rail-list li {
    display: grid;
    gap: 4px;
    padding: 10px 0;
    border-top: 1px solid var(--line);
}
.rail-list li:first-child {
    border-top: 0;
    padding-top: 0;
}
.rail-list a {
    color: var(--text);
    font-weight: 700;
    line-height: 1.25;
}
.rail-list span {
    color: var(--faint);
    font-family: var(--mono);
    font-size: 11px;
}
.topic-lane-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 14px;
}
.topic-lane {
    border: 1px solid var(--line);
    border-left: 3px solid var(--topic-accent, var(--accent));
    border-radius: var(--radius);
    padding: 16px;
    background: var(--surface-glass);
}
.topic-lane h3 {
    margin: 12px 0 8px;
}
.topic-lane p {
    min-height: 80px;
    margin: 0 0 12px;
    font-size: 14px;
    line-height: 1.5;
}
.lane-story-list {
    display: grid;
    gap: 8px;
    margin: 0;
    padding-left: 18px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.35;
}
.compact-source-grid .source-card {
    font-size: 14px;
}
.page-hero {
    padding-bottom: 10px;
}
.narrow-page-head {
    max-width: 940px;
}
.source-directory {
    display: grid;
    gap: 28px;
}
.source-role-group {
    display: grid;
    gap: 12px;
}
.source-facts {
    display: grid;
    gap: 8px;
    margin: 14px 0;
}
.source-facts div {
    display: grid;
    gap: 3px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--fill-subtle);
}
.source-facts dt {
    color: var(--faint);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.source-facts dd {
    margin: 0;
    color: var(--text);
    font-size: 13px;
}
.brief-track-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin: 22px 0;
}
.sample-issue {
    margin-top: 18px;
}
.jobs-board-hero .layout,
.sponsor-hero .layout,
.newsletter-hero .layout {
    align-items: start;
}
.job-filter-bar {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 20px 0;
}
.job-card[hidden] {
    display: none;
}
.stacked-packages {
    display: grid;
    gap: 10px;
}
.stacked-packages div {
    display: grid;
    gap: 4px;
    border-top: 1px solid var(--line);
    padding-top: 10px;
}
.stacked-packages div:first-child {
    border-top: 0;
    padding-top: 0;
}
.stacked-packages span {
    color: var(--muted);
    font-size: 13px;
}
.sponsor-kpis {
    margin-top: 20px;
}
.sponsor-package-card {
    display: grid;
    align-content: start;
}
.sponsor-example {
    margin-bottom: 14px;
    border-color: var(--warn-line);
}
#privacy-main,
#corrections-main {
    max-width: 850px;
}
#privacy-main .panel,
#corrections-main .panel {
    margin-top: 18px;
    overflow-x: auto;
}
#privacy-main .panel:first-of-type,
#corrections-main .panel:first-of-type {
    margin-top: 24px;
}
.admin-table,
.table {
    width: 100%;
    min-width: 620px;
    border-collapse: separate;
    border-spacing: 0;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--fill-subtle);
}
.admin-table th,
.admin-table td {
    border-bottom: 1px solid var(--line);
    border-right: 1px solid var(--line);
    padding: 12px 10px;
    text-align: left;
    vertical-align: top;
}
.admin-table th:last-child,
.admin-table td:last-child,
.table th:last-child,
.table td:last-child {
    border-right: 0;
}
.admin-table tr:last-child td,
.table tr:last-child td {
    border-bottom: 0;
}
.admin-table th {
    color: var(--accent);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: var(--accent-surface);
}
.table-enhanced th {
    cursor: pointer;
    user-select: none;
}
.table-enhanced th:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: -2px;
}
.sort-indicator {
    margin-left: 6px;
    color: var(--faint);
    font-size: 9px;
    letter-spacing: 0.05em;
}
.table-row-expandable {
    cursor: pointer;
}
.table-row-expandable:not(.is-expanded) td {
    max-width: 320px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.admin-table td {
    color: var(--muted);
    line-height: 1.5;
}

/* module: 04-home.css */
/* Home / app shell */
.home-app {
    padding: 28px 0 16px;
}
.daily-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: start;
    margin-bottom: 18px;
}
.date-line {
    color: var(--faint);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.daily-title {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 500;
    font-size: clamp(40px, 8vw, 68px);
    letter-spacing: -0.04em;
    line-height: 0.95;
    max-width: 880px;
    margin-top: 8px;
}
.daily-title em {
    color: var(--accent);
}
.daily-summary {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    color: var(--faint);
    font-family: var(--mono);
    font-size: 11px;
    margin-top: 12px;
}
.daily-summary b {
    color: var(--muted);
    font-weight: 600;
}
.daily-actions {
    display: flex;
    gap: 8px;
}
.home-pane {
    display: none;
}
.home-pane.active {
    display: block;
    animation: fade-in 0.24s ease both;
}
@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.home-section {
    padding: 24px 0 0;
}
.home-section-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    margin-bottom: 14px;
}
.home-section-title {
    font-family: var(--serif);
    font-size: 25px;
    font-weight: 600;
    letter-spacing: -0.025em;
}
.home-section-title em {
    color: var(--accent);
    font-style: italic;
    font-weight: 400;
}
.section-tag {
    color: var(--faint);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.hero-rail,
.trending-rail {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    padding: 4px 2px 18px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}
.hero-rail::-webkit-scrollbar,
.trending-rail::-webkit-scrollbar,
.chip-rail::-webkit-scrollbar {
    display: none;
}
.hero-card {
    flex: 0 0 min(440px, calc(100vw - 48px));
    min-height: 520px;
    border-radius: 22px;
    overflow: hidden;
    position: relative;
    background: var(--surface);
    border: 1px solid var(--line);
    scroll-snap-align: start;
    box-shadow: var(--shadow);
}
.hero-cover {
    position: absolute;
    inset: 0;
}
.hero-cover svg,
.hero-cover img {
    width: 100%;
    height: 100%;
    display: block;
}
.topic-art-frame {
    position: relative;
    width: 100%;
    height: auto;
    min-height: 0;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background:
        radial-gradient(
            circle at 76% 24%,
            color-mix(in srgb, var(--topic-accent, var(--accent)) 20%, transparent),
            transparent 42%
        ),
        linear-gradient(
            135deg,
            color-mix(in srgb, var(--text) 5%, transparent),
            color-mix(in srgb, var(--text) 1%, transparent)
        ),
        var(--surface-2);
}
.hero-cover .topic-art-frame,
.trend-cover .topic-art-frame,
.app-card-cover .topic-art-frame,
.topic-page-art .topic-art-frame {
    height: 100%;
    min-height: 100%;
    aspect-ratio: auto;
}
.topic-art-frame::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: var(--art-overlay), var(--art-shine);
    mix-blend-mode: screen;
    opacity: 0.55;
}
.topic-art-img,
.topic-art-fallback,
.topic-art-fallback svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}
.topic-art-fallback {
    color: var(--topic-accent, var(--accent));
}
.topic-art-img {
    z-index: 1;
    display: block;
    object-fit: cover;
    object-position: var(--art-x, 50%) var(--art-y, 50%);
    transform: scale(var(--art-scale, 1)) rotate(var(--art-rotate, 0deg));
    filter:
        hue-rotate(var(--art-hue, 0deg))
        saturate(var(--art-sat, 1))
        brightness(var(--art-bright, 1));
}
.topic-art-fallback {
    z-index: 0;
}
.topic-art-fallback svg {
    display: block;
}
.topic-art-frame.is-fallback .topic-art-fallback {
    z-index: 1;
}
.topic-art-frame.is-fallback::after {
    z-index: 2;
}
.hero-shade {
    position: absolute;
    inset: 0;
    background: var(--hero-shade);
}
.hero-body {
    position: absolute;
    z-index: 2;
    left: 24px;
    right: 24px;
    bottom: 24px;
}
.hero-title {
    font-size: 31px;
    line-height: 1.04;
    margin: 14px 0 12px;
}
.hero-dek {
    margin: 0 0 15px;
    color: var(--muted);
    line-height: 1.5;
}
.hero-links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 14px;
}
.trend-card {
    flex: 0 0 190px;
    scroll-snap-align: start;
}
.trend-cover {
    border: 1px solid var(--line);
    border-radius: 18px;
    aspect-ratio: 5 / 4;
    overflow: hidden;
    background: var(--surface);
    position: relative;
    margin-bottom: 10px;
}
.trend-cover svg,
.trend-cover img {
    display: block;
    width: 100%;
    height: 100%;
}
.trend-rank {
    position: absolute;
    top: 10px;
    left: 10px;
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    background: var(--rank-pill-bg);
    border: 1px solid var(--line-2);
    border-radius: 999px;
    padding: 4px 7px;
}
.trend-rank span {
    color: var(--accent);
}
.trend-head {
    font-family: var(--serif);
    font-size: 16px;
    line-height: 1.18;
    margin: 0 0 6px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.trend-meta {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--faint);
}
.chip-rail {
    display: flex;
    gap: 7px;
    overflow-x: auto;
    scrollbar-width: none;
    padding: 0 1px 18px;
}
.chip {
    flex: 0 0 auto;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--muted);
    border-radius: 999px;
    padding: 9px 13px;
    font-family: var(--mono);
    font-size: 11px;
    transition:
        background 0.14s ease,
        color 0.14s ease,
        transform 0.14s ease;
}
.chip.active {
    background: var(--text);
    color: var(--accent-on);
    border-color: var(--text);
    font-weight: 700;
}
.chip:active {
    transform: scale(0.95);
}
.chip .count {
    opacity: 0.55;
    margin-left: 4px;
    font-size: 10px;
}
.account-chip {
    min-height: 32px;
    display: inline-flex;
    align-items: center;
    max-width: 150px;
    padding: 0 11px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text);
    font-family: var(--mono);
    font-size: 11px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.account-chip:hover {
    background: var(--surface-2);
    border-color: var(--line-2);
    text-decoration: none;
}
.account-chip.signed-in {
    border-color: var(--blue-line);
}
.account-profile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.account-avatar {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    border: 1px solid var(--line);
    object-fit: cover;
    float: left;
    margin: 0 12px 8px 0;
}
.feed-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 18px;
    align-items: start;
}
.feed {
    display: grid;
    gap: 16px;
}
.app-card {
    padding: 0;
    overflow: hidden;
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    min-height: 185px;
}
.app-card-cover {
    position: relative;
    background: var(--surface-2);
    min-height: 100%;
}
.app-card-cover svg,
.app-card-cover img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 185px;
    object-fit: cover;
}
.card-save {
    position: absolute;
    top: 11px;
    right: 11px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--line-2);
    background: var(--rank-pill-bg);
    display: grid;
    place-items: center;
    color: var(--text);
    backdrop-filter: blur(8px);
}
.card-save.saved {
    color: var(--accent);
    border-color: var(--accent-line-strong);
}
.card-save svg {
    width: 16px;
    height: 16px;
}
.app-card-body {
    padding: 18px;
    display: grid;
    gap: 10px;
    align-content: start;
}
.app-card h3 {
    font-size: 23px;
}
.app-card h3 a {
    color: var(--text);
}
.card-dek {
    margin: 0;
    color: var(--muted);
    line-height: 1.45;
}
.card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 2px;
}
.inline-link {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--accent);
}
.inline-link.secondary {
    color: var(--muted);
}
.status-stack {
    display: grid;
    gap: 14px;
    position: sticky;
    top: 96px;
}
.status-card {
    overflow: hidden;
    position: relative;
}
.status-card::before {
    content: "";
    position: absolute;
    top: -70px;
    right: -70px;
    width: 180px;
    height: 180px;
    background: var(--accent);
    filter: blur(70px);
    opacity: 0.12;
}
.status-label {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--accent);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    margin-bottom: 12px;
}
.live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse {
    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.35;
        transform: scale(0.86);
    }
}
.status-big {
    font-family: var(--serif);
    font-style: italic;
    font-size: 45px;
    line-height: 1;
    letter-spacing: -0.045em;
}
.status-big span {
    color: var(--accent);
}
.status-row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 8px 0;
    border-bottom: 1px solid var(--line);
    font-family: var(--mono);
    font-size: 12px;
}
.status-row:last-child {
    border-bottom: 0;
}
.status-row .k {
    color: var(--faint);
}
.status-row .v {
    color: var(--text);
}
.news-card {
    position: relative;
    overflow: hidden;
    padding: 24px;
}
.news-card::before {
    content: "";
    position: absolute;
    top: -60px;
    left: -60px;
    width: 160px;
    height: 160px;
    background: var(--accent);
    filter: blur(55px);
    opacity: 0.14;
}
.news-card > * {
    position: relative;
}
.news-card h3 {
    font-size: 28px;
    font-style: italic;
    margin-bottom: 8px;
}
.jobs-strip {
    display: grid;
    gap: 12px;
}
.job-mini {
    border-top: 1px solid var(--line);
    padding-top: 12px;
}
.sponsor-slot {
    border-color: var(--warn-line);
    background: var(--sponsor-warn-bg);
    overflow: hidden;
}
.sponsor-shot {
    position: relative;
    margin: -19px -19px 16px;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-bottom: 1px solid var(--line);
    background: var(--fill-muted);
}
.sponsor-shot::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        var(--image-scrim),
        inset 0 0 0 1px var(--modal-border);
    pointer-events: none;
}
.sponsor-shot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.house-ad-stack {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 14px 0;
}
.house-ad-stack--single {
    grid-template-columns: minmax(0, 1fr);
}
.sidebar .house-ad-stack,
.signal-rail .house-ad-stack,
.status-stack .house-ad-stack {
    grid-template-columns: minmax(0, 1fr);
}
.house-ad-showcase {
    margin: 34px 0 10px;
}
.sponsor-slot h2,
.sponsor-slot h3 {
    margin-bottom: 8px;
}
.sponsor-slot p {
    margin-bottom: 10px;
}
.sponsor-proof {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.45;
}
.sponsor-category {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.35;
}
.sponsor-slot .badge.warn {
    border-color: var(--warn-line);
    color: var(--warn);
    letter-spacing: 0;
}
.sponsor-slot--drill {
    border-color: var(--cyan-line);
    background: var(--sponsor-drill-bg);
}
.sponsor-slot--drill .badge.warn {
    border-color: var(--cyan-line);
    color: var(--cyan);
}
.sponsor-slot--tribe {
    border-color: var(--warn-line);
    background: var(--sponsor-tribe-bg);
}
.sponsor-slot--tribe .sponsor-shot img {
    filter: brightness(1.08) contrast(1.08) saturate(1.04);
}
.sponsor-slot--compact {
    display: grid;
    grid-template-columns: minmax(96px, 34%) minmax(0, 1fr);
    gap: 10px 14px;
    align-items: start;
}
.sponsor-slot--compact .sponsor-shot {
    grid-row: 1 / span 6;
    margin: 0;
    aspect-ratio: 1 / 1;
    border: 1px solid var(--line);
    border-radius: 8px;
}
.sponsor-slot--compact .badge.warn,
.sponsor-slot--compact h2,
.sponsor-slot--compact h3,
.sponsor-slot--compact p {
    margin-bottom: 0;
}
.sponsor-slot--compact h2,
.sponsor-slot--compact h3 {
    font-size: clamp(20px, 2.1vw, 26px);
}
.sponsor-slot--compact .sponsor-proof {
    display: none;
}
.sponsor-slot--compact .sponsor-category {
    color: var(--faint);
}
.sponsor-slot--compact .sponsor-actions {
    margin-top: 4px;
}
.sponsor-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 0;
}
.sponsor-secondary {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.3;
}
@media (max-width: 720px) {
    .house-ad-stack {
        grid-template-columns: minmax(0, 1fr);
    }
    .sponsor-slot--compact {
        display: block;
    }
    .sponsor-slot--compact .sponsor-shot {
        aspect-ratio: 2.1 / 1;
        margin: -1px -1px 12px;
    }
}

/* module: 05-discuss-pages.css */
/* Discuss */
.discussion .sort-tab {
    font-family: var(--mono);
    font-size: 0.72rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.discussion .sort-tab.active {
    background: var(--accent-surface-strong);
    border-color: var(--accent);
    color: var(--accent);
}

.discuss-sort {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
    margin: 4px 0 16px;
}
.discuss-sort .sort-tab,
.discussion .sort-tab,
.sort-tab.feed-chip {
    border-radius: 6px;
}
.sort-tab.active,
.discuss-sort .sort-tab.active,
.discussion .sort-tab.active {
    background: var(--accent-surface);
    color: var(--text);
    border-color: var(--accent-line);
    font-weight: 600;
}
.discuss-list {
    display: grid;
    gap: 0;
    border: 1px solid var(--line);
    border-radius: 18px;
    overflow: hidden;
    background: var(--surface-glass);
}
.discuss-pane-status {
    margin: 12px 0 0;
    color: var(--muted);
    font-size: 0.95rem;
}
.discuss-pane-status--offline {
    color: var(--warn);
}
.discuss-pane-error {
    margin-top: 12px;
}
.discuss-filters {
    display: grid;
    gap: 0.75rem;
    margin-bottom: 1rem;
}
.discuss-topic-chips {
    flex-wrap: wrap;
}
.discuss-preview {
    margin: 0.35rem 0 0.5rem;
    color: var(--muted);
    font-size: 0.92rem;
}
.discuss-preview-author {
    color: var(--text);
    font-weight: 600;
}
.discuss-closed-badge,
.discuss-flagged-badge {
    font-size: 0.72rem;
}
.comment-reply-context {
    margin: 0.15rem 0 0.35rem;
    font-size: 0.85rem;
    color: var(--muted);
}
.pill-btn--ghost {
    padding-inline: 0.45rem;
    min-height: auto;
    font-size: 0.78rem;
}
.saved-pane-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 12px 0 0;
}
.saved-sort {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 12px 0 0;
}
.saved-pane-status {
    margin: 12px 0 0;
    color: var(--muted);
    font-size: 0.95rem;
}
.saved-pane-status--offline {
    color: var(--warn);
}
.saved-pane-status--auth a {
    color: var(--accent);
}
.saved-pane-error {
    margin-top: 12px;
}
.saved-list {
    display: grid;
    gap: 0;
    margin-top: 16px;
    border: 1px solid var(--line);
    border-radius: 18px;
    overflow: hidden;
    background: var(--surface-glass);
}
.saved-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--line);
}
.saved-row:last-child {
    border-bottom: 0;
}
.saved-row:hover {
    background: var(--fill-hover);
}
.saved-head {
    margin: 8px 0 0;
    font-size: 1.05rem;
    line-height: 1.35;
}
.saved-row-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    flex-shrink: 0;
}
.tips-pane-status {
    margin: 12px 0 0;
    color: var(--muted);
    font-size: 0.95rem;
}
.tips-pane-status--offline {
    color: var(--warn);
}
.tips-pane-error {
    margin-top: 12px;
}
.tips-list {
    display: grid;
    gap: 0;
    margin-top: 16px;
    border: 1px solid var(--line);
    border-radius: 18px;
    overflow: hidden;
    background: var(--surface-glass);
}
.tips-row {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr);
    gap: 14px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--line);
}
.tips-row:last-child {
    border-bottom: 0;
}
.tips-rank {
    font-family: var(--serif);
    color: var(--muted);
    font-size: 1.1rem;
    padding-top: 4px;
}
.tips-head {
    margin: 8px 0 0;
    font-size: 1.05rem;
}
.tips-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}
.pill-btn--active {
    border-color: var(--accent-line);
    color: var(--accent);
}
.discuss-row {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr);
    gap: 14px;
    padding: 20px;
    border-bottom: 1px solid var(--line);
}
.discuss-row:last-child {
    border-bottom: 0;
}
.discuss-row:hover {
    background: var(--fill-hover);
}
.discuss-rank {
    font-family: var(--serif);
    font-style: italic;
    font-size: 34px;
    color: var(--faint);
    line-height: 0.9;
}
.discuss-row:nth-child(-n + 3) .discuss-rank {
    color: var(--accent);
}
.discuss-head {
    font-family: var(--serif);
    font-size: 22px;
    line-height: 1.12;
    margin-bottom: 8px;
}
.discuss-head a {
    color: var(--text);
}
.discuss-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 12px;
}
.pill-btn {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: transparent;
    color: var(--muted);
    padding: 7px 11px;
    font-family: var(--mono);
    font-size: 11px;
}
.pill-btn.voted {
    background: var(--accent);
    color: var(--accent-on);
    border-color: var(--accent);
    font-weight: 700;
}
.mod-note {
    color: var(--faint);
    font-family: var(--mono);
    font-size: 11px;
    margin-top: 10px;
}

/* Story discussion */
.discussion {
    scroll-margin-top: 90px;
}
.discussion-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 12px;
}
.discussion-head h2 {
    margin-bottom: 4px;
}
.comment-form {
    margin: 18px 0 22px;
}
.comment-form textarea {
    min-height: 132px;
    resize: vertical;
}
.comment-list {
    display: grid;
    gap: 0;
    border: 1px solid var(--border, var(--line));
    border-radius: 16px;
    overflow: hidden;
    background: var(--surface-glass);
}
.comment {
    position: relative;
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 10px;
    padding: 16px 18px;
    padding-left: calc(18px + var(--comment-depth, 0) * 24px);
    border-bottom: 1px solid var(--line);
}
.comment:last-child {
    border-bottom: 0;
}
.comment-line {
    width: 2px;
    align-self: stretch;
    background: var(--comment-thread-line);
    border-radius: 999px;
}
.comment-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    color: var(--faint);
    font-family: var(--mono);
    font-size: 11px;
    margin-bottom: 8px;
}
.comment-meta strong {
    color: var(--text);
}
.comment-body {
    color: var(--text);
    line-height: 1.55;
}
.comment-body p,
.comment-body ul,
.comment-body ol,
.comment-body blockquote,
.comment-body pre {
    margin: 0 0 10px;
}
.comment-body pre {
    overflow-x: auto;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--pre-bg);
}
.comment-body code {
    font-family: var(--mono);
    font-size: 0.92em;
}
.comment-body blockquote {
    padding-left: 12px;
    border-left: 2px solid var(--accent);
    color: var(--muted);
}
.comment-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 10px;
}
.comment.removed .comment-body {
    color: var(--faint);
    font-family: var(--mono);
    font-size: 12px;
}
.comment.collapsed .comment-body,
.comment.collapsed .comment-actions {
    display: none;
}

/* Legacy / route pages */
.story-list {
    display: grid;
    gap: 13px;
}
.story-card {
    display: grid;
    gap: 12px;
    transition:
        transform 0.14s ease,
        border-color 0.14s ease,
        background 0.14s ease;
}
.story-card:hover {
    transform: translateY(-1px);
    border-color: var(--accent-line);
    background: var(--card-hover-bg);
}
.story-card h3 a {
    color: var(--text);
}
.story-card-with-art {
    grid-template-columns: minmax(170px, 220px) minmax(0, 1fr);
    align-items: stretch;
}
.story-card-art {
    min-height: 100%;
}
.story-card-art .topic-art-frame {
    min-height: 180px;
    border: 1px solid var(--line);
    border-radius: 14px;
}
.story-card-content {
    display: grid;
    gap: 12px;
    align-content: start;
}
.topic-grid,
.source-grid,
.job-grid,
.package-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}
.source-groups {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}
.source-groups > div {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 14px;
    background: var(--fill-subtle);
}
.source-groups h3 {
    margin-top: 0;
}
.topic-card h3 a,
.job-card h3 a {
    color: var(--text);
}
.topic-card-visual {
    padding: 0;
    overflow: hidden;
}
.topic-card-art,
.topic-lane-art,
.featured-story-art {
    display: block;
    border-bottom: 1px solid var(--line);
}
.topic-card-art {
    aspect-ratio: 16 / 5;
    max-height: 126px;
}
.topic-lane-art {
    aspect-ratio: 16 / 7;
    max-height: 136px;
}
.featured-story-art {
    aspect-ratio: 16 / 7;
}
.topic-card-body {
    display: grid;
    gap: 10px;
    padding: 18px;
}
.topic-card-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 4px;
}
.topic-page-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 320px);
    gap: 22px;
    align-items: stretch;
    margin-bottom: 24px;
}
.topic-page-art {
    border: 1px solid var(--line);
    border-radius: 18px;
    overflow: hidden;
    min-height: 210px;
    box-shadow: var(--shadow);
}
.topic-lane {
    overflow: hidden;
}
.topic-lane-art {
    margin: -16px -16px 16px;
}
.featured-story-card--visual {
    overflow: hidden;
}
.featured-story-art {
    margin: -22px -22px 18px;
    max-height: 260px;
}
.job-card.featured {
    border-color: var(--accent-line-strong);
    background: var(--job-featured-bg);
}
.table th,
.table td {
    border-bottom: 1px solid var(--line);
    border-right: 1px solid var(--line);
    padding: 12px 10px;
    text-align: left;
    vertical-align: top;
}
.table th {
    color: var(--muted);
    font-size: 12px;
    font-family: var(--mono);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.table td {
    color: var(--text);
}
.article {
    max-width: 860px;
}
.article h1 {
    font-size: clamp(38px, 5vw, 62px);
    line-height: 0.98;
    margin-top: 12px;
}
.article .dek {
    font-size: 20px;
    color: var(--muted);
}
.article-section {
    margin: 28px 0;
}
.article-section ol,
.article-section ul,
.card ul,
.package-card ul {
    color: var(--muted);
    line-height: 1.7;
    padding-left: 22px;
}
.article-section li + li,
.card li + li,
.package-card li + li {
    margin-top: 8px;
}
.source-list {
    display: grid;
    gap: 8px;
}
.source-link {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px;
    background: var(--chip-bg);
}
.source-link span {
    color: var(--faint);
    font-family: var(--mono);
    font-size: 12px;
}
.empty {
    color: var(--faint);
    border: 1px dashed var(--line);
    border-radius: var(--radius);
    padding: 18px;
}
.empty a {
    color: var(--accent);
    text-decoration: underline;
}
.input-error {
    border-color: var(--danger) !important;
    animation: error-flash 0.4s ease;
}
@keyframes error-flash {
    0%,
    100% {
        box-shadow: 0 0 0 0 transparent;
    }
    50% {
        box-shadow: 0 0 0 3px var(--danger-line);
    }
}
.api-banner {
    border-bottom: 1px solid var(--warn-line);
    background: var(--warn-surface);
    color: var(--text);
    font-size: 13px;
}
.api-banner-inner {
    max-width: var(--max);
    margin: 0 auto;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.api-banner-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--warn);
    flex: 0 0 auto;
}
.api-banner--offline .api-banner-dot {
    background: var(--danger);
}
.api-banner-text {
    margin: 0;
    color: var(--muted);
    line-height: 1.45;
    flex: 1;
}
.api-banner-text strong {
    color: var(--text);
}
.api-banner-dismiss {
    width: 32px;
    height: 32px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--fill-muted);
    color: var(--muted);
    cursor: pointer;
}
.api-banner-dismiss:hover,
.api-banner-dismiss:focus-visible {
    color: var(--text);
    border-color: var(--accent);
}
.skip-to-content {
    position: absolute;
    top: -100px;
    left: 16px;
    z-index: 200;
    background: var(--accent);
    color: var(--accent-on);
    padding: 10px 16px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 14px;
    transition: top 0.2s ease;
}
.skip-to-content:focus {
    top: 12px;
}
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
.admin-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.status-pill {
    border-radius: 999px;
    padding: 4px 8px;
    font-size: 12px;
    font-family: var(--mono);
    border: 1px solid var(--line);
    color: var(--muted);
}
.status-pill.published {
    color: var(--accent);
    border-color: var(--accent-line);
}
.status-pill.review {
    color: var(--warn);
    border-color: var(--warn-line);
}
.footer {
    margin-top: 52px;
    padding: 36px 0;
    border-top: 1px solid var(--line);
    color: var(--faint);
}
.footer-grid {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 18px;
    align-items: start;
}
.footer a {
    color: var(--muted);
}
.footer-colophon {
    display: grid;
    gap: 10px;
    max-width: 560px;
}
.footer-colophon p {
    margin: 0;
    color: var(--muted);
}
.footer-brand {
    display: block;
    color: var(--text);
    font-family: var(--serif);
    font-size: clamp(34px, 5vw, 58px);
    font-style: italic;
    font-weight: 600;
    line-height: 0.95;
}
.footer-links {
    align-self: end;
    display: grid;
    gap: 8px;
}
.footer-link-row {
    margin: 0;
}
.footer-link-row--policies {
    color: var(--faint);
    font-size: 0.92em;
}

.story-lead {
    margin: 24px 0;
    color: var(--text);
    font-family: var(--serif);
    font-size: clamp(21px, 2.4vw, 30px);
    line-height: 1.32;
}
.dropcap::first-letter {
    float: left;
    margin: 6px 10px 0 0;
    color: var(--accent);
    font-size: 3.2em;
    line-height: 0.75;
}

.subscribe-pill {
    position: fixed;
    right: 18px;
    bottom: calc(18px + var(--safe-bottom));
    z-index: 35;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    padding: 0 13px;
    border: 1px solid var(--accent-line);
    border-radius: 999px;
    background: var(--surface-glass-panel);
    color: var(--text);
    box-shadow: var(--shadow);
    font-family: var(--mono);
    font-size: 12px;
    backdrop-filter: blur(14px);
}
.subscribe-pill:hover {
    background: var(--surface-2);
    text-decoration: none;
}

.skeleton-screen {
    min-height: 55vh;
}
.skeleton-line,
.skeleton-card {
    overflow: hidden;
    border-radius: 8px;
    background: linear-gradient(
        90deg,
        var(--skeleton-shine),
        var(--skeleton-shine-mid),
        var(--skeleton-shine)
    );
    background-size: 220% 100%;
    animation: skeleton-pulse 1.2s ease-in-out infinite;
}
.skeleton-line {
    height: 14px;
    margin-bottom: 13px;
}
.skeleton-line--eyebrow {
    width: min(180px, 42%);
}
.skeleton-line--title {
    width: min(720px, 92%);
    height: 52px;
}
.skeleton-line--dek {
    width: min(560px, 82%);
    height: 18px;
}
.skeleton-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 26px;
}
.skeleton-card {
    min-height: 132px;
    border: 1px solid var(--line);
}
@keyframes skeleton-pulse {
    to {
        background-position: -220% 0;
    }
}
@media (max-width: 760px) {
    .subscribe-pill {
        right: 12px;
        bottom: calc(var(--mobile-tabbar-h) + var(--safe-bottom) + 12px);
        width: 42px;
        padding: 0;
        justify-content: center;
    }
    .subscribe-pill span {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }
    .skeleton-grid {
        grid-template-columns: 1fr;
    }
}

/* module: 06-search-mobile.css */
/* Search overlay */
.search-overlay {
    position: fixed;
    inset: 0;
    z-index: 100;
    background: var(--bg);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(12px);
    transition:
        opacity 0.18s ease,
        visibility 0.18s ease,
        transform 0.26s cubic-bezier(0.2, 0.7, 0.2, 1);
    display: flex;
    justify-content: center;
}
.search-overlay.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}
.search-shell {
    width: min(720px, 100%);
    height: 100dvh;
    display: flex;
    flex-direction: column;
}
.search-head {
    padding: calc(env(safe-area-inset-top, 0px) + 16px) 16px 14px;
    display: flex;
    gap: 10px;
    align-items: center;
    border-bottom: 1px solid var(--line);
}
.search-input {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--surface);
    padding: 0 14px;
    min-height: 46px;
}
.search-input input {
    border: 0;
    background: transparent;
    padding: 0;
    border-radius: 0;
}
.search-input svg {
    width: 17px;
    height: 17px;
    color: var(--faint);
}
.search-close {
    border: 0;
    background: transparent;
    color: var(--accent);
    font-family: var(--mono);
    font-size: 12px;
    padding: 8px 4px;
}
.search-results {
    flex: 1;
    overflow-y: auto;
    padding: 22px 18px 54px;
}
.search-hint {
    font-family: var(--mono);
    color: var(--faint);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 14px;
}
.search-suggest {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.search-result {
    display: block;
    padding: 15px 0;
    border-bottom: 1px solid var(--line);
}
.search-result:hover {
    text-decoration: none;
}
.search-result .sr-cat {
    color: var(--accent);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 6px;
}
.search-result h3 {
    font-size: 18px;
    color: var(--text);
}
.search-result .sr-meta {
    margin-top: 6px;
    color: var(--faint);
    font-family: var(--mono);
    font-size: 11px;
}
.search-group + .search-group {
    margin-top: 20px;
}
.search-group h2 {
    font-size: 18px;
    margin-bottom: 4px;
}
.toast {
    position: fixed;
    left: 50%;
    bottom: 24px;
    transform: translateX(-50%) translateY(18px);
    z-index: 120;
    background: var(--text);
    color: var(--accent-on);
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 700;
    padding: 10px 14px;
    border-radius: 999px;
    opacity: 0;
    pointer-events: none;
    transition:
        opacity 0.24s ease,
        transform 0.24s ease;
}
.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
.spinner {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-family: var(--mono);
    font-size: 12px;
}
.spinner::before {
    content: "";
    width: 16px;
    height: 16px;
    border: 2px solid var(--line);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

/* Mobile bottom nav */
.mobile-tabbar {
    display: none;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    border-top: 1px solid var(--line);
    background: var(--tabbar-bg);
    backdrop-filter: blur(20px) saturate(140%);
    padding-bottom: var(--safe-bottom);
}
.mobile-tabbar-inner {
    width: min(720px, 100%);
    margin: 0 auto;
    height: var(--mobile-tabbar-h);
    display: grid;
    grid-template-columns: repeat(5, 1fr);
}
.mobile-tab {
    border: 0;
    background: transparent;
    color: var(--faint);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: 0.04em;
    position: relative;
    text-decoration: none;
}
.mobile-tab:hover {
    color: var(--accent);
    text-decoration: none;
}
.mobile-tab svg {
    width: 20px;
    height: 20px;
}
.mobile-tab.active {
    color: var(--accent);
}
.mobile-tab.active::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 28px;
    height: 2px;
    border-radius: 0 0 999px 999px;
    background: var(--accent);
}

@media (max-width: 1060px) {
    .signal-hero-grid,
    .signal-desk-grid,
    .feed-grid,
    .layout,
    .two-col {
        grid-template-columns: 1fr;
    }
    .signal-rail {
        position: static;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .topic-lane-grid,
    .brief-track-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .status-stack {
        position: static;
    }
    .topic-grid,
    .source-grid,
    .source-groups,
    .job-grid,
    .package-grid,
    .pricing-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .signal-hero h1 {
        max-width: 760px;
        font-size: 52px;
    }
    .signal-hero-copy {
        padding-top: 28px;
    }
}
@media (max-width: 760px) {
    body.has-mobile-tabs {
        padding-bottom: calc(var(--mobile-tabbar-h) + var(--safe-bottom));
    }
    .container {
        width: min(100% - 24px, 1180px);
    }
    .header-inner {
        min-height: 64px;
    }
    .brand-subtitle,
    .nav {
        display: none;
    }
    .brand-title {
        font-size: 25px;
    }
    .site-header .header-actions {
        display: flex;
    }
    .home-app {
        padding: 18px 0 0;
    }
    .daily-header {
        grid-template-columns: 1fr;
    }
    .daily-actions {
        display: none;
    }
    .daily-title {
        font-size: 34px;
    }
    .daily-summary {
        font-size: 10.5px;
    }
    .home-section {
        padding-top: 24px;
    }
    .hero-card {
        min-height: 410px;
        flex-basis: calc(100vw - 40px);
    }
    .hero-title {
        font-size: 27px;
    }
    .trending-rail {
        gap: 12px;
    }
    .trend-card {
        flex-basis: 148px;
    }
    .app-card {
        grid-template-columns: 1fr;
    }
    .app-card-cover {
        aspect-ratio: 16 / 7;
    }
    .app-card-cover svg,
    .app-card-cover img {
        min-height: auto;
    }
    .story-card-with-art {
        grid-template-columns: 1fr;
    }
    .story-card-art .topic-art-frame {
        min-height: 118px;
        aspect-ratio: 16 / 6;
    }
    .topic-page-hero {
        grid-template-columns: 1fr;
        gap: 14px;
        margin-bottom: 18px;
    }
    .topic-page-art {
        min-height: 128px;
    }
    .topic-card-art,
    .topic-lane-art {
        max-height: 112px;
    }
    .topic-card-body {
        padding: 16px;
    }
    .topic-card-actions {
        align-items: flex-start;
        flex-direction: column;
    }
    .featured-story-art {
        margin: -16px -16px 14px;
        max-height: 170px;
    }
    .topic-lane-art {
        margin: -16px -16px 14px;
    }
    .mobile-tabbar {
        display: block;
    }
    .static-mobile-tabbar {
        display: block;
    }
    .signal-hero {
        padding-top: 24px;
    }
    .signal-hero-copy {
        min-height: auto;
        padding-top: 0;
    }
    .signal-hero h1 {
        font-size: 38px;
        line-height: 1;
    }
    .today-signal-card,
    .featured-story-card {
        padding: 16px;
    }
    .signal-rail,
    .topic-lane-grid,
    .brief-track-grid {
        grid-template-columns: 1fr;
    }
    .signal-item {
        grid-template-columns: 34px minmax(0, 1fr);
    }
    .footer {
        padding-bottom: calc(36px + var(--mobile-tabbar-h));
    }
    .topic-grid,
    .source-grid,
    .source-groups,
    .job-grid,
    .package-grid,
    .pricing-grid,
    .kpi-grid,
    .form-row {
        grid-template-columns: 1fr;
    }
    .section-head {
        flex-direction: column;
        align-items: flex-start;
    }
    .footer-grid {
        grid-template-columns: 1fr;
    }
    .discuss-row {
        grid-template-columns: 42px minmax(0, 1fr);
        padding: 18px 14px;
    }
    .discuss-rank {
        font-size: 28px;
    }
}
.modal-overlay {
    position: fixed;
    inset: 0;
    background: var(--overlay-bg);
    display: grid;
    place-items: center;
    padding: 24px;
    z-index: 1000;
}
.modal-card {
    width: min(520px, 100%);
    background: var(--surface);
    border: 1px solid var(--modal-border);
    border-radius: 8px;
    padding: 24px;
    box-shadow: var(--modal-shadow);
}
.field-input {
    width: 100%;
    margin-bottom: 16px;
}
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}

/* module: 07-trust-focus-prose.css */
/* ── Live / Demo / Offline data-source trust indicator ────────────────────── */
.api-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 32px;
    padding: 0 11px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--chip-bg);
    color: var(--muted);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.02em;
    white-space: nowrap;
    cursor: pointer;
    transition:
        background 0.14s ease,
        border-color 0.14s ease,
        transform 0.14s ease;
}
.api-status:hover {
    background: var(--surface-2);
    border-color: var(--line-2);
}
.api-status:active {
    transform: scale(0.96);
}
.api-status:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}
.api-status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
    flex: none;
}
.api-status--live {
    color: var(--good);
    border-color: var(--good-line);
}
.api-status--live .api-status-dot {
    animation: pulse 1.6s ease-in-out infinite;
}
.api-status--demo,
.api-status--sample {
    color: var(--warn);
    border-color: var(--warn-line);
}
.api-status--offline {
    color: var(--danger);
    border-color: var(--danger-line);
}

.api-banner {
    border-bottom: 1px solid var(--line);
    background: var(--surface);
}
.api-banner--demo,
.api-banner--sample {
    background: var(--warn-surface);
    border-bottom-color: var(--warn-line);
}
.api-banner--offline {
    background: var(--danger-surface);
    border-bottom-color: var(--danger-line);
}
.api-banner-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 0;
}
.api-banner-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex: none;
}
.api-banner--demo .api-banner-dot,
.api-banner--sample .api-banner-dot {
    background: var(--warn);
}
.api-banner--offline .api-banner-dot {
    background: var(--danger);
}
.api-banner-text {
    margin: 0;
    flex: 1;
    color: var(--muted);
    font-family: var(--sans);
    font-size: 12.5px;
    line-height: 1.45;
}
.api-banner-text strong {
    color: var(--text);
    font-family: var(--mono);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-right: 4px;
}
.api-banner-dismiss {
    flex: none;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    border: 1px solid transparent;
    background: transparent;
    color: var(--muted);
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    transition:
        background 0.14s ease,
        color 0.14s ease,
        border-color 0.14s ease;
}
.api-banner-dismiss:hover {
    background: var(--fill-hover);
    color: var(--text);
    border-color: var(--line);
}
.api-banner-dismiss:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}
@media (max-width: 760px) {
    .api-banner-inner {
        width: min(100% - 24px, 1180px);
    }
    /* Header is tight on phones (brand + chip + 3 icons): collapse the chip to a
       compact dot. The full state stays available via aria-label + tap-to-toast,
       and the banner already spells out any non-live state. */
    .header-inner {
        gap: 12px;
    }
    .header-actions {
        gap: 6px;
    }
    .account-chip {
        max-width: 92px;
        padding: 0 8px;
    }
    .api-status {
        width: 34px;
        padding: 0;
        justify-content: center;
    }
    .api-status-label {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }
}
@media (max-width: 400px) {
    .account-chip {
        display: none;
    }
}
@media (max-width: 359px) {
    /* The base layout already fills a 320px viewport with no slack, so drop the
       subtle chip on ultra-narrow screens to avoid horizontal overflow. The
       non-live trust banner is full-width and still shows here, so the important
       demo/offline signal is never lost. */
    .api-status {
        display: none;
    }
}

/* ── interaction & focus polish (a11y + visual) ──────────────────────────────
   Layered on top of the global :focus-visible ring (never weakening it), plus
   disabled/empty/tag/label/motion refinements. CSS-only, token-based, and
   covered by the prefers-reduced-motion block above. */

/* Form fields: integrated focus (accent border + soft ring) replacing the
   detached outline. Text inputs match :focus-visible on click too, so mouse
   users get the same feedback. The ring stays a strong, visible indicator. */
.input:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: none;
    border-color: var(--accent);
    background: var(--accent-surface);
    box-shadow: 0 0 0 3px var(--accent-ring);
}

/* Links: unify keyboard focus with the hover underline (outline still applies). */
a:focus-visible {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

/* Buttons: accent border to match hover. Primary has an accent (yellow) fill, so
   the global accent outline is nearly invisible on it — switch that ring to text. */
.button:focus-visible {
    border-color: var(--accent);
}
.button.primary:focus-visible {
    outline-color: var(--text);
}

/* Cards: keyboard focus mirrors the hover lift + glow, on top of the ring. */
.story-card:focus-visible,
.app-card:focus-visible {
    transform: translateY(-1px);
    border-color: var(--accent-line);
}

/* Search results & icon buttons: subtle accent reinforcement on focus. */
.search-result:focus-visible {
    background: var(--accent-surface);
    box-shadow: inset 2px 0 0 var(--accent);
}
.icon-btn:focus-visible {
    border-color: var(--accent);
}
.mobile-tab:focus-visible {
    outline-offset: -3px;
    border-radius: 8px;
}

/* Disabled buttons: read as disabled beyond opacity (don't touch .loading). */
.button:disabled:not(.loading) {
    background: var(--surface-2);
    border-color: var(--line);
    cursor: not-allowed;
}
.icon-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* Empty state: a faint wash so it reads as intentional, not absent. */
.empty {
    background: var(--accent-surface);
}

/* Smooth the tag hover colour shift. */
.tag {
    transition:
        color 0.14s ease,
        border-color 0.14s ease;
}

/* Label ↔ field vertical rhythm. */
.field-label {
    display: block;
    margin-bottom: 6px;
}

/* Active mobile-tab indicator pops in instead of snapping. */
.mobile-tab.active::before {
    animation: tab-pop 0.22s ease;
}
@keyframes tab-pop {
    from {
        opacity: 0;
        transform: translateX(-50%) scaleX(0.4);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) scaleX(1);
    }
}

/* Toast clears the mobile tab bar + home-indicator safe area. */
@media (max-width: 760px) {
    .toast {
        bottom: calc(24px + var(--mobile-tabbar-h) + var(--safe-bottom));
    }
}

/* ── aesthetic pass: form controls, depth, prose links, search rows ───────────
   CSS-only, token-based; new motion covered by the prefers-reduced-motion block. */

/* Custom checkboxes & radios (themed; replaces native, keeps :checked semantics). */
input[type="checkbox"],
input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    min-width: 18px;
    padding: 0;
    margin: 0;
    margin-top: 1px;
    border: 1px solid var(--line-2);
    background: var(--surface);
    display: inline-grid;
    place-content: center;
    cursor: pointer;
    transition:
        background 0.14s ease,
        border-color 0.14s ease;
}
input[type="checkbox"] {
    border-radius: 5px;
}
input[type="radio"] {
    border-radius: 50%;
}
input[type="checkbox"]::before {
    content: "";
    width: 10px;
    height: 10px;
    transform: scale(0);
    transition: transform 0.12s ease-in-out;
    background: var(--accent-on);
    clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
}
input[type="radio"]::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    transform: scale(0);
    transition: transform 0.12s ease;
    background: var(--accent-on);
}
input[type="checkbox"]:checked,
input[type="radio"]:checked {
    background: var(--accent);
    border-color: var(--accent);
}
input[type="checkbox"]:checked::before,
input[type="radio"]:checked::before {
    transform: scale(1);
}
input[type="checkbox"]:hover,
input[type="radio"]:hover {
    border-color: var(--accent);
}
input[type="checkbox"]:focus-visible,
input[type="radio"]:focus-visible {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-ring);
}

/* Custom select: themed chevron, no native arrow (inline SVG, no external asset). */
select {
    appearance: none;
    -webkit-appearance: none;
    padding-right: 36px;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'><path d='M6 9l6 6 6-6'/></svg>");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
}

/* Subtle resting depth (keeps the existing inset highlight). */
.panel,
.card,
.story-card,
.topic-card,
.source-card,
.job-card,
.package-card {
    box-shadow: 0 1px 0 var(--fill-subtle) inset, var(--card-shadow-rest);
}
.story-card:hover {
    box-shadow: 0 1px 0 var(--fill-subtle) inset, var(--card-shadow-hover);
}

/* (Prose-link affordance intentionally omitted: the product's content links use the
   already-styled .inline-link; remaining body anchors are unclassed and inconsistently
   nested, so a clean, non-over-broad selector isn't available. Skipped over dead CSS.) */

/* Richer search-result rows: interactive wash + left accent rule. */
.search-result {
    padding: 14px 12px;
    border-radius: 8px;
    transition: background 0.14s ease;
}
.search-result:hover {
    background: var(--fill-subtle);
    box-shadow: inset 2px 0 0 var(--accent);
}

/* ── slice 4: tables, prose blocks, rail affordance (CSS-only) ────────────────
   Reduced-motion N/A (no animation). Token-based, low-specificity additions. */

/* Policy/data tables: header emphasis, zebra striping, row hover. */
.admin-table th,
.table th {
    background: var(--fill-subtle);
    color: var(--muted);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.admin-table tbody tr:nth-child(even) td,
.table tbody tr:nth-child(even) td {
    background: var(--fill-subtle);
}
.admin-table tbody tr:hover td,
.table tbody tr:hover td {
    background: var(--fill-muted);
}

/* Prose blocks anywhere (story/policy/markdown), not just .comment-body. */
blockquote {
    margin: 0 0 12px;
    padding-left: 12px;
    border-left: 2px solid var(--accent);
    color: var(--muted);
}
pre {
    overflow-x: auto;
    margin: 0 0 12px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--pre-bg);
}
:not(pre) > code {
    background: var(--fill-muted);
    padding: 1px 5px;
    border-radius: 5px;
}
pre code {
    background: none;
    padding: 0;
}

/* Horizontal rails: subtle right-edge fade hints there's more to scroll. */
.hero-rail,
.trending-rail {
    -webkit-mask-image: linear-gradient(
        to right,
        #000 calc(100% - 40px),
        transparent
    );
    mask-image: linear-gradient(to right, #000 calc(100% - 40px), transparent);
}

/* ── slice 5: editorial pass (CSS-only, conservative, system fonts) ───────────
   Semantic colour discipline, spacing scale, topic-spine, long-read measure,
   active-nav, section ornament, masthead. Drop cap intentionally omitted: the
   content is sectioned panels/bullets with no flowing lead paragraph. */

/* Semantic alias tokens — one job each (additive; lime stays the identity). */
:root {
    --brand: var(--accent); /* identity: masthead, CTA, focus */
    --positive: var(--good); /* approved / positive state */
    --temporal: var(--warn); /* freshness / "new" */
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 24px;
    --space-6: 32px;
    --space-7: 48px;
    --space-8: 64px;
}

/* De-overload: a "positive/approved" badge reads green, not brand-lime. */
.badge.green {
    color: var(--positive);
    border-color: var(--good-line);
}

/* Spacing: section rhythm onto the scale (light normalize). */
.section {
    padding: var(--space-6) 0;
}

/* (Topic-spine card wash omitted: the hydrated feed renders plain .story-card
   with no --topic-accent, so the colored left-rule isn't actually in use here.) */

/* Nav active state unified in feed visual system block below. */

/* Long-read: comfortable measure + rhythm for body prose on long-form pages,
   scoped to their roots so feed/card surfaces elsewhere are unaffected. */
#story-root p,
#story-root li,
#privacy-main p,
#privacy-main li,
#terms-main p,
#terms-main li {
    max-width: 72ch;
}
#story-root li,
#privacy-main li,
#terms-main li {
    line-height: 1.72;
}

/* Character: section ornament — a faded rule with a centered diamond. */
hr {
    border: 0;
    height: 1px;
    margin: var(--space-6) 0;
    overflow: visible;
    position: relative;
    background: linear-gradient(
        to right,
        transparent,
        var(--line) 18%,
        var(--line) 82%,
        transparent
    );
}
hr::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 5px;
    height: 5px;
    transform: translate(-50%, -50%) rotate(45deg);
    background: var(--faint);
    border: 1px solid var(--bg);
}

/* Masthead/wordmark strengthening within the system serif (no webfonts). */
.brand-title {
    font-size: 26px;
    letter-spacing: -0.05em;
}
.logo-mark {
    border-color: var(--border-strong);
    background: linear-gradient(145deg, var(--logo-grad-a), var(--logo-grad-b));
    color: var(--accent);
}

/* module: 08-feed-system.css */
/* Community front page (HN/Lxer-style) */
#dotgrid {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: var(--dotgrid-opacity);
}
.community-home {
    position: relative;
    z-index: 1;
}
.live-strip {
    border-bottom: 1px solid var(--line);
    background: var(--surface-glass-panel);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.06em;
    color: var(--muted);
}
.live-strip-inner {
    min-height: 36px;
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
    padding: 8px 0;
}
.live-strip .ls-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--good);
    display: inline-block;
    margin-right: 6px;
}
.community-hero {
    padding: 28px 0 8px;
}
.community-hero .eyebrow {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--muted);
    margin-bottom: 10px;
}
.community-hero h1 {
    font-family: var(--serif);
    font-size: clamp(2rem, 5vw, 3rem);
    line-height: 1.05;
    margin: 0 0 12px;
}
.community-hero .accent {
    color: var(--accent);
    font-style: italic;
}
.control-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin: 18px 0 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
}
.control-bar .tabs {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
.control-bar .tab {
    font-family: var(--mono);
    font-size: 11px;
    padding: 8px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--muted);
}
/* Sort tab active: see .feed-chip.active */
.control-bar .timefilter {
    display: flex;
    align-items: center;
    gap: 6px;
}
.control-bar .pill {
    font-family: var(--mono);
    font-size: 11px;
    padding: 6px 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--muted);
}
.control-bar .pill.active {
    border-color: var(--accent);
    color: var(--accent);
}
.grep-line {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    margin-bottom: 16px;
    background: var(--surface-glass-soft);
}
.grep-line .prompt {
    color: var(--accent);
    font-family: var(--font-mono);
    font-weight: 700;
}
.grep-line input {
    flex: 1;
    min-width: 0;
    font-family: var(--font-mono);
    font-size: 13px;
    background: transparent;
    border: 0;
    color: var(--text);
}
.grep-line input::placeholder {
    color: var(--faint);
}
.grep-line .hint {
    color: var(--faint);
    font-family: var(--font-mono);
    font-size: 11px;
}
.grep-line .kbd {
    display: inline-block;
    padding: 2px 5px;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--chip-bg);
    font-size: 10px;
}
.home-container {
    max-width: 1120px;
}
.feed-main {
    max-width: 720px;
}
.feed-layout {
    display: grid;
    grid-template-columns: minmax(0, 720px) minmax(0, 1fr);
    gap: 28px;
    align-items: start;
}
@media (max-width: 960px) {
    .feed-layout {
        grid-template-columns: 1fr;
    }
    .feed-main {
        max-width: none;
    }
}
@media (min-width: 961px) {
    .feed-layout {
        grid-template-columns: 1fr;
    }
    .feed-rail {
        max-width: 720px;
    }
}
.thread-list {
    list-style: none;
    margin: 0;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--surface);
}
.thread {
    display: grid;
    grid-template-columns: 32px 52px minmax(0, 1fr);
    gap: 10px;
    padding: 12px 14px;
    border-bottom: 1px solid var(--line);
    position: relative;
}
.thread:last-child {
    border-bottom: 0;
}
.thread:hover {
    background: var(--fill-hover);
}
.thread-stripe {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--c-topic, var(--accent));
}
.thread.cat-kernel {
    --c-topic: var(--c-kernel);
}
.thread.cat-security {
    --c-topic: var(--c-security);
}
.thread.cat-distros {
    --c-topic: var(--c-distros);
}
.thread.cat-desktop {
    --c-topic: var(--c-desktop);
}
.thread.cat-homelab {
    --c-topic: var(--c-homelab);
}
.thread.cat-linux-hardware,
.thread.cat-hardware {
    --c-topic: var(--c-linux-hardware);
}
.thread.cat-jobs {
    --c-topic: var(--c-jobs);
}
.thread.cat-gaming {
    --c-topic: var(--c-gaming);
}
.thread.cat-self-hosting {
    --c-topic: var(--c-self-hosting);
}
.thread.cat-open-source-ai {
    --c-topic: var(--c-open-source-ai);
}
.thread.cat-local-llm {
    --c-topic: var(--c-local-llm);
}
.thread.cat-ai-hardware {
    --c-topic: var(--c-ai-hardware);
}
.thread.cat-robotics {
    --c-topic: var(--c-robotics);
}
.thread.cat-storage {
    --c-topic: var(--c-storage);
}
.thread.cat-server {
    --c-topic: var(--c-server);
}
.thread.cat-networking {
    --c-topic: var(--c-networking);
}
.thread.cat-privacy {
    --c-topic: var(--c-privacy);
}
.thread.cat-developer-tools {
    --c-topic: var(--c-developer-tools);
}
.thread.cat-submission {
    --c-topic: var(--cyan);
}
.thread.cat-submission.pending {
    background: var(--surface-glass-muted);
}
.thread.cat-submission.pending .thread-stripe {
    background: var(--muted);
}
.feed-sort-legend {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
    margin: 0 0 12px;
}
.feed-offline-banner {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--warn);
    border: 1px solid var(--warn-line);
    border-radius: var(--radius);
    padding: 10px 14px;
    margin-bottom: 12px;
    background: var(--warn-surface);
}
.feed-rail-more {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 10px 12px;
    background: var(--surface-glass-soft);
}
.feed-rail-more summary {
    cursor: pointer;
    font-family: var(--mono);
    font-size: 12px;
    color: var(--muted);
}
.feed-rail-more-body {
    margin-top: 12px;
    display: grid;
    gap: 12px;
}
.status-snapshot-note {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
    margin: 8px 0 0;
}
.thread-rank {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--faint);
    line-height: 1;
    padding-top: 6px;
    opacity: 0.35;
}
.thread-rank--lead {
    opacity: 1;
    color: var(--accent);
    font-size: 13px;
    font-weight: 700;
}
.thread-vote {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
}
.thread-vote .up {
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 4px 8px;
    background: transparent;
}
.thread-vote .up.voted {
    background: var(--accent);
    color: var(--accent-on);
    border-color: var(--accent);
}
.thread-domain {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
    margin: 0 0 4px;
}
.thread-domain a {
    color: var(--muted);
}
.thread-domain a:hover {
    color: var(--accent);
}
.thread-title {
    font-family: var(--font-ui);
    font-size: 17px;
    font-weight: 600;
    line-height: 1.25;
    margin: 0 0 6px;
}
.thread-meta--compact {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
}
.thread-meta--compact .meta-sep {
    color: var(--faint);
}
.thread-meta-comments {
    color: var(--muted);
}
.thread-meta-comments--active {
    color: var(--accent);
    font-weight: 700;
}
.thread-meta-score {
    color: var(--text-2);
}
.feed-intro-link,
.feed-context-toggle {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
    background: none;
    border: 0;
    padding: 0;
    cursor: pointer;
    text-decoration: underline;
}
.feed-context-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    text-decoration: none;
}
.footer-filter-hint {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
    margin: 10px 0 0;
}
.topic-page-head {
    margin-bottom: 16px;
}
.topic-page-title {
    font-family: var(--font-ui);
    font-size: clamp(1.35rem, 3vw, 1.75rem);
    margin: 0 0 6px;
}
.topic-page-dek {
    margin: 0;
    max-width: 60ch;
}
.topic-page-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.topic-page-more {
    margin-top: 20px;
    font-size: 13px;
    color: var(--muted);
}
.thread-title a {
    color: var(--text);
}
.thread-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
}
.chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
}
.chip.reader {
    border-color: var(--cyan);
    color: var(--cyan);
}
.chip.pending {
    border-color: var(--warn);
    color: var(--warn);
}

/* Topic filter chips (community feed) */
.topic-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 14px;
}
.topic-chip {
    font-family: var(--font-mono);
    font-size: 11px;
    padding: 6px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--muted);
    background: transparent;
}
/* Topic chip active: see .feed-chip.active */
a.thread-topic {
    color: var(--muted);
    text-decoration: none;
}
a.thread-topic:hover {
    color: var(--accent);
    text-decoration: underline;
}

/* Story compact / full dispatch surfaces */
.story-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--muted);
    margin: 0 0 14px;
}
.story-breadcrumb a {
    color: var(--muted);
}
.story-breadcrumb-title {
    color: var(--text-2);
    max-width: 42ch;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.story-compact {
    position: relative;
    padding-left: 12px;
}
.story-compact .thread-stripe {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    border-radius: 3px;
    background: var(--topic-accent, var(--accent));
}
.story-compact-title {
    font-family: var(--serif);
    font-style: italic;
    font-size: clamp(1.6rem, 4vw, 2.35rem);
    line-height: 1.08;
    margin: 8px 0 12px;
}
.story-compact-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin: 16px 0;
}
.story-compact-actions .up {
    font-family: var(--font-mono);
    font-size: 13px;
    padding: 6px 10px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: transparent;
    cursor: pointer;
}
.story-compact-actions .up.voted {
    background: var(--accent);
    color: var(--accent-on);
    border-color: var(--accent);
}
.story-compact-sidebar .card h2,
.story-compact-sidebar .card h3 {
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.story-full-dispatch {
    margin: 20px 0;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    background: var(--surface-glass-dispatch);
}
.story-full-dispatch summary {
    font-family: var(--font-mono);
    font-size: 12px;
    cursor: pointer;
    color: var(--muted);
}
.story-page--full .panel.pad h2 {
    font-family: var(--font-mono);
    font-size: 13px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
body.page-story-compact .subscribe-pill {
    display: none;
}
body.page-feed {
    background: var(--bg);
}
body.page-feed #dotgrid {
    opacity: 0.22;
}
body.page-feed .community-hero {
    margin-bottom: 8px;
}
body.page-feed .feed-layout {
    margin-top: 4px;
}
.live-strip-inner {
    font-family: var(--mono);
    font-size: 11px;
    gap: 14px;
    flex-wrap: wrap;
}
.live-strip-inner b {
    color: var(--text);
    font-weight: 600;
}
body.page-story-full .story-page--full .article {
    max-width: 72ch;
}
body.page-story-full .story-page--full .article-section h2 {
    margin-top: 1.5rem;
}
.field-label {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.04em;
    color: var(--muted);
    text-transform: none;
}
.feed-rail .card {
    margin-bottom: 14px;
}

/* Admin / metrics layout utilities (token-based; replaces inline spacing/color) */
.notice--spaced {
    margin-bottom: 1.5rem;
}
.badge--compact {
    font-size: 11px;
}
.admin-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}
.admin-stack {
    margin-bottom: 16px;
}
.admin-stack-sm {
    margin-bottom: 8px;
}
.admin-stack-xs {
    margin-top: 8px;
}
.admin-stack-result {
    margin-top: 12px;
}
.admin-h4 {
    margin: 0 0 4px;
}
.admin-h4-lg {
    margin: 0 0 8px;
}
.admin-row-strong {
    font-weight: 700;
    border-top: 1px solid var(--line);
}
.admin-muted {
    color: var(--muted);
}
.admin-required {
    color: var(--danger);
}
.admin-flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}
.admin-flex-between h2 {
    margin: 0;
}
.admin-flex-actions {
    margin-top: 12px;
    display: flex;
    gap: 8px;
}
.metrics-dashboard .card + .card,
.metrics-dashboard .admin-stack + .card {
    margin-top: 16px;
}
.metrics-dashboard .admin-grid-2 {
    margin-top: 16px;
}
.section-head--spaced {
    margin-top: 24px;
}
.status-big small {
    font-family: var(--mono);
    font-size: 13px;
    color: var(--muted);
    font-style: normal;
    margin-left: 6px;
}
.admin-list {
    padding-left: 20px;
    margin: 0;
}
.admin-list li {
    margin-bottom: 4px;
}
.story-summary.is-error {
    color: var(--danger);
}
.notice--compact {
    margin-bottom: 12px;
}
.admin-section-head {
    margin-top: 24px;
}
.admin-brief-list li {
    margin-bottom: 12px;
}
.text-sm {
    font-size: 0.85em;
    color: var(--muted);
}
.admin-card-tight {
    margin-top: 8px;
}
.admin-card-spaced {
    margin-top: 16px;
}
.kpi-grid--spaced {
    margin-top: 8px;
}
.story-summary--spaced {
    margin-top: 12px;
}
.topic-art-cover {
    --topic-cover-accent: var(--topic-accent, var(--accent));
}

/* Light theme — polish for blend modes and legibility */
:root[data-theme="light"] select {
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%237a8774' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'><path d='M6 9l6 6 6-6'/></svg>");
}
:root[data-theme="light"] .topic-art-frame::after {
    mix-blend-mode: normal;
    opacity: 0.42;
}
:root[data-theme="light"] .story-card:hover,
:root[data-theme="light"] .topic-card:hover {
    background: var(--surface);
    box-shadow: var(--shadow);
}
:root[data-theme="light"] .admin-table,
:root[data-theme="light"] .table {
    background: var(--surface);
}
:root[data-theme="light"] .discuss-list,
:root[data-theme="light"] .thread-list {
    background: var(--surface);
}
:root[data-theme="light"] .discuss-row:hover,
:root[data-theme="light"] .thread:hover {
    background: var(--accent-surface);
}
:root[data-theme="light"] pre {
    background: color-mix(in srgb, var(--surface-2) 88%, var(--bg));
}
:root[data-theme="light"] :not(pre) > code {
    background: var(--code-inline-bg);
    color: var(--accent);
}
:root[data-theme="light"] .status-card,
:root[data-theme="light"] .news-card {
    box-shadow: 0 1px 0 var(--panel-inset) inset;
}
:root[data-theme="light"] .sponsor-shot {
    border-bottom-color: var(--line);
}
:root[data-theme="light"] .sponsor-slot--compact .sponsor-shot {
    border-color: var(--line);
}
:root[data-theme="light"] .chip.active {
    background: var(--accent);
    color: var(--accent-on);
    border-color: var(--accent);
}
:root[data-theme="light"] .search-overlay {
    background: var(--overlay-bg);
}

.feed-load-more-wrap {
    margin: 1.25rem 0 0;
    text-align: center;
}
.feed-load-more {
    min-width: 12rem;
}
.search-page-input {
    margin: 1rem 0 1.5rem;
}
.admin-bulk-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 0.75rem;
    align-items: center;
    margin: 0.75rem 0;
}
.admin-bulk-bar .admin-muted {
    font-size: 0.85rem;
    color: var(--muted);
}
.admin-queue-table tr:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: -2px;
}

/* ── UX plan: feed mobile, touch targets, reader polish ───────────────────── */
.control-bar-primary {
    flex: 1 1 auto;
    min-width: 0;
}
.feed-filters-more {
    font-family: var(--mono);
    font-size: 11px;
}
.feed-filters-more summary {
    list-style: none;
    cursor: pointer;
    padding: 10px 14px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--muted);
}
.feed-filters-more[open] summary {
    border-color: var(--accent);
    color: var(--accent);
}
.feed-filters-more-body {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    padding: 10px 0 4px;
}
.feed-ranking-help {
    margin: 0 0 12px;
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
}
.feed-ranking-help summary {
    cursor: pointer;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}
.feed-type-chips {
    display: flex;
    gap: 8px;
    margin: 0 0 8px;
}
.topic-chips-scroll {
    position: relative;
    margin: 0 0 10px;
    overflow: hidden;
}
.topic-chips-scroll::before,
.topic-chips-scroll::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    width: 28px;
    pointer-events: none;
    z-index: 1;
}
.topic-chips-scroll::before {
    left: 0;
    background: linear-gradient(90deg, var(--bg), transparent);
}
.topic-chips-scroll::after {
    right: 0;
    background: linear-gradient(270deg, var(--bg), transparent);
}
.topic-chips-scroll .topic-chips {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    margin: 0;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    padding: 4px 28px 8px;
    scrollbar-width: thin;
}
.topic-chips-scroll .topic-chip {
    flex: none;
    scroll-snap-align: start;
    min-height: 44px;
    min-width: 44px;
    justify-content: center;
}
.topic-active-chip {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
    margin: 0 0 12px;
}
.topic-active-chip .topic-chip {
    margin-left: 6px;
}
.thread-feed-summary {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.thread-vote .up,
.story-compact-actions .up,
.control-bar .tab,
.control-bar .pill,
.topic-chip,
.feed-type-chip,
.mobile-tab,
.story-compact-actions .button,
.story-sticky-actions .button {
    min-height: 44px;
    min-width: 44px;
}
.thread-vote .up {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 12px;
}
.thread-vote .up.vote-throttled {
    border-color: var(--warn);
    color: var(--warn);
}
.control-bar .tab,
.control-bar .pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.community-home .control-bar {
    position: sticky;
    top: calc(var(--header-h, 56px) + 4px);
    z-index: 40;
    background: color-mix(in srgb, var(--bg) 92%, transparent);
    backdrop-filter: blur(8px);
}
.nav-toggle {
    display: none;
}
@media (max-width: 960px) {
    .nav-toggle {
        display: inline-flex;
    }
    .site-header .nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 12px 16px;
        background: var(--surface);
        border-bottom: 1px solid var(--line);
        box-shadow: var(--modal-shadow);
    }
    .site-header .nav.nav--open {
        display: flex;
    }
    .site-header .nav a {
        padding: 12px 8px;
        min-height: 44px;
    }
    .site-header .header-inner {
        position: relative;
        flex-wrap: wrap;
    }
    .feed-filters-more {
        width: 100%;
    }
}
.archive-link {
    font-family: var(--mono);
    font-size: 11px;
}
.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0;
    z-index: 120;
    background: var(--accent);
    pointer-events: none;
}
.story-sticky-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 90;
    background: color-mix(in srgb, var(--surface) 94%, transparent);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(10px);
    padding: 8px 0;
    box-shadow: var(--shadow-sm);
}
.story-sticky-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.story-sticky-title {
    font-family: var(--serif);
    font-size: 14px;
    font-style: italic;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
}
.story-sticky-actions {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    flex-shrink: 0;
}
.story-toc {
    margin: 0 0 20px;
}
.story-toc-title {
    font-size: 1rem;
    margin: 0 0 8px;
}
.story-toc ul {
    margin: 0;
    padding-left: 1.2rem;
    font-family: var(--mono);
    font-size: 12px;
}
.comment-load-more {
    margin-top: 12px;
}
@media (prefers-reduced-motion: reduce) {
    .api-status--live .api-status-dot,
    .ls-dot {
        animation: none !important;
    }
    .card:hover,
    .topic-card:hover,
    .thread:hover {
        transform: none !important;
    }
    .mobile-tab.active::before {
        transition: none !important;
    }
}
@media (prefers-contrast: more) {
    :root {
        --muted: color-mix(in srgb, var(--text) 72%, var(--bg));
        --faint: color-mix(in srgb, var(--text) 58%, var(--bg));
        --line: color-mix(in srgb, var(--text) 35%, var(--bg));
    }
    .live-strip,
    #api-trust-banner {
        border-width: 2px;
    }
}
/* ── Feed visual system (consistent chips, calmer chrome) ───────────────── */
.feed-chip,
.control-bar .tab,
.control-bar .pill,
.topic-chip,
.feed-type-chip,
.feed-filters-more-summary,
.discuss-sort .sort-tab,
.discussion .sort-tab,
body.page-app .filter-bar .chip,
body.page-app .job-filter-bar .chip,
body.page-app .tag-chip-row .tag.feed-chip {
    font-family: var(--mono);
    font-size: 11px;
    line-height: 1.2;
    padding: 6px 11px;
    min-height: 32px;
    border: 1px solid var(--line);
    border-radius: 6px;
    color: var(--muted);
    background: var(--chip-bg);
    cursor: pointer;
    transition:
        background 0.12s ease,
        border-color 0.12s ease,
        color 0.12s ease;
}
body.page-app .tag-chip-row .tag.feed-chip {
    cursor: default;
}
.feed-chip:hover,
.control-bar .tab:hover,
.topic-chip:hover {
    color: var(--text);
    border-color: var(--line-2);
    background: var(--fill-hover);
}
.feed-chip.active,
.control-bar .tab.active,
.control-bar .pill.active,
.topic-chip.active,
.feed-type-chip.active {
    background: var(--accent-surface);
    color: var(--text);
    border-color: var(--accent-line);
    font-weight: 600;
    box-shadow: none;
}
.control-bar .tab.active,
.topic-chip.active {
    /* No solid phosphor fill — outline active only */
    background: var(--accent-surface);
    color: var(--text);
}
.nav a.active {
    color: var(--text);
    font-weight: 600;
    background: transparent;
    border-color: transparent;
    box-shadow: inset 0 -2px 0 var(--accent);
}
.feed-toolbar {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--surface);
    padding: 12px 14px 10px;
    margin-bottom: 14px;
}
.feed-toolbar .control-bar {
    margin: 0 0 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--line);
}
.feed-toolbar .grep-line {
    margin-bottom: 0;
    background: var(--bg-elev);
}
.feed-filter-chips {
    margin-bottom: 10px;
}
.feed-submit-link {
    font-family: var(--mono);
}
.live-strip {
    background: var(--surface);
    border-bottom: 1px solid var(--line);
}
.live-strip-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0;
}
.live-strip-metrics {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
    padding: 8px 0;
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
}
.feed-trust-slot {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid var(--line);
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
}
.feed-trust-slot:empty {
    display: none;
    border: 0;
    padding: 0;
}
.feed-trust-slot--sample,
.feed-trust-slot--demo {
    background: var(--warn-surface);
    color: var(--text-2);
    border-bottom-color: var(--warn-line);
}
.feed-trust-slot--offline {
    background: var(--danger-surface);
    border-bottom-color: var(--danger-line);
}
.feed-trust-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
    flex: none;
}
.feed-trust-slot--sample .feed-trust-dot,
.feed-trust-slot--demo .feed-trust-dot {
    color: var(--warn);
}
.feed-trust-text {
    flex: 1;
    margin: 0;
}
.feed-trust-dismiss {
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    padding: 4px 8px;
}
.thread-rank {
    display: none;
}
.thread {
    grid-template-columns: 52px minmax(0, 1fr);
}
.thread-meta-tag {
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--faint);
}
body.page-feed #dotgrid {
    opacity: 0.15;
}
body.page-feed {
    background: var(--bg);
}
.community-hero .accent {
    color: var(--accent);
    font-style: normal;
    font-weight: 600;
}
.feed-filters-more summary.feed-filters-more-summary {
    list-style: none;
}
.feed-filters-more[open] .feed-filters-more-summary {
    border-color: var(--accent-line);
    color: var(--text);
}

/* ── Collapsible feed rows (expand-in-place) ───────────────────────────── */
.thread--collapsible .thread-body {
    min-width: 0;
}
.thread-toggle {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: start;
    gap: 10px;
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
    text-align: left;
    color: inherit;
    font: inherit;
    cursor: pointer;
}
.thread-cat-chip {
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.06em;
    line-height: 1;
    padding: 4px 6px;
    border: 1px solid
        color-mix(in srgb, var(--c-topic, var(--accent)) 40%, transparent);
    border-radius: 4px;
    color: var(--c-topic, var(--accent));
    white-space: nowrap;
    margin-top: 2px;
}
.thread-toggle-main {
    min-width: 0;
}
.thread-toggle .thread-title {
    display: block;
    font-family: var(--font-ui);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.3;
    color: var(--text);
    margin: 0 0 3px;
}
.thread-impact {
    display: block;
    font-family: var(--mono);
    font-size: 11px;
    line-height: 1.4;
    color: var(--muted);
}
.thread-line-domain {
    color: var(--faint);
}
.thread-line-sep {
    color: var(--faint);
    margin: 0 4px;
}
.thread-chevron {
    width: 8px;
    height: 8px;
    margin-top: 6px;
    border-right: 1.5px solid var(--faint);
    border-bottom: 1.5px solid var(--faint);
    transform: rotate(45deg);
    transition: transform 0.18s ease;
}
.thread.is-open .thread-chevron {
    transform: rotate(-135deg);
}
.thread-toggle:hover .thread-chevron {
    border-color: var(--accent);
}
.thread.is-open {
    background: var(--fill-hover);
}
.thread-panel {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--line);
    display: grid;
    gap: 10px;
}
.thread-panel[hidden] {
    display: none;
}
.thread-panel-summary {
    margin: 0;
    font-size: 14px;
    line-height: 1.55;
    color: var(--text-2);
}
.thread-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.thread-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.thread-action {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.thread-panel-foot {
    margin: 0;
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
}
.thread-panel-foot a {
    color: var(--muted);
}
.thread-panel-foot a:hover {
    color: var(--accent);
}
/* Toolbar: inline expand hint + Filters disclosure */
.feed-expand-hint {
    margin: 0 0 0 auto;
    font-family: var(--mono);
    font-size: 11px;
    color: var(--faint);
    white-space: nowrap;
}
.feed-filters-disclosure {
    margin-top: 10px;
}
.feed-filters-disclosure .feed-filters-more-summary {
    gap: 6px;
}
.feed-filters-disclosure .feed-filters-more-summary::after {
    content: "";
    width: 6px;
    height: 6px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg);
    transition: transform 0.18s ease;
}
.feed-filters-disclosure[open] .feed-filters-more-summary::after {
    transform: rotate(-135deg);
}
.feed-filters-disclosure .feed-filters-more-body {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
}
/* Let the horizontally-scrolling topic rail shrink to the panel width instead
   of forcing the page wide (flex children default to min-width: auto). */
.feed-filters-disclosure .feed-filters-more-body > * {
    min-width: 0;
    max-width: 100%;
}
.feed-filters-group {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

@media print {
    .site-header,
    .mobile-tabbar,
    .story-sticky-bar,
    .reading-progress,
    #subscribe-pill,
    .dotgrid,
    .api-status,
    #api-trust-banner,
    .sidebar,
    .story-compact-actions,
    .comment-form,
    .feed-rail {
        display: none !important;
    }
    body {
        background: #fff;
        color: #111;
    }
    .article,
    .story-page {
        max-width: 100%;
    }
    a[href]::after {
        content: " (" attr(href) ")";
        font-size: 9pt;
        color: #444;
    }
    a[href^="#"]::after,
    a.button::after {
        content: "";
    }
}
/* ── Sitewide app pages (consistent with home feed chrome) ─────────────── */
.site-trust-slot {
    max-width: var(--max);
    margin: 0 auto;
    padding: 0 20px;
}
.site-trust-slot.feed-trust-slot {
    border-bottom: 1px solid var(--line);
}
body.page-app .page-intro {
    margin-bottom: 18px;
}
.page-eyebrow,
body.page-app .page-eyebrow,
body.page-app .section .page-eyebrow {
    color: var(--accent);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}
.page-title,
body.page-app .page-title,
body.page-app .section-head h1,
body.page-app main > h1:not(.story-compact-title):not(.topic-page-title),
body.page-app .page-hero h1 {
    font-family: var(--sans);
    font-style: normal;
    font-weight: 700;
    font-size: clamp(1.65rem, 4vw, 2.35rem);
    line-height: 1.15;
    letter-spacing: -0.02em;
}
body.page-app .card h2,
body.page-app .card h3,
body.page-app .surface-panel h2,
body.page-app .surface-panel h3,
body.page-app .panel h2,
body.page-app .panel h3 {
    font-family: var(--sans);
    font-style: normal;
    font-weight: 600;
    font-size: 1.125rem;
    line-height: 1.25;
}
body.page-app .button.primary {
    background: var(--accent-surface);
    color: var(--text);
    border-color: var(--accent-line);
}
body.page-app .button.primary:hover {
    background: var(--fill-hover);
    border-color: var(--accent);
    color: var(--text);
}
body.page-app .surface-card,
body.page-app .surface-panel {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--surface);
}
body.page-app .surface-panel.pad {
    padding: 16px 18px;
    margin-top: 16px;
}
body.page-app .tag-chip-row .tag.feed-chip,
body.page-app .filter-bar .chip,
body.page-app .job-filter-bar .chip {
    border-radius: 6px;
    cursor: default;
}
body.page-app .filter-bar .chip,
body.page-app .job-filter-bar .chip {
    cursor: pointer;
}
body.page-app .filter-bar .chip.active,
body.page-app .job-filter-bar .chip.active {
    background: var(--accent-surface);
    color: var(--text);
    border-color: var(--accent-line);
    font-weight: 600;
}
body.page-app .page-hero--jobs .layout {
    align-items: start;
}
body.page-app .topic-page-hero h1 {
    font-family: var(--sans);
    font-style: normal;
    font-weight: 700;
    font-size: clamp(1.65rem, 4vw, 2.35rem);
    line-height: 1.15;
}
body.page-app .job-card h3 {
    font-family: var(--sans);
    font-style: normal;
    font-size: 1.05rem;
}
body.page-app .tag-chip-row .tag.feed-chip {
    display: inline-flex;
    align-items: center;
}
body.page-app .eyebrow:not(.community-hero .eyebrow) {
    color: var(--accent);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}
body.page-app .panel.pad,
body.page-app .surface-panel.pad {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--surface);
    padding: 16px 18px;
}
body.page-app main .card:not(.story-card):not(.topic-card),
body.page-app .sidebar .card {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--surface);
}
body.page-app .package-card h2,
body.page-app .package-card h3 {
    font-family: var(--sans);
    font-style: normal;
    font-weight: 600;
    font-size: 1.05rem;
}
#api-trust-banner.api-banner {
    border-bottom: 1px solid var(--line);
    background: var(--warn-surface);
    font-family: var(--mono);
    font-size: 11px;
}
#api-trust-banner .api-banner-inner {
    max-width: var(--max);
    padding: 8px 20px;
}
.page-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-top: 12px;
}
.page-actions p {
    margin: 0;
    width: 100%;
}

/* module: 09-trust-card.css */
/* ── per-story trust card (Slice A) ──────────────────────────────────────────
   Consolidates editorial trust signals (primary source verified, reviewed-by,
   source type, published/updated, AI assistance) under the story lead. Uses
   existing tokens; honours light/dark theme via --line/--text/--muted/--brand. */
.trust-card {
    margin: 0 0 var(--space-4, 16px);
    padding: var(--space-4, 16px);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.025);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.02) inset;
}
:root[data-theme="light"] .trust-card {
    background: rgba(0, 0, 0, 0.02);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.02) inset;
}
.trust-card-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-3, 12px) var(--space-5, 24px);
}
@media (min-width: 640px) {
    .trust-card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
.trust-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-family: var(--mono);
    font-size: 12.5px;
    line-height: 1.5;
    color: var(--text);
    min-width: 0;
}
.trust-item--source,
.trust-item--ai {
    grid-column: 1 / -1;
}
.trust-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
}
.trust-value {
    color: var(--text);
    word-break: break-word;
}
.trust-value[href],
a.trust-value {
    color: var(--brand, var(--accent));
    text-decoration: underline;
    text-underline-offset: 2px;
}
.trust-value[href]:hover,
a.trust-value:hover {
    text-decoration-thickness: 2px;
}
.trust-value svg {
    width: 12px;
    height: 12px;
    vertical-align: -1px;
    margin-left: 2px;
}
.trust-item--ai .trust-value {
    color: var(--muted);
    font-size: 12px;
}
.trust-card-foot {
    margin: var(--space-3, 12px) 0 0;
    padding-top: var(--space-3, 12px);
    border-top: 1px solid var(--line);
    font-family: var(--mono);
    font-size: 11.5px;
}
.trust-correction-link {
    color: var(--muted);
    text-decoration: none;
}
.trust-correction-link:hover {
    color: var(--brand, var(--accent));
    text-decoration: underline;
    text-underline-offset: 3px;
}
/* module: 10-premium.css */
/* =====================================================================
   10-premium.css — Premium refinement layer (additive overrides only)

   Goal: a calmer, more premium feel with clearer hierarchy, WITHOUT a
   redesign. Identity is preserved: phosphor accent, dark-by-default,
   Georgia serif headlines, JetBrains Mono for labels/metadata.

   All values reference theme tokens (var(--accent), var(--line), ...),
   so the light theme adapts automatically. This file is intentionally
   the LAST entry in assets/styles/_order.json so it composes as a thin
   override layer. Removing this file + its _order.json line fully
   reverts the visual changes.

   Added 2026-05-29 (feature/ai-ui-premium).
   ===================================================================== */

:root {
    --radius-xs: 6px;
    --radius-chip: 10px;
    --radius-pill: 999px;
    --radius-lg: 18px;
    /* Hairline border: softer than --line, reads as premium on dark. */
    --hairline: color-mix(in srgb, var(--text) 9%, transparent);
    --elev-1: 0 1px 2px color-mix(in srgb, #000 22%, transparent);
    --elev-2: 0 8px 24px color-mix(in srgb, #000 26%, transparent);
}

/* --------------------------------------------------------------------
   Live status strip — quieter, calmer
   ------------------------------------------------------------------ */
.live-strip {
    background: color-mix(in srgb, var(--surface) 68%, var(--bg));
}
.live-strip b,
.live-strip strong {
    color: var(--text);
    font-weight: 600;
}

/* --------------------------------------------------------------------
   Hero — tighten vertical rhythm, refine type scale
   ------------------------------------------------------------------ */
.community-hero {
    padding: 26px 0 6px;
}
.community-hero .eyebrow {
    letter-spacing: 0.08em;
    opacity: 0.85;
}
.community-hero h1 {
    font-size: clamp(1.9rem, 4.4vw, 2.7rem);
    letter-spacing: -0.02em;
}
.community-hero .story-summary {
    max-width: 60ch;
    font-size: 15px;
}

/* --------------------------------------------------------------------
   Notices — slim and low-profile, never louder than the content
   ------------------------------------------------------------------ */
.notice {
    font-size: 12.5px;
    padding: 9px 13px;
    border-radius: var(--radius-sm);
    line-height: 1.5;
}
.notice--compact,
.community-beta-notice {
    background: color-mix(in srgb, var(--warn) 6%, var(--surface));
    border-color: color-mix(in srgb, var(--warn) 24%, transparent);
    margin-bottom: 12px;
}

/* --------------------------------------------------------------------
   Feed toolbar — one cohesive, light bar (remove double-border noise)
   ------------------------------------------------------------------ */
.feed-toolbar {
    border-color: var(--hairline);
    border-radius: var(--radius);
    background: color-mix(in srgb, var(--surface) 78%, var(--bg));
    box-shadow: var(--elev-1);
    padding: 12px 14px;
}
.feed-toolbar .control-bar {
    margin: 0 0 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--hairline);
}
.feed-toolbar .grep-line {
    background: color-mix(in srgb, var(--bg) 50%, var(--surface));
    border-color: var(--hairline);
}

/* --------------------------------------------------------------------
   Chips & tabs — one unified look, premium active state
   ------------------------------------------------------------------ */
.feed-chip,
.control-bar .tab,
.control-bar .pill,
.topic-chip,
.feed-filters-more-summary {
    font-family: var(--mono);
    border-radius: var(--radius-chip);
    border: 1px solid var(--hairline);
    color: var(--muted);
    transition:
        color 0.14s ease,
        background 0.14s ease,
        border-color 0.14s ease;
}
.feed-chip:hover,
.control-bar .tab:hover,
.control-bar .pill:hover,
.topic-chip:hover,
.feed-filters-more-summary:hover {
    color: var(--text);
    border-color: var(--line-2);
}
.feed-chip.active,
.control-bar .tab.active,
.control-bar .pill.active,
.topic-chip.active {
    color: var(--accent);
    border-color: var(--accent-line);
    background: var(--accent-surface);
    font-weight: 600;
}

/* --------------------------------------------------------------------
   Topic chip strip — single-row scroll with a fade affordance so
   clipped chips read as "more to the right"
   ------------------------------------------------------------------ */
.feed-filter-chips {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 2px;
    -webkit-mask-image: linear-gradient(
        to right,
        #000 calc(100% - 26px),
        transparent
    );
    mask-image: linear-gradient(to right, #000 calc(100% - 26px), transparent);
}
.feed-filter-chips::-webkit-scrollbar {
    display: none;
}
.feed-filter-chips .topic-chip {
    white-space: nowrap;
    flex: 0 0 auto;
}

/* --------------------------------------------------------------------
   Ranking-help sentence in sans (label/summary stays mono); keep code
   spans mono. Fixes long mono paragraphs being hard to read.
   ------------------------------------------------------------------ */
.feed-ranking-help p,
.feed-sort-legend {
    font-family: var(--font-ui);
    font-size: 12px;
    line-height: 1.5;
    color: var(--muted);
}
.feed-ranking-help code,
.feed-sort-legend code {
    font-family: var(--mono);
}

/* --------------------------------------------------------------------
   Thread list & rows — stronger title hierarchy, upright titles,
   calmer rhythm, clearer hover
   ------------------------------------------------------------------ */
.thread-list {
    border-color: var(--hairline);
    border-radius: var(--radius);
    box-shadow: var(--elev-1);
}
.thread {
    padding: 14px 16px;
    gap: 12px;
    transition: background 0.14s ease;
}
.thread + .thread {
    border-top: 1px solid var(--hairline);
}
.thread:hover {
    background: color-mix(in srgb, var(--accent) 4%, var(--surface));
}
.thread-title,
.thread-title a {
    font-family: var(--font-ui);
    font-style: normal;
    font-weight: 600;
    font-size: 17px;
    line-height: 1.3;
    letter-spacing: -0.01em;
    color: var(--text);
}
.thread-title a:hover {
    color: var(--accent);
    text-decoration: none;
}
.thread-feed-summary {
    font-family: var(--font-ui);
    font-size: 13.5px;
    line-height: 1.5;
    color: var(--muted);
    margin: 4px 0 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.thread-domain {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--faint);
}
.thread:hover .thread-stripe {
    opacity: 1;
}

/* --------------------------------------------------------------------
   Buttons — consistent radius + a little premium on the primary CTA
   ------------------------------------------------------------------ */
.button {
    border-radius: var(--radius-sm);
}
.button.primary {
    box-shadow: 0 6px 18px color-mix(in srgb, var(--accent) 16%, transparent);
}
.button.primary:hover {
    background: color-mix(in srgb, var(--accent) 90%, #fff);
}

/* --------------------------------------------------------------------
   Cards — hairline borders + soft elevation for depth
   ------------------------------------------------------------------ */
.card {
    border-color: var(--hairline);
    box-shadow: var(--elev-1);
}

/* --------------------------------------------------------------------
   Misc polish
   ------------------------------------------------------------------ */
.footer-filter-hint {
    display: none;
} /* dev-facing query hint also removed in markup */
* {
    scrollbar-color: var(--line-2) transparent;
}
