/* CLT Studio. Design tokens first: modules restyle through these, never with new colours.
   Brand: CLT Podcasting (www.cltpodcasting.com). Purple rgb(153,105,249) is the signature,
   but white text on it is 3.7:1, so filled buttons use --brand rgb(124,77,230) (5.2:1).
   Deep purple rgb(69,22,106) carries headings and brand areas. Fonts: Wix Madefor Display
   (headings, figures) + Wix Madefor Text (UI), the marketing site's pair, via Google Fonts. */
:root {
	color-scheme: light;
	--font: "Wix Madefor Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
	--font-display: "Wix Madefor Display", "Wix Madefor Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
	--mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

	--bg: #f7f6fa;
	--surface: #ffffff;
	--surface-2: #fbfaff;         /* sidebar, toolbars */
	--sunken: #f1eff6;
	--hover: #f3effb;
	--text: #17131f;
	--text-2: #463f52;
	--muted: #645e70;             /* 5.6:1 on --bg */
	--border: #e7e3ef;
	--border-strong: #d3cde0;

	--brand: #7c4de6;             /* primary buttons, selected state */
	--brand-strong: #6536cf;      /* hover */
	--brand-bright: #9969f9;      /* signature purple: rings, charts, decoration only */
	--brand-deep: #45166a;        /* headings, brand panels */
	--brand-soft: #f1ebff;
	--brand-soft-2: #e4d8ff;
	--on-brand: #ffffff;
	--link: #6a3ad8;              /* 6.1:1 on white */
	--heading: #2c1046;

	--good: #18794e;  --good-soft: #e3f5eb;  --good-line: #b8e2cb;
	--warn: #8f5800;  --warn-soft: #fcf0d9;  --warn-line: #f0d6a4;
	--bad: #b42318;   --bad-soft: #fdeceb;   --bad-line: #f3c7c2;
	--info: #2459a8;  --info-soft: #e8f0fb;  --info-line: #c8d9f3;

	--radius-sm: 8px;
	--radius: 10px;
	--radius-lg: 14px;
	--shadow-xs: 0 1px 2px rgba(35, 20, 60, .06);
	--shadow: 0 1px 2px rgba(35, 20, 60, .05), 0 2px 6px -2px rgba(35, 20, 60, .06);
	--shadow-lg: 0 2px 4px rgba(35, 20, 60, .04), 0 12px 32px -8px rgba(35, 20, 60, .16);
	--space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-5: 24px; --space-6: 32px; --space-7: 48px;
	--sidebar: 248px;
	--content: 1120px;
	--focus: 0 0 0 2px var(--surface), 0 0 0 4px var(--brand-bright);
	--ease: cubic-bezier(.22, 1, .36, 1);
	--auth-glow: radial-gradient(1200px 600px at 85% -10%, rgba(153, 105, 249, .22), transparent 60%), radial-gradient(900px 500px at -10% 110%, rgba(69, 22, 106, .14), transparent 60%);
}

@media (prefers-color-scheme: dark) {
	:root {
		color-scheme: dark;
		--bg: #0f0c15;
		--surface: #17131f;
		--surface-2: #130f1a;
		--sunken: #1f1a2a;
		--hover: #221c2f;
		--text: #f1eef7;
		--text-2: #cbc4d8;
		--muted: #a098ae;             /* 6.6:1 on --surface */
		--border: #2a2437;
		--border-strong: #3b334c;
		--brand: #7c4de6;
		--brand-strong: #6a3ad8;
		--brand-deep: #2a1043;
		--brand-soft: #241a3a;
		--brand-soft-2: #33245a;
		--link: #b89bff;              /* 7.9:1 on --surface */
		--heading: #ebe2ff;
		--good: #5fd39a;  --good-soft: #12291e;  --good-line: #1f4a35;
		--warn: #f0b955;  --warn-soft: #2d2210;  --warn-line: #574118;
		--bad: #ff8a80;   --bad-soft: #321613;   --bad-line: #5c2622;
		--info: #8cb8ff;  --info-soft: #132239;  --info-line: #23406b;
		--shadow-xs: 0 1px 2px rgba(0, 0, 0, .4);
		--shadow: 0 1px 2px rgba(0, 0, 0, .35), 0 2px 8px -2px rgba(0, 0, 0, .4);
		--shadow-lg: 0 2px 4px rgba(0, 0, 0, .3), 0 16px 40px -8px rgba(0, 0, 0, .6);
		--auth-glow: radial-gradient(1200px 600px at 85% -10%, rgba(124, 77, 230, .28), transparent 60%), radial-gradient(900px 500px at -10% 110%, rgba(153, 105, 249, .12), transparent 60%);
	}
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 15px/1.55 var(--font); color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
a { color: var(--link); text-decoration: none; text-underline-offset: 2px; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.25; margin: 0; font-weight: 650; font-family: var(--font-display); color: var(--heading); text-wrap: balance; }
h1 { font-size: 1.625rem; font-weight: 700; letter-spacing: -.02em; color: var(--text); }
h2 { font-size: 1.0625rem; letter-spacing: -.01em; }
h3 { font-size: 1rem; }
p { margin: 0 0 var(--space-3); }
strong { font-weight: 650; }
code { font-family: var(--mono); font-size: .86em; background: var(--sunken); padding: 1px 6px; border-radius: 5px; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: var(--radius-sm); }
::selection { background: var(--brand-soft-2); }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.center { text-align: center; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; z-index: 50; border-radius: var(--radius-sm); }
.skip:focus { left: 8px; }
.inline { display: inline; }
.stack > * + * { margin-top: var(--space-4); }
.row { display: flex; gap: var(--space-3); align-items: center; flex-wrap: wrap; }
.grid { display: grid; gap: var(--space-4); grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); margin-bottom: var(--space-4); }
.icon { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

/* ---- App shell */
.app { display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); min-height: 100vh; }
/* Grid children may shrink below their content, so a wide table scrolls inside its card
   instead of making the whole page scroll sideways (phones especially). */
