.simple { display: grid; grid-template-columns: 340px 1fr; height: 100vh; }
.left { background: var(--surface-1); border-right: 1px solid var(--border); overflow-y: auto; padding: 18px 16px 24px;
  display: flex; flex-direction: column; gap: 14px; }
.left header h1 { font-size: 18px; margin: 0 0 2px; }
.left header p { margin: 0; font-size: 12px; }
.left h2 { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-secondary); margin: 0 0 8px; }
.slider-label { display: flex; justify-content: space-between; color: var(--text-secondary); margin-bottom: 6px; font-size: 13px; }
.slider-label b { color: var(--text-primary); font-variant-numeric: tabular-nums; font-weight: 600; }
.left input[type=range] { width: 100%; accent-color: var(--accent); }
.scale { display: flex; justify-content: space-between; font-size: 11px; margin-top: 2px; }
.more summary { cursor: pointer; color: var(--text-secondary); font-size: 13px; }
.deep-opt { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--text-primary); cursor: pointer;
  border: 1px solid var(--border); border-radius: var(--radius); padding: 8px 10px; background: var(--surface-2); }
.deep-opt input { margin-top: 2px; accent-color: var(--accent); }
.deep-opt .muted { font-size: 12px; line-height: 1.4; }
.more .field input { width: 110px; }
.left button.primary { flex: none; }
#find { position: relative; overflow: hidden; }
#find .lbl { position: relative; font-variant-numeric: tabular-nums; }
#find .fill { position: absolute; top: 0; bottom: 0; left: 0; width: 0; background: rgba(255, 255, 255, 0.28);
  transition: width .3s ease-out; }
