/* Studio is an application workspace. The screener retains its independent page layout. */
body:has(#reportStudio) { overflow:hidden; }
body:has(#reportStudio) > .brand-nav, body:has(#reportStudio) .seo-breadcrumb,
body:has(#reportStudio) .global-page-actions, body:has(#reportStudio) > .app-footer,
body:has(#reportStudio) .studio-appbar, body:has(#reportStudio) #studioWorkbench { display:none!important; }
body:has(#reportStudio) > main { padding:0!important; }
#reportStudio { --rs-bg:var(--bs-body-bg,#f3f5f8); --rs-panel:var(--bs-tertiary-bg,#fff); --rs-line:var(--bs-border-color,#dce2ea); --rs-accent:#0ea5e9; height:100dvh; display:flex; flex-direction:column; color:var(--bs-body-color); font:13px/1.45 system-ui,sans-serif; background:var(--rs-bg); }
#reportStudio button,#reportStudio input,#reportStudio select,#reportStudio textarea { font:inherit; }
#reportStudio button { border:1px solid var(--rs-line); border-radius:6px; background:var(--rs-panel); color:inherit; padding:6px 10px; cursor:pointer; }
#reportStudio button:hover { border-color:var(--rs-accent); }
#reportStudio button:focus-visible,#reportStudio input:focus-visible,#reportStudio select:focus-visible,.rs-visual:focus-visible { outline:3px solid var(--rs-accent); outline-offset:2px; }
#reportStudio button:disabled { opacity:.4; cursor:default; }
#reportStudio button.primary { background:var(--rs-accent); border-color:var(--rs-accent); color:#031c29; font-weight:650; }
#reportStudio input,#reportStudio select,#reportStudio textarea { width:100%; border:1px solid var(--rs-line); border-radius:5px; padding:7px 8px; background:var(--rs-bg); color:inherit; }
.rs-header { display:flex; align-items:center; gap:14px; padding:10px 18px; border-bottom:1px solid var(--rs-line); min-height:62px; background:var(--rs-panel); }
.rs-brand { text-decoration:none; color:inherit; font-size:15px; font-weight:750; white-space:nowrap; }
.rs-brand i { color:var(--rs-accent); margin-right:7px; }
.rs-report-name { max-width:300px; border-color:transparent!important; font-size:15px!important; font-weight:650; }
.rs-status { color:var(--bs-secondary-color); font-size:11px; white-space:nowrap; }
.rs-header .rs-spacer { flex:1; }
.rs-toolbar { display:flex; gap:6px; align-items:center; padding:8px 18px; border-bottom:1px solid var(--rs-line); background:var(--rs-panel); flex-wrap:wrap; }
.rs-toolbar-divider { width:1px; height:23px; background:var(--rs-line); margin:0 6px; }
.rs-body { display:grid; grid-template-columns:240px minmax(0,1fr) 280px; min-height:0; flex:1; }
.rs-data,.rs-inspector { overflow:auto; background:var(--rs-panel); padding:16px; }
.rs-data { border-right:1px solid var(--rs-line); }
.rs-inspector { border-left:1px solid var(--rs-line); }
.rs-panel-title { font-weight:700; font-size:14px; margin:0 0 14px; }
.rs-muted { color:var(--bs-secondary-color); font-size:12px; }
.rs-data details { margin:12px 0; }
.rs-data summary { cursor:pointer; font-weight:650; padding:5px 0; }
.rs-data details details { margin:4px 0 4px 10px; }
.rs-data details details summary { font-size:11px; color:var(--bs-secondary-color); text-transform:uppercase; letter-spacing:.04em; }
#reportStudio .rs-field { display:block; width:100%; text-align:left; border:0; background:transparent; padding:5px 7px; margin:1px 0; }
.rs-field .rs-field-type { display:inline-block; width:22px; color:var(--rs-accent); font-family:monospace; }
.rs-canvas-area { min-width:0; min-height:0; display:flex; flex-direction:column; background:var(--bs-secondary-bg,#e8edf3); }
.rs-page-heading { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:10px 20px; }
.rs-reader-filters { display:flex; flex-wrap:wrap; gap:8px; padding:6px 20px; }
.rs-reader-filter { font-size:11px; max-width:200px; }
.rs-reader-filter span { display:block; margin-bottom:3px; }
.rs-page-viewport { overflow:auto; overflow-anchor:none; flex:1; min-height:0; padding:8px 24px 28px; }
.rs-page { position:relative; width:100%; min-width:576px; min-height:720px; background:var(--rs-bg); box-shadow:0 3px 20px #00000012; display:grid; grid-template-columns:repeat(12,minmax(0,1fr)); grid-auto-rows:48px; align-content:start; background-image:radial-gradient(var(--rs-line) 1px,transparent 1px); background-size:calc(100% / 12) 48px; }
.rs-visual { position:relative; margin:5px; border:1px solid var(--rs-line); border-radius:7px; background:var(--rs-panel); min-width:0; overflow:hidden; display:flex; flex-direction:column; }
.rs-visual.selected { border:2px solid var(--rs-accent); box-shadow:0 0 0 2px #0ea5e918; }
.rs-visual-header { padding:10px 13px 5px; font-weight:650; display:flex; gap:8px; cursor:grab; touch-action:none; }
.rs-visual-header span { flex:1; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.rs-visual-content { flex:1 0 54px; min-height:54px; overflow:auto; padding:8px 14px; }
.rs-visual-source { flex:0 1 auto; max-height:42px; overflow:auto; padding:4px 13px 8px; font-size:10px; line-height:1.3; color:var(--bs-secondary-color); }
.rs-evidence { margin-top:4px; padding-top:4px; border-top:1px solid var(--rs-line); }
.rs-resize { position:absolute; right:0; bottom:0; cursor:nwse-resize!important; padding:1px 4px!important; border:0!important; background:transparent!important; touch-action:none; }
.rs-kpi { font-size:clamp(26px,4vw,46px); font-weight:650; letter-spacing:-.04em; }
.rs-chart { width:100%; height:100%; min-height:90px; }
.rs-chart text { fill:currentColor; font-size:11px; }
.rs-table { width:100%; border-collapse:collapse; font-size:11px; white-space:nowrap; }
.rs-table th,.rs-table td { border-bottom:1px solid var(--rs-line); padding:7px 9px; text-align:left; }
.rs-table th { position:sticky; top:0; background:var(--rs-panel); }
.rs-pagination { display:flex; justify-content:space-between; align-items:center; gap:4px; margin-top:8px; }
.rs-empty { grid-column:1/-1; grid-row:2/12; display:flex; flex-direction:column; align-items:center; justify-content:center; text-align:center; padding:30px; }
.rs-empty-icon { font-size:40px; color:var(--rs-accent); margin-bottom:18px; }
.rs-empty h2 { font-size:24px; font-weight:650; }
.rs-empty p { max-width:360px; color:var(--bs-secondary-color); line-height:1.7; }
.rs-empty-actions { display:flex; flex-wrap:wrap; justify-content:center; gap:8px; margin-top:12px; }
.rs-pages { display:flex; gap:5px; align-items:center; padding:8px 14px; border-top:1px solid var(--rs-line); overflow:auto; background:var(--rs-panel); }
.rs-pages button[aria-selected=true] { color:var(--rs-accent)!important; border-bottom:2px solid var(--rs-accent)!important; }
.rs-inspector-tabs { display:flex; gap:4px; margin-bottom:18px; }
.rs-inspector-tabs button { flex:1; border:0!important; }
.rs-inspector-tabs button[aria-selected=true] { background:#0ea5e918!important; color:var(--rs-accent)!important; }
.rs-control { display:block; margin:12px 0; }
.rs-control > span { display:block; margin-bottom:5px; font-size:11px; font-weight:650; color:var(--bs-secondary-color); }
.rs-control-row { display:grid; grid-template-columns:1fr 1fr; gap:8px; }
.rs-filter { padding:9px; border:1px solid var(--rs-line); border-radius:6px; margin:8px 0; }
.rs-filter select,.rs-filter input { margin-bottom:5px; }
.rs-dialog { width:min(620px,94vw); max-height:88dvh; border:1px solid var(--rs-line); border-radius:12px; padding:22px; background:var(--bs-body-bg); color:var(--bs-body-color); }
.rs-dialog::backdrop { background:#0008; }
.rs-dialog[open] { position:fixed; top:5dvh; max-height:85dvh; overflow:auto; z-index:1040; box-shadow:0 15px 80px #0005; }
.rs-dialog .studio-filter-rail { width:100%; height:auto; max-height:none; overflow:visible; }
.rs-dialog .studio-data-panel { display:none!important; }
.rs-dialog-header { display:flex; justify-content:space-between; align-items:center; margin-bottom:16px; }
.rs-library-item { display:flex; gap:8px; justify-content:space-between; padding:10px 0; border-bottom:1px solid var(--rs-line); }
.rs-alert { padding:8px 18px; background:#f59e0b22; border-bottom:1px solid #f59e0b55; }
.rs-preview .rs-data,.rs-preview .rs-inspector { display:none; }
.rs-preview .rs-body { grid-template-columns:minmax(0,1fr); }
.rs-preview .rs-page { background-image:none; }
.rs-preview .rs-resize { display:none; }
.rs-text { white-space:pre-wrap; overflow-wrap:anywhere; }
.rs-print-pages { display:none; }
.rs-table-continuation { break-before:page; }
.rs-table-continuation tr { break-inside:avoid; }
.rs-table-continuation .rs-table { table-layout:fixed; white-space:normal; }
.rs-table-continuation th,.rs-table-continuation td { overflow-wrap:anywhere; }
@media(max-width:1100px) { .rs-body { grid-template-columns:190px minmax(0,1fr) 245px; } .rs-data,.rs-inspector { padding:12px; } .rs-page-viewport { padding:8px 12px 20px; } .rs-status { max-width:140px; white-space:normal; } }
@media(max-width:760px) { .rs-header { padding:8px; gap:6px; flex-wrap:wrap; } .rs-brand { font-size:13px; } .rs-report-name { max-width:170px; } .rs-toolbar { padding:6px; gap:4px; } .rs-toolbar button { padding:5px 7px!important; } .rs-body { display:flex; flex-direction:column; overflow:auto; } .rs-data { display:none; } .rs-data.mobile-open { display:block; flex:0 0 240px; } .rs-canvas-area { flex:1 0 440px; } .rs-inspector { flex:0 0 auto; max-height:360px; border-top:1px solid var(--rs-line); } .rs-page { min-width:576px; } .rs-page-viewport { padding:6px; } .rs-page-heading { padding:7px; } .rs-toolbar-divider { display:none; } .rs-preview .rs-canvas-area { flex:1; } }
@media print {
    html:has(#reportStudio),body:has(#reportStudio) { overflow:visible!important; background:#fff!important; color:#172033!important; }
    body:has(#reportStudio) .print-masthead { display:none!important; }
    #reportStudio { --rs-bg:#fff; --rs-panel:#fff; --rs-line:#cbd0d8; --bs-secondary-color:#555; height:auto; display:block; background:#fff!important; color:#172033!important; }
    #reportStudio > :not(.rs-print-pages) { display:none!important; }
    .rs-print-pages { display:block; }
    .rs-print-pages > section { break-after:page; }
    .rs-print-pages > section:last-child { break-after:auto; }
    .rs-print-page { break-inside:avoid; }
    .rs-print-pages h2 { font-size:18px; line-height:1.25; margin:0 0 6px; color:#172033!important; }
    .rs-print-pages h3 { font-size:14px; line-height:1.25; margin:0 0 8px; color:#172033!important; }
    .rs-print-pages p { font-size:10px; line-height:1.35; margin:0 0 7px; }
    .rs-print-page .rs-page { width:100%; min-width:0; min-height:0!important; background:#fff; color:#172033; box-shadow:none; background-image:none; grid-auto-rows:var(--rs-print-row,36px); }
    .rs-visual { break-inside:avoid; background:#fff; color:#172033; }
    .rs-visual-header { padding:5px 8px 2px; font-size:12px; }
    .rs-visual-content { flex:1 1 auto; min-height:0; padding:4px 8px; }
    .rs-visual-source { flex:0 0 auto; max-height:none; padding:2px 8px; font-size:8px; color:#555; }
    .rs-visual-source .rs-evidence { display:none; }
    .rs-kpi { font-size:28px; line-height:1.1; }
    .rs-chart { min-height:0; }
    .rs-print-pages .rs-table th { position:static; background:#fff; color:#172033; }
    .rs-print-page .rs-table th,.rs-print-page .rs-table td { padding:3px 6px; font-size:9px; line-height:1.2; }
    .rs-resize,.rs-pagination { display:none!important; }
    .rs-visual.selected { border:1px solid #aaa; box-shadow:none; }
    @page { size:A4 landscape; margin:10mm; }
}
.rs-template-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(230px,1fr)); gap:10px; margin:12px 0 18px; }
.rs-template-card { display:flex; flex-direction:column; gap:6px; padding:12px; border:1px solid var(--rs-line); border-radius:8px; background:var(--rs-panel); }
.rs-template-card h3 { font-size:14px; font-weight:650; margin:0; }
.rs-template-card h3 i { color:var(--rs-accent); margin-right:6px; }
.rs-template-card p { flex:1; margin:0; color:var(--bs-secondary-color); }
.rs-template-card button { align-self:flex-start; }
.rs-visual-content .rs-empty-actions { justify-content:flex-start; margin-top:4px; }
