/* ROGEAP Statistics — public dashboard styles
   Scoped under #rogeap-app to avoid clashing with the active theme. */

#rogeap-app {
	--rogeap-primary: #1b6ec2;
	--rogeap-dark: #0d3c61;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: #1d2327;
}

#rogeap-app .rogeap-header {
	border-bottom: 3px solid var(--rogeap-primary);
	padding-bottom: 10px;
	margin-bottom: 18px;
}

#rogeap-app .rogeap-title {
	margin: 0;
	font-size: 1.6rem;
	color: var(--rogeap-dark);
}

#rogeap-app .rogeap-subtitle {
	margin: 4px 0 0;
	color: #646970;
	font-size: .9rem;
}

/* Filters */
#rogeap-app .rogeap-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	align-items: flex-end;
	background: #f6f8fa;
	border: 1px solid #e2e4e7;
	border-radius: 8px;
	padding: 14px 16px;
	margin-bottom: 18px;
}

#rogeap-app .rogeap-filter {
	display: flex;
	flex-direction: column;
	min-width: 150px;
}

#rogeap-app .rogeap-filter label {
	font-size: .72rem;
	text-transform: uppercase;
	letter-spacing: .04em;
	color: #646970;
	margin-bottom: 4px;
}

#rogeap-app .rogeap-filter-actions {
	flex-direction: row;
	gap: 8px;
	margin-left: auto;
}

/* KPI cards */
#rogeap-app .rogeap-kpis {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 14px;
	margin-bottom: 20px;
}

#rogeap-app .rogeap-kpi {
	background: #fff;
	border: 1px solid #e2e4e7;
	border-top: 4px solid var(--rogeap-primary);
	border-radius: 8px;
	padding: 16px;
	text-align: center;
	box-shadow: 0 1px 3px rgba(0, 0, 0, .06);
}

#rogeap-app .rogeap-kpi-value {
	font-size: 1.9rem;
	font-weight: 700;
	color: var(--rogeap-dark);
}

#rogeap-app .rogeap-kpi-label {
	margin-top: 4px;
	font-size: .82rem;
	color: #646970;
}

/* Tabs */
#rogeap-app .rogeap-tabs {
	margin-bottom: 18px;
}

/* Grid layout — the 3 panels (map + 2 charts) sit on a single aligned row. */
#rogeap-app .rogeap-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 18px;
	margin-bottom: 18px;
	align-items: stretch;
}

#rogeap-app .rogeap-panel {
	position: relative;
	display: flex;
	flex-direction: column;
	background: #fff;
	border: 1px solid #e2e4e7;
	border-radius: 8px;
	padding: 16px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, .05);
	/* Grid items default to min-width:auto, which refuses to shrink below the
	   content's min-content size. A Chart.js canvas then blows its column out
	   (one panel became ~1160px while the map was crushed to ~130px, even
	   though the columns are repeat(3, 1fr)). min-width:0 lets the three 1fr
	   tracks stay equal and Chart.js resizes each canvas to its 1/3 column. */
	min-width: 0;
}

#rogeap-app .rogeap-panel-title {
	margin: 0 0 12px;
	padding-right: 34px; /* leave room for the enlarge button */
	font-size: 1rem;
	color: var(--rogeap-dark);
}

/* Enlarge button (corner of each panel) */
#rogeap-app .rogeap-enlarge {
	position: absolute;
	top: 12px;
	right: 12px;
	width: 30px;
	height: 30px;
	padding: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: #646970;
	background: #fff;
	border: 1px solid #e2e4e7;
	border-radius: 8px;
	cursor: pointer;
	z-index: 3;
	box-shadow: 0 1px 2px rgba(0, 0, 0, .06);
	transition: background .15s, color .15s, border-color .15s, transform .1s;
}

#rogeap-app .rogeap-enlarge:hover {
	background: var(--rogeap-primary);
	color: #fff;
	border-color: var(--rogeap-primary);
}