#find:disabled { opacity: 1; cursor: progress; background: color-mix(in srgb, var(--accent) 55%, var(--surface-2)); }
#find.indeterminate .fill { width: 35% !important; transition: none; animation: find-slide 1.3s ease-in-out infinite; }
@keyframes find-slide { from { left: -35%; } to { left: 100%; } }
@media (prefers-reduced-motion: reduce) { #find.indeterminate .fill { animation: none; left: 0; width: 100% !important; opacity: .4; } }

.routes { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.route { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface-2); padding: 10px 12px;
  cursor: pointer; display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 2px 8px; text-align: left; width: 100%;
  font: inherit; color: inherit; }
.route:hover { border-color: var(--text-muted); }
.route.sel { border-color: var(--accent); box-shadow: inset 3px 0 0 var(--accent); }
.route .rk { grid-row: span 3; font-weight: 700; color: var(--text-secondary); font-size: 15px; padding-top: 1px; }
.route .eff { font-size: 16px; font-weight: 650; font-variant-numeric: tabular-nums; }
.route .eff small { font-size: 12px; font-weight: 400; color: var(--text-muted); margin-left: 6px; }
.route .meta { font-size: 12px; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.route .gemline { display: flex; gap: 8px; font-size: 12px; color: var(--text-muted); flex-wrap: wrap; }
.route .gemline .key { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 4px; }
.route .exports { grid-column: 2; display: none; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.route.sel .exports { display: flex; }
.route .exports a { font-size: 12px; padding: 3px 8px; }

.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 2px; }
.seg button { border: none; background: transparent; color: var(--text-secondary); padding: 6px 8px; border-radius: 6px; font-weight: 600; }
.seg button.on { background: var(--surface-1); color: var(--text-primary); box-shadow: 0 0 0 1px var(--border); }
.seg .badge { font-weight: 500; color: var(--text-muted); margin-left: 4px; font-variant-numeric: tabular-nums; }
.view { display: flex; flex-direction: column; gap: 14px; }
.view[hidden] { display: none; }
.route .name { font-size: 15px; font-weight: 650; overflow-wrap: anywhere; }
.route .name, .route .eff, .route .meta, .route .gemline { grid-column: 2; }
.route .rk.star { color: var(--accent); }
.route .saved-at { color: var(--text-muted); }
.route .exports button { font-size: 12px; padding: 3px 8px; }
.route .exports .danger { color: var(--critical); border-color: var(--border); }
.route .exports .done { color: var(--text-muted); cursor: default; }
.inline-form { grid-column: 2; display: flex; gap: 6px; margin-top: 6px; }
.inline-form input { flex: 1; min-width: 0; background: var(--surface-1); color: var(--text-primary); border: 1px solid var(--accent);
  border-radius: 6px; padding: 4px 7px; font: inherit; font-size: 13px; }
.inline-form button { font-size: 12px; padding: 3px 8px; }
.lib-empty { color: var(--text-muted); font-size: 13px; line-height: 1.5; }

/* ---- route viewer: top bar / 3D / player bar, nothing floats over the route ---- */
.stage { min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.stage .viewport { flex: 1; min-height: 0; }
.stage-top[hidden], .player[hidden], .wp-card[hidden], .empty[hidden] { display: none; }
.stage-top { display: flex; align-items: center; justify-content: space-between; gap: 10px 24px; flex-wrap: wrap;
  padding: 10px 16px; background: var(--surface-1); border-bottom: 1px solid var(--border); }
.rt-head { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.rt-name { font-weight: 650; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rt-stats { display: flex; flex-wrap: wrap; gap: 6px; }
.stat { background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: 2px 10px;
  font-size: 12px; color: var(--text-secondary); white-space: nowrap; }
.stat b { color: var(--text-primary); font-variant-numeric: tabular-nums; font-weight: 600; }
.view-opts { display: flex; align-items: center; gap: 4px 16px; flex-wrap: wrap; font-size: 13px; }
.view-opts .check { margin: 0; }

.empty { position: absolute; inset: 0; display: grid; place-items: center; color: var(--text-muted); pointer-events: none; }
.empty p { margin: 0; }
.stage .details { left: 12px; right: auto; }

.wp-card { position: absolute; top: 12px; right: 12px; width: 300px; max-width: calc(100% - 24px); z-index: 4;
  background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 12px; font-size: 13px; }
.wp-card h3 { margin: 0 0 8px; font-size: 14px; display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.wp-card h3 span { color: var(--text-muted); font-weight: 400; font-size: 12px; }
.wp-card dl { display: grid; grid-template-columns: auto 1fr; gap: 5px 10px; margin: 0; }
.wp-card dt { color: var(--text-muted); }
.wp-card dd { margin: 0; font-variant-numeric: tabular-nums; }
.wp-card .place { color: var(--text-primary); font-weight: 600; }

.player { display: flex; align-items: center; gap: 14px; padding: 8px 16px; background: var(--surface-1); border-top: 1px solid var(--border); }
.player-btns { display: flex; gap: 4px; }
.player-btns button { width: 36px; height: 32px; padding: 0; font-size: 17px; line-height: 1; }
.player-btns .play { width: 44px; background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-size: 14px; }
.walk-count { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; min-width: 150px; }
.track { flex: 1; display: flex; gap: 3px; align-items: center; min-width: 0; height: 28px; }
.track button { flex: 1; min-width: 3px; height: 10px; padding: 0; border: 0; border-radius: 3px; cursor: pointer;
  background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--border); transition: height .15s; }
.track button:hover, .track button:focus-visible { background: var(--text-muted); height: 16px; }
.track button.done { background: color-mix(in srgb, var(--accent) 45%, var(--surface-2)); }
.track button.cur { background: var(--accent); height: 18px; box-shadow: none; }
.player-keys { font-size: 11px; white-space: nowrap; cursor: help; }
.loading .routes, .loading .viewport canvas { opacity: .55; transition: opacity .2s; }

@media (max-width: 860px) {
  .simple { grid-template-columns: 1fr; height: auto; }
  .left { border-right: none; border-bottom: 1px solid var(--border); }
  .stage .viewport { min-height: 65vh; }
  .player { flex-wrap: wrap; gap: 8px 12px; }
  .track { flex-basis: 100%; order: 3; }
  .player-keys { display: none; }
  .walk-count { min-width: 0; }
  .wp-card { left: 12px; width: auto; }
}

/* =====================================================================
   Pro theme (this page only: body.pro)
   Docked panels joined by hairlines, small 3-6 px corners, near-black
   surfaces with a restrained champagne-gold accent.
   ===================================================================== */
body.pro {
  color-scheme: dark;
  --surface-0: #0a0b0e;
  --surface-1: #111317;
  --surface-2: #171a1f;
  --surface-3: #20232a;
  --border: #23262d;
  --border-2: #31353e;
  --border-3: #474c57;
  --text-primary: #ebe8e1;
  --text-secondary: #b3afa5;
  --text-muted: #7f7b72;
  --accent: #d4af6a;
  --accent-hi: #e9cf96;
  --accent-lo: #9c7a3c;
  --accent-ink: #15110a;
  --accent-tint: rgba(212, 175, 106, 0.1);
  --route: #e6c47f;
  --teleport: #8fb8f0;
  --platform: #e4dccb;
  --critical: #e06c6c;
  --scene-bg: transparent;
  --radius: 4px;
  --r-sm: 3px;
  --r-md: 4px;
  --r-lg: 6px;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 13px;
  background: var(--surface-0);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
}
.pro :focus-visible { outline: 2px solid rgba(212, 175, 106, 0.8); outline-offset: 1px; }
.pro .muted, .pro .hint, .pro .count, .pro .empty { color: var(--text-muted); }

/* shell: app bar on top, sidebar and stage docked below */
.pro .shell { display: grid; grid-template-rows: 44px minmax(0, 1fr); height: 100vh; }
.pro .simple { height: auto; min-height: 0; grid-template-columns: 340px minmax(0, 1fr); }
.pro .appbar {
  display: flex; align-items: center; gap: 14px; min-width: 0; padding: 0 18px;
  background: var(--surface-1); border-bottom: 1px solid var(--border);
}
.pro .appbar h1 {
  margin: 0; font-size: 12px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent-hi); white-space: nowrap;
}
.pro .appbar-sep { width: 1px; height: 16px; background: var(--border-2); flex: none; }
.pro #dataset { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pro .appbar-keys { margin-left: auto; font-size: 11px; white-space: nowrap; }

/* buttons and inputs */
.pro button, .pro .button {
  font: inherit; font-size: 12px; border-radius: var(--r-md); border: 1px solid var(--border-2);
  background: var(--surface-2); color: var(--text-primary); transition: background .12s, border-color .12s, color .12s;
}
.pro button:hover, .pro .button:hover { background: var(--surface-3); border-color: var(--border-3); }
.pro button.ghost { background: transparent; }
.pro input[type=number], .pro input[type=text] {
  font: inherit; font-size: 12px; font-variant-numeric: tabular-nums; color: var(--text-primary);
  background: var(--surface-0); border: 1px solid var(--border-2); border-radius: var(--r-sm); padding: 5px 8px;
}
.pro input[type=number]:focus, .pro input[type=text]:focus { border-color: var(--accent); outline: none; }

/* sidebar */
.pro .left {
  padding: 0; gap: 0; background: var(--surface-1); border-right: 1px solid var(--border);
  scrollbar-width: none;  /* still scrolls with the wheel; the bar is hidden */
}
.pro .left::-webkit-scrollbar { display: none; }
.pro .view { gap: 0; }
.pro .seg {
  position: sticky; top: 0; z-index: 2; display: grid; grid-template-columns: 1fr 1fr; gap: 0; padding: 0;
  background: var(--surface-1); border: 0; border-bottom: 1px solid var(--border); border-radius: 0;
}
.pro .seg button {
  border: 0; border-radius: 0; background: none; padding: 13px 8px 12px; color: var(--text-muted);
  font-size: 11px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; box-shadow: inset 0 -2px 0 transparent;
}
.pro .seg button:hover { background: none; color: var(--text-primary); }
.pro .seg button.on { color: var(--text-primary); box-shadow: inset 0 -2px 0 var(--accent); }
.pro .seg .badge {
  display: inline-block; min-width: 18px; margin-left: 6px; padding: 0 5px; border-radius: var(--r-sm);
  background: var(--surface-3); color: var(--text-secondary); font-size: 10px; line-height: 16px; letter-spacing: 0;
}
.pro .seg .badge:empty { display: none; }

.pro .sec { display: flex; flex-direction: column; gap: 12px; padding: 16px 18px 18px; border-bottom: 1px solid var(--border); }
.pro .sec h2 { margin: 0; font-size: 10.5px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-muted); }

/* gem toggles: a two-column grid */
.pro .chips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.pro .chip {
  display: flex; align-items: center; gap: 8px; min-width: 0; padding: 7px 10px; cursor: pointer; user-select: none;
  font-size: 12px; color: var(--text-secondary); background: var(--surface-2);
  border: 1px solid var(--border-2); border-radius: var(--r-md); transition: border-color .12s, background .12s, color .12s;
}
.pro .chip:hover { border-color: var(--border-3); color: var(--text-primary); }
.pro .chip.on { color: var(--text-primary); background: var(--accent-tint); border-color: rgba(212, 175, 106, 0.55); }
.pro .chip .sw { width: 8px; height: 8px; border-radius: 2px; flex: none; box-shadow: none; }
.pro .chip:not(.on) .sw { opacity: 0.35; }
.pro .chip .n { margin-left: auto; font-size: 11px; color: var(--text-muted); font-variant-numeric: tabular-nums; }

/* sliders: thin track, small square-cornered thumb */
.pro .slider { display: flex; flex-direction: column; gap: 6px; }
.pro .slider-label { margin: 0; font-size: 12px; color: var(--text-secondary); }
.pro .slider-label b { color: var(--accent-hi); font-weight: 600; }
.pro input[type=range] {
  -webkit-appearance: none; appearance: none; width: 100%; height: 4px; margin: 7px 0; cursor: pointer; border-radius: 2px;
  background: linear-gradient(90deg, var(--accent) var(--fill, 50%), var(--border-2) var(--fill, 50%));
}
.pro input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 12px; height: 18px; border-radius: 2px; cursor: pointer;
  background: var(--accent-hi); border: 1px solid var(--accent-lo); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}
.pro input[type=range]::-moz-range-thumb {
  width: 12px; height: 18px; border-radius: 2px; cursor: pointer;
  background: var(--accent-hi); border: 1px solid var(--accent-lo); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}
.pro input[type=range]:focus-visible { outline-offset: 6px; }
.pro .scale { margin-top: -2px; font-size: 11px; }

/* option rows: text on the left, switch on the right */
.pro .deep-opt {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; cursor: pointer;
  padding: 0; background: none; border: 0; border-radius: 0;
}
.pro .deep-opt > span { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pro .deep-opt b { font-size: 13px; font-weight: 600; color: var(--text-primary); }
.pro .deep-opt .muted { font-size: 12px; line-height: 1.45; }
.pro .deep-opt input {
  -webkit-appearance: none; appearance: none; flex: none; position: relative; width: 34px; height: 18px; margin: 1px 0 0;
  cursor: pointer; border-radius: var(--r-sm); background: var(--surface-3); border: 1px solid var(--border-2);
  transition: background .15s, border-color .15s;
}
.pro .deep-opt input::after {
  content: ""; position: absolute; top: 2px; left: 2px; width: 12px; height: 12px; border-radius: 2px;
  background: var(--text-muted); transition: transform .15s, background .15s;
}
.pro .deep-opt:hover input { border-color: var(--border-3); }
.pro .deep-opt input:checked { background: var(--accent); border-color: var(--accent); }
.pro .deep-opt input:checked::after { transform: translateX(16px); background: var(--accent-ink); }

.pro .more summary { display: flex; align-items: center; gap: 9px; list-style: none; font-size: 12px; color: var(--text-secondary); }
.pro .more summary::-webkit-details-marker { display: none; }
.pro .more summary::before {
  content: ""; width: 5px; height: 5px; margin-left: 2px; border: solid var(--text-muted); border-width: 0 1.5px 1.5px 0;
  transform: rotate(-45deg); transition: transform .15s;
}
.pro .more[open] summary::before { transform: rotate(45deg); }
.pro .more summary:hover { color: var(--text-primary); }
.pro .more .field { margin: 10px 0 0; font-size: 12px; }
.pro .more .field input { width: 96px; }

/* find button: solid gold; while searching it turns dark and fills with gold */
.pro .find-sec { gap: 8px; }
.pro #find {
  width: 100%; flex: none; padding: 11px; border: 1px solid var(--accent); border-radius: var(--r-md);
  background: var(--accent); color: var(--accent-ink); font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
}
.pro #find:hover:not(:disabled) { background: var(--accent-hi); border-color: var(--accent-hi); }
.pro #find:disabled { background: var(--surface-2); border-color: var(--border-2); color: var(--text-primary); }
.pro #find:disabled .lbl { font-weight: 600; letter-spacing: 0.02em; text-transform: none; }
.pro #find .fill { background: linear-gradient(90deg, rgba(212, 175, 106, 0.3), rgba(212, 175, 106, 0.55)); }
.pro #status { margin: 0; font-size: 12px; }
.pro #status:empty { display: none; }

/* result and library lists: flat rows split by hairlines */
.pro .results, .pro #lib-view .sec { gap: 10px; padding: 16px 0 0; border-bottom: 0; }
.pro .results h2, .pro #lib-view h2, .pro #lib-status { padding: 0 18px; }
.pro #lib-status { margin: 0; }
.pro #lib-status:empty { display: none; }
.pro .results:has(.routes:empty) { display: none; }
.pro .routes { gap: 0; }
.pro .route {
  grid-template-columns: 30px minmax(0, 1fr); gap: 3px 8px; padding: 12px 18px 12px 16px;
  background: none; border: 0; border-top: 1px solid var(--border); border-left: 2px solid transparent; border-radius: 0;
  transition: background .12s;
}
.pro .route:last-child { border-bottom: 1px solid var(--border); }
.pro .route:hover { background: var(--surface-2); border-color: var(--border); border-left-color: transparent; }
.pro .route.sel, .pro .route.sel:hover {
  background: linear-gradient(90deg, rgba(212, 175, 106, 0.1), rgba(212, 175, 106, 0.02));
  border-left-color: var(--accent); box-shadow: none;
}
.pro .route:focus-visible { outline-offset: -2px; }
.pro .route .rk { padding-top: 3px; font-size: 12px; font-weight: 600; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.pro .route.sel .rk, .pro .route .rk.star { color: var(--accent); }
.pro .route .name { font-size: 13px; font-weight: 600; }
.pro .route .eff { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; }
.pro .route .eff small { margin-left: 8px; font-size: 11px; font-weight: 500; color: var(--text-muted); }
.pro .route .meta { font-size: 12px; line-height: 1.45; color: var(--text-secondary); }
.pro .route .gemline { gap: 4px 12px; font-size: 11px; }
.pro .route .gemline .key { width: 7px; height: 7px; border-radius: 1px; }
.pro .route .exports { gap: 6px; margin-top: 8px; align-items: center; }
.pro .route .exports .act, .pro .route .exports .button { padding: 4px 10px; line-height: 16px; }
.pro .route .exports .danger { color: var(--critical); }
.pro .route .exports .danger:hover { border-color: rgba(224, 108, 108, 0.6); }
.pro .route .exports .done { color: var(--text-muted); }
.pro .ex-group { display: inline-flex; align-items: stretch; }
.pro .ex-group .ex-label {
  display: flex; align-items: center; padding: 0 8px; font-size: 10px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-muted); background: var(--surface-1); border: 1px solid var(--border-2); border-right: 0;
  border-radius: var(--r-md) 0 0 var(--r-md);
}
.pro .ex-group .button { border-radius: 0; }
.pro .ex-group .button + .button { margin-left: -1px; }
.pro .ex-group .button:last-child { border-radius: 0 var(--r-md) var(--r-md) 0; }
.pro .ex-group .button:hover { position: relative; z-index: 1; }
.pro .inline-form { gap: 6px; margin-top: 8px; }
.pro .inline-form input { flex: 1; border-color: var(--accent); }
.pro .inline-form button { padding: 4px 10px; }
.pro .lib-empty { padding: 4px 18px 16px; font-size: 12px; }

/* stage: route bar, number strip, 3D view, player */
.pro .stage { gap: 0; background: var(--surface-0); }
.pro .stage-top { display: block; overflow: hidden; padding: 0; border: 0; border-bottom: 1px solid var(--border); border-radius: 0; background: var(--surface-1); }
.pro .stage-top[hidden], .pro .player[hidden], .pro .wp-card[hidden], .pro .details[hidden] { display: none; }
.pro .stage-bar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px 20px; min-height: 46px; padding: 8px 18px; }
.pro .rt-title { display: flex; align-items: baseline; gap: 12px; min-width: 0; }
.pro .rt-name { min-width: 0; font-size: 14px; font-weight: 600; }
.pro .rt-sub { flex: none; font-size: 12px; color: var(--text-muted); }
.pro .rt-sub:not(:empty)::before { content: ""; display: inline-block; width: 1px; height: 11px; margin-right: 12px; background: var(--border-2); }
.pro .view-opts { gap: 6px 18px; font-size: 12px; }
.pro .view-opts .check { gap: 7px; margin: 0; color: var(--text-secondary); }
.pro .view-opts .check:hover { color: var(--text-primary); }
.pro .view-opts input[type=checkbox] {
  -webkit-appearance: none; appearance: none; position: relative; flex: none; width: 14px; height: 14px; margin: 0; cursor: pointer;
  background: var(--surface-0); border: 1px solid var(--border-3); border-radius: var(--r-sm);
}
.pro .view-opts input[type=checkbox]:checked { background: var(--accent); border-color: var(--accent); }
.pro .view-opts input[type=checkbox]:checked::after {
  content: ""; position: absolute; left: 4px; top: 1px; width: 4px; height: 8px;
  border: solid var(--accent-ink); border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.pro #overview { padding: 5px 12px; }
/* hairline grid: every cell has a right and bottom line; the strip's -1px margins hide the outer ones */
.pro .rt-stats { display: flex; flex-wrap: wrap; gap: 0; margin: 0 -1px -1px 0; border-top: 1px solid var(--border); }
.pro .stat {
  display: flex; flex: 1 1 auto; flex-direction: column; gap: 3px; padding: 9px 14px 10px; white-space: nowrap;
  font-size: 12px; background: none; border: 0; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); border-radius: 0;
}
.pro .stat .k { font-size: 10px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); }
.pro .stat b { font-size: 16px; font-weight: 600; letter-spacing: -0.01em; color: var(--text-primary); font-variant-numeric: tabular-nums; }
.pro .stat.key b { color: var(--accent-hi); }

