/* Advisors (web/js/ext/advisors): docked exploration dashboards. Loaded by the extension itself. */

.app-dock.adv-dock { padding: 0; scrollbar-width: thin; scrollbar-color: rgba(201,164,92,.45) transparent; }
/* Smaller desktops: a narrower dashboard so the whole country still fits beside it. */
@media (min-width: 701px) and (max-width: 1199px) { .app-dock.adv-dock { width: clamp(340px, 38vw, 460px); } }
.adv-root { --adv: #c9a45c; min-height: 100%; font-size: 13px; line-height: 1.45; }
.adv-root .sub { color: var(--ink-dim); font-size: 11px; font-weight: normal; }
.adv-grip { display: none; }

/* ---------- header: council button, advisor tabs, close ---------- */
.adv-head {
  position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 6px; padding: 7px 10px 7px 10px;
  background: linear-gradient(180deg, #1f2e3f, #16222f); border-bottom: 1px solid var(--line);
  box-shadow: 0 3px 8px rgba(0,0,0,.35);
}
.adv-council-btn {
  display: inline-flex; align-items: center; gap: 5px; flex: none; padding: 4px 8px; cursor: pointer; border-radius: 4px;
  background: rgba(0,0,0,.25); border: 1px solid rgba(201,164,92,.45); color: var(--ink-dim); font-family: var(--serif); font-size: 12px;
}
.adv-council-btn:hover, .adv-council-btn[aria-pressed="true"] { color: var(--gold-bright); border-color: var(--gold); }
.adv-tabs { display: flex; gap: 3px; flex: 1; min-width: 0; overflow-x: auto; scrollbar-width: none; padding: 2px; }
.adv-tabs::-webkit-scrollbar { display: none; }
.adv-tabs button {
  flex: none; padding: 0; width: 34px; height: 34px; border-radius: 50%; border: none; background: none; cursor: pointer;
  display: grid; place-items: center; opacity: .62; filter: saturate(.6); transition: opacity .15s, transform .15s, filter .15s;
}
.adv-tabs button:hover { opacity: 1; filter: none; transform: translateY(-1px); }
.adv-tabs button[aria-selected="true"] { opacity: 1; filter: none; box-shadow: 0 0 0 2px var(--adv), 0 0 10px var(--adv); }
.adv-head .adv-close { flex: none; }

/* ---------- title ---------- */
.adv-title {
  display: flex; gap: 14px; align-items: center; padding: 16px 16px 14px;
  background: radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--adv) 30%, transparent), transparent 62%);
  border-bottom: 1px solid rgba(201,164,92,.3);
}
.adv-title .adv-emblem { flex: none; filter: drop-shadow(0 3px 6px rgba(0,0,0,.6)); }
.adv-kind { font-size: 10px; letter-spacing: .22em; text-transform: uppercase; color: var(--adv); filter: brightness(1.25); }
.adv-title h2 { margin: 1px 0 3px; font-family: var(--serif); font-weight: normal; font-size: 23px; letter-spacing: .06em; text-transform: uppercase; color: var(--gold-bright); line-height: 1.15; }
.adv-title p { margin: 0; color: var(--ink-dim); font-size: 12.5px; }
.adv-title.council { padding-bottom: 10px; }

.adv-council { display: grid; grid-template-columns: 1fr; gap: 8px; padding: 12px 14px; }
.adv-card {
  display: flex; gap: 12px; align-items: center; text-align: left; cursor: pointer; padding: 9px 12px; border-radius: 6px;
  background: linear-gradient(90deg, color-mix(in srgb, var(--adv) 16%, rgba(0,0,0,.25)), rgba(0,0,0,.18));
  border: 1px solid rgba(201,164,92,.3); color: var(--ink); transition: border-color .15s, transform .15s;
}
.adv-card:hover, .adv-card:focus-visible { border-color: var(--adv); transform: translateX(2px); }
.adv-card .t { display: flex; flex-direction: column; min-width: 0; }
.adv-card .r { font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-dim); }
.adv-card b { font-family: var(--serif); font-weight: normal; font-size: 17px; color: var(--gold-bright); letter-spacing: .03em; }
.adv-card .d { font-size: 12px; color: var(--ink-dim); }