#rogeap-app .rogeap-enlarge:active {
	transform: scale(.94);
}

#rogeap-app .rogeap-enlarge .rogeap-ico {
	width: 16px;
	height: 16px;
}

/* Toggle which icon shows: expand normally, collapse while enlarged. */
#rogeap-app .rogeap-enlarge .rogeap-ico-collapse,
#rogeap-app .rogeap-panel.is-enlarged .rogeap-enlarge .rogeap-ico-expand {
	display: none;
}

#rogeap-app .rogeap-panel.is-enlarged .rogeap-enlarge .rogeap-ico-collapse {
	display: inline-block;
}

/* Shared SVG icon sizing (buttons). */
#rogeap-app .rogeap-ico {
	width: 15px;
	height: 15px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
	flex: 0 0 auto;
}

/* Action buttons (filter bar) */
#rogeap-app .rogeap-btn {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 7px 14px;
	font-size: .82rem;
	font-weight: 600;
	line-height: 1;
	color: #1d2327;
	background: #fff;
	border: 1px solid #cfd6dd;
	border-radius: 8px;
	cursor: pointer;
	box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
	transition: background .15s, color .15s, border-color .15s, box-shadow .15s, transform .1s;
}

#rogeap-app .rogeap-btn:hover {
	box-shadow: 0 2px 8px rgba(13, 60, 97, .16);
	transform: translateY(-1px);
}

#rogeap-app .rogeap-btn:active {
	transform: translateY(0);
}

#rogeap-app .rogeap-btn-ghost {
	color: #646970;
}

#rogeap-app .rogeap-btn-ghost:hover {
	color: var(--rogeap-dark);
	border-color: #9aa4ad;
}

#rogeap-app .rogeap-btn-neutral {
	color: #0d3c61;
	border-color: #bcd3e8;
	background: #eef5fb;
}

#rogeap-app .rogeap-btn-primary {
	color: #fff;
	background: var(--rogeap-primary);
	border-color: var(--rogeap-primary);
}

#rogeap-app .rogeap-btn-primary:hover {
	background: #155a9e;
	border-color: #155a9e;
}

#rogeap-app .rogeap-btn-success {
	color: #fff;
	background: #2bb673;
	border-color: #2bb673;
}

#rogeap-app .rogeap-btn-success:hover {
	background: #229460;
	border-color: #229460;
}

/* Chart canvas is sized by its wrapper (charts use maintainAspectRatio:false).
   overflow:hidden is a safety net: if Chart.js has not yet shrunk the canvas
   back after collapsing an enlarged panel, the oversized canvas is clipped to
   the wrapper instead of spilling over the rest of the page. */
#rogeap-app .rogeap-canvas-wrap {
	position: relative;
	flex: 1 1 auto;
	height: 300px;
	min-width: 0;
	min-height: 0;
	overflow: hidden;
}

/* Belt-and-braces: never let a Chart.js canvas push past its wrapper (which
   would re-inflate the grid column). Chart.js sets inline width/height, so the
   attribute drives the intrinsic size while these cap the rendered box. */
#rogeap-app .rogeap-canvas-wrap canvas {
	max-width: 100%;
}

#rogeap-app .rogeap-panel-title small {
	font-weight: 400;
	color: #8c8f94;
	font-size: .78rem;
}

#rogeap-app .rogeap-map {
	flex: 1 1 auto;
	height: 300px;
	border-radius: 6px;
	z-index: 0;
}

#rogeap-app .rogeap-hint,
#rogeap-app .rogeap-footer {
	color: #8c8f94;
	font-size: .78rem;
	margin-top: 8px;
}

#rogeap-app .rogeap-loading {
	padding: 10px 0;
	color: var(--rogeap-primary);
	font-size: .9rem;
}

#rogeap-app .rogeap-panel-table {
	overflow-x: auto;
}