.pro .stage .viewport {
  border: 0; border-radius: 0;
  background: radial-gradient(120% 90% at 50% 0%, #161924 0%, #0d0e13 55%, #090a0d 100%);
}
.pro .empty p { font-size: 13px; }
.pro .empty b { color: var(--text-secondary); }
.pro .count { font-size: 11px; }

/* waypoint card and block details over the 3D view */
.pro .wp-card, .pro .details {
  padding: 0; overflow: hidden; font-size: 12px; border-radius: var(--r-lg);
  background: rgba(17, 19, 23, 0.94); border: 1px solid var(--border-2); box-shadow: 0 10px 28px rgba(0, 0, 0, 0.5);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.pro .wp-card h3, .pro .details h3 {
  margin: 0; padding: 9px 12px; font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--accent-hi); background: rgba(255, 255, 255, 0.02); border-bottom: 1px solid var(--border);
}
.pro .wp-card h3 span { font-size: 11px; font-weight: 500; letter-spacing: 0.02em; text-transform: none; color: var(--text-muted); }
.pro .wp-card dl, .pro .details dl { gap: 6px 12px; padding: 10px 12px 11px; }
.pro .wp-card dt, .pro .details dt { color: var(--text-muted); }
.pro .wp-card .place { color: var(--accent-hi); }
.pro .details .close { padding: 0 6px; font-size: 12px; letter-spacing: 0; }

.pro .player {
  gap: 16px; min-height: 50px; padding: 8px 18px; border: 0; border-top: 1px solid var(--border); border-radius: 0;
  background: var(--surface-1);
}
.pro .player-btns { gap: 4px; }
.pro .player-btns button { display: grid; place-items: center; width: 32px; height: 30px; padding: 0; font-size: 16px; line-height: 1; }
.pro .player-btns .play { width: 40px; font-size: 11px; color: var(--accent-ink); background: var(--accent); border-color: var(--accent); }
.pro .player-btns .play:hover { background: var(--accent-hi); border-color: var(--accent-hi); }
.pro .walk-count {
  min-width: 140px; font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-secondary);
}
.pro .track { gap: 2px; height: 24px; }
.pro .track button { height: 6px; border: 0; border-radius: 1px; background: var(--surface-3); box-shadow: none; }
.pro .track button:hover, .pro .track button:focus-visible { height: 12px; background: var(--border-3); }
.pro .track button.done { background: var(--accent-lo); }
.pro .track button.cur { height: 14px; background: var(--accent-hi); box-shadow: none; }