/* ---------- body and sections ---------- */
.adv-body { padding: 4px 0 18px; }
.adv-loading { padding: 28px 16px; color: var(--ink-dim); font-family: var(--serif); font-style: italic; text-align: center; }
.adv-sec { padding: 14px 16px 12px; border-bottom: 1px solid rgba(201,164,92,.18); }
.adv-sec h3 { margin: 0 0 4px; font-family: var(--serif); font-weight: normal; font-size: 16px; color: var(--gold-bright); letter-spacing: .04em; }
.adv-sec details > summary { cursor: pointer; list-style: none; }
.adv-sec details > summary h3 { display: inline; }
.adv-kicker { font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: var(--adv); filter: brightness(1.2); margin-bottom: 1px; }
.adv-note { margin: 0 0 8px; color: var(--ink-dim); font-size: 12px; }
.adv-note b { color: var(--ink); }
.adv-note.pad, .adv-empty.pad { padding: 10px 16px; }
.adv-empty { color: var(--ink-dim); font-size: 12px; margin: 4px 0; }
.adv-h4 { margin: 10px 0 4px; font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-dim); font-weight: 600; }
.adv-callout {
  margin: 0 16px 6px; font-size: 12.5px; line-height: 1.45; color: var(--gold-bright); font-weight: 600;
}
.adv-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin: 6px 0 8px; }