/* Backdrop behind an enlarged panel. */
#rogeap-app .rogeap-backdrop {
	position: fixed;
	inset: 0;
	z-index: 99998;
	background: rgba(13, 60, 97, .55);
}

#rogeap-app .rogeap-backdrop[hidden] {
	display: none;
}

/* Prevent the page from scrolling behind an enlarged panel. */
body.rogeap-modal-open {
	overflow: hidden;
}

/* A panel blown up in place: fixed, centred, near-fullscreen. The enlarge
   button stays visible and toggles back to collapse. */
#rogeap-app .rogeap-panel.is-enlarged {
	position: fixed;
	inset: 4vh 4vw;
	z-index: 99999;
	margin: 0;
	width: auto;
	height: auto;
	overflow: hidden;
	box-shadow: 0 16px 56px rgba(0, 0, 0, .4);
	animation: rogeap-pop .16s ease-out;
}

@keyframes rogeap-pop {
	from { transform: scale(.97); opacity: .6; }
	to   { transform: scale(1); opacity: 1; }
}

/* Chart/map fill the enlarged panel (flexbox computes the height). */
#rogeap-app .rogeap-panel.is-enlarged .rogeap-canvas-wrap,
#rogeap-app .rogeap-panel.is-enlarged .rogeap-map {
	height: auto;
	min-height: 0;
	flex: 1 1 auto;
}

/* Responsive */
@media (max-width: 960px) {
	#rogeap-app .rogeap-grid {
		grid-template-columns: 1fr;
	}
}

/* ======================================================================
   View switch (Dashboards | Build your own analysis)
   ====================================================================== */

#rogeap-app .rogeap-views {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 0 0 18px;
	border-bottom: 1px solid #e2e4e7;
}

#rogeap-app .rogeap-view-tab {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-bottom: -1px;
	padding: 10px 16px;
	font-size: .92rem;
	font-weight: 600;
	color: #646970;
	background: transparent;
	border: 1px solid transparent;
	border-bottom: 3px solid transparent;
	border-radius: 8px 8px 0 0;
	cursor: pointer;
}

#rogeap-app .rogeap-view-tab:hover {
	color: var(--rogeap-dark);
	background: #f6f8fa;
}

#rogeap-app .rogeap-view-tab[aria-selected="true"] {
	color: var(--rogeap-dark);
	background: #fff;
	border-color: #e2e4e7 #e2e4e7 transparent;
	border-bottom: 3px solid var(--rogeap-primary);
}

#rogeap-app .rogeap-view-tab .rogeap-ico {
	width: 18px;
	height: 18px;
}

#rogeap-app .rogeap-new {
	font-style: normal;
	font-size: .66rem;
	text-transform: uppercase;
	letter-spacing: .05em;
	padding: 2px 6px;
	border-radius: 10px;
	color: #fff;
	background: #2bb673;
}

#rogeap-app .rogeap-view[hidden] {
	display: none;
}

/* ======================================================================
   Analysis explorer
   ====================================================================== */

#rogeap-app .rx {
	/* Layout follows the width the theme gives the shortcode, not the viewport. */
	container-type: inline-size;
	--rx-border: #e2e4e7;
	--rx-muted: #646970;
	--rx-soft: #f6f8fa;
	--rx-accent-soft: #eaf2fb;
}

#rogeap-app .rx [hidden] {
	display: none !important;
}

#rogeap-app .rx-intro p {
	margin: 0 0 14px;
	color: var(--rx-muted);
	font-size: .92rem;
	max-width: 70ch;
}

#rogeap-app .rx-muted {
	color: var(--rx-muted);
	font-size: .82rem;
}

#rogeap-app .rx-label {
	display: block;
	margin-bottom: 4px;
	font-size: .7rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .04em;
	color: var(--rx-muted);
}

#rogeap-app .rx-input {
	width: 100%;
	min-width: 0;
	padding: 6px 9px;
	font-size: .85rem;
	color: #1d2327;
	background: #fff;
	border: 1px solid #cfd6dd;
	border-radius: 6px;
}