@media (max-width: 1100px) {
  .pro .appbar-keys { display: none; }
}
@media (max-width: 860px) {
  .pro .shell { height: auto; grid-template-rows: 44px auto; }
  .pro .simple { grid-template-columns: 1fr; }
  .pro .left { overflow: visible; border-right: 0; border-bottom: 1px solid var(--border); }
  .pro .seg { position: static; }
  .pro .stat { flex-basis: 33%; border-bottom: 1px solid var(--border); }
  .pro .stage .viewport { min-height: 65vh; }
  .pro .walk-count { min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .pro .chip, .pro .route, .pro button, .pro .deep-opt input, .pro .deep-opt input::after { transition: none; }
}

/* ---- ad slots (hidden unless AdSense is configured, or --ad-preview) and sidebar footer ---- */
.ad[hidden], .pro .ad[hidden] { display: none; }
.pro .ad { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.pro .ad-label { align-self: stretch; font-size: 9.5px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-muted); }
.pro .ad-body { display: flex; align-items: center; justify-content: center; max-width: 100%; overflow: hidden; }
.pro .ad.preview .ad-body {
  font-size: 11px; color: var(--text-muted); border: 1px dashed var(--border-3); border-radius: var(--r-sm);
  background: repeating-linear-gradient(135deg, transparent 0 8px, rgba(255, 255, 255, 0.02) 8px 16px);
}
.pro .ad-side { margin-top: auto; padding: 14px 18px 16px; border-top: 1px solid var(--border); }
.pro .ad-rail { padding: 14px 10px; background: var(--surface-1); border-left: 1px solid var(--border); overflow: hidden; }
.pro.has-rail .simple { grid-template-columns: 340px minmax(0, 1fr) 182px; }
.pro .side-foot {
  display: flex; flex-wrap: wrap; gap: 4px 10px; padding: 12px 18px 16px; border-top: 1px solid var(--border);
  font-size: 11px; line-height: 1.45; color: var(--text-muted);
}
.pro .ad-side[hidden] + .side-foot { margin-top: auto; }
.pro .side-foot a { color: var(--text-secondary); text-decoration: none; }
.pro .side-foot a:hover { color: var(--accent-hi); text-decoration: underline; }
@media (max-width: 1399px) {
  .pro .ad-rail { display: none; }
  .pro.has-rail .simple { grid-template-columns: 340px minmax(0, 1fr); }
}
@media (max-width: 860px) {
  .pro.has-rail .simple { grid-template-columns: 1fr; }
  .pro .ad-side { margin-top: 0; }
}