/* headline tiles */
.adv-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 12px 16px 10px; }
/* two or four tiles sit in two columns, not one stranded on a second row of three */
.adv-tiles:has(> .adv-tile:nth-child(2):last-child, > .adv-tile:nth-child(4):last-child) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.adv-tile {
  --tc: var(--gold-bright); padding: 7px 9px; border-radius: 5px; min-width: 0;
  display: grid; grid-row: span 3; grid-template-rows: subgrid; row-gap: 1px; align-content: start;
  background: linear-gradient(180deg, rgba(255,235,190,.06), rgba(0,0,0,.18)); border: 1px solid rgba(201,164,92,.28);
}
.adv-tile .k {
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; align-self: end;
  font-size: 10px; line-height: 1.25; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-dim); overflow-wrap: anywhere;
}
.adv-tile b { display: block; font-family: var(--serif); font-size: 19px; font-weight: normal; color: var(--tc); line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adv-tile.long b { font-size: 15px; line-height: 1.2; white-space: normal; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
/* the subtitle carries the source and caveat, so it wraps (up to 3 lines; full text in the title tooltip) */
.adv-tile .s { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; font-size: 10.5px; line-height: 1.3; color: var(--ink-dim); overflow-wrap: break-word; }

/* ---------- controls ---------- */
.adv-seg { display: inline-flex; border: 1px solid rgba(201,164,92,.5); border-radius: 4px; overflow: hidden; flex: none; }
.adv-seg button {
  border: none; background: rgba(0,0,0,.25); color: var(--ink-dim); padding: 3px 9px; cursor: pointer; font-size: 12px;
  border-right: 1px solid rgba(201,164,92,.3);
}
.adv-seg button:last-child { border-right: none; }
.adv-seg button:hover { color: var(--gold-bright); }
.adv-seg button[aria-pressed="true"] { background: linear-gradient(180deg, #5a4a24, #3a2f15); color: var(--gold-bright); }
.adv-select { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--ink-dim); min-width: 0; }
.adv-select select, .adv-fbuild select, .adv-fbuild input, .adv-tsearch input {
  font: inherit; font-size: 12px; color: var(--ink); background: #101a24; border: 1px solid rgba(201,164,92,.45); border-radius: 4px; padding: 3px 6px; min-width: 0; max-width: 100%;
}
.adv-select select { max-width: 230px; }
.adv-select select:focus, .adv-fbuild input:focus, .adv-tsearch input:focus { outline: none; border-color: var(--gold-bright); }
.adv-mini {
  font: inherit; font-size: 11.5px; cursor: pointer; padding: 2px 8px; border-radius: 10px; color: var(--ink-dim);
  background: rgba(0,0,0,.25); border: 1px solid rgba(201,164,92,.4); white-space: nowrap; list-style: none;
}
.adv-mini:hover { color: var(--gold-bright); border-color: var(--gold); }
.adv-check { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--ink-dim); cursor: pointer; }
.adv-check input { accent-color: var(--gold); margin: 0; }
.adv-lensbtn {
  display: inline-flex; align-items: center; gap: 6px; cursor: pointer; font-family: var(--serif); font-size: 12px; color: var(--gold-bright);
  padding: 3px 9px; border-radius: 4px; border: 1px solid var(--gold); background: linear-gradient(180deg, #3a5068, #223244);
}
.adv-lensbtn:hover { background: linear-gradient(180deg, #4a6584, #2b4057); }
.adv-lensbtn[aria-pressed="true"] { background: linear-gradient(180deg, #5a4a24, #3a2f15); }
.adv-link { background: none; border: none; padding: 0; color: var(--gold-bright); text-decoration: underline; text-decoration-color: rgba(236,208,142,.4); cursor: pointer; font-size: 12px; }

.adv-chips { display: flex; flex-wrap: wrap; gap: 4px; margin: 4px 0 6px; }
.adv-chip {
  --cc: var(--gold); display: inline-flex; align-items: center; gap: 4px; cursor: pointer; font-size: 11.5px; padding: 2px 8px 2px 5px;
  border-radius: 12px; background: rgba(0,0,0,.28); border: 1px solid rgba(201,164,92,.3); color: var(--ink-dim); opacity: .7;
}
.adv-chip > i { width: 9px; height: 9px; border-radius: 50%; border: 1.5px solid var(--cc); background: transparent; flex: none; }
.adv-chip[aria-checked="true"] { opacity: 1; color: var(--ink); border-color: color-mix(in srgb, var(--cc) 70%, transparent); background: color-mix(in srgb, var(--cc) 14%, rgba(0,0,0,.3)); }
.adv-chip[aria-checked="true"] > i { background: var(--cc); }
.adv-chip .ic { display: inline-flex; }
.adv-chip .n { color: var(--ink-dim); font-size: 10px; font-variant-numeric: tabular-nums; }
.adv-slider label { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--ink-dim); }
.adv-slider input { flex: 1; accent-color: var(--gold); min-width: 0; }
.adv-slider b { color: var(--gold-bright); font-weight: 600; min-width: 84px; text-align: right; font-variant-numeric: tabular-nums; }
.adv-fchip {
  display: inline-flex; align-items: center; gap: 6px; font-size: 12px; padding: 2px 4px 2px 9px; border-radius: 12px;
  background: linear-gradient(180deg, #5a4a24, #3a2f15); border: 1px solid var(--gold); color: var(--ink);
}
.adv-fchip button { background: none; border: none; color: var(--gold-bright); cursor: pointer; padding: 0 4px; font-size: 11px; }
.adv-filterbar:empty { display: none; }
.adv-brushinfo { font-size: 12px; color: var(--ink); margin: 6px 0 0; }
.adv-brushinfo:empty { display: none; }
.adv-brushinfo .adv-mini { margin-left: 6px; }

/* ---------- bar list ---------- */
.adv-bars { display: flex; flex-direction: column; gap: 1px; }
.adv-bar {
  display: grid; grid-template-columns: auto auto minmax(0, 1fr) auto; grid-template-rows: auto 5px; align-items: center; column-gap: 0;
  width: 100%; text-align: left; cursor: pointer; padding: 3px 6px 4px; border: 1px solid transparent; border-radius: 4px; background: none; color: var(--ink);
}
.adv-bar:hover, .adv-bar.hot, .adv-bar:focus-visible { background: rgba(201,164,92,.12); border-color: rgba(201,164,92,.35); }
.adv-bar.sel { background: rgba(201,164,92,.18); border-color: var(--gold); }
.adv-bar .rk { grid-column: 1; margin-right: 6px; color: var(--ink-dim); font-size: 11px; min-width: 14px; text-align: right; font-variant-numeric: tabular-nums; }
.adv-bar .ic { grid-column: 2; margin-right: 6px; display: inline-flex; color: var(--gold-bright); }
.adv-bar .lb { grid-column: 3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 12.5px; }
.adv-bar .vl { grid-column: 4; margin-left: 8px; font-weight: 600; font-variant-numeric: tabular-nums; font-size: 12.5px; }
.adv-bar .tr { grid-column: 1 / -1; grid-row: 2; position: relative; height: 4px; border-radius: 2px; background: rgba(255,255,255,.06); }
.adv-bar .tr i { position: absolute; top: 0; bottom: 0; left: 0; border-radius: 2px; background: linear-gradient(90deg, #b4872f, #ecd08e); }
.adv-bars.div .tr::after { content: ""; position: absolute; left: 50%; top: -2px; bottom: -2px; width: 1px; background: rgba(236,208,142,.4); }
.adv-bars.div .tr i { left: auto; }
.adv-bars.div .tr i:not(.neg) { left: 50%; }
.good { color: #8fd18a; }
.bad { color: #f09a7f; }
.adv-bar .tr i.good { background: linear-gradient(90deg, #2e9c8a, #7dc2b0); }
.adv-bar .tr i.bad { background: linear-gradient(270deg, #c2463d, #e08a6a); }
.adv-bars.compact .adv-bar { padding: 1px 6px 2px; }

/* ---------- stacked bars ---------- */
.adv-stack { display: flex; flex-direction: column; gap: 1px; }
.adv-srow {
  display: grid; grid-template-columns: 112px minmax(0, 1fr) 62px; gap: 8px; align-items: center; width: 100%; text-align: left;
  background: none; border: 1px solid transparent; border-radius: 3px; color: var(--ink); padding: 2px 4px; cursor: pointer; font-size: 12px;
}
.adv-srow:hover, .adv-srow.hot, .adv-srow:focus-visible { background: rgba(201,164,92,.1); border-color: rgba(201,164,92,.3); }
.adv-srow.sel { background: rgba(201,164,92,.18); border-color: var(--gold); }
.adv-srow .lb { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adv-srow .st { display: flex; height: 11px; border-radius: 2px; overflow: hidden; background: rgba(255,255,255,.04); }
.adv-srow .st i { display: block; height: 100%; box-shadow: inset -1px 0 0 rgba(0,0,0,.35); }
.adv-srow .st i:hover { filter: brightness(1.35); }
.adv-srow .vl { text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; }

/* ---------- share bar ---------- */
.adv-share-bar { display: flex; height: 18px; border-radius: 3px; overflow: hidden; border: 1px solid rgba(0,0,0,.6); box-shadow: 0 0 0 1px rgba(201,164,92,.3); margin: 4px 0 8px; }
.adv-share-bar i { display: block; height: 100%; cursor: pointer; box-shadow: inset -1px 0 0 rgba(0,0,0,.4); transition: filter .12s; }
.adv-share-bar i:hover, .adv-share-bar i.hot { filter: brightness(1.35); }
.adv-share-bar i.sel { box-shadow: inset 0 0 0 2px #fff3c4; }
.adv-swatches { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px 10px; }
.adv-sw {
  display: flex; align-items: center; gap: 6px; text-align: left; cursor: pointer; padding: 2px 5px; font-size: 12px;
  background: none; border: 1px solid transparent; border-radius: 3px; color: var(--ink); min-width: 0;
}
.adv-sw i { width: 11px; height: 11px; border-radius: 2px; flex: none; box-shadow: 0 0 0 1px rgba(0,0,0,.5); }
.adv-sw .lb { flex: 1; min-width: 0; line-height: 1.25; overflow-wrap: anywhere; } /* long names wrap onto two lines */
.adv-sw .vl { font-variant-numeric: tabular-nums; color: var(--ink-dim); }
.adv-sw:hover, .adv-sw.hot { background: rgba(201,164,92,.12); border-color: rgba(201,164,92,.3); }
.adv-sw.sel { border-color: var(--gold); background: rgba(201,164,92,.18); }

/* ---------- donut ---------- */
.adv-donut svg path { cursor: pointer; stroke: rgba(0,0,0,.5); stroke-width: .8; }
.adv-donut svg path:hover, .adv-donut svg path.hot { filter: brightness(1.3); }
.adv-donut .big { fill: var(--gold-bright); font-family: var(--serif); font-size: 17px; }
.adv-donut .small { fill: var(--ink-dim); font-size: 10px; }

/* ---------- histogram ---------- */
.adv-hist svg { display: block; max-width: 100%; }
.adv-hist .bin { cursor: pointer; }
.adv-hist .hit { fill: transparent; }
.adv-hist .bin:hover .hit, .adv-hist .bin.hot .hit { fill: rgba(236,208,142,.1); }
.adv-hist .bin:hover .bar, .adv-hist .bin.hot .bar { filter: brightness(1.4); stroke: #fff3c4; stroke-width: 1; }
.adv-hist .axis { stroke: rgba(201,164,92,.5); }
.adv-hist .tick { fill: var(--ink-dim); font-size: 9.5px; }
.adv-hist .marker { stroke: #fff3c4; stroke-dasharray: 3 3; }
.adv-hist .mk { fill: #fff3c4; font-size: 9.5px; }

/* ---------- small multiples ---------- */
.adv-multiples { display: grid; grid-template-columns: repeat(auto-fill, minmax(var(--min, 120px), 1fr)); gap: 6px; }
.adv-mult { text-align: left; background: rgba(0,0,0,.2); border: 1px solid rgba(201,164,92,.25); border-radius: 4px; padding: 5px 6px; color: var(--ink); cursor: pointer; font-size: 11.5px; }
.adv-mult:hover, .adv-mult.hot { border-color: var(--gold); }
.adv-mult .body { display: block; margin-top: 3px; }

/* ---------- legends ---------- */
.adv-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: 11px; color: var(--ink-dim); margin: 6px 0 2px; }
.adv-legend .t { color: var(--ink); width: 100%; font-size: 11px; }
.adv-legend.ramp { display: grid; grid-template-columns: 1fr; gap: 2px; max-width: 320px; }
.adv-legend.ramp .g { display: block; height: 8px; border-radius: 2px; box-shadow: 0 0 0 1px rgba(0,0,0,.5); }
.adv-legend.ramp .ends { display: flex; justify-content: space-between; font-variant-numeric: tabular-nums; }
.adv-legend.sw .it { display: inline-flex; align-items: center; gap: 4px; }
.adv-legend.sw i { width: 10px; height: 10px; border-radius: 2px; }
.adv-legend.size svg circle { fill: rgba(236,208,142,.18); stroke: rgba(236,208,142,.8); }
.adv-legend.size svg text { fill: var(--ink-dim); font-size: 10px; }

/* ---------- scatter ---------- */
.adv-scatter { position: relative; width: 100%; margin: 4px 0; touch-action: none; }
.adv-scatter canvas { display: block; cursor: crosshair; border-radius: 3px; }
.adv-scatter canvas:focus-visible { outline: 2px solid var(--gold-bright); outline-offset: 1px; }
.adv-ptip {
  position: absolute; z-index: 3; pointer-events: none; max-width: 240px; padding: 5px 8px; font-size: 11.5px; line-height: 1.45;
  background: rgba(10,15,22,.96); border: 1px solid var(--line); border-radius: 4px; color: var(--ink); box-shadow: 0 4px 12px rgba(0,0,0,.5);
}
.adv-ptip b { color: var(--gold-bright); font-weight: 600; }
.adv-shint { text-align: right; margin-top: 1px; font-size: 10px; color: rgba(232,220,192,.5); pointer-events: none; } /* under the plot, clear of guide labels */

/* ---------- table ---------- */
.adv-table { --cols: 1fr; margin: 4px 0; font-size: 12px; }
.adv-tsearch { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; }
.adv-tsearch input { flex: 1; }
.adv-tsearch .cnt { font-size: 11px; color: var(--ink-dim); white-space: nowrap; font-variant-numeric: tabular-nums; }
.adv-thead, .adv-tr { display: grid; grid-template-columns: var(--cols); column-gap: 8px; align-items: center; padding: 0 6px; }
.adv-thead { border-bottom: 1px solid rgba(201,164,92,.5); padding-bottom: 3px; align-items: end; }
.adv-thead .th button {
  background: none; border: none; padding: 2px 0; cursor: pointer; color: var(--ink-dim); font-size: 10px; letter-spacing: .05em; line-height: 1.2;
  text-transform: uppercase; font-weight: 600; width: 100%; white-space: normal; hyphens: manual; overflow-wrap: normal;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden;
}
.adv-thead .th.r button { text-align: right; }
.adv-thead .th.l button { text-align: left; }
.adv-thead .th[aria-sort="ascending"] button, .adv-thead .th[aria-sort="descending"] button { color: var(--gold-bright); }
.adv-thead .arr { font-size: 8px; margin-left: 3px; }
.adv-thead .th.r { text-align: right; }
.adv-tbody { position: relative; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: rgba(201,164,92,.4) transparent; }
.adv-tbody:focus-visible { outline: 1px solid var(--gold-bright); }
.adv-tspace { position: relative; }
.adv-tr { position: absolute; left: 0; right: 0; cursor: pointer; border-bottom: 1px solid rgba(255,255,255,.04); }
.adv-tr:nth-child(even) { background: rgba(255,255,255,.015); }
.adv-tr:hover, .adv-tr.hot { background: rgba(201,164,92,.14); }
.adv-tr.sel { box-shadow: inset 3px 0 0 var(--gold-bright); background: rgba(201,164,92,.08); }
.adv-tr.sel.hot { background: rgba(201,164,92,.2); }
.adv-tr .td { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; position: relative; }
.adv-tr .td.l .sub { margin-left: 1px; }
.adv-tr .td.r { text-align: right; }
.adv-tr .rk { color: var(--ink-dim); font-size: 10.5px; }
.adv-tr .td .ic { display: inline-flex; vertical-align: -3px; margin-right: 4px; }
.adv-tr .td.hasbar .tbar { position: absolute; right: 0; top: 4px; bottom: 4px; border-radius: 2px; background: rgba(201,164,92,.25); }
.adv-tr .td.hasbar .tv { position: relative; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; vertical-align: 0; box-shadow: 0 0 0 1px rgba(0,0,0,.6); }
.adv-minibar { display: flex; height: 10px; border-radius: 2px; overflow: hidden; background: rgba(255,255,255,.05); margin-top: 1px; }
.adv-minibar i { display: block; height: 100%; }

/* ---------- explainer, sources ---------- */
.adv-explain { display: grid; grid-template-columns: 30px 1fr; gap: 8px; padding: 6px 0; border-bottom: 1px dashed rgba(201,164,92,.15); }
.adv-explain .ic { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: color-mix(in srgb, var(--cc) 25%, #0f1822); border: 1px solid var(--cc); }
.adv-explain b { font-family: var(--serif); color: var(--gold-bright); font-weight: normal; font-size: 14px; }
.adv-explain p { margin: 2px 0; font-size: 12px; color: var(--ink); }
.adv-explain .src { font-size: 10.5px; color: var(--ink-dim); }
.adv-sources { padding: 12px 16px 6px; font-size: 11.5px; color: var(--ink-dim); }
.adv-sources h4 { margin: 8px 0 4px; font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); font-weight: 600; }
.adv-sources ul { margin: 0 0 6px; padding-left: 16px; }
.adv-sources li { margin: 2px 0; }
.adv-sources b { color: var(--ink); font-weight: 600; }
.adv-sources .v { color: var(--ink-dim); white-space: nowrap; }
.adv-caveats li::marker { color: var(--gold); }

/* ---------- explorer ---------- */
.adv-cols { position: relative; }
.adv-cols > summary { display: inline-block; }
.adv-cols > summary::-webkit-details-marker { display: none; }
.adv-cols-pop {
  position: absolute; z-index: 6; left: 0; top: calc(100% + 4px); width: 300px; max-height: 320px; overflow-y: auto; padding: 8px 10px;
  background: #141f2b; border: 1px solid var(--line); border-radius: 5px; box-shadow: 0 8px 20px rgba(0,0,0,.6);
}
.adv-cols-pop fieldset { border: none; margin: 0 0 6px; padding: 0; }
.adv-cols-pop legend { font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); padding: 0; margin-bottom: 2px; }
.adv-cols-pop label { display: flex; align-items: center; gap: 6px; font-size: 12px; padding: 1px 0; cursor: pointer; }
.adv-cols-pop input { accent-color: var(--gold); margin: 0; }
.adv-fbuild { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 4px 0; }
.adv-fbuild .adv-select select { max-width: 150px; }
.adv-fbuild input[type="text"] { width: 104px; }
.adv-presets { display: inline-flex; gap: 4px; }
.adv-summary { margin: 6px 0 0; }
.adv-axes { display: flex; flex-wrap: wrap; gap: 6px 10px; margin: 2px 0 6px; }
.adv-axes .adv-select select { max-width: 160px; }
.adv-logs { display: inline-flex; gap: 10px; }
.adv-fieldinfo p { margin: 3px 0; font-size: 11.5px; color: var(--ink-dim); }
.adv-fieldinfo b { color: var(--ink); }

/* ---------- map tooltip for the dashboards' own marks ---------- */
.adv-maptip {
  position: fixed; z-index: 21; pointer-events: none; max-width: 280px; padding: 6px 9px; font-size: 12px; line-height: 1.45;
  background: rgba(12,18,26,.97); border: 1px solid var(--line); border-radius: 4px; color: var(--ink); box-shadow: 0 4px 14px rgba(0,0,0,.5);
}
.adv-maptip b { color: var(--gold-bright); }
.adv-maptip .sub { color: var(--ink-dim); font-size: 11px; }
body.adv-tip-on #tooltip { display: none !important; }

/* ---------- phones: the dock is a bottom sheet ---------- */
@media (max-width: 700px) {
  .adv-grip { display: block; height: 14px; position: relative; }
  .adv-grip::before { content: ""; position: absolute; left: 50%; top: 5px; width: 44px; height: 4px; margin-left: -22px; border-radius: 2px; background: rgba(201,164,92,.6); }
  .adv-head { padding: 4px 8px 6px; }
  .adv-council-btn span { display: none; }
  .adv-title { padding: 10px 12px; gap: 10px; }
  .adv-title .adv-emblem { width: 44px; height: 44px; }
  .adv-title h2 { font-size: 19px; }
  .adv-title p { font-size: 12px; }
  .adv-sec { padding: 12px 12px 10px; }
  .adv-tiles { padding: 10px 12px 8px; gap: 6px; }
  .adv-tile b { font-size: 16px; }
  .adv-callout { margin: 0 12px 4px; }
  .adv-swatches { grid-template-columns: 1fr; }
  .adv-srow { grid-template-columns: 90px minmax(0, 1fr) 56px; }
  .adv-cols-pop { width: min(300px, calc(100vw - 40px)); }
}
@media (prefers-reduced-motion: reduce) {
  .adv-tabs button, .adv-card { transition: none; }
}

/* small-multiple donuts (Land) */
.adv-mult .adv-donut { display: grid; place-items: center; }
.adv-donut.passive svg path { cursor: inherit; }
.adv-donut.passive .big { font-size: 13px; }
.adv-mult .lb { display: block; text-align: center; font-family: var(--serif); color: var(--gold-bright); }
.adv-mult .lb .sub { display: none; }

/* ---------- map colour picker and selection framing ---------- */
.adv-sec.adv-mapsec { padding-top: 8px; padding-bottom: 10px; }
.adv-mappick { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.adv-mappick .k {
  display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-dim); font-weight: 600;
}
.adv-mappick .k svg, .adv-mappick .k .emoji { color: var(--adv); filter: brightness(1.25); }
.adv-mappick .adv-seg { flex-wrap: wrap; }
.adv-seg + .adv-mini { margin-left: 8px; }
.adv-framebtn { display: inline-flex; align-items: center; gap: 4px; color: var(--gold-bright); border-color: rgba(236,208,142,.55); margin-right: 4px; }
.adv-framebtn svg { flex: none; }
.adv-row .adv-framebtn { margin-left: 2px; }
@media (max-width: 700px) {
  .adv-mappick .adv-seg button { padding: 4px 8px; }
}

/* ---------- ten advisors, detail cards, caveats ---------- */
/* Ten medallions fit the header: smaller tabs, and the Council label hides when the dock is narrow. */
.adv-root { container-type: inline-size; }
.adv-tabs button { width: 31px; height: 31px; }
.adv-tabs button .adv-emblem { width: 27px; height: 27px; }
@container (max-width: 470px) {
  .adv-council-btn span { display: none; }
  .adv-tabs { gap: 1px; }
  .adv-tabs button { width: 28px; height: 28px; }
  .adv-tabs button .adv-emblem { width: 24px; height: 24px; }
  .adv-head { gap: 4px; padding-left: 8px; padding-right: 8px; }
}
.adv-council-h {
  margin: 10px 16px 0; font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); font-weight: 600;
}
.adv-council-h + .adv-council { padding-top: 6px; padding-bottom: 4px; }
.adv-card .adv-emblem { flex: none; }

.adv-detail:empty { display: none; }
.adv-card-detail {
  margin: 10px 0 2px; padding: 4px 10px 8px; border-radius: 5px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--adv) 12%, rgba(0,0,0,.25)), rgba(0,0,0,.15));
  border: 1px solid color-mix(in srgb, var(--adv) 45%, rgba(201,164,92,.3));
}
.adv-card-detail .adv-tiles { padding: 4px 0 8px; }
.adv-card-detail .adv-h4 { color: var(--gold-bright); font-family: var(--serif); font-size: 13px; letter-spacing: .04em; text-transform: none; font-weight: normal; }
.adv-chiplist { display: flex; flex-wrap: wrap; gap: 4px; }
.adv-chiplist .adv-mini b { color: var(--ink); font-weight: 600; margin-left: 3px; }
.adv-chiplist .adv-mini:disabled { opacity: .5; cursor: default; }
.adv-callout.adv-caveat { margin: 4px 0 8px; color: #e8a07a; font-weight: 500; font-style: italic; }
.adv-rule { font-style: italic; }
.adv-olist { margin: 2px 0 6px; padding-left: 20px; font-size: 12px; }
.adv-olist li { margin: 2px 0; }
.adv-olist b { font-weight: 600; color: var(--ink); }
.adv-cols-chart svg { height: 110px; }