#rogeap-app .rx-input:focus,
#rogeap-app .rx button:focus-visible,
#rogeap-app .rx summary:focus-visible {
	outline: 2px solid var(--rogeap-primary);
	outline-offset: 1px;
}

/* Quick-start presets */
#rogeap-app .rx-presets-wrap {
	margin-bottom: 16px;
}

#rogeap-app .rx-presets {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
	gap: 10px;
}

#rogeap-app .rx-preset {
	display: flex;
	flex-direction: column;
	gap: 3px;
	min-width: 0;
	padding: 10px 12px;
	text-align: left;
	background: #fff;
	border: 1px solid var(--rx-border);
	border-left: 4px solid var(--rogeap-primary);
	border-radius: 8px;
	cursor: pointer;
	transition: box-shadow .15s, transform .1s;
}

#rogeap-app .rx-preset:nth-child(2) { border-left-color: #2bb673; }
#rogeap-app .rx-preset:nth-child(3) { border-left-color: #e8618c; }
#rogeap-app .rx-preset:nth-child(4) { border-left-color: #f5a623; }
#rogeap-app .rx-preset:nth-child(5) { border-left-color: #7b4fa3; }

#rogeap-app .rx-preset:hover {
	box-shadow: 0 3px 12px rgba(13, 60, 97, .14);
	transform: translateY(-1px);
}

#rogeap-app .rx-preset-title {
	font-weight: 700;
	font-size: .88rem;
	color: var(--rogeap-dark);
}

#rogeap-app .rx-preset-desc {
	font-size: .76rem;
	color: var(--rx-muted);
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* Two-column layout: builder | result */
#rogeap-app .rx-layout {
	display: grid;
	grid-template-columns: minmax(270px, 320px) minmax(0, 1fr);
	gap: 18px;
	align-items: start;
}

#rogeap-app .rx-builder {
	position: sticky;
	top: 12px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	max-height: calc(100vh - 24px);
	overflow-y: auto;
	padding-right: 2px;
}

#rogeap-app .rx-step {
	background: #fff;
	border: 1px solid var(--rx-border);
	border-radius: 8px;
	padding: 12px 14px;
}

#rogeap-app .rx-step-title {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 10px;
	font-size: .9rem;
	color: var(--rogeap-dark);
}

#rogeap-app .rx-num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	font-size: .75rem;
	color: #fff;
	background: var(--rogeap-primary);
	border-radius: 50%;
	flex: 0 0 auto;
}

#rogeap-app .rx-count {
	margin-left: auto;
	font-size: .72rem;
	font-weight: 600;
	color: var(--rx-muted);
	background: var(--rx-soft);
	border-radius: 10px;
	padding: 1px 7px;
}

/* Selected indicator chips */
#rogeap-app .rx-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 5px;
	margin-bottom: 8px;
}

#rogeap-app .rx-chip {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	max-width: 100%;
	padding: 3px 4px 3px 9px;
	font-size: .76rem;
	line-height: 1.3;
	color: #1d2327;
	background: var(--rx-accent-soft);
	border-left: 3px solid var(--rx-chip, var(--rogeap-primary));
	border-radius: 5px;
}

#rogeap-app .rx-chip button {
	width: 18px;
	height: 18px;
	padding: 0;
	font-size: 14px;
	line-height: 1;
	color: var(--rx-muted);
	background: transparent;
	border: 0;
	border-radius: 50%;
	cursor: pointer;
}

#rogeap-app .rx-chip button:hover {
	color: #fff;
	background: #d0021b;
}

#rogeap-app .rx-search-row {
	display: flex;
	gap: 8px;
	align-items: center;
	margin-bottom: 8px;
}

#rogeap-app .rx-link {
	padding: 0;
	font-size: .78rem;
	color: var(--rogeap-primary);
	background: none;
	border: 0;
	cursor: pointer;
	white-space: nowrap;
}

