/* Larger rail titles with a quiet line on the text's centre axis. */
.section-heading,.tv .section-heading{display:flex;align-items:center;gap:20px}
.section-heading h2,.tv .section-heading h2{font-size:27px;line-height:1.25;flex:0 1 auto;margin:0;min-width:0}
.section-heading::after{content:"";height:1px;flex:1;min-width:28px;background:linear-gradient(90deg,rgba(153,176,255,.38),rgba(123,148,223,.08))}
.brand-mark, .tv .sidebar-brand img.brand-mark{object-fit:contain;clip-path:none;background:none;filter:none;border-radius:8px;display:block}
.tv .sidebar-brand img.brand-mark{width:36px;height:36px;flex:0 0 36px}
.select-source{display:none!important}
.catalog-filters{align-items:center;gap:12px;padding:6px 0;margin:20px 0 28px}
.catalog-filters>label{display:block;flex:1 1 145px;font-size:14px;min-width:0}
.select-trigger,.catalog-filters .secondary{position:relative;display:inline-flex;align-items:center;justify-content:space-between;gap:14px;width:100%;min-height:48px;padding:12px 16px;border:1px solid rgba(144,165,237,.26);border-radius:14px;background:linear-gradient(145deg,rgba(30,43,87,.95),rgba(16,25,60,.96));color:#eef2ff;font-size:14px;font-weight:400;line-height:1.4;box-shadow:inset 0 1px rgba(205,219,255,.05);transition:border-color 160ms ease,box-shadow 160ms ease}
.select-trigger>span{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}
.select-trigger>svg{width:18px;height:18px;flex:0 0 18px;stroke:#aebeea;stroke-width:1.7;fill:none;stroke-linecap:round;stroke-linejoin:round}
.select-trigger:is(:focus-visible,:focus,:hover),.catalog-filters .secondary:is(:focus-visible,:focus,:hover){outline:2px solid #b9d0ff;outline-offset:1px;border-color:#779bff;box-shadow:0 0 12px rgba(65,105,255,.24);transform:none}
.catalog-filters .secondary{width:auto;flex:0 0 auto;justify-content:center;padding-inline:20px;font-family:var(--font-body);font-weight:400}
.catalog-filters .secondary::after{display:none}
:root[data-theme=dark] .catalog-filters .secondary{border-radius:14px}
@media(min-width:601px){.catalog-filters>label:last-of-type{flex-grow:1.3;flex-basis:185px}}
.setting-row .select-trigger{width:auto;min-width:180px;max-width:60%}
.choice-popup{position:fixed;inset:auto;margin:0;padding:8px;border:1px solid rgba(155,181,255,.4);border-radius:18px;background:linear-gradient(145deg,#18264c,#0b1532);color:#f3f5ff;box-shadow:0 18px 60px rgba(0,0,18,.65),0 0 18px rgba(65,105,255,.16);overflow:hidden;font-family:var(--font-body)}
.choice-popup::backdrop{background:rgba(0,4,20,.24)}
.choice-title{font-size:12px;color:#aabbe7;padding:8px 12px 12px}
.choice-options{max-height:min(290px,calc(100vh - 150px));overflow:auto;padding:3px;scrollbar-width:thin;scrollbar-color:#4c629c transparent}
.choice-option{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;min-height:46px;padding:11px 13px;text-align:left;border-radius:10px;border:1px solid transparent;background:transparent;color:#e5ebff;font-size:15px;font-weight:400}
.choice-option[aria-selected=true]{background:rgba(82,106,204,.18);color:#c8d9ff}
.choice-option:is(:focus,:focus-visible,:hover){outline:none;border-color:#afcaff;background:linear-gradient(110deg,rgba(114,76,255,.5),rgba(43,116,218,.44));box-shadow:inset 0 1px rgba(234,241,255,.12);color:#fff}
.choice-option>svg{width:19px;height:19px;flex:0 0 19px;fill:none;stroke:#b7ceff;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
@media(max-width:600px){.section-heading h2,.tv .section-heading h2{font-size:23px}.section-heading{gap:14px}.catalog-filters>label{flex-basis:calc(50% - 8px)}.catalog-filters .secondary{min-height:46px}.setting-row .select-trigger{min-width:140px}.choice-option{min-height:48px}}
@media(prefers-reduced-motion:reduce){.select-trigger{transition:none}}

/* Keep the final settings panel and its help text above the lower edge. */
body[data-screen=settings] main{padding-bottom:max(180px,65vh)}
body[data-screen=settings] .settings-group:last-of-type{margin-bottom:96px;scroll-margin-bottom:96px}
/* One idle contour above the poster and text, with no internal poster seam. */
.card:not(:focus):not(:focus-visible):not(.is-focused){box-shadow:0 8px 20px rgba(0,0,0,.16)}
.card:not(:focus):not(:focus-visible):not(.is-focused)::after{opacity:1;border:1px solid var(--card-edge);box-shadow:none}
.card .poster{box-shadow:none}
.card::after{transition:opacity 180ms ease-out,border-color 180ms ease-out,box-shadow 180ms ease-out}
