.east-explorer {
  --east-panel: #181c25;
  --east-line: #383e50;
  --east-text: #f4f2f7;
  --east-muted: #b8becd;
  --east-accent: #ffbc94;
  color: var(--east-text);
  color-scheme: dark;
}
[data-theme="light"] .east-explorer {
  --east-panel: #fffaf5;
  --east-line: #d2c5ba;
  --east-text: #282333;
  --east-muted: #5c5465;
  --east-accent: #964319;
  color-scheme: light;
}
.east-explorer * { box-sizing: border-box; }
.east-explorer [hidden] { display: none !important; }
.east-explorer :focus-visible { outline: 2px solid var(--east-accent); outline-offset: 2px; }
.east-toolbar { display: flex; flex-wrap: wrap; gap: .65rem; align-items: end; margin-bottom: .85rem; }
.east-toolbar > label { flex: 1 1 10rem; }
.east-explorer label { display: grid; gap: .3rem; font-size: .86rem; font-weight: 600; }
.east-explorer :where(select, input:not([type="checkbox"]), button) {
  font: inherit;
  color: inherit;
  min-height: 2.65rem;
  background: var(--east-panel);
  border: 1px solid var(--east-line);
  border-radius: .55rem;
  padding: .45rem .65rem;
}
.east-explorer :is(select, input:not([type="checkbox"])) { width: 100%; min-width: 0; }
.east-explorer button { cursor: pointer; }
.east-explorer button:hover { border-color: var(--east-accent); }
.east-explorer button:disabled { opacity: .55; cursor: default; }
.east-layout { display: grid; grid-template-columns: minmax(0, 2fr) minmax(15rem, 1fr); gap: .85rem; align-items: start; }
.east-map-panel, .east-catalog {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--east-line);
  border-radius: .9rem;
  background: var(--east-panel);
}
.east-map-tools { display: flex; flex-wrap: wrap; gap: .35rem; padding: .5rem; }
.east-map-tools button { min-width: 2.65rem; }
.east-map-tools .east-check { margin-inline-start: .4rem; }
.east-map {
  height: clamp(21rem, 54vh, 38rem);
  overflow: auto;
  overscroll-behavior: contain;
  background: #21271f;
}
.east-stage { position: relative; margin-inline: auto; }
.east-map.is-dragging { cursor: grabbing; }
.east-stage img { display: block; width: 100%; height: 100%; max-width: none; user-select: none; }
.east-map.is-dimmed #eastTerrain { filter: brightness(.57); }
.east-explorer .east-marker {
  position: absolute;
  transform: translate(-50%, -50%);
  display: grid;
  place-content: center;
  width: 18px;
  height: 18px;
  min-height: 0;
  padding: 0;
  border: 1px solid #e3af743d;
  border-radius: 5px;
  background: #18151bf2;
  color: #f0c48d;
}
.east-marker svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.east-marker .east-item-icon { width: 14px; height: 14px; object-fit: contain; }
.east-marker[data-kind="glint"] { color: #b9d8e9; }
.east-marker[data-kind="quest"] { color: #d9c3e9; }
.east-marker[data-kind="resource"] { color: #c3d8a8; }
.east-marker[data-kind="monster"] svg { stroke: var(--east-monster-color, #efa5a5); }
.east-monster-swatch {
  display: inline-block;
  width: .7em;
  height: .7em;
  flex: 0 0 .7em;
  margin-inline-end: .35em;
  border-radius: 50%;
  background: var(--east-monster-color, #efa5a5);
  box-shadow: 0 0 0 1px #352b38;
}
.east-layer-controls .east-monster-swatch { margin-block-start: .25em; margin-inline-end: 0; }
.east-marker[data-kind="loot"] { color: #efc3ac; }
.east-marker[data-kind="landmark"] { color: #d3c5f0; }
.east-marker.is-found { opacity: .64; }
.east-explorer .east-marker:is(:hover, :focus-visible, [aria-pressed="true"]) { outline: 1px solid #fff; outline-offset: 1px; opacity: 1; z-index: 1; }
.east-detail { display: flex; flex-wrap: wrap; align-items: center; gap: .65rem; padding: .75rem; }
.east-detail div { flex: 1 1 10rem; }
.east-detail label, .east-explorer .east-check { display: flex; align-items: center; gap: .35rem; }
.east-detail small, .east-list small { display: block; margin-top: .2rem; color: var(--east-muted); }
.east-filters { display: grid; gap: .65rem; padding: .75rem; }
.east-layer-controls { display: grid; gap: .5rem; }
.east-layer-controls fieldset { margin: 0; min-width: 0; max-height: 9rem; overflow: auto; border: 1px solid var(--east-line); border-radius: .55rem; }
.east-layer-controls .east-check { align-items: start; padding-block: .2rem; }
.east-layer-controls .east-item-icon { width: 24px; height: 24px; object-fit: contain; flex: none; }
.east-list .east-item-icon { width: 24px; height: 24px; object-fit: contain; vertical-align: middle; margin-inline-end: .45rem; }
.east-item-icon[data-level] { border-radius: 4px; padding: 2px; background: linear-gradient(#534e52, #787878); }
.east-item-icon[data-level="2"] { background: linear-gradient(#2b4964, #43719f); }
.east-item-icon[data-level="3"] { background: linear-gradient(#52386a, #8158a1); }
.east-item-icon[data-level="4"] { background: linear-gradient(#a6712c, #d2aa4e); }
.east-item-icon[data-level="5"] { background: linear-gradient(#8b4118, #c66529); }
.east-layer-controls small { display: block; font-weight: 400; color: var(--east-muted); }
.east-progress { color: var(--east-muted); }
.east-progress progress { width: 100%; height: .65rem; accent-color: var(--east-accent); }
.east-list { list-style: none; margin: 0; padding: 0 .6rem .6rem; max-height: clamp(16rem, 40vh, 28rem); overflow: auto; }
.east-list li { display: flex; align-items: center; gap: .55rem; padding: .3rem .1rem; border-top: 1px solid var(--east-line); }
.east-list button { text-align: left; flex: 1; min-width: 0; border-color: transparent; }
.east-list button[aria-pressed="true"] { border-color: var(--east-accent); }
.east-list input[type="checkbox"] { width: 1.1rem; height: 1.1rem; flex: none; }
.east-status { color: var(--east-accent); min-height: 1.3em; margin: .45rem 0; font-size: .85rem; }
#eastEmpty { padding: .55rem .75rem; color: var(--east-muted); font-size: .85rem; }
.east-explorer dialog { width: min(30rem, calc(100% - 2rem)); padding: 1rem; background: var(--east-panel); color: var(--east-text); border: 1px solid var(--east-line); border-radius: .9rem; }
.east-explorer dialog::backdrop { background: #0009; }
.east-explorer dialog .east-toolbar { margin: .8rem 0 0; }
@media (max-width: 720px) {
  .east-layout { grid-template-columns: minmax(0, 1fr); }
  .east-map { height: clamp(17rem, 46vh, 28rem); }
}