/* Indicator catalogue */
#rogeap-app .rx-ind-list {
	max-height: 340px;
	overflow-y: auto;
	border: 1px solid var(--rx-border);
	border-radius: 6px;
}

#rogeap-app .rx-theme > summary {
	position: sticky;
	top: 0;
	z-index: 1;
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 7px 10px;
	font-size: .8rem;
	font-weight: 700;
	color: var(--rogeap-dark);
	background: var(--rx-soft);
	border-bottom: 1px solid var(--rx-border);
	cursor: pointer;
	list-style: none;
}

#rogeap-app .rx-theme > summary::-webkit-details-marker { display: none; }

#rogeap-app .rx-theme > summary .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	color: var(--rogeap-primary);
}

#rogeap-app .rx-theme ul {
	margin: 0;
	padding: 2px 0;
	list-style: none;
}

#rogeap-app .rx-theme li {
	display: flex;
	align-items: center;
	gap: 4px;
	margin: 0;
	padding: 3px 8px 3px 10px;
}

#rogeap-app .rx-theme li:hover {
	background: #fafbfc;
}

#rogeap-app .rx-theme li label {
	display: flex;
	align-items: flex-start;
	gap: 6px;
	flex: 1 1 auto;
	min-width: 0;
	margin: 0;
	font-size: .8rem;
	line-height: 1.35;
	cursor: pointer;
}

#rogeap-app .rx-theme li input {
	margin-top: 2px;
	flex: 0 0 auto;
}

#rogeap-app .rx-theme li.is-disabled label {
	color: #a7aaad;
	cursor: not-allowed;
}

#rogeap-app .rx-badges {
	display: inline-flex;
	gap: 3px;
	flex: 0 0 auto;
}

#rogeap-app .rx-badge {
	font-size: .62rem;
	font-weight: 600;
	padding: 1px 4px;
	color: var(--rx-muted);
	background: #eef0f2;
	border-radius: 3px;
}

#rogeap-app .rx-badge-calc { color: #0d3c61; background: #dbe9f7; }
#rogeap-app .rx-badge-women { color: #9b2c5a; background: #fbe3ee; }

#rogeap-app .rx-info {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 15px;
	height: 15px;
	font-size: .62rem;
	font-weight: 700;
	font-style: italic;
	color: var(--rogeap-primary);
	border: 1px solid currentColor;
	border-radius: 50%;
	cursor: help;
	flex: 0 0 auto;
}

/* Segmented buttons */
#rogeap-app .rx-seg {
	display: flex;
	padding: 2px;
	background: var(--rx-soft);
	border: 1px solid var(--rx-border);
	border-radius: 7px;
}

#rogeap-app .rx-seg button {
	flex: 1 1 0;
	min-width: 0;
	padding: 6px 4px;
	font-size: .78rem;
	font-weight: 600;
	color: var(--rx-muted);
	background: transparent;
	border: 0;
	border-radius: 5px;
	cursor: pointer;
}

#rogeap-app .rx-seg button.is-active {
	color: #fff;
	background: var(--rogeap-primary);
	box-shadow: 0 1px 2px rgba(0, 0, 0, .15);
}

#rogeap-app .rx-seg button:disabled {
	opacity: .45;
	cursor: not-allowed;
}

#rogeap-app .rx-field {
	display: block;
	min-width: 0;
	margin-bottom: 10px;
}

#rogeap-app .rx-field:last-child {
	margin-bottom: 0;
}

/* Countries dropdown */
#rogeap-app .rx-dd > summary {
	padding: 6px 28px 6px 9px;
	font-size: .85rem;
	background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='%23646970' stroke-width='2' d='M2 5l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 9px center / 11px;
	border: 1px solid #cfd6dd;
	border-radius: 6px;
	cursor: pointer;
	list-style: none;
}

#rogeap-app .rx-dd > summary::-webkit-details-marker { display: none; }