.app > .main, .dash > *, .dash-col > * { min-width: 0; }
/* The sidebar column's background runs the full page height, not just the first screen. */
@media (min-width: 861px) {
	.app { background: linear-gradient(to right, var(--surface-2) calc(var(--sidebar) - 1px), var(--border) calc(var(--sidebar) - 1px), var(--border) var(--sidebar), transparent var(--sidebar)), var(--bg); }
}
.sidebar { background: var(--surface-2); border-right: 1px solid var(--border); padding: var(--space-4) var(--space-3); display: flex; flex-direction: column; gap: var(--space-4); position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.sidebar-top { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); padding: var(--space-1) var(--space-2) 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); }
.brand:hover { text-decoration: none; }
.brand-logo { display: block; height: 26px; width: auto; }
@media (prefers-color-scheme: dark) { .brand-logo { filter: brightness(0) invert(1); opacity: .94; } }
.brand-tag { font-family: var(--font-display); font-weight: 700; font-size: .8rem; letter-spacing: .01em; color: var(--heading); background: var(--brand-soft); border-radius: 6px; padding: 3px 7px 2px; line-height: 1.2; }
.sidebar .nav-toggle { display: none; }
.switcher { position: relative; }
.switcher select { width: 100%; appearance: none; -webkit-appearance: none; padding: 9px 34px 9px 40px; font-weight: 600; background: var(--surface); border-color: var(--border); box-shadow: var(--shadow-xs); cursor: pointer; text-overflow: ellipsis; }
.switcher select:hover { border-color: var(--border-strong); }
.switcher-avatar { position: absolute; left: 9px; top: 50%; transform: translateY(-50%); width: 22px; height: 22px; border-radius: 6px; background: linear-gradient(135deg, var(--brand-bright), var(--brand-deep)); color: #fff; font: 700 .7rem/22px var(--font-display); text-align: center; pointer-events: none; }
.switcher .chev { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); pointer-events: none; color: var(--muted); width: 16px; height: 16px; }
.nav-group + .nav-group { margin-top: var(--space-4); }
.nav-label { font-size: .7rem; font-weight: 650; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); padding: 0 10px 6px; margin: 0; }
.sidebar nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; }
.sidebar nav a { position: relative; display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: var(--radius-sm); color: var(--text-2); font-weight: 500; font-size: .92rem; transition: background-color .15s var(--ease), color .15s var(--ease); }
.sidebar nav a .icon { color: var(--muted); transition: color .15s var(--ease); }
.sidebar nav a:hover { background: var(--hover); color: var(--text); text-decoration: none; }
.sidebar nav a:hover .icon { color: var(--text-2); }
.sidebar nav a[aria-current="page"] { background: var(--brand-soft); color: var(--heading); font-weight: 650; }
.sidebar nav a[aria-current="page"] .icon { color: var(--brand); }
.sidebar nav a[aria-current="page"]::before { content: ""; position: absolute; left: -12px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: var(--brand); }
.sidebar-foot { margin-top: auto; display: grid; gap: var(--space-2); }
.user-menu { position: relative; }
.user-menu > summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: var(--radius); cursor: pointer; transition: background-color .15s var(--ease); }
.user-menu > summary::-webkit-details-marker { display: none; }
.user-menu > summary:hover, .user-menu[open] > summary { background: var(--hover); }
.avatar { width: 30px; height: 30px; border-radius: 50%; flex: none; display: grid; place-items: center; background: var(--brand-soft-2); color: var(--heading); font: 700 .75rem/1 var(--font-display); }
.user-id { min-width: 0; flex: 1; display: grid; line-height: 1.3; }
.user-id strong { font-size: .85rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-id span { font-size: .76rem; color: var(--muted); text-transform: capitalize; }
.user-menu .chev { width: 16px; height: 16px; color: var(--muted); }
.user-pop { position: absolute; bottom: calc(100% + 6px); left: 0; right: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 6px; z-index: 30; animation: pop .16s var(--ease); }
.user-pop form { margin: 0; }
.menu-item { display: flex; width: 100%; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 6px; background: none; border: 0; font: inherit; font-size: .9rem; color: var(--text); cursor: pointer; text-align: left; }
.menu-item:hover { background: var(--hover); text-decoration: none; }
.menu-item .icon { width: 16px; height: 16px; color: var(--muted); }
.user-pop .legal-links { padding: 6px 10px 4px; margin: 4px 0 0; border-top: 1px solid var(--border); }
.sidebar-legal { padding: 0 8px; }
.main { padding: 0 var(--space-6) var(--space-7); max-width: calc(var(--content) + 2 * var(--space-6)); width: 100%; animation: enter .28s var(--ease); }
.page-header { position: sticky; top: 0; z-index: 20; display: flex; justify-content: space-between; align-items: center; gap: var(--space-4); margin: 0 calc(-1 * var(--space-6)) var(--space-5); padding: var(--space-5) var(--space-6) var(--space-4); background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid transparent; }
.page-header h1 { overflow-wrap: anywhere; }
.page-header p { margin: 4px 0 0; font-size: .92rem; }
@supports (animation-timeline: scroll()) {
	.page-header { animation: header-line linear both; animation-timeline: scroll(); animation-range: 0 40px; }
}
@keyframes header-line { to { border-bottom-color: var(--border); } }
.actions { display: flex; gap: var(--space-2); flex-wrap: wrap; align-items: center; }

@media (max-width: 860px) {
	.app { grid-template-columns: 1fr; grid-template-rows: auto 1fr; align-items: start; }
	.sidebar.is-open { max-height: 100vh; overflow-y: auto; background: var(--surface-2); box-shadow: var(--shadow-lg); }
	.nav-toggle .icon-close, .sidebar.is-open .nav-toggle .icon-open { display: none; }
	.sidebar.is-open .nav-toggle .icon-close { display: block; }
	.sidebar { position: sticky; top: 0; z-index: 40; height: auto; max-height: none; overflow: visible; border-right: 0; border-bottom: 1px solid var(--border); padding: var(--space-3) var(--space-4); gap: var(--space-3); background: color-mix(in srgb, var(--surface-2) 90%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
	.sidebar-top { padding: 0; }
	.sidebar .nav-toggle { display: inline-flex; }
	.js .sidebar:not(.is-open) .sidebar-body { display: none; }
	.sidebar-body { display: grid; gap: var(--space-4); padding-bottom: var(--space-2); animation: drop .2s var(--ease); }
	.sidebar nav a[aria-current="page"]::before { left: -4px; }
	.sidebar-foot { margin-top: 0; }
	.user-pop { bottom: auto; top: calc(100% + 6px); }
	.main { padding: 0 var(--space-4) var(--space-6); }
	.page-header { position: static; margin: 0 calc(-1 * var(--space-4)) var(--space-4); padding: var(--space-5) var(--space-4) 0; background: none; backdrop-filter: none; -webkit-backdrop-filter: none; flex-wrap: wrap; align-items: flex-start; animation: none; }
}
@media (min-width: 861px) { .sidebar-body { display: contents; } }

/* ---- Public pages (sign-in, apply, guest pages) */
/* html gets the plain background so the body's glow paints over the whole body box, which
   grows with the content: the glow covers the full page, not just the first screen. */
html:has(> body.public) { background: var(--bg); }
.public { min-height: 100vh; display: flex; flex-direction: column; align-items: center; padding: var(--space-7) var(--space-4) var(--space-5); background: var(--auth-glow), var(--bg); background-repeat: no-repeat; background-size: 100% 100%; }
.public-main { width: 100%; max-width: 440px; flex: 1; display: flex; flex-direction: column; animation: enter .32s var(--ease); }
.public-main.wide { max-width: 720px; }
.public-brand { display: flex; justify-content: center; margin-bottom: var(--space-6); }
.public-brand .brand-logo { height: 32px; }
.public .card { box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--border) 70%, transparent); padding: var(--space-6); }
.public .card-head h2 { font-size: 1.375rem; font-weight: 700; letter-spacing: -.015em; }
.public-foot { margin-top: auto; padding-top: var(--space-6); display: grid; justify-items: center; gap: 4px; text-align: center; }
.public-foot .legal-links { justify-content: center; margin: 0; }
.public-foot .copyright { font-size: .78rem; color: var(--muted); margin: 0; }
.bare { background: transparent; }
.bare .public-main { max-width: none; padding: var(--space-4); animation: none; }
.auth-center { text-align: center; }
.auth-center .empty-icon { margin: 0 auto var(--space-4); }
.auth-title { font-size: 1.375rem; font-weight: 700; letter-spacing: -.015em; margin-bottom: var(--space-3); }
.auth-card .btn-block { margin-top: var(--space-2); }
.auth-who { display: grid; gap: 2px; padding: var(--space-3) var(--space-4); margin-bottom: var(--space-4); background: var(--brand-soft); border-radius: var(--radius); }
.auth-who strong { color: var(--heading); overflow-wrap: anywhere; font-size: 1.02rem; }
.auth-note { margin: var(--space-4) 0 0; }
.auth-alt { margin: var(--space-5) 0 0; padding-top: var(--space-4); border-top: 1px solid var(--border); font-size: .9rem; }

/* ---- Cards, tables, empty states */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: var(--space-5); box-shadow: var(--shadow); }
.card + .card { margin-top: var(--space-4); }
.grid > .card + .card, .tiles > .card + .card { margin-top: 0; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: var(--space-3); margin-bottom: var(--space-4); }
.card-head h2 { display: flex; align-items: center; gap: 8px; }
.card-head h2 .icon { color: var(--brand); width: 17px; height: 17px; }
.card-flush { padding: 0; overflow: hidden; }
.card-warn { background: color-mix(in srgb, var(--warn-soft) 70%, var(--surface)); border-color: var(--warn-line); }
.card-warn > .card-head h2 .icon { color: var(--warn); }
.post-block { display: block; }
.card-flush > .card-head { padding: var(--space-4) var(--space-5) 0; }
.table-wrap { overflow: auto; max-height: min(72vh, 760px); margin: 0 calc(-1 * var(--space-5)); padding: 0 var(--space-5); }
.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .92rem; }
.table th { position: sticky; top: 0; z-index: 1; background: var(--surface); text-align: left; font-weight: 600; color: var(--muted); font-size: .74rem; text-transform: uppercase; letter-spacing: .06em; padding: 10px 12px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.table th.right { text-align: right; }
.table td { padding: 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table tbody tr { transition: background-color .12s var(--ease); }
.table tbody tr:hover td { background: var(--hover); }
.table tbody tr:hover td:first-child { border-radius: var(--radius-sm) 0 0 var(--radius-sm); }
.table tbody tr:hover td:last-child { border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.table tr:last-child td { border-bottom: 0; }
.table td strong a, .table td > a:first-child:only-child { color: var(--text); font-weight: 600; }
.table td strong a:hover { color: var(--link); }
.empty { text-align: center; padding: var(--space-6) var(--space-4); display: grid; justify-items: center; }
.empty-icon { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; margin-bottom: var(--space-4); color: var(--brand); background: linear-gradient(145deg, var(--brand-soft), var(--brand-soft-2)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand-bright) 22%, transparent), 0 6px 16px -6px color-mix(in srgb, var(--brand) 40%, transparent); }
.empty-icon .icon { width: 26px; height: 26px; stroke-width: 1.6; }
.empty h3 { margin-bottom: var(--space-2); font-size: 1.05rem; color: var(--text); }
.empty p { max-width: 46ch; margin-inline: auto; }
.empty .btn { margin-top: var(--space-2); }
.stat { font: 700 1.75rem/1.1 var(--font-display); letter-spacing: -.02em; color: var(--text); margin: 0 0 var(--space-2); font-variant-numeric: tabular-nums; }

/* Stat tiles (Today) */
.tiles { display: grid; gap: var(--space-4); grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-bottom: var(--space-5); }
.tile { position: relative; display: grid; gap: 6px; align-content: start; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: var(--space-4) var(--space-5); box-shadow: var(--shadow); color: inherit; transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease); }
a.tile:hover { text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow-lg); border-color: var(--border-strong); }
.tile-head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); font-size: .85rem; font-weight: 600; color: var(--text-2); }
.tile-head .icon { width: 16px; height: 16px; color: var(--brand); }
.tile-value { font: 700 2rem/1.1 var(--font-display); letter-spacing: -.025em; color: var(--text); font-variant-numeric: tabular-nums; }
.tile-foot { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); font-size: .8rem; color: var(--muted); min-height: 28px; }
.tile-accent { background: linear-gradient(150deg, #5a2390 0%, var(--brand-deep) 70%); border-color: transparent; color: #f4ecff; }
.tile-accent .tile-head, .tile-accent .tile-foot { color: #dccbf7; }
.tile-accent .tile-head .icon { color: #c9adff; }
.tile-accent .tile-value { color: #fff; }
.trend { display: inline-flex; align-items: center; gap: 3px; font-weight: 650; font-size: .78rem; padding: 2px 7px; border-radius: 999px; background: var(--sunken); color: var(--text-2); }
.trend .icon { width: 13px; height: 13px; stroke-width: 2.2; }
.trend-up { background: var(--good-soft); color: var(--good); }
.trend-down { background: var(--bad-soft); color: var(--bad); }
.tile-accent .trend { background: rgba(255, 255, 255, .14); color: #fff; }
.spark { display: block; width: 100%; max-width: 112px; flex: none; height: 32px; overflow: visible; }
.spark path.line { fill: none; stroke: var(--brand-bright); stroke-width: 1.75; stroke-linejoin: round; stroke-linecap: round; }
.spark path.area { fill: url(#spark-fill); stroke: none; }
.tile-accent .spark path.line { stroke: #d2b8ff; }

/* Dashboard layout */
.dash { display: grid; gap: var(--space-4); grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); align-items: start; }
.dash > .card + .card, .dash-col > .card + .card { margin-top: 0; }
.dash-col { display: grid; gap: var(--space-4); }
@media (max-width: 1100px) { .dash { grid-template-columns: minmax(0, 1fr); } }
.pipeline { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.stage { display: grid; gap: 2px; padding: 10px 12px; border-radius: var(--radius); background: var(--sunken); color: inherit; transition: background-color .15s var(--ease); }
a.stage:hover { background: var(--brand-soft); text-decoration: none; }
.stage-n { font: 700 1.35rem/1.15 var(--font-display); color: var(--text); font-variant-numeric: tabular-nums; }
.stage-l { font-size: .78rem; color: var(--muted); font-weight: 550; }
.stage-bar { height: 4px; border-radius: 4px; background: var(--border); overflow: hidden; margin-top: 6px; }
.stage-bar span { display: block; height: 100%; background: var(--brand-bright); border-radius: inherit; }
.list { list-style: none; margin: 0; padding: 0; display: grid; }
.list-item { display: flex; align-items: center; gap: var(--space-3); padding: 10px 8px; margin: 0 -8px; border-radius: var(--radius-sm); color: inherit; transition: background-color .12s var(--ease); }
a.list-item:hover { background: var(--hover); text-decoration: none; }
.list-item + .list-item { border-top: 1px solid var(--border); }
.list-main { min-width: 0; flex: 1; display: grid; }
.list-title { font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-sub { font-size: .82rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.date-chip { flex: none; width: 44px; text-align: center; border-radius: var(--radius-sm); background: var(--brand-soft); color: var(--heading); padding: 4px 0 5px; line-height: 1.1; }
.date-chip b { display: block; font: 700 1.05rem/1.1 var(--font-display); }
.date-chip small { display: block; font-size: .66rem; font-weight: 650; text-transform: uppercase; letter-spacing: .06em; color: var(--link); }
.list-empty { color: var(--muted); font-size: .9rem; margin: 0; padding: var(--space-2) 0; display: flex; align-items: center; gap: 8px; }
.list-empty .icon { color: var(--muted); width: 16px; height: 16px; }
.quick { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.quick a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); color: var(--text); font-weight: 600; font-size: .9rem; transition: border-color .15s var(--ease), background-color .15s var(--ease), transform .15s var(--ease); }
.quick a:hover { border-color: var(--brand-soft-2); background: var(--brand-soft); text-decoration: none; }
.quick a:active { transform: scale(.98); }
.quick .icon { color: var(--brand); width: 17px; height: 17px; }
.bars { display: flex; align-items: flex-end; gap: 3px; height: 96px; padding-top: var(--space-2); }
.bars span { flex: 1; min-height: 3px; border-radius: 3px 3px 0 0; background: linear-gradient(to top, var(--brand), var(--brand-bright)); opacity: .85; transition: opacity .15s; }
.bars span:hover { opacity: 1; }
.bars-axis { display: flex; justify-content: space-between; font-size: .74rem; color: var(--muted); margin-top: 6px; }
.big-number { display: flex; align-items: baseline; gap: var(--space-3); flex-wrap: wrap; }
.big-number .stat { margin: 0; }

/* ---- Forms */
.field { display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px; margin-bottom: var(--space-4); }
.field label { font-weight: 600; font-size: .9rem; color: var(--text); }
.field-check label { font-weight: 450; display: flex; gap: 8px; align-items: center; }
input[type=text], input[type=email], input[type=url], input[type=number], input[type=password], input[type=date], input[type=datetime-local], input[type=search], input[type=tel], input[type=time], select, textarea {
	font: inherit; color: inherit; width: 100%; padding: 9px 12px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--surface); box-shadow: var(--shadow-xs); transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
}
input::placeholder, textarea::placeholder { color: var(--muted); opacity: 1; }
input:hover:not(:focus), select:hover:not(:focus), textarea:hover:not(:focus) { border-color: color-mix(in srgb, var(--border-strong) 60%, var(--text-2)); }
input[type=checkbox], input[type=radio] { accent-color: var(--brand); width: 16px; height: 16px; }
input[type=file] { font: inherit; font-size: .9rem; max-width: 100%; }
input[type=file]::file-selector-button { font: inherit; font-weight: 600; font-size: .85rem; padding: 6px 12px; margin-right: 10px; border-radius: var(--radius-sm); border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); cursor: pointer; }
textarea { resize: vertical; line-height: 1.5; }
/* A select is as tall as a text input next to it (inputs: 9px padding + 15px x 1.55 line + borders). */
.field select { height: calc(15px * 1.55 + 20px); padding-block: 0; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-bright) 30%, transparent); }
.hint { color: var(--muted); font-size: .84rem; margin: 0; }
.error { color: var(--bad); font-size: .84rem; margin: 0; font-weight: 550; }
.field-error input, .field-error textarea, .field-error select { border-color: var(--bad); }
.field-error input:focus, .field-error textarea:focus { box-shadow: 0 0 0 3px color-mix(in srgb, var(--bad) 22%, transparent); }
.hp { position: absolute; left: -5000px; }
progress { accent-color: var(--brand); }

/* ---- Buttons */
.btn { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 7px; font: inherit; font-weight: 600; font-size: .92rem; padding: 9px 16px; border-radius: var(--radius-sm); border: 1px solid transparent; cursor: pointer; text-decoration: none; line-height: 1.2; white-space: nowrap; transition: background-color .15s var(--ease), border-color .15s var(--ease), box-shadow .15s var(--ease), transform .1s var(--ease), color .15s; }
.btn:hover { text-decoration: none; }
.btn:active:not(:disabled) { transform: translateY(1px); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
.btn .icon { width: 16px; height: 16px; }
.btn-primary { background: var(--brand); color: var(--on-brand); box-shadow: 0 1px 2px rgba(45, 15, 90, .25), inset 0 1px 0 rgba(255, 255, 255, .14); }
.btn-primary:hover { background: var(--brand-strong); color: var(--on-brand); }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--border-strong); box-shadow: var(--shadow-xs); }
.btn-secondary:hover { background: var(--hover); border-color: color-mix(in srgb, var(--border-strong) 70%, var(--text-2)); }
.btn-danger { background: var(--surface); color: var(--bad); border-color: var(--bad-line); }
.btn-danger:hover { background: var(--bad-soft); }
.btn-ghost { background: transparent; color: var(--text-2); }
.btn-ghost:hover { background: var(--hover); color: var(--text); }
.btn-sm { padding: 5px 11px; font-size: .84rem; border-radius: 7px; }
.btn-lg { padding: 12px 22px; font-size: 1rem; }
.btn-block { width: 100%; }
.btn-icon { padding: 7px; }
.btn.is-loading { color: transparent !important; pointer-events: none; }
.btn.is-loading::after { content: ""; position: absolute; width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-color: var(--on-brand) var(--on-brand) transparent transparent; animation: spin .7s linear infinite; }
.btn-secondary.is-loading::after, .btn-ghost.is-loading::after, .btn-danger.is-loading::after { border-color: var(--text-2) var(--text-2) transparent transparent; }
button.link { background: none; border: 0; padding: 0; color: var(--link); font: inherit; cursor: pointer; }
button.link:hover { text-decoration: underline; }

/* ---- Flash (toast) + badges */
.flash { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: var(--radius); margin-bottom: var(--space-4); border: 1px solid; font-size: .92rem; font-weight: 500; box-shadow: var(--shadow); animation: toast .32s var(--ease); }
.flash .icon { width: 18px; height: 18px; margin-top: 1px; }
.flash-msg { flex: 1; min-width: 0; }
.flash-close { background: none; border: 0; padding: 2px; margin: -2px -4px -2px 0; color: inherit; opacity: .7; cursor: pointer; border-radius: 6px; display: inline-flex; }
.flash-close:hover { opacity: 1; }
.flash-close .icon { width: 16px; height: 16px; margin: 0; }
.flash-success { background: var(--good-soft); color: var(--good); border-color: var(--good-line); }
.flash-error { background: var(--bad-soft); color: var(--bad); border-color: var(--bad-line); }
.flash-info { background: var(--info-soft); color: var(--info); border-color: var(--info-line); }
.toasts { position: fixed; z-index: 60; right: var(--space-5); bottom: var(--space-5); width: min(380px, calc(100vw - 2 * var(--space-4))); display: grid; gap: var(--space-2); }
.toasts .flash { margin: 0; box-shadow: var(--shadow-lg); background-color: color-mix(in srgb, var(--surface) 30%, var(--good-soft)); }
.toasts .flash-error { background-color: color-mix(in srgb, var(--surface) 30%, var(--bad-soft)); }
.toasts .flash-info { background-color: color-mix(in srgb, var(--surface) 30%, var(--info-soft)); }
.flash.is-leaving { opacity: 0; transform: translateY(6px); transition: opacity .25s, transform .25s; }
@media (max-width: 560px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-3); } .tile { padding: var(--space-3) var(--space-4); } .tile-value { font-size: 1.6rem; } .tile-foot { flex-wrap: wrap; } .tile-accent { grid-column: 1 / -1; } .pipeline { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 860px) { .toasts { right: var(--space-4); bottom: var(--space-4); } }
.badge { display: inline-flex; align-items: center; gap: 5px; font-size: .74rem; font-weight: 650; padding: 2px 9px; border-radius: 999px; background: var(--sunken); color: var(--text-2); line-height: 1.5; white-space: nowrap; }
.badge-good, .badge-warn, .badge-bad, .badge-info { padding-left: 7px; }
.badge-good::before, .badge-warn::before, .badge-bad::before, .badge-info::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-good { background: var(--good-soft); color: var(--good); }
.badge-warn { background: var(--warn-soft); color: var(--warn); }
.badge-bad { background: var(--bad-soft); color: var(--bad); }
.badge-info { background: var(--info-soft); color: var(--info); }
.badge-brand { background: var(--brand-soft); color: var(--heading); }

.cf-turnstile { margin: var(--space-3) 0; min-height: 65px; }
details > summary { cursor: pointer; }
hr { border: 0; border-top: 1px solid var(--border); margin: var(--space-5) 0; }
meter { accent-color: var(--brand); }

/* ---- Motion: state feedback only; all of it switches off for reduced motion. */
@keyframes enter { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@keyframes toast { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: translateY(4px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes drop { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.skeleton { border-radius: var(--radius-sm); background: linear-gradient(90deg, var(--sunken) 25%, var(--hover) 50%, var(--sunken) 75%); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; color: transparent !important; }
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
	.btn.is-loading::after { animation: none; border-color: currentColor; opacity: .5; }
	a.tile:hover { transform: none; }
}

/* ---- legal links (footer, user menu) */
.legal-links { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: var(--space-3); font-size: .78rem; }
.legal-links a { color: var(--muted); }
.legal-links a:hover { color: var(--text); }
/* ---- trust (legal pages, report form, takedowns) */
.legal-draft { background: var(--warn-soft); color: var(--warn); border-radius: var(--radius); padding: 10px 14px; margin-bottom: var(--space-4); }
.legal-placeholder { background: var(--warn-soft); color: var(--warn); padding: 0 3px; border-radius: 3px; font-weight: 600; }
.legal-nav { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: var(--space-4); font-size: .9rem; }
.legal-nav a[aria-current="page"] { font-weight: 650; color: var(--text); }
.legal article { line-height: 1.6; }
.legal article h2 { font-size: 1.05rem; margin-top: var(--space-5); }
.legal article li { margin-bottom: 6px; }
.legal-agent { font-style: normal; background: var(--sunken); padding: 12px 16px; border-radius: var(--radius-sm); }
.report-form fieldset { border: 0; padding: 0; margin: 0 0 var(--space-4); }
.report-form legend { font-weight: 600; margin-bottom: var(--space-2); }
.report-form .radio { display: block; margin-bottom: var(--space-2); }
.report-form .radio .hint { display: block; margin-left: 24px; }
.report-form .dmca { background: var(--sunken); padding: var(--space-4); border-radius: var(--radius); }
.report-form:has(input[name="category"]:checked):not(:has(input[name="category"][value="copyright"]:checked)) .dmca { display: none; }
.prewrap { white-space: pre-wrap; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; }
/* ---- intake */
.intake-filters { margin-bottom: var(--space-4); gap: var(--space-4); }
.intake-filters label { display: flex; flex-direction: column; gap: 4px; font-size: .85rem; color: var(--text-2); }
.intake-filters input[type=text] { min-width: 220px; }
.intake-filters select, .intake-bulkbar select { width: auto; }
.intake-filters label.intake-check, .intake-bulkbar label.intake-check { flex-direction: row; align-items: center; gap: 6px; }
.intake-bulkbar { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: var(--space-3) var(--space-4); margin-bottom: var(--space-4); font-size: .88rem; }
.intake-bulkbar label { display: flex; align-items: center; gap: 6px; }
.intake-bulkbar input[type=date] { width: auto; padding: 5px 8px; }
.intake-board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px, 1fr); gap: var(--space-4); overflow-x: auto; padding-bottom: var(--space-3); align-items: start; }
.intake-col { background: var(--sunken); border-radius: var(--radius-lg); padding: var(--space-3); min-height: 120px; }
.intake-col header { padding: var(--space-1) var(--space-2) var(--space-3); }
.intake-col h2 { font-size: .95rem; }
.intake-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.intake-empty { padding: 0 var(--space-2); }
.intake-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: var(--space-3); box-shadow: var(--shadow); }
.intake-card p { margin: 4px 0 0; }
.intake-card-top { display: flex; align-items: flex-start; gap: var(--space-2); }
.intake-name { font-weight: 600; color: var(--text); flex: 1; min-width: 0; overflow-wrap: anywhere; }
.intake-pick { padding-top: 2px; }
.intake-reason { color: var(--text-2); white-space: pre-line; }
.intake-quick { margin-top: var(--space-2); gap: var(--space-2); }
.intake-guest { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-4); align-items: start; }
.intake-guest .card + .card { margin-top: 0; }
@media (max-width: 960px) { .intake-guest { grid-template-columns: 1fr; } }
.intake-reason-lg { white-space: pre-line; font-size: 1rem; }
.intake-meter { display: grid; grid-template-columns: 140px 1fr 32px; align-items: center; gap: var(--space-3); font-size: .9rem; margin-bottom: var(--space-2); }
.intake-meter meter { width: 100%; height: 10px; }
.intake-meter strong { text-align: right; }
.intake-flags { margin: var(--space-2) 0 var(--space-3); padding-left: 1.2em; color: var(--warn); font-size: .9rem; }
.intake-flag { background: var(--bad-soft); color: var(--bad); padding: var(--space-2) var(--space-3); border-radius: var(--radius-sm); }
.intake-snooze { margin-top: var(--space-4); }
.intake-snooze input[type=date] { width: auto; }
.intake-secondary { margin-top: var(--space-3); }
.intake-timeline { list-style: none; margin: 0 0 var(--space-4); padding: 0; display: grid; gap: var(--space-2); font-size: .92rem; }
.intake-timeline li { padding-left: var(--space-3); border-left: 2px solid var(--border); }
.intake-answers { margin: 0; display: grid; gap: 2px var(--space-3); }
.intake-answers dt { font-weight: 600; font-size: .85rem; color: var(--muted); margin-top: var(--space-3); }
.intake-answers dd { margin: 0; overflow-wrap: anywhere; }
.intake-answers dd p { margin: 0 0 var(--space-2); }
.intake-headshot { float: right; width: 120px; height: 120px; object-fit: cover; border-radius: var(--radius); margin: 0 0 var(--space-3) var(--space-3); }
.intake-links { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-3); overflow-wrap: anywhere; }
.intake-links p { margin: 4px 0 0; }
.intake-builder input[type=text] { min-width: 200px; }
.intake-builder textarea { margin-top: 4px; }
.intake-order { width: 70px !important; }
.intake-off td { color: var(--muted); }
.intake-newform { margin-top: var(--space-4); }
.intake-newform input { max-width: 320px; }
.intake-snippet { font-family: var(--mono); font-size: .82rem; }
.intake-merge { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.intake-preview { margin-top: var(--space-4); }
.intake-preview summary { cursor: pointer; color: var(--link); }
.intake-mail { white-space: pre-wrap; font: inherit; background: var(--sunken); padding: var(--space-4); border-radius: var(--radius); margin: 0; overflow-wrap: anywhere; }
.intake-thanks { text-align: center; padding: var(--space-5) 0; }
.intake-thanks h2 { margin-bottom: var(--space-3); font-size: 1.25rem; }
.intake-embed .intake-apply { max-width: 680px; margin: 0 auto; }
.bare .intake-embed { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: var(--space-5); }
/* ---- booking */
.book-title { margin-bottom: var(--space-2); }
.lead-time { font-size: 1.1rem; margin-bottom: var(--space-1); }
.tz-picker { margin-bottom: var(--space-4); }
.tz-picker select { width: auto; max-width: 100%; }
.slot-day { border: 0; padding: 0; margin: 0 0 var(--space-4); }
.slot-day legend { font-weight: 600; margin-bottom: var(--space-2); padding: 0; }
.slot-grid { display: grid; gap: var(--space-2); grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
.slot { position: relative; }
.slot input { position: absolute; opacity: 0; inset: 0; }
.slot span { display: block; text-align: center; padding: 8px 6px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; font-weight: 550; }
.slot:hover span { background: var(--sunken); }
.slot input:checked + span { background: var(--brand); color: var(--on-brand); border-color: var(--link); }
.slot input:focus-visible + span { box-shadow: var(--focus); }
.slot-pages { justify-content: space-between; margin-bottom: var(--space-4); }
.check-row { display: flex; gap: 8px; align-items: center; font-weight: 400; }
fieldset.field { border: 0; padding: 0; }
fieldset.field legend { font-weight: 550; font-size: .92rem; margin-bottom: 6px; padding: 0; }
.grow { flex: 1 1 280px; }
details.tpl { border: 1px solid var(--border); border-radius: var(--radius); padding: var(--space-3) var(--space-4); margin-bottom: var(--space-3); }
details.tpl summary { cursor: pointer; font-weight: 550; }
details.tpl[open] summary { margin-bottom: var(--space-3); }
.prep-questions li, .checklist li, .episode-list li { margin-bottom: var(--space-2); }
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { padding: 4px 0; }
.right { text-align: right; }
/* ---- review */
.review-two { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.review-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.review-list .row { justify-content: space-between; }
.review-upload { background: var(--sunken); border-radius: var(--radius); padding: var(--space-4); }
.review-upload h3 { margin-bottom: var(--space-3); }
.review-upload progress { width: 100%; margin-bottom: var(--space-2); }
.review-transcript pre, .review-pre { white-space: pre-wrap; max-height: 420px; overflow: auto; background: var(--sunken); padding: var(--space-3); border-radius: var(--radius-sm); font: .88rem/1.5 var(--mono); }
.review-transcript summary { cursor: pointer; margin-bottom: var(--space-3); }
.review-options { margin-bottom: var(--space-4); }
.review-chosen { font-weight: 600; }
.review-chosen::after { content: " (current)"; color: var(--muted); font-weight: 400; }
.review-notes { margin-bottom: var(--space-5); }
.review-line { padding: var(--space-2) var(--space-3); border-radius: var(--radius-sm); margin-bottom: 2px; }
.review-line p, .review-line h3 { margin: 0; }
.review-line.is-flagged { background: var(--warn-soft); }
.review-line.is-approved { background: var(--good-soft); }
.review-flag { margin-top: var(--space-1); font-size: .9rem; color: var(--warn); }
.review-choice { gap: var(--space-3); margin-top: var(--space-2); font-size: .9rem; }
.review-choice input[type=text] { flex: 1; min-width: 180px; padding: 5px 8px; }
.review-warn { background: var(--warn-soft); color: var(--warn); border-radius: var(--radius-sm); padding: var(--space-3) var(--space-3) var(--space-3) var(--space-6); margin: 0 0 var(--space-4); }
.review-diff { background: var(--info-soft); border-radius: var(--radius); padding: var(--space-4); margin-bottom: var(--space-4); }
.review-diff dl { display: grid; grid-template-columns: max-content 1fr; gap: var(--space-2) var(--space-4); margin: var(--space-3) 0 0; }
.review-diff dt { font-weight: 600; }
.review-diff dd { margin: 0; white-space: pre-wrap; }
.review-diff del { color: var(--bad); }
.review-diff ins { background: var(--good-soft); color: var(--good); text-decoration: none; padding: 0 3px; border-radius: 3px; }
.review-guest { align-items: flex-start; margin-bottom: var(--space-4); }
.review-avatar { border-radius: 50%; object-fit: cover; }
.review-quote { border-bottom: 1px solid var(--border); padding-bottom: var(--space-3); margin-bottom: var(--space-3); }
.review-images { display: grid; gap: var(--space-4); grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.review-images figure { margin: 0; }
.review-images img, .review-previews img { width: 100%; height: auto; border-radius: var(--radius-sm); border: 1px solid var(--border); display: block; }
.review-images figcaption { font-size: .85rem; margin-top: var(--space-2); }
.review-colors { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.review-colors input[type=color] { width: 44px; height: 32px; padding: 0; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: none; }
.review-template { border-top: 1px solid var(--border); padding: var(--space-4) 0; }
.review-previews { display: grid; gap: var(--space-3); grid-template-columns: 1fr 1fr 1.4fr; align-items: start; margin-top: var(--space-3); }
.review-logo { max-height: 80px; max-width: 100%; margin-bottom: var(--space-3); }
.review-guest-form h1 { margin-bottom: var(--space-2); }
.review-lines { border: 0; padding: 0; margin: 0; }
/* ---- publish */
.copy-field { display: flex; gap: var(--space-2); align-items: center; margin: var(--space-2) 0; }
.copy-field input { flex: 1; min-width: 0; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85rem; }
.dir-list, .post-list, .stack-list, .share-images { list-style: none; margin: 0; padding: 0; }
.dir-row { display: grid; gap: var(--space-2); padding: var(--space-3) 0; border-bottom: 1px solid var(--border); }
.dir-row:last-child { border-bottom: 0; }
.dir-row .hint { margin-top: 2px; }
.dir-actions, .dir-forms { display: flex; gap: var(--space-2); flex-wrap: wrap; align-items: center; }
.dir-forms input[type=url] { min-width: 260px; flex: 1; }
.post-item { padding: var(--space-4) 0; border-bottom: 1px solid var(--border); }
.post-item:last-child { border-bottom: 0; }
.post-head { margin-bottom: var(--space-2); }
.post-body { display: flex; gap: var(--space-4); align-items: flex-start; }
.post-form { flex: 1; min-width: 0; }
.post-img { width: 120px; height: 120px; object-fit: cover; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.post-copy { white-space: pre-wrap; margin: 0; }
.check-inline { display: inline-flex; gap: 6px; align-items: center; margin-right: var(--space-4); font-weight: 400; }
.stack-list li + li { margin-top: var(--space-3); }
.share-images { display: grid; gap: var(--space-4); grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.share-images li { display: grid; gap: var(--space-2); justify-items: start; }
.share-images img { width: 100%; height: auto; border-radius: var(--radius-sm); border: 1px solid var(--border); }
fieldset.field { border: 0; padding: 0; margin: 0 0 var(--space-4); }
fieldset.field legend { font-weight: 550; font-size: .92rem; margin-bottom: 6px; }

/* ---- hosting */
.hosting-cover { border-radius: var(--radius); border: 1px solid var(--border); display: block; margin-bottom: var(--space-3); object-fit: cover; }
.hosting-bars { display: flex; align-items: flex-end; gap: 2px; height: 72px; margin: var(--space-3) 0; }
.hosting-bars span { flex: 1; background: var(--brand-soft); border-top: 2px solid var(--brand); min-height: 2px; }
.hosting-mini { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.hosting-checks { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.hosting-check { display: flex; gap: var(--space-2); align-items: baseline; }
.hosting-public-head { display: flex; gap: var(--space-4); align-items: center; margin-bottom: var(--space-4); }
.hosting-public-head img { border-radius: var(--radius); flex: none; }
.hosting-notes p, .hosting-notes ul, .hosting-notes ol { margin: 0 0 var(--space-3); }
.hosting-player { width: 100%; margin: var(--space-3) 0; }
.hosting-ep-list, .hosting-chapters { margin: 0; padding-left: var(--space-5); display: grid; gap: var(--space-2); }
.hosting-ep-list { list-style: none; padding-left: 0; }
.hosting-embed { max-width: 640px; }

/* ---- memberships */
.membership-tier { padding: var(--space-3) 0; }
.membership-tier p { margin: 0 0 var(--space-2); }
.membership-option { display: inline-flex; gap: var(--space-2); align-items: center; padding: var(--space-2) var(--space-3); border-radius: var(--radius); background: var(--surface); cursor: pointer; }
.membership-tier-edit + .membership-tier-edit { margin-top: var(--space-3); }
.membership-tier-edit summary { cursor: pointer; padding: var(--space-2) 0; }
/* ---- apple */
.apple-events { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.apple-event { display: flex; gap: var(--space-2); align-items: baseline; flex-wrap: wrap; }
.apple-error p { margin: 0 0 var(--space-1); }

/* ---- media (clips, audiograms, loudness, mixdown) */
.md-job { display: inline-flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); min-width: 0; }
.md-job .md-err { flex-basis: 100%; color: var(--bad); }
.md-job .hint { flex-basis: 100%; }
.md-bar { position: relative; width: 120px; height: 6px; border-radius: 999px; background: var(--sunken); overflow: hidden; }
.md-job.is-compact .md-bar { width: 72px; }
.md-bar > span { position: absolute; inset: 0 auto 0 0; background: var(--brand-bright); border-radius: inherit; transition: width .4s var(--ease); }
.md-job[data-status=queued] .md-bar > span { background: var(--border-strong); }
.md-cell { display: flex; align-items: center; gap: var(--space-3); min-width: 0; }
.md-cell > span:last-child { display: grid; min-width: 0; }
.md-kind { display: inline-grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: var(--radius-sm); background: var(--brand-soft); color: var(--brand); }
.md-actions { justify-content: flex-end; gap: var(--space-1); flex-wrap: nowrap; }
.md-facts { margin: 0; padding-left: 1.1em; display: grid; gap: var(--space-2); font-size: .9rem; color: var(--text-2); }
.md-row { gap: var(--space-2); margin-top: var(--space-3); }
.md-meter-head, .md-lufs-head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-3); font-size: .88rem; margin-bottom: var(--space-2); }
.md-meter-head strong { font-family: var(--font-display); font-size: 1.05rem; }
.md-meter-track { display: block; height: 8px; border-radius: 999px; background: var(--sunken); overflow: hidden; margin-bottom: var(--space-2); }
.md-meter-track > span { display: block; height: 100%; border-radius: inherit; background: var(--brand-bright); }
.md-meter.is-warn .md-meter-track > span { background: var(--warn); }
.md-meter.is-bad .md-meter-track > span { background: var(--bad); }
.md-lufs { margin-bottom: var(--space-4); }
.md-lufs-head strong { font-family: var(--font-display); font-size: 1.15rem; }
.md-lufs-head .is-good { color: var(--good); } .md-lufs-head .is-warn { color: var(--warn); } .md-lufs-head .is-bad { color: var(--bad); }
.md-lufs-track { position: relative; display: block; height: 10px; border-radius: 999px; background: linear-gradient(90deg, var(--sunken), var(--brand-soft-2) 58%, var(--sunken)); }
.md-lufs-target { position: absolute; top: -4px; bottom: -4px; width: 2px; margin-left: -1px; background: var(--brand-deep); border-radius: 2px; }
.md-lufs-dot { position: absolute; top: 50%; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; border: 2px solid var(--surface); box-shadow: var(--shadow-xs); }
.md-lufs-dot.is-good { background: var(--good); } .md-lufs-dot.is-warn { background: var(--warn); } .md-lufs-dot.is-bad { background: var(--bad); }
.md-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-3) var(--space-4); margin: 0 0 var(--space-2); }
.md-stats div { display: grid; gap: 2px; }
.md-stats dt { font-size: .78rem; color: var(--muted); }
.md-stats dd { margin: 0; font-size: .92rem; font-weight: 600; }
.md-result { margin-top: var(--space-4); padding: var(--space-3); border-radius: var(--radius); background: var(--sunken); display: grid; gap: var(--space-2); }
.md-result audio, .md-editor audio { width: 100%; }
.md-result .md-row { margin-top: 0; }
.md-clips, .md-renders, .md-tracks, .md-panel { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-3); }
.md-clip { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: var(--space-4); padding: var(--space-3); border-radius: var(--radius); background: var(--surface-2); border: 1px solid var(--border); }
.md-clip.is-ready { border-color: var(--good-line); }
.md-clip.is-error { border-color: var(--bad-line); }
.md-clip-head { display: grid; gap: var(--space-1); }
.md-clip-head strong { font-family: var(--font-display); font-size: 1rem; line-height: 1.3; }
.md-tags { gap: var(--space-2); }
.md-hook { margin: var(--space-2) 0 0; color: var(--text-2); }
.md-excerpt { margin: var(--space-1) 0 var(--space-2); font-style: italic; }
.md-video { display: block; width: 100%; max-height: 520px; border-radius: var(--radius-sm); background: #000; }
.md-video.is-9x16 { aspect-ratio: 9 / 16; }
.md-video.is-1x1 { aspect-ratio: 1; }
.md-video.is-16x9 { aspect-ratio: 16 / 9; }
.md-video-ph { display: grid; place-items: center; align-content: center; gap: var(--space-1); width: 100%; aspect-ratio: 9 / 16; border-radius: var(--radius-sm); background: linear-gradient(160deg, var(--brand-deep), var(--brand)); color: var(--on-brand); font-size: .8rem; font-weight: 600; }
.md-video-ph.is-1x1 { aspect-ratio: 1; } .md-video-ph.is-16x9 { aspect-ratio: 16 / 9; }
.md-video-ph .icon { width: 22px; height: 22px; opacity: .85; }
.md-renders li { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: var(--space-4); align-items: start; }
.md-renders .md-video-ph { aspect-ratio: 16 / 9; }
.md-render-meta { display: grid; gap: var(--space-2); justify-items: start; }
.md-add { margin-top: var(--space-4); }
.md-add summary, .md-panel a { cursor: pointer; }
.md-add summary { display: inline-flex; align-items: center; gap: var(--space-2); font-weight: 600; font-size: .9rem; color: var(--link); }
.md-inline-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0 var(--space-3); align-items: end; margin-top: var(--space-3); }
.md-inline-form > .btn { margin-bottom: var(--space-4); justify-self: start; }
.md-ag-form { margin: var(--space-4) 0; }
.md-sizes { border: 0; padding: 0; margin: 0 0 var(--space-3); display: flex; gap: var(--space-2); flex-wrap: wrap; }
.md-sizes legend { font-size: .85rem; font-weight: 600; margin-bottom: var(--space-2); padding: 0; }
.md-size { position: relative; display: inline-flex; align-items: center; gap: var(--space-2); padding: var(--space-2) var(--space-3); border: 1px solid var(--border-strong); border-radius: var(--radius-sm); font-size: .85rem; cursor: pointer; background: var(--surface); }
.md-size input { position: absolute; opacity: 0; pointer-events: none; }
.md-size:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-deep); font-weight: 600; }
.md-size:has(input:focus-visible) { box-shadow: var(--focus); }
.md-size-shape { display: inline-block; border: 2px solid currentColor; border-radius: 3px; opacity: .7; }
.md-size-9x16 .md-size-shape { width: 10px; height: 17px; } .md-size-1x1 .md-size-shape { width: 14px; height: 14px; } .md-size-16x9 .md-size-shape { width: 19px; height: 11px; }
.md-tracks li { display: grid; grid-template-columns: minmax(0, 1fr) 110px 100px; gap: var(--space-3); align-items: end; padding-bottom: var(--space-3); border-bottom: 1px solid var(--border); }
.md-track-name { display: inline-flex; align-items: center; gap: var(--space-2); font-weight: 600; padding-bottom: 6px; }
.md-mini { display: grid; gap: 4px; font-size: .78rem; color: var(--muted); }
.md-mini input { width: 100%; }
.md-tracks + .field { margin-top: var(--space-3); }
.md-panel { gap: var(--space-2); margin-bottom: var(--space-3); }
.md-panel li { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; gap: var(--space-2); align-items: center; font-size: .9rem; }
.md-panel li > .icon { color: var(--muted); }
.md-panel-job { display: flex; justify-content: space-between; gap: var(--space-2); align-items: center; margin: 0 0 var(--space-2); }
.md-wave { position: relative; border-radius: var(--radius); background: var(--sunken); padding: var(--space-3); margin-bottom: var(--space-3); user-select: none; touch-action: none; }
.md-wave canvas { display: block; width: 100%; height: 96px; cursor: crosshair; }
.md-wave-sel { position: absolute; top: var(--space-3); bottom: var(--space-3); background: color-mix(in srgb, var(--brand-bright) 22%, transparent); border-left: 2px solid var(--brand); border-right: 2px solid var(--brand); border-radius: 3px; pointer-events: none; }
.md-wave-head { position: absolute; top: 6px; bottom: 6px; width: 2px; background: var(--brand-deep); pointer-events: none; }
.md-wave-note { margin: calc(-1 * var(--space-1)) 0 var(--space-4); }
.md-trim { display: grid; grid-template-columns: 1fr 1fr auto; gap: var(--space-3); align-items: start; }
.md-trim > .btn { margin-top: 26px; }
.md-words { max-height: 460px; overflow: auto; display: grid; gap: var(--space-2); font-size: .94rem; line-height: 1.55; }
.md-words p { margin: 0; padding: var(--space-2) var(--space-3); border-radius: var(--radius-sm); color: var(--text-2); }
.md-words p.in { background: var(--brand-soft); color: var(--text); }
.md-t { font: 600 .75rem var(--mono); color: var(--link); background: none; border: 0; padding: 0 var(--space-2) 0 0; cursor: pointer; }
.md-t:hover { text-decoration: underline; }
.md-editor input[type=range] { width: 100%; accent-color: var(--brand); }
@media (max-width: 640px) {
	.md-clip { grid-template-columns: 84px minmax(0, 1fr); gap: var(--space-3); }
	.md-renders li { grid-template-columns: 1fr; }
	.md-trim { grid-template-columns: 1fr 1fr; }
	.md-trim > .btn { grid-column: 1 / -1; margin-top: 0; }
	.md-tracks li { grid-template-columns: 1fr 1fr; }
	.md-track-name { grid-column: 1 / -1; padding-bottom: 0; }
	.md-bar { width: 88px; }
}
@media (prefers-reduced-motion: reduce) { .md-bar > span { transition: none; } }
.md-pair { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); }
.md-pair > .field { margin-bottom: var(--space-1); }
.md-pair-hint { margin-bottom: var(--space-4); }
.md-row form { display: inline-flex; margin: 0; }
.md-excerpt { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
@media (max-width: 640px) {
	.md-renders li > .md-video, .md-renders li > .md-video-ph { max-width: 220px; }
	.md-clip .md-hook { display: none; }
}
