/* FlatcastX V3 - 30 October 2026. Precise contrast fixes over V1/V2.
   Never recolor user-designed theme stage, live-room canvas, avatars, radio
   icon gradients, broadcast audio controls or administration. */
html[data-fx-site-theme="dark"] .page {
 --fx3-bg:#14243a;--fx3-panel:#1c304a;--fx3-card:#28415e;
 --fx3-line:#52738f;--fx3-text:#eff7ff;--fx3-muted:#c5d8ed;
 --fx3-link:#9bdfff; color:var(--fx3-text)
}
/* Header images per selection; administrator overrides the defaults with CSS vars. */
.page .top-hero {background-image:var(--fx-v3-light-header,url('/assets/images/flatcastx_header.png'))!important;background-position:center!important;background-size:cover!important}
html[data-fx-site-theme="dark"] .page .top-hero {background-image:var(--fx-v3-dark-header,url('/assets/images/flatcastx_header_dark_v3.png'))!important}
/* Homepage headline: left-aligned inside content; no wasted empty indentation. */
.page .section-bar{display:flex!important;align-items:center!important;gap:9px!important;padding:6px 0 10px!important}
.page .section-header{flex:0 1 auto!important;margin:0!important;min-width:0!important;padding:3px 0 3px 10px!important;border-left:4px solid #35b8fb!important;line-height:1.2!important}
.page .lang-select-form{margin-left:auto!important;flex:0 0 auto!important}
/* Real homepage stream DOM is stream-side-cell / stream-count / stream-url.
   This selector comes after V2 to supersede :hover / old inline sheets. */
html[data-fx-site-theme="dark"] .page .stream-row,
html[data-fx-site-theme="dark"] .page .stream-row:hover,
html[data-fx-site-theme="dark"] .page .stream-row:focus-within{background:#28415d!important;border:1px solid #52738f!important;color:#edf6ff!important;box-shadow:0 2px 10px rgba(0,9,24,.22)!important}
html[data-fx-site-theme="dark"] .page .stream-row:hover,
html[data-fx-site-theme="dark"] .page .stream-row:focus-within{background:#314f6d!important;border-color:#82bee6!important}
html[data-fx-site-theme="dark"] .page .stream-side-cell,
html[data-fx-site-theme="dark"] .page .stream-side-cell:hover,
html[data-fx-site-theme="dark"] .page .stream-row:hover .stream-side-cell{
 background:transparent!important;border-right-color:#587995!important;filter:none!important;box-shadow:none!important}
html[data-fx-site-theme="dark"] .page .stream-count,
html[data-fx-site-theme="dark"] .page .stream-count small,
html[data-fx-site-theme="dark"] .page .stream-row:hover .stream-count,
html[data-fx-site-theme="dark"] .page .stream-row:hover .stream-count small{color:#f0f7ff!important;background:transparent!important;text-shadow:none!important}
html[data-fx-site-theme="dark"] .page .stream-row .room-icon,
html[data-fx-site-theme="dark"] .page .stream-row:hover .room-icon{filter:none!important;opacity:1!important;color:#fff!important}
html[data-fx-site-theme="dark"] .page .stream-info,
html[data-fx-site-theme="dark"] .page .stream-title{color:#eaf6ff!important}
html[data-fx-site-theme="dark"] .page .stream-desc{color:#d7e8f7!important}
html[data-fx-site-theme="dark"] .page .stream-url,
html[data-fx-site-theme="dark"] .page .stream-url .fx-sid-inline,
html[data-fx-site-theme="dark"] .page .stream-url .fx-sid-inline b,
html[data-fx-site-theme="dark"] .page .stream-url .fx-stream-web-passive,
html[data-fx-site-theme="dark"] .page .stream-row:hover .stream-url,
html[data-fx-site-theme="dark"] .page .stream-row:hover .fx-stream-web-passive{color:#ace3ff!important;opacity:1!important;text-shadow:none!important}
html[data-fx-site-theme="dark"] .page .stream-url .fx-separator{color:#cfdfed!important}
html[data-fx-site-theme="dark"] .page .fx-stream-web-passive{overflow-wrap:anywhere}
/* Broadcast takeover */
html[data-fx-site-theme="dark"] .page .fx-yayinal-panel,
html[data-fx-site-theme="dark"] .page .fx-yayinal-form{background:#1d324b!important;color:#eef7ff!important}
html[data-fx-site-theme="dark"] .page .fx-yayinal-note{background:#2d4b66!important;color:#e7f2ff!important;border-left-color:#45baff!important}
html[data-fx-site-theme="dark"] .page .fx-yayinal-row label{color:#d8edff!important}
html[data-fx-site-theme="dark"] .page .fx-yayinal-row input{background:#10243a!important;color:#f1f8ff!important;border:1px solid #7295b2!important}
html[data-fx-site-theme="dark"] .page .fx-yayinal-row input::placeholder{color:#b8d4e9!important}
html[data-fx-site-theme="dark"] .page .fx-yayinal-back{background:#2b4762!important;color:#f0f8ff!important}
/* News cards (AJAX) */
html[data-fx-site-theme="dark"] .page .fx-duyuru-page,
html[data-fx-site-theme="dark"] .page .fx-duyuru-list,
html[data-fx-site-theme="dark"] .page .fx-duyuru-item{background:#233a55!important;border-color:#557894!important;color:#ecf5ff!important}
html[data-fx-site-theme="dark"] .page .fx-duyuru-item .fx-duyuru-content,
html[data-fx-site-theme="dark"] .page .fx-duyuru-item .fx-duyuru-content :is(p,span,div,li,strong,b){color:#ebf5ff!important;opacity:1!important}
html[data-fx-site-theme="dark"] .page .fx-duyuru-item :is(.fx-duyuru-title,h2,h3){color:#cae9ff!important}
html[data-fx-site-theme="dark"] .page .fx-duyuru-item a{color:#9ce2ff!important}
/* Support panel and account/settings */
html[data-fx-site-theme="dark"] .page .fx-contact-wrap :is(.fx-card,.fx-card-body,.fx-info-line,.fx-member-required),
html[data-fx-site-theme="dark"] .page .fx-inline-settings-box{background:#223b55!important;color:#eaf5ff!important;border-color:#527592!important}
html[data-fx-site-theme="dark"] .page .fx-contact-wrap :is(label,.fx-label,p,.fx-info-line,.fx-info-line span,.fx-info-line a){color:#e2f1ff!important}
html[data-fx-site-theme="dark"] .page .fx-contact-wrap :is(input,textarea,select),
html[data-fx-site-theme="dark"] .page .fx-inline-settings-box :is(input,select,textarea){background:#10273f!important;color:#f1f9ff!important;border-color:#6a90ae!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list :is(label,.m-label,.cr-label){color:#c5e4ff!important}
/* Create radio and edit radio: preserve semantic icon tiles and button colors. */
html[data-fx-site-theme="dark"] .page #lobby-stream-list :is(.create-radio-card,.fx-cr-card,.fx-radio-create-box,.fx-inline-settings-box){background:#203750!important;color:#e9f4ff!important;border-color:#567995!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list :is(.create-radio-card,.fx-cr-card) :is(input:not([type="color"]),select,textarea){background:#122840!important;color:#eff8ff!important;border-color:#6b91ad!important}
/* My Radios screen, subviews and portals. */
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-my-radios-table :is(th,td),
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-my-radios-table :is(.fx-room-data-row,.fx-room-toolbar-row) td{background:#263e59!important;color:#eef7ff!important;border-color:#557894!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-my-radios-table th{background:#1a3b5c!important;color:#f8fbff!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-my-radios-table :is(a,b,span,small,.fx-my-radios-note,.fx-mini-muted){color:#dfefff!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-my-radios-table :is(.fx-sid-badge,.fx-web-link){color:#9edfff!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-my-radios-table :is(input,select,textarea){color:#f3f9ff!important;background:#12283f!important}
html[data-fx-site-theme="dark"] body .fx-radio-action-menu,
html[data-fx-site-theme="dark"] body .fx-radio-action-menu-portal{background:#203a56!important;color:#ebf6ff!important;border:1px solid #6a94b1!important}
html[data-fx-site-theme="dark"] body .fx-radio-action-menu .fx-radio-action-item{color:#eaf6ff!important;background:transparent!important}
html[data-fx-site-theme="dark"] body .fx-radio-action-menu .fx-radio-action-item:hover{background:#315778!important;color:#fff!important}
/* Portal modals from the lobby are not always descendants of .page. */
html[data-fx-site-theme="dark"] :is(.fx-res-card,.fx-rbl-card,.fx-rbl-head,.fx-rbl-list,.fx-rbl-foot,.fx-rbl-empty,.fx-room-roles-wrap){background:#223a56!important;color:#eaf5ff!important;border-color:#557894!important}
html[data-fx-site-theme="dark"] :is(.fx-res-card,.fx-rbl-card,.fx-room-roles-wrap) :is(h1,h2,h3,th,td,p,span,small,label){color:#e4f2ff!important}
html[data-fx-site-theme="dark"] :is(.fx-res-card,.fx-rbl-card,.fx-room-roles-wrap) :is(input:not([type="checkbox"]),select,textarea){background:#122941!important;color:#f3faff!important;border-color:#6a90b1!important}
html[data-fx-site-theme="dark"] .page #modalIframe .modal-content,
html[data-fx-site-theme="dark"] .page #iframe-loader-area > div,
html[data-fx-site-theme="dark"] .page #iframe-loader-area .iframe-box{background:#213b57!important;color:#eff8ff!important;border-color:#6787a2!important}
html[data-fx-site-theme="dark"] .page #iframe-loader-area :is(pre,code,textarea){background:#142c45!important;color:#eaf6ff!important}
html[data-fx-site-theme="dark"] .page #modalIframe .modal-content :is(b,p,span,strong,h3){color:#d4ecff!important}
/* Light editor chrome: only toolbar + side panels, not #stage artwork or theme elements. */
html[data-fx-site-theme="light"] body:has(#app>.topbar){background:#e9f2fa!important;color:#142f49!important}
html[data-fx-site-theme="light"] #app>.topbar{background:linear-gradient(180deg,#f6fbff,#d4e7f5)!important;color:#143b5b!important;border-bottom:1px solid #88b6d4!important}
html[data-fx-site-theme="light"] #app>.topbar .title{color:#133956!important}
html[data-fx-site-theme="light"] #app>.sidebar,
html[data-fx-site-theme="light"] #app>.props{background:#e3eef7!important;color:#173f5e!important}
html[data-fx-site-theme="light"] #app :is(.sidebar,.props) :is(.group,.panel){background:#f8fbff!important;color:#224762!important;border-color:#acc7da!important}
html[data-fx-site-theme="light"] #app :is(.sidebar,.props) :is(label,.hint,p,small){color:#294f6c!important}
html[data-fx-site-theme="light"] #app>.stage-wrap{background:#d7e4ef!important}
/* Modal color icon status buttons remain recognizable and are not globally overridden. */
/* V3 correction: live Radyo Listesi actually renders fx-admin-reference-table,
   fx-admin-reference-data and fx-admin-action-dropdown-menu (not my-radios-table). */
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-radio-table-panel,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-radio-toolbar,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table tbody.fx-admin-room-group{background:#1c3049!important;color:#eaf5ff!important;border-color:#526f8a!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table tr.fx-admin-reference-data td,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-admin-reference-tools td,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-room-toolbar-row td{background:#263d58!important;color:#e9f4ff!important;border-color:#54738f!important;box-shadow:none!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table th{background:#1b4465!important;color:#fff!important;border-color:#517593!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-room-name,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-room-name b,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-mini-muted,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-room-action-title span,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-pass-text{color:#e6f4ff!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-radio-table-panel .fx-my-radios-note{color:#c5dffa!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-sid-badge,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-web-link,
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-pass-toggle{background:#15314d!important;color:#b6e6ff!important;border:1px solid #688aa9!important;box-shadow:none!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-reference-table .fx-pass-toggle:hover{background:#214663!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-action-dropdown-menu,
html[data-fx-site-theme="dark"] body .fx-admin-action-dropdown-menu{background:#213850!important;border:1px solid #7191ab!important;box-shadow:0 14px 26px #05101cbb!important;color:#eaf6ff!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-action-dropdown-menu :is(a,button,span,b),
html[data-fx-site-theme="dark"] body .fx-admin-action-dropdown-menu :is(a,button,span,b){color:#ebf5ff!important}
html[data-fx-site-theme="dark"] .page #lobby-stream-list .fx-admin-action-dropdown-menu :is(a,button):hover,
html[data-fx-site-theme="dark"] body .fx-admin-action-dropdown-menu :is(a,button):hover{background:#305471!important}
/* Use source row hover with same semantic count/icon grounding. */
html[data-fx-site-theme="dark"] .page .stream-row:hover .stream-side-cell :is(.stream-count,.stream-count small){color:#f2f8ff!important;background:transparent!important}
/* Fixed browser UI hidden handling, even when old V1 widgets declare display:flex. */
#fx-appearance .fx-theme-switch[hidden],#fx-appearance .fx-reader-row[hidden],#fx-appearance .fx-reset[hidden]{display:none!important}

/* Admin can disable magnification without deleting a visitor's saved setting. */
html[data-fx-reader-enabled="0"] [data-fx-readable="1"]{font-size:var(--fx-base-font-size)!important}
#fx-appearance .fx-appearance-label[hidden]{display:none!important}