#rogeap-app .rx-dd-panel {
	margin-top: 6px;
	padding: 8px;
	background: #fff;
	border: 1px solid var(--rx-border);
	border-radius: 6px;
}

#rogeap-app .rx-checklist {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 2px 8px;
	margin-top: 8px;
}

#rogeap-app .rx-checklist label {
	display: flex;
	align-items: center;
	gap: 5px;
	margin: 0;
	font-size: .78rem;
	cursor: pointer;
}

#rogeap-app .rx-chip-row {
	display: flex;
	flex-wrap: wrap;
	gap: 5px;
}

#rogeap-app .rx-chip-toggle {
	padding: 4px 10px;
	font-size: .78rem;
	font-weight: 600;
	color: #1d2327;
	background: #fff;
	border: 1px solid #cfd6dd;
	border-radius: 14px;
	cursor: pointer;
}

#rogeap-app .rx-chip-toggle[aria-pressed="true"] {
	color: #fff;
	background: var(--rogeap-primary);
	border-color: var(--rogeap-primary);
}

/* Axis / series */
#rogeap-app .rx-axis-row {
	display: flex;
	align-items: flex-end;
	gap: 6px;
	margin-bottom: 10px;
}

#rogeap-app .rx-axis-row .rx-field {
	flex: 1 1 0;
	margin-bottom: 0;
}

#rogeap-app .rx-swap {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0;
	color: var(--rogeap-primary);
	background: #fff;
	border: 1px solid #cfd6dd;
	border-radius: 6px;
	cursor: pointer;
	flex: 0 0 auto;
}

#rogeap-app .rx-swap .rogeap-ico {
	transform: rotate(90deg);
}

#rogeap-app .rx-swap:disabled {
	opacity: .4;
	cursor: not-allowed;
}

#rogeap-app .rx-check {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 4px 0 0;
	font-size: .82rem;
	cursor: pointer;
}

/* Chart type gallery */
#rogeap-app .rx-types {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(84px, 1fr));
	gap: 6px;
	margin-bottom: 12px;
	padding-top: 6px;
}

#rogeap-app .rx-type {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 4px;
	min-width: 0;
	padding: 9px 4px 7px;
	font-size: .72rem;
	font-weight: 600;
	color: #3c434a;
	background: #fff;
	border: 1px solid var(--rx-border);
	border-radius: 8px;
	cursor: pointer;
	transition: border-color .15s, box-shadow .15s;
}

#rogeap-app .rx-type svg {
	width: 26px;
	height: 26px;
	fill: currentColor;
	stroke: currentColor;
	stroke-width: 1.6;
	stroke-linejoin: round;
	color: var(--rogeap-primary);
}

#rogeap-app .rx-type span {
	max-width: 100%;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

#rogeap-app .rx-type:hover:not(:disabled) {
	border-color: var(--rogeap-primary);
	box-shadow: 0 2px 8px rgba(13, 60, 97, .12);
}

#rogeap-app .rx-type.is-active {
	color: #fff;
	background: var(--rogeap-primary);
	border-color: var(--rogeap-primary);
}

#rogeap-app .rx-type.is-active svg {
	color: #fff;
}

#rogeap-app .rx-type:disabled {
	opacity: .38;
	cursor: not-allowed;
}

#rogeap-app .rx-rec {
	position: absolute;
	top: -7px;
	right: -3px;
	padding: 1px 5px;
	font-size: .58rem;
	font-style: normal;
	font-weight: 700;
	color: #fff;
	background: #2bb673;
	border-radius: 8px;
	box-shadow: 0 1px 2px rgba(0, 0, 0, .15);
}

/* Stage */
#rogeap-app .rx-stage {
	margin-bottom: 18px;
}

#rogeap-app .rx-stage.is-busy .rx-surface {
	opacity: .5;
	transition: opacity .2s;
}

#rogeap-app .rx-stage-head {
	padding-right: 40px;
}

#rogeap-app .rx-title {
	width: 100%;
	padding: 2px 0;
	font-size: 1.15rem;
	font-weight: 700;
	color: var(--rogeap-dark);
	background: transparent;
	border: 0;
	border-bottom: 1px dashed transparent;
}

#rogeap-app .rx-title::placeholder {
	color: var(--rogeap-dark);
	opacity: 1;
}

#rogeap-app .rx-title:hover,
#rogeap-app .rx-title:focus {
	border-bottom-color: #cfd6dd;
	outline: none;
}

#rogeap-app .rx-subtitle {
	margin: 2px 0 10px;
	font-size: .8rem;
	color: var(--rx-muted);
}

#rogeap-app .rx-toolbar {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin-bottom: 10px;
}

#rogeap-app .rx-toolbar .rogeap-btn {
	padding: 6px 10px;
}

#rogeap-app .rx-toolbar .rogeap-btn:disabled {
	opacity: .45;
	cursor: not-allowed;
	transform: none;
	box-shadow: none;
}

#rogeap-app .rx-toolbar-sep {
	flex: 1 1 auto;
}

#rogeap-app .rx-inline-box {
	margin-bottom: 10px;
	padding: 10px 12px;
	font-size: .82rem;
	background: var(--rx-soft);
	border: 1px solid var(--rx-border);
	border-radius: 6px;
}

#rogeap-app .rx-inline-box form {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
}

#rogeap-app .rx-inline-box label {
	display: block;
	flex: 1 1 100%;
	margin: 0;
	font-weight: 600;
}

#rogeap-app .rx-inline-box .rx-input {
	flex: 1 1 220px;
	width: auto;
	margin: 4px 8px 4px 0;
}

#rogeap-app .rx-flash {
	margin-bottom: 8px;
	padding: 7px 12px;
	font-size: .82rem;
	color: #0d3c61;
	background: #e7f3ec;
	border-left: 3px solid #2bb673;
	border-radius: 4px;
}

#rogeap-app .rx-notes {
	margin-bottom: 8px;
	padding: 7px 12px;
	font-size: .8rem;
	color: #6b4e00;
	background: #fff8e5;
	border-left: 3px solid #f5a623;
	border-radius: 4px;
}

#rogeap-app .rx-notes p {
	margin: 2px 0;
}

#rogeap-app .rx-surface {
	position: relative;
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	min-height: 0;
}

#rogeap-app .rx-canvas-wrap {
	height: 440px;
}

#rogeap-app .rx-map {
	height: 440px;
	border-radius: 6px;
	z-index: 0;
}

#rogeap-app .rx-stage-table {
	max-height: 440px;
	overflow: auto;
}

#rogeap-app .rx-message {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 260px;
	padding: 24px;
	text-align: center;
	font-size: .92rem;
	color: var(--rx-muted);
	background: repeating-linear-gradient(45deg, #fafbfc, #fafbfc 10px, #f4f6f8 10px, #f4f6f8 20px);
	border-radius: 6px;
}

#rogeap-app .rx-message-error {
	color: #8a1f11;
}

/* Enlarged stage: the chart fills the panel. */
#rogeap-app .rx-stage.is-enlarged .rx-canvas-wrap,
#rogeap-app .rx-stage.is-enlarged .rx-map,
#rogeap-app .rx-stage.is-enlarged .rx-stage-table {
	flex: 1 1 auto;
	height: auto;
	max-height: none;
	min-height: 0;
}

/* Data table + saved analyses */
#rogeap-app .rx-bottom {
	display: grid;
	grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
	gap: 18px;
}

#rogeap-app .rx-table-wrap {
	max-height: 380px;
	overflow: auto;
}

#rogeap-app .rx-table {
	width: 100%;
	border-collapse: collapse;
	font-size: .8rem;
	font-variant-numeric: tabular-nums;
}

#rogeap-app .rx-table th,
#rogeap-app .rx-table td {
	padding: 6px 10px;
	border-bottom: 1px solid #eef0f2;
	text-align: right;
	white-space: nowrap;
}

#rogeap-app .rx-table th[scope="row"],
#rogeap-app .rx-table thead th:first-child {
	text-align: left;
	white-space: normal;
	min-width: 140px;
}

#rogeap-app .rx-table thead th {
	position: sticky;
	top: 0;
	font-size: .72rem;
	color: var(--rx-muted);
	background: var(--rx-soft);
	white-space: normal;
}

#rogeap-app .rx-table tbody tr:hover {
	background: #fafbfc;
}

#rogeap-app .rx-table .rx-total {
	font-weight: 700;
}

#rogeap-app .rx-saved-list {
	margin: 0;
	padding: 0;
	list-style: none;
}

#rogeap-app .rx-saved-list li {
	display: flex;
	align-items: stretch;
	gap: 4px;
	margin: 0 0 6px;
}

#rogeap-app .rx-saved-load {
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	min-width: 0;
	padding: 7px 10px;
	text-align: left;
	background: var(--rx-soft);
	border: 1px solid var(--rx-border);
	border-radius: 6px;
	cursor: pointer;
}

#rogeap-app .rx-saved-load strong {
	font-size: .82rem;
	color: var(--rogeap-dark);
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

#rogeap-app .rx-saved-load span {
	font-size: .7rem;
	color: var(--rx-muted);
}

#rogeap-app .rx-saved-load:hover {
	border-color: var(--rogeap-primary);
}

#rogeap-app .rx-saved-del {
	width: 30px;
	padding: 0;
	font-size: 16px;
	color: var(--rx-muted);
	background: #fff;
	border: 1px solid var(--rx-border);
	border-radius: 6px;
	cursor: pointer;
}

#rogeap-app .rx-saved-del:hover {
	color: #fff;
	background: #d0021b;
	border-color: #d0021b;
}

@media (max-width: 1100px) {
	#rogeap-app .rx-bottom {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 900px) {
	#rogeap-app .rx-layout {
		grid-template-columns: 1fr;
	}

	#rogeap-app .rx-builder {
		position: static;
		max-height: none;
		overflow: visible;
	}

	#rogeap-app .rx-canvas-wrap,
	#rogeap-app .rx-map {
		height: 340px;
	}
}

/* Same breakpoints driven by the explorer's own width (narrow theme columns). */
@container (max-width: 1000px) {
	#rogeap-app .rx-bottom {
		grid-template-columns: 1fr;
	}
}

@container (max-width: 820px) {
	#rogeap-app .rx-layout {
		grid-template-columns: 1fr;
	}

	#rogeap-app .rx-builder {
		position: static;
		max-height: none;
		overflow: visible;
	}

	#rogeap-app .rx-canvas-wrap,
	#rogeap-app .rx-map {
		height: 360px;
	}
}

/* Publication notices (v3.1.0) */
#rogeap-app .rogeap-notice {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	border-radius: 8px;
	padding: 10px 14px;
	margin-bottom: 16px;
	font-size: .9rem;
	line-height: 1.45;
}

#rogeap-app .rogeap-notice .rogeap-ico {
	flex: 0 0 auto;
	margin-top: 2px;
}

#rogeap-app .rogeap-notice-data {
	background: #fff8e5;
	border: 1px solid #f0c33c;
	border-left-width: 4px;
	color: #614a00;
}

#rogeap-app .rogeap-notice-private {
	display: block;
	background: #f0f6fc;
	border: 1px dashed #72aee6;
	color: #0a4b78;
}

.rogeap-private-placeholder {
	border: 1px solid #e2e4e7;
	border-radius: 8px;
	background: #f6f8fa;
	padding: 28px 20px;
	text-align: center;
	color: #3c434a;
	font-size: 1rem;
}

.rogeap-private-placeholder p {
	margin: 0;
}
