/* World Map Stage 2 V14.13.8 — labels, validated fronts, compass and hover travel route */
/* Compatibility marker: World Map Stage 2 V14.13.7 */
/* World Map Stage 2 V14.11.2 — independent diplomacy layers and adjacency-aware palettes */
/* Compatibility: World Map Stage 2 V14.10 — exact capture classification and summaries for allied, enemy and barbarian captures */
/* Compatibility: World Map Stage 2 V14.9 — concise capture/loss summaries with player shares */
/* Compatibility: World Map Stage 2 V14.8 — continuous 14-day conquest history and trustworthy owner state */
/* Compatibility: World Map Stage 2 V14.7.2 — honest final-loss state and exact event moment in tooltip */
/* Compatibility marker: World Map Stage 2 V14.7.1 */
:root {
  --bg: #f2e8cf;
  --paper: #fffaf0;
  --paper-2: #fff8e8;
  --line: #dfcb9b;
  --line-2: #cfb27a;
  --gold: #8f5a16;
  --gold-dark: #5a3f00;
  --text: #4a3820;
  --muted: #806c4d;
  --danger: #922b2b;
  --ok: #4e7b2b;
  --shadow: 0 14px 28px rgba(0,0,0,.28);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; color: var(--text); background: radial-gradient(circle at top, #f9f0dc 0%, var(--bg) 56%, #e6d1a6 100%); }
body { overflow: hidden; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
input, select, textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 10px; background: #fff; color: var(--text);
}
textarea { resize: vertical; }
label { display: block; }
.twmpw-overlay { position: fixed; inset: 0; padding: 18px; display: flex; }
.twmpw-card {
  width: min(1600px, 100%); height: calc(100vh - 36px); margin: auto; display: flex; flex-direction: column;
  background: linear-gradient(180deg, #fffdf7 0%, #fff7e7 100%); border: 1px solid #cfa968; border-radius: 18px; box-shadow: var(--shadow); overflow: hidden;
}
.twmpw-card.is-minimized { height: auto; }
.twmpw-card.is-minimized .twmpw-body { display: none; }
.twmpw-card.is-maximized { width: 100%; height: 100%; border-radius: 0; }
.twmpw-header {
  display: grid; grid-template-columns: minmax(250px, 1fr) minmax(340px, 520px) minmax(420px, max-content);
  gap: 12px; align-items: center; padding: 16px 18px; border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #f4e5c1 0%, #e9d4a1 100%);
}
.twmpw-title { font-size: 29px; font-weight: 800; color: var(--gold-dark); }
.twmpw-sub { margin-top: 4px; font-size: 13px; color: #77602d; }
.twmpw-world-meta { font-size: 12px; color: #654d1d; padding: 0 8px; }
.twmpw-world-meta-title { font-weight: 800; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 4px; }
.twmpw-world-meta-line { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.twmpw-header-actions { display: flex; align-items: center; justify-content: flex-end; gap: 12px; }
.twmpw-header-main-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.twmpw-window-controls { display: flex; gap: 6px; }
.twmpw-win-btn { width: 34px; height: 34px; border: 1px solid #c9b37f; border-radius: 10px; background: rgba(255,255,255,.75); color: var(--gold-dark); }
.twmpw-win-close { color: #7d1d1d; }
.twmpw-body { flex: 1; min-height: 0; display: grid; grid-template-columns: 260px 1fr; }
.twmpw-body.twmpw-sidebar-collapsed { grid-template-columns: 76px 1fr; }
.twmpw-sidebar {
  border-right: 1px solid var(--line); background: linear-gradient(180deg, #f4ead1 0%, #efe2c2 100%);
  display: flex; flex-direction: column; gap: 8px; padding: 14px;
  min-height: 0; overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; scrollbar-gutter: stable;
}
.twmpw-sidebar::-webkit-scrollbar { width: 10px; }
.twmpw-sidebar::-webkit-scrollbar-track { background: rgba(255,255,255,.35); border-radius: 999px; }
.twmpw-sidebar::-webkit-scrollbar-thumb { background: #c6a160; border-radius: 999px; border: 2px solid #f1e4c6; }
.twmpw-sidebar { scrollbar-width: thin; scrollbar-color: #c6a160 rgba(255,255,255,.35); }

.twmpw-main { min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.twmpw-status { padding: 10px 16px; border-bottom: 1px solid var(--line); background: #fff5df; font-size: 13px; color: #6a4c13; }
.twmpw-content { padding: 18px; overflow: auto; min-height: 0; }
.twmpw-content::-webkit-scrollbar { width: 10px; height: 10px; }
.twmpw-content::-webkit-scrollbar-track { background: rgba(255,255,255,.35); border-radius: 999px; }
.twmpw-content::-webkit-scrollbar-thumb { background: #c6a160; border-radius: 999px; border: 2px solid #f1e4c6; }
.twmpw-content { scrollbar-width: thin; scrollbar-color: #c6a160 rgba(255,255,255,.35); }
.twmpw-footer { padding: 14px 18px; border-top: 1px solid var(--line); background: #fbf4e3; display: flex; justify-content: space-between; gap: 12px; }
.twmpw-footer-right { margin-left: auto; display: flex; gap: 8px; }
.twmpw-step {
  display: inline-flex; align-items: center; gap: 8px; width: 100%; text-align: left; border: 1px solid #d3bf95; border-radius: 12px;
  background: #fff9eb; color: var(--gold-dark); font-weight: 700; padding: 11px 12px;
}
.twmpw-step.active { background: linear-gradient(180deg, #aa7424 0%, #8f5a16 100%); color: #fff; border-color: #814d0d; box-shadow: inset 0 1px 0 rgba(255,255,255,.18); }
.twmpw-step-stats, .twmpw-step-diagnostics { margin-top: 8px; }
.twmpw-collapse-btn { justify-content: center; font-size: 18px; }
.twmpw-body.twmpw-sidebar-collapsed .twmpw-step { justify-content: center; }
.twmpw-body.twmpw-sidebar-collapsed .twmpw-step-text { display: none; }
.twmpw-btn {
  border: 1px solid #7d4f13; background: linear-gradient(180deg, #aa7424 0%, #8f5a16 100%); color: #fff; padding: 10px 14px; border-radius: 10px; font-weight: 700;
}
.twmpw-btn-ghost { background: rgba(255,255,255,.72); color: var(--gold-dark); border-color: #c5a56a; }
.twmpw-btn-xs { padding: 6px 10px; font-size: 12px; }
.twmpw-btn[disabled] { opacity: .5; cursor: not-allowed; }
.twmpw-link-danger { background: transparent; border: 0; color: var(--danger); font-weight: 700; }
.twmpw-help { padding: 12px 14px; border: 1px solid #dbc184; border-radius: 12px; background: #fff4d8; color: #624811; line-height: 1.5; }
.twmpw-help-grid { display: grid; gap: 10px; }
.twmpw-help-title { font-weight: 800; color: var(--gold-dark); }
.twmpw-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.top-gap { margin-top: 8px; }
.twmpw-block { margin-top: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); padding: 14px; box-shadow: 0 2px 10px rgba(111,73,18,.06); }
.twmpw-block-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; }
.twmpw-grid2, .twmpw-grid3, .twmpw-grid4 { display: grid; gap: 12px; }
.twmpw-grid2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.twmpw-grid3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.twmpw-grid4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.twmpw-summary { margin-top: 10px; padding: 10px 12px; border-radius: 10px; background: #fff1cf; border: 1px solid #dbc184; color: #6a4d13; }
.twmpw-subhead { margin: 10px 0 8px; font-size: 12px; font-weight: 800; color: var(--gold-dark); text-transform: uppercase; letter-spacing: .04em; }
.twmpw-subhead-inline { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.twmpw-table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.twmpw-coords-table-wrap{height:320px;max-height:320px;overflow-y:auto;overflow-x:hidden}
.twmpw-coords-table-wrap .twmpw-table{width:100%}

.twmpw-table { width: 100%; border-collapse: collapse; min-width: 0; }
.twmpw-table th, .twmpw-table td { padding: 10px 12px; border-bottom: 1px solid #eee1c1; text-align: left; vertical-align: top; }
.twmpw-table th { position: sticky; top: 0; z-index: 1; background: #f7ead0; color: var(--gold-dark); }
.twmpw-result-table-summary{margin-bottom:12px}
.twmpw-result-table-scroll{max-height:520px;overflow-y:auto;overflow-x:hidden}
.twmpw-result-table{table-layout:fixed;font-size:13px}
.twmpw-result-table th,.twmpw-result-table td{white-space:normal;word-break:break-word;overflow-wrap:anywhere;padding:8px 8px;line-height:1.25}
.twmpw-result-table th:nth-child(1),.twmpw-result-table td:nth-child(1){width:4%}
.twmpw-result-table th:nth-child(2),.twmpw-result-table td:nth-child(2){width:6%}
.twmpw-result-table th:nth-child(3),.twmpw-result-table td:nth-child(3){width:8%}
.twmpw-result-table th:nth-child(4),.twmpw-result-table td:nth-child(4){width:12%}
.twmpw-result-table th:nth-child(5),.twmpw-result-table td:nth-child(5),.twmpw-result-table th:nth-child(6),.twmpw-result-table td:nth-child(6){width:10%}
.twmpw-result-table th:nth-child(7),.twmpw-result-table td:nth-child(7){width:4%}
.twmpw-result-table th:nth-child(8),.twmpw-result-table td:nth-child(8),.twmpw-result-table th:nth-child(9),.twmpw-result-table td:nth-child(9){width:8%}
.twmpw-result-table th:nth-child(10),.twmpw-result-table td:nth-child(10),.twmpw-result-table th:nth-child(11),.twmpw-result-table td:nth-child(11){width:8%}
.twmpw-result-table th:nth-child(12),.twmpw-result-table td:nth-child(12){width:7%}
.twmpw-result-table th:last-child,.twmpw-result-table td:last-child{width:7%}
.twmpw-result-table .muted{font-size:11px;line-height:1.2}
.twmpw-result-table .twmpw-btn-xs{padding:4px 6px;font-size:11px;white-space:normal}

.twmpw-chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.twmpw-chip { display: inline-flex; align-items: center; gap: 8px; border-radius: 999px; padding: 6px 10px; background: #fff4d8; border: 1px solid #dcc180; }
.twmpw-inline-check { display: inline-flex; gap: 8px; align-items: center; margin-right: 14px; }
.twmpw-kv { display: grid; grid-template-columns: 180px 1fr; gap: 6px 12px; }
.muted { color: var(--muted); }
.twmpw-tag { display: inline-flex; align-items: center; border-radius: 999px; padding: 4px 8px; background: #f6ecd2; border: 1px solid #dbc184; font-size: 12px; }
.twmpw-toolbar { display: flex; gap: 8px; flex-wrap: wrap; }
.twmpw-filter-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; }
.twmpw-bar-row { display: grid; grid-template-columns: 200px 1fr 70px; gap: 12px; align-items: center; margin-top: 12px; }
.twmpw-bar-track { height: 12px; border-radius: 999px; overflow: hidden; background: #efe2c1; border: 1px solid #dcc180; }
.twmpw-bar-fill { height: 100%; background: linear-gradient(180deg, #aa7424 0%, #8f5a16 100%); }
.twmpw-strategy-card { border: 1px solid #dbc184; border-radius: 12px; background: #fff8e6; padding: 14px; }
.twmpw-strategy-card-title, .twmpw-strategy-name { font-weight: 800; color: var(--gold-dark); }
.twmpw-strategy-name { margin-top: 6px; }
.twmpw-strategy-text { margin-top: 8px; line-height: 1.5; }
.twmpw-strategy-badge { margin-top: 10px; display: inline-flex; padding: 6px 10px; border-radius: 999px; background: #f6ecd2; border: 1px solid #dbc184; }
.twmpw-strategy-chain { margin-top: 14px; display: grid; gap: 10px; }
.twmpw-strategy-step { display: grid; gap: 4px; padding: 10px 12px; border-radius: 10px; background: #fffdf7; border: 1px solid #ead9b0; }
.twmpw-map-toolbar { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.twmpw-map-wrap { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: #fff; }
.twmpw-map { width: 100%; height: 520px; display: block; }
.twmpw-cat-buildings { display: grid; gap: 10px; }
.twmpw-cat-building-card { border: 1px solid #e2cf9c; border-radius: 12px; background: #fffef9; padding: 10px; display: grid; grid-template-columns: 1fr 160px; gap: 12px; }
.twmpw-cat-building-main { display: flex; gap: 10px; align-items: center; }
.twmpw-cat-building-icon { width: 30px; height: 30px; border-radius: 8px; background: linear-gradient(180deg, #e1c88e, #c9a45a); flex: 0 0 auto; }
.twmpw-cat-building-side { display: grid; gap: 6px; }
.twmpw-cat-building-badge { font-size: 12px; color: var(--muted); font-weight: 700; }
.twmpw-render-skip { contain: content; }
.twmpw-sm-backdrop::backdrop { background: rgba(47,34,17,.48); }
.twmpw-sm-modal { width: min(880px, 92vw); border: 1px solid #cfa968; border-radius: 16px; background: linear-gradient(180deg, #fffdf7 0%, #fff7e7 100%); box-shadow: var(--shadow); }
.twmpw-sm-head, .twmpw-sm-actions { padding: 14px 16px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.twmpw-sm-body { padding: 0 16px 16px; }
.twmpw-sm-title { font-size: 18px; font-weight: 800; color: var(--gold-dark); }
.twmpw-hide { display: none !important; }
@media (max-width: 1200px) {
  .twmpw-header { grid-template-columns: 1fr; }
  .twmpw-grid4, .twmpw-grid3, .twmpw-grid2, .twmpw-filter-grid { grid-template-columns: 1fr; }
}


.twmpw-hide{display:none!important}
.twmpw-toolbar{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.twmpw-block.is-collapsed .twmpw-block-body{display:none}
.twmpw-help-box{margin-bottom:14px;position:relative}
.twmpw-help-trigger{border:1px solid #dbc184;background:#fff4d8;color:#624811;border-radius:12px;padding:10px 12px;font-weight:800;width:100%;text-align:left}
.twmpw-help-popup{display:none;margin-top:8px;padding:12px 14px;border:1px solid #dbc184;border-radius:12px;background:#fff4d8;color:#624811;line-height:1.5}
.twmpw-help-popup.is-open{display:block}
.twmpw-validation-box{margin-top:12px;padding:10px 12px;border-radius:10px;background:#fff1cf;border:1px solid #dbc184;color:#6a4d13}
.twmpw-validation-row{margin-bottom:8px}
.twmpw-validation-body{overflow:auto;display:flex;gap:8px;flex-wrap:wrap}
.twmpw-tag-danger{background:#fde8e8;border-color:#d9aaaa;color:#8b2d2d}
.twmpw-tag-ok{background:#e7f4df;border-color:#b6d1a0;color:#355d17}
.twmpw-filter-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.twmpw-map-toolbar,.twmpw-bar-row{display:flex;align-items:center;gap:12px}.twmpw-map-toolbar{margin-bottom:12px;justify-content:space-between;flex-wrap:wrap}
.twmpw-map-wrap{border:1px solid var(--line);border-radius:12px;background:#fff;overflow:hidden}
.twmpw-map{display:block;width:100%;height:auto}
.twmpw-bar-row{margin-bottom:10px}.twmpw-bar-row>div:first-child{width:180px}.twmpw-bar-track{flex:1;height:12px;border-radius:999px;background:#efe3c7;overflow:hidden;border:1px solid #dcc699}.twmpw-bar-fill{height:100%;background:linear-gradient(90deg,#8f5a16,#c69a45)}
.twmpw-strategy-card{border:1px solid var(--line);border-radius:14px;background:linear-gradient(180deg,#fffdf8 0%,#fff8ea 100%);padding:16px;box-shadow:0 2px 10px rgba(111,73,18,.06)}
.twmpw-strategy-card-title{font-size:12px;font-weight:800;color:var(--gold-dark);text-transform:uppercase;letter-spacing:.04em;margin-bottom:8px}.twmpw-strategy-name{font-size:20px;font-weight:800;color:var(--gold-dark);margin-bottom:8px}.twmpw-strategy-text{line-height:1.55;color:#5b4520}.twmpw-strategy-badge{display:inline-flex;margin-top:10px;padding:8px 10px;border-radius:999px;background:#fff1cf;border:1px solid #dbc184;color:#6a4d13;font-weight:700}.twmpw-strategy-chain{display:grid;gap:10px;margin-top:14px}.twmpw-strategy-step{display:grid;gap:4px;padding:10px 12px;border-radius:12px;border:1px solid #e2cfab;background:#fffaf0}
.twmpw-cat-buildings{display:grid;gap:12px}.twmpw-cat-building-card{display:flex;justify-content:space-between;gap:14px;align-items:flex-start;padding:12px;border:1px solid var(--line);border-radius:12px;background:#fffaf0}.twmpw-cat-building-main{display:flex;align-items:center;gap:10px;flex:1}.twmpw-cat-building-icon{width:28px;height:28px;border-radius:8px;background:linear-gradient(180deg,#ead4a7 0%,#d7ba77 100%);border:1px solid #c7a25b}.twmpw-cat-building-side{width:140px}.twmpw-cat-building-badge{display:block;font-size:12px;font-weight:800;color:var(--gold-dark);margin-bottom:6px}.twmpw-cat-building-add{display:flex;flex-direction:column;gap:8px}
@media (max-width:1200px){.twmpw-grid4,.twmpw-filter-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.twmpw-header{grid-template-columns:1fr}.twmpw-header-actions{justify-content:flex-start}.twmpw-world-meta-line{white-space:normal}}
@media (max-width:860px){.twmpw-body{grid-template-columns:1fr}.twmpw-sidebar{border-right:0;border-bottom:1px solid var(--line)}.twmpw-grid3,.twmpw-grid2,.twmpw-grid4,.twmpw-filter-grid{grid-template-columns:1fr}.twmpw-kv{grid-template-columns:1fr}.twmpw-bar-row{flex-direction:column;align-items:flex-start}.twmpw-bar-row>div:first-child{width:auto}}

.twmpw-header-title{display:flex;flex-direction:column;gap:4px}
.twmpw-status-main{display:flex;align-items:center;justify-content:space-between;gap:12px}
.twmpw-status-text{font-weight:700;color:#6d521d}
.twmpw-status-pct{font-weight:800;color:#8f5a16;min-width:48px;text-align:right}
.twmpw-status-bar{margin-top:6px;height:10px;border-radius:999px;background:#efe3c7;overflow:hidden;border:1px solid #dcc699}
.twmpw-status-bar-fill{height:100%;background:linear-gradient(90deg,#8f5a16,#c69a45);transition:width .16s ease}
.twmpw-step-icon{font-size:15px;line-height:1}
.twmpw-unit-select{display:flex;align-items:center;gap:8px}
.twmpw-unit-icon-placeholder{width:24px;height:24px;border-radius:999px;display:inline-flex;align-items:center;justify-content:center;background:#efe3c7;border:1px solid #dcc699;color:#6d521d;font-size:12px}
.twmpw-note{background:#fff7e9;border:1px solid #ead6ae;border-radius:12px;padding:12px 14px;color:#5a4211;line-height:1.45}
.twmpw-note-compact{background:#fff7e9;border:1px solid #ead6ae;border-radius:12px;padding:12px 14px;color:#5a4211;line-height:1.45}
.twmpw-summary-plain{background:transparent;border:0;padding:0;margin-top:8px}
.twmpw-row-actions{display:flex;justify-content:flex-end;margin:10px 0 14px}
.twmpw-subblock{background:#fffdf7;border:1px solid #eadfc1;border-radius:14px;padding:14px;margin-top:14px}
.twmpw-subblock-title{font-weight:800;color:#4b3207;margin-bottom:10px}
.twmpw-spacer{height:12px}
.twmpw-label-row{display:inline-flex;align-items:center;gap:8px}
.twmpw-block-soft{background:#fffdf7;border:1px dashed #dcc699}
.twmpw-cat-settings-left{display:flex;flex-direction:column;gap:8px}
.twmpw-cat-settings-note{font-size:12px;color:#7b653b}
.twmpw-toggle-stack{display:flex;flex-direction:column;gap:10px}
.twmpw-toggle-row{display:flex;align-items:center;justify-content:space-between;gap:12px;border:1px solid #eadfc1;border-radius:12px;padding:10px 12px;background:#fff}
.twmpw-toggle{position:relative;display:inline-flex;align-items:center}
.twmpw-toggle input{position:absolute;opacity:0;pointer-events:none}
.twmpw-toggle-slider{width:42px;height:24px;border-radius:999px;background:#d7c29b;position:relative;display:inline-block;transition:background .16s ease}
.twmpw-toggle-slider::after{content:'';position:absolute;top:3px;left:3px;width:18px;height:18px;border-radius:50%;background:#fff;box-shadow:0 1px 2px rgba(0,0,0,.2);transition:left .16s ease}
.twmpw-toggle input:checked + .twmpw-toggle-slider{background:#8f5a16}
.twmpw-toggle input:checked + .twmpw-toggle-slider::after{left:21px}
.twmpw-coords-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:10px 0 8px}
.twmpw-lazy-block .twmpw-block-body{display:block}
.twmpw-lazy-note{padding:10px 12px;border-top:1px dashed #e0c98b;background:#fff7e4;color:#6d521d;font-size:13px}
.twmpw-warn{display:grid;gap:8px;margin:12px 0;padding:12px 14px;border-radius:12px;background:#fff0d7;border:1px solid #e0bf7d;color:#7a4f12}
.twmpw-tiny-preview{margin:10px 0 14px;padding:10px 12px;border-radius:12px;background:#fffdf7;border:1px dashed #dcc699;color:#6d521d}
.twmpw-link-danger{border:0;background:transparent;color:#9f2d16;font-weight:800}
.twmpw-lazy-block textarea{width:100%;min-height:180px}

body{background:radial-gradient(circle at top,#f5e4be 0%,#ebd09a 28%,#d7b173 58%,#b98c4d 100%);}
.twmpw-card{background:linear-gradient(180deg,#fffaf0 0%,#fff4df 38%,#f8e5bf 100%);border:1px solid #b98a43;box-shadow:0 18px 44px rgba(64,38,9,.28), inset 0 1px 0 rgba(255,255,255,.5);}
.twmpw-header{background:linear-gradient(180deg,#6f4d17 0%,#5b3d10 100%);color:#fff1d2;border-bottom:1px solid #8f6727;}
.twmpw-title,.twmpw-sub,.twmpw-world-meta-title,.twmpw-world-meta-line{color:#fff1d2}
.twmpw-world-meta{background:rgba(255,245,220,.08);border-color:rgba(255,233,182,.24)}
.twmpw-sidebar{background:linear-gradient(180deg,#fff2d4 0%,#f5dfb1 100%)}
.twmpw-step.active{box-shadow:inset 0 0 0 1px #ffd27a, 0 6px 14px rgba(143,90,22,.18)}
.twmpw-block,.twmpw-subblock,.twmpw-note,.twmpw-note-compact,.twmpw-validation-box,.twmpw-warn,.twmpw-help,.twmpw-help-popup{box-shadow:inset 0 1px 0 rgba(255,255,255,.45)}
.twmpw-table thead th{position:sticky;top:0;z-index:1}
.twmpw-btn{box-shadow:inset 0 1px 0 rgba(255,255,255,.45),0 2px 6px rgba(90,56,13,.12)}
.twmpw-row-actions{gap:8px;flex-wrap:wrap}
.twmpw-help.small{font-size:13px}


.twmpw-world-meta{justify-self:center;text-align:center;border-radius:18px;padding:14px 18px}
.twmpw-step{display:flex;align-items:center;gap:10px}
.twmpw-step-num{display:inline-flex;align-items:center;justify-content:center;min-width:28px;width:28px;height:28px;border-radius:999px;background:#ead4a7;border:1px solid #c7a25b;color:#5b3d10;font-weight:800;flex:0 0 28px}
.twmpw-sidebar-collapsed .twmpw-step{justify-content:center;padding-left:8px;padding-right:8px}
.twmpw-sidebar-collapsed .twmpw-step-text{display:none}
.twmpw-sidebar-collapsed .twmpw-step-num{display:inline-flex}
.twmpw-info-btn{margin-left:8px;border:1px solid #d9be83;background:#fff7e4;color:#6d521d;border-radius:999px;width:18px;height:18px;font-size:11px;font-weight:800;line-height:1;cursor:help;display:inline-flex;align-items:center;justify-content:center;user-select:none;flex:0 0 18px;text-transform:none !important;font-variant:normal !important;font-style:normal !important;font-family:Segoe UI,Tahoma,sans-serif !important;}
.twmpw-unit-icon-img{width:24px;height:24px;object-fit:contain}
.twmpw-textarea-top-gap textarea{margin-top:10px}
.twmpw-color-field-wrap{display:flex;align-items:center}
.twmpw-color-square{width:24px;height:24px;border-radius:6px;border:1px solid rgba(0,0,0,.18);box-shadow:inset 0 1px 0 rgba(255,255,255,.35);cursor:pointer;display:inline-block}
.twmpw-color-square-large{width:40px;height:40px;border-radius:10px}
.twmpw-stack{display:grid;gap:14px}
.twmpw-collapsed-line{align-items:center}
.twmpw-collapsed-main{display:flex;align-items:center;gap:10px;flex-wrap:wrap;min-width:0}
.twmpw-collapsed-label{font-weight:800;color:#6d521d}
.twmpw-collapsed-name{font-weight:900}
.twmpw-collapsed-stats{font-weight:800;color:#4b3207;background:#fff4df;border:1px solid #e6c98f;border-radius:999px;padding:4px 10px}
.twmpw-collapsed-unit{display:inline-flex;align-items:center;gap:6px;font-weight:700;color:#5b4520}
.twmpw-collapsed-unit img{width:18px;height:18px;object-fit:contain}
.twmpw-color-popover{margin:12px 0 0;padding:12px;border:1px solid #dcc699;border-radius:12px;background:#fffaf0;box-shadow:0 10px 24px rgba(64,38,9,.12)}
.twmpw-color-popover-title{font-size:12px;font-weight:800;text-transform:uppercase;color:#6d521d;margin-bottom:10px}
.twmpw-color-popover-row{margin-bottom:10px}
.twmpw-color-popover input[type="color"]{width:72px;height:42px;padding:0;border:1px solid #d8bb7f;border-radius:10px;background:#fff;cursor:pointer}
.twmpw-color-presets{display:grid;grid-template-columns:repeat(6,24px);gap:8px}
.twmpw-color-preset{width:24px;height:24px;border-radius:6px;border:1px solid rgba(0,0,0,.18);cursor:pointer}
.twmpw-color-preset.is-active{outline:2px solid #5b3d10;outline-offset:1px}
.twmpw-grid2 > label:first-child{grid-column:span 1}
.twmpw-grid2 input[data-bind="attack-name"]{min-width:320px}

.twmpw-collapsed-name-pill{display:inline-flex;align-items:center;min-height:30px;padding:4px 12px;border-radius:999px;background:color-mix(in srgb, var(--attack-color) 12%, #fff7e4 88%);border:1px solid color-mix(in srgb, var(--attack-color) 38%, #d8bb7f 62%);font-weight:900;box-shadow:inset 0 1px 0 rgba(255,255,255,.45)}
.twmpw-collapsed-unit-pill{display:inline-flex;align-items:center;gap:6px;min-height:30px;padding:4px 12px;border-radius:999px;background:#fff7e4;border:1px solid #e6c98f;font-weight:800;color:#5b4520;box-shadow:inset 0 1px 0 rgba(255,255,255,.45)}
.twmpw-collapsed-unit-pill img{width:18px;height:18px;object-fit:contain}
.twmpw-collapsed-color-square{width:28px;height:28px;border-radius:8px}
.twmpw-color-presets-title{margin:2px 0 8px;font-size:11px;font-weight:800;letter-spacing:.03em;text-transform:uppercase;color:#7a5c24}


.twmpw-step-icon{display:inline-flex;align-items:center;justify-content:center;min-width:28px;width:28px;height:28px;border-radius:999px;background:#ead4a7;border:1px solid #c7a25b;color:#5b3d10;font-size:15px;flex:0 0 28px}
.twmpw-sidebar-collapsed .twmpw-step-plan-map .twmpw-step-icon,.twmpw-sidebar-collapsed .twmpw-step-stats .twmpw-step-icon,.twmpw-sidebar-collapsed .twmpw-step-diagnostics .twmpw-step-icon{display:inline-flex}
.twmpw-sidebar-collapsed .twmpw-step:not(.twmpw-step-stats):not(.twmpw-step-diagnostics) .twmpw-step-num{display:inline-flex}
.twmpw-sidebar-collapsed .twmpw-step .twmpw-step-icon{display:none}
.twmpw-sidebar-collapsed .twmpw-step-stats .twmpw-step-num,.twmpw-sidebar-collapsed .twmpw-step-diagnostics .twmpw-step-num{display:none}
.twmpw-subhead-with-info{display:flex;align-items:center;gap:8px}
.twmpw-info-wrap{position:relative;display:inline-flex;align-items:center}
.twmpw-hover-tooltip{position:absolute;left:50%;top:calc(100% + 8px);transform:translateX(-50%);min-width:220px;max-width:280px;padding:10px 12px;border:1px solid #d9be83;border-radius:12px;background:#fff7e4;color:#624811;line-height:1.45;box-shadow:0 10px 24px rgba(64,38,9,.12);opacity:0;visibility:hidden;pointer-events:none;transition:opacity .14s ease,visibility .14s ease;z-index:30}
.twmpw-hover-tooltip code{background:#fffdf7;border:1px solid #ead6ae;border-radius:6px;padding:1px 4px}
.twmpw-info-btn:hover + .twmpw-hover-tooltip{opacity:1;visibility:visible}
.twmpw-color-square{padding:0;appearance:none;-webkit-appearance:none;flex:0 0 auto}
.twmpw-color-square:focus,.twmpw-color-square:active{transform:none}
.twmpw-color-field-wrap{position:relative;display:inline-flex;align-items:flex-start}
.twmpw-color-popover{position:relative;margin:8px 0 0}
.twmpw-collapsed-line{margin-bottom:0;align-items:center}


.twmpw-color-inline-anchor{position:relative;display:inline-flex;align-items:center;vertical-align:middle;overflow:visible}
.twmpw-color-inline-anchor .twmpw-color-popover{position:absolute;left:calc(100% + 10px);top:50%;transform:translateY(-50%);margin:0;z-index:40;min-width:260px}
.twmpw-color-field-wrap{display:inline-flex;align-items:center;overflow:visible}
.twmpw-color-square,.twmpw-color-square-large,.twmpw-collapsed-color-square{flex:0 0 auto;transform:none !important}

.twmpw-step-svg{width:16px;height:16px;display:block;fill:currentColor}
.twmpw-sidebar-collapsed .twmpw-step-plan-map .twmpw-step-icon,.twmpw-sidebar-collapsed .twmpw-step-stats .twmpw-step-icon,.twmpw-sidebar-collapsed .twmpw-step-diagnostics .twmpw-step-icon{display:inline-flex !important}
.twmpw-sidebar-collapsed .twmpw-step-stats .twmpw-step-num,.twmpw-sidebar-collapsed .twmpw-step-diagnostics .twmpw-step-num{display:none !important}


/* targeted fixes: collapsed spacing + sticky footer */
.twmpw-content{flex:1 1 auto;}
.twmpw-block-collapsed{margin-top:8px;padding-top:10px;padding-bottom:10px;}
.twmpw-block-collapsed .twmpw-block-head{margin-bottom:0;}


.twmpw-region-card .twmpw-block-body{display:grid;gap:14px}
.twmpw-region-header-grid>label:nth-child(2){max-width:74px}
.twmpw-region-type-panel{display:grid;gap:14px;padding:14px 16px}
.twmpw-region-type-section{display:grid;gap:10px}
.twmpw-region-type-section-title{font-size:13px;font-weight:800;text-transform:uppercase;color:#6d521d}
.twmpw-region-type-list{display:flex;flex-wrap:wrap;gap:10px;align-items:flex-start}
.twmpw-region-type-chip{display:inline-flex;align-items:center;gap:10px;padding:8px 12px;border:1px solid #e0c98b;border-radius:999px;background:#fffaf0;max-width:100%}
.twmpw-region-type-chip-main{display:inline-flex;align-items:center;gap:8px;flex-wrap:wrap;min-width:0}
.twmpw-region-type-badge{width:10px;height:10px;border-radius:999px;display:inline-block;box-shadow:0 0 0 1px rgba(0,0,0,.12)}
.twmpw-region-type-name{font-weight:900;color:#5c3910}
.twmpw-region-type-unit{display:inline-flex;align-items:center;gap:6px;padding:3px 9px;border-radius:999px;background:#fff7e4;border:1px solid #e6c98f;font-weight:700;color:#5b4520}
.twmpw-region-type-unit img{width:16px;height:16px;object-fit:contain}
.twmpw-region-type-chip-side{display:inline-flex;align-items:center;gap:8px;flex-wrap:wrap}
.twmpw-region-count-inline{display:inline-flex;align-items:center;gap:8px;margin:0;padding:3px 8px;border-radius:999px;background:#fff7e4;border:1px solid #e6c98f}
.twmpw-region-count-inline span{font-size:12px;font-weight:700;color:#6d521d;white-space:nowrap}
.twmpw-region-count-inline input{width:56px;min-width:56px;padding:5px 8px;border-radius:999px;text-align:center}
.twmpw-region-count-inline{display:flex;align-items:center;gap:8px;color:#6d521d;font-size:13px;font-weight:700}
.twmpw-region-count-inline input{width:80px}
.twmpw-region-type-add-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:10px}
.twmpw-region-type-add{display:grid;gap:4px;text-align:left;padding:12px 14px;border:1px dashed #d7bb7b;border-radius:14px;background:#fffdf6;color:#68481a;cursor:pointer}
.twmpw-region-type-add:hover{background:#fff8e8}
.twmpw-region-type-add-name{font-weight:800}
.twmpw-region-type-add-meta{font-size:12px;color:#876631}


.twmpw-region-collapsed-types{display:inline-flex;align-items:center;gap:8px;flex-wrap:wrap}
.twmpw-region-type-pill{display:inline-flex;align-items:center;gap:6px;min-height:30px;padding:4px 12px;border-radius:999px;background:color-mix(in srgb, var(--attack-color) 12%, #fff7e4 88%);border:1px solid color-mix(in srgb, var(--attack-color) 38%, #d8bb7f 62%);font-weight:800;color:#5b4520;box-shadow:inset 0 1px 0 rgba(255,255,255,.45)}
.twmpw-region-type-pill-dot{width:10px;height:10px;border-radius:999px;display:inline-block;box-shadow:0 0 0 1px rgba(255,255,255,.6) inset}
.twmpw-region-collapsed-empty{display:inline-flex;align-items:center;min-height:30px;padding:4px 12px;border-radius:999px;background:#fff7e4;border:1px solid #e6c98f;font-weight:700;color:#8a6a32}


.twmpw-cat-source-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) 280px;gap:16px;align-items:start}
.twmpw-cat-source-col{display:flex;flex-direction:column;gap:8px}
.twmpw-cat-source-side{display:flex;align-items:flex-start}
.twmpw-toggle-row-tall{min-height:100%;width:100%;padding:16px 14px}
.twmpw-cat-buildings-picker{display:flex;flex-direction:column;gap:12px}
.twmpw-cat-buildings-toolbar{display:flex;flex-wrap:wrap;gap:10px}
.twmpw-building-choice{display:inline-flex;align-items:center;gap:8px;padding:8px 10px;border-radius:12px;border:1px solid #d8c18c;background:#fffaf0;color:var(--gold-dark);font-weight:800;cursor:pointer}
.twmpw-building-choice.is-active{background:#f2e0b7;border-color:#b78a37;box-shadow:inset 0 0 0 1px rgba(255,255,255,.45)}
.twmpw-building-choice-icon{width:22px;height:22px;border-radius:6px;flex:0 0 22px}
.twmpw-cat-buildings-list{display:grid;gap:10px}
.twmpw-cat-building-name{font-weight:800;color:#6f5320}
@media (max-width: 1200px){.twmpw-cat-source-grid{grid-template-columns:1fr}.twmpw-cat-source-side{max-width:420px}}


/* step3 targeted layout */
.twmpw-cat-source-top-line{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.twmpw-cat-source-top-toggle{max-width:540px;flex:0 0 auto}
.twmpw-cat-source-grid-two{grid-template-columns:1fr 1fr}
.twmpw-cat-buildings-list-pills{display:flex;flex-wrap:wrap;gap:12px}
.twmpw-cat-building-pill{display:flex;align-items:center;justify-content:space-between;gap:14px;min-width:260px;max-width:340px;padding:14px 16px}
.twmpw-cat-building-text{display:flex;flex-direction:column;gap:4px}
.twmpw-cat-building-side-inline{width:auto;min-width:72px}
.twmpw-cat-building-side-inline input{width:72px;text-align:center}
.twmpw-label-row{display:inline-flex;align-items:center;gap:8px;flex-wrap:wrap}
@media (max-width: 1180px){.twmpw-cat-source-grid-two{grid-template-columns:1fr}}

.twmpw-hover-tooltip{font-family:Segoe UI,Tahoma,sans-serif !important;font-size:16px !important;font-weight:400 !important;font-style:normal !important;line-height:1.45 !important;text-transform:none !important;letter-spacing:normal !important;color:#624811 !important;}
.twmpw-hover-tooltip *{font-family:Segoe UI,Tahoma,sans-serif !important;font-size:16px !important;font-weight:400 !important;font-style:normal !important;line-height:1.45 !important;text-transform:none !important;letter-spacing:normal !important;color:#624811 !important;}
.twmpw-hover-tooltip b,.twmpw-hover-tooltip strong{font-weight:800 !important;}
.twmpw-hover-tooltip br{content:"";}
.twmpw-hover-tooltip code{font-family:Consolas,Monaco,monospace !important;font-size:15px !important;}
.twmpw-hover-tooltip .twmpw-tooltip-html,.twmpw-hover-tooltip .twmpw-tooltip-html *{display:initial;}
.twmpw-hover-tooltip .twmpw-tooltip-title{display:block;font-weight:800 !important;margin-bottom:4px;color:#624811 !important;}

.twmpw-toggle-row-with-actions{gap:16px;align-items:center}
.twmpw-toggle-row-right{display:flex;align-items:center;gap:10px;margin-left:auto;flex-wrap:wrap;justify-content:flex-end}
.twmpw-inline-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.twmpw-btn-icon{display:inline-flex;align-items:center;justify-content:center;margin-right:6px}
.twmpw-inline-modal-backdrop{position:fixed;inset:0;background:rgba(34,22,4,.18);display:flex;align-items:center;justify-content:center;padding:24px;z-index:80}
.twmpw-inline-modal{width:min(760px,92vw);border:1px solid #cfa968;border-radius:18px;background:linear-gradient(180deg,#fffdf7 0%,#fff7e7 100%);box-shadow:0 28px 60px rgba(73,45,2,.18);overflow:hidden}
.twmpw-inline-modal-head{display:flex;justify-content:space-between;align-items:center;padding:16px 18px;border-bottom:1px solid #eadbb6;background:#fff8ea}
.twmpw-inline-modal-title{font-weight:800;color:#6f4a0b;font-size:22px}
.twmpw-inline-modal-body{padding:18px}
.twmpw-bbtime-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.twmpw-bbtime-col{border:1px solid #e4d2aa;border-radius:14px;background:#fff;padding:14px;display:flex;flex-direction:column;gap:12px}
.twmpw-bbtime-col label{display:flex;flex-direction:column;gap:6px}
.twmpw-input-label{font-weight:700;color:#7b5719}
.twmpw-quick-presets{display:flex;gap:8px;flex-wrap:wrap}
.twmpw-inline-modal-actions{display:flex;justify-content:flex-end;gap:10px}
.twmpw-cat-source-top-toggle{max-width:540px;flex:0 0 auto}
.twmpw-bbtime-modal input{font-size:18px;letter-spacing:.02em}
@media (max-width: 900px){.twmpw-bbtime-grid{grid-template-columns:1fr}.twmpw-toggle-row-right{justify-content:flex-start}}


.twmpw-cat-region-arrive-row{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.twmpw-help-inline-note{margin:0;flex:1 1 320px}
.twmpw-cat-source-top-line .twmpw-inline-actions{margin-left:auto}
.twmpw-bbtime-modal input[type="datetime-local"]{min-height:44px}


.twmpw-cat-timewindows{display:flex;flex-direction:column;gap:10px;margin-top:8px}
.twmpw-timewindow-list{display:flex;flex-direction:column;gap:10px}
.twmpw-timewindow-card{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:12px 14px;border:1px solid #d7bb79;border-radius:14px;background:#f4ead1}
.twmpw-timewindow-title{font-weight:800;color:#6d4a11;min-width:70px}
.twmpw-timewindow-grid{display:flex;flex-direction:column;gap:4px;flex:1;color:#6a4e23}

.twmpw-help-error{background:#fff0ea;border-color:#d38b6d;color:#8a3f25;font-weight:700}

.twmpw-modal-x{width:38px;height:38px;border:1px solid #d4b16f;border-radius:12px;background:#fff7ea;color:#7a520d;font-size:26px;line-height:1;font-weight:700;display:inline-flex;align-items:center;justify-content:center;box-shadow:0 2px 8px rgba(122,82,13,.14);cursor:pointer}.twmpw-modal-x:hover{background:#fff1d3}


.twmpw-btn-prominent{
  min-height: 48px;
  padding: 12px 18px;
  font-size: 15px;
  font-weight: 800;
  border-radius: 14px;
  box-shadow: 0 8px 18px rgba(122,80,13,.10);
}
.twmpw-cat-region-arrive-row .twmpw-btn-prominent{
  align-self:flex-start;
}


.twmpw-help-spaced{ margin-bottom:12px; }
.twmpw-towers-toggle-row{
  display:grid;
  grid-template-columns:minmax(260px,.88fr) minmax(420px,1.12fr);
  gap:14px;
  align-items:stretch;
}
.twmpw-towers-toggle-item .twmpw-toggle-row{
  margin:0;
  min-height:56px;
}
.twmpw-towers-toggle-item{ min-width:0; }
.twmpw-towers-toggle-item:last-child .twmpw-label-row{
  flex-wrap:nowrap;
}
@media (max-width: 900px){
  .twmpw-towers-toggle-row{ grid-template-columns:1fr; }
  .twmpw-towers-toggle-item:last-child .twmpw-label-row{ flex-wrap:wrap; }
}


.twmpw-window-list{display:flex;flex-direction:column;gap:8px}
.twmpw-pair-group-row td{background:#f7edd8;font-weight:800;color:#6a4a14}
.twmpw-sm-backdrop{position:fixed;inset:0;border:none;padding:24px;background:transparent;z-index:1000;display:none;align-items:center;justify-content:center;max-width:none;max-height:none}
.twmpw-sm-backdrop[open]{display:flex}
.twmpw-sm-actions{justify-content:flex-end}
.twmpw-sm-modal{max-height:min(84vh,960px);overflow:auto;width:min(1100px,94vw)}
.twmpw-sm-body{padding:0 20px 20px}
.twmpw-sm-head,.twmpw-sm-actions{padding:16px 20px}


/* step 5 targeted spacing and window modal */
.twmpw-step5{display:grid;gap:18px}
.twmpw-step5>.twmpw-block:first-child{display:grid;gap:18px}
.twmpw-step5 .twmpw-block,.twmpw-step5 .twmpw-subblock{margin-top:0}
.twmpw-step5 .twmpw-subblock{padding:18px}
.twmpw-step5 .twmpw-subblock-title{margin-bottom:14px}
.twmpw-step5 .twmpw-grid2{row-gap:18px;column-gap:14px;align-items:start}
.twmpw-step5 .twmpw-grid2>label,.twmpw-step5 .twmpw-field-stack{display:grid;gap:8px;align-content:start}
.twmpw-step5 .twmpw-note-compact,.twmpw-step5 .twmpw-help,.twmpw-step5 .twmpw-help.small{margin-top:6px;margin-bottom:6px}
.twmpw-step5 .twmpw-row-actions{margin:0}
.twmpw-step5-help-card{align-self:stretch;display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:6px}.twmpw-step5-help-card b{display:block}.twmpw-step5-help-card span{display:block;line-height:1.5}.twmpw-step5-inline-warning,.twmpw-step5-inline-success{margin-top:8px}.twmpw-step5-inline-success{color:var(--success);font-weight:700}.twmpw-step5-warning-text{color:var(--danger);font-weight:700}
.twmpw-toggle-row-soft{background:#fffdf7;border-color:#eadfc1}
.twmpw-pair-link-wrap{min-width:260px}
.twmpw-window-launch{display:grid;gap:8px;align-content:start}
.twmpw-window-launch.is-compact .twmpw-help{margin:0}
.twmpw-window-pair-buttons{display:grid;gap:10px;min-width:220px}
.twmpw-window-pair-single{min-width:260px}
.twmpw-window-pair-single .twmpw-btn{justify-self:start}
.twmpw-timewindow-list-compact{gap:8px}
.twmpw-timewindow-card-compact{padding:10px 12px}
.twmpw-window-modal-stack{gap:16px}
.twmpw-window-modal-col{min-width:0}
.twmpw-window-modal-list{display:grid;gap:12px;min-width:0}
.twmpw-window-modal-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto;gap:12px;align-items:end;padding:12px 14px;border:1px solid #eadfc1;border-radius:14px;background:#fffdf7;min-width:0}
.twmpw-window-modal-row>*{min-width:0}
.twmpw-window-modal-row label{display:grid;gap:6px;min-width:0}
.twmpw-window-modal-row input{min-width:0}
.twmpw-window-modal-row .twmpw-btn{align-self:end;white-space:nowrap}
.twmpw-window-modal-toolbar{display:flex;justify-content:flex-start;padding-top:4px}
@media (max-width: 980px){
  .twmpw-window-modal-row{grid-template-columns:1fr}
  .twmpw-pair-link-wrap{min-width:0}
  .twmpw-window-pair-buttons,.twmpw-window-pair-single{min-width:0}
}


.twmpw-step6{display:grid;gap:14px}
.twmpw-step6 .twmpw-row{align-items:flex-start}
.twmpw-step6 .twmpw-summary{flex:1;min-width:320px}
.twmpw-step6 .twmpw-row-actions{margin:0;justify-content:flex-end}
.twmpw-unit-cell{display:inline-flex;align-items:center;gap:8px;white-space:nowrap}
.twmpw-unit-icon{width:20px;height:20px;object-fit:contain;flex:0 0 20px}
.twmpw-map-shell{display:grid;gap:10px}
.twmpw-virtual-map-panel{display:grid;gap:14px}
.twmpw-virtual-map-top{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:10px}
.twmpw-virtual-metric{display:grid;gap:6px;padding:12px 14px;border:1px solid #eadfc1;border-radius:14px;background:#fffdf7}
.twmpw-virtual-metric span{font-size:12px;color:#6a5427}
.twmpw-virtual-metric b{font-size:18px;color:#5a3f00}
.twmpw-virtual-map-layout{display:grid;grid-template-columns:minmax(0,1.7fr) minmax(260px,.9fr);gap:14px;align-items:start}
.twmpw-virtual-map-main,.twmpw-virtual-side-card{display:grid;gap:10px;padding:12px 14px;border:1px solid #eadfc1;border-radius:14px;background:#fffdf7}
.twmpw-virtual-map-main-full{width:100%;grid-column:1/-1}
.twmpw-virtual-map-caption{display:grid;gap:4px;color:#5f4b20}
.twmpw-virtual-map-caption span{font-size:12px;line-height:1.45;color:#6a5427}
.twmpw-virtual-map-side{display:grid;gap:12px}
.twmpw-virtual-side-title{font-weight:700;color:#5a3f00}
.twmpw-virtual-chip-wrap{display:flex;flex-wrap:wrap;gap:8px}
.twmpw-virtual-stat-list{display:grid;gap:8px}
.twmpw-virtual-stat-row{display:flex;justify-content:space-between;gap:12px;padding:8px 0;border-bottom:1px dashed #e4d5b4;color:#5f4b20}
.twmpw-virtual-stat-row:last-child{border-bottom:0;padding-bottom:0}
.twmpw-quick-preview-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px}
.twmpw-quick-preview-card{display:grid;gap:10px;padding:12px 14px;border:1px solid #eadfc1;border-radius:14px;background:#fffdf7}
.twmpw-quick-preview-head{display:flex;justify-content:space-between;gap:10px;align-items:center}
.twmpw-quick-preview-index{display:inline-flex;align-items:center;justify-content:center;min-width:34px;height:26px;padding:0 8px;border-radius:999px;background:#fff4d8;border:1px solid #dcc699;color:#5a3f00;font-weight:700}
.twmpw-quick-preview-type{font-weight:700;text-align:right}
.twmpw-quick-preview-route{display:flex;gap:8px;align-items:center;flex-wrap:wrap;color:#5a3f00}
.twmpw-quick-preview-meta{display:flex;justify-content:space-between;gap:10px;flex-wrap:wrap;font-size:12px;color:#6a5427}
.twmpw-quick-preview-times{display:grid;gap:8px}
.twmpw-quick-preview-times div{display:grid;gap:2px;padding:8px 10px;border-radius:10px;background:#fff7e5;border:1px solid #eadfc1}
.twmpw-quick-preview-times span,.twmpw-quick-preview-risk{font-size:12px;color:#6a5427}
.twmpw-quick-preview-times b,.twmpw-quick-preview-risk b{color:#5a3f00}
.twmpw-step6 textarea[readonly]{min-height:220px;background:#fffdf7}
.twmpw-step6 .twmpw-toggle-row{margin-top:10px}
@media (max-width: 980px){
  .twmpw-virtual-map-layout{grid-template-columns:1fr}
}

.twmpw-world-modal{max-width:760px}
.twmpw-sm-backdrop-open{display:flex}
.twmpw-sm-body input[data-bind="world-url"]{width:100%;margin-top:8px}
.twmpw-header-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px}
.twmpw-header-main-actions{display:flex;flex-wrap:wrap;gap:10px;justify-content:flex-end}

.twmpw-diag-list{display:grid;grid-template-columns:1fr;gap:8px;padding:12px}.twmpw-diag-list-row{display:flex;justify-content:space-between;gap:12px;border-bottom:1px solid rgba(151,103,29,.18);padding-bottom:6px}.twmpw-diag-list-row span{color:#7a5420}.twmpw-diag-list-row b{text-align:right;word-break:break-word}.twmpw-note-active{outline:2px solid rgba(170,111,24,.35)}

@media (max-width: 1100px){
.twmpw-result-table{font-size:12px}
.twmpw-result-table th,.twmpw-result-table td{padding:6px 6px}
.twmpw-result-table .muted{font-size:10px}
.twmpw-result-table .twmpw-unit-cell{gap:4px}
.twmpw-result-table .twmpw-unit-icon{width:14px;height:14px}
}

.twmpw-step6-stack{display:grid;gap:14px}
.twmpw-step6-stack .twmpw-help{margin:0}


.twmpw-server-job-card{border:1px solid var(--line);border-radius:14px;padding:12px 14px;background:#fbf4df;display:grid;gap:10px;margin-bottom:2px}
.twmpw-server-job-card.is-running{background:#fbf4df}
.twmpw-server-job-card.is-completed{background:#f3f8ea}
.twmpw-server-job-card.is-failed{background:#fff0ea}
.twmpw-server-job-head{font-size:14px;line-height:1.4}
.twmpw-server-job-bar{height:12px;border-radius:999px;background:#ead9b6;overflow:hidden}
.twmpw-server-job-bar-fill{height:100%;border-radius:999px;background:linear-gradient(90deg,#b8781f,#d5a146);transition:width .25s ease}
.twmpw-server-job-card.is-completed .twmpw-server-job-bar-fill{background:linear-gradient(90deg,#6a9d2f,#8cc64a)}
.twmpw-server-job-card.is-failed .twmpw-server-job-bar-fill{background:linear-gradient(90deg,#ba5e38,#dd8b61)}
.twmpw-server-job-meta{display:grid;gap:4px;font-size:13px;color:var(--muted)}

.twmpw-debug-log{background:#1f1f1f;color:#f3f3f3;padding:12px;border-radius:10px;max-height:260px;overflow:auto;white-space:pre-wrap;font:12px/1.45 ui-monospace,SFMono-Regular,Consolas,monospace;}

input[disabled], select[disabled], textarea[disabled]{cursor:not-allowed;opacity:.7}

.twmpw-boot-block{min-height:220px}
.twmpw-boot-loader{width:42px;height:42px;border-radius:50%;border:4px solid rgba(151,103,29,.16);border-top-color:#a96f18;animation:twmpw-spin 1s linear infinite;margin:4px 0 10px}
@keyframes twmpw-spin{to{transform:rotate(360deg)}}


.twmpw-sm-modal-explain{max-height:min(86vh,980px);overflow:hidden;display:flex;flex-direction:column}
.twmpw-sm-body-explain{padding:0 20px 20px;overflow:hidden;display:flex;flex-direction:column;gap:10px;min-height:0}
.twmpw-modal-table-scroll{max-height:52vh;min-height:180px;height:52vh;overflow-y:auto;overflow-x:auto;flex:1 1 auto;display:block}.twmpw-modal-table-scroll::-webkit-scrollbar{width:12px;height:12px}


.twmpw-collapsible{display:flex;flex-direction:column;min-width:0;height:100%}
.twmpw-collapsible-head{margin-bottom:10px;font-weight:800;color:#6d4a11}
.twmpw-collapsible-body{min-height:0;min-width:0}
.twmpw-collapsible-scroll{min-height:0;min-width:0;overflow:auto;max-height:100%}
.twmpw-stats-mini-block{min-width:0}
.twmpw-stats-table-wrap{height:100%;max-height:100%;overflow:auto}
.twmpw-stats-table-wrap .twmpw-table{min-width:0;width:100%}
.twmpw-stats-mini-block{margin-top:16px;margin-bottom:16px}
.twmpw-stats-mini-block .twmpw-block-head{margin-bottom:0}
.twmpw-stats-mini-block .twmpw-block-body{padding-top:12px}
.twmpw-stats-mini-table-wrap{max-height:360px;overflow:auto}
.twmpw-stats-mini-table-wrap .twmpw-table thead th{position:sticky;top:0;z-index:2}

.twmpw-grid2>.twmpw-stats-mini-block,.twmpw-grid2>.twmpw-block{min-width:0}

.twmpw-cat-settings-block{margin-top:8px}
.twmpw-cat-settings-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px;align-items:start}
.twmpw-cat-settings-left,.twmpw-cat-settings-right{display:flex;flex-direction:column;gap:12px}
.twmpw-cat-settings-note{margin:0}
@media (max-width: 900px){.twmpw-cat-settings-grid{grid-template-columns:1fr}}

.twmpw-step5-main-strategy-label .twmpw-label-row{display:flex;margin-bottom:8px;}

.twmpw-global-loader{position:fixed;inset:0;background:rgba(58,40,14,.28);display:flex;align-items:center;justify-content:center;z-index:9999;padding:20px}
.twmpw-global-loader-card{width:min(520px,calc(100vw - 32px));background:linear-gradient(180deg,#fffdf7 0%,#fff4df 100%);border:1px solid #cfa968;border-radius:18px;box-shadow:var(--shadow);padding:22px;display:grid;gap:12px;text-align:center}
.twmpw-global-loader-title{font-size:22px;font-weight:800;color:var(--gold-dark)}
.twmpw-global-loader-text{color:#6a4c13;line-height:1.45}
.twmpw-global-loader-progress{font-weight:800;color:var(--gold-dark)}

/* TWMP admin world catalog final fix 2026-05-01 */
#worldCatalog.twmpw-admin-world-list,
.twmpw-admin-pane #worldCatalog.twmpw-admin-world-list{
  max-height:420px!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  padding-right:6px!important;
}

#worldCatalog .twmpw-admin-world-card,
.twmpw-admin-pane #worldCatalog .twmpw-admin-world-card{
  display:grid!important;
  grid-template-columns:1fr!important;
  gap:10px!important;
  align-items:start!important;
  padding:12px!important;
  min-width:0!important;
  width:100%!important;
  overflow:hidden!important;
}

#worldCatalog .twmpw-admin-world-meta,
#worldCatalog .twmpw-admin-world-meta b,
#worldCatalog .twmpw-admin-muted{
  min-width:0!important;
  white-space:normal!important;
  word-break:break-word!important;
  overflow-wrap:anywhere!important;
}

#worldCatalog .twmpw-admin-world-actions,
.twmpw-admin-pane #worldCatalog .twmpw-admin-world-actions{
  display:grid!important;
  grid-template-columns:1fr 1fr!important;
  gap:8px!important;
  align-items:stretch!important;
  justify-content:stretch!important;
  width:100%!important;
  min-width:0!important;
  overflow:visible!important;
}

#worldCatalog .twmpw-admin-world-actions label,
.twmpw-admin-pane #worldCatalog .twmpw-admin-world-actions label{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:7px!important;
  min-width:0!important;
  min-height:36px!important;
  width:100%!important;
  margin:0!important;
  padding:6px 8px!important;
  border:1px solid #ead7af!important;
  border-radius:10px!important;
  background:#fffdf7!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}

#worldCatalog .twmpw-admin-world-actions input[type="checkbox"]{
  width:16px!important;
  height:16px!important;
  min-width:16px!important;
  margin:0!important;
  padding:0!important;
  flex:0 0 16px!important;
  appearance:auto!important;
  -webkit-appearance:checkbox!important;
  accent-color:#8b5c0b!important;
}

#worldCatalog .twmpw-admin-world-actions .twmpw-btn,
#worldCatalog .twmpw-admin-world-actions .twmpw-icon-btn,
.twmpw-admin-pane #worldCatalog .twmpw-admin-world-actions .twmpw-btn,
.twmpw-admin-pane #worldCatalog .twmpw-admin-world-actions .twmpw-icon-btn{
  width:100%!important;
  min-width:0!important;
  height:38px!important;
  min-height:38px!important;
  padding:8px 10px!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}

#worldCatalog .twmpw-admin-world-actions [data-act="save-world-flags"]{
  grid-column:1 / -1!important;
}

@media (max-width:760px){
  #worldCatalog .twmpw-admin-world-actions,
  .twmpw-admin-pane #worldCatalog .twmpw-admin-world-actions{
    grid-template-columns:1fr!important;
  }
}

/* TWMP hotfix: Userscript Center admin spacing */
.twmpw-userscript-center,
.twmpw-admin-userscripts,
.twmpw-userscripts-admin,
#twmpwUserscriptCenter,
[data-admin-section="userscripts"],
[data-tab-panel="userscripts"] {
  box-sizing: border-box !important;
  padding: 22px 24px 34px !important;
}

.twmpw-userscript-center > *,
.twmpw-admin-userscripts > *,
.twmpw-userscripts-admin > *,
#twmpwUserscriptCenter > *,
[data-admin-section="userscripts"] > *,
[data-tab-panel="userscripts"] > * {
  max-width: 100%;
}

.twmpw-userscript-center h1,
.twmpw-userscript-center h2,
.twmpw-userscript-center h3,
.twmpw-admin-userscripts h1,
.twmpw-admin-userscripts h2,
.twmpw-admin-userscripts h3,
.twmpw-userscripts-admin h1,
.twmpw-userscripts-admin h2,
.twmpw-userscripts-admin h3,
#twmpwUserscriptCenter h1,
#twmpwUserscriptCenter h2,
#twmpwUserscriptCenter h3 {
  margin-top: 0 !important;
  margin-bottom: 14px !important;
}

.twmpw-userscript-center .twmpw-admin-card,
.twmpw-userscript-center .twmpw-admin-block,
.twmpw-userscript-center .twmpw-admin-table-wrap,
.twmpw-admin-userscripts .twmpw-admin-card,
.twmpw-admin-userscripts .twmpw-admin-block,
.twmpw-admin-userscripts .twmpw-admin-table-wrap,
.twmpw-userscripts-admin .twmpw-admin-card,
.twmpw-userscripts-admin .twmpw-admin-block,
.twmpw-userscripts-admin .twmpw-admin-table-wrap,
#twmpwUserscriptCenter .twmpw-admin-card,
#twmpwUserscriptCenter .twmpw-admin-block,
#twmpwUserscriptCenter .twmpw-admin-table-wrap {
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.twmpw-userscript-center table,
.twmpw-admin-userscripts table,
.twmpw-userscripts-admin table,
#twmpwUserscriptCenter table {
  width: 100% !important;
}

/* TWMP V205 VISUAL MAP STEP START */
.twmpw-visual-map-step .twmpw-block-head{gap:10px;align-items:center;}
.twmpw-visual-toolbar{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;}
.twmpw-visual-toggle{width:auto;min-width:260px;margin:0;}
.twmpw-visual-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(340px,520px);gap:12px;align-items:start;min-width:0;}
.twmpw-visual-map-card{border:1px solid #d8bf88;border-radius:14px;background:#fff8e8;padding:10px;min-width:0;}
.twmpw-visual-map-scroll{height:min(62vh,620px);min-height:380px;overflow:hidden;border:1px solid rgba(95,64,16,.22);border-radius:12px;background:linear-gradient(90deg, rgba(120,84,25,.08) 1px, transparent 1px),linear-gradient(0deg, rgba(120,84,25,.08) 1px, transparent 1px),#fffdf7;background-size:28px 28px;}
.twmpw-visual-svg{display:block;width:100%;height:100%;min-width:0;min-height:0;}
.twmpw-visual-svg circle{vector-effect:non-scaling-stroke;}
.twmpw-vm-attack{stroke:#fff;stroke-width:.45;}
.twmpw-vm-region{stroke:#1c1202;stroke-width:.35;opacity:.88;}
.twmpw-visual-side{min-width:0;max-height:min(72vh,760px);overflow-y:auto;overflow-x:hidden;padding-right:2px;}
.twmpw-visual-layer{border:1px solid rgba(120,84,25,.18);border-radius:12px;background:#fffdf7;padding:8px 10px;}
.twmpw-visual-layer summary{cursor:pointer;display:flex;align-items:center;gap:8px;min-width:0;}
.twmpw-color-dot{display:inline-block;width:12px;height:12px;border-radius:999px;border:1px solid rgba(0,0,0,.25);box-shadow:0 1px 2px rgba(0,0,0,.14);flex:0 0 auto;}
.twmpw-visual-coords-scroll{max-height:220px;overflow-y:auto;overflow-x:hidden;margin-top:8px;}
.twmpw-visual-coords-scroll table{width:100%;border-collapse:collapse;table-layout:fixed;}
.twmpw-visual-coords-scroll td{padding:5px 4px;border-bottom:1px solid rgba(120,84,25,.12);vertical-align:middle;}
.twmpw-visual-coords-scroll td:first-child{width:42%;}.twmpw-visual-coords-scroll td:last-child{text-align:right;}
.twmpw-visual-map-step textarea[data-role="visual-map-reserve"]{width:100%;box-sizing:border-box;}
@media (max-width:1100px){.twmpw-visual-grid{grid-template-columns:1fr}.twmpw-visual-map-scroll{height:440px}.twmpw-visual-side{max-height:none}.twmpw-visual-svg{min-width:0;min-height:0}}
/* TWMP V205 VISUAL MAP STEP END */

/* v206 visual map selection/layer controls */
.twmpw-visual-svg{cursor:crosshair;user-select:none;touch-action:none;}
.twmpw-visual-select-rect{fill:rgba(40,95,180,.12);stroke:#285fb4;stroke-width:.55;stroke-dasharray:2 1;vector-effect:non-scaling-stroke;pointer-events:none;}
.twmpw-vm-selected{fill:none;stroke:#111;stroke-width:.75;vector-effect:non-scaling-stroke;pointer-events:none;}
.twmpw-visual-layer-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:6px;}
.twmpw-visual-layer-toggle{width:100%;margin:0;justify-content:flex-start;gap:8px;min-width:0;}
.twmpw-visual-layer-toggle b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.twmpw-visual-layer summary{justify-content:space-between;border-top:1px solid rgba(120,84,25,.12);padding-top:6px;margin-top:4px;}
.twmpw-visual-row-selected td{background:rgba(40,95,180,.10);}
.twmpw-visual-help{font-size:12px;color:#6f4d16;margin-top:6px;line-height:1.35;}
.twmpw-visual-side select[data-role="visual-map-select-mode"],
.twmpw-visual-side select[data-role="visual-map-target-layer"]{width:100%;}

/* v207 visual map selected state and group filtering */
.twmpw-vm-selected-halo{fill:rgba(255,255,255,.82);stroke:#111;stroke-width:1.15;vector-effect:non-scaling-stroke;pointer-events:none;filter:drop-shadow(0 0 2px rgba(0,0,0,.35));}
.twmpw-vm-selected{fill:rgba(40,95,180,.34);stroke:#fff;stroke-width:.55;vector-effect:non-scaling-stroke;pointer-events:none;}
.twmpw-visual-selected-groups{border:1px solid rgba(120,84,25,.18);border-radius:12px;background:#fffdf7;padding:8px;display:flex;flex-direction:column;gap:6px;}
.twmpw-visual-selected-group{display:grid;grid-template-columns:18px 14px minmax(0,1fr) auto;align-items:center;gap:8px;padding:5px 6px;border-radius:9px;background:rgba(120,84,25,.055);}
.twmpw-visual-selected-group input{margin:0;}
.twmpw-visual-selected-group span:nth-child(3){overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.twmpw-visual-selected-preview{display:flex;flex-wrap:wrap;gap:6px;max-height:132px;overflow:auto;}
.twmpw-visual-selected-chip{display:inline-flex;align-items:center;gap:5px;border:1px solid rgba(120,84,25,.20);border-radius:999px;background:#fff8e8;padding:4px 8px;font-size:12px;}
.twmpw-visual-canvas-wrap{position:relative;width:100%;height:100%;min-width:0;min-height:0;}
.twmpw-visual-canvas{display:block;width:100%;height:100%;cursor:crosshair;user-select:none;touch-action:none;}
.twmpw-visual-select-box{position:absolute;border:1px dashed #285fb4;background:rgba(40,95,180,.12);pointer-events:none;border-radius:3px;}
@media (max-width:1100px){.twmpw-visual-canvas-wrap{min-width:0;min-height:0}}

.twmpw-vm-row-actions{display:flex;align-items:center;justify-content:flex-end;gap:6px;flex-wrap:wrap;min-width:0;}
.twmpw-vm-row-actions .twmpw-btn{margin:0;}
.twmpw-vm-coord-meta{display:flex;align-items:center;gap:7px;min-width:0;flex-wrap:wrap;}
.twmpw-vm-coord-meta code{flex:0 0 auto;}
.twmpw-vm-owner{display:inline-flex;align-items:center;gap:4px;min-width:0;max-width:100%;font-size:11px;color:#6f4d16;vertical-align:middle;}
.twmpw-vm-owner span:first-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:115px;}
.twmpw-vm-owner span:last-child{display:inline-flex;align-items:center;border:1px solid rgba(120,84,25,.22);border-radius:999px;padding:1px 5px;background:#fff8e8;color:#5f4010;max-width:64px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.twmpw-visual-selected-chip{max-width:100%;white-space:normal;overflow-wrap:anywhere;}
.twmpw-visual-selected-chip .twmpw-vm-owner{margin-left:2px;}
.twmpw-vm-continent{font-size:32px;font-weight:800;fill:rgba(120,84,25,.105);stroke:rgba(255,255,255,.55);stroke-width:.8;text-anchor:middle;dominant-baseline:middle;user-select:none;pointer-events:none;}
.twmpw-visual-map-step .twmpw-row-actions{gap:8px;}

/* TWMP V210 visual map zoom/fullscreen polish */
.twmpw-visual-toolbar-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;flex-wrap:wrap;min-width:0;}
.twmpw-visual-zoom-controls{display:inline-flex;align-items:center;gap:6px;flex-wrap:wrap;min-width:0;}
.twmpw-visual-zoom-controls .twmpw-btn{min-width:34px;padding-left:10px;padding-right:10px;}
.twmpw-visual-zoom-label{display:inline-flex;align-items:center;justify-content:center;min-width:56px;padding:6px 9px;border:1px solid rgba(120,84,25,.22);border-radius:10px;background:#fff8e8;color:#5f4010;font-weight:800;font-size:12px;}
.twmpw-visual-map-fullscreen{position:fixed;inset:10px;z-index:100000;background:#fff8e8;border:1px solid #d8bf88;border-radius:16px;box-shadow:0 18px 55px rgba(0,0,0,.36);margin:0!important;padding:12px;display:flex;flex-direction:column;overflow:hidden;}
.twmpw-visual-map-fullscreen>.twmpw-block-head{flex:0 0 auto;}
.twmpw-visual-map-fullscreen>.twmpw-block-body{flex:1 1 auto;min-height:0;overflow:hidden;display:flex;flex-direction:column;gap:10px;}
.twmpw-visual-map-fullscreen .twmpw-note{flex:0 0 auto;margin:0;}
.twmpw-visual-map-fullscreen .twmpw-visual-toolbar{flex:0 0 auto;}
.twmpw-visual-map-fullscreen .twmpw-visual-grid{flex:1 1 auto;min-height:0;grid-template-columns:minmax(0,1fr) minmax(360px,500px);align-items:stretch;}
.twmpw-visual-map-fullscreen .twmpw-visual-map-card{display:flex;flex-direction:column;min-height:0;}
.twmpw-visual-map-fullscreen .twmpw-visual-map-scroll{flex:1 1 auto;height:auto;min-height:0;}
.twmpw-visual-map-fullscreen .twmpw-visual-side{height:100%;max-height:none;overflow:auto;padding-right:4px;}
.twmpw-visual-map-fullscreen .twmpw-visual-help{margin-bottom:0;}
@media (max-width:1100px){.twmpw-visual-map-fullscreen{inset:6px;padding:10px;overflow:auto}.twmpw-visual-map-fullscreen>.twmpw-block-body{overflow:visible}.twmpw-visual-map-fullscreen .twmpw-visual-grid{grid-template-columns:1fr}.twmpw-visual-map-fullscreen .twmpw-visual-map-scroll{height:60vh;min-height:360px}.twmpw-visual-map-fullscreen .twmpw-visual-side{height:auto;max-height:none}}

/* TWMP V211 visual map zoom/pan fix */
.twmpw-visual-svg,
.twmpw-visual-canvas{cursor:crosshair;}
.twmpw-visual-map-step .twmpw-visual-map-scroll{overscroll-behavior:contain;}
.twmpw-visual-map-step .twmpw-visual-svg[data-zoom]:not([data-zoom="1.00"]),
.twmpw-visual-map-step .twmpw-visual-canvas[data-zoom]:not([data-zoom="1.00"]){cursor:grab;}
.twmpw-visual-map-step .twmpw-visual-map-panning{cursor:grabbing!important;}

/* TWMP V217 visual map adaptive canvas zoom/cursor fix */
.twmpw-visual-map-step.twmpw-visual-map-shift-selection .twmpw-visual-svg[data-zoom]:not([data-zoom="1.00"]),
.twmpw-visual-map-step.twmpw-visual-map-shift-selection .twmpw-visual-canvas[data-zoom]:not([data-zoom="1.00"]){cursor:crosshair!important;}

/* v218: visual map of the calculated plan */
.twmpw-plan-map-step .twmpw-visual-toolbar{align-items:center;gap:12px;flex-wrap:wrap}
.twmpw-pvm-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(340px,420px);gap:14px;align-items:stretch;min-width:0}
.twmpw-pvm-map-card,.twmpw-pvm-side{min-width:0}
.twmpw-pvm-canvas-wrap{position:relative;width:100%;height:min(64vh,620px);min-height:430px;border:1px solid #dec89c;border-radius:14px;overflow:hidden;background:#fffaf0;box-shadow:inset 0 1px 0 rgba(255,255,255,.65)}
.twmpw-pvm-canvas{display:block;width:100%;height:100%;cursor:crosshair;touch-action:none}
.twmpw-pvm-panning .twmpw-pvm-canvas{cursor:grab}
.twmpw-pvm-select-rect{position:absolute;border:1px solid #1d4ed8;background:rgba(29,78,216,.12);pointer-events:none;border-radius:4px;box-shadow:0 0 0 1px rgba(255,255,255,.78) inset}
.twmpw-pvm-tooltip{position:absolute;z-index:5;max-width:280px;padding:9px 11px;border-radius:12px;background:rgba(36,24,7,.94);color:#fff;font-size:12px;line-height:1.38;box-shadow:0 10px 24px rgba(0,0,0,.25);pointer-events:none}
.twmpw-pvm-side .twmpw-block-body{min-width:0}
.twmpw-pvm-active-card{border:1px solid #eadbb6;border-radius:12px;background:#fffaf0;padding:10px;display:grid;gap:8px}
.twmpw-pvm-selected-list{display:grid;gap:6px;max-height:260px;overflow:auto;overflow-x:hidden;padding-right:2px}
.twmpw-pvm-selected-row{display:grid;gap:2px;border:1px solid #eadbb6;border-radius:10px;background:#fffdf7;padding:7px 9px;min-width:0}
.twmpw-pvm-selected-row b,.twmpw-pvm-selected-row span{white-space:normal;overflow-wrap:anywhere}
@media (max-width: 980px){.twmpw-pvm-grid{grid-template-columns:1fr}.twmpw-pvm-canvas-wrap{height:460px;min-height:360px}}


/* TWMP V219 visual plan map fullscreen polish */
.twmpw-pvm-fullscreen{position:fixed;inset:10px;z-index:100000;background:#fff8e8;border:1px solid #d8bf88;border-radius:16px;box-shadow:0 18px 55px rgba(0,0,0,.36);margin:0!important;padding:12px;display:flex;flex-direction:column;overflow:hidden}
.twmpw-pvm-fullscreen>.twmpw-block-head{flex:0 0 auto}
.twmpw-pvm-fullscreen>.twmpw-block-body{flex:1 1 auto;min-height:0;overflow:hidden;display:flex;flex-direction:column;gap:10px}
.twmpw-pvm-fullscreen .twmpw-note{flex:0 0 auto;margin:0}
.twmpw-pvm-fullscreen .twmpw-visual-toolbar{flex:0 0 auto}
.twmpw-pvm-fullscreen .twmpw-pvm-grid{flex:1 1 auto;min-height:0;grid-template-columns:minmax(0,1fr) minmax(360px,500px);align-items:stretch}
.twmpw-pvm-fullscreen .twmpw-pvm-map-card{display:flex;flex-direction:column;min-height:0}
.twmpw-pvm-fullscreen .twmpw-pvm-canvas-wrap{flex:1 1 auto;height:auto;min-height:0}
.twmpw-pvm-fullscreen .twmpw-pvm-side{height:100%;max-height:none;overflow:auto;padding-right:4px}
.twmpw-pvm-fullscreen .twmpw-visual-help{margin-bottom:0}
@media (max-width:1100px){.twmpw-pvm-fullscreen{inset:6px;padding:10px;overflow:auto}.twmpw-pvm-fullscreen>.twmpw-block-body{overflow:visible}.twmpw-pvm-fullscreen .twmpw-pvm-grid{grid-template-columns:1fr}.twmpw-pvm-fullscreen .twmpw-pvm-canvas-wrap{height:60vh;min-height:360px}.twmpw-pvm-fullscreen .twmpw-pvm-side{height:auto;max-height:none}}


/* v223 visual plan map deterministic selection fixed */
/* v222 visual plan map selection links fixed */
.twmpw-pvm-link-toggles{display:grid;gap:8px;margin-top:8px;min-width:0}
.twmpw-pvm-link-toggle-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:8px;min-width:0;max-height:168px;overflow:auto;padding:2px}
.twmpw-pvm-link-toggle{min-width:0;gap:10px;align-items:center}
.twmpw-pvm-link-toggle>span:first-child{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:11px;color:#5f4417}
.twmpw-plan-map-step.twmpw-pvm-shift-selection .twmpw-pvm-canvas{cursor:crosshair!important}
.twmpw-pvm-route-dragging .twmpw-pvm-canvas{cursor:move!important}
.twmpw-pvm-fullscreen .twmpw-pvm-link-toggle-list{max-height:128px}

/* v224 visual plan map selection no reset and pan priority fixed */

/* v225 visual plan map is visible before result with collapsed icon */


/* v237 visual plan map context target/tower bypass polish */
.twmpw-pvm-selected-links{margin-bottom:10px;}
.twmpw-pvm-context-menu{position:absolute;z-index:8;min-width:170px;padding:6px;border:1px solid #d5b879;border-radius:12px;background:#fffaf0;box-shadow:0 10px 26px rgba(0,0,0,.22);}
.twmpw-pvm-context-menu .twmpw-btn{width:100%;justify-content:flex-start;text-align:left;}
.twmpw-plan-map-step.twmpw-pvm-target-pick .twmpw-pvm-canvas{cursor:crosshair!important;}
.twmpw-pvm-target-hint{position:absolute;left:12px;top:12px;z-index:6;padding:7px 10px;border-radius:999px;background:rgba(36,24,7,.86);color:#fff;font-size:12px;pointer-events:none;}

/* TWMP CHURCH ZONE V285 */
.twmpw-church-zone-step .twmpw-block-body{gap:14px}
.twmpw-church-zone-step .twmpw-church-zone-settings{align-items:end;row-gap:12px;column-gap:14px}
.twmpw-church-zone-step .twmpw-field-stack{display:grid;gap:8px;align-content:start}
.twmpw-church-zone-step .twmpw-input-label{display:inline-flex;align-items:center;gap:6px;margin-bottom:0}
.twmpw-church-zone-step .twmpw-church-zone-toggle{min-height:52px;height:52px;margin:0;align-self:end;box-sizing:border-box}
.twmpw-church-zone-step textarea{min-height:132px}
.twmpw-church-zone-step .twmpw-summary{margin:0}
.twmpw-church-zone-table-card .twmpw-block-body{padding-top:10px}
.twmpw-church-zone-table{min-width:720px}
.twmpw-church-zone-table th,.twmpw-church-zone-table td{padding:8px 10px;vertical-align:middle}
.twmpw-church-zone-table td:first-child,.twmpw-church-zone-table th:first-child{width:42px;text-align:center}
.twmpw-church-zone-table .twmpw-badge{display:inline-flex;align-items:center;border-radius:999px;padding:2px 8px;font-size:12px;font-weight:800;border:1px solid #eadfc1;background:#fff7df;color:#6f4b0a;white-space:nowrap}
.twmpw-church-zone-table .twmpw-badge.ok{background:#eef8e9;color:#2f6b22;border-color:#cfe7c3}
.twmpw-church-zone-table .twmpw-badge.warn{background:#fff1d8;color:#8a4b00;border-color:#f0d0a0}

/* TWMP CHURCH ZONE V286 */
.twmpw-church-zone-step .twmpw-block-body{gap:14px}
.twmpw-church-zone-step .twmpw-church-zone-settings{align-items:end;row-gap:12px;column-gap:14px}
.twmpw-church-zone-step .twmpw-field-stack{display:grid;gap:8px;align-content:start}
.twmpw-church-zone-step .twmpw-input-label{display:inline-flex;align-items:center;gap:6px;margin-bottom:0}
.twmpw-church-zone-step .twmpw-church-zone-toggle{min-height:52px;height:52px;margin:0;align-self:end;box-sizing:border-box}
.twmpw-church-zone-step textarea{min-height:132px}
.twmpw-church-zone-step .twmpw-summary{margin:0}
.twmpw-church-zone-table-card .twmpw-block-body{padding-top:10px}
.twmpw-church-zone-table{min-width:720px}
.twmpw-church-zone-table th,.twmpw-church-zone-table td{padding:8px 10px;vertical-align:middle}
.twmpw-church-zone-table td:first-child,.twmpw-church-zone-table th:first-child{width:42px;text-align:center}
.twmpw-church-zone-table .twmpw-badge{display:inline-flex;align-items:center;border-radius:999px;padding:2px 8px;font-size:12px;font-weight:800;border:1px solid #eadfc1;background:#fff7df;color:#6f4b0a;white-space:nowrap}
.twmpw-church-zone-table .twmpw-badge.ok{background:#eef8e9;color:#2f6b22;border-color:#cfe7c3}
.twmpw-church-zone-table .twmpw-badge.warn{background:#fff1d8;color:#8a4b00;border-color:#f0d0a0}

/* TWMP CHURCH ZONE V287 */
.twmpw-church-zone-step .twmpw-block-body{gap:14px}
.twmpw-church-zone-step .twmpw-church-zone-settings{align-items:end;row-gap:12px;column-gap:14px}
.twmpw-church-zone-step .twmpw-field-stack{display:grid;gap:8px;align-content:start}
.twmpw-church-zone-step .twmpw-input-label{display:inline-flex;align-items:center;gap:6px;margin-bottom:0}
.twmpw-church-zone-step .twmpw-church-zone-toggle{min-height:52px;height:52px;margin:0;align-self:end;box-sizing:border-box}
.twmpw-church-zone-step textarea{min-height:132px}
.twmpw-church-zone-step .twmpw-summary{margin:0}
.twmpw-church-zone-table-card .twmpw-block-body{padding-top:10px}
.twmpw-church-zone-table{min-width:720px}
.twmpw-church-zone-table th,.twmpw-church-zone-table td{padding:8px 10px;vertical-align:middle}
.twmpw-church-zone-table td:first-child,.twmpw-church-zone-table th:first-child{width:42px;text-align:center}
.twmpw-church-zone-table .twmpw-badge{display:inline-flex;align-items:center;border-radius:999px;padding:2px 8px;font-size:12px;font-weight:800;border:1px solid #eadfc1;background:#fff7df;color:#6f4b0a;white-space:nowrap}
.twmpw-church-zone-table .twmpw-badge.ok{background:#eef8e9;color:#2f6b22;border-color:#cfe7c3}
.twmpw-church-zone-table .twmpw-badge.warn{background:#fff1d8;color:#8a4b00;border-color:#f0d0a0}

/* TWMP CHURCH ZONE V288 */
.twmpw-church-zone-step .twmpw-block-body{gap:14px}
.twmpw-church-zone-step .twmpw-church-zone-settings{align-items:end;row-gap:12px;column-gap:14px}
.twmpw-church-zone-step .twmpw-field-stack{display:grid;gap:8px;align-content:start}
.twmpw-church-zone-step .twmpw-input-label{display:inline-flex;align-items:center;gap:6px;margin-bottom:0}
.twmpw-church-zone-step .twmpw-church-zone-toggle{min-height:52px;height:52px;margin:0;align-self:end;box-sizing:border-box}
.twmpw-church-zone-step textarea{min-height:132px}
.twmpw-church-zone-step .twmpw-summary{margin:0}
.twmpw-church-zone-table-card .twmpw-block-body{padding-top:10px}
.twmpw-church-zone-table{min-width:720px}
.twmpw-church-zone-table th,.twmpw-church-zone-table td{padding:8px 10px;vertical-align:middle}
.twmpw-church-zone-table td:first-child,.twmpw-church-zone-table th:first-child{width:42px;text-align:center}
.twmpw-church-zone-table .twmpw-badge{display:inline-flex;align-items:center;border-radius:999px;padding:2px 8px;font-size:12px;font-weight:800;border:1px solid #eadfc1;background:#fff7df;color:#6f4b0a;white-space:nowrap}
.twmpw-church-zone-table .twmpw-badge.ok{background:#eef8e9;color:#2f6b22;border-color:#cfe7c3}
.twmpw-church-zone-table .twmpw-badge.warn{background:#fff1d8;color:#8a4b00;border-color:#f0d0a0}

/* TWMP CHURCH ZONE V289 */
.twmpw-church-zone-step .twmpw-block-body{gap:14px}
.twmpw-church-zone-step .twmpw-church-zone-settings{align-items:end;row-gap:12px;column-gap:14px}
.twmpw-church-zone-step .twmpw-field-stack{display:grid;gap:8px;align-content:start}
.twmpw-church-zone-step .twmpw-input-label{display:inline-flex;align-items:center;gap:6px;margin-bottom:0}
.twmpw-church-zone-step .twmpw-church-zone-toggle{min-height:52px;height:52px;margin:0;align-self:end;box-sizing:border-box}
.twmpw-church-zone-step textarea{min-height:132px}
.twmpw-church-zone-step .twmpw-summary{margin:0}
.twmpw-church-zone-table-card .twmpw-block-body{padding-top:10px}
.twmpw-church-zone-table{min-width:720px}
.twmpw-church-zone-table th,.twmpw-church-zone-table td{padding:8px 10px;vertical-align:middle}
.twmpw-church-zone-table td:first-child,.twmpw-church-zone-table th:first-child{width:42px;text-align:center}
.twmpw-church-zone-table .twmpw-badge{display:inline-flex;align-items:center;border-radius:999px;padding:2px 8px;font-size:12px;font-weight:800;border:1px solid #eadfc1;background:#fff7df;color:#6f4b0a;white-space:nowrap}
.twmpw-church-zone-table .twmpw-badge.ok{background:#eef8e9;color:#2f6b22;border-color:#cfe7c3}
.twmpw-church-zone-table .twmpw-badge.warn{background:#fff1d8;color:#8a4b00;border-color:#f0d0a0}

/* TWMP CHURCH ZONE V290 */
.twmpw-church-zone-step .twmpw-block-body{gap:14px}
.twmpw-church-zone-step .twmpw-church-zone-settings{align-items:end;row-gap:12px;column-gap:14px}
.twmpw-church-zone-step .twmpw-field-stack{display:grid;gap:8px;align-content:start}
.twmpw-church-zone-step .twmpw-input-label{display:inline-flex;align-items:center;gap:6px;margin-bottom:0}
.twmpw-church-zone-step .twmpw-church-zone-toggle{min-height:52px;height:52px;margin:0;align-self:end;box-sizing:border-box}
.twmpw-church-zone-step textarea{min-height:132px}
.twmpw-church-zone-step .twmpw-summary{margin:0}
.twmpw-church-zone-table-card .twmpw-block-body{padding-top:10px}
.twmpw-church-zone-table{min-width:720px}
.twmpw-church-zone-table th,.twmpw-church-zone-table td{padding:8px 10px;vertical-align:middle}
.twmpw-church-zone-table td:first-child,.twmpw-church-zone-table th:first-child{width:42px;text-align:center}
.twmpw-church-zone-table .twmpw-badge{display:inline-flex;align-items:center;border-radius:999px;padding:2px 8px;font-size:12px;font-weight:800;border:1px solid #eadfc1;background:#fff7df;color:#6f4b0a;white-space:nowrap}
.twmpw-church-zone-table .twmpw-badge.ok{background:#eef8e9;color:#2f6b22;border-color:#cfe7c3}
.twmpw-church-zone-table .twmpw-badge.warn{background:#fff1d8;color:#8a4b00;border-color:#f0d0a0}

/* TWMP CHURCH ZONE V291 */
.twmpw-church-zone-step .twmpw-block-body{gap:14px}
.twmpw-church-zone-step .twmpw-church-zone-settings{align-items:end;row-gap:12px;column-gap:14px}
.twmpw-church-zone-step .twmpw-field-stack{display:grid;gap:8px;align-content:start}
.twmpw-church-zone-step .twmpw-input-label{display:inline-flex;align-items:center;gap:6px;margin-bottom:0}
.twmpw-church-zone-step .twmpw-church-zone-toggle{min-height:52px;height:52px;margin:0;align-self:end;box-sizing:border-box}
.twmpw-church-zone-step textarea{min-height:132px}
.twmpw-church-zone-step .twmpw-summary{margin:0}
.twmpw-church-zone-table-card .twmpw-block-body{padding-top:10px}
.twmpw-church-zone-table{min-width:720px}
.twmpw-church-zone-table th,.twmpw-church-zone-table td{padding:8px 10px;vertical-align:middle}
.twmpw-church-zone-table td:first-child,.twmpw-church-zone-table th:first-child{width:42px;text-align:center}
.twmpw-church-zone-table .twmpw-badge{display:inline-flex;align-items:center;border-radius:999px;padding:2px 8px;font-size:12px;font-weight:800;border:1px solid #eadfc1;background:#fff7df;color:#6f4b0a;white-space:nowrap}
.twmpw-church-zone-table .twmpw-badge.ok{background:#eef8e9;color:#2f6b22;border-color:#cfe7c3}
.twmpw-church-zone-table .twmpw-badge.warn{background:#fff1d8;color:#8a4b00;border-color:#f0d0a0}
.twmpw-church-zone-settings-panel{margin-top:14px}
.twmpw-church-zone-settings-panel .twmpw-block-body{gap:12px}
.twmpw-church-zone-calc-grid{align-items:end;gap:14px}
.twmpw-church-zone-settings-panel .twmpw-field-stack{display:grid;gap:8px}
.twmpw-church-zone-unknown-toggle{min-height:52px;height:52px;align-self:end;margin:0;box-sizing:border-box}
.twmpw-church-zone-settings-panel select{min-height:38px}

/* TWMP CHURCH ZONE V292 ALIGN FIX */
.twmpw-church-zone-settings-panel .twmpw-church-zone-calc-grid{display:grid!important;grid-template-columns:minmax(280px,1fr) minmax(280px,1fr);align-items:end!important;gap:14px!important}
.twmpw-church-zone-settings-panel .twmpw-field-stack{display:grid!important;gap:8px!important;align-content:start!important;margin:0!important}
.twmpw-church-zone-settings-panel .twmpw-field-stack .twmpw-input-label{display:inline-flex!important;align-items:center!important;gap:6px!important;margin:0!important;line-height:1.2!important}
.twmpw-church-zone-settings-panel .twmpw-field-stack select{height:42px!important;min-height:42px!important;box-sizing:border-box!important}
.twmpw-church-zone-settings-panel .twmpw-church-zone-unknown-toggle{display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:space-between!important;gap:12px!important;height:42px!important;min-height:42px!important;margin:0!important;padding:0 12px!important;box-sizing:border-box!important;align-self:end!important;width:100%!important;overflow:visible!important}
.twmpw-church-zone-unknown-toggle>.twmpw-label-row{display:inline-flex!important;align-items:center!important;gap:6px!important;min-width:0!important;line-height:1.2!important;margin:0!important;flex:1 1 auto!important;white-space:normal!important}
.twmpw-church-zone-unknown-toggle>.twmpw-toggle{flex:0 0 auto!important;margin-left:auto!important;align-self:center!important;display:inline-flex!important;align-items:center!important;justify-content:center!important}
@media (max-width: 820px){.twmpw-church-zone-settings-panel .twmpw-church-zone-calc-grid{grid-template-columns:1fr!important}.twmpw-church-zone-settings-panel .twmpw-church-zone-unknown-toggle{align-self:stretch!important}}

/* v303: compact and readable data validation modal */
.twmpw-validation-report{display:grid;gap:14px}
.twmpw-validation-hero{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;padding:14px 16px;border-radius:16px;border:1px solid #e4cf9f;background:#fff8e8;box-shadow:inset 0 1px 0 rgba(255,255,255,.55)}
.twmpw-validation-hero b{display:block;font-size:16px;color:#5b3f00;margin-bottom:4px}
.twmpw-validation-hero span{color:#6b5427;line-height:1.45}
.twmpw-validation-hero>span{flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;min-width:42px;min-height:30px;padding:3px 10px;border-radius:999px;font-weight:900;border:1px solid #e1c587;background:#fff1cf;color:#6a4d13}
.twmpw-validation-hero.is-ok{background:#f5faed;border-color:#cfe5bd}.twmpw-validation-hero.is-ok>span{background:#eef8e9;border-color:#cfe7c3;color:#2f6b22}
.twmpw-validation-hero.is-warn{background:#fff4df;border-color:#e6c98f}.twmpw-validation-hero.is-warn>span{background:#fff1d8;border-color:#f0d0a0;color:#8a4b00}
.twmpw-validation-card{display:grid;gap:10px;padding:14px 16px;border-radius:16px;border:1px solid #e4cf9f;background:#fffaf0;box-shadow:inset 0 1px 0 rgba(255,255,255,.55)}
.twmpw-validation-card.is-ok{background:#fbfff6;border-color:#d3e7c5}.twmpw-validation-card.is-warn{background:#fff8eb;border-color:#e7c990}
.twmpw-validation-card-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.twmpw-validation-card-head b{display:block;color:#5b3f00}.twmpw-validation-card-head span{display:block;color:#7a6030;font-size:12px;margin-top:2px}
.twmpw-validation-status{display:inline-flex!important;align-items:center;justify-content:center;min-height:24px;padding:2px 9px;border-radius:999px;border:1px solid #e1c587;background:#fff1cf;color:#6a4d13!important;font-size:12px!important;font-weight:900;white-space:nowrap}
.twmpw-validation-card.is-ok .twmpw-validation-status{background:#eef8e9;border-color:#cfe7c3;color:#2f6b22!important}.twmpw-validation-card.is-warn .twmpw-validation-status{background:#fff1d8;border-color:#f0d0a0;color:#8a4b00!important}
.twmpw-validation-card-title{font-weight:900;color:#4d3600}.twmpw-validation-card-text{color:#675126;line-height:1.45}.twmpw-validation-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
.twmpw-validation-metrics>div{display:grid;gap:2px;padding:9px 10px;border-radius:12px;background:rgba(255,255,255,.62);border:1px solid rgba(210,177,112,.45)}
.twmpw-validation-metrics span{font-size:12px;color:#7a6030}.twmpw-validation-metrics b{font-size:15px;color:#4d3600}.twmpw-validation-main-metrics{grid-template-columns:repeat(4,minmax(0,1fr))}
.twmpw-validation-samples{padding:9px 10px;border-radius:12px;background:#fff4dc;border:1px dashed #e4c384;color:#6a4d13;line-height:1.45}
.twmpw-validation-list{display:grid;gap:8px}.twmpw-validation-list>div{padding:9px 10px;border-radius:12px;background:#fffdfa;border:1px solid #eadfc1;color:#5b4520;line-height:1.4}
.twmpw-validation-scroll{max-height:300px;overflow-y:auto;overflow-x:auto;margin-top:2px}
@media (max-width: 760px){.twmpw-validation-hero,.twmpw-validation-card-head{flex-direction:column}.twmpw-validation-metrics,.twmpw-validation-main-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}}

.twmpw-validation-conflict-summary{display:grid;gap:10px;padding:12px;border-radius:14px;background:rgba(255,255,255,.55);border:1px solid rgba(210,177,112,.42)}
.twmpw-validation-conflict-metrics{grid-template-columns:repeat(4,minmax(0,1fr))}
.twmpw-validation-conflict-list{display:grid;gap:10px}
.twmpw-validation-conflict-group{display:grid;gap:8px;padding:10px;border-radius:13px;background:#fffdfa;border:1px solid #eadfc1}
.twmpw-validation-conflict-title{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}
.twmpw-validation-conflict-title b{color:#5b3f00}.twmpw-validation-conflict-title span{font-size:12px;color:#7a6030;white-space:nowrap}
.twmpw-validation-conflict-columns{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.twmpw-validation-conflict-label{font-size:12px;font-weight:900;color:#6a4d13;margin-bottom:5px}
.twmpw-validation-chiplist{display:flex;flex-wrap:wrap;gap:6px}
.twmpw-validation-chip{display:inline-flex;align-items:center;gap:5px;max-width:100%;padding:5px 8px;border-radius:999px;background:#fff4dc;border:1px solid #e6c98f;color:#5b3f00;line-height:1.15}
.twmpw-validation-chip b{font-size:12px}.twmpw-validation-chip small{font-size:11px;color:#765b28;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:190px}.twmpw-validation-chip.is-more{font-size:12px;font-weight:900;background:#fffaf0}
@media (max-width: 760px){.twmpw-validation-conflict-columns{grid-template-columns:1fr}.twmpw-validation-conflict-title{flex-direction:column}.twmpw-validation-conflict-title span{white-space:normal}.twmpw-validation-conflict-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* v304: unified scrollbars for validation and project modals */
.twmpw-sm-modal,
.twmpw-sm-body,
.twmpw-validation-scroll,
.twmpw-modal-table-scroll,
#projectDialog .twmpw-sm-body,
#projectDialog .twmpw-project-table-wrap,
#projectDialog .twmpw-project-history{
  scrollbar-width: thin;
  scrollbar-color: #c6a160 rgba(255,255,255,.35);
}
.twmpw-sm-modal::-webkit-scrollbar,
.twmpw-sm-body::-webkit-scrollbar,
.twmpw-validation-scroll::-webkit-scrollbar,
.twmpw-modal-table-scroll::-webkit-scrollbar,
#projectDialog .twmpw-sm-body::-webkit-scrollbar,
#projectDialog .twmpw-project-table-wrap::-webkit-scrollbar,
#projectDialog .twmpw-project-history::-webkit-scrollbar{
  width:10px;
  height:10px;
}
.twmpw-sm-modal::-webkit-scrollbar-track,
.twmpw-sm-body::-webkit-scrollbar-track,
.twmpw-validation-scroll::-webkit-scrollbar-track,
.twmpw-modal-table-scroll::-webkit-scrollbar-track,
#projectDialog .twmpw-sm-body::-webkit-scrollbar-track,
#projectDialog .twmpw-project-table-wrap::-webkit-scrollbar-track,
#projectDialog .twmpw-project-history::-webkit-scrollbar-track{
  background:rgba(255,255,255,.35);
  border-radius:999px;
}
.twmpw-sm-modal::-webkit-scrollbar-thumb,
.twmpw-sm-body::-webkit-scrollbar-thumb,
.twmpw-validation-scroll::-webkit-scrollbar-thumb,
.twmpw-modal-table-scroll::-webkit-scrollbar-thumb,
#projectDialog .twmpw-sm-body::-webkit-scrollbar-thumb,
#projectDialog .twmpw-project-table-wrap::-webkit-scrollbar-thumb,
#projectDialog .twmpw-project-history::-webkit-scrollbar-thumb{
  background:#c6a160;
  border-radius:999px;
  border:2px solid #f1e4c6;
}
.twmpw-sm-modal::-webkit-scrollbar-corner,
.twmpw-sm-body::-webkit-scrollbar-corner,
.twmpw-validation-scroll::-webkit-scrollbar-corner,
.twmpw-modal-table-scroll::-webkit-scrollbar-corner,
#projectDialog .twmpw-sm-body::-webkit-scrollbar-corner,
#projectDialog .twmpw-project-table-wrap::-webkit-scrollbar-corner,
#projectDialog .twmpw-project-history::-webkit-scrollbar-corner{
  background:rgba(255,255,255,.35);
}

/* v305: smooth validation modal and virtualized conflict table */
.twmpw-sm-modal{
  overflow:hidden;
  display:flex;
  flex-direction:column;
  min-height:0;
}
.twmpw-sm-head,
.twmpw-sm-actions{
  flex:0 0 auto;
}
.twmpw-sm-body{
  min-height:0;
  overflow:auto;
}
.twmpw-validation-virtual{
  max-height:min(38vh,360px);
  min-height:220px;
  contain:content;
  will-change:scroll-position;
}
.twmpw-validation-virtual-table{
  table-layout:fixed;
  width:100%;
}
.twmpw-validation-virtual-table th,
.twmpw-validation-virtual-table td{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.twmpw-validation-spacer-row td{
  padding:0!important;
  border:0!important;
  height:inherit!important;
  background:transparent!important;
}

/* UI perf stage15: canvas-backed result map for large plans. */
.twmpw-map-shell-canvas .twmpw-map-wrap{
  contain: layout paint style;
  content-visibility: auto;
  contain-intrinsic-size: 1px 420px;
}
.twmpw-map-canvas{
  width: 100%;
  height: auto;
  display: block;
  touch-action: none;
  image-rendering: auto;
  background: #fffaf0;
}
.twmpw-map-perf-label{
  margin-left: auto;
  font-size: 12px;
  color: var(--muted, #766b5b);
  white-space: nowrap;
}
@media (max-width: 720px){
  .twmpw-map-perf-label{ width: 100%; white-space: normal; }
}
.twmpw-ui-perf-stage12-marker{content-visibility:auto;}
.twmpw-ui-perf-stage12-marker-2{contain:layout paint style;}
/* UI perf stage13 virtual result table. */
.twmpw-result-vtable{position:relative;contain:layout paint style;}
.twmpw-vtable-viewport{position:relative;max-height:620px;overflow:auto;contain:layout paint style;}
.twmpw-vtable-spacer{height:var(--twmpw-vtable-height,0px);pointer-events:none;}
.twmpw-vtable-table{position:absolute;left:0;top:0;width:100%;will-change:transform;}
.twmpw-ui-perf-stage13-marker{will-change:transform;}

/* UI perf stage16: clean virtual table labels and keep header fixed while virtual body scrolls */
.twmpw-result-vtable{position:relative;}
.twmpw-vtable-header{position:sticky;top:0;z-index:5;background:#f5ecd9;border-bottom:1px solid rgba(120,82,24,.25);overflow:hidden;}
.twmpw-vtable-head-table{width:100%;margin:0;table-layout:fixed;}
.twmpw-vtable-body-table{table-layout:fixed;}
.twmpw-vtable-viewport{position:relative;max-height:620px;overflow:auto;contain:layout paint style;}
.twmpw-vtable-viewport .twmpw-vtable-table thead{display:none;}
.twmpw-vtable-spacer{height:var(--twmpw-vtable-height,0px);pointer-events:none;}
.twmpw-vtable-table{position:absolute;left:0;top:0;width:100%;will-change:transform;}

/* UI Performance Stage 22: preloader for heavy row explanation modal */
.twmpw-explain-loading{display:flex;align-items:flex-start;gap:14px;padding:14px 4px;color:#5f420f;line-height:1.45}
.twmpw-explain-loading .twmpw-boot-loader{flex:0 0 auto;width:34px;height:34px;margin:0;border-width:3px}
.twmpw-sm-body-explain[aria-busy="true"]{min-height:180px;cursor:progress}

/* 04.06 targeted UX fixes: tower builder modal and small inline hints */
.twmpw-muted-mini{
  font-size:12px;
  font-weight:700;
  color:var(--muted,#766b5b);
  text-transform:none;
  letter-spacing:0;
}
.twmpw-row-actions-tight{margin:0 0 8px 0;}
.twmpw-tower-builder-row{
  display:grid;
  grid-template-columns:minmax(260px,1fr) 180px auto;
  gap:12px;
  align-items:end;
  border:1px solid rgba(120,82,24,.18);
  background:rgba(255,250,235,.7);
  border-radius:12px;
  padding:12px;
  margin:10px 0;
}
.twmpw-tower-builder-row textarea{min-height:110px;resize:vertical;}
.twmpw-tower-builder-remove{align-self:end;white-space:nowrap;}
@media (max-width: 760px){
  .twmpw-tower-builder-row{grid-template-columns:1fr;}
  .twmpw-tower-builder-remove{justify-self:start;}
}


/* twmpw-v387-pair-settings-fullscreen-css */
.twmpw-collapsible-fullscreen-capable .twmpw-collapsible-head{
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:10px;
}
.twmpw-collapsible-title-text{
  min-width:0;
}
.twmpw-pair-table-fullscreen-btn{
  white-space:nowrap;
}
html.twmpw-pair-table-fullscreen-open,
html.twmpw-pair-table-fullscreen-open body{
  overflow:hidden !important;
}
.twmpw-collapsible-fullscreen{
  position:fixed !important;
  inset:18px !important;
  z-index:9998 !important;
  height:auto !important;
  max-height:none !important;
  min-height:0 !important;
  display:flex !important;
  flex-direction:column !important;
  padding:14px !important;
  border:1px solid #d6b166 !important;
  border-radius:18px !important;
  background:#fffaf0 !important;
  box-shadow:0 18px 60px rgba(55, 34, 8, .38) !important;
}
.twmpw-collapsible-fullscreen .twmpw-collapsible-head{
  flex:0 0 auto;
  margin-bottom:12px;
  padding:0 2px 10px;
  border-bottom:1px solid rgba(166, 109, 18, .22);
}
.twmpw-collapsible-fullscreen .twmpw-collapsible-body{
  flex:1 1 auto !important;
  min-height:0 !important;
  max-height:none !important;
  height:auto !important;
}
.twmpw-collapsible-fullscreen .twmpw-collapsible-scroll{
  height:100% !important;
  max-height:none !important;
  overflow:auto !important;
  border-radius:12px;
}
.twmpw-collapsible-fullscreen .twmpw-table{
  min-width:1040px;
}
.twmpw-collapsible-fullscreen .twmpw-table thead th{
  position:sticky;
  top:0;
  z-index:2;
}
@media (max-width: 700px){
  .twmpw-collapsible-fullscreen{inset:8px !important; padding:10px !important; border-radius:14px !important;}
  .twmpw-collapsible-fullscreen-capable .twmpw-collapsible-head{align-items:flex-start; flex-direction:column;}
}


/* twmpw-v388-pair-time-exclusive-css */
.twmpw-pair-arrival-disabled-by-exact,
.twmpw-pair-exact-disabled-by-arrival{
  opacity:.72;
}
.twmpw-pair-arrival-disabled-by-exact input:disabled,
.twmpw-pair-arrival-disabled-by-exact select:disabled,
.twmpw-pair-arrival-disabled-by-exact textarea:disabled,
.twmpw-pair-arrival-disabled-by-exact button:disabled,
.twmpw-pair-exact-disabled-by-arrival input:disabled{
  cursor:not-allowed;
}
.twmpw-pair-arrival-disabled-by-exact::after{
  content:'Окна прихода недоступны, пока задано точное время прихода.';
  display:block;
  margin-top:8px;
  padding:8px 10px;
  border:1px solid rgba(166,109,18,.22);
  border-radius:10px;
  background:#fff4cf;
  color:#6b4208;
  font-size:12px;
  line-height:1.35;
}


/* twmpw-v389-pair-time-exclusive-css */
.twmpw-v389-arrival-locked-by-exact,
.twmpw-v389-exact-locked-by-arrival{
  opacity:.72;
}
.twmpw-v389-arrival-locked-by-exact input:disabled,
.twmpw-v389-arrival-locked-by-exact select:disabled,
.twmpw-v389-arrival-locked-by-exact textarea:disabled,
.twmpw-v389-arrival-locked-by-exact button:disabled,
.twmpw-v389-exact-locked-by-arrival input:disabled{
  cursor:not-allowed;
}
.twmpw-v389-arrival-locked-by-exact::after{
  content:'Окна прихода недоступны, пока задано точное время прихода.';
  display:block;
  margin-top:8px;
  padding:8px 10px;
  border:1px solid rgba(166,109,18,.22);
  border-radius:10px;
  background:#fff4cf;
  color:#6b4208;
  font-size:12px;
  line-height:1.35;
}
.twmpw-v389-exact-locked-by-arrival::after{
  content:'Точное время прихода недоступно, пока заданы окна прихода.';
  display:block;
  margin-top:8px;
  padding:8px 10px;
  border:1px solid rgba(166,109,18,.22);
  border-radius:10px;
  background:#fff4cf;
  color:#6b4208;
  font-size:12px;
  line-height:1.35;
}
/* Step 0: isolated visual world overview module */
.twmpw-wom{height:calc(100vh - 245px);min-height:560px;border:1px solid #c9ad76;border-radius:14px;overflow:hidden;background:#f7efd9;display:flex;flex-direction:column}.twmpw-wom.is-full{position:fixed;inset:0;z-index:8000;height:100vh;border-radius:0}.twmpw-wom-head{height:48px;display:flex;align-items:center;justify-content:space-between;padding:0 12px;background:#ead8ad;border-bottom:1px solid #c9ad76}.twmpw-wom-head>div:first-child{display:flex;gap:10px;align-items:baseline}.twmpw-wom-head span{font-size:12px;color:#71572f}.twmpw-wom-head-actions,.twmpw-wom-tools{display:flex;gap:6px}.twmpw-wom button{border:1px solid #bfa36b;background:#fff8e8;border-radius:9px;color:#5b421d;cursor:pointer}.twmpw-wom-head-actions button{width:34px;height:34px}.twmpw-wom svg{width:18px;height:18px;fill:currentColor}.twmpw-wom-body{display:flex;min-height:0;flex:1}.twmpw-wom-tools{width:66px;padding:8px 6px;flex-direction:column;background:#efe1bd;border-right:1px solid #c9ad76}.twmpw-wom-tools button{height:58px;padding:5px 2px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px}.twmpw-wom-tools small{font-size:10px;font-weight:800}.twmpw-wom-stage{position:relative;flex:1;min-width:0}.twmpw-wom-stage canvas{display:block;width:100%;height:100%;cursor:grab}.twmpw-wom-stage canvas:active{cursor:grabbing}.twmpw-wom-status{position:absolute;left:10px;bottom:10px;padding:6px 9px;border-radius:999px;background:rgba(255,248,232,.9);border:1px solid #c9ad76;font-size:12px;font-weight:800}.twmpw-wom-tip,.twmpw-wom-context{position:absolute;z-index:5;background:#fffaf0;border:1px solid #bfa36b;border-radius:9px;box-shadow:0 8px 28px rgba(50,35,12,.22)}.twmpw-wom-tip{pointer-events:none;padding:8px 10px;font-size:12px;line-height:1.4}.twmpw-wom-context{width:205px;padding:5px}.twmpw-wom-context button{width:100%;padding:8px;text-align:left;border:0;background:transparent}.twmpw-wom-context button:hover{background:#f1dfb8}.twmpw-wom-modal{position:fixed;inset:0;z-index:9000;background:rgba(39,28,10,.48);display:flex;align-items:center;justify-content:center;padding:24px}.twmpw-wom-modal>div{width:min(660px,94vw);max-height:84vh;display:flex;flex-direction:column;background:#fffaf0;border:1px solid #bfa36b;border-radius:14px;box-shadow:0 18px 60px rgba(0,0,0,.3)}.twmpw-wom-modal header,.twmpw-wom-modal footer{display:flex;align-items:center;justify-content:space-between;padding:12px 14px;background:#ead8ad}.twmpw-wom-modal header{border-radius:14px 14px 0 0}.twmpw-wom-modal header button{font-size:24px;border:0;background:transparent}.twmpw-wom-modal main{padding:12px;overflow:auto}.twmpw-wom-row{display:flex;align-items:center;gap:9px;padding:7px;border-bottom:1px solid #ead8ad}.twmpw-wom-row>b{flex:1}.twmpw-wom-row>span{width:18px;height:18px;border-radius:4px}.twmpw-wom-row input[type=color]{width:34px;height:28px;padding:1px;border:1px solid #bfa36b;border-radius:6px}

/* World overview map stage 2 */
.twmpw-wom-head-actions button svg{fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-tools{width:76px!important;min-width:76px!important}
.twmpw-wom-tools button{width:68px!important;min-height:66px!important;height:auto!important;padding:6px 4px!important;overflow:hidden}
.twmpw-wom-tools button small{display:block;width:100%;max-width:100%;font-size:9px!important;line-height:1.12!important;white-space:normal!important;overflow-wrap:anywhere;text-align:center}
.twmpw-wom-stage{min-width:0}.twmpw-wom-tip{pointer-events:none;z-index:20;min-width:150px;max-width:280px;line-height:1.35}
.twmpw-wom-modal-card{width:min(650px,calc(100vw - 32px));max-height:min(82vh,820px);display:grid;grid-template-rows:auto auto minmax(0,1fr) auto;overflow:hidden;background:#fffaf0;border:1px solid #bfa36b;border-radius:14px;box-shadow:0 18px 60px rgba(0,0,0,.3)}
.twmpw-wom-modal-relations .twmpw-wom-modal-card{width:min(880px,calc(100vw - 32px))}
.twmpw-wom-modal-search{padding:10px 14px;border-bottom:1px solid #dec792;background:#fff7e5}
.twmpw-wom-modal-search input{width:100%;height:38px;padding:8px 12px;border:1px solid #cda866;border-radius:9px;background:#fffdf8;color:#49320c;outline:none}
.twmpw-wom-modal-search input:focus{border-color:#966017;box-shadow:0 0 0 3px rgba(150,96,23,.14)}
.twmpw-wom-modal main{min-height:0;overflow-y:auto!important;overflow-x:hidden;scrollbar-width:thin;scrollbar-color:#c6a160 rgba(255,255,255,.35);scrollbar-gutter:stable}
.twmpw-wom-modal main::-webkit-scrollbar{width:10px;height:10px}.twmpw-wom-modal main::-webkit-scrollbar-track{background:rgba(255,255,255,.35);border-radius:999px}.twmpw-wom-modal main::-webkit-scrollbar-thumb{background:#c6a160;border-radius:999px;border:2px solid #f1e4c6}.twmpw-wom-modal main::-webkit-scrollbar-thumb:hover{background:#ad8440}
.twmpw-wom-row[hidden]{display:none!important}.twmpw-wom-color-row{display:grid!important;grid-template-columns:34px minmax(0,1fr);align-items:center;cursor:default!important}.twmpw-wom-color-input{width:28px!important;height:28px!important;min-width:28px;padding:1px!important;border-radius:7px!important;cursor:pointer}.twmpw-wom-color-row b{min-width:0;overflow-wrap:anywhere}
.twmpw-wom-relation-row{display:grid!important;grid-template-columns:minmax(0,1fr) 150px;gap:16px;align-items:center}.twmpw-wom-relation-row b{min-width:0;overflow-wrap:anywhere}.twmpw-wom-relation-row select{width:150px!important;min-width:150px;max-width:150px;justify-self:end}
.twmpw-wom-color-dot{width:20px!important;height:20px!important;border-radius:5px!important;border:1px solid rgba(0,0,0,.18)}.twmpw-wom-group-create{padding:8px 6px 14px;border-bottom:1px solid #e5d2aa;margin-bottom:5px}
@media(max-width:700px){.twmpw-wom-tools{width:66px!important;min-width:66px!important}.twmpw-wom-tools button{width:60px!important}.twmpw-wom-relation-row{grid-template-columns:1fr;gap:7px}.twmpw-wom-relation-row select{justify-self:start}}

/* === World overview map · Stage 2 V6 · 12.07.2026 === */
.twmpw-wom-stage canvas{
  cursor:crosshair!important;
  user-select:none;
  touch-action:none;
}
.twmpw-wom-stage canvas.is-panning{
  cursor:grabbing!important;
}
.twmpw-wom-stage canvas.space-pan-ready{
  cursor:grab!important;
}
.twmpw-wom-title span{
  white-space:normal;
}

/* === World overview map · Stage 2 V7 · shared cache / performance / groups === */
.twmpw-wom-title{display:flex!important;flex-direction:column;align-items:flex-start!important;gap:1px!important;min-width:0}
.twmpw-wom-title b{line-height:1.15}.twmpw-wom-title span,.twmpw-wom-title small{display:block;max-width:min(760px,60vw);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#71572f}.twmpw-wom-title small{font-size:11px;color:#886d40}
.twmpw-wom-head-actions button:disabled{opacity:.58;cursor:wait}.twmpw-wom-refresh-btn.is-loading svg{animation:twmpw-wom-spin .8s linear infinite}@keyframes twmpw-wom-spin{to{transform:rotate(360deg)}}
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"]{cursor:crosshair!important;image-rendering:auto}.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].is-panning{cursor:grabbing!important}.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].space-pan-ready{cursor:grab!important}
.twmpw-wom-minimap{position:absolute;right:12px;bottom:12px;width:224px;border:1px solid #a98a52;border-radius:12px;background:rgba(255,250,240,.96);box-shadow:0 10px 30px rgba(55,36,10,.22);overflow:hidden;z-index:16;transition:width .16s ease}.twmpw-wom-minimap-head{height:30px;display:flex;align-items:center;justify-content:space-between;padding:0 6px 0 10px;background:#ead8ad;border-bottom:1px solid #c9ad76;font-size:11px;font-weight:800;color:#5b421d}.twmpw-wom-minimap-head button{width:25px;height:23px;display:inline-flex;align-items:center;justify-content:center;padding:0}.twmpw-wom-minimap-head svg{width:14px;height:14px}.twmpw-wom-minimap-body{padding:6px}.twmpw-wom-minimap canvas{display:block;width:210px!important;height:142px!important;border:1px solid #d2ba84;border-radius:7px;background:#efe1bf;cursor:crosshair!important}.twmpw-wom-minimap.is-collapsed{width:36px}.twmpw-wom-minimap.is-collapsed .twmpw-wom-minimap-head{padding:0 5px;justify-content:center;border-bottom:0}.twmpw-wom-minimap.is-collapsed .twmpw-wom-minimap-head span,.twmpw-wom-minimap.is-collapsed .twmpw-wom-minimap-body{display:none}
.twmpw-wom-group-builder{padding:12px;border:1px solid #dbc184;border-radius:12px;background:#fff6df;margin-bottom:14px}.twmpw-wom-group-builder-grid{display:grid;grid-template-columns:minmax(180px,1.4fr) minmax(170px,1fr) 130px 150px;gap:10px;align-items:end}.twmpw-wom-group-builder-grid label,.twmpw-wom-group-color-row label{display:grid;gap:5px;font-size:12px;font-weight:800;color:#6d521d}.twmpw-wom-group-builder-grid input,.twmpw-wom-group-builder-grid select{width:100%}.twmpw-wom-group-color-row{display:flex;align-items:center;justify-content:space-between;gap:14px;margin:10px 0}.twmpw-wom-group-color-row>.twmpw-toggle-row{flex:1;margin:0}.twmpw-wom-group-color-row input[type="color"]{width:44px;height:36px;padding:1px;border:1px solid #bfa36b;border-radius:9px}.twmpw-wom-groups-list{display:grid;gap:8px}.twmpw-wom-group-card{display:grid;grid-template-columns:minmax(150px,1fr) 38px minmax(170px,1.2fr) auto auto auto;gap:9px;align-items:center;padding:10px;border:1px solid #dec792;border-radius:11px;background:#fffaf0}.twmpw-wom-group-card .twmpw-wom-group-visible{margin:0;padding:0;border:0;background:transparent;min-width:0}.twmpw-wom-group-card input[type="text"]{min-width:0}.twmpw-wom-group-card .twmpw-link-danger{white-space:nowrap}
.twmpw-wom-rel-summary{display:grid;gap:7px;margin-bottom:12px;padding:10px;border:1px solid #dbc184;border-radius:12px;background:#fff6df}.twmpw-wom-rel-summary-group{display:grid;grid-template-columns:130px minmax(0,1fr);gap:10px;align-items:start;padding:6px 8px;border-left:4px solid var(--summary-color);border-radius:7px;background:rgba(255,255,255,.64)}.twmpw-wom-rel-summary-group b{color:var(--summary-color)}.twmpw-wom-rel-summary-group span{min-width:0;overflow-wrap:anywhere;font-size:12px;color:#5b4520}.twmpw-wom-rel-name{display:flex;align-items:center;gap:9px;min-width:0}.twmpw-wom-rel-name b{min-width:0;overflow-wrap:anywhere}.twmpw-wom-status-pill{display:inline-flex;align-items:center;min-height:23px;padding:2px 8px;border-radius:999px;border:1px solid color-mix(in srgb,var(--pill-color) 55%,#fff 45%);background:color-mix(in srgb,var(--pill-color) 13%,#fff 87%);color:color-mix(in srgb,var(--pill-color) 82%,#321 18%);font-size:11px;font-weight:900;white-space:nowrap}
.twmpw-wom-modal-groups .twmpw-wom-modal-card{width:min(980px,calc(100vw - 32px))}.twmpw-wom-modal-relations .twmpw-wom-modal-card{width:min(940px,calc(100vw - 32px))}
@media(max-width:980px){.twmpw-wom-group-builder-grid{grid-template-columns:1fr 1fr}.twmpw-wom-group-card{grid-template-columns:1fr 38px 1fr auto}.twmpw-wom-group-card .twmpw-btn,.twmpw-wom-group-card .twmpw-link-danger{justify-self:start}}
@media(max-width:700px){.twmpw-wom-title span,.twmpw-wom-title small{max-width:48vw}.twmpw-wom-minimap{right:7px;bottom:42px}.twmpw-wom-group-builder-grid{grid-template-columns:1fr}.twmpw-wom-group-card{grid-template-columns:1fr}.twmpw-wom-rel-summary-group{grid-template-columns:1fr}.twmpw-wom-rel-name{align-items:flex-start;flex-direction:column}.twmpw-wom-group-color-row{align-items:flex-start;flex-direction:column}}

/* === World overview map · Stage 2 V8 · UX / CSRF / settings / labels === */
.twmpw-wom-head{
  min-height:62px!important;
  height:auto!important;
  padding:7px 12px!important;
  gap:12px;
  box-sizing:border-box;
}
.twmpw-wom-title{
  gap:3px!important;
  padding:1px 0 2px;
}
.twmpw-wom-title b{line-height:1.18!important}
.twmpw-wom-title span,.twmpw-wom-title small{
  line-height:1.28;
  min-height:14px;
}
.twmpw-wom-head-actions{
  align-items:center;
  justify-content:center;
  flex:0 0 auto;
}
.twmpw-wom-head-actions button{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:0!important;
  line-height:1!important;
  box-sizing:border-box;
}
.twmpw-wom-head-actions button svg{
  display:block;
  flex:0 0 auto;
  margin:0!important;
  transform:none;
}
.twmpw-wom-tools{
  align-items:center!important;
  box-sizing:border-box;
  padding:8px 4px!important;
}
.twmpw-wom-tools button{
  box-sizing:border-box!important;
  width:64px!important;
  margin:0 auto!important;
  flex:0 0 auto;
}
.twmpw-wom-tools button>span{
  display:flex;
  align-items:center;
  justify-content:center;
  width:24px;
  height:24px;
  flex:0 0 auto;
}
.twmpw-wom-tools button svg{display:block;margin:auto}
.twmpw-wom-status{
  z-index:18;
  max-width:min(78%,760px);
  white-space:normal;
  line-height:1.25;
}
.twmpw-wom-tip{z-index:24!important}
.twmpw-wom-context{z-index:40!important}
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].alt-pan-ready,
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].space-pan-ready{
  cursor:grab!important;
}
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].is-panning{
  cursor:grabbing!important;
}
.twmpw-wom-modal main{padding:16px!important}
.twmpw-wom-modal header,.twmpw-wom-modal footer{padding:13px 16px!important}
.twmpw-wom-modal-search{
  display:grid;
  grid-template-columns:minmax(0,1fr);
  gap:9px;
  padding:11px 16px!important;
}
.twmpw-wom-modal-players .twmpw-wom-modal-search{
  grid-template-columns:minmax(220px,1fr) minmax(210px,300px);
}
.twmpw-wom-modal-search select{
  width:100%;
  height:38px;
  padding:7px 10px;
  border:1px solid #cda866;
  border-radius:9px;
  background:#fffdf8;
  color:#49320c;
}
.twmpw-wom-color-row{
  grid-template-columns:34px minmax(0,1fr) auto!important;
  min-height:52px;
  gap:11px!important;
  padding:8px 7px!important;
}
.twmpw-wom-color-copy{
  display:grid;
  gap:3px;
  min-width:0;
}
.twmpw-wom-color-copy b{
  min-width:0;
  overflow-wrap:anywhere;
  line-height:1.2;
}
.twmpw-wom-color-copy small{
  color:#80663b;
  font-size:11px;
  line-height:1.2;
  overflow-wrap:anywhere;
}
.twmpw-wom-color-row>[data-inline-rel-pill]:empty{display:none}
.twmpw-wom-rel-summary{gap:8px!important;padding:11px!important;margin-bottom:15px!important}
.twmpw-wom-rel-summary-group{
  grid-template-columns:34px 130px minmax(0,1fr)!important;
  gap:10px!important;
  align-items:center!important;
  min-height:42px;
  padding:7px 9px!important;
}
.twmpw-wom-rel-summary-group input[type="color"]{
  width:30px!important;
  height:30px!important;
  min-width:30px!important;
}
.twmpw-wom-rel-summary-group span{line-height:1.3}
.twmpw-wom-group-builder{
  padding:14px!important;
  margin-bottom:18px!important;
}
.twmpw-wom-group-builder .twmpw-subhead{margin-bottom:11px}
.twmpw-wom-group-builder-grid{row-gap:12px!important}
.twmpw-wom-group-color-row{margin:13px 0!important}
.twmpw-wom-group-builder .twmpw-summary{
  margin:13px 0 0!important;
  padding:10px 12px!important;
}
.twmpw-wom-create-group-btn{
  margin-top:12px!important;
}
.twmpw-wom-groups-list{gap:10px!important}
.twmpw-wom-group-card{padding:11px!important}
.twmpw-wom-settings-list{
  display:grid;
  gap:10px;
}
.twmpw-wom-setting-row{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center!important;
  gap:18px;
  min-height:66px;
  margin:0!important;
  padding:12px 14px!important;
  border:1px solid #dec792!important;
  border-radius:11px;
  background:#fff8e8!important;
}
.twmpw-wom-setting-row>span:first-child{
  display:grid;
  gap:4px;
  min-width:0;
}
.twmpw-wom-setting-row b{color:#5b421d;line-height:1.2}
.twmpw-wom-setting-row small{color:#80663b;line-height:1.3;font-size:11px}
.twmpw-wom-modal-settings .twmpw-wom-modal-card{width:min(680px,calc(100vw - 32px))}
.twmpw-wom-minimap{z-index:22!important}

@media(max-width:700px){
  .twmpw-wom-head{min-height:74px!important;padding:6px 8px!important;align-items:flex-start!important}
  .twmpw-wom-title span,.twmpw-wom-title small{max-width:52vw!important;white-space:normal!important;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
  .twmpw-wom-head-actions{padding-top:1px}
  .twmpw-wom-tools{width:72px!important;min-width:72px!important;padding-inline:4px!important}
  .twmpw-wom-tools button{width:62px!important}
  .twmpw-wom-modal{padding:10px!important}
  .twmpw-wom-modal main{padding:12px!important}
  .twmpw-wom-modal-players .twmpw-wom-modal-search{grid-template-columns:1fr}
  .twmpw-wom-color-row{grid-template-columns:32px minmax(0,1fr)!important}
  .twmpw-wom-color-row>[data-inline-rel-pill]{grid-column:2}
  .twmpw-wom-rel-summary-group{grid-template-columns:32px minmax(0,1fr)!important}
  .twmpw-wom-rel-summary-group span{grid-column:1/-1;padding-left:42px}
  .twmpw-wom-status{max-width:calc(100% - 18px);font-size:11px}
}
.twmpw-wom-modal-settings .twmpw-wom-modal-card{grid-template-rows:auto minmax(0,1fr) auto!important}

/* V8 visual verification refinements */
.twmpw-wom-modal-players .twmpw-wom-modal-card{width:min(820px,calc(100vw - 32px))}
.twmpw-wom-modal-allies .twmpw-wom-modal-card{width:min(760px,calc(100vw - 32px))}
@media(max-width:700px){
  .twmpw-wom-modal-players .twmpw-wom-modal-card,
  .twmpw-wom-modal-allies .twmpw-wom-modal-card{width:calc(100vw - 20px)}
}
.twmpw-wom-color-row>[data-inline-rel-pill]{width:auto!important;height:auto!important;min-width:0;justify-self:end;overflow:visible}
@media(max-width:700px){.twmpw-wom-color-row>[data-inline-rel-pill]{justify-self:start}}


/* World map V9 — stability and interaction refinements */
.twmpw-wom-relation-row{
  grid-template-columns:minmax(0,1fr) minmax(128px,156px) 150px!important;
  gap:12px!important;
}
.twmpw-wom-neutral-color{
  display:grid;
  grid-template-columns:32px minmax(0,1fr);
  align-items:center;
  gap:7px;
  min-width:0;
}
.twmpw-wom-neutral-color[hidden]{display:none!important}
.twmpw-wom-neutral-color input[type="color"]{width:32px!important;height:30px!important;min-width:32px!important}
.twmpw-wom-neutral-color small{font-size:10px;line-height:1.15;color:#80663b;overflow-wrap:anywhere}
@media(max-width:760px){
  .twmpw-wom-relation-row{grid-template-columns:1fr!important;gap:8px!important}
  .twmpw-wom-relation-row select{justify-self:start!important}
  .twmpw-wom-neutral-color{justify-self:start;max-width:190px}
}


/* World map V10 — professional drawing, player hover and modal polish */
.twmpw-wom-head{
  display:grid!important;
  grid-template-columns:minmax(260px,1fr) auto auto;
  align-items:center!important;
  column-gap:12px!important;
}
.twmpw-wom-title{min-width:0}
.twmpw-wom-drawbar{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:5px;
  min-width:0;
  padding:4px 6px;
  border:1px solid rgba(170,132,67,.48);
  border-radius:11px;
  background:rgba(255,248,232,.62);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.65);
}
.twmpw-wom-drawbar button,.twmpw-wom-draw-color{
  position:relative;
  width:32px!important;
  height:32px!important;
  min-width:32px;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:0!important;
  border:1px solid transparent!important;
  border-radius:8px!important;
  background:transparent!important;
  color:#624719;
  cursor:pointer;
  box-sizing:border-box;
}
.twmpw-wom-drawbar button:hover,.twmpw-wom-draw-color:hover{background:#fff8e8!important;border-color:#c9ad76!important}
.twmpw-wom-drawbar button.is-active{background:#fff3ce!important;border-color:#9d6b1e!important;box-shadow:0 0 0 2px rgba(157,107,30,.14)}
.twmpw-wom-drawbar svg{width:17px!important;height:17px!important;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}
.twmpw-wom-draw-color input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}
.twmpw-wom-draw-color:after{content:'';position:absolute;right:3px;bottom:3px;width:8px;height:8px;border-radius:50%;background:var(--draw-color,#c0392b);border:1px solid #fff;box-shadow:0 0 0 1px rgba(80,48,9,.45);pointer-events:none}
.twmpw-wom-draw-width small{position:absolute;right:2px;bottom:1px;min-width:13px;height:13px;padding:0 2px;border-radius:7px;background:#805615;color:#fff;font-size:8px!important;line-height:13px!important;text-align:center;pointer-events:none}
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"]{touch-action:none}
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].is-drawing{cursor:crosshair!important}
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].is-erasing{cursor:not-allowed!important}
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].is-transforming{cursor:move!important}

.twmpw-wom-tip{
  width:min(320px,calc(100vw - 24px));
  max-width:320px!important;
  padding:0!important;
  overflow:hidden;
  border-radius:12px!important;
  background:#fffaf0!important;
  box-shadow:0 14px 38px rgba(50,35,12,.30)!important;
}
.twmpw-wom-tip-title{padding:10px 12px;background:#ead8ad;border-bottom:1px solid #c9ad76;color:#604619;font-size:12px;font-weight:900;text-align:center;text-transform:uppercase;letter-spacing:.025em}
.twmpw-wom-tip section{padding:9px 12px;border-bottom:1px solid #ead8ad}
.twmpw-wom-tip section:last-child{border-bottom:0}
.twmpw-wom-tip h4{display:flex;align-items:center;gap:7px;margin:0 0 7px;color:#2876a8;font-size:12px;text-transform:uppercase;letter-spacing:.03em}
.twmpw-wom-tip h4 .twmpw-wom-status-pill{margin-left:auto;text-transform:none;letter-spacing:0}
.twmpw-wom-tip-row{display:grid;grid-template-columns:minmax(86px,1fr) minmax(110px,1.4fr);gap:10px;align-items:start;padding:3px 0}
.twmpw-wom-tip-row span{color:#80663b;min-width:0}
.twmpw-wom-tip-row b{text-align:right;color:#3c2d16;overflow-wrap:anywhere}
.twmpw-wom-tip-row b.is-accent{color:#b68a00}

.twmpw-wom-modal-players .twmpw-wom-modal-search{grid-template-columns:minmax(220px,1fr) minmax(190px,260px) auto!important;align-items:center}
.twmpw-wom-clear-player-colors{height:38px;white-space:nowrap}
.twmpw-wom-player-color-row{grid-template-columns:34px minmax(0,1fr) auto auto!important}
.twmpw-wom-remove-player-color{white-space:nowrap;justify-self:end}
.twmpw-wom-remove-player-color[hidden]{display:none!important}
.twmpw-wom-relation-row{grid-template-columns:minmax(0,1fr) 190px 160px!important;gap:12px!important;align-items:center!important}
.twmpw-wom-relation-row>.twmpw-wom-rel-name{grid-column:1}
.twmpw-wom-relation-row>.twmpw-wom-neutral-color{grid-column:2;justify-self:stretch}
.twmpw-wom-relation-row>select{grid-column:3!important;width:160px!important;min-width:160px!important;max-width:160px!important;justify-self:end!important}

.twmpw-wom-context{overflow:visible!important}
.twmpw-wom-context-sub{position:relative}
.twmpw-wom-context-sub>[data-c="drawing"]{display:flex;align-items:center;justify-content:space-between}
.twmpw-wom-context-drawing{display:none;position:absolute;left:100%;top:-5px;width:220px;padding:6px;border:1px solid #bfa36b;border-radius:10px;background:#fffaf0;box-shadow:0 10px 34px rgba(50,35,12,.25)}
.twmpw-wom-context.open-left .twmpw-wom-context-drawing{left:auto;right:100%}
.twmpw-wom-context-sub:hover .twmpw-wom-context-drawing,.twmpw-wom-context.drawing-open .twmpw-wom-context-drawing{display:block}
.twmpw-wom-context-drawing button,.twmpw-wom-context-drawing label{width:100%;min-height:34px;display:grid;grid-template-columns:24px minmax(0,1fr) auto;align-items:center;gap:8px;padding:6px 8px;border:0;border-radius:7px;background:transparent;color:#5b421d;font-size:12px;text-align:left;cursor:pointer;box-sizing:border-box}
.twmpw-wom-context-drawing button:hover,.twmpw-wom-context-drawing label:hover{background:#f1dfb8}
.twmpw-wom-context-drawing svg{width:17px;height:17px;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-context-drawing input[type="color"]{width:28px;height:25px;padding:1px;border:1px solid #bfa36b;border-radius:6px}
.twmpw-wom-context-drawing select{height:28px;border:1px solid #bfa36b;border-radius:6px;background:#fffaf0;color:#5b421d}

@media(max-width:1100px){
  .twmpw-wom-head{grid-template-columns:minmax(0,1fr) auto!important;grid-template-rows:auto auto;row-gap:6px!important}
  .twmpw-wom-drawbar{grid-column:1/-1;grid-row:2;justify-self:center;max-width:100%;overflow-x:auto;scrollbar-width:none}
  .twmpw-wom-drawbar::-webkit-scrollbar{display:none}
  .twmpw-wom-head-actions{grid-column:2;grid-row:1}
}
@media(max-width:760px){
  .twmpw-wom-modal-players .twmpw-wom-modal-search{grid-template-columns:1fr!important}
  .twmpw-wom-player-color-row{grid-template-columns:32px minmax(0,1fr)!important}
  .twmpw-wom-player-color-row>[data-inline-rel-pill],.twmpw-wom-player-color-row>.twmpw-wom-remove-player-color{grid-column:2;justify-self:start}
  .twmpw-wom-relation-row{grid-template-columns:1fr!important;gap:8px!important}
  .twmpw-wom-relation-row>.twmpw-wom-rel-name,.twmpw-wom-relation-row>.twmpw-wom-neutral-color,.twmpw-wom-relation-row>select{grid-column:1!important;justify-self:stretch!important;width:100%!important;max-width:none!important}
  .twmpw-wom-context-drawing{position:fixed;left:12px!important;right:12px!important;top:auto!important;bottom:12px;width:auto;max-height:50vh;overflow:auto}
}


/* World map V11 — tooltip modes, true centered drawing toolbar and diplomacy pill management */
.twmpw-wom-head{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto minmax(0,1fr)!important;
  align-items:center!important;
  column-gap:14px!important;
}
.twmpw-wom-title{grid-column:1;justify-self:start;max-width:100%;}
.twmpw-wom-drawbar{grid-column:2;justify-self:center;}
.twmpw-wom-head-actions{grid-column:3;justify-self:end;}
.twmpw-wom-clear-player-colors{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding-top:0!important;
  padding-bottom:0!important;
  line-height:1.15!important;
  text-align:center!important;
}
.twmpw-wom-tip h4 .twmpw-wom-tip-icon{
  width:17px!important;
  height:17px!important;
  min-width:17px;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.8;
  stroke-linecap:round;
  stroke-linejoin:round;
}
.twmpw-wom-tip h4>span:not(.twmpw-wom-status-pill){min-width:0}
.twmpw-wom-tip-brief{padding-block:10px!important}
.twmpw-wom-rel-summary-toolbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:2px 1px 9px;
  border-bottom:1px solid #dec792;
  margin-bottom:2px;
}
.twmpw-wom-rel-summary-toolbar>div{display:grid;gap:2px;min-width:0}
.twmpw-wom-rel-summary-toolbar b{color:#5b421d}
.twmpw-wom-rel-summary-toolbar small{font-size:11px;color:#80663b}
.twmpw-wom-clear-relations{
  flex:0 0 auto;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-height:34px;
  padding:6px 11px!important;
  line-height:1.1!important;
}
.twmpw-wom-rel-summary-group{
  grid-template-columns:34px 130px minmax(0,1fr)!important;
  align-items:start!important;
}
.twmpw-wom-rel-summary-pills{display:flex;flex-wrap:wrap;gap:6px;min-width:0;padding-top:1px}
.twmpw-wom-rel-ally-pill{
  display:inline-flex;
  align-items:center;
  max-width:100%;
  min-height:27px;
  border:1px solid color-mix(in srgb,var(--pill-color) 50%,#fff 50%);
  border-radius:999px;
  background:color-mix(in srgb,var(--pill-color) 11%,#fff 89%);
  color:color-mix(in srgb,var(--pill-color) 82%,#321 18%);
  font-size:11px;
  font-weight:800;
  overflow:hidden;
}
.twmpw-wom-rel-ally-pill>span{min-width:0;padding:4px 4px 4px 9px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:inherit!important}
.twmpw-wom-rel-ally-pill>button{
  width:25px!important;
  height:25px!important;
  min-width:25px;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:0!important;
  border:0!important;
  border-left:1px solid color-mix(in srgb,var(--pill-color) 35%,#fff 65%)!important;
  border-radius:0!important;
  background:transparent!important;
  color:inherit!important;
  font-size:17px;
  line-height:1!important;
}
.twmpw-wom-rel-ally-pill>button:hover{background:color-mix(in srgb,var(--pill-color) 18%,#fff 82%)!important}
.twmpw-wom-rel-empty{display:inline-flex;align-items:center;min-height:27px;color:#8a744d!important;font-size:11px!important}
@media(max-width:1100px){
  .twmpw-wom-head{grid-template-columns:minmax(0,1fr) auto!important;grid-template-rows:auto auto!important;}
  .twmpw-wom-title{grid-column:1;grid-row:1}
  .twmpw-wom-head-actions{grid-column:2;grid-row:1}
  .twmpw-wom-drawbar{grid-column:1/-1;grid-row:2;justify-self:center;max-width:100%;overflow-x:auto;scrollbar-width:none}
}
@media(max-width:700px){
  .twmpw-wom-rel-summary-toolbar{align-items:flex-start;flex-direction:column}
  .twmpw-wom-rel-summary-group{grid-template-columns:32px minmax(0,1fr)!important}
  .twmpw-wom-rel-summary-pills{grid-column:1/-1;padding-left:42px}
}


/* World map V11 final — per-world identity and fullscreen world badge */
.twmpw-wom-title-line{display:flex;align-items:center;gap:10px;min-width:0}
.twmpw-wom-title-line>b{flex:0 0 auto}
.twmpw-wom-world-badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  min-height:25px;
  padding:3px 9px 3px 6px;
  border:1px solid rgba(149,105,35,.36);
  border-radius:999px;
  background:rgba(255,250,235,.68);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.7);
  color:#654516;
  font-size:12px;
  font-weight:800;
  line-height:1;
  white-space:nowrap;
}
.twmpw-wom-world-badge img{width:20px;height:14px;object-fit:cover;border-radius:2px;box-shadow:0 0 0 1px rgba(65,45,18,.18)}
.twmpw-wom:not(.is-full) .twmpw-wom-world-badge{display:none!important}


/* World map V12 — transactional modals, adaptive context drawing and precision alignment */
.twmpw-wom-rel-ally-pill>button{
  display:grid!important;
  place-items:center!important;
  padding:0!important;
  font-size:0!important;
  line-height:0!important;
  text-align:center!important;
}
.twmpw-wom-rel-ally-pill>button::before{
  content:'×';
  display:block;
  font-size:17px;
  line-height:1;
  transform:translateY(-.5px);
}
.twmpw-wom-title{
  min-width:0!important;
  overflow:hidden!important;
}
.twmpw-wom-title>span,.twmpw-wom-title>small{
  width:100%;
  max-width:100%!important;
}
.twmpw-wom-world-badge{
  display:inline-flex!important;
  flex-direction:row!important;
  align-items:center!important;
  width:auto!important;
  max-width:none!important;
  min-width:max-content!important;
  white-space:nowrap!important;
}
.twmpw-wom-world-badge>img{display:block;flex:0 0 auto}
.twmpw-wom-world-badge>span{
  display:inline-block!important;
  width:auto!important;
  max-width:none!important;
  min-width:0!important;
  min-height:0!important;
  overflow:visible!important;
  white-space:nowrap!important;
  line-height:1!important;
  color:inherit!important;
}
.twmpw-wom-head{
  grid-template-columns:minmax(0,1fr) auto minmax(0,1fr)!important;
}
.twmpw-wom-drawbar{position:relative;z-index:2;max-width:min(100%,520px)}
.twmpw-wom-head-actions{position:relative;z-index:3}
.twmpw-wom-context-drawing{
  position:fixed!important;
  z-index:2147483000!important;
  left:0;
  right:auto;
  top:0;
  bottom:auto;
  max-height:calc(100vh - 16px);
  overflow-y:auto;
  overscroll-behavior:contain;
  scrollbar-width:thin;
  scrollbar-color:#c6a160 #fff7e5;
}
.twmpw-wom-context-drawing::-webkit-scrollbar{width:8px}
.twmpw-wom-context-drawing::-webkit-scrollbar-track{background:#fff7e5;border-radius:999px}
.twmpw-wom-context-drawing::-webkit-scrollbar-thumb{background:#c6a160;border-radius:999px;border:2px solid #fff7e5}
.twmpw-wom-tip{
  border:1px solid #bfa36b!important;
  color:#49320c!important;
  font-family:inherit!important;
}
.twmpw-wom-modal[data-transactional="true"]{cursor:default}
@media(max-width:1100px){
  .twmpw-wom-head{grid-template-columns:minmax(0,1fr) auto!important;grid-template-rows:auto auto!important}
  .twmpw-wom-title{grid-column:1;grid-row:1}
  .twmpw-wom-head-actions{grid-column:2;grid-row:1}
  .twmpw-wom-drawbar{grid-column:1/-1;grid-row:2;justify-self:center;max-width:100%}
}


/* World map V13 — client-side analytics: focus, locator, isochrones and tactical lens */
.twmpw-wom-modal-analytics .twmpw-wom-modal-card{width:min(980px,calc(100vw - 32px));height:min(820px,calc(100vh - 28px))}
.twmpw-wom-modal-analytics main{padding:0!important;overflow:hidden!important;display:grid;grid-template-rows:auto minmax(0,1fr)}
.twmpw-wom-analysis-tabs{display:flex;align-items:center;gap:6px;padding:10px 16px;border-bottom:1px solid #dec792;background:#fff7e5;overflow-x:auto;scrollbar-width:thin}
.twmpw-wom-analysis-tabs button{min-height:36px;padding:7px 13px;border:1px solid transparent;border-radius:9px;background:transparent;color:#654719;font-weight:800;white-space:nowrap}
.twmpw-wom-analysis-tabs button:hover{background:#f3e2bd;border-color:#d5b575}
.twmpw-wom-analysis-tabs button.is-active{background:#fffaf0;border-color:#a97627;box-shadow:0 0 0 2px rgba(169,118,39,.12)}
.twmpw-wom-analysis-panels{min-height:0;overflow:auto;padding:16px;scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5}
.twmpw-wom-analysis-panel{display:grid;gap:14px}
.twmpw-wom-analysis-panel[hidden]{display:none!important}
.twmpw-wom-analysis-lead{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:14px;border:1px solid #dec792;border-radius:12px;background:#fff8e8}
.twmpw-wom-analysis-lead>div{display:grid;gap:4px;min-width:0}.twmpw-wom-analysis-lead b{color:#5b421d;font-size:15px}.twmpw-wom-analysis-lead small{color:#80663b;line-height:1.35}
.twmpw-wom-analysis-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}
.twmpw-wom-analysis-grid>label,.twmpw-wom-analysis-source>label,.twmpw-wom-analysis-result-actions>label{display:grid;gap:5px;min-width:0;color:#6c4e1c;font-size:11px;font-weight:800}
.twmpw-wom-analysis-grid input,.twmpw-wom-analysis-grid select,.twmpw-wom-analysis-source input,.twmpw-wom-analysis-source select,.twmpw-wom-analysis-result-actions input{width:100%;height:38px;padding:7px 10px;border:1px solid #cda866;border-radius:9px;background:#fffdf8;color:#49320c;box-sizing:border-box}
.twmpw-wom-analysis-source{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px;padding:14px;border:1px solid #dec792;border-radius:12px;background:#fff8e8}
.twmpw-wom-analysis-source>[hidden]{display:none!important}
.twmpw-wom-analysis-checks{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
.twmpw-wom-analysis-check{min-height:58px!important;margin:0!important;padding:10px 12px!important;border:1px solid #dec792!important;border-radius:10px;background:#fffaf0!important}
.twmpw-wom-analysis-check>span:first-child{display:grid;gap:3px}.twmpw-wom-analysis-check small{color:#80663b;font-size:10px;line-height:1.25}
.twmpw-wom-analysis-inline-toggle{grid-column:span 2;min-height:60px!important;margin:0!important;padding:10px 12px!important;border:1px solid #dec792!important;border-radius:10px;background:#fffaf0!important}
.twmpw-wom-analysis-actions{display:flex;flex-wrap:wrap;align-items:center;gap:9px}
.twmpw-wom-analysis-result-actions{display:grid;grid-template-columns:auto minmax(160px,1fr) auto minmax(180px,1fr) auto;align-items:end;gap:9px;padding:13px;border:1px solid #dec792;border-radius:12px;background:#fff8e8}
.twmpw-wom-locator-summary{display:flex!important;flex-wrap:wrap;gap:8px 18px;align-items:center}.twmpw-wom-analysis-running{color:#9a5f08;font-weight:800}
.twmpw-wom-lens-demo{display:flex;align-items:center;gap:12px;padding:18px;border:1px dashed #c6a160;border-radius:12px;background:#fffaf0;color:#5b421d;font-weight:800}.twmpw-wom-lens-demo kbd{display:grid;place-items:center;width:42px;height:42px;border:1px solid #9f7534;border-radius:9px;background:#fff;color:#6b4817;box-shadow:0 3px 0 #c6a160;font-size:20px}
.twmpw-wom-context-analytics{display:none;position:fixed!important;z-index:2147483000!important;left:0;top:0;width:248px;max-height:calc(100vh - 16px);padding:6px;border:1px solid #bfa36b;border-radius:10px;background:#fffaf0;box-shadow:0 10px 34px rgba(50,35,12,.25);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5}
.twmpw-wom-context.analytics-open .twmpw-wom-context-analytics,.twmpw-wom-context-sub:hover>.twmpw-wom-context-analytics{display:block}
.twmpw-wom-context-analytics button{width:100%;min-height:36px;display:grid;grid-template-columns:24px minmax(0,1fr);align-items:center;gap:8px;padding:7px 8px;border:0;border-radius:7px;background:transparent;color:#5b421d;font-size:12px;text-align:left;cursor:pointer;box-sizing:border-box}
.twmpw-wom-context-analytics button:hover{background:#f1dfb8}.twmpw-wom-context-analytics svg{width:17px;height:17px;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].is-lens{cursor:crosshair!important}
@media(max-width:900px){.twmpw-wom-analysis-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.twmpw-wom-analysis-result-actions{grid-template-columns:1fr 1fr}.twmpw-wom-analysis-result-actions>button{align-self:end}.twmpw-wom-analysis-checks{grid-template-columns:1fr}}
@media(max-width:620px){.twmpw-wom-modal-analytics .twmpw-wom-modal-card{width:calc(100vw - 20px);height:calc(100vh - 20px)}.twmpw-wom-analysis-grid,.twmpw-wom-analysis-source,.twmpw-wom-analysis-result-actions{grid-template-columns:1fr}.twmpw-wom-analysis-inline-toggle{grid-column:auto}.twmpw-wom-analysis-tabs{padding-inline:10px}.twmpw-wom-analysis-panels{padding:11px}.twmpw-wom-context-analytics{left:12px!important;right:12px!important;width:auto!important}}


/* World map V13 FIX3 — stable context hover, working focus and noble travel radius */
.twmpw-wom-context-sub:hover>.twmpw-wom-context-drawing,
.twmpw-wom-context-sub:hover>.twmpw-wom-context-analytics{display:none}
.twmpw-wom-context.drawing-open .twmpw-wom-context-drawing,
.twmpw-wom-context.analytics-open .twmpw-wom-context-analytics{display:block}
.twmpw-wom-context-drawing,.twmpw-wom-context-analytics{pointer-events:auto}
.twmpw-wom-focus-summary{display:grid!important;gap:3px}.twmpw-wom-focus-summary small{color:#80663b}.twmpw-wom-focus-summary small.is-warning{color:#a23c2b;font-weight:800}
.twmpw-wom-noble-card{display:flex;align-items:center;gap:12px;padding:13px 14px;border:1px solid #dec792;border-radius:12px;background:#fff8e8;color:#5b421d}
.twmpw-wom-noble-card>.twmpw-wom-unit-icon{width:36px;height:36px;flex:0 0 36px;object-fit:contain}
.twmpw-wom-noble-card>div{display:grid;gap:4px;min-width:0}.twmpw-wom-noble-card b{font-size:15px}.twmpw-wom-noble-card small{color:#80663b;line-height:1.35}
.twmpw-wom-analysis-bands-toggle{grid-column:auto!important}.twmpw-wom-analysis-bands-toggle>span:first-child{display:grid;gap:4px;min-width:0}.twmpw-wom-analysis-bands-toggle small{display:block;line-height:1.35;color:#80663b}
.twmpw-wom-isochrone-summary{display:flex!important;flex-wrap:wrap;align-items:center;gap:6px 20px}.twmpw-wom-isochrone-summary small{flex-basis:100%;color:#80663b}
.twmpw-wom-unit-icon{width:20px;height:20px;object-fit:contain;flex:0 0 20px;vertical-align:middle}
.twmpw-wom-tip h4>.twmpw-wom-unit-icon{width:19px;height:19px;flex-basis:19px}.twmpw-wom-tip-travel{background:linear-gradient(180deg,rgba(240,247,255,.58),rgba(255,250,240,.45))}
@media(max-width:620px){.twmpw-wom-isochrone-summary{display:grid!important;gap:4px}.twmpw-wom-noble-card{align-items:flex-start}}

.twmpw-wom-unit-icon-wrap{position:relative;width:22px;height:22px;display:inline-grid;place-items:center;flex:0 0 22px}.twmpw-wom-unit-icon-wrap>.twmpw-wom-unit-icon-fallback{position:absolute;inset:0;display:grid;place-items:center;color:#9a6a1f;font-size:17px;line-height:1}.twmpw-wom-unit-icon-wrap>.twmpw-wom-unit-icon{position:relative;z-index:1;width:100%;height:100%;object-fit:contain}.twmpw-wom-noble-card>.twmpw-wom-unit-icon-wrap{width:36px;height:36px;flex-basis:36px}.twmpw-wom-noble-card>.twmpw-wom-unit-icon-wrap>.twmpw-wom-unit-icon-fallback{font-size:25px}.twmpw-wom-tip h4>.twmpw-wom-unit-icon-wrap{width:19px;height:19px;flex-basis:19px}.twmpw-wom-tip h4>.twmpw-wom-unit-icon-wrap>.twmpw-wom-unit-icon-fallback{font-size:15px}

/* World map V13.2 — consistent context arrows */
.twmpw-wom-context-sub>[data-c="drawing"],
.twmpw-wom-context-sub>[data-c="analytics"]{
  display:flex;
  align-items:center;
  justify-content:space-between;
  width:100%;
}
.twmpw-wom-context-sub>[data-c="drawing"]>b,
.twmpw-wom-context-sub>[data-c="analytics"]>b{
  margin-left:auto;
  line-height:1;
  text-align:center;
}

/* World Map Stage 2 V13.4 — coordinates clipboard modal */
.twmpw-wom-modal-coordinates .twmpw-wom-modal-card{
  width:min(660px,calc(100vw - 32px));
  grid-template-rows:auto minmax(0,1fr)!important;
}
.twmpw-wom-modal-coordinates main{padding:16px!important;overflow:auto!important}
.twmpw-wom-coordinates-body{display:grid;gap:14px}
.twmpw-wom-coordinates-body textarea{
  width:100%;
  min-height:220px;
  max-height:52vh;
  resize:vertical;
  box-sizing:border-box;
  padding:13px 14px;
  border:1px solid #c9ad76;
  border-radius:12px;
  background:#fffdf8;
  color:#49320c;
  font:700 14px/1.65 ui-monospace,SFMono-Regular,Consolas,"Liberation Mono",monospace;
  letter-spacing:.02em;
  outline:none;
  white-space:pre-wrap;
  overflow-wrap:normal;
  word-break:normal;
  overflow-y:auto;
  overflow-x:hidden;
  scrollbar-width:thin;
  scrollbar-color:#c6a160 rgba(255,255,255,.35);
}
.twmpw-wom-coordinates-body textarea:focus{border-color:#966017;box-shadow:0 0 0 3px rgba(150,96,23,.14)}
.twmpw-wom-coordinates-body .twmpw-toggle-row{margin:0;min-height:48px}
@media(max-width:620px){
  .twmpw-wom-modal-coordinates .twmpw-wom-modal-card{width:calc(100vw - 20px)}
  .twmpw-wom-coordinates-body textarea{min-height:180px;font-size:13px}
}


/* World Map Stage 2 V13.5 — full-row focus toggle and unified range control */
.twmpw-wom-analysis-master-toggle{
  cursor:pointer;
  user-select:none;
  transition:border-color .14s ease,box-shadow .14s ease,background .14s ease,transform .14s ease;
}
.twmpw-wom-analysis-master-toggle:hover{
  border-color:#c89a4c;
  background:#fff5dc;
  box-shadow:0 4px 16px rgba(118,78,18,.10);
}
.twmpw-wom-analysis-master-toggle:active{transform:translateY(1px)}
.twmpw-wom-analysis-master-toggle:focus-within{
  border-color:#966017;
  box-shadow:0 0 0 3px rgba(150,96,23,.14);
}
.twmpw-wom-analysis-master-toggle>.twmpw-toggle{margin-left:auto;flex:0 0 auto}
.twmpw-wom-analysis-range-field{
  min-height:66px;
  padding:10px 12px;
  border:1px solid #dec792;
  border-radius:10px;
  background:#fffaf0;
  box-sizing:border-box;
  align-content:center;
}
.twmpw-wom-analysis-range-field>span{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  min-width:0;
}
.twmpw-wom-analysis-range-field [data-focus-opacity-value]{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:46px;
  min-height:24px;
  padding:2px 8px;
  border:1px solid #d1ad68;
  border-radius:999px;
  background:#fff4d7;
  color:#754b11;
  font-size:11px;
  line-height:1;
  box-sizing:border-box;
}
.twmpw-wom-focus-range{
  --twmpw-range-fill:15%;
  -webkit-appearance:none;
  appearance:none;
  width:100%;
  height:8px!important;
  margin:8px 0 4px;
  padding:0!important;
  border:0!important;
  border-radius:999px!important;
  outline:0;
  cursor:pointer;
  background:linear-gradient(90deg,#9d681d 0 var(--twmpw-range-fill),#ead8ad var(--twmpw-range-fill) 100%)!important;
  box-shadow:inset 0 1px 2px rgba(80,51,10,.18),0 0 0 1px rgba(154,104,29,.12);
}
.twmpw-wom-focus-range::-webkit-slider-runnable-track{
  height:8px;
  border:0;
  border-radius:999px;
  background:transparent;
}
.twmpw-wom-focus-range::-webkit-slider-thumb{
  -webkit-appearance:none;
  appearance:none;
  width:20px;
  height:20px;
  margin-top:-6px;
  border:2px solid #91601d;
  border-radius:50%;
  background:#fffdf8;
  box-shadow:0 2px 7px rgba(80,51,10,.26),0 0 0 3px rgba(255,246,222,.72);
  transition:transform .12s ease,box-shadow .12s ease;
}
.twmpw-wom-focus-range::-moz-range-track{
  height:8px;
  border:0;
  border-radius:999px;
  background:transparent;
}
.twmpw-wom-focus-range::-moz-range-progress{
  height:8px;
  border-radius:999px;
  background:#9d681d;
}
.twmpw-wom-focus-range::-moz-range-thumb{
  width:18px;
  height:18px;
  border:2px solid #91601d;
  border-radius:50%;
  background:#fffdf8;
  box-shadow:0 2px 7px rgba(80,51,10,.26),0 0 0 3px rgba(255,246,222,.72);
}
.twmpw-wom-focus-range:hover::-webkit-slider-thumb{transform:scale(1.06)}
.twmpw-wom-focus-range:focus-visible{box-shadow:inset 0 1px 2px rgba(80,51,10,.18),0 0 0 3px rgba(150,96,23,.18)}
.twmpw-wom-focus-range:focus-visible::-webkit-slider-thumb{box-shadow:0 2px 7px rgba(80,51,10,.26),0 0 0 4px rgba(150,96,23,.20)}
@media(max-width:620px){
  .twmpw-wom-analysis-master-toggle{align-items:flex-start}
  .twmpw-wom-analysis-range-field{min-height:62px}
}


/* World Map Stage 2 V13.6 — viewport-safe detailed tooltips */
.twmpw-wom-tip{
  position:fixed!important;
  z-index:8900!important;
  box-sizing:border-box;
  scrollbar-width:thin;
  scrollbar-color:#c6a160 #fff7e5;
}
.twmpw-wom-tip.is-scrollable{
  overflow-y:auto!important;
  overscroll-behavior:contain;
  pointer-events:auto;
}
.twmpw-wom-tip::-webkit-scrollbar{width:8px}
.twmpw-wom-tip::-webkit-scrollbar-track{background:#fff7e5;border-radius:999px}
.twmpw-wom-tip::-webkit-scrollbar-thumb{background:#c6a160;border-radius:999px;border:2px solid #fff7e5}


/* World Map Stage 2 V13.7 — clean colour swatches, disabled focus range and wrapped coordinates */
.twmpw-wom-modal input[type="color"],
.twmpw-wom-group-color-row input[type="color"],
.twmpw-wom-rel-summary-group input[type="color"],
.twmpw-wom-neutral-color input[type="color"]{
  -webkit-appearance:none!important;
  appearance:none!important;
  padding:0!important;
  border:0!important;
  outline:0!important;
  border-radius:3px!important;
  background:transparent!important;
  box-shadow:none!important;
  cursor:pointer;
}
.twmpw-wom-modal input[type="color"]::-webkit-color-swatch-wrapper{padding:0!important}
.twmpw-wom-modal input[type="color"]::-webkit-color-swatch{border:0!important;border-radius:3px!important}
.twmpw-wom-modal input[type="color"]::-moz-color-swatch{border:0!important;border-radius:3px!important}
.twmpw-wom-analysis-range-field.is-disabled{
  opacity:.52;
  background:#f3ead7;
  cursor:not-allowed;
}
.twmpw-wom-analysis-range-field.is-disabled [data-focus-opacity-value]{background:#eee3ce;color:#8b7858;border-color:#d6c7aa}
.twmpw-wom-focus-range:disabled{cursor:not-allowed!important;filter:saturate(.25);box-shadow:none!important}
.twmpw-wom-coordinates-body textarea[wrap="soft"]{
  white-space:pre-wrap!important;
  overflow-wrap:normal!important;
  word-break:normal!important;
  overflow-x:hidden!important;
}

/* World map V14.0 — recent changes */
.twmpw-wom-tip-change{
  background:linear-gradient(180deg,rgba(255,247,229,.9),rgba(255,251,242,.72));
  border-top:1px solid rgba(190,151,83,.45);
}
.twmpw-wom-changes-summary{
  display:flex!important;
  flex-wrap:wrap;
  align-items:center;
  gap:8px 18px;
}
.twmpw-wom-changes-summary>span{
  white-space:nowrap;
}
.twmpw-wom-changes-summary>small{
  flex-basis:100%;
}
.twmpw-wom-changes-list{
  display:grid;
  gap:7px;
  padding:12px;
  border:1px solid #dec792;
  border-radius:12px;
  background:#fff8e8;
}
.twmpw-wom-change-row{
  width:100%;
  min-width:0;
  display:grid;
  grid-template-columns:12px minmax(0,1fr) auto;
  align-items:center;
  gap:10px;
  padding:9px 10px;
  border:1px solid transparent;
  border-radius:9px;
  background:#fffdf8;
  color:#5b421d;
  text-align:left;
  cursor:pointer;
}
.twmpw-wom-change-row:hover{
  border-color:#d3af6b;
  background:#fff7e5;
}
.twmpw-wom-change-row>span:nth-child(2){display:grid;gap:3px;min-width:0}
.twmpw-wom-change-row b,.twmpw-wom-change-row small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.twmpw-wom-change-row small{color:#80663b;font-size:10px}
.twmpw-wom-change-row time{color:#8a6a35;font-size:10px;font-weight:700;white-space:nowrap}
.twmpw-wom-change-dot{
  width:9px;
  height:9px;
  border-radius:50%;
  background:var(--change-color,#96733f);
  box-shadow:0 0 0 2px #fff,0 0 0 3px color-mix(in srgb,var(--change-color,#96733f) 70%,transparent);
}
.twmpw-wom-changes-result-actions{
  grid-template-columns:auto auto minmax(150px,1fr) auto minmax(180px,1fr) auto;
}
@media(max-width:1100px){
  .twmpw-wom-changes-result-actions{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:620px){
  .twmpw-wom-change-row{grid-template-columns:12px minmax(0,1fr)}
  .twmpw-wom-change-row time{grid-column:2}
  .twmpw-wom-changes-result-actions{grid-template-columns:1fr}
}


/* World map V14.1 — responsive, readable changes panel without horizontal scrolling */
.twmpw-wom-modal-analytics main,
.twmpw-wom-analysis-panels,
.twmpw-wom-analysis-panel,
.twmpw-wom-analysis-panel>*{
  min-width:0;
  max-width:100%;
  box-sizing:border-box;
}
.twmpw-wom-analysis-panels{
  overflow-y:auto!important;
  overflow-x:hidden!important;
  overscroll-behavior:contain;
  scrollbar-gutter:stable;
}
.twmpw-wom-changes-panel{
  width:100%;
  grid-template-columns:minmax(0,1fr);
  align-content:start;
}
.twmpw-wom-changes-master{
  width:100%;
}
.twmpw-wom-changes-master>div{
  max-width:760px;
}
.twmpw-wom-changes-filter-card,
.twmpw-wom-changes-output,
.twmpw-wom-changes-result-actions{
  width:100%;
  min-width:0;
  overflow:hidden;
}
.twmpw-wom-changes-filter-card{
  display:grid;
  gap:12px;
  padding:14px;
  border:1px solid #dec792;
  border-radius:12px;
  background:#fff8e8;
}
.twmpw-wom-changes-filter-grid{
  width:100%;
  grid-template-columns:repeat(2,minmax(0,1fr));
}
.twmpw-wom-changes-filter-grid>label,
.twmpw-wom-changes-filter-grid select{
  min-width:0;
  max-width:100%;
}
.twmpw-wom-changes-selection-toggle{
  grid-column:auto!important;
  width:100%;
}
.twmpw-wom-changes-primary-actions{
  padding-top:1px;
}
.twmpw-wom-changes-primary-actions .twmpw-btn{
  min-width:170px;
}
.twmpw-wom-changes-output{
  display:grid;
  gap:12px;
}
.twmpw-wom-changes-summary{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:8px;
  padding:0!important;
  border:0!important;
  background:transparent!important;
}
.twmpw-wom-changes-summary>span{
  min-width:0;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  padding:10px 12px;
  border:1px solid #dec792;
  border-radius:10px;
  background:#fff8e8;
  color:#6c4e1c;
  white-space:normal;
  line-height:1.3;
}
.twmpw-wom-changes-summary>span b{
  flex:0 0 auto;
  color:#4f3510;
}
.twmpw-wom-changes-summary>small{
  grid-column:1/-1;
  min-width:0;
  padding:2px 1px;
  line-height:1.35;
}
.twmpw-wom-changes-list{
  width:100%;
  min-width:0;
  box-sizing:border-box;
}
.twmpw-wom-change-row{
  box-sizing:border-box;
}
.twmpw-wom-changes-result-actions{
  display:grid;
  grid-template-columns:minmax(0,1fr)!important;
  align-items:stretch;
  gap:12px;
  padding:14px;
}
.twmpw-wom-changes-result-actions>.twmpw-subhead{
  min-width:0;
}
.twmpw-wom-changes-quick-actions{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:9px;
}
.twmpw-wom-changes-quick-actions .twmpw-btn{
  width:100%;
  min-width:0;
}
.twmpw-wom-changes-create-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}
.twmpw-wom-changes-create-card{
  min-width:0;
  display:grid;
  grid-template-columns:minmax(0,1fr);
  align-content:start;
  gap:9px;
  padding:12px;
  border:1px solid #e2cd9d;
  border-radius:10px;
  background:#fffdf8;
}
.twmpw-wom-changes-create-card label{
  min-width:0;
  display:grid;
  gap:5px;
  color:#6c4e1c;
  font-size:11px;
  font-weight:800;
}
.twmpw-wom-changes-create-card input{
  width:100%;
  min-width:0;
  height:38px;
  padding:7px 10px;
  border:1px solid #cda866;
  border-radius:9px;
  background:#fffdf8;
  color:#49320c;
  box-sizing:border-box;
}
.twmpw-wom-changes-create-card .twmpw-btn{
  width:100%;
  min-width:0;
  min-height:40px;
  padding:8px 12px;
  white-space:normal;
  line-height:1.25;
}
@media(max-width:900px){
  .twmpw-wom-changes-filter-grid,
  .twmpw-wom-changes-summary{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}
@media(max-width:700px){
  .twmpw-wom-changes-create-grid{
    grid-template-columns:minmax(0,1fr);
  }
}
@media(max-width:620px){
  .twmpw-wom-changes-filter-card,
  .twmpw-wom-changes-result-actions{
    padding:11px;
  }
  .twmpw-wom-changes-filter-grid,
  .twmpw-wom-changes-summary,
  .twmpw-wom-changes-quick-actions{
    grid-template-columns:minmax(0,1fr);
  }
  .twmpw-wom-changes-primary-actions{
    display:grid;
    grid-template-columns:minmax(0,1fr);
  }
  .twmpw-wom-changes-primary-actions .twmpw-btn{
    width:100%;
    min-width:0;
  }
}
.twmpw-wom-changes-selection-toggle>span:first-child{
  min-width:0;
  display:grid;
  gap:3px;
}
.twmpw-wom-changes-selection-toggle small{
  color:#80663b;
  line-height:1.3;
}

/* World map V14.2 — machine time, comparison and planner-ready history */
.twmpw-wom-analysis-tabs{
  flex-wrap:wrap;
  overflow-x:hidden;
}
.twmpw-wom-tip-timeline{
  margin:10px -14px -12px;
  padding:10px 14px 12px;
  border-top:1px solid #e3cf9f;
  background:linear-gradient(180deg,rgba(255,249,235,.74),rgba(244,225,184,.58));
}
.twmpw-wom-tip-timeline b{display:block;color:#7d4e0a;margin-bottom:4px}
.twmpw-wom-tip-timeline small{display:block;color:#6d552f;line-height:1.38}
.twmpw-wom-timeline{
  position:absolute;
  left:50%;
  bottom:47px;
  z-index:17;
  width:min(720px,calc(100% - 180px));
  min-width:0;
  transform:translateX(-50%);
  padding:10px 12px 9px;
  border:1px solid rgba(160,111,34,.70);
  border-radius:13px;
  background:rgba(255,248,230,.92);
  box-shadow:0 8px 24px rgba(69,43,8,.22),inset 0 1px 0 rgba(255,255,255,.75);
  backdrop-filter:blur(7px);
  color:#54370d;
  box-sizing:border-box;
}
.twmpw-wom-timeline[hidden]{display:none!important}
.twmpw-wom-timeline-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  min-width:0;
}
.twmpw-wom-timeline-head>span{
  min-width:0;
  display:grid;
  gap:1px;
}
.twmpw-wom-timeline-head b{font-size:13px;line-height:1.2}
.twmpw-wom-timeline-head small{
  color:#775c31;
  font-size:11px;
  line-height:1.25;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.twmpw-wom-timeline-head>div{display:flex;align-items:center;gap:5px;flex:0 0 auto}
.twmpw-wom-timeline-head button{
  min-height:29px;
  padding:4px 9px;
  border:1px solid #c89f58;
  border-radius:8px;
  background:#fffaf0;
  color:#5f3e0d;
  font-weight:800;
  cursor:pointer;
}
.twmpw-wom-timeline-head button:hover{background:#f2dfb5;border-color:#a87526}
.twmpw-wom-timeline-head [data-timeline-close]{width:29px;padding:0;font-size:20px;line-height:1}
.twmpw-wom-timeline-range,
.twmpw-wom-timeline-modal-range{
  display:grid;
  grid-template-columns:max-content minmax(0,1fr) max-content;
  align-items:center;
  gap:9px;
  min-width:0;
}
.twmpw-wom-timeline-range{margin-top:8px}
.twmpw-wom-timeline-range time,
.twmpw-wom-timeline-modal-range time{
  color:#74582f;
  font-size:10px;
  font-weight:800;
  white-space:nowrap;
}
.twmpw-wom-timeline-range input,
.twmpw-wom-timeline-slider{
  --twmpw-range-fill:100%;
  width:100%;
  min-width:0;
  height:22px;
  margin:0;
  appearance:none;
  -webkit-appearance:none;
  background:transparent;
  cursor:pointer;
}
.twmpw-wom-timeline-range input::-webkit-slider-runnable-track,
.twmpw-wom-timeline-slider::-webkit-slider-runnable-track{
  height:8px;
  border:1px solid #b98a3f;
  border-radius:999px;
  background:linear-gradient(90deg,#a86b13 0 var(--twmpw-range-fill),#ead7ae var(--twmpw-range-fill) 100%);
  box-shadow:inset 0 1px 2px rgba(85,50,5,.16);
}
.twmpw-wom-timeline-range input::-webkit-slider-thumb,
.twmpw-wom-timeline-slider::-webkit-slider-thumb{
  width:20px;
  height:20px;
  margin-top:-7px;
  border:3px solid #fff9e9;
  border-radius:50%;
  background:#a6660d;
  box-shadow:0 2px 7px rgba(80,49,6,.34),0 0 0 1px #8b570e;
  appearance:none;
  -webkit-appearance:none;
}
.twmpw-wom-timeline-range input::-moz-range-track,
.twmpw-wom-timeline-slider::-moz-range-track{
  height:7px;
  border:1px solid #b98a3f;
  border-radius:999px;
  background:#ead7ae;
}
.twmpw-wom-timeline-range input::-moz-range-progress,
.twmpw-wom-timeline-slider::-moz-range-progress{height:7px;border-radius:999px;background:#a86b13}
.twmpw-wom-timeline-range input::-moz-range-thumb,
.twmpw-wom-timeline-slider::-moz-range-thumb{
  width:15px;height:15px;border:3px solid #fff9e9;border-radius:50%;background:#a6660d;box-shadow:0 2px 7px rgba(80,49,6,.34)
}
.twmpw-wom-timeline-compare{
  display:flex;
  align-items:center;
  gap:7px;
  margin-top:4px;
  color:#6d5128;
  font-size:10px;
  font-weight:700;
  cursor:pointer;
}
.twmpw-wom-timeline-compare input{accent-color:#9d620e}
.twmpw-wom-timeline-panel{
  width:100%;
  min-width:0;
  box-sizing:border-box;
  display:grid;
  grid-template-columns:minmax(0,1fr);
  gap:12px;
  overflow-x:hidden;
}
.twmpw-wom-timeline-panel>*{min-width:0;box-sizing:border-box}
.twmpw-wom-timeline-settings-card,
.twmpw-wom-timeline-control-card,
.twmpw-wom-timeline-result-actions{
  width:100%;
  min-width:0;
  padding:14px;
  border:1px solid #dec48e;
  border-radius:11px;
  background:#fffaf0;
  box-sizing:border-box;
}
.twmpw-wom-timeline-settings-card{display:grid;gap:12px}
.twmpw-wom-timeline-settings-grid{
  display:grid;
  grid-template-columns:minmax(0,.78fr) minmax(0,1.22fr);
  gap:10px;
  align-items:stretch;
}
.twmpw-wom-timeline-settings-grid>label{min-width:0}
.twmpw-wom-timeline-settings-grid>label:first-child{
  display:grid;
  align-content:start;
  gap:6px;
  color:#6c4e1c;
  font-size:11px;
  font-weight:800;
}
.twmpw-wom-timeline-settings-grid select{width:100%;min-width:0;height:42px;box-sizing:border-box}
.twmpw-wom-timeline-compare-row{grid-column:auto!important;margin:0!important}
.twmpw-wom-timeline-control-card{display:grid;gap:12px}
.twmpw-wom-timeline-control-card[hidden]{display:none!important}
.twmpw-wom-timeline-control-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.twmpw-wom-timeline-control-head>span{min-width:0;display:grid;gap:3px}
.twmpw-wom-timeline-control-head small{color:#775d34;line-height:1.3}
.twmpw-wom-timeline-modal-range{padding:10px 1px 2px}
.twmpw-wom-timeline-summary{
  width:100%;
  min-width:0;
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:8px;
  padding:0!important;
  border:0!important;
  background:transparent!important;
}
.twmpw-wom-timeline-summary>span{
  min-width:0;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:8px;
  padding:10px 11px;
  border:1px solid #e1c995;
  border-radius:9px;
  background:#fff7e5;
  color:#70552d;
  line-height:1.3;
}
.twmpw-wom-timeline-summary>span b{color:#4d320b;text-align:right}
.twmpw-wom-timeline-summary>small{
  grid-column:1/-1;
  padding:9px 11px;
  border:1px solid #e1c995;
  border-radius:9px;
  background:#fff7e5;
  line-height:1.35;
}
.twmpw-wom-timeline-result-actions{
  display:grid!important;
  grid-template-columns:minmax(0,1fr)!important;
  align-items:stretch;
  gap:12px;
}
.twmpw-wom-timeline-result-actions>.twmpw-subhead{min-width:0}
.twmpw-wom-timeline-result-actions .twmpw-wom-changes-quick-actions,
.twmpw-wom-timeline-result-actions .twmpw-wom-changes-create-grid{min-width:0}
@media(max-width:900px){
  .twmpw-wom-timeline{width:min(680px,calc(100% - 112px))}
  .twmpw-wom-timeline-summary{grid-template-columns:minmax(0,1fr)}
  .twmpw-wom-timeline-summary>small{grid-column:auto}
}
@media(max-width:700px){
  .twmpw-wom-timeline-settings-grid{grid-template-columns:minmax(0,1fr)}
  .twmpw-wom-timeline{width:calc(100% - 20px);bottom:52px;padding:9px 10px}
  .twmpw-wom-timeline-head small{white-space:normal;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
}
@media(max-width:520px){
  .twmpw-wom-analysis-tabs{gap:4px;padding:8px}
  .twmpw-wom-analysis-tabs button{flex:1 1 44%;min-width:0;padding-inline:7px;white-space:normal;line-height:1.15}
  .twmpw-wom-timeline-range,
  .twmpw-wom-timeline-modal-range{grid-template-columns:minmax(0,1fr);gap:4px}
  .twmpw-wom-timeline-range time:last-child,
  .twmpw-wom-timeline-modal-range time:last-child{display:none}
  .twmpw-wom-timeline-control-head{align-items:flex-start}
  .twmpw-wom-timeline-settings-card,
  .twmpw-wom-timeline-control-card,
  .twmpw-wom-timeline-result-actions{padding:11px}
}
.twmpw-wom-timeline-compare-row>span:first-child{
  min-width:0;
  display:grid;
  gap:3px;
}
.twmpw-wom-timeline-compare-row b,
.twmpw-wom-timeline-compare-row small{display:block;min-width:0}
.twmpw-wom-timeline-compare-row small{color:#80663b;line-height:1.32;font-weight:500}

/* World Map Stage 2 V14.3 — unified changes workspace and polished historical UI */
.twmpw-wom-timeline-head [data-timeline-close]{
  width:30px;
  height:30px;
  min-height:30px;
  padding:0;
  display:grid;
  place-items:center;
  line-height:0;
}
.twmpw-wom-timeline-head [data-timeline-close] svg{
  width:15px!important;
  height:15px!important;
  display:block;
  fill:none!important;
  stroke:currentColor;
  stroke-width:2;
  stroke-linecap:round;
}
.twmpw-wom-timeline-compare{
  width:fit-content;
  max-width:100%;
  min-height:34px;
  margin:7px 0 0 auto;
  padding:5px 7px 5px 9px;
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:10px;
  border:1px solid rgba(203,166,99,.72);
  border-radius:10px;
  background:rgba(255,251,241,.78);
  box-sizing:border-box;
  color:#684a20;
  font-size:11px;
  font-weight:800;
}
.twmpw-wom-timeline-compare>span:first-child{min-width:0;line-height:1.25}
.twmpw-wom-timeline-compare>.twmpw-toggle{flex:0 0 auto}
.twmpw-wom-timeline-compare .twmpw-toggle-slider{width:38px;height:22px}
.twmpw-wom-timeline-compare .twmpw-toggle-slider::after{width:16px;height:16px}
.twmpw-wom-timeline-compare .twmpw-toggle input:checked + .twmpw-toggle-slider::after{left:19px}

.twmpw-wom-changes-hub{
  width:100%;
  min-width:0;
  display:grid;
  gap:12px;
  overflow-x:hidden;
}
.twmpw-wom-changes-view-tabs{
  width:fit-content;
  max-width:100%;
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:4px;
  padding:4px;
  border:1px solid #dec48e;
  border-radius:11px;
  background:#f4e5bf;
  box-sizing:border-box;
}
.twmpw-wom-changes-view-tabs button{
  min-width:150px;
  min-height:36px;
  padding:7px 14px;
  border:0;
  border-radius:8px;
  background:transparent;
  color:#6b4b1d;
  font-weight:900;
  white-space:nowrap;
}
.twmpw-wom-changes-view-tabs button.is-active{
  background:#fffaf0;
  color:#4f330d;
  box-shadow:0 1px 4px rgba(79,51,13,.18),inset 0 0 0 1px #c69a50;
}
.twmpw-wom-changes-events-view,
.twmpw-wom-timeline-panel{
  width:100%;
  min-width:0;
  display:grid;
  gap:12px;
  box-sizing:border-box;
}
.twmpw-wom-changes-events-view[hidden],
.twmpw-wom-timeline-panel[hidden]{display:none!important}

.twmpw-wom-tip.has-timeline-layout{
  width:min(660px,calc(100vw - 20px))!important;
  max-width:min(660px,calc(100vw - 20px))!important;
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  align-items:stretch;
  overflow:visible!important;
}
.twmpw-wom-tip.has-timeline-layout.is-scrollable{
  overflow-y:auto!important;
  overflow-x:hidden!important;
}
.twmpw-wom-tip.has-timeline-layout>.twmpw-wom-tip-title{
  grid-column:1/-1;
}
.twmpw-wom-tip.has-timeline-layout>section{
  min-width:0;
  margin:0!important;
  padding:10px 12px!important;
  border-right:1px solid #ead8ad;
  border-bottom:1px solid #ead8ad;
  background:#fffaf0;
  box-sizing:border-box;
}
.twmpw-wom-tip.has-timeline-layout>section:nth-of-type(even){border-right:0}
.twmpw-wom-tip.has-timeline-layout>.twmpw-wom-tip-timeline{
  margin:0!important;
  background:linear-gradient(180deg,rgba(255,249,235,.98),rgba(244,225,184,.82));
}
.twmpw-wom-tip.has-timeline-layout .twmpw-wom-tip-row{
  grid-template-columns:minmax(88px,.9fr) minmax(120px,1.45fr);
  gap:9px;
}
.twmpw-wom-tip.has-timeline-layout.is-condensed>section{padding:7px 10px!important}
.twmpw-wom-tip.has-timeline-layout.is-condensed h4{margin-bottom:4px}
.twmpw-wom-tip.has-timeline-layout.is-condensed .twmpw-wom-tip-row{padding:2px 0}

@media(max-width:720px){
  .twmpw-wom-changes-view-tabs{width:100%}
  .twmpw-wom-changes-view-tabs button{min-width:0;white-space:normal;line-height:1.2}
  .twmpw-wom-tip.has-timeline-layout{
    grid-template-columns:minmax(0,1fr);
    width:min(430px,calc(100vw - 16px))!important;
    max-width:min(430px,calc(100vw - 16px))!important;
  }
  .twmpw-wom-tip.has-timeline-layout>section{border-right:0}
}

/* World Map Stage 2 V14.4 — stable historical tooltips and low-cost hover rendering */
.twmpw-wom-tip,
.twmpw-wom-tip.is-scrollable{
  pointer-events:none!important;
}
.twmpw-wom-tip:not(.has-timeline-layout)>.twmpw-wom-tip-timeline{
  margin:0!important;
  padding:10px 12px 12px!important;
  width:auto!important;
  max-width:100%!important;
  box-sizing:border-box!important;
  border-top:0!important;
  border-bottom:0!important;
}
.twmpw-wom-tip:not(.has-timeline-layout)>.twmpw-wom-tip-timeline .twmpw-wom-tip-row{
  grid-template-columns:minmax(86px,1fr) minmax(110px,1.4fr);
  min-width:0;
}
.twmpw-wom-tip:not(.has-timeline-layout)>.twmpw-wom-tip-timeline h4,
.twmpw-wom-tip:not(.has-timeline-layout)>.twmpw-wom-tip-timeline .twmpw-wom-tip-row{
  width:100%;
  box-sizing:border-box;
}
.twmpw-wom-tip[hidden]{display:none!important}


/* World Map Stage 2 V14.5.2 — map modes integrated into drawing toolbar */
.twmpw-wom-drawbar .twmpw-wom-mode-btn{
  width:32px!important;
  height:32px!important;
  min-width:32px!important;
  padding:0!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  border:1px solid transparent!important;
  border-radius:8px!important;
  background:transparent!important;
  color:#624719;
  transition:background-color .12s ease,border-color .12s ease,box-shadow .12s ease,color .12s ease;
}
.twmpw-wom-drawbar .twmpw-wom-mode-btn:hover{background:#fff8e8!important;border-color:#c9ad76!important}
.twmpw-wom-drawbar .twmpw-wom-mode-btn.is-active{
  background:#fff3ce!important;
  border-color:#9d6b1e!important;
  color:#704812!important;
  box-shadow:0 0 0 2px rgba(157,107,30,.14),inset 0 1px 0 rgba(255,255,255,.7)!important;
}
.twmpw-wom-toolbar-separator{
  align-self:stretch;
  width:1px;
  min-width:1px;
  margin:3px 2px;
  background:rgba(145,107,48,.42);
  border-radius:1px;
  pointer-events:none;
}
.twmpw-wom-stage canvas.is-tool-select{cursor:crosshair}
.twmpw-wom-stage canvas.is-tool-pan{cursor:grab}
.twmpw-wom-stage canvas.is-tool-pan:active,.twmpw-wom-stage canvas.is-panning{cursor:grabbing}


/* World Map Stage 2 V14.6 — selection workflow and adaptive action panel */
.twmpw-wom-selection-bar{
  position:absolute;left:50%;bottom:10px;z-index:23;
  width:min(760px,calc(100% - 210px));min-height:48px;
  transform:translateX(-50%);display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:7px 8px 7px 11px;box-sizing:border-box;
  border:1px solid rgba(160,111,34,.72);border-radius:13px;
  background:rgba(255,248,230,.95);box-shadow:0 8px 24px rgba(69,43,8,.22),inset 0 1px 0 rgba(255,255,255,.78);
  backdrop-filter:blur(7px);color:#54370d;
}
.twmpw-wom-selection-bar[hidden]{display:none!important}
.twmpw-wom-selection-summary{display:flex;align-items:center;gap:9px;min-width:0}
.twmpw-wom-selection-summary>svg{width:19px!important;height:19px!important;flex:0 0 auto;fill:none!important;stroke:#8a5a12;stroke-width:1.8;stroke-linejoin:round}
.twmpw-wom-selection-summary>span{display:grid;gap:1px;min-width:0}
.twmpw-wom-selection-summary b{font-size:12px;line-height:1.2;white-space:nowrap}.twmpw-wom-selection-summary strong{font-size:14px;color:#6f4307}
.twmpw-wom-selection-summary small{font-size:10px;color:#775c31;white-space:nowrap}
.twmpw-wom-selection-actions{display:flex;align-items:center;gap:5px;flex:0 0 auto}
.twmpw-wom-selection-actions>button,.twmpw-wom-selection-more>button{
  min-height:34px;padding:5px 9px;display:inline-flex;align-items:center;justify-content:center;gap:6px;
  border:1px solid #c9ad76;border-radius:8px;background:#fffaf0;color:#5d3d0d;font-size:11px;font-weight:850;white-space:nowrap;
}
.twmpw-wom-selection-actions button:hover{background:#f2dfb5;border-color:#a87526}
.twmpw-wom-selection-actions button:focus-visible{outline:2px solid #1c6ba0;outline-offset:2px}
.twmpw-wom-selection-actions svg{width:15px!important;height:15px!important;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-selection-clear{width:34px!important;padding:0!important}
.twmpw-wom-selection-more{position:relative}
.twmpw-wom-selection-menu{
  position:absolute;right:0;bottom:calc(100% + 7px);z-index:45;width:230px;padding:5px;
  border:1px solid #bfa36b;border-radius:10px;background:#fffaf0;box-shadow:0 10px 30px rgba(50,35,12,.24)
}
.twmpw-wom-selection-menu[hidden]{display:none!important}
.twmpw-wom-selection-menu button{width:100%;min-height:34px;padding:7px 8px;display:flex;align-items:center;gap:8px;border:0;background:transparent;text-align:left;font-size:11px;font-weight:750}
.twmpw-wom-selection-menu button:hover{background:#f1dfb8}.twmpw-wom-selection-menu button:disabled{opacity:.46;cursor:not-allowed;background:transparent}
.twmpw-wom-selection-menu button span{flex:1}.twmpw-wom-selection-menu kbd{padding:1px 5px;border:1px solid #d0b67f;border-radius:5px;background:#fff8e8;font-size:9px}
.twmpw-wom-stage.has-selection-panel .twmpw-wom-timeline{bottom:calc(18px + var(--wom-selection-panel-height,48px))}
.twmpw-wom-stage.has-selection-panel .twmpw-wom-minimap{bottom:calc(18px + var(--wom-selection-panel-height,48px))}
.twmpw-wom-stage.has-selection-panel .twmpw-wom-status{bottom:calc(18px + var(--wom-selection-panel-height,48px))}
.twmpw-wom-stage.has-selection-panel.has-timeline-panel .twmpw-wom-status{bottom:calc(26px + var(--wom-selection-panel-height,48px) + var(--wom-timeline-panel-height,110px))}
@media(max-width:980px){
  .twmpw-wom-selection-bar{width:calc(100% - 22px)}
  .twmpw-wom-stage.has-selection-panel .twmpw-wom-minimap{bottom:calc(18px + var(--wom-selection-panel-height,48px))}
}
@media(max-width:700px){
  .twmpw-wom-selection-bar{align-items:stretch;gap:7px;padding:7px 8px}
  .twmpw-wom-selection-summary{flex:1}.twmpw-wom-selection-summary small{white-space:normal}
  .twmpw-wom-selection-actions>button span,.twmpw-wom-selection-more>button span{display:none}
  .twmpw-wom-selection-actions>button,.twmpw-wom-selection-more>button{width:34px;padding:0}
  .twmpw-wom-selection-menu button span{display:block}
  .twmpw-wom-stage.has-selection-panel.has-timeline-panel .twmpw-wom-status{top:8px;bottom:auto;max-width:calc(100% - 18px)}
}
@media(max-width:470px){
  .twmpw-wom-selection-summary small{display:none}.twmpw-wom-selection-summary b{white-space:normal}
  .twmpw-wom-selection-actions{gap:3px}.twmpw-wom-selection-bar{gap:5px}
}

/* Compatibility marker: World Map Stage 2 V14.5 */

/* World Map Stage 2 V14.6.1 — trustworthy change synchronization */
.twmpw-wom-changes-summary>small.is-trusted{
  color:#2f6c3f;
  border:1px solid #b9dfbf;
  border-radius:9px;
  background:#edf8ef;
  padding:8px 10px;
}
.twmpw-wom-change-row em,
.twmpw-wom-change-row i{
  display:block;
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  font-size:10px;
  line-height:1.28;
  font-style:normal;
}
.twmpw-wom-change-row em.twmpw-wom-change-confirmed{
  color:#2f6c3f;
  font-weight:800;
}
.twmpw-wom-change-row em.twmpw-wom-change-current{
  color:#7a4b00;
  font-weight:850;
}
.twmpw-wom-change-row i{
  color:#8a6a35;
}
.twmpw-wom-change-row.is-mismatch,
.twmpw-wom-change-row.is-gap{
  border-color:#e1a8a8;
  background:#fff7f5;
}
.twmpw-wom-change-row.is-superseded{
  border-color:#dfc17f;
  background:#fffaf0;
}
@media(max-width:620px){
  .twmpw-wom-change-row em,
  .twmpw-wom-change-row i{white-space:normal;overflow:visible;text-overflow:clip;}
}

/* World Map Stage 2 V14.7.1 — current-owner relation fix and clear historical event status */
.twmpw-wom-custom-period{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);
  align-items:end;
  gap:10px;
  margin-top:10px;
  padding:11px;
  border:1px solid #dfc58d;
  border-radius:11px;
  background:#fffaf0;
}
.twmpw-wom-custom-period[hidden]{display:none!important}
.twmpw-wom-custom-period label{display:grid;gap:5px;min-width:0;color:#6c4e1c;font-size:11px;font-weight:850}
.twmpw-wom-custom-period input{
  width:100%;min-width:0;height:40px;box-sizing:border-box;padding:8px 10px;
  border:1px solid #cda866;border-radius:9px;background:#fffdf8;color:#49320c;
  font-variant-numeric:tabular-nums;letter-spacing:.01em;
}
.twmpw-wom-custom-period input:focus{outline:none;border-color:#966017;box-shadow:0 0 0 3px rgba(150,96,23,.14)}
.twmpw-wom-custom-period-arrow{align-self:center;color:#9b6b1a;font-weight:900;padding-top:18px}
.twmpw-wom-custom-period-error{display:block;min-height:15px;margin:5px 2px 0;color:#9b3b31;font-size:11px;font-weight:750}

.twmpw-wom-loss-summary-card{display:grid!important;grid-template-columns:minmax(0,1fr);align-content:start;gap:7px!important}
.twmpw-wom-loss-summary-card>span{display:flex;align-items:center;justify-content:space-between;gap:8px}
.twmpw-wom-loss-summary-card>button{
  width:100%;min-height:30px;padding:5px 8px;border:1px solid #cda866;border-radius:8px;
  background:#fffdf8;color:#714b0e;font-size:10px;font-weight:850;line-height:1.2;
}
.twmpw-wom-loss-summary-card>button:hover:not(:disabled){background:#f5e2b6;border-color:#ae7721}
.twmpw-wom-loss-summary-card>button:disabled{opacity:.48;cursor:not-allowed}
.twmpw-wom-changes-list-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:1px}
.twmpw-wom-changes-list-head .twmpw-subhead{margin:0}
.twmpw-wom-changes-list-head .twmpw-btn{min-height:34px;padding:6px 10px;white-space:nowrap}

.twmpw-wom-modal-all-events,.twmpw-wom-modal-loss-summary,.twmpw-wom-modal-capture-summary{z-index:9100}
.twmpw-wom-modal-all-events .twmpw-wom-modal-card,
.twmpw-wom-modal-loss-summary .twmpw-wom-modal-card,
.twmpw-wom-modal-capture-summary .twmpw-wom-modal-card{
  width:min(1120px,calc(100vw - 30px));height:min(880px,calc(100vh - 24px));
  grid-template-rows:auto minmax(0,1fr) auto;
}
.twmpw-wom-modal-all-events header>div,.twmpw-wom-modal-loss-summary header>div,.twmpw-wom-modal-capture-summary header>div{display:grid;gap:2px;min-width:0}
.twmpw-wom-modal-all-events header small,.twmpw-wom-modal-loss-summary header small,.twmpw-wom-modal-capture-summary header small{color:#80663b;font-size:11px;font-weight:700;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

.twmpw-wom-event-browser{display:grid;gap:12px;min-width:0}
.twmpw-wom-event-browser-filters{
  position:sticky;top:-12px;z-index:3;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;
  padding:12px;margin:-12px -12px 0;background:#fffaf0;border-bottom:1px solid #e1cc9d;
}
.twmpw-wom-event-browser-filters label{display:grid;gap:5px;min-width:0;color:#6c4e1c;font-size:10px;font-weight:850}
.twmpw-wom-event-browser-filters label.is-search{grid-column:span 2}
.twmpw-wom-event-browser-filters input,.twmpw-wom-event-browser-filters select,
.twmpw-wom-event-pagination select{
  width:100%;min-width:0;height:38px;box-sizing:border-box;padding:7px 9px;border:1px solid #cda866;
  border-radius:9px;background:#fffdf8;color:#49320c;
}
.twmpw-wom-event-browser-filters input:focus,.twmpw-wom-event-browser-filters select:focus{outline:none;border-color:#966017;box-shadow:0 0 0 3px rgba(150,96,23,.12)}
.twmpw-wom-event-browser-toolbar{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 12px;border:1px solid #dfc58d;border-radius:11px;background:#fff8e8;color:#6c4e1c}
.twmpw-wom-event-browser-toolbar>div{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.twmpw-wom-all-events-list{display:grid;gap:7px;min-width:0}
.twmpw-wom-all-event-row{
  width:100%;min-width:0;display:grid;grid-template-columns:12px minmax(0,1fr) auto;align-items:center;gap:10px;
  padding:10px 11px;border:1px solid #ead7af;border-radius:10px;background:#fffdf8;color:#5b421d;text-align:left;
}
.twmpw-wom-all-event-row:hover{border-color:#cda866;background:#fff7e5}
.twmpw-wom-all-event-row>span:nth-child(2){display:grid;gap:3px;min-width:0}
.twmpw-wom-all-event-row b,.twmpw-wom-all-event-row small,.twmpw-wom-all-event-row em{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.twmpw-wom-all-event-row small{color:#80663b;font-size:10px}.twmpw-wom-all-event-row em{color:#7a4b00;font-size:10px;font-style:normal;font-weight:850}
.twmpw-wom-all-event-row time{display:grid;gap:2px;text-align:right;color:#6b4a17;font-size:10px;font-weight:850;white-space:nowrap}
.twmpw-wom-all-event-row time small{font-weight:700;color:#927444}
.twmpw-wom-event-empty{padding:24px;text-align:center;border:1px dashed #d9bd82;border-radius:10px;background:#fff8e8;color:#80663b;font-weight:750}
.twmpw-wom-event-pagination{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border-top:1px solid #e1cc9d}
.twmpw-wom-event-pagination label{display:flex;align-items:center;gap:8px;color:#6c4e1c;font-size:10px;font-weight:850}
.twmpw-wom-event-pagination select{width:78px;height:34px}
.twmpw-wom-event-pagination>div{display:flex;align-items:center;gap:10px;color:#6c4e1c}
.twmpw-wom-event-pagination button{width:34px;height:34px;display:inline-flex;align-items:center;justify-content:center;padding:0}
.twmpw-wom-event-pagination button:disabled{opacity:.45;cursor:not-allowed}

.twmpw-wom-loss-hero{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
.twmpw-wom-loss-hero article{display:grid;gap:3px;padding:14px;border:1px solid #dfc58d;border-radius:12px;background:#fff8e8;color:#6c4e1c}
.twmpw-wom-loss-hero article.is-returned{border-color:#b9d8bf;background:#f0f8f1}.twmpw-wom-loss-hero article.is-net{border-color:#e2adad;background:#fff4f1}
.twmpw-wom-loss-hero small{font-size:10px;font-weight:850;text-transform:uppercase;letter-spacing:.035em}.twmpw-wom-loss-hero b{font-size:26px;line-height:1;color:#4f3510}.twmpw-wom-loss-hero span{font-size:10px;color:#80663b}
.twmpw-wom-loss-actions{display:flex;gap:9px;flex-wrap:wrap;margin:12px 0}.twmpw-wom-loss-actions .twmpw-btn{min-height:40px}
.twmpw-wom-loss-section{display:grid;gap:10px;margin-top:14px;padding-top:14px;border-top:1px solid #e2cfaa}
.twmpw-wom-loss-section-head{display:flex;align-items:center;justify-content:space-between;gap:10px}.twmpw-wom-loss-section-head>span{color:#80663b;font-size:10px;font-weight:750}
.twmpw-wom-loss-allies{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
.twmpw-wom-loss-ally-card{display:grid;gap:10px;padding:12px;border:1px solid #dfc58d;border-radius:11px;background:#fffdf8}
.twmpw-wom-loss-ally-card header{display:flex;align-items:flex-start;justify-content:space-between;gap:9px;padding:0;background:transparent;border-radius:0}
.twmpw-wom-loss-ally-card header b{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#4f3510}.twmpw-wom-loss-ally-card header span{color:#9b3b31;font-size:10px;font-weight:850;white-space:nowrap}
.twmpw-wom-loss-ally-card>div{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.twmpw-wom-loss-ally-card>div span{display:grid;gap:2px;padding:8px;border-radius:8px;background:#fff8e8;color:#80663b;font-size:9px}.twmpw-wom-loss-ally-card>div b{font-size:15px;color:#4f3510}
.twmpw-wom-loss-timeline{height:150px;display:flex;align-items:stretch;gap:4px;padding:12px 10px 24px;border:1px solid #dfc58d;border-radius:11px;background:linear-gradient(180deg,#fffdf8,#fff8e8)}
.twmpw-wom-loss-timeline>div{position:relative;flex:1;min-width:3px;display:flex;align-items:flex-end;justify-content:center;border-bottom:1px solid rgba(173,132,64,.28)}
.twmpw-wom-loss-timeline>div>span{width:min(18px,78%);height:var(--loss-height);min-height:3px;border-radius:5px 5px 2px 2px;background:linear-gradient(180deg,#c04939,#8e2f25);box-shadow:0 1px 0 rgba(255,255,255,.5) inset}
.twmpw-wom-loss-timeline>div>small{position:absolute;left:50%;bottom:-18px;transform:translateX(-50%);color:#8a6a35;font-size:8px;white-space:nowrap}
.twmpw-wom-loss-return-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.twmpw-wom-loss-return-stats>span{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:10px 12px;border:1px solid #dfc58d;border-radius:10px;background:#fff8e8;color:#6c4e1c}.twmpw-wom-loss-return-stats>small{grid-column:1/-1;color:#80663b;line-height:1.45}

@media(max-width:900px){
  .twmpw-wom-event-browser-filters{grid-template-columns:repeat(2,minmax(0,1fr))}
  .twmpw-wom-loss-hero{grid-template-columns:repeat(2,minmax(0,1fr))}
  .twmpw-wom-loss-allies{grid-template-columns:1fr}
}
@media(max-width:620px){
  .twmpw-wom-custom-period{grid-template-columns:1fr}.twmpw-wom-custom-period-arrow{display:none}
  .twmpw-wom-changes-list-head{align-items:stretch;flex-direction:column}.twmpw-wom-changes-list-head .twmpw-btn{width:100%}
  .twmpw-wom-modal-all-events .twmpw-wom-modal-card,.twmpw-wom-modal-loss-summary .twmpw-wom-modal-card,
.twmpw-wom-modal-capture-summary .twmpw-wom-modal-card{width:calc(100vw - 14px);height:calc(100vh - 14px)}
  .twmpw-wom-event-browser-filters{grid-template-columns:1fr}.twmpw-wom-event-browser-filters label.is-search{grid-column:auto}
  .twmpw-wom-event-browser-toolbar,.twmpw-wom-event-pagination{align-items:stretch;flex-direction:column}.twmpw-wom-event-browser-toolbar>div{justify-content:stretch}.twmpw-wom-event-browser-toolbar .twmpw-btn{flex:1}
  .twmpw-wom-all-event-row{grid-template-columns:12px minmax(0,1fr)}.twmpw-wom-all-event-row time{grid-column:2;text-align:left}
  .twmpw-wom-loss-hero{grid-template-columns:1fr 1fr}.twmpw-wom-loss-actions{display:grid;grid-template-columns:1fr}.twmpw-wom-loss-actions .twmpw-btn{width:100%}
  .twmpw-wom-loss-ally-card>div,.twmpw-wom-loss-return-stats{grid-template-columns:1fr}.twmpw-wom-loss-return-stats>small{grid-column:auto}
  .twmpw-wom-loss-timeline{gap:2px}.twmpw-wom-loss-timeline>div>small{display:none}
}
.twmpw-wom-modal-coordinates{z-index:9200}
.twmpw-wom-loss-note{color:#80663b;font-size:10px;line-height:1.4}
.twmpw-wom-drawbar .twmpw-wom-mode-btn{transition:none!important}
.twmpw-wom-loss-warning{border:1px solid #d59a3a;border-radius:12px;background:#fff4d8;color:#71480b;padding:10px 12px;font-size:13px;font-weight:750;line-height:1.4}

/* V14.7.1: concise explanation of historical event versus current owner */
.twmpw-wom-event-context-note{
  margin:-2px 0 10px;
  padding:9px 12px;
  border:1px solid rgba(190,139,45,.34);
  border-radius:10px;
  background:#fff7e4;
  color:#72521f;
  font-size:12px;
  line-height:1.4;
}


/* World Map Stage 2 V14.7.2 — exact historical event moment without ambiguous “Стало тогда” */
.twmpw-wom-tip-change .twmpw-wom-tip-row.is-event-moment{
  grid-template-columns:minmax(150px,auto) minmax(92px,1fr);
  align-items:start;
}
.twmpw-wom-tip-change .twmpw-wom-tip-row.is-event-moment>span{
  white-space:nowrap;
  font-variant-numeric:tabular-nums;
  letter-spacing:-.01em;
}
@media(max-width:430px){
  .twmpw-wom-tip-change .twmpw-wom-tip-row.is-event-moment{
    grid-template-columns:minmax(135px,auto) minmax(82px,1fr);
    gap:7px;
  }
  .twmpw-wom-tip-change .twmpw-wom-tip-row.is-event-moment>span{font-size:11px;}
}

/* World Map Stage 2 V14.8 — history integrity and diplomatic owner colours */
.twmpw-wom-tip-change .twmpw-wom-tip-row.is-owner b{
  color:var(--owner-color,#806b48)!important;
  font-weight:900;
}
.twmpw-wom-change-row em.twmpw-wom-change-current{
  color:var(--owner-color,#806b48)!important;
}
.twmpw-wom-history-range{
  flex-basis:100%;
  color:#6f542b;
  border-top:1px solid rgba(191,149,78,.28);
  padding-top:7px;
  margin-top:2px;
}


/* World Map Stage 2 V14.9 — concise capture/loss summaries */
.twmpw-wom-capture-summary-card>button{border-color:#9fc7a8;background:#f4fbf5;color:#2f6c3f}
.twmpw-wom-capture-summary-card>button:hover:not(:disabled){background:#e7f5ea;border-color:#74aa80}
.twmpw-wom-capture-hero article:nth-child(1),
.twmpw-wom-capture-hero article:nth-child(2){border-color:#b8d6bf;background:#f4faf5}
.twmpw-wom-summary-leader{
  display:grid;gap:5px;margin-top:12px;padding:12px 14px;border:1px solid #dfc58d;border-radius:12px;
  background:linear-gradient(135deg,#fff8e8,#fffdf8);color:#6c4e1c;
}
.twmpw-wom-summary-leader.is-capture{border-color:#acd0b4;background:linear-gradient(135deg,#eef8f0,#fffdf8)}
.twmpw-wom-summary-leader>small{font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.035em;color:#8a6a35}
.twmpw-wom-summary-leader>div{display:flex;align-items:center;justify-content:space-between;gap:10px;min-width:0}
.twmpw-wom-summary-leader>div b{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#4f3510;font-size:16px}
.twmpw-wom-summary-leader>div span{flex:0 0 auto;padding:4px 8px;border-radius:999px;background:#f1dfb8;color:#6b470e;font-size:10px;font-weight:900}
.twmpw-wom-summary-leader.is-capture>div span{background:#dceddf;color:#2f6c3f}
.twmpw-wom-summary-leader p{margin:0;color:#80663b;font-size:10px;line-height:1.35}
.twmpw-wom-summary-players{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
.twmpw-wom-summary-player-card{display:grid;gap:7px;padding:11px 12px;border:1px solid #dfc58d;border-radius:11px;background:#fffdf8;min-width:0}
.twmpw-wom-summary-player-card header{display:flex;align-items:center;justify-content:space-between;gap:9px;padding:0;background:transparent;border-radius:0;min-width:0}
.twmpw-wom-summary-player-card header b{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#4f3510}
.twmpw-wom-summary-player-card header span{flex:0 0 auto;color:#805918;font-size:10px;font-weight:900}
.twmpw-wom-summary-player-card>div{height:6px;border-radius:999px;background:#efe2c5;overflow:hidden}
.twmpw-wom-summary-player-card>div span{display:block;width:var(--summary-share);height:100%;border-radius:inherit;background:linear-gradient(90deg,#ad6b15,#d19b42)}
.twmpw-wom-modal-capture-summary .twmpw-wom-summary-player-card>div span{background:linear-gradient(90deg,#347b48,#70b17e)}
.twmpw-wom-summary-player-card>small{color:#80663b;font-size:10px;line-height:1.3}
.twmpw-wom-loss-ally-card.is-capture{border-color:#b9d8bf;background:#f7fcf8}
.twmpw-wom-loss-ally-card.is-capture header span{color:#347b48}
.twmpw-wom-loss-timeline.is-capture>div>span{background:linear-gradient(180deg,#73b580,#337a48)}
.twmpw-wom-capture-peak{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:9px 11px;border:1px solid #c9decf;border-radius:10px;background:#f3faf4;color:#54715c;font-size:10px}
.twmpw-wom-capture-peak b{color:#2f6c3f;text-align:right}
@media(max-width:900px){.twmpw-wom-summary-players{grid-template-columns:1fr}}
@media(max-width:620px){
  .twmpw-wom-summary-leader>div,.twmpw-wom-capture-peak{align-items:flex-start;flex-direction:column}
  .twmpw-wom-summary-leader>div span{align-self:flex-start}
  .twmpw-wom-capture-peak b{text-align:left}
}


/* World Map Stage 2 V14.10 — exact external-capture classification */
.twmpw-wom-enemy-summary-card>button{border-color:#dda7a1;background:#fff5f3;color:#8d352c}
.twmpw-wom-enemy-summary-card>button:hover:not(:disabled){background:#fde8e4;border-color:#c87970}
.twmpw-wom-barbarian-summary-card>button{border-color:#d9bd76;background:#fff8e4;color:#815b13}
.twmpw-wom-barbarian-summary-card>button:hover:not(:disabled){background:#f8e9bd;border-color:#ba8b2b}
.twmpw-wom-capture-breakdown{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px}
.twmpw-wom-capture-breakdown article{display:grid;gap:3px;padding:11px 12px;border:1px solid #dfc58d;border-radius:11px;background:#fffdf8;min-width:0}
.twmpw-wom-capture-breakdown article span{color:#6c4e1c;font-size:11px;font-weight:850;line-height:1.25}
.twmpw-wom-capture-breakdown article b{color:#4f3510;font-size:22px;line-height:1.05}
.twmpw-wom-capture-breakdown article small{color:#80663b;font-size:9px}
.twmpw-wom-capture-breakdown article.is-returned,.twmpw-wom-capture-breakdown article.is-coalition{border-color:#afd1b7;background:#f2f9f3}
.twmpw-wom-capture-breakdown article.is-enemy{border-color:#dfaaa4;background:#fff5f3}
.twmpw-wom-capture-breakdown article.is-barbarian{border-color:#dfc57f;background:#fff8e5}
.twmpw-wom-capture-breakdown article.is-nap{border-color:#d8c47a;background:#fffbed}
.twmpw-wom-capture-breakdown article.is-neutral{border-color:#d9cdb5;background:#fbf8f0}
.twmpw-wom-capture-hero.is-enemy article:nth-child(1),.twmpw-wom-capture-hero.is-enemy article:nth-child(2){border-color:#dfaaa4;background:#fff5f3}
.twmpw-wom-capture-hero.is-barbarian article:nth-child(1),.twmpw-wom-capture-hero.is-barbarian article:nth-child(2){border-color:#dfc57f;background:#fff8e5}
.twmpw-wom-summary-leader.is-enemy{border-color:#dfaaa4;background:linear-gradient(135deg,#fff2ef,#fffdf8)}
.twmpw-wom-summary-leader.is-enemy>div span{background:#f5d7d2;color:#87342b}
.twmpw-wom-summary-leader.is-barbarian{border-color:#ddc078;background:linear-gradient(135deg,#fff7df,#fffdf8)}
.twmpw-wom-summary-leader.is-barbarian>div span{background:#f1dfad;color:#785311}
.twmpw-wom-modal-enemy-summary .twmpw-wom-summary-player-card>div span{background:linear-gradient(90deg,#9b3f34,#dc786c)}
.twmpw-wom-modal-barbarian-summary .twmpw-wom-summary-player-card>div span{background:linear-gradient(90deg,#9b6b16,#ddb956)}
.twmpw-wom-loss-ally-card.is-enemy{border-color:#dfaaa4;background:#fff7f5}
.twmpw-wom-loss-ally-card.is-enemy header span{color:#9b3b31}
.twmpw-wom-loss-ally-card.is-barbarian{border-color:#dfc57f;background:#fffaf0}
.twmpw-wom-loss-ally-card.is-barbarian header span{color:#8c6215}
.twmpw-wom-loss-timeline.is-enemy>div>span{background:linear-gradient(180deg,#dc786c,#92372e)}
.twmpw-wom-loss-timeline.is-barbarian>div>span{background:linear-gradient(180deg,#e1bd5c,#9a6b17)}
.twmpw-wom-capture-peak.is-enemy{border-color:#e3b4ae;background:#fff5f3;color:#85514b}.twmpw-wom-capture-peak.is-enemy b{color:#8d352c}
.twmpw-wom-capture-peak.is-barbarian{border-color:#dfc57f;background:#fff8e5;color:#826b3b}.twmpw-wom-capture-peak.is-barbarian b{color:#815b13}
@media(max-width:900px){.twmpw-wom-capture-breakdown{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:620px){.twmpw-wom-capture-breakdown{grid-template-columns:1fr}}

/* World Map Stage 2 V14.11.2 — independent diplomacy layers and adjacency-aware palettes */
.twmpw-wom-diplomacy-colors{
  display:grid;
  grid-template-columns:minmax(190px,.9fr) minmax(360px,1.45fr);
  gap:10px 16px;
  align-items:center;
  padding:11px 12px;
  border:1px solid #dec792;
  border-radius:11px;
  background:#fff8e8;
}
.twmpw-wom-diplomacy-colors-copy{display:grid;gap:3px;min-width:0}
.twmpw-wom-diplomacy-colors-copy b{color:#5b421d;line-height:1.2}
.twmpw-wom-diplomacy-colors-copy small{color:#80663b;font-size:11px;line-height:1.35}
.twmpw-wom-diplomacy-color-modes{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:5px;
  min-width:0;
  padding:4px;
  border:1px solid #d8bd83;
  border-radius:10px;
  background:#f3e2bd;
}
.twmpw-wom-diplomacy-color-modes button{
  min-width:0!important;
  min-height:36px;
  padding:6px 9px!important;
  border:1px solid transparent!important;
  border-radius:8px!important;
  background:transparent!important;
  color:#664819!important;
  font-size:12px!important;
  font-weight:900!important;
  line-height:1.15!important;
  white-space:normal;
  box-shadow:none!important;
}
.twmpw-wom-diplomacy-color-modes button:hover{background:rgba(255,250,238,.72)!important}
.twmpw-wom-diplomacy-color-modes button.is-active{
  border-color:#c58c2a!important;
  background:#fffaf0!important;
  color:#4d320b!important;
  box-shadow:0 1px 4px rgba(94,57,10,.16)!important;
}
.twmpw-wom-diplomacy-color-legend{
  grid-column:1/-1;
  display:flex;
  flex-wrap:wrap;
  gap:6px 14px;
  padding-top:1px;
  color:#755a2e;
  font-size:11px;
  font-weight:800;
}
.twmpw-wom-diplomacy-color-legend span{display:inline-flex;align-items:center;gap:6px;white-space:nowrap}
.twmpw-wom-diplomacy-color-legend i{
  width:11px;
  height:11px;
  border:1px solid color-mix(in srgb,var(--legend-color) 72%,#4d320b 28%);
  border-radius:3px;
  background:var(--legend-color);
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.35);
}
@media(max-width:860px){
  .twmpw-wom-diplomacy-colors{grid-template-columns:1fr}
  .twmpw-wom-diplomacy-color-modes,.twmpw-wom-diplomacy-color-legend{grid-column:1}
}
@media(max-width:560px){
  .twmpw-wom-diplomacy-color-modes{grid-template-columns:1fr}
  .twmpw-wom-diplomacy-color-modes button{min-height:34px}
}

.twmpw-wom-diplomacy-color-block{display:grid;gap:8px;min-width:0}
.twmpw-wom-diplomacy-color-block-copy{display:grid;gap:3px;min-width:0}
.twmpw-wom-diplomacy-color-block-copy b,.twmpw-wom-diplomacy-auto-copy b{color:#5b421d;line-height:1.2}
.twmpw-wom-diplomacy-color-block-copy small,.twmpw-wom-diplomacy-auto-copy small{color:#80663b;font-size:11px;line-height:1.35}
.twmpw-wom-diplomacy-auto-toggle{grid-column:1 / -1;margin:0}
.twmpw-wom-diplomacy-auto-copy{display:grid;gap:3px;min-width:0}
.twmpw-wom-diplomacy-auto-toggle{border-color:#dec792;background:rgba(255,255,255,.68)}
.twmpw-wom-diplomacy-auto-toggle:has(input:checked){border-color:#c99a45;background:#fffaf0;box-shadow:inset 3px 0 0 #b67a19}
@media(max-width:560px){.twmpw-wom-diplomacy-color-block{gap:10px}}


/* World Map Stage 2 V14.12 — Statistics */
.twmpw-wom-modal-statistics{z-index:10080}
.twmpw-wom-modal-statistics>.twmpw-wom-modal-card{width:min(1420px,96vw);height:min(930px,94vh);max-width:none;display:grid;grid-template-rows:auto minmax(0,1fr) auto}
.twmpw-wom-modal-statistics>.twmpw-wom-modal-card>header{align-items:flex-start}
.twmpw-wom-modal-statistics>.twmpw-wom-modal-card>header>div:first-child{display:grid;gap:2px;min-width:0}
.twmpw-wom-modal-statistics>.twmpw-wom-modal-card>header small{color:#80663b;font-size:11px;font-weight:700}
.twmpw-wom-modal-statistics>.twmpw-wom-modal-card>main{padding:0;overflow:auto;background:#f8f1df}
.twmpw-wom-modal-statistics>.twmpw-wom-modal-card>footer{justify-content:flex-end;gap:14px}

.twmpw-wom-modal-statistics.is-fullscreen{padding:0}
.twmpw-wom-modal-statistics.is-fullscreen>.twmpw-wom-modal-card{width:100vw;height:100vh;max-height:none;border-radius:0;border-left:0;border-right:0}
.twmpw-wom-modal-statistics.is-fullscreen>.twmpw-wom-modal-card>header{border-radius:0}
.twmpw-wom-stat-window-actions{display:flex!important;align-items:center;gap:4px;flex:0 0 auto}
.twmpw-wom-stat-window-actions button{display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;padding:0!important;border-radius:8px!important;color:#5b421d!important}
.twmpw-wom-stat-window-actions button:hover{background:rgba(255,250,238,.72)!important}
.twmpw-wom-stat-window-actions [data-stat-maximize] svg{width:18px;height:18px;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-stat-window-actions [data-stat-close]{font-size:24px!important;line-height:1!important}
.twmpw-wom-stat-info-label{display:inline-flex;align-items:center;gap:5px;min-width:0;cursor:help}
.twmpw-wom-stat-info-label>span{min-width:0}
.twmpw-wom-stat-info-label>i{display:inline-grid;place-items:center;width:15px;height:15px;flex:0 0 auto;border:1px solid #b9995f;border-radius:50%;background:#fff8e8;color:#7b571f;font-size:9px;font-style:normal;font-weight:900;line-height:1}
.twmpw-wom-stat-tooltip{position:fixed;z-index:10120;display:none;max-width:min(330px,calc(100vw - 28px));padding:9px 11px;border:1px solid #bfa36b;border-radius:9px;background:#fffaf0;color:#5b421d;box-shadow:0 10px 30px rgba(46,31,9,.28);font-size:11px;font-weight:700;line-height:1.42;white-space:pre-line;pointer-events:none;transform:translateZ(0)}
.twmpw-wom-stat-tooltip.is-visible{display:block}
.twmpw-wom-stat-kpi[data-stat-tip],.twmpw-wom-stat-insights article[data-stat-tip],.twmpw-wom-stat-donut-legend>span[data-stat-tip],.twmpw-wom-stat-bars>div[data-stat-tip],.twmpw-wom-stat-metric-list>span[data-stat-tip]{cursor:help}
.twmpw-wom-stat-shell{min-width:0}
.twmpw-wom-stat-sticky{position:sticky;top:0;z-index:8;padding:12px 14px 0;background:linear-gradient(#fffaf0 85%,rgba(255,250,240,.92));border-bottom:1px solid #dec792;box-shadow:0 5px 12px rgba(86,54,14,.08)}
.twmpw-wom-stat-filters{display:grid;grid-template-columns:120px 150px minmax(170px,1fr) minmax(170px,1fr) 115px 160px auto;gap:8px;align-items:end}
.twmpw-wom-stat-filters label{display:grid;gap:4px;min-width:0;color:#6d521d;font-size:11px;font-weight:900}
.twmpw-wom-stat-filters select{min-width:0;width:100%;height:36px}
.twmpw-wom-stat-filters>button{height:36px;min-height:36px;display:inline-flex;align-items:center;justify-content:center;padding-block:0;line-height:1;white-space:nowrap}
.twmpw-wom-stat-tabs{display:flex;gap:4px;margin-top:10px;overflow-x:auto;scrollbar-width:thin}
.twmpw-wom-stat-tabs button{min-width:104px;padding:9px 14px;border:0;border-bottom:3px solid transparent;background:transparent;color:#73552a;font-size:12px;font-weight:900;white-space:nowrap}
.twmpw-wom-stat-tabs button:hover{background:rgba(229,202,143,.22)}
.twmpw-wom-stat-tabs button.is-active{border-bottom-color:#9a6014;color:#4d320b;background:#fff}
.twmpw-wom-stat-context{display:flex;flex-wrap:wrap;align-items:center;gap:8px 18px;padding:12px 16px 4px;color:#71552a;font-size:11px}
.twmpw-wom-stat-context>span{display:flex;align-items:center;gap:5px}
.twmpw-wom-stat-context>span:first-child{display:grid;gap:1px;margin-right:auto}
.twmpw-wom-stat-context small{color:#8d7348}
.twmpw-wom-stat-warning,.twmpw-wom-stat-error{margin:10px 16px;padding:11px 13px;border:1px solid #d9a047;border-radius:12px;background:#fff2d2;color:#7a5315}
.twmpw-wom-stat-content{display:grid;gap:14px;padding:12px 16px 22px}
.twmpw-wom-stat-kpis{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px}
.twmpw-wom-stat-kpi{position:relative;display:grid;gap:4px;min-height:118px;padding:13px 14px;border:1px solid #dec792;border-radius:14px;background:#fffaf0;box-shadow:0 4px 12px rgba(86,54,14,.07);overflow:hidden}
.twmpw-wom-stat-kpi::before{content:'';position:absolute;inset:0 auto 0 0;width:4px;background:#b68a42}
.twmpw-wom-stat-kpi.is-positive::before{background:#2e9a59}.twmpw-wom-stat-kpi.is-negative::before{background:#c44535}
.twmpw-wom-stat-kpi small{color:#80663b;font-size:11px;font-weight:900}.twmpw-wom-stat-kpi b{color:#4d320b;font-size:25px;line-height:1}.twmpw-wom-stat-kpi span{align-self:end;color:#80663b;font-size:11px;line-height:1.35}.twmpw-wom-stat-kpi em{position:absolute;top:12px;right:12px;padding:3px 7px;border-radius:999px;background:#f1e0b9;color:#6f4f1d;font-size:10px;font-style:normal;font-weight:900}
.twmpw-wom-stat-insights{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.twmpw-wom-stat-insights article{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:3px 10px;padding:11px 13px;border:1px solid #dec792;border-radius:12px;background:#fff}.twmpw-wom-stat-insights small{color:#80663b;font-weight:900}.twmpw-wom-stat-insights b{color:#4d320b;text-align:right}.twmpw-wom-stat-insights span{grid-column:1/-1;color:#80663b;font-size:11px;line-height:1.35}.twmpw-wom-stat-insights article.is-positive{border-left:4px solid #2e9a59}.twmpw-wom-stat-insights article.is-negative{border-left:4px solid #c44535}
.twmpw-wom-stat-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.twmpw-wom-stat-grid.is-wide{grid-template-columns:minmax(0,1.55fr) minmax(330px,.75fr)}
.twmpw-wom-stat-card,.twmpw-wom-stat-chart,.twmpw-wom-stat-table-card{min-width:0;padding:13px;border:1px solid #dec792;border-radius:14px;background:#fffaf0;box-shadow:0 4px 12px rgba(86,54,14,.06)}
.twmpw-wom-stat-card>header,.twmpw-wom-stat-chart-head,.twmpw-wom-stat-table-card>header{display:flex;justify-content:space-between;gap:12px;align-items:flex-start;margin-bottom:11px}.twmpw-wom-stat-card>header>div,.twmpw-wom-stat-chart-head>div,.twmpw-wom-stat-table-card>header>div{display:grid;gap:2px}.twmpw-wom-stat-card header b,.twmpw-wom-stat-chart-head b,.twmpw-wom-stat-table-card header b{color:#5b421d}.twmpw-wom-stat-card header small,.twmpw-wom-stat-chart-head small,.twmpw-wom-stat-table-card header small{color:#80663b;font-size:11px}
.twmpw-wom-stat-legend{display:flex;flex-wrap:wrap;gap:8px 12px;color:#71552a;font-size:10px;font-weight:900}.twmpw-wom-stat-legend span::before{content:'';display:inline-block;width:9px;height:9px;margin-right:5px;border-radius:3px;vertical-align:-1px}.twmpw-wom-stat-legend .is-gain::before{background:#2e9a59}.twmpw-wom-stat-legend .is-loss::before{background:#c44535}.twmpw-wom-stat-legend .is-net::before{background:#8e5a16}
.twmpw-wom-stat-trend{display:block;width:100%;height:auto;min-height:210px;overflow:visible}.twmpw-wom-stat-trend line{stroke:#cdb88c;stroke-width:1}.twmpw-wom-stat-trend rect.is-gain{fill:rgba(46,154,89,.68)}.twmpw-wom-stat-trend rect.is-loss{fill:rgba(196,69,53,.58)}.twmpw-wom-stat-trend polyline{fill:none;stroke:#8e5a16;stroke-width:3;stroke-linejoin:round;stroke-linecap:round}.twmpw-wom-stat-trend rect.is-hit{fill:transparent;pointer-events:all;cursor:help}.twmpw-wom-stat-trend text{fill:#8a7045;font-size:9px}
.twmpw-wom-stat-donut-wrap{display:grid;grid-template-columns:170px minmax(0,1fr);gap:18px;align-items:center}.twmpw-wom-stat-donut{display:grid;place-items:center;width:160px;aspect-ratio:1;border-radius:50%;background:conic-gradient(var(--stat-donut));position:relative}.twmpw-wom-stat-donut::after{content:'';position:absolute;inset:28px;border-radius:50%;background:#fffaf0}.twmpw-wom-stat-donut>span{position:relative;z-index:1;display:grid;text-align:center}.twmpw-wom-stat-donut b{font-size:22px;color:#4d320b}.twmpw-wom-stat-donut small{font-size:10px;color:#80663b}.twmpw-wom-stat-donut-legend{display:grid;gap:7px}.twmpw-wom-stat-donut-legend>span{display:grid;grid-template-columns:12px minmax(0,1fr) auto;gap:7px;align-items:center;color:#65491c;font-size:11px}.twmpw-wom-stat-donut-legend i{width:10px;height:10px;border-radius:3px;background:var(--stat-color)}.twmpw-wom-stat-donut-legend em{font-style:normal;color:#80663b}
.twmpw-wom-stat-bars{display:grid;gap:9px}.twmpw-wom-stat-bars>div{display:grid;grid-template-columns:110px minmax(0,1fr) 52px 44px;gap:8px;align-items:center;font-size:11px}.twmpw-wom-stat-bars i{height:9px;border-radius:999px;background:linear-gradient(90deg,var(--stat-color) var(--stat-width),#eadfc8 var(--stat-width));box-shadow:inset 0 0 0 1px rgba(95,62,19,.12)}.twmpw-wom-stat-bars em{font-style:normal;color:#80663b;text-align:right}
.twmpw-wom-stat-ranking-bars{display:grid;gap:6px}.twmpw-wom-stat-ranking-bars button{display:grid;grid-template-columns:24px minmax(0,1fr) 58px 44px;gap:8px;align-items:center;width:100%;padding:7px 8px;border:1px solid transparent;border-radius:9px;background:transparent;text-align:left}.twmpw-wom-stat-ranking-bars button:hover{border-color:#d9bd82;background:#fff}.twmpw-wom-stat-ranking-bars button>em{font-style:normal;color:#9b7b43;font-weight:900}.twmpw-wom-stat-ranking-bars button>span{display:grid;gap:4px;min-width:0}.twmpw-wom-stat-ranking-bars button>span b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#5b421d}.twmpw-wom-stat-ranking-bars button i{height:5px;border-radius:99px;background:linear-gradient(90deg,var(--stat-color) var(--stat-width),#eadfc8 var(--stat-width))}.twmpw-wom-stat-ranking-bars strong{text-align:right;color:#5b421d}.twmpw-wom-stat-ranking-bars small{text-align:right;color:#80663b}
.twmpw-wom-stat-activity{display:grid;gap:3px;min-width:540px}.twmpw-wom-stat-hours,.twmpw-wom-stat-activity-row{display:grid;grid-template-columns:28px repeat(24,minmax(10px,1fr));gap:2px}.twmpw-wom-stat-hours::before{content:''}.twmpw-wom-stat-hours span{font-size:8px;color:#90754a;text-align:center}.twmpw-wom-stat-activity-row b{font-size:9px;color:#80663b}.twmpw-wom-stat-activity-row i{height:15px;border:1px solid rgba(130,91,29,.12);border-radius:3px;background:color-mix(in srgb,#a96c16 calc(var(--stat-heat)*85%),#f0e4ca)}
.twmpw-wom-stat-activity-card{overflow:auto}
.twmpw-wom-stat-continent-grid{display:grid;grid-template-columns:repeat(10,minmax(42px,1fr));gap:4px}.twmpw-wom-stat-continent-grid button{display:grid;gap:1px;min-height:43px;padding:4px;border:1px solid rgba(134,91,26,.18);border-radius:7px;background:color-mix(in srgb,#a96c16 calc(var(--stat-heat)*76%),#f4e9d1);color:#5d421b}.twmpw-wom-stat-continent-grid button:hover,.twmpw-wom-stat-continent-grid button.is-active{outline:2px solid #8e5a16;outline-offset:1px}.twmpw-wom-stat-continent-grid b{font-size:9px}.twmpw-wom-stat-continent-grid span{font-size:10px}
.twmpw-wom-stat-contested{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.twmpw-wom-stat-contested button{display:grid;grid-template-columns:26px minmax(0,1fr);gap:8px;align-items:center;padding:8px;border:1px solid #dec792;border-radius:9px;background:#fff;text-align:left}.twmpw-wom-stat-contested em{font-style:normal;color:#9b7b43;font-weight:900}.twmpw-wom-stat-contested span{display:grid;gap:2px;min-width:0}.twmpw-wom-stat-contested b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#5b421d}.twmpw-wom-stat-contested small{color:#80663b}.twmpw-wom-stat-current-owner{display:block!important;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;border-left:3px solid var(--stat-owner-color);padding-left:6px;color:#65491c!important}.twmpw-wom-stat-current-owner strong{color:#4d320b}
.twmpw-wom-stat-metric-list{display:grid;gap:7px}.twmpw-wom-stat-metric-list>span,.twmpw-wom-stat-frontier>span{display:flex;justify-content:space-between;gap:12px;padding:8px 9px;border-radius:8px;background:#fff;color:#65491c}.twmpw-wom-stat-metric-list em,.twmpw-wom-stat-frontier em{font-style:normal;color:#80663b;text-align:right}.twmpw-wom-stat-frontier{display:grid;gap:5px;margin-top:10px;padding-top:10px;border-top:1px solid #dec792}.twmpw-wom-stat-frontier>small{color:#80663b;font-weight:900}
.twmpw-wom-stat-table-wrap{overflow:auto;max-height:620px}.twmpw-wom-stat-table{width:100%}.twmpw-wom-stat-table-card table{width:100%;border-collapse:separate;border-spacing:0;font-size:11px}.twmpw-wom-stat-table-card th{position:sticky;top:0;z-index:2;padding:8px;background:#f0dfbc;color:#65491c;text-align:right;white-space:nowrap}.twmpw-wom-stat-table-card th:nth-child(2){text-align:left}.twmpw-wom-stat-table-card td{padding:8px;border-bottom:1px solid #eadfc8;color:#65491c;text-align:right;white-space:nowrap}.twmpw-wom-stat-table-card td:nth-child(2){max-width:280px;text-align:left;overflow:hidden;text-overflow:ellipsis}.twmpw-wom-stat-table-card td.is-positive{color:#23834a;font-weight:900}.twmpw-wom-stat-table-card td.is-negative{color:#b43d31;font-weight:900}.twmpw-wom-stat-table-card td button{padding:5px 8px;border:1px solid #cfae70;border-radius:7px;background:#fff8e8;color:#684817;font-size:10px;font-weight:900}
.twmpw-wom-stat-loading{display:grid;place-items:center;gap:8px;min-height:420px;color:#6b4d20;text-align:center}.twmpw-wom-stat-loading span{width:32px;height:32px;border:3px solid #dfc797;border-top-color:#8e5a16;border-radius:50%;animation:twmpw-spin .8s linear infinite}.twmpw-wom-stat-loading small{color:#80663b}.twmpw-wom-stat-error{display:grid;gap:8px;justify-items:start}.twmpw-wom-stat-empty{padding:16px;color:#80663b;text-align:center}
@media(max-width:1180px){.twmpw-wom-stat-filters{grid-template-columns:repeat(3,minmax(0,1fr)) auto}.twmpw-wom-stat-kpis{grid-template-columns:repeat(3,minmax(0,1fr))}.twmpw-wom-stat-grid.is-wide{grid-template-columns:1fr}.twmpw-wom-stat-insights{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.twmpw-wom-modal-statistics>.twmpw-wom-modal-card{width:100vw;height:100vh;max-height:none;border-radius:0}.twmpw-wom-stat-filters{grid-template-columns:repeat(2,minmax(0,1fr))}.twmpw-wom-stat-kpis,.twmpw-wom-stat-grid,.twmpw-wom-stat-insights{grid-template-columns:1fr 1fr}.twmpw-wom-stat-donut-wrap{grid-template-columns:1fr;justify-items:center}.twmpw-wom-stat-contested{grid-template-columns:1fr}.twmpw-wom-stat-continent-grid{grid-template-columns:repeat(5,minmax(42px,1fr))}}
@media(max-width:520px){.twmpw-wom-stat-filters,.twmpw-wom-stat-kpis,.twmpw-wom-stat-grid,.twmpw-wom-stat-insights{grid-template-columns:1fr}.twmpw-wom-stat-context{display:grid}.twmpw-wom-stat-tabs button{min-width:92px}.twmpw-wom-stat-content{padding-inline:10px}.twmpw-wom-stat-sticky{padding-inline:10px}.twmpw-wom-modal-statistics>.twmpw-wom-modal-card>footer>span{display:none}}


/* World Map Stage 2 V14.12.2 — precise statistics UI */
.twmpw-wom-modal-statistics>.twmpw-wom-modal-card>header{align-items:center!important}
.twmpw-wom-stat-window-actions{align-self:center;display:grid!important;grid-auto-flow:column;grid-auto-columns:36px;gap:2px;height:36px;place-items:center}
.twmpw-wom-stat-window-actions button{box-sizing:border-box!important;display:grid!important;place-items:center!important;width:36px!important;height:36px!important;min-width:36px!important;min-height:36px!important;margin:0!important;padding:0!important;border:0!important;border-radius:8px!important;background:transparent!important;line-height:0!important;vertical-align:middle!important}
.twmpw-wom-stat-window-actions button svg{display:block;width:18px;height:18px;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-stat-window-actions [data-stat-close] svg{width:17px;height:17px}
.twmpw-wom-stat-tooltip[hidden]{display:none!important}
.twmpw-wom-stat-info-label{cursor:default}
.twmpw-wom-stat-info-trigger{cursor:help;transition:background .14s ease,border-color .14s ease,transform .14s ease}
.twmpw-wom-stat-info-trigger:hover,.twmpw-wom-stat-info-trigger:focus-visible{background:#fff;border-color:#98651c;outline:none;transform:translateY(-1px)}
.twmpw-wom-stat-kpi small>.twmpw-wom-stat-info-label{font:inherit;color:inherit}
.twmpw-wom-stat-custom-period{grid-column:1/-1;display:grid;grid-template-columns:minmax(190px,260px) auto minmax(190px,260px) minmax(190px,1fr);gap:8px;align-items:end;margin-top:8px;padding:9px 10px;border:1px solid #dec792;border-radius:10px;background:rgba(255,255,255,.56)}
.twmpw-wom-stat-custom-period[hidden]{display:none!important}
.twmpw-wom-stat-custom-period label{display:grid;gap:4px;min-width:0;color:#6d521d;font-size:11px;font-weight:900}
.twmpw-wom-stat-custom-period input{width:100%;height:36px;min-width:0}
.twmpw-wom-stat-custom-period>small{align-self:center;color:#a23c2b;font-size:11px;font-weight:800;line-height:1.3}
.twmpw-wom-stat-table-counter{align-self:center;color:#80663b;font-size:10px;font-weight:900;white-space:nowrap}
.twmpw-wom-stat-table-wrap{overflow:auto;max-height:620px;contain:layout paint style;overflow-anchor:none}
.twmpw-wom-stat-table-card tbody tr:not(.twmpw-wom-stat-spacer-row){height:42px}
.twmpw-wom-stat-spacer-row,.twmpw-wom-stat-spacer-row td{padding:0!important;border:0!important;background:transparent!important;pointer-events:none}
.twmpw-wom-stat-table-card tbody{contain:layout style}
@media(max-width:760px){.twmpw-wom-stat-custom-period{grid-template-columns:1fr auto 1fr}.twmpw-wom-stat-custom-period>small{grid-column:1/-1}}
@media(max-width:520px){.twmpw-wom-stat-custom-period{grid-template-columns:1fr}.twmpw-wom-stat-custom-period .twmpw-wom-custom-period-arrow{display:none}}

/* World Map Stage 2 V14.13.5 — coordinate suggestions and centered available-space toolbar */
.twmpw-wom-head{
  display:grid!important;
  grid-template-columns:max-content minmax(0,1fr) max-content!important;
  column-gap:12px!important;
}
.twmpw-wom-title{grid-column:1!important;justify-self:start;min-width:0}
.twmpw-wom-center-tools{grid-column:2;display:flex;align-items:center;justify-content:center;justify-self:stretch;gap:10px;min-width:0;padding:0 8px;box-sizing:border-box}
.twmpw-wom-drawbar{grid-column:auto!important;flex:0 0 auto}
.twmpw-wom-map-search{
  position:relative;z-index:8;width:clamp(220px,24vw,380px);min-width:220px;height:38px;display:grid;grid-template-columns:30px minmax(0,1fr) 32px;align-items:center;border:1px solid rgba(170,132,67,.62);border-radius:11px;background:rgba(255,250,240,.9);box-shadow:inset 0 1px 0 rgba(255,255,255,.78),0 2px 8px rgba(79,53,12,.06);box-sizing:border-box
}
.twmpw-wom-map-search:focus-within{border-color:#9d6b1e;box-shadow:0 0 0 2px rgba(157,107,30,.13),inset 0 1px 0 rgba(255,255,255,.82)}
.twmpw-wom-map-search-icon{display:flex;align-items:center;justify-content:center;color:#7a5a26;pointer-events:none}
.twmpw-wom-map-search-icon svg{width:17px!important;height:17px!important;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-map-search input{width:100%;min-width:0;height:36px;padding:0 4px;border:0!important;outline:0!important;background:transparent!important;color:#49320c;font:inherit;font-size:12px;font-weight:750;box-shadow:none!important}
.twmpw-wom-map-search input::placeholder{color:#927a50;font-weight:650}
.twmpw-wom-map-search>[data-map-search-toggle]{width:30px!important;height:30px!important;display:flex!important;align-items:center!important;justify-content:center!important;padding:0!important;margin-right:2px;border:0!important;background:transparent!important;border-radius:8px!important;color:#70501e}
.twmpw-wom-map-search>[data-map-search-toggle]:hover,.twmpw-wom-map-search>[data-map-search-toggle][aria-expanded="true"]{background:#f2dfb6!important}
.twmpw-wom-map-search>[data-map-search-toggle] svg{width:15px!important;height:15px!important;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;transition:transform .14s ease}
.twmpw-wom-map-search>[data-map-search-toggle][aria-expanded="true"] svg{transform:rotate(180deg)}
.twmpw-wom-map-search-popup{position:absolute;left:0;right:0;top:calc(100% + 6px);z-index:30;max-height:min(480px,62vh);overflow:auto;padding:5px;border:1px solid #bfa36b;border-radius:11px;background:#fffaf0;box-shadow:0 14px 38px rgba(50,35,12,.28);scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5;overscroll-behavior:contain}
.twmpw-wom-map-search-popup[hidden]{display:none!important}
.twmpw-wom-map-search-popup::-webkit-scrollbar{width:8px}.twmpw-wom-map-search-popup::-webkit-scrollbar-track{background:#fff7e5;border-radius:999px}.twmpw-wom-map-search-popup::-webkit-scrollbar-thumb{background:#c6a160;border:2px solid #fff7e5;border-radius:999px}
.twmpw-wom-map-search-popup button{width:100%;min-height:43px;display:grid;grid-template-columns:28px minmax(0,1fr);align-items:center;gap:8px;padding:6px 8px;border:0!important;border-radius:8px!important;background:transparent!important;text-align:left;color:#4c3511;box-sizing:border-box}
.twmpw-wom-map-search-popup button:hover,.twmpw-wom-map-search-popup button.is-active,.twmpw-wom-map-search-popup button[aria-selected="true"]{background:#f1dfb8!important}
.twmpw-wom-map-search-result-icon{display:flex;align-items:center;justify-content:center;color:#8b611d}
.twmpw-wom-map-search-result-icon svg{width:17px!important;height:17px!important;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-map-search-popup button>span:last-child{display:grid;gap:2px;min-width:0}
.twmpw-wom-map-search-popup b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px}
.twmpw-wom-map-search-popup small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#80663b;font-size:10px}
.twmpw-wom-map-search-more,.twmpw-wom-map-search-empty{padding:9px 10px;text-align:center;color:#80663b;font-size:11px;font-weight:800}
.twmpw-wom-head-actions{grid-column:3!important;justify-self:end}
@media(max-width:1420px){.twmpw-wom-map-search{width:clamp(200px,22vw,300px);min-width:200px}.twmpw-wom-center-tools{gap:8px}}
@media(max-width:1180px){
  .twmpw-wom-head{grid-template-columns:minmax(0,1fr) auto!important;grid-template-rows:auto auto!important;row-gap:6px!important;min-height:82px!important;height:auto!important;padding-top:6px!important;padding-bottom:6px!important}
  .twmpw-wom-title{grid-column:1;grid-row:1}.twmpw-wom-head-actions{grid-column:2!important;grid-row:1}.twmpw-wom-center-tools{grid-column:1/-1;grid-row:2;justify-self:center;max-width:100%;overflow:visible}.twmpw-wom-drawbar{max-width:calc(100vw - 360px);overflow-x:auto;scrollbar-width:none}.twmpw-wom-map-search{width:min(360px,34vw);min-width:190px}
}
@media(max-width:760px){.twmpw-wom-head{min-height:126px!important;grid-template-rows:auto auto auto!important}.twmpw-wom-center-tools{grid-row:2/4;display:grid;grid-template-columns:1fr;gap:6px;width:100%}.twmpw-wom-drawbar{grid-row:1;justify-self:center;max-width:100%}.twmpw-wom-map-search{grid-row:2;justify-self:center;width:min(420px,100%);min-width:0}}


/* World Map Stage 2 V14.13.6 — fullscreen-first navigation */
.twmpw-step-world-map .twmpw-step-icon{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;width:34px;height:34px;border-radius:50%;border:1px solid rgba(141,91,20,.35);background:rgba(255,248,232,.72)}
.twmpw-step-world-map .twmpw-step-svg{width:21px;height:21px;fill:none}
.twmpw-step-world-map.active .twmpw-step-icon{border-color:rgba(255,255,255,.55);background:rgba(255,255,255,.18)}
.twmpw-wom-close-btn svg{fill:none!important;stroke:currentColor;stroke-width:2;stroke-linecap:round}

/* World Map Stage 2 V14.13.7 — polished globe, rich search and blocking loader */
.twmpw-step-world-map .twmpw-step-icon{
  display:inline-flex!important;align-items:center;justify-content:center;position:relative;
  width:36px;height:36px;min-width:36px;flex:0 0 36px;border-radius:50%;
  color:#75480e;border:1px solid #b88432;
  background:radial-gradient(circle at 34% 28%,#fff8df 0 18%,#f3d79b 44%,#d39a3d 100%);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 3px 8px rgba(97,58,8,.18);
}
.twmpw-step-world-map .twmpw-step-icon::after{content:'';position:absolute;inset:4px;border-radius:50%;border:1px solid rgba(255,255,255,.38);pointer-events:none}
.twmpw-step-world-map .twmpw-step-svg{width:22px;height:22px;display:block;fill:none;filter:drop-shadow(0 1px 0 rgba(255,255,255,.45))}
.twmpw-step-world-map:hover .twmpw-step-icon{transform:translateY(-1px);border-color:#8f5a16;box-shadow:inset 0 1px 0 rgba(255,255,255,.95),0 5px 12px rgba(97,58,8,.24)}
.twmpw-step-world-map.active .twmpw-step-icon{color:#fff;border-color:#f2cf88;background:radial-gradient(circle at 34% 28%,#dfad56 0 18%,#ad711d 52%,#7d4808 100%)}
.twmpw-sidebar-collapsed .twmpw-step-world-map .twmpw-step-icon{display:inline-flex!important;margin:0!important}
.twmpw-sidebar-collapsed .twmpw-step-world-map .twmpw-step-num{display:none!important}

.twmpw-wom-map-search>[data-map-search-clear]{
  width:28px!important;height:28px!important;display:flex!important;align-items:center!important;justify-content:center!important;
  flex:0 0 28px;padding:0!important;border:0!important;border-radius:8px!important;background:transparent!important;color:#8a6a38;
}
.twmpw-wom-map-search>[data-map-search-clear][hidden]{display:none!important}
.twmpw-wom-map-search>[data-map-search-clear]:hover{background:#f2dfb6!important;color:#5d3c0d}
.twmpw-wom-map-search>[data-map-search-clear] svg{width:14px!important;height:14px!important;fill:none!important;stroke:currentColor;stroke-width:2;stroke-linecap:round}
.twmpw-wom-map-search-popup button>span:last-child{gap:3px}
.twmpw-wom-map-search-popup small{font-size:10.5px;line-height:1.25}

.twmpw-wom-preloader{position:absolute;inset:0;z-index:120;display:grid;place-items:center;padding:24px;background:linear-gradient(180deg,rgba(250,241,218,.98),rgba(240,222,184,.96));backdrop-filter:blur(2px);pointer-events:all;cursor:wait}
.twmpw-wom-preloader-card{width:min(440px,calc(100vw - 44px));display:grid;justify-items:center;gap:10px;padding:25px 28px 22px;border:1px solid #c7a25b;border-radius:18px;background:linear-gradient(180deg,#fffaf0,#f8e9c8);box-shadow:0 20px 55px rgba(64,42,10,.24),inset 0 1px 0 rgba(255,255,255,.9);text-align:center;color:#56380c}
.twmpw-wom-preloader-card>b{font-size:17px;letter-spacing:.01em}
.twmpw-wom-preloader-card>small{max-width:360px;color:#80663b;font-size:12px;line-height:1.45}
.twmpw-wom-preloader-globe{position:relative;width:58px;height:58px;display:grid;place-items:center;color:#8d5914;border-radius:50%;background:radial-gradient(circle at 35% 30%,#fff7d8,#e7bd70 60%,#b87920);box-shadow:inset 0 1px 0 rgba(255,255,255,.8),0 8px 20px rgba(115,70,12,.2)}
.twmpw-wom-preloader-globe svg{width:34px;height:34px;fill:none;stroke:currentColor;stroke-width:1.35;stroke-linecap:round}
.twmpw-wom-preloader-globe>span{position:absolute;inset:-6px;border:2px solid rgba(141,89,20,.18);border-top-color:#8d5914;border-radius:50%;animation:twmpw-wom-spin .9s linear infinite}
.twmpw-wom-preloader-track{width:min(280px,75%);height:5px;overflow:hidden;border-radius:999px;background:#e6cea0;margin-top:4px}
.twmpw-wom-preloader-track>i{display:block;width:42%;height:100%;border-radius:999px;background:linear-gradient(90deg,#b67a21,#e0ad55,#9a6015);animation:twmpw-wom-loader-slide 1.05s ease-in-out infinite}
@keyframes twmpw-wom-loader-slide{0%{transform:translateX(-110%)}50%{transform:translateX(135%)}100%{transform:translateX(350%)}}
.twmpw-wom.is-loading .twmpw-wom-head,.twmpw-wom.is-loading .twmpw-wom-body{pointer-events:none;user-select:none}
@media(prefers-reduced-motion:reduce){.twmpw-wom-preloader-globe>span,.twmpw-wom-preloader-track>i{animation-duration:2.4s}}

/* World Map Stage 2 V14.13.8 — final visual layers, labels, front validation and compass */
.twmpw-wom-tip-group-list{display:flex;flex-wrap:wrap;gap:6px;margin-top:4px}
.twmpw-wom-tip-group-pill{display:inline-flex;align-items:center;min-height:24px;padding:3px 9px;border:1px solid color-mix(in srgb,var(--group-color) 55%,#fff 45%);border-radius:999px;background:color-mix(in srgb,var(--group-color) 12%,#fff 88%);color:color-mix(in srgb,var(--group-color) 80%,#2e220f 20%);font-size:11px;font-weight:900;box-shadow:inset 3px 0 0 var(--group-color)}
.twmpw-wom-tip-groups{border-left:3px solid #8e44ad!important}
.twmpw-wom-map-search{grid-template-columns:30px minmax(0,1fr) 32px!important}
.twmpw-wom-map-search>[data-map-search-toggle]{grid-column:3;align-self:center;justify-self:center;margin:0!important;transform:none!important;position:relative;top:auto!important;right:auto!important}
.twmpw-wom-map-search>[data-map-search-toggle] svg{display:block}
.twmpw-wom-map-search>[data-map-search-clear]{position:absolute;right:34px;top:50%;transform:translateY(-50%);z-index:2}
.twmpw-wom-map-search input{padding-right:34px!important}

/* World Map Stage 2 V14.14 — attack analysis */
.twmpw-aa-modal{z-index:10120}
.twmpw-aa-modal>.twmpw-wom-modal-card{width:min(1540px,96vw);height:min(930px,94vh);max-width:none;display:grid;grid-template-rows:auto minmax(0,1fr)}
.twmpw-aa-modal>.twmpw-wom-modal-card>header{align-items:center}
.twmpw-aa-modal>.twmpw-wom-modal-card>header>div:first-child{display:grid;gap:3px}.twmpw-aa-modal header small{font-size:11px;color:#80663b;font-weight:700}
.twmpw-aa-modal>.twmpw-wom-modal-card>main{padding:0;overflow:auto;background:#f8f1df}

.twmpw-aa-modal.is-fullscreen{padding:0}.twmpw-aa-modal.is-fullscreen>.twmpw-wom-modal-card{width:100vw;height:100vh;max-height:none;border-radius:0;border:0}
.twmpw-aa-sticky{position:sticky;top:0;z-index:4;background:linear-gradient(180deg,#fffaf0,#f7ecd3);border-bottom:1px solid #dcc08a;box-shadow:0 8px 20px rgba(87,58,18,.08)}
.twmpw-aa-filters{display:grid;grid-template-columns:1.2fr 1fr .9fr .9fr .85fr .85fr auto;gap:10px;padding:16px 18px 10px;align-items:end}
.twmpw-aa-filters label,.twmpw-aa-import-actions label{display:grid;gap:5px;font-weight:800;color:#644819;font-size:12px}.twmpw-aa-filters select,.twmpw-aa-filters input,.twmpw-aa-import-actions select{height:42px;border:1px solid #d7b46e;border-radius:11px;background:#fffaf0;color:#4f3815;padding:0 12px;font-weight:700;min-width:0}.twmpw-aa-filters button{height:42px;border:1px solid #c99743;border-radius:11px;background:#fffaf0;color:#5a3c10;font-weight:900;padding:0 18px}
.twmpw-aa-tabs{display:flex;gap:4px;padding:0 18px;overflow:auto}.twmpw-aa-tabs button{border:0;border-bottom:3px solid transparent;background:transparent;padding:12px 18px;color:#6a4a19;font-weight:900;white-space:nowrap}.twmpw-aa-tabs button.is-active{background:#fffaf0;border-bottom-color:#a5670a}
.twmpw-aa-content{padding:18px}.twmpw-aa-kpis{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}.twmpw-aa-kpis article{background:#fffaf0;border:1px solid #dfc18a;border-radius:14px;padding:14px;box-shadow:inset 4px 0 0 #ba7c1d}.twmpw-aa-kpis small{display:block;color:#82612d;font-weight:800}.twmpw-aa-kpis b{display:block;font-size:28px;color:#4d340e;margin-top:7px}
.twmpw-aa-grid{display:grid;grid-template-columns:1.2fr .8fr;gap:16px;margin-top:16px}.twmpw-aa-grid section{background:#fffaf0;border:1px solid #dfc18a;border-radius:15px;padding:16px}.twmpw-aa-grid h3{margin:0 0 14px;color:#5c3e12}.twmpw-aa-bar{display:grid;grid-template-columns:120px 1fr 54px;gap:10px;align-items:center;margin:9px 0}.twmpw-aa-bar i{height:10px;background:#ead9b8;border-radius:999px;overflow:hidden}.twmpw-aa-bar i b{display:block;height:100%;background:linear-gradient(90deg,#b87516,#d49a3e);border-radius:999px}.twmpw-aa-rank{width:100%;display:flex;justify-content:space-between;gap:12px;border:0;border-bottom:1px solid #ead6ad;background:transparent;padding:10px 4px;text-align:left;color:#51360e;font-weight:800}.twmpw-aa-rank:hover{background:#fff2d6}
.twmpw-aa-table-wrap{height:calc(94vh - 205px);min-height:420px;overflow-y:auto;overflow-x:hidden;border:1px solid #ddbd80;border-radius:14px;background:#fffaf0}.twmpw-aa-table{width:100%;table-layout:fixed;border-collapse:collapse;min-width:0}.twmpw-aa-table thead{position:sticky;top:0;z-index:2}.twmpw-aa-table th{background:#ecd7aa;padding:10px;text-align:left;color:#563b12}.twmpw-aa-table td{padding:9px 10px;border-bottom:1px solid #ead8b5;color:#563b12}.twmpw-aa-table tbody tr:hover{background:#fff3d9}.twmpw-aa-table button{border:1px solid #c99b50;background:#fffaf0;border-radius:8px;padding:6px 10px;font-weight:800;color:#5a3b0d}.twmpw-aa-more{text-align:center;padding:12px;color:#80663b;font-weight:700}
.twmpw-aa-chip{display:inline-flex;padding:4px 8px;border-radius:999px;font-size:11px;font-weight:900;background:#e8dcc4}.twmpw-aa-chip.is-noble{background:#eadcf2;color:#6f2c91}.twmpw-aa-chip.is-ram{background:#f5d7d3;color:#9f2b1e}.twmpw-aa-chip.is-scout{background:#d8ebf7;color:#1d638e}.twmpw-aa-chip.is-catapult{background:#f8dfca;color:#a64e0c}
.twmpw-aa-import{max-width:1100px;margin:0 auto}.twmpw-aa-drop{display:grid;grid-template-columns:1fr 260px;gap:14px}.twmpw-aa-drop textarea{min-height:420px;resize:vertical;border:1px solid #d4b16e;border-radius:14px;background:#fffaf0;padding:15px;font:13px/1.5 ui-monospace,SFMono-Regular,Consolas,monospace;color:#4b3513}.twmpw-aa-file{display:grid;place-items:center;border:2px dashed #c99544;border-radius:14px;background:#f5e6c6;color:#664617;font-weight:900;cursor:pointer;min-height:160px}.twmpw-aa-file input{display:none}.twmpw-aa-import-actions{display:flex;justify-content:flex-end;align-items:end;gap:12px;margin-top:14px}.twmpw-aa-hint{color:#7d653d;font-size:12px;text-align:right}
.twmpw-aa-map-settings{max-width:760px;margin:20px auto;background:#fffaf0;border:1px solid #ddbd80;border-radius:16px;padding:22px;display:grid;gap:14px}.twmpw-aa-map-settings label{font-weight:900;color:#573a0d}.twmpw-aa-map-settings p{color:#80663b;line-height:1.5}
.twmpw-wom-tools button[data-tool="attackAnalysis"] svg{color:#a33b24}.twmpw-wom-tools button[data-tool="attackAnalysis"]{box-shadow:inset 0 0 0 1px rgba(173,72,35,.08)}
@media(max-width:1000px){.twmpw-aa-filters{grid-template-columns:repeat(3,minmax(0,1fr))}.twmpw-aa-kpis{grid-template-columns:repeat(3,1fr)}.twmpw-aa-grid{grid-template-columns:1fr}.twmpw-aa-drop{grid-template-columns:1fr}}
@media(max-width:620px){.twmpw-aa-modal>.twmpw-wom-modal-card{width:100vw;height:100vh;max-height:none;border-radius:0}.twmpw-aa-filters,.twmpw-aa-kpis{grid-template-columns:1fr 1fr}.twmpw-aa-content{padding:10px}.twmpw-aa-kpis b{font-size:22px}}

.twmpw-aa-table th:nth-child(1){width:13%}.twmpw-aa-table th:nth-child(2){width:14%}.twmpw-aa-table th:nth-child(3){width:9%}.twmpw-aa-table th:nth-child(4){width:12%}.twmpw-aa-table th:nth-child(5){width:13%}.twmpw-aa-table th:nth-child(6){width:22%}.twmpw-aa-table th:nth-child(7){width:6%}.twmpw-aa-table th:nth-child(8){width:11%}.twmpw-aa-table td{overflow:hidden;text-overflow:ellipsis;vertical-align:middle}.twmpw-aa-table td:nth-child(6){white-space:normal}.twmpw-aa-unit{display:inline-flex;align-items:center;gap:6px;min-width:0;font-weight:900}.twmpw-aa-unit img{width:20px;height:20px;object-fit:contain;image-rendering:auto}.twmpw-aa-label{display:block;margin-top:3px;color:#80633a;white-space:normal}.twmpw-aa-route{white-space:nowrap}.twmpw-aa-route b{color:#a4660b;margin:0 4px}.twmpw-aa-kpis article em{display:block;margin-top:5px;color:#8b6b39;font-size:11px;font-style:normal}.twmpw-aa-zone-kpis{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-top:12px}.twmpw-aa-zone-kpis article{display:grid;grid-template-columns:1fr auto;gap:3px;background:#f6e7c7;border:1px solid #ddbd80;border-radius:12px;padding:10px 12px}.twmpw-aa-zone-kpis small{grid-column:1/-1;color:#80633a}.twmpw-aa-rank span,.twmpw-aa-rank b{display:grid}.twmpw-aa-rank small{font-size:10px;color:#94764a;font-weight:700}.twmpw-aa-map-settings{max-width:980px}.twmpw-aa-map-settings>section{display:grid;gap:10px}.twmpw-aa-switch-row{display:flex!important;align-items:center;justify-content:space-between;gap:18px;padding:13px 15px;border:1px solid #e1c794;border-radius:13px;background:#fffaf0}.twmpw-aa-switch-row>span{display:grid;gap:3px}.twmpw-aa-switch-row small{font-weight:600;color:#80663b;line-height:1.35}.twmpw-aa-switch-row input{position:absolute;opacity:0;pointer-events:none}.twmpw-aa-switch-row i{position:relative;flex:0 0 46px;width:46px;height:25px;border-radius:999px;background:#d8c39a;box-shadow:inset 0 0 0 1px #b99555;transition:.18s}.twmpw-aa-switch-row i:after{content:"";position:absolute;width:19px;height:19px;left:3px;top:3px;border-radius:50%;background:#fffaf0;box-shadow:0 2px 5px rgba(69,43,8,.28);transition:.18s}.twmpw-aa-switch-row input:checked+i{background:#a96b10}.twmpw-aa-switch-row input:checked+i:after{transform:translateX(21px)}.twmpw-aa-coord-tools{padding-top:8px;border-top:1px solid #e3c997}.twmpw-aa-coord-tools>div:first-child{display:grid;gap:3px}.twmpw-aa-coord-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.twmpw-aa-coord-grid article{background:#f7ead0;border:1px solid #dfc28a;border-radius:12px;padding:12px;display:grid;gap:8px}.twmpw-aa-coord-grid article>b{font-size:24px}.twmpw-aa-coord-grid article>div{display:flex;gap:6px}.twmpw-aa-coord-grid button{flex:1;border:1px solid #c99b50;background:#fffaf0;border-radius:8px;padding:7px;font-weight:800;color:#5a3b0d}.twmp-btn-danger-soft{background:#fff2e8!important;color:#8d2a1f!important;border-color:#d99b88!important}.twmpw-wom-tip-attacks{border-left:4px solid #9c5f0b}.twmpw-wom-tip-attack-summary{display:flex;gap:8px;flex-wrap:wrap}.twmpw-wom-tip-attack-summary span{background:#f5e5c4;border-radius:8px;padding:5px 7px}.twmpw-wom-tip-attack-units{display:flex;gap:9px;flex-wrap:wrap;align-items:center;margin-top:7px}.twmpw-wom-tip-attack-units>.twmpw-aa-unit span{display:none}.twmpw-wom-tip-attack-units>.twmpw-aa-unit img{width:18px;height:18px}.twmpw-aa-crossed{font-size:18px;color:#8d3d18}.twmpw-wom-tool[data-wom="attackAnalysis"] svg{stroke-width:2.2}.twmpw-wom-context-attacks{display:grid;gap:2px;border-top:1px solid rgba(121,79,22,.18);margin-top:4px;padding-top:4px}.twmpw-wom-context-attacks small{padding:5px 10px 2px;color:#8a6a39;font-weight:800}
@media(max-width:1100px){.twmpw-aa-table th:nth-child(2),.twmpw-aa-table td:nth-child(2){display:none}.twmpw-aa-table th:nth-child(6){width:27%}.twmpw-aa-zone-kpis,.twmpw-aa-coord-grid{grid-template-columns:1fr 1fr}}

/* World Map Stage 2 V14.15.1 — attack analysis navigation and map precision */
.twmpw-wom-modal-coordinates{z-index:10280!important}
.twmpw-aa-table th:nth-child(1){width:19%}.twmpw-aa-table th:nth-child(2){width:10%}.twmpw-aa-table th:nth-child(3){width:14%}.twmpw-aa-table th:nth-child(4){width:14%}.twmpw-aa-table th:nth-child(5){width:21%}.twmpw-aa-table th:nth-child(6){width:15%}.twmpw-aa-table th:nth-child(7){width:7%}
.twmpw-aa-table td{white-space:normal;overflow-wrap:anywhere}.twmpw-aa-time,.twmpw-aa-travel,.twmpw-aa-person{display:grid;gap:3px;min-width:0}.twmpw-aa-time small,.twmpw-aa-travel small,.twmpw-aa-person small{color:#8b6b39;font-size:10px;font-weight:700}.twmpw-aa-person b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.twmpw-aa-route{display:grid;grid-template-columns:auto minmax(0,1fr) 16px auto minmax(0,1fr);gap:3px 5px;align-items:center;white-space:normal}.twmpw-aa-route>b{margin:0;color:#a4660b}.twmpw-aa-route>small{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#896c3f;font-size:10px}.twmpw-aa-route>i{grid-row:1/3;grid-column:3;font-style:normal;color:#a4660b;font-weight:900;text-align:center}
.twmpw-aa-zone-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;margin-top:14px;padding:12px 14px;border:1px solid #ddbd80;border-radius:12px;background:#fffaf0}.twmpw-aa-zone-head>div{display:grid;gap:4px}.twmpw-aa-zone-head small{color:#80663b;line-height:1.4}.twmpw-aa-zone-head>span{display:grid;place-items:center;flex:0 0 22px;width:22px;height:22px;border:1px solid #c99b50;border-radius:50%;background:#f5e5c4;color:#70480f;font-weight:900;cursor:help}
.twmpw-aa-heat-legend{display:flex;align-items:center;gap:14px;flex-wrap:wrap;padding:10px 12px;border:1px dashed #d7b46e;border-radius:10px;background:#fbf1de;color:#684918;font-size:11px;font-weight:800}.twmpw-aa-heat-legend span{display:inline-flex;align-items:center;gap:6px}.twmpw-aa-heat-legend i{width:12px;height:12px;border-radius:50%;box-shadow:0 0 0 4px rgba(0,0,0,.04)}.twmpw-aa-heat-legend .is-source i{background:#2980b9}.twmpw-aa-heat-legend .is-target i{background:#cd4430}.twmpw-aa-heat-legend small{flex-basis:100%;color:#8b6b39;font-weight:600}
.twmpw-wom-context-attacks{display:none;position:fixed!important;z-index:2147483000!important;left:0;top:0;width:248px;max-height:calc(100vh - 16px);padding:6px;border:1px solid #bfa36b;border-radius:10px;background:#fffaf0;box-shadow:0 10px 34px rgba(50,35,12,.25);overflow-y:auto;overscroll-behavior:contain}
.twmpw-wom-context-sub:hover>.twmpw-wom-context-attacks{display:none}
.twmpw-wom-context.attacks-open .twmpw-wom-context-attacks{display:block}
.twmpw-wom-context-sub>[data-c="attacks"]{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%}
.twmpw-wom-context-sub>[data-c="attacks"]>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.twmpw-wom-context-sub>[data-c="attacks"]>b{margin-left:auto;min-width:14px;padding:0;background:transparent;color:#6c4a18;font-size:18px;line-height:1;text-align:right}
.twmpw-wom-context-attacks button{width:100%;min-height:36px;display:grid;grid-template-columns:24px minmax(0,1fr) auto;align-items:center;gap:8px;padding:7px 8px;border:0;border-radius:7px;background:transparent;color:#5b421d;font-size:12px;text-align:left;cursor:pointer;box-sizing:border-box}
.twmpw-wom-context-attacks button:hover{background:#f1dfb8}.twmpw-wom-context-attacks svg{width:17px;height:17px;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}.twmpw-wom-context-attacks button>b{min-width:24px;padding:2px 6px;border-radius:999px;background:#ead7af;text-align:center;font-size:10px}
@media(max-width:1100px){.twmpw-aa-table th:nth-child(2),.twmpw-aa-table td:nth-child(2){display:table-cell}.twmpw-aa-table th:nth-child(5){width:18%}.twmpw-aa-table th:nth-child(6){width:17%}}
@media(max-width:760px){.twmpw-aa-table th:nth-child(2),.twmpw-aa-table td:nth-child(2){display:none}.twmpw-aa-table th:nth-child(1){width:22%}.twmpw-aa-table th:nth-child(3),.twmpw-aa-table th:nth-child(4){width:16%}.twmpw-aa-table th:nth-child(5){width:20%}.twmpw-aa-table th:nth-child(6){width:18%}.twmpw-aa-table th:nth-child(7){width:8%}.twmpw-wom-context-attacks{left:12px!important;right:12px!important;width:auto!important}}

/* World Map Stage 2 V14.15.2 — attack context submenu regression fix */


/* World Map Stage 2 V14.15.4 — final attack analysis refinements */
.twmpw-aa-menu-swords{display:grid!important;place-items:center;width:28px;height:28px;font-family:"Segoe UI Symbol","Noto Sans Symbols 2",sans-serif;font-size:23px;font-weight:700;line-height:1;color:#7e2e17;text-shadow:0 1px 0 #fff6df;transform:translateY(-1px)}
.twmpw-aa-unit.is-icon-only{display:inline-grid;place-items:center;width:24px;height:24px;min-width:24px}.twmpw-aa-unit.is-icon-only img{width:22px;height:22px;object-fit:contain}
.twmpw-aa-defence{display:flex;align-items:flex-start;gap:7px;min-width:0}.twmpw-aa-defence-units{display:flex;align-items:center;gap:5px;flex-wrap:wrap;min-width:0}
.twmpw-aa-game-icon{position:relative;display:inline-grid;place-items:center;width:29px;height:27px;border:1px solid #dfc28a;border-radius:7px;background:#fff8e9}.twmpw-aa-game-icon img{max-width:20px;max-height:20px;object-fit:contain}.twmpw-aa-game-icon b{position:absolute;right:-4px;bottom:-5px;min-width:16px;padding:1px 3px;border-radius:6px;background:#6e4a16;color:#fff8e9;font-size:8px;line-height:1;text-align:center}
.twmpw-aa-relation-kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;margin-top:10px}.twmpw-aa-relation-kpis article{display:grid;grid-template-columns:1fr auto;gap:3px;padding:10px 12px;border:1px solid #ddbd80;border-left:4px solid #9a7b49;border-radius:11px;background:#fffaf0}.twmpw-aa-relation-kpis small{grid-column:1/-1;color:#80633a}.twmpw-aa-relation-kpis .is-own{border-left-color:#2f7dcc}.twmpw-aa-relation-kpis .is-ally{border-left-color:#2daa61}.twmpw-aa-relation-kpis .is-nap{border-left-color:#d5aa21}.twmpw-aa-relation-kpis .is-enemy{border-left-color:#c63b31}.twmpw-aa-relation-kpis .is-friendly{border-left-color:#7c54a4}
.twmpw-aa-person.is-relation-own{border-left:3px solid #2f7dcc;padding-left:6px}.twmpw-aa-person.is-relation-ally{border-left:3px solid #2daa61;padding-left:6px}.twmpw-aa-person.is-relation-nap{border-left:3px solid #d5aa21;padding-left:6px}.twmpw-aa-person.is-relation-enemy{border-left:3px solid #c63b31;padding-left:6px}
.twmpw-wom-context-attacks .is-reset{margin-top:5px;border-top:1px solid #e1c794!important;color:#8a321f}
@media(max-width:1100px){.twmpw-aa-relation-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* V14.15.5 — attack icons and readable table */
.twmpw-aa-icon-fallback{display:grid;place-items:center;color:#8f5a12;font-weight:900;font-size:15px;line-height:1}
.twmpw-aa-unit.is-icon-only{position:relative}.twmpw-aa-unit.is-icon-only>.twmpw-aa-icon-fallback{position:absolute;inset:0}.twmpw-aa-unit.is-icon-only>img{position:relative;z-index:1}
.twmpw-aa-game-icon>.twmpw-aa-icon-fallback{position:absolute;inset:0}.twmpw-aa-game-icon>img{position:relative;z-index:1}
.twmpw-aa-table th:nth-child(1){width:17%}.twmpw-aa-table th:nth-child(2){width:20%}.twmpw-aa-table th:nth-child(3){width:20%}.twmpw-aa-table th:nth-child(4){width:12%}.twmpw-aa-table th:nth-child(5){width:24%}.twmpw-aa-table th:nth-child(6){width:7%}
.twmpw-aa-table td{padding:12px 10px;vertical-align:top}.twmpw-aa-time-meta{display:flex;gap:6px;flex-wrap:wrap;margin-top:5px}.twmpw-aa-time-meta em{font-style:normal;font-size:10px;font-weight:800;padding:3px 6px;border-radius:999px;background:#f2e0bb;color:#704b13}
.twmpw-aa-parties{display:grid;gap:6px}.twmpw-aa-party{display:grid;gap:2px;padding-left:8px;border-left:3px solid #b89a68}.twmpw-aa-party small{font-size:9px;text-transform:uppercase;letter-spacing:.04em;color:#8c7047}.twmpw-aa-party b{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.twmpw-aa-party em{font-size:10px;font-style:normal;color:#8b6b39}.twmpw-aa-party.is-source{border-color:#2b78c5}.twmpw-aa-party.is-target{border-color:#c84a3a}
.twmpw-aa-route-card{display:grid;grid-template-columns:minmax(0,1fr) 20px minmax(0,1fr);align-items:center;gap:6px}.twmpw-aa-route-card>span{display:grid;min-width:0}.twmpw-aa-route-card b{color:#a4660b}.twmpw-aa-route-card small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#896c3f;font-size:10px}.twmpw-aa-route-card i{text-align:center;font-style:normal;font-weight:900;color:#9f6717}
.twmpw-aa-type-cell{display:flex;align-items:center;gap:8px}.twmpw-aa-type-cell>span:last-child{display:grid;gap:2px}.twmpw-aa-type-cell small{font-size:10px;color:#80633a}.twmpw-aa-wall-cell{display:grid;justify-items:center;gap:3px}.twmpw-aa-wall-cell>small{font-size:9px;color:#80633a}.twmpw-aa-empty{align-self:center;color:#8b6b39}
.twmpw-wom-tip-attack-units .twmpw-aa-unit.is-icon-only{width:22px;height:22px}.twmpw-wom-tip-attack-units .twmpw-aa-unit.is-icon-only img{width:21px;height:21px}.twmpw-wom-tip-attack-units .twmpw-aa-icon-fallback{font-size:13px}
@media(max-width:1000px){.twmpw-aa-table th:nth-child(3),.twmpw-aa-table td:nth-child(3){display:none}.twmpw-aa-table th:nth-child(1){width:21%}.twmpw-aa-table th:nth-child(2){width:24%}.twmpw-aa-table th:nth-child(4){width:15%}.twmpw-aa-table th:nth-child(5){width:31%}.twmpw-aa-table th:nth-child(6){width:9%}}

/* World Map Stage 2 V14.15.5.9 — attack table scrolling and defence layout */
.twmpw-aa-bar>span{display:grid;place-items:center;width:30px;min-width:30px}
.twmpw-aa-bar .twmpw-aa-unit.is-icon-only{width:26px;height:26px;min-width:26px}
.twmpw-aa-bar .twmpw-aa-unit.is-icon-only img{width:23px;height:23px}
.twmpw-aa-unit.is-unmarked .twmpw-aa-icon-fallback{display:grid;place-items:center;font-size:0;color:#8b5815}
.twmpw-aa-crossed-swords-svg{display:block;width:23px;height:23px;fill:currentColor;filter:drop-shadow(0 1px 0 rgba(255,248,232,.9));transform:translateY(-.25px)}

.twmpw-aa-table-wrap{overflow-anchor:none;overscroll-behavior:contain;scrollbar-gutter:stable}
.twmpw-aa-table tbody tr{content-visibility:auto;contain-intrinsic-size:112px}
.twmpw-aa-more{min-height:38px;display:grid;place-items:center;background:#f6e8ca;border-top:1px solid #dfc18a}

.twmpw-aa-defence{display:grid;grid-template-columns:48px minmax(0,1fr);align-items:start;gap:8px;width:100%;min-width:0}
.twmpw-aa-wall-cell{display:grid;grid-template-rows:auto auto;justify-items:center;align-content:start;gap:3px;min-width:0;padding-right:7px;border-right:1px solid #ead8b5}
.twmpw-aa-wall-cell>small{font-size:9px;line-height:1.1;color:#80633a;font-weight:800}
.twmpw-aa-defence-body{display:grid;grid-template-rows:auto auto;gap:5px;min-width:0}
.twmpw-aa-defence-units{display:grid;grid-template-columns:repeat(auto-fit,minmax(58px,1fr));align-items:start;gap:5px;min-width:0}
.twmpw-aa-game-icon{position:relative;display:grid;grid-template-columns:22px minmax(0,1fr);align-items:center;justify-items:start;gap:4px;width:auto;height:32px;min-width:0;padding:3px 5px;border:1px solid #dfc28a;border-radius:7px;background:#fff8e9;box-sizing:border-box}
.twmpw-aa-game-icon img{position:relative;z-index:1;width:20px;height:20px;max-width:20px;max-height:20px;object-fit:contain;justify-self:center}
.twmpw-aa-game-icon b{position:static;min-width:0;max-width:100%;padding:0;background:transparent;color:#5f4012;font-size:10px;line-height:1.1;text-align:right;justify-self:end;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.twmpw-aa-game-icon>.twmpw-aa-icon-fallback{display:grid;place-items:center;position:absolute;left:5px;top:5px;width:20px;height:20px;inset:auto;font-size:12px;color:#8b6b39}
.twmpw-aa-wall-cell .twmpw-aa-game-icon{grid-template-columns:20px minmax(0,1fr);width:44px;padding:3px 4px;gap:2px}
.twmpw-aa-wall-cell .twmpw-aa-game-icon b{font-size:10px}
.twmpw-aa-defence-total{display:block;justify-self:start;font-size:9px;line-height:1.15;color:#80633a;font-weight:800;white-space:nowrap}
.twmpw-aa-defence-body>.twmpw-aa-empty{align-self:center;min-height:32px;display:flex;align-items:center;line-height:1.25}

@media(max-width:760px){
  .twmpw-aa-defence{grid-template-columns:42px minmax(0,1fr);gap:5px}
  .twmpw-aa-wall-cell{padding-right:4px}
  .twmpw-aa-wall-cell .twmpw-aa-game-icon{width:38px;grid-template-columns:18px minmax(0,1fr);padding:3px;gap:1px}
  .twmpw-aa-game-icon{grid-template-columns:18px minmax(0,1fr);height:29px;padding:3px 4px;gap:2px}
  .twmpw-aa-game-icon img{width:18px;height:18px;max-width:18px;max-height:18px}
  .twmpw-aa-game-icon>.twmpw-aa-icon-fallback{left:4px;top:5px;width:18px;height:18px}
  .twmpw-aa-game-icon b{font-size:9px}
  .twmpw-aa-defence-units{grid-template-columns:repeat(auto-fit,minmax(46px,1fr));gap:4px}
}
.twmpw-aa-bar{grid-template-columns:34px minmax(0,1fr) 68px;gap:12px}
.twmpw-aa-bar>strong{text-align:right;font-variant-numeric:tabular-nums}
.twmpw-aa-table tbody tr.twmpw-aa-virtual-spacer{content-visibility:visible;contain-intrinsic-size:0}
.twmpw-aa-table tbody tr.twmpw-aa-virtual-spacer:hover{background:transparent}
.twmpw-aa-table .twmpw-aa-virtual-spacer td{padding:0!important;border:0!important;line-height:0;font-size:0;overflow:hidden}

/* World Map Stage 2 V14.15.5.12 — target route labels, unified mode reset and noble radius lens */
.twmpw-aa-filter-panel{display:grid;gap:7px;padding:10px 18px 8px;border-bottom:1px solid rgba(184,130,45,.14)}
.twmpw-aa-filter-main{display:grid;grid-template-columns:minmax(280px,2fr) minmax(112px,.62fr) minmax(112px,.62fr) minmax(310px,1.25fr) auto;gap:8px;align-items:end}
.twmpw-aa-search{position:relative;display:block;min-width:0}
.twmpw-aa-search input{width:100%;height:36px;padding:0 34px 0 34px;border:1px solid #d7b46e;border-radius:10px;background:#fffaf0;color:#4f3815;font-weight:750;box-sizing:border-box;outline:none}
.twmpw-aa-search input:focus{border-color:#b97818;box-shadow:0 0 0 3px rgba(185,120,24,.12)}
.twmpw-aa-search-icon{position:absolute;left:11px;top:50%;transform:translateY(-50%);font-size:18px;line-height:1;color:#8b6429;pointer-events:none}
.twmpw-aa-search button{position:absolute;right:6px;top:50%;transform:translateY(-50%);width:25px;height:25px;padding:0;border:0;border-radius:7px;background:transparent;color:#775522;font-size:20px;line-height:1;cursor:pointer}
.twmpw-aa-search button:hover{background:#f1dfbb}
.twmpw-aa-compact-filter,.twmpw-aa-date-range,.twmpw-aa-gap-filter,.twmpw-aa-village-filter{display:grid;gap:3px;min-width:0;color:#644819;font-size:10px;font-weight:850}
.twmpw-aa-compact-filter select,.twmpw-aa-gap-filter select,.twmpw-aa-village-filter select,.twmpw-aa-date-range input{height:36px;min-width:0;border:1px solid #d7b46e;border-radius:10px;background:#fffaf0;color:#4f3815;padding:0 9px;font-weight:750;box-sizing:border-box}
.twmpw-aa-date-range{grid-template-columns:minmax(118px,1fr) 12px minmax(118px,1fr);align-items:end}
.twmpw-aa-date-range>span{grid-column:1/-1}
.twmpw-aa-date-range>i{align-self:center;text-align:center;font-style:normal;color:#9a7742;padding-bottom:10px}
.twmpw-aa-reset{height:36px;padding:0 15px;border:1px solid #c99743;border-radius:10px;background:#fffaf0;color:#5a3c10;font-weight:900;white-space:nowrap}
.twmpw-aa-reset:disabled{opacity:.45;cursor:default}
.twmpw-aa-filter-secondary{display:flex;align-items:center;gap:8px;min-height:30px;flex-wrap:wrap}
.twmpw-aa-inline-switch{display:inline-flex;align-items:center;gap:8px;min-height:30px;padding:3px 9px 3px 6px;border:1px solid #dfc28a;border-radius:10px;background:#fff8e9;color:#5f4217;font-size:11px;font-weight:850;cursor:pointer;user-select:none}
.twmpw-aa-inline-switch input{position:absolute;opacity:0;pointer-events:none}
.twmpw-aa-inline-switch i{position:relative;width:34px;height:19px;flex:0 0 34px;border-radius:999px;background:#d8c39a;box-shadow:inset 0 0 0 1px #b99555;transition:.16s}
.twmpw-aa-inline-switch i:after{content:"";position:absolute;left:3px;top:3px;width:13px;height:13px;border-radius:50%;background:#fffaf0;box-shadow:0 1px 4px rgba(69,43,8,.28);transition:.16s}
.twmpw-aa-inline-switch input:checked+i{background:#a96b10}
.twmpw-aa-inline-switch input:checked+i:after{transform:translateX(15px)}
.twmpw-aa-gap-filter,.twmpw-aa-village-filter{grid-template-columns:auto minmax(82px,auto);align-items:center;gap:5px}
.twmpw-aa-gap-filter select,.twmpw-aa-village-filter select{height:30px;padding:0 8px;border-radius:8px;font-size:11px}
.twmpw-aa-gap-filter.is-disabled{opacity:.48}
.twmpw-aa-filter-result{margin-left:auto;color:#80633a;font-size:11px;font-weight:850;white-space:nowrap}
.twmpw-aa-time>b{white-space:nowrap;font-variant-numeric:tabular-nums}
.twmpw-aa-time>small{font-variant-numeric:tabular-nums}
.twmpw-aa-group-row{background:rgba(246,231,199,.42)}
.twmpw-aa-group-row:hover{background:#fff0d2!important}
.twmpw-aa-group-mark{display:flex;align-items:center;gap:6px;min-width:0}
.twmpw-aa-group-mark>b{font-size:18px;line-height:1;color:#6b4610;font-variant-numeric:tabular-nums}
.twmpw-aa-group-mark>i{font-style:normal;font-size:13px;color:#9a7132}
.twmpw-aa-group-mark>span:last-child{display:grid;gap:2px;min-width:0}
.twmpw-aa-group-mark strong{font-size:12px;white-space:nowrap}
.twmpw-aa-group-mark small{font-size:9px;color:#8b6b39;white-space:normal;line-height:1.2}
.twmpw-aa-mark-stack{display:flex;align-items:center;gap:5px;flex-wrap:wrap}
.twmpw-aa-mark-stack>span{display:inline-flex;align-items:center;gap:3px;padding:2px 4px;border:1px solid #e1c794;border-radius:8px;background:#fff8e9}
.twmpw-aa-mark-stack b{font-size:10px;font-variant-numeric:tabular-nums}
.twmpw-aa-mark-stack i{font-style:normal;font-size:9px;color:#9a7132}
.twmpw-aa-route-card.is-group small{white-space:normal;overflow-wrap:anywhere}
.twmpw-aa-group-no-defence{display:grid;place-items:center;min-height:38px;color:#8a6c40;font-size:10px;font-weight:750;text-align:center}
.twmpw-aa-defence-units{display:flex!important;align-items:flex-start;align-content:flex-start;flex-wrap:wrap;gap:5px;min-width:0}
.twmpw-aa-game-icon{display:inline-grid;grid-template-columns:20px auto;width:auto;min-width:max-content;max-width:none;height:32px;flex:0 0 auto;padding:3px 6px 3px 5px;gap:4px}
.twmpw-aa-game-icon b{position:static;min-width:0;max-width:none;overflow:visible;text-overflow:clip;white-space:nowrap;font-size:10px;font-variant-numeric:tabular-nums;letter-spacing:0}
.twmpw-aa-wall-cell .twmpw-aa-game-icon{width:44px;min-width:44px;grid-template-columns:20px auto;padding:3px 4px}
.twmpw-aa-more{font-variant-numeric:tabular-nums}
@media(max-width:1250px){
  .twmpw-aa-filter-main{grid-template-columns:minmax(240px,1.6fr) repeat(2,minmax(105px,.65fr)) minmax(270px,1.2fr) auto}
  .twmpw-aa-filter-result{width:100%;margin-left:0}
}
@media(max-width:900px){
  .twmpw-aa-filter-main{grid-template-columns:minmax(0,1fr) minmax(105px,.45fr) minmax(105px,.45fr) auto}
  .twmpw-aa-date-range{grid-column:1/-1;grid-template-columns:minmax(0,1fr) 12px minmax(0,1fr)}
  .twmpw-aa-reset{grid-column:4;grid-row:1}
}
@media(max-width:620px){
  .twmpw-aa-filter-panel{padding:8px 10px 7px}
  .twmpw-aa-filter-main{grid-template-columns:1fr 1fr}
  .twmpw-aa-search{grid-column:1/-1}
  .twmpw-aa-date-range{grid-column:1/-1}
  .twmpw-aa-reset{grid-column:1/-1;grid-row:auto}
  .twmpw-aa-filter-secondary{align-items:stretch}
  .twmpw-aa-inline-switch,.twmpw-aa-gap-filter,.twmpw-aa-village-filter{width:100%;box-sizing:border-box}
  .twmpw-aa-gap-filter,.twmpw-aa-village-filter{grid-template-columns:minmax(0,1fr) minmax(120px,auto)}
  .twmpw-aa-filter-result{white-space:normal}
  .twmpw-aa-game-icon{grid-template-columns:18px auto;height:29px;padding:3px 5px 3px 4px;gap:3px}
  .twmpw-aa-game-icon b{font-size:9px}
}
.twmpw-aa-search-icon svg{display:block;width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round}
/* V14.15.5.10 compactness and overflow hardening */
.twmpw-aa-filter-panel{gap:5px;padding:7px 18px 6px}
.twmpw-aa-search input,.twmpw-aa-compact-filter select,.twmpw-aa-date-range input,.twmpw-aa-reset{height:32px}
.twmpw-aa-compact-filter,.twmpw-aa-date-range,.twmpw-aa-gap-filter,.twmpw-aa-village-filter{gap:2px;font-size:9px}
.twmpw-aa-date-range>i{padding-bottom:8px}
.twmpw-aa-filter-secondary{min-height:26px;gap:6px}
.twmpw-aa-inline-switch{min-height:26px;padding:2px 8px 2px 5px}
.twmpw-aa-inline-switch input{position:absolute;width:1px!important;height:1px!important;margin:0!important;padding:0!important;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.twmpw-aa-gap-filter select,.twmpw-aa-village-filter select{height:27px}
@media(max-width:620px){
 .twmpw-aa-filter-panel{padding:6px 10px 5px}
 .twmpw-aa-time>b{white-space:normal;overflow-wrap:anywhere;font-size:9px;line-height:1.2}
}


/* World Map Stage 2 V14.15.5.12 — target route labels, unified mode reset and noble radius lens */
.twmpw-aa-switch-row.is-disabled{opacity:.58;cursor:not-allowed}
.twmpw-aa-switch-row.is-disabled b,.twmpw-aa-switch-row.is-disabled small{opacity:.95}
.twmpw-aa-search input{appearance:none;-webkit-appearance:none}
.twmpw-aa-search input::-webkit-search-cancel-button,.twmpw-aa-search input::-webkit-search-decoration,.twmpw-aa-search input::-webkit-search-results-button,.twmpw-aa-search input::-webkit-search-results-decoration{display:none!important}
.twmpw-aa-search button{display:grid!important;place-items:center!important;line-height:0!important}
.twmpw-aa-search button svg{display:block;width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:round}
.twmpw-aa-heat-legend .is-own i{background:#2e8b57}.twmpw-aa-heat-legend .is-ally i{background:#2f9e91}.twmpw-aa-heat-legend .is-nap i{background:#3b82f6}.twmpw-aa-heat-legend .is-enemy i{background:#c0392b}.twmpw-aa-heat-legend .is-neutral i{background:#8b6b39}
.twmpw-aa-heat-legend .is-source-outline i,.twmpw-aa-heat-legend .is-target-outline i{background:transparent!important;box-shadow:none!important;border:2px solid #8b6b39}.twmpw-aa-heat-legend .is-source-outline i{border-style:dashed}
.twmpw-aa-scheme-legend{display:flex;align-items:center;gap:14px;flex-wrap:wrap;padding:10px 12px;border:1px dashed #d7b46e;border-radius:10px;background:#fbf1de;color:#684918;font-size:11px;font-weight:800}.twmpw-aa-scheme-legend span{display:inline-flex;align-items:center;gap:6px}.twmpw-aa-scheme-legend i{width:12px;height:12px;border-radius:50%;box-shadow:0 0 0 4px rgba(0,0,0,.04)}.twmpw-aa-scheme-legend .is-source i{background:#7d6b2f}.twmpw-aa-scheme-legend .is-target i{background:#b46a2a}.twmpw-aa-scheme-legend .is-main i{background:#8b3f18}.twmpw-aa-scheme-legend .is-noble i{background:#7d3fb2}.twmpw-aa-scheme-legend small{flex-basis:100%;color:#8b6b39;font-weight:600}

/* World Map Stage 2 V14.15.5.12 — target route labels, unified mode reset and noble radius lens */
.twmpw-aa-unknown-mark-svg{display:block;width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:2.25;stroke-linecap:round;stroke-linejoin:round;filter:drop-shadow(0 1px 0 rgba(255,248,232,.9));transform:translateY(-.2px)}
.twmpw-aa-unit.is-unmarked .twmpw-aa-icon-fallback{color:#8b5815}
.twmpw-wom-context-sub>[data-c="analytics"],.twmpw-wom-context-sub>[data-c="attacks"],.twmpw-wom-context-sub>[data-c="drawing"]{display:grid!important;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;gap:7px}
.twmpw-wom-context-active{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 6px;border-radius:999px;background:#a96b10;color:#fffaf0;font-size:10px;font-style:normal;font-weight:900;line-height:1;box-shadow:0 0 0 1px rgba(107,66,12,.22)}
.twmpw-wom-context-analytics .is-reset,.twmpw-wom-context-drawing .is-reset,.twmpw-wom-context-attacks .is-reset,.twmpw-wom-context>.is-reset{margin-top:4px!important;border-top:1px solid #e1c794!important;background:#fff3e9!important;color:#8a321f!important}
.twmpw-wom-context-analytics .is-reset:hover,.twmpw-wom-context-drawing .is-reset:hover,.twmpw-wom-context-attacks .is-reset:hover,.twmpw-wom-context>.is-reset:hover{background:#f8dfd0!important;color:#742315!important}
.twmpw-wom-context-drawing .is-active-mode{background:#f1dfb8!important;box-shadow:inset 3px 0 0 #a96b10;color:#5a3708!important}
.twmpw-wom-context-analytics .is-reset svg,.twmpw-wom-context-drawing .is-reset svg,.twmpw-wom-context-attacks .is-reset svg{stroke:#a13f29!important}
.twmpw-wom-map-stage canvas.is-noble-radius-lens,.twmpw-wom-map-stage canvas.is-noble-radius-lens:active{cursor:crosshair!important}

/* World Map Stage 2 V14.15.5.13 — full noble-radius hold mode, context hotkeys and styled map action */
.twmpw-wom-context-analytics button{grid-template-columns:24px minmax(0,1fr) auto}
.twmpw-wom-context-hotkey{display:inline-flex;align-items:center;justify-content:center;min-width:24px;height:20px;padding:0 6px;border:1px solid #c9ad76;border-bottom-color:#a9874e;border-radius:6px;background:linear-gradient(#fffdf6,#ead8ad);box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 1px 1px rgba(71,45,12,.12);color:#654619;font:800 10px/1 Segoe UI,sans-serif;white-space:nowrap}
.twmpw-wom-context-shortcuts{margin-top:5px;padding:7px 5px 3px;border-top:1px solid #e1c794;display:grid;grid-template-columns:1fr 1fr;gap:5px 7px;color:#80633a;font-size:9px;font-weight:750}
.twmpw-wom-context-shortcuts span{display:flex;align-items:center;gap:5px;min-width:0;white-space:nowrap}
.twmpw-wom-context-shortcuts .twmpw-wom-context-hotkey{min-width:21px;height:18px;padding:0 4px;font-size:9px}
.twmpw-aa-map-fit{width:100%;min-height:42px;display:inline-flex;align-items:center;justify-content:center;gap:9px;margin-top:2px;border-radius:10px;font-weight:900;letter-spacing:.01em}
.twmpw-aa-map-fit-icon{display:inline-grid;place-items:center;width:22px;height:22px;border-radius:7px;background:rgba(255,255,255,.24);font-size:17px;line-height:1}
.twmpw-aa-map-fit:hover{transform:translateY(-1px)}
.twmpw-aa-map-fit:active{transform:none}
@media(max-width:620px){.twmpw-wom-context-shortcuts{grid-template-columns:1fr 1fr}.twmpw-aa-map-fit{min-height:40px}}

/* World Map Stage 2 V14.16.0.7 — military statistics base */
.twmpw-wom-stat-context.is-official{padding-top:12px}
.twmpw-wom-official-stat{display:grid;gap:12px;min-width:0}
.twmpw-wom-stat-official-controls{display:grid;grid-template-columns:minmax(270px,1fr) minmax(240px,.8fr);gap:10px;align-items:end;padding:11px 12px;border:1px solid #dec792;border-radius:13px;background:#fffaf0;box-shadow:0 4px 12px rgba(86,54,14,.05)}
.twmpw-wom-stat-official-controls.is-od{grid-template-columns:auto minmax(390px,1fr) minmax(210px,.55fr)}
.twmpw-wom-stat-official-controls>div{display:grid;gap:5px;min-width:0}
.twmpw-wom-stat-official-controls small,.twmpw-wom-od-search>span{color:#6d521d;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.03em}
.twmpw-wom-stat-segmented{display:flex;align-items:center;gap:3px;min-width:0;padding:3px;border:1px solid #d8bd84;border-radius:10px;background:#f5e7ca;overflow-x:auto}
.twmpw-wom-stat-segmented button{flex:1 0 auto;min-height:31px;padding:6px 10px;border:1px solid transparent;border-radius:7px;background:transparent;color:#73552a;font-size:11px;font-weight:900;white-space:nowrap;cursor:pointer}
.twmpw-wom-stat-segmented button:hover{background:rgba(255,250,240,.72)}
.twmpw-wom-stat-segmented button.is-active{border-color:#c79b52;background:#fffaf0;color:#4d320b;box-shadow:0 2px 6px rgba(83,50,9,.12)}
.twmpw-wom-od-search{display:grid;gap:5px;min-width:0}
.twmpw-wom-od-search input{width:100%;height:38px;box-sizing:border-box}
.twmpw-wom-stat-classification-note{display:grid;grid-template-columns:auto minmax(0,1fr);gap:10px;align-items:center;padding:10px 12px;border:1px solid #88b79a;border-left:4px solid #2e8b57;border-radius:11px;background:#eff8f1;color:#426049}
.twmpw-wom-stat-classification-note b{color:#245d38;white-space:nowrap}
.twmpw-wom-stat-classification-note span{font-size:11px;line-height:1.4}
.twmpw-wom-stat-classification-note.is-warning{border-color:#d2b26f;border-left-color:#b47719;background:#fff5df;color:#6e531e}
.twmpw-wom-stat-classification-note.is-warning b{color:#75510f}
.twmpw-wom-stat-classification-note.is-neutral{border-color:#b9a57e;border-left-color:#8b6b39;background:#f8f1e4;color:#665334}
.twmpw-wom-stat-classification-note.is-neutral b{color:#5e471f}
.twmpw-wom-military-kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
.twmpw-wom-military-kpis article{position:relative;display:grid;gap:5px;min-height:105px;padding:12px 13px;border:1px solid #dec792;border-radius:13px;background:#fffaf0;box-shadow:0 4px 12px rgba(86,54,14,.06);overflow:hidden}
.twmpw-wom-military-kpis article::before{content:"";position:absolute;inset:0 auto 0 0;width:4px;background:#9a6b22}
.twmpw-wom-military-kpis article.is-def::before{background:#2f7fb5}
.twmpw-wom-military-kpis article.is-off::before{background:#b54b35}
.twmpw-wom-military-kpis article.is-pop::before{background:#7c4aa0}
.twmpw-wom-military-kpis small{color:#80663b;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.03em}
.twmpw-wom-military-kpis b{color:#4d320b;font-size:22px;line-height:1.05}
.twmpw-wom-military-kpis span{align-self:end;color:#80663b;font-size:10px;line-height:1.35}
.twmpw-wom-troop-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px}
.twmpw-wom-troop-grid>article{display:grid;gap:9px;min-width:0;padding:11px;border:1px solid #dec792;border-radius:12px;background:#fff;box-shadow:0 3px 10px rgba(79,52,14,.05)}
.twmpw-wom-troop-grid>article.is-def{border-left:4px solid #2f7fb5}
.twmpw-wom-troop-grid>article.is-off{border-left:4px solid #b54b35}
.twmpw-wom-troop-grid header{display:grid;grid-template-columns:36px minmax(0,1fr) auto;gap:8px;align-items:center}
.twmpw-wom-troop-icon{display:grid;place-items:center;width:34px;height:34px;border:1px solid #d9bd82;border-radius:9px;background:#fff8e8}
.twmpw-wom-troop-icon .twmpw-wom-unit-icon-wrap{width:27px;height:27px;display:grid;place-items:center}
.twmpw-wom-troop-icon .twmpw-wom-unit-icon{max-width:25px;max-height:25px}
.twmpw-wom-troop-grid header>span:nth-child(2){display:grid;gap:2px;min-width:0}
.twmpw-wom-troop-grid header b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#5b421d;font-size:12px}
.twmpw-wom-troop-grid header small{justify-self:start;padding:2px 6px;border-radius:999px;background:#e9dbc0;color:#73552a;font-size:9px;font-weight:900}
.twmpw-wom-troop-grid article.is-def header small{background:#e3f0f8;color:#28638a}
.twmpw-wom-troop-grid article.is-off header small{background:#f8e7e1;color:#8f3828}
.twmpw-wom-troop-grid header strong{color:#4d320b;font-size:15px;text-align:right;white-space:nowrap}
.twmpw-wom-troop-bar{height:6px;border-radius:999px;background:#eee2ca;overflow:hidden}
.twmpw-wom-troop-bar i{display:block;height:100%;border-radius:inherit;background:#a66c1a}
.twmpw-wom-troop-grid article.is-def .twmpw-wom-troop-bar i{background:#2f7fb5}
.twmpw-wom-troop-grid article.is-off .twmpw-wom-troop-bar i{background:#b54b35}
.twmpw-wom-troop-grid dl{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;margin:0}
.twmpw-wom-troop-grid dl>div{display:grid;gap:1px;padding:6px 7px;border-radius:8px;background:#f8efdd}
.twmpw-wom-troop-grid dt{color:#8a7045;font-size:9px;font-weight:800}
.twmpw-wom-troop-grid dd{margin:0;color:#5b421d;font-size:11px;font-weight:900;white-space:nowrap}
.twmpw-wom-troop-grid footer{display:flex;flex-wrap:wrap;gap:5px 9px;padding-top:7px;border-top:1px solid #eadfc8;color:#80663b;font-size:9px}
.twmpw-wom-troop-grid footer b{color:#5b421d}
.twmpw-wom-stat-official-empty{display:grid;gap:7px;justify-items:start;min-height:190px;padding:20px;border:1px dashed #cfae70;border-radius:14px;background:#fffaf0;color:#6a4d20}
.twmpw-wom-stat-official-empty b{font-size:15px}
.twmpw-wom-stat-official-empty span{max-width:760px;color:#80663b;font-size:11px;line-height:1.5}
.twmpw-wom-od-table-card{padding:0;overflow:hidden}
.twmpw-wom-od-table-card>header{padding:12px 13px 0}
.twmpw-wom-od-table-card .twmpw-wom-stat-table-wrap{max-height:620px;min-height:240px}
.twmpw-wom-od-table-card table{min-width:900px}
.twmpw-wom-od-table-card td.is-selected,.twmpw-wom-od-table-card th.is-selected{background:#fff3d8;color:#774d0c;font-weight:900}
.twmpw-wom-od-name{display:grid;gap:3px;min-width:150px}
.twmpw-wom-od-name>b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#5b421d}
.twmpw-wom-od-name>small{justify-self:start;padding:2px 6px;border-radius:999px;background:#ede0c7;color:#73552a;font-size:9px;font-weight:900}
.twmpw-wom-od-name>small.is-own{background:#dff2e4;color:#287044}
.twmpw-wom-od-name>small.is-ally{background:#dcf1ef;color:#247269}
.twmpw-wom-od-name>small.is-nap{background:#e1ebfb;color:#315f9f}
.twmpw-wom-od-name>small.is-enemy{background:#f8e1dc;color:#9b392b}
.twmpw-wom-od-name>small.is-neutral{background:#eee4d2;color:#735b34}
.twmpw-wom-military-kpis.is-od article:nth-child(2)::before{background:#b54b35}
.twmpw-wom-military-kpis.is-od article:nth-child(3)::before{background:#2f7fb5}
.twmpw-wom-military-kpis.is-od article:nth-child(4)::before{background:#7c4aa0}
@media(max-width:1180px){.twmpw-wom-stat-official-controls.is-od{grid-template-columns:1fr 1.4fr}.twmpw-wom-stat-official-controls.is-od .twmpw-wom-od-search{grid-column:1/-1}.twmpw-wom-troop-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.twmpw-wom-stat-official-controls,.twmpw-wom-stat-official-controls.is-od{grid-template-columns:1fr}.twmpw-wom-stat-official-controls.is-od .twmpw-wom-od-search{grid-column:auto}.twmpw-wom-military-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.twmpw-wom-troop-grid{grid-template-columns:1fr}.twmpw-wom-stat-classification-note{grid-template-columns:1fr}.twmpw-wom-stat-classification-note b{white-space:normal}}
@media(max-width:520px){.twmpw-wom-military-kpis{grid-template-columns:1fr}.twmpw-wom-stat-segmented button{padding-inline:8px}.twmpw-wom-troop-grid dl{grid-template-columns:1fr 1fr}}

/* World Map Stage 2 V14.16.0.7 — dual-role heavy cavalry, stable search and complete percentages */
.twmpw-wom-od-search-box{display:grid;grid-template-columns:30px minmax(0,1fr) 32px;align-items:center;min-width:0;height:38px;border:1px solid #d7b46e;border-radius:10px;background:#fffaf0;box-shadow:inset 0 1px 0 rgba(255,255,255,.82);transition:border-color .14s ease,box-shadow .14s ease}
.twmpw-wom-od-search-box:focus-within{border-color:#9d6b1e;box-shadow:0 0 0 3px rgba(157,107,30,.12),inset 0 1px 0 rgba(255,255,255,.9)}
.twmpw-wom-od-search-box>i{display:grid;place-items:center;color:#7a5a26;pointer-events:none}
.twmpw-wom-od-search-box>i svg{display:block;width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-od-search-box input{width:100%;min-width:0;height:36px;padding:0 4px!important;border:0!important;border-radius:0!important;background:transparent!important;color:#49320c;font:750 12px/1.2 Segoe UI,sans-serif;outline:0!important;box-shadow:none!important;appearance:none;-webkit-appearance:none}
.twmpw-wom-od-search-box input::placeholder{color:#927a50;font-weight:650}
.twmpw-wom-od-search-box button{display:grid;place-items:center;width:28px;height:28px;padding:0;border:0;border-radius:8px;background:transparent;color:#70501e;cursor:pointer}
.twmpw-wom-od-search-box button:hover{background:#f2dfb6;color:#5d3c0d}
.twmpw-wom-od-search-box button[hidden]{display:none!important}
.twmpw-wom-od-search-box button svg{display:block;width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:2.1;stroke-linecap:round}
.twmpw-wom-troop-grid>article.is-both{border-left:0;box-shadow:inset 4px 0 #2f7fb5,inset 8px 0 #b54b35,0 3px 10px rgba(79,52,14,.05);padding-left:15px}
.twmpw-wom-troop-grid article.is-both header small{background:linear-gradient(90deg,#e3f0f8 0 50%,#f8e7e1 50%);color:#684b38}
.twmpw-wom-troop-grid article.is-both .twmpw-wom-troop-bar i{background:linear-gradient(90deg,#2f7fb5,#b54b35)}
.twmpw-wom-od-metric{display:grid;gap:2px;justify-items:end;white-space:nowrap}
.twmpw-wom-od-metric>b{color:inherit;font-size:11px}
.twmpw-wom-od-metric>small{color:#94784a;font-size:9px;font-weight:850}
.twmpw-wom-od-table-card td.is-selected .twmpw-wom-od-metric>small{color:#9a6514}
/* World Map Stage 2 V14.17.0.2 — linked mass plan foundation and dual-role paladin */

/* World Map Stage 2 V14.17.0.3 — native TWMP mass-plan interface */
.twmpw-mass-plan-menu-icon{display:inline-flex;align-items:center;justify-content:center}
.twmpw-mass-plan-menu-icon svg{width:23px!important;height:23px!important;fill:none!important;stroke:currentColor!important;stroke-width:1.75!important;stroke-linecap:round!important;stroke-linejoin:round!important}
.twmpw-mass-plan-modal{z-index:2147483200!important}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card{width:min(1380px,calc(100vw - 32px));height:min(880px,calc(100vh - 32px));max-width:none;max-height:none;grid-template-rows:auto minmax(0,1fr) auto;background:#fffaf0}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>header{align-items:center!important;border-bottom:1px solid #c9ad76;background:#ead8ad}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>header>div:first-child{display:grid;gap:2px;min-width:0}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>header b{color:#4d320b;font-size:18px;line-height:1.2}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>header small{color:#71572f;font-size:11px;font-weight:750;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>header [data-mass-close]{display:grid!important;place-items:center!important;width:36px!important;height:36px!important;min-width:36px!important;padding:0!important;border:0!important;border-radius:8px!important;background:transparent!important;color:#654619!important;line-height:0!important}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>header [data-mass-close]:hover{background:rgba(255,250,240,.62)!important}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>header [data-mass-close] svg{width:18px;height:18px;fill:none!important;stroke:currentColor!important;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>main{padding:0!important;overflow:hidden!important;min-height:0;background:#f8f1df}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>footer{gap:12px;border-top:1px solid #c9ad76;background:#ead8ad;color:#71572f;font-size:11px;font-weight:750}
.twmpw-mass-plan-modal>.twmpw-wom-modal-card>footer>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.twmpw-mass-plan-shell{height:100%;display:flex;flex-direction:column;min-height:0;background:#f8f1df;color:#5b421d}
.twmpw-mass-plan-summary{display:grid;grid-template-columns:repeat(6,minmax(120px,1fr));gap:9px;padding:12px 14px;border-bottom:1px solid #dec792;background:#fff7e5}
.twmpw-mass-plan-summary article{min-width:0;padding:10px 12px;border:1px solid #dec792;border-radius:11px;background:#fffaf0;box-shadow:0 3px 10px rgba(86,54,14,.045)}
.twmpw-mass-plan-summary article>span{display:block;margin-bottom:4px;color:#80663b;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.025em;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.twmpw-mass-plan-summary article>b{display:block;color:#4d320b;font-size:20px;line-height:1.05}
.twmpw-mass-plan-summary article>small{display:block;margin-top:4px;color:#8a6a39;font-size:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.twmpw-mass-plan-toolbar{display:flex;align-items:center;gap:9px;padding:10px 14px;border-bottom:1px solid #dec792;background:#fffaf0}
.twmpw-mass-plan-toolbar .twmpw-btn{height:38px;min-height:38px;padding:0 15px;border-radius:9px;white-space:nowrap}
.twmpw-mass-plan-search{position:relative;flex:1;display:grid;grid-template-columns:20px minmax(0,1fr) 30px;align-items:center;gap:7px;height:38px;padding:0 6px 0 11px;border:1px solid #cda866;border-radius:9px;background:#fffdf8;box-sizing:border-box;transition:border-color .14s ease,box-shadow .14s ease}
.twmpw-mass-plan-search:focus-within{border-color:#966017;box-shadow:0 0 0 3px rgba(150,96,23,.14)}
.twmpw-mass-plan-search>svg{width:17px;height:17px;fill:none!important;stroke:#80663b!important;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-search input{width:100%;min-width:0;height:34px;padding:0;border:0!important;outline:0!important;background:transparent!important;color:#49320c!important;font:inherit;box-shadow:none!important}
.twmpw-mass-plan-search input::placeholder{color:#9a8057}
.twmpw-mass-plan-search button{display:grid;place-items:center;width:28px;height:28px;padding:0;border:0;border-radius:7px;background:transparent;color:#80663b}
.twmpw-mass-plan-search button:hover{background:#f1dfb8}
.twmpw-mass-plan-search button[hidden]{display:none!important}
.twmpw-mass-plan-search button svg{width:15px;height:15px;fill:none!important;stroke:currentColor!important;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-ready{display:grid;grid-template-columns:34px minmax(0,1fr) auto;align-items:center;gap:10px;margin:10px 14px 0;padding:9px 11px;border:1px solid #d2b26f;border-left:4px solid #b47719;border-radius:10px;background:#fff5df;color:#6e531e}
.twmpw-mass-plan-ready.is-ready{border-color:#88b79a;border-left-color:#2e8b57;background:#eff8f1;color:#426049}
.twmpw-mass-plan-ready>span{display:grid;place-items:center;width:30px;height:30px;border-radius:9px;background:rgba(255,255,255,.6)}
.twmpw-mass-plan-ready>span svg{width:18px;height:18px;fill:none!important;stroke:currentColor!important;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-ready>div{min-width:0;display:grid;gap:2px}
.twmpw-mass-plan-ready b{font-size:12px}.twmpw-mass-plan-ready small{min-width:0;font-size:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.twmpw-mass-plan-ready>em{min-width:48px;padding:5px 8px;border-radius:999px;background:rgba(255,255,255,.72);font-size:11px;font-style:normal;font-weight:900;text-align:center}
.twmpw-mass-plan-grid{display:grid;grid-template-columns:minmax(300px,350px) minmax(0,1fr);min-height:0;flex:1;padding:10px 14px 0;gap:10px}
.twmpw-mass-plan-grid>aside{min-height:0;overflow:auto;padding-right:4px;scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5}
.twmpw-mass-plan-grid>main{min-width:0;min-height:0;overflow:auto;scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5}
.twmpw-mass-plan-grid>aside::-webkit-scrollbar,.twmpw-mass-plan-grid>main::-webkit-scrollbar{width:9px;height:9px}
.twmpw-mass-plan-grid>aside::-webkit-scrollbar-track,.twmpw-mass-plan-grid>main::-webkit-scrollbar-track{background:#fff7e5;border-radius:999px}
.twmpw-mass-plan-grid>aside::-webkit-scrollbar-thumb,.twmpw-mass-plan-grid>main::-webkit-scrollbar-thumb{background:#c6a160;border:2px solid #fff7e5;border-radius:999px}
.twmpw-mass-plan-section{margin-bottom:10px;border:1px solid #dec792;border-radius:11px;overflow:hidden;background:#fffaf0;box-shadow:0 3px 10px rgba(86,54,14,.04)}
.twmpw-mass-plan-section>header{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:9px 11px;border-bottom:1px solid #ead8ad;background:#f0dfbc;color:#65491c}
.twmpw-mass-plan-section>header b{font-size:12px}.twmpw-mass-plan-section>header span{display:inline-flex;align-items:center;justify-content:center;min-width:26px;height:22px;padding:0 7px;border:1px solid #d1b579;border-radius:999px;background:#fffaf0;color:#6a4918;font-size:10px;font-weight:900}
.twmpw-mass-plan-row{width:100%;display:grid;grid-template-columns:5px minmax(0,1fr) 24px;align-items:center;gap:10px;min-height:52px;padding:8px 10px;border:0!important;border-top:1px solid #eee1c6!important;border-radius:0!important;background:#fffaf0!important;color:#5b421d!important;text-align:left;cursor:pointer}
.twmpw-mass-plan-row:first-child{border-top:0!important}.twmpw-mass-plan-row:hover,.twmpw-mass-plan-row:focus-visible{background:#fff3d7!important;outline:none;box-shadow:inset 3px 0 0 #a96b10}
.twmpw-mass-plan-row>i{width:5px;height:34px;border-radius:99px;background:var(--mass-color)}
.twmpw-mass-plan-row>span{min-width:0}.twmpw-mass-plan-row b,.twmpw-mass-plan-row small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.twmpw-mass-plan-row b{font-size:11px}.twmpw-mass-plan-row small{margin-top:3px;color:#80663b;font-size:10px}
.twmpw-mass-plan-row>em{display:grid;place-items:center;color:#8a6a39;font-style:normal}.twmpw-mass-plan-row>em svg{width:16px;height:16px;fill:none!important;stroke:currentColor!important;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-stage{min-height:100%;border:1px solid #dec792;border-radius:12px;background:#fffaf0;overflow:hidden;box-shadow:0 3px 10px rgba(86,54,14,.04)}
.twmpw-mass-plan-mode{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:11px 13px;border-bottom:1px solid #ead8ad;background:#fff7e5}
.twmpw-mass-plan-mode>div{min-width:0;display:grid;gap:3px}.twmpw-mass-plan-mode b{color:#5b421d;font-size:13px}.twmpw-mass-plan-mode small{color:#80663b;font-size:10px;line-height:1.35}
.twmpw-mass-plan-links{display:grid;gap:9px;padding:11px}
.twmpw-mass-plan-link{position:relative;padding:11px 12px 10px;border:1px solid #e0cc9f;border-left:4px solid var(--mass-link-color);border-radius:10px;background:#fffdf8;box-shadow:0 2px 7px rgba(86,54,14,.035)}
.twmpw-mass-plan-link-route{display:grid;grid-template-columns:minmax(120px,1fr) 38px minmax(120px,1fr);align-items:center;gap:8px}
.twmpw-mass-plan-link-route>span{position:relative;display:grid;gap:2px;min-width:0;padding-left:12px}.twmpw-mass-plan-link-route>span>i{position:absolute;left:0;top:4px;width:6px;height:6px;border-radius:50%;background:var(--mass-link-color)}
.twmpw-mass-plan-link-route b,.twmpw-mass-plan-link-route small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.twmpw-mass-plan-link-route b{color:#5b421d;font-size:11px}.twmpw-mass-plan-link-route small{color:#8a6a39;font-size:9px}
.twmpw-mass-plan-link-route>em{display:grid;place-items:center;color:var(--mass-link-color)}.twmpw-mass-plan-link-route>em svg{width:24px;height:24px;fill:none!important;stroke:currentColor!important;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-link-meta{display:flex;align-items:center;flex-wrap:wrap;gap:5px;margin-top:9px;padding-top:8px;border-top:1px dashed #e1c794}
.twmpw-mass-plan-link-meta>span,.twmpw-mass-plan-link-meta>b,.twmpw-mass-plan-link-meta>small{display:inline-flex;align-items:center;min-height:22px;padding:2px 7px;border:1px solid #dbc184;border-radius:999px;background:#fff7e5;color:#65491c;font-size:9px;font-weight:850}
.twmpw-mass-plan-link-meta>b{border-color:color-mix(in srgb,var(--mass-link-color) 42%,#dbc184);background:color-mix(in srgb,var(--mass-link-color) 9%,#fff 91%)}
.twmpw-mass-plan-empty{padding:13px;color:#80663b;font-size:10px}.twmpw-mass-plan-empty.is-large{min-height:260px;display:grid;place-content:center;justify-items:center;gap:7px;padding:24px;text-align:center}.twmpw-mass-plan-empty.is-large>b{color:#5b421d;font-size:14px}.twmpw-mass-plan-empty.is-large>small{max-width:520px;color:#80663b;line-height:1.45}.twmpw-mass-plan-empty-icon{display:grid;place-items:center;width:46px;height:46px;border:1px solid #d8bd84;border-radius:13px;background:#fff7e5;color:#8e5a16}.twmpw-mass-plan-empty-icon svg{width:25px;height:25px;fill:none!important;stroke:currentColor!important;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-loading{height:100%;min-height:360px;display:grid;place-content:center;justify-items:center;gap:10px;color:#6b4d20}.twmpw-mass-plan-loading>span{width:30px;height:30px;border:3px solid #dfc797;border-top-color:#8e5a16;border-radius:50%;animation:twmpw-spin .8s linear infinite}.twmpw-mass-plan-loading>b{font-size:12px}
.twmpw-mass-plan-assets{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:10px;padding:9px 14px;border-top:1px solid #dec792;background:#fff7e5;color:#80663b;font-size:10px}.twmpw-mass-plan-assets span{white-space:nowrap}.twmpw-mass-plan-assets b{color:#5b421d}
.twmpw-wom-context-mass-plan{display:none;position:fixed!important;z-index:2147483000!important;left:0;top:0;width:276px;max-height:calc(100vh - 16px);padding:6px;border:1px solid #bfa36b;border-radius:10px;background:#fffaf0;box-shadow:0 10px 34px rgba(50,35,12,.25);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5}
.twmpw-wom-context.mass-plan-open .twmpw-wom-context-mass-plan{display:block}
.twmpw-wom-context-mass-plan button{width:100%;min-height:36px;display:grid;grid-template-columns:24px minmax(0,1fr);align-items:center;gap:8px;padding:7px 8px;border:0;border-radius:7px;background:transparent;color:#5b421d;font-size:12px;text-align:left;cursor:pointer;box-sizing:border-box}
.twmpw-wom-context-mass-plan button:hover,.twmpw-wom-context-mass-plan button:focus-visible{background:#f1dfb8;outline:none}
.twmpw-wom-context-mass-plan svg{width:17px;height:17px;fill:none!important;stroke:currentColor!important;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-context-mass-plan::-webkit-scrollbar{width:8px}.twmpw-wom-context-mass-plan::-webkit-scrollbar-track{background:#fff7e5;border-radius:999px}.twmpw-wom-context-mass-plan::-webkit-scrollbar-thumb{background:#c6a160;border:2px solid #fff7e5;border-radius:999px}
@media(max-width:1100px){.twmpw-mass-plan-summary{grid-template-columns:repeat(3,minmax(0,1fr))}.twmpw-mass-plan-grid{grid-template-columns:minmax(270px,320px) minmax(0,1fr)}}
@media(max-width:820px){.twmpw-mass-plan-modal{padding:10px!important}.twmpw-mass-plan-modal>.twmpw-wom-modal-card{width:100%;height:100%;max-height:none;border-radius:12px}.twmpw-mass-plan-toolbar{flex-wrap:wrap}.twmpw-mass-plan-search{flex-basis:100%}.twmpw-mass-plan-grid{grid-template-columns:1fr;overflow:auto}.twmpw-mass-plan-grid>aside{max-height:none;overflow:visible;padding-right:0}.twmpw-mass-plan-grid>main{min-height:360px;overflow:visible}.twmpw-mass-plan-ready small{white-space:normal}.twmpw-mass-plan-assets{overflow-x:auto;justify-content:flex-start}.twmpw-wom-context-mass-plan{left:12px!important;right:12px!important;top:auto!important;bottom:12px!important;width:auto!important;max-height:55vh}}
@media(max-width:560px){.twmpw-mass-plan-summary{grid-template-columns:repeat(2,minmax(0,1fr));padding:10px}.twmpw-mass-plan-toolbar{padding:9px 10px}.twmpw-mass-plan-toolbar .twmpw-btn{flex:1}.twmpw-mass-plan-ready{margin-inline:10px}.twmpw-mass-plan-grid{padding-inline:10px}.twmpw-mass-plan-link-route{grid-template-columns:1fr 28px 1fr}.twmpw-mass-plan-modal>.twmpw-wom-modal-card>footer>span{display:none}.twmpw-mass-plan-modal>.twmpw-wom-modal-card>footer{justify-content:flex-end}}


/* World Map Stage 2 V14.17.0.4 — universal search, linked plan forms and native window controls */
.twmpw-wom-map-search{grid-template-columns:30px minmax(0,1fr) 32px!important}
.twmpw-wom-map-search>[data-map-search-toggle]{display:none!important}
.twmpw-wom-map-search>[data-map-search-clear]{position:static!important;grid-column:3;align-self:center;justify-self:center;right:auto!important;top:auto!important;transform:none!important;margin:0!important}
.twmpw-wom-map-search input{padding-right:4px!important}

.twmpw-mass-plan-modal.is-fullscreen{padding:0!important}
.twmpw-mass-plan-modal.is-fullscreen>.twmpw-wom-modal-card{width:100vw!important;height:100vh!important;max-height:none!important;border:0!important;border-radius:0!important}
.twmpw-mass-plan-window-actions{display:flex;align-items:center;gap:4px;flex:0 0 auto}
.twmpw-mass-plan-window-actions button{display:grid!important;place-items:center!important;width:36px!important;height:36px!important;min-width:36px!important;padding:0!important;border:0!important;border-radius:8px!important;background:transparent!important;color:#654619!important;line-height:0!important}
.twmpw-mass-plan-window-actions button:hover{background:rgba(255,250,240,.62)!important}
.twmpw-mass-plan-window-actions svg{width:18px;height:18px;fill:none!important;stroke:currentColor!important;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-ready.is-empty{border-color:#cdb681;border-left-color:#8a6a39;background:#fff8e8;color:#6b542f}
.twmpw-mass-plan-ready.is-empty>span svg{width:19px;height:19px}
.twmpw-mass-plan-toolbar [data-mass-action="calculate"]:disabled{cursor:not-allowed;opacity:.58;filter:saturate(.72)}

.twmpw-mass-plan-search{isolation:isolate}
.twmpw-mass-plan-search input{appearance:none;-webkit-appearance:none}
.twmpw-mass-plan-search-popup{position:absolute;left:-1px;right:-1px;top:calc(100% + 6px);z-index:80;max-height:min(460px,58vh);overflow:auto;padding:5px;border:1px solid #bfa36b;border-radius:11px;background:#fffaf0;box-shadow:0 14px 38px rgba(50,35,12,.28);scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5;overscroll-behavior:contain}
.twmpw-mass-plan-search-popup[hidden]{display:none!important}
.twmpw-mass-plan-search-popup::-webkit-scrollbar{width:8px}.twmpw-mass-plan-search-popup::-webkit-scrollbar-track{background:#fff7e5;border-radius:999px}.twmpw-mass-plan-search-popup::-webkit-scrollbar-thumb{background:#c6a160;border:2px solid #fff7e5;border-radius:999px}
.twmpw-mass-plan-search-popup button{width:100%;min-height:46px;display:grid;grid-template-columns:28px minmax(0,1fr);align-items:center;gap:9px;padding:7px 9px;border:0!important;border-radius:8px!important;background:transparent!important;color:#4c3511!important;text-align:left;box-sizing:border-box}
.twmpw-mass-plan-search-popup button:hover,.twmpw-mass-plan-search-popup button.is-active,.twmpw-mass-plan-search-popup button[aria-selected="true"]{background:#f1dfb8!important}
.twmpw-mass-plan-search-popup button>span:first-child{display:grid;place-items:center;color:#8b611d}
.twmpw-mass-plan-search-popup button>span:first-child svg{width:17px;height:17px;fill:none!important;stroke:currentColor!important;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-search-popup button>span:last-child{display:grid;gap:2px;min-width:0}
.twmpw-mass-plan-search-popup b,.twmpw-mass-plan-search-popup small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.twmpw-mass-plan-search-popup b{font-size:12px}.twmpw-mass-plan-search-popup small{color:#80663b;font-size:10px;line-height:1.25}
.twmpw-mass-plan-search-empty{padding:11px;text-align:center;color:#80663b;font-size:11px;font-weight:800}
.twmpw-mass-plan-row{grid-template-columns:5px minmax(0,1fr)!important}
.twmpw-mass-plan-row>em{display:none!important}

.twmpw-mass-plan-draft-modal{z-index:2147483300!important;padding:18px!important}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card{width:min(760px,calc(100vw - 28px));max-height:min(850px,calc(100vh - 28px));grid-template-rows:auto minmax(0,1fr) auto;background:#fffaf0}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>header{align-items:center!important;border-bottom:1px solid #c9ad76;background:#ead8ad}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>header>div:first-child{display:grid;gap:2px;min-width:0}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>header b{color:#4d320b;font-size:17px;line-height:1.2}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>header small{color:#71572f;font-size:11px;font-weight:750;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>header [data-mass-draft-cancel]{display:grid!important;place-items:center!important;width:36px!important;height:36px!important;min-width:36px!important;padding:0!important;border:0!important;border-radius:8px!important;background:transparent!important;color:#654619!important;line-height:0!important}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>header [data-mass-draft-cancel]:hover{background:rgba(255,250,240,.62)!important}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>header svg{width:18px;height:18px;fill:none!important;stroke:currentColor!important;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>main{min-height:0;padding:14px!important;overflow:auto!important;background:#f8f1df;scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>main::-webkit-scrollbar{width:9px}.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>main::-webkit-scrollbar-track{background:#fff7e5;border-radius:999px}.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>main::-webkit-scrollbar-thumb{background:#c6a160;border:2px solid #fff7e5;border-radius:999px}
.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card>footer{justify-content:flex-end;gap:8px;border-top:1px solid #c9ad76;background:#ead8ad}
.twmpw-mass-draft-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}
.twmpw-mass-draft-grid>label,.twmpw-mass-draft-color-field>label{display:grid;gap:5px;min-width:0;color:#65491c;font-size:11px;font-weight:900}
.twmpw-mass-draft-grid .is-wide{grid-column:1/-1}
.twmpw-mass-draft-grid input[type="text"],.twmpw-mass-draft-grid input[type="number"],.twmpw-mass-draft-grid select,.twmpw-mass-draft-grid textarea{width:100%;min-width:0;border:1px solid #cda866;border-radius:8px;background:#fffdf8;color:#49320c;box-sizing:border-box;outline:none;font:inherit}
.twmpw-mass-draft-grid input[type="text"],.twmpw-mass-draft-grid input[type="number"],.twmpw-mass-draft-grid select{height:38px;padding:0 10px}
.twmpw-mass-draft-grid textarea{min-height:102px;padding:9px 10px;resize:vertical;line-height:1.42;scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5}
.twmpw-mass-draft-grid input:focus,.twmpw-mass-draft-grid select:focus,.twmpw-mass-draft-grid textarea:focus{border-color:#966017;box-shadow:0 0 0 3px rgba(150,96,23,.14)}
.twmpw-mass-draft-color-field{grid-column:1/-1;display:grid;grid-template-columns:130px minmax(0,1fr);align-items:end;gap:10px;padding:10px;border:1px solid #dec792;border-radius:10px;background:#fffaf0}
.twmpw-mass-draft-color-field input[type="color"]{width:100%;height:38px;padding:3px;border:1px solid #cda866;border-radius:8px;background:#fffdf8;cursor:pointer}
.twmpw-mass-draft-colors{display:flex;align-items:center;gap:7px;flex-wrap:wrap;min-height:38px}
.twmpw-mass-draft-colors button{display:grid;place-items:center;width:28px;height:28px;padding:0;border:1px solid #c9ad76;border-radius:8px;background:#fffaf0;cursor:pointer}
.twmpw-mass-draft-colors button:hover,.twmpw-mass-draft-colors button.is-active{border-color:#7f5718;box-shadow:0 0 0 3px rgba(150,96,23,.14)}
.twmpw-mass-draft-colors button i{width:18px;height:18px;border-radius:5px;background:var(--draft-color);box-shadow:inset 0 0 0 1px rgba(0,0,0,.14)}
.twmpw-mass-draft-grid .twmpw-toggle-row{margin:0;padding:10px 11px;border:1px solid #dec792;border-radius:10px;background:#fffaf0}
.twmpw-mass-draft-grid .twmpw-toggle-row>span:first-child{display:grid;gap:2px}.twmpw-mass-draft-grid .twmpw-toggle-row small{color:#80663b;font-size:10px;font-weight:650;line-height:1.35}
.twmpw-mass-draft-types{display:grid;gap:7px;padding:10px;border:1px solid #dec792;border-radius:10px;background:#fffaf0}
.twmpw-mass-draft-types>header{display:grid;gap:2px;padding-bottom:6px;border-bottom:1px solid #ead8ad}.twmpw-mass-draft-types>header b{color:#5b421d;font-size:12px}.twmpw-mass-draft-types>header small{color:#80663b;font-size:10px;line-height:1.35}
.twmpw-mass-draft-types>label{display:grid;grid-template-columns:7px minmax(0,1fr) 86px;align-items:center;gap:9px;padding:7px 8px;border:1px solid #ead8ad;border-radius:8px;background:#fffdf8}
.twmpw-mass-draft-types>label>i{width:7px;height:32px;border-radius:99px;background:var(--draft-type-color)}
.twmpw-mass-draft-types>label>span{display:grid;gap:2px;min-width:0}.twmpw-mass-draft-types>label b,.twmpw-mass-draft-types>label small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.twmpw-mass-draft-types>label b{color:#5b421d;font-size:11px}.twmpw-mass-draft-types>label small{color:#80663b;font-size:9px}
.twmpw-mass-draft-types>label input{width:86px!important;text-align:center}
.twmpw-mass-draft-note{padding:10px;border:1px dashed #d2b26f;border-radius:8px;background:#fff7e5;color:#80663b;font-size:10px;line-height:1.42}

.twmpw-wom-context-sub>[data-c="mass-plan"]{display:grid!important;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:8px;width:100%}
.twmpw-wom-context-sub>[data-c="mass-plan"]>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.twmpw-wom-context-sub>[data-c="mass-plan"]>b{justify-self:end;margin-left:auto;min-width:14px;padding:0;background:transparent;color:#6c4a18;font-size:18px;line-height:1;text-align:right}
.twmpw-wom-context-mass-plan button{grid-template-columns:24px minmax(0,1fr) auto!important}
.twmpw-wom-context-mass-plan button>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.twmpw-wom-context-mass-plan kbd{display:inline-flex;align-items:center;justify-content:center;min-width:40px;height:20px;padding:0 6px;border:1px solid #c9ad76;border-bottom-color:#a9874e;border-radius:6px;background:linear-gradient(#fffdf6,#ead8ad);box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 1px 1px rgba(71,45,12,.12);color:#654619;font:800 9px/1 Segoe UI,sans-serif;white-space:nowrap}
.twmpw-wom-context-mass-plan .is-reset{margin-top:5px;border-top:1px solid #e1c794!important;background:#fff3e9!important;color:#8a321f!important}
.twmpw-wom-context-mass-plan .is-reset:hover{background:#f8dfd0!important;color:#742315!important}

@media(max-width:820px){.twmpw-mass-plan-search-popup{max-height:42vh}.twmpw-mass-plan-draft-modal{padding:8px!important}.twmpw-mass-plan-draft-modal>.twmpw-wom-modal-card{width:100%;max-height:100%;height:100%;border-radius:12px}.twmpw-mass-draft-grid{grid-template-columns:1fr}.twmpw-mass-draft-grid .is-wide,.twmpw-mass-draft-color-field{grid-column:1}.twmpw-mass-draft-color-field{grid-template-columns:110px minmax(0,1fr)}}
@media(max-width:560px){.twmpw-mass-plan-window-actions button{width:34px!important;height:34px!important;min-width:34px!important}.twmpw-mass-draft-color-field{grid-template-columns:1fr}.twmpw-mass-draft-types>label{grid-template-columns:6px minmax(0,1fr) 72px}.twmpw-mass-draft-types>label input{width:72px!important}.twmpw-mass-plan-search-popup small{white-space:normal;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}


/* World Map Stage 2 V14.18.0 — detailed capture statistics */
.twmpw-wom-capture-controls{display:grid;grid-template-columns:minmax(390px,1.2fr) minmax(310px,1fr) minmax(230px,.72fr) minmax(230px,.72fr);gap:10px;align-items:end;padding:11px 12px;border:1px solid #dec792;border-radius:13px;background:#fffaf0;box-shadow:0 4px 12px rgba(86,54,14,.05)}
.twmpw-wom-capture-controls>div{display:grid;gap:5px;min-width:0}.twmpw-wom-capture-controls>div>small,.twmpw-wom-capture-search>small{color:#6d521d;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.03em}
.twmpw-wom-capture-search-box{display:grid;grid-template-columns:32px minmax(0,1fr) 32px;align-items:center;height:39px;border:1px solid #d1b577;border-radius:10px;background:#fff;overflow:hidden}.twmpw-wom-capture-search-box>i{display:grid;place-items:center;color:#896628}.twmpw-wom-capture-search-box svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round}.twmpw-wom-capture-search-box input{width:100%;height:37px;padding:0;border:0!important;background:transparent!important;box-shadow:none!important}.twmpw-wom-capture-search-box button{display:grid;place-items:center;width:32px;height:37px;padding:0;border:0;background:transparent;color:#80663b}.twmpw-wom-capture-search-box button:hover{background:#f4e6c8}.twmpw-wom-capture-search-box button[hidden]{display:none}.twmpw-wom-capture-toggle{min-height:64px;padding:8px 10px;background:#fff}.twmpw-wom-capture-toggle span:first-child{display:grid;gap:2px}.twmpw-wom-capture-toggle small{font-size:10px;line-height:1.25}
.twmpw-wom-capture-active-filter{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:9px 12px;border:1px solid #bc9959;border-left:4px solid #98651c;border-radius:10px;background:#fff4dc;color:#65491c;font-size:11px}.twmpw-wom-capture-active-filter button{padding:5px 9px;border:1px solid #cba96b;border-radius:7px;background:#fffaf0;color:#65491c;font-weight:900}
.twmpw-wom-capture-actions{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:9px 11px;border:1px solid #dec792;border-radius:11px;background:rgba(255,250,240,.8);color:#71552a;font-size:11px}.twmpw-wom-capture-actions>div{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:6px}.twmpw-wom-capture-actions .twmpw-btn{min-height:34px;padding:7px 10px;font-size:10px}
.twmpw-wom-capture-trend rect.is-barbarian{fill:rgba(128,107,72,.65)}.twmpw-wom-capture-trend rect.is-internal{fill:rgba(126,82,145,.58)}.twmpw-wom-stat-legend .is-barbarian::before{background:#806b48}.twmpw-wom-stat-legend .is-internal::before{background:#7e5291}
.twmpw-wom-capture-flows{display:grid;gap:7px;max-height:475px;overflow:auto}.twmpw-wom-capture-flows button{position:relative;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:3px 12px;width:100%;padding:9px 10px 12px;border:1px solid #dec792;border-radius:10px;background:#fff;text-align:left;overflow:hidden}.twmpw-wom-capture-flows button:hover,.twmpw-wom-capture-flows button.is-active{border-color:#a8782e;background:#fff8e8}.twmpw-wom-capture-flows button>span{display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);gap:7px;align-items:center;min-width:0}.twmpw-wom-capture-flows button>span b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#5b421d}.twmpw-wom-capture-flows button>span b:last-child{text-align:right}.twmpw-wom-capture-flows button i{color:#a27631;font-style:normal}.twmpw-wom-capture-flows button em{color:#5b421d;font-size:15px;font-style:normal;font-weight:900}.twmpw-wom-capture-flows button small{grid-column:1/-1;color:#80663b}.twmpw-wom-capture-flows button u{position:absolute;left:0;bottom:0;width:var(--capture-flow-width);height:4px;background:linear-gradient(90deg,#b47719,#d6a352);text-decoration:none}
.twmpw-wom-capture-waves{display:grid;gap:8px;max-height:475px;overflow:auto}.twmpw-wom-capture-waves article{padding:10px;border:1px solid #dec792;border-radius:11px;background:#fff}.twmpw-wom-capture-waves article>header{display:flex;justify-content:space-between;gap:10px}.twmpw-wom-capture-waves article>header>span{display:grid;gap:2px;min-width:0}.twmpw-wom-capture-waves article>header b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#5b421d}.twmpw-wom-capture-waves article>header small{color:#80663b}.twmpw-wom-capture-waves article>header em{color:#8e5a16;font-size:18px;font-style:normal;font-weight:900}.twmpw-wom-capture-waves article>div{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;margin-top:8px}.twmpw-wom-capture-waves article>div span{display:grid;gap:1px;padding:6px;border-radius:8px;background:#f8f0dd}.twmpw-wom-capture-waves article>div b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#5b421d}.twmpw-wom-capture-waves article>div small{color:#80663b;font-size:9px}.twmpw-wom-capture-waves article>footer{display:flex;flex-wrap:wrap;gap:5px;margin-top:8px}.twmpw-wom-capture-waves article>footer button{padding:5px 8px;border:1px solid #cfae70;border-radius:7px;background:#fff8e8;color:#684817;font-size:10px;font-weight:900}
.twmpw-wom-capture-contested{display:grid;gap:7px;max-height:420px;overflow:auto}.twmpw-wom-capture-contested>button{display:grid;grid-template-columns:26px minmax(0,1fr);gap:8px;padding:8px;border:1px solid #dec792;border-radius:9px;background:#fff;text-align:left}.twmpw-wom-capture-contested>button:hover{border-color:#ad8139;background:#fff8e8}.twmpw-wom-capture-contested>button>em{font-style:normal;color:#9b7b43;font-weight:900}.twmpw-wom-capture-contested>button>span{display:grid;gap:2px;min-width:0}.twmpw-wom-capture-contested b,.twmpw-wom-capture-contested small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.twmpw-wom-capture-contested b{color:#5b421d}.twmpw-wom-capture-contested small{color:#80663b}.twmpw-wom-capture-contested strong{justify-self:start;padding:2px 6px;border-radius:999px;font-size:9px}.twmpw-wom-capture-contested strong.is-held{background:#e5f5e9;color:#277b48}.twmpw-wom-capture-contested strong.is-lost{background:#f9e7e2;color:#a83f32}
.twmpw-wom-capture-ranking .twmpw-wom-stat-segmented{min-width:190px}.twmpw-wom-capture-ranking td:nth-child(2){max-width:330px}.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap{max-height:640px}.twmpw-wom-capture-journal table{min-width:1260px}.twmpw-wom-capture-journal th:nth-child(2),.twmpw-wom-capture-journal td:nth-child(2){text-align:left}.twmpw-wom-capture-journal td{vertical-align:top}.twmpw-wom-capture-journal time{display:grid;gap:2px;color:#65491c}.twmpw-wom-capture-journal time small{color:#8c744d}.twmpw-wom-capture-journal td>button:not(.twmpw-wom-capture-row-action){max-width:240px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:left}.twmpw-wom-capture-type{display:inline-flex;padding:2px 6px;border-radius:999px;font-size:9px;font-weight:900}.twmpw-wom-capture-type.is-gain{background:#e3f4e8;color:#227543}.twmpw-wom-capture-type.is-loss{background:#f8e4df;color:#a43a2e}.twmpw-wom-capture-type.is-barbarian{background:#eee8da;color:#6d5c3d}.twmpw-wom-capture-type.is-internal{background:#eee6f2;color:#6e487c}.twmpw-wom-capture-type.is-external{background:#f6ecd6;color:#7b571f}.twmpw-wom-capture-journal td:nth-child(5)>small{display:block;margin-top:3px;color:#80663b}.twmpw-wom-capture-current{display:grid;gap:2px}.twmpw-wom-capture-current b{font-size:10px}.twmpw-wom-capture-current small{max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.twmpw-wom-capture-current.is-held b{color:#23834a}.twmpw-wom-capture-current.is-lost b{color:#b43d31}.twmpw-wom-capture-row-action{white-space:nowrap}.twmpw-wom-capture-pagination{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:10px;padding-top:10px;border-top:1px solid #dec792;color:#71552a;font-size:11px}.twmpw-wom-capture-pagination label,.twmpw-wom-capture-pagination>div{display:flex;align-items:center;gap:7px}.twmpw-wom-capture-pagination select{height:32px}.twmpw-wom-capture-pagination button{width:34px;height:32px;border:1px solid #cfae70;border-radius:7px;background:#fff8e8;color:#684817;font-weight:900}.twmpw-wom-capture-pagination button:disabled{opacity:.45}.twmpw-wom-capture-retention-card{align-self:start}
@media(max-width:1220px){.twmpw-wom-capture-controls{grid-template-columns:1fr 1fr}.twmpw-wom-capture-kpis{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:760px){.twmpw-wom-capture-controls{grid-template-columns:1fr}.twmpw-wom-capture-actions{align-items:stretch;flex-direction:column}.twmpw-wom-capture-actions>div{justify-content:flex-start}.twmpw-wom-capture-waves article>div{grid-template-columns:1fr 1fr}.twmpw-wom-capture-pagination{align-items:flex-start;flex-direction:column}}
@media(max-width:520px){.twmpw-wom-capture-kpis{grid-template-columns:1fr}.twmpw-wom-capture-actions .twmpw-btn{flex:1 1 calc(50% - 6px)}.twmpw-wom-capture-active-filter{align-items:flex-start;flex-direction:column}}

/* World Map Stage 2 V14.18.1 — capture statistics UX, fullscreen virtual tables */
.twmpw-wom-capture-controls{
  grid-template-columns:minmax(560px,1.45fr) minmax(235px,.55fr) minmax(235px,.55fr);
  align-items:stretch;
}
.twmpw-wom-capture-mode-control{display:grid;gap:5px;min-width:0}
.twmpw-wom-capture-mode-control>.twmpw-wom-stat-segmented{
  display:grid;
  grid-template-columns:repeat(6,minmax(0,1fr));
  gap:3px;
  overflow:visible;
  min-width:0;
}
.twmpw-wom-capture-mode-control>.twmpw-wom-stat-segmented button{
  min-width:0;
  padding:6px 6px;
  font-size:10px;
  line-height:1.1;
  overflow:hidden;
  text-overflow:ellipsis;
}
.twmpw-wom-stat-filters.has-capture-search{
  grid-template-columns:120px 150px minmax(170px,1fr) minmax(170px,1fr) 115px 160px minmax(250px,1.35fr) auto;
}
.twmpw-wom-stat-capture-search{display:grid;gap:4px;min-width:0;color:#6d521d;font-size:11px;font-weight:900}
.twmpw-wom-stat-map-search{
  width:100%!important;
  min-width:0!important;
  height:36px!important;
  border-radius:10px!important;
  background:#fffaf0!important;
  z-index:1!important;
}
.twmpw-wom-stat-map-search input{height:34px!important;font-size:11px!important}
.twmpw-wom-stat-map-search>[data-map-search-clear]{position:static!important;grid-column:3;align-self:center;justify-self:center;right:auto!important;top:auto!important;transform:none!important;margin:0!important}
.twmpw-wom-capture-waves article>div{grid-template-columns:repeat(3,minmax(0,1fr))}
.twmpw-wom-capture-waves article>div .is-date{
  grid-column:1/-1;
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:12px;
  padding:7px 9px;
  background:#f2e2bb;
}
.twmpw-wom-capture-waves article>div .is-date small{font-size:9px;text-transform:uppercase;letter-spacing:.03em;font-weight:850}
.twmpw-wom-capture-waves article>div .is-date b{
  overflow:visible;
  text-overflow:clip;
  white-space:nowrap;
  font-size:11px;
  font-variant-numeric:tabular-nums;
}
.twmpw-wom-capture-table-head-actions{display:flex;align-items:center;justify-content:flex-end;gap:7px;min-width:0}
.twmpw-wom-capture-ranking .twmpw-wom-capture-ranking-switch{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));width:148px;min-width:148px;padding:2px;overflow:visible}
.twmpw-wom-capture-ranking-switch button{min-height:28px!important;padding:4px 8px!important;font-size:10px!important}
.twmpw-wom-capture-expand{
  display:grid;
  place-items:center;
  width:32px;
  height:32px;
  min-width:32px;
  padding:0;
  border:1px solid #cfad70;
  border-radius:8px;
  background:#fff8e8;
  color:#65461a;
  cursor:pointer;
}
.twmpw-wom-capture-expand:hover{border-color:#a8782e;background:#f2dfb6;color:#4d320b}
.twmpw-wom-capture-expand svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap{height:min(520px,58vh);max-height:none;overflow:auto;contain:layout paint}
.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap{height:min(640px,68vh);max-height:none;overflow:auto;contain:layout paint}
.twmpw-wom-capture-ranking table{min-width:980px}
.twmpw-wom-capture-ranking tbody tr:not(.twmpw-wom-stat-spacer-row){height:42px}
.twmpw-wom-capture-journal tbody tr:not(.twmpw-wom-stat-spacer-row){height:58px}
.twmpw-wom-capture-table-status{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:8px 12px;
  border-top:1px solid #dec792;
  background:#f4e4bc;
  color:#71552a;
  font-size:10px;
}
.twmpw-wom-capture-table-status span{font-weight:850}
.twmpw-wom-capture-table-status small{color:#80663b}
.twmpw-wom-capture-pagination{display:none!important}

.twmpw-wom-modal-capture-table{z-index:11040;padding:12px}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card{
  width:calc(100vw - 24px);
  height:calc(100vh - 24px);
  max-width:none;
  max-height:none;
  border-radius:14px;
}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>header button{
  display:grid;
  place-items:center;
  width:34px;
  height:34px;
  padding:0;
  border:0;
  border-radius:8px;
  background:transparent;
  color:#5b421d;
}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>header button:hover{background:rgba(255,250,238,.72)}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>header button svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>main{min-height:0;padding:0!important;overflow:hidden!important}
.twmpw-wom-capture-table-shell{display:grid;grid-template-rows:auto minmax(0,1fr);height:100%;min-height:0;background:#fffaf0}
.twmpw-wom-capture-table-toolbar{
  position:relative;
  z-index:4;
  display:grid;
  grid-template-columns:minmax(260px,1.35fr) minmax(180px,.72fr) minmax(180px,.72fr) minmax(130px,.52fr) auto auto;
  gap:9px;
  align-items:end;
  padding:11px 12px;
  border-bottom:1px solid #dec792;
  background:linear-gradient(180deg,#fffaf0,#f8edd4);
  box-shadow:0 4px 12px rgba(86,54,14,.07);
}
.twmpw-wom-capture-table-search,.twmpw-wom-capture-table-field{display:grid;gap:4px;min-width:0;color:#6d521d;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.03em}
.twmpw-wom-capture-table-field select{width:100%;min-width:0;height:36px}
.twmpw-wom-capture-table-toolbar>.twmpw-btn{height:36px;min-height:36px;white-space:nowrap}
.twmpw-wom-capture-table-found{align-self:center;justify-self:end;white-space:nowrap;color:#71552a;font-size:11px}
.twmpw-wom-capture-expanded-wrap{height:100%;max-height:none;min-height:0;overflow:auto;overscroll-behavior:contain;contain:layout paint;scrollbar-gutter:stable}
.twmpw-wom-capture-expanded-wrap table.is-ranking{min-width:1060px}
.twmpw-wom-capture-expanded-wrap table.is-journal{min-width:1380px}
.twmpw-wom-capture-expanded-wrap thead th{top:0;z-index:3;padding:0;background:#ead6a4}
.twmpw-wom-capture-expanded-wrap thead th>button{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:6px;
  width:100%;
  min-height:40px;
  padding:8px 9px;
  border:0;
  background:transparent;
  color:#65491c;
  font:900 10px/1.15 inherit;
  text-align:left;
  white-space:nowrap;
  cursor:pointer;
}
.twmpw-wom-capture-expanded-wrap thead th>button:hover{background:#dfc58d}
.twmpw-wom-capture-expanded-wrap thead th>button.is-active{background:#d8bb7c;color:#4d320b}
.twmpw-wom-capture-expanded-wrap thead th>button i{font-style:normal;font-size:11px;color:#947037}
.twmpw-wom-capture-expanded-wrap tbody tr:not(.twmpw-wom-stat-spacer-row){height:58px}
.twmpw-wom-capture-expanded-wrap table.is-ranking tbody tr:not(.twmpw-wom-stat-spacer-row){height:42px}
.twmpw-wom-capture-expanded-wrap td{vertical-align:middle}
.twmpw-wom-capture-expanded-wrap::-webkit-scrollbar,.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap::-webkit-scrollbar,.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap::-webkit-scrollbar{width:9px;height:9px}
.twmpw-wom-capture-expanded-wrap::-webkit-scrollbar-track,.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap::-webkit-scrollbar-track,.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap::-webkit-scrollbar-track{background:#fff7e5}
.twmpw-wom-capture-expanded-wrap::-webkit-scrollbar-thumb,.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap::-webkit-scrollbar-thumb,.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap::-webkit-scrollbar-thumb{background:#c6a160;border:2px solid #fff7e5;border-radius:999px}

@media(max-width:1420px){
  .twmpw-wom-stat-filters.has-capture-search{grid-template-columns:repeat(4,minmax(0,1fr))}
  .twmpw-wom-capture-table-toolbar{grid-template-columns:repeat(3,minmax(0,1fr))}
  .twmpw-wom-capture-table-found{justify-self:start}
}
@media(max-width:1220px){
  .twmpw-wom-capture-controls{grid-template-columns:1fr 1fr}
  .twmpw-wom-capture-mode-control{grid-column:1/-1}
}
@media(max-width:760px){
  .twmpw-wom-capture-controls{grid-template-columns:1fr}
  .twmpw-wom-capture-mode-control{grid-column:1}
  .twmpw-wom-capture-mode-control>.twmpw-wom-stat-segmented button{padding-inline:3px;font-size:9px}
  .twmpw-wom-capture-table-toolbar{grid-template-columns:1fr 1fr}
  .twmpw-wom-modal-capture-table{padding:0}
  .twmpw-wom-modal-capture-table>.twmpw-wom-modal-card{width:100vw;height:100vh;border-radius:0}
  .twmpw-wom-capture-table-status{align-items:flex-start;flex-direction:column}
}
@media(max-width:520px){
  .twmpw-wom-capture-mode-control>.twmpw-wom-stat-segmented{gap:2px;padding:2px}
  .twmpw-wom-capture-mode-control>.twmpw-wom-stat-segmented button{min-height:29px;padding-inline:1px;font-size:8.5px;letter-spacing:-.02em}
  .twmpw-wom-capture-waves article>div .is-date{align-items:flex-start;flex-direction:column;gap:2px}
  .twmpw-wom-capture-table-toolbar{grid-template-columns:1fr}
  .twmpw-wom-capture-table-found{justify-self:start}
}
/* V14.18.1 visual finish for expanded capture tables */
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>header>div{display:grid;gap:2px;min-width:0}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>header>div>b{font-size:14px;line-height:1.2}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>header>div>small{color:#80663b;font-size:10px;line-height:1.25}
.twmpw-wom-capture-expanded-wrap table.is-journal td:first-child{min-width:180px}
.twmpw-wom-capture-expanded-wrap table.is-journal td:nth-child(2){min-width:230px}
.twmpw-wom-capture-expanded-wrap table.is-journal td:nth-child(3),
.twmpw-wom-capture-expanded-wrap table.is-journal td:nth-child(4){min-width:150px}
.twmpw-wom-capture-expanded-wrap table.is-journal td:nth-child(5){min-width:135px}
.twmpw-wom-capture-expanded-wrap table.is-journal td:nth-child(6){min-width:185px}
.twmpw-wom-capture-expanded-wrap table.is-journal td:first-child time{display:grid;gap:2px;white-space:nowrap;font-variant-numeric:tabular-nums}
.twmpw-wom-capture-expanded-wrap table.is-journal td:first-child time>small{display:block;color:#80663b;font-size:9px;line-height:1.2}
.twmpw-wom-capture-expanded-wrap table.is-journal td:nth-child(5)>small{display:inline-block;margin-left:4px}
.twmpw-wom-capture-table-toolbar .twmpw-wom-capture-ranking-switch{width:100%;min-width:0}


/* World Map Stage 2 V14.18.2 — OS-style capture windows, faceted filters and instant suggestions */
.twmpw-wom-capture-window-head{position:relative;align-items:flex-start!important;margin-bottom:8px!important;padding-right:42px}
.twmpw-wom-capture-window-head>.twmpw-wom-capture-expand{position:absolute;top:0;right:0}
.twmpw-wom-capture-table-subbar{display:flex;align-items:center;justify-content:flex-start;min-height:34px;margin:0 0 9px}
.twmpw-wom-capture-table-subbar .twmpw-wom-capture-ranking-switch{width:148px;min-width:148px}
.twmpw-wom-capture-table-status{justify-content:flex-start;min-height:34px}
.twmpw-wom-capture-table-status small{display:none!important}
.twmpw-wom-stat-capture-search,.twmpw-wom-capture-table-search{overflow:visible}
.twmpw-wom-stat-sticky,.twmpw-wom-stat-filters,.twmpw-wom-capture-table-toolbar{overflow:visible!important}
.twmpw-wom-stat-map-search .twmpw-wom-map-search-popup{z-index:80;text-transform:none;letter-spacing:normal;font-weight:400}
.twmpw-wom-capture-table-toolbar>.twmpw-btn{display:inline-flex!important;align-items:center!important;justify-content:center!important;line-height:1!important;padding-top:0!important;padding-bottom:0!important}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card{display:grid;grid-template-rows:auto minmax(0,1fr) auto;overflow:hidden}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>header{width:100%;box-sizing:border-box}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>main,.twmpw-wom-capture-table-shell,.twmpw-wom-capture-table-toolbar,.twmpw-wom-capture-expanded-wrap{width:100%;box-sizing:border-box}
.twmpw-wom-capture-expanded-wrap table{width:100%!important;border-collapse:separate;border-spacing:0}
.twmpw-wom-capture-expanded-wrap table.is-ranking{min-width:1060px;width:100%!important}
.twmpw-wom-capture-expanded-wrap table.is-journal{min-width:1380px;width:100%!important}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>footer{width:100%;box-sizing:border-box}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>footer>[data-capture-table-footer]{font-weight:800;color:#71552a}
@media(max-width:760px){.twmpw-wom-capture-window-head{padding-right:40px}.twmpw-wom-capture-table-subbar{overflow-x:auto;scrollbar-width:none}}
.twmpw-wom-capture-expanded-wrap td button{
  max-width:100%;
  padding:5px 8px;
  border:1px solid #cfae70;
  border-radius:7px;
  background:#fff8e8;
  color:#684817;
  font:900 10px/1.2 inherit;
  text-align:left;
  box-shadow:none;
}
.twmpw-wom-capture-expanded-wrap td button:hover{border-color:#ad8139;background:#f2dfb6;color:#4d320b}
.twmpw-wom-capture-expanded-wrap td:last-child button{white-space:nowrap;text-align:center}


/* World Map Stage 2 V14.18.3 — aligned capture windows and stable search */
.twmpw-wom-capture-window-head{
  min-height:38px;
  align-items:center!important;
  padding-right:46px;
}
.twmpw-wom-capture-window-head>.twmpw-wom-capture-expand{
  top:50%;
  right:0;
  transform:translateY(-50%);
}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>main{
  padding:12px 14px 14px!important;
  background:#f8f1df!important;
}
.twmpw-wom-capture-table-shell{
  min-width:0;
  overflow:hidden;
  border:1px solid #dec792;
  border-radius:12px;
  background:#fffaf0;
  box-shadow:0 4px 12px rgba(86,54,14,.06);
}
.twmpw-wom-capture-table-toolbar{
  padding:12px 14px;
  background:#fffaf0;
  box-shadow:none;
}
.twmpw-wom-capture-expanded-wrap{
  margin:0;
  background:#fffaf0;
}
.twmpw-wom-capture-expanded-wrap thead th:first-child>button,
.twmpw-wom-capture-expanded-wrap tbody td:first-child{padding-left:12px}
.twmpw-wom-capture-expanded-wrap thead th:last-child>button,
.twmpw-wom-capture-expanded-wrap tbody td:last-child{padding-right:12px}
.twmpw-wom-capture-table-found{padding-inline:4px}
@media(max-width:760px){
  .twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>main{padding:8px!important}
  .twmpw-wom-capture-window-head{padding-right:42px}
}


/* World Map Stage 2 V14.18.4 — canonical continents and readable capture tables */
.twmpw-wom-capture-window-head{display:grid!important;grid-template-columns:minmax(0,1fr) auto;gap:14px;align-items:center!important;min-height:46px;padding:10px 12px!important;margin-bottom:8px!important}
.twmpw-wom-capture-window-head>.twmpw-wom-capture-expand{position:static!important;transform:none!important;align-self:center;justify-self:end;margin:0!important}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card{grid-template-rows:auto minmax(0,1fr)!important}
.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>main{padding:16px!important}
.twmpw-wom-capture-table-shell{height:100%;border-radius:13px;box-shadow:0 5px 18px rgba(77,50,11,.08)}
.twmpw-wom-capture-table-toolbar{gap:12px;padding:14px 16px;border-bottom:1px solid #d8bd82;background:linear-gradient(180deg,#fffaf0 0%,#fbf1dc 100%)}
.twmpw-wom-capture-expanded-wrap{padding:0 10px 10px;background:#fffaf0}
.twmpw-wom-capture-expanded-wrap table{border:1px solid #e1cc9d;border-radius:10px;overflow:hidden}
.twmpw-wom-capture-expanded-wrap thead th{border-bottom:1px solid #cba969}
.twmpw-wom-capture-expanded-wrap tbody tr:not(.twmpw-wom-stat-spacer-row),.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap tbody tr:not(.twmpw-wom-stat-spacer-row),.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap tbody tr:not(.twmpw-wom-stat-spacer-row){transition:background-color .14s ease,box-shadow .14s ease}
.twmpw-wom-capture-expanded-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):nth-child(even){background:#fff7e8}
.twmpw-wom-capture-expanded-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):nth-child(odd){background:#fffdf7}
.twmpw-wom-capture-expanded-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):hover,.twmpw-wom-capture-expanded-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):focus-within,.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):hover,.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):hover{background:#f3e1b8;box-shadow:inset 3px 0 0 #a86b16}
.twmpw-wom-capture-expanded-wrap tbody td{padding:10px 12px;border-bottom:1px solid rgba(210,181,123,.48);color:#5d4724;line-height:1.35}
.twmpw-wom-capture-expanded-wrap tbody tr:last-child td{border-bottom:0}
.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):nth-child(even),.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):nth-child(even){background:#fff8ea}
.twmpw-wom-capture-type-group{display:flex;flex-wrap:wrap;align-items:center;gap:4px;min-width:120px}
.twmpw-wom-capture-type,.twmpw-wom-capture-flag,.twmpw-wom-capture-current>b{display:inline-flex;align-items:center;min-height:20px;padding:3px 7px;border:1px solid transparent;border-radius:999px;font-size:9px;font-weight:900;line-height:1;white-space:nowrap}
.twmpw-wom-capture-flag.is-return{background:#e8edf8;border-color:#c7d2e8;color:#465f91}.twmpw-wom-capture-flag.is-pingpong{background:#f0e5f5;border-color:#d9c0e3;color:#724985}.twmpw-wom-capture-flag.is-repeat{background:#f4ead7;border-color:#dbc49a;color:#7d5a24}
.twmpw-wom-capture-current{align-items:start}.twmpw-wom-capture-current>b{justify-self:start}.twmpw-wom-capture-current.is-held>b{background:#e3f4e8;border-color:#b9ddc4;color:#227543}.twmpw-wom-capture-current.is-lost>b{background:#f8e4df;border-color:#e8bdb5;color:#a43a2e}.twmpw-wom-capture-current small{margin-top:2px;line-height:1.25}
.twmpw-wom-modal-capture-table [data-capture-table-done],.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>footer{display:none!important}
@media(max-width:760px){.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>main{padding:8px!important}.twmpw-wom-capture-expanded-wrap{padding:0 4px 6px}}


/* World Map Stage 2 V14.18.5 — coordinate-canonical continents and width-safe capture tables */
.twmpw-wom-capture-expanded-wrap,.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap,.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap{overflow-x:hidden!important;overflow-y:auto!important}
.twmpw-wom-capture-expanded-wrap table,.twmpw-wom-capture-ranking table,.twmpw-wom-capture-journal table{width:100%!important;min-width:0!important;max-width:100%!important;table-layout:fixed!important}
.twmpw-wom-capture-expanded-wrap table.is-journal,.twmpw-wom-capture-journal table{min-width:0!important}
.twmpw-wom-capture-expanded-wrap table.is-ranking{min-width:0!important}
.twmpw-wom-capture-expanded-wrap table,.twmpw-wom-capture-ranking table,.twmpw-wom-capture-journal table{font-size:10px!important}
.twmpw-wom-capture-expanded-wrap thead th,.twmpw-wom-capture-ranking thead th,.twmpw-wom-capture-journal thead th{padding:0!important;white-space:normal!important}
.twmpw-wom-capture-expanded-wrap thead th>button{min-height:42px;padding:7px 6px!important;font-size:10px!important;line-height:1.15;white-space:normal!important;gap:3px}
.twmpw-wom-capture-expanded-wrap tbody tr:not(.twmpw-wom-stat-spacer-row),.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap tbody tr:not(.twmpw-wom-stat-spacer-row){height:78px!important}
.twmpw-wom-capture-expanded-wrap table.is-ranking tbody tr:not(.twmpw-wom-stat-spacer-row),.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap tbody tr:not(.twmpw-wom-stat-spacer-row){height:42px!important}
.twmpw-wom-capture-expanded-wrap tbody td,.twmpw-wom-capture-ranking tbody td,.twmpw-wom-capture-journal tbody td{min-width:0!important;max-width:none!important;padding:7px 7px!important;white-space:normal!important;overflow:visible!important;text-overflow:clip!important;overflow-wrap:anywhere;word-break:normal;line-height:1.22!important}
.twmpw-wom-capture-expanded-wrap td>button:not(.twmpw-wom-capture-row-action),.twmpw-wom-capture-journal td>button:not(.twmpw-wom-capture-row-action){display:flex;align-items:center;justify-content:space-between;gap:5px;width:100%;max-width:none!important;white-space:normal!important;overflow:visible!important;text-overflow:clip!important;text-align:left;line-height:1.2}
.twmpw-wom-capture-expanded-wrap td>button:not(.twmpw-wom-capture-row-action)>span,.twmpw-wom-capture-journal td>button:not(.twmpw-wom-capture-row-action)>span{min-width:0;overflow-wrap:anywhere}
.twmpw-wom-capture-current small{max-width:none!important;white-space:normal!important;overflow:visible!important;text-overflow:clip!important;overflow-wrap:anywhere}
.twmpw-wom-capture-type-group{min-width:0!important;gap:3px}
.twmpw-wom-capture-type,.twmpw-wom-capture-flag,.twmpw-wom-capture-current>b{min-height:18px;padding:2px 5px;font-size:8px}
.twmpw-wom-capture-continent{display:inline-flex;flex:0 0 auto;align-items:center;justify-content:center;min-width:28px;min-height:19px;padding:2px 5px;border:1px solid #d4b36f;border-radius:999px;background:#f3e4c2;color:#654719;font-size:8px;font-style:normal;font-weight:900;line-height:1}
.twmpw-wom-capture-row-action{width:100%;min-width:0;padding:5px 4px!important;font-size:9px!important;white-space:nowrap!important}
/* Journal column proportions: all data stays inside the available viewport. */
.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(1),.twmpw-wom-capture-journal th:nth-child(1){width:11%}
.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(2),.twmpw-wom-capture-journal th:nth-child(2){width:17%}
.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(3),.twmpw-wom-capture-journal th:nth-child(3){width:12.5%}
.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(4),.twmpw-wom-capture-journal th:nth-child(4){width:12.5%}
.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(5),.twmpw-wom-capture-journal th:nth-child(5){width:10%}
.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(6),.twmpw-wom-capture-journal th:nth-child(6){width:16%}
.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(7),.twmpw-wom-capture-journal th:nth-child(7){width:7.5%}
.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(8),.twmpw-wom-capture-journal th:nth-child(8){width:7%}
.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(9),.twmpw-wom-capture-journal th:nth-child(9){width:6.5%}
/* Ranking column proportions. */
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(1),.twmpw-wom-capture-ranking th:nth-child(1){width:3%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(2),.twmpw-wom-capture-ranking th:nth-child(2){width:22%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(n+3),.twmpw-wom-capture-ranking th:nth-child(n+3){width:9.375%}
.twmpw-wom-capture-expanded-wrap::-webkit-scrollbar:horizontal,.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap::-webkit-scrollbar:horizontal,.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap::-webkit-scrollbar:horizontal{height:0!important;display:none!important}
@media(max-width:1180px){
 .twmpw-wom-capture-expanded-wrap table,.twmpw-wom-capture-ranking table,.twmpw-wom-capture-journal table{font-size:9px!important}
 .twmpw-wom-capture-expanded-wrap tbody td,.twmpw-wom-capture-ranking tbody td,.twmpw-wom-capture-journal tbody td{padding:6px 4px!important}
 .twmpw-wom-capture-expanded-wrap thead th>button{padding:6px 3px!important;font-size:9px!important}
}


/* World Map Stage 2 V14.19.0 — capture map workflow, heatmap analytics and balanced tables */
.twmpw-wom-analysis-heatmap-toggle{
  margin:8px 0 0!important;padding:8px 10px!important;min-height:48px!important;
  border:1px solid #ddc58f!important;border-radius:10px!important;background:#fff9ec!important;
  align-items:center!important;gap:12px!important
}
.twmpw-wom-analysis-heatmap-toggle>span:first-child{display:grid;gap:2px;min-width:0}
.twmpw-wom-analysis-heatmap-toggle b{font-size:12px;line-height:1.15;color:#5f4216}
.twmpw-wom-analysis-heatmap-toggle small{font-size:10px;line-height:1.25;color:#876b3b}
.twmpw-wom-analysis-heatmap-toggle.is-disabled{opacity:.56;cursor:not-allowed}
/* World Map Stage 2 V14.21.7 — compact toggles use the same slider/knob contract as the shared control. */
.twmpw-toggle-sm{min-width:38px!important}
.twmpw-toggle-sm .twmpw-toggle-slider{width:38px!important;height:22px!important}
.twmpw-toggle-sm .twmpw-toggle-slider::after{width:16px!important;height:16px!important;left:3px!important;top:3px!important}
.twmpw-toggle-sm input:checked+.twmpw-toggle-slider::after{left:19px!important}

/* Shared table rhythm: complete labels, no horizontal scrollbar, readable density. */
.twmpw-wom-capture-ranking .twmpw-wom-stat-table-wrap,
.twmpw-wom-capture-journal .twmpw-wom-stat-table-wrap,
.twmpw-wom-capture-expanded-wrap{
  overflow-x:hidden!important;overscroll-behavior:contain;scrollbar-gutter:stable;
  border:1px solid #e0ca98;border-radius:10px;background:#fffaf0
}
.twmpw-wom-capture-ranking table,
.twmpw-wom-capture-journal table,
.twmpw-wom-capture-expanded-wrap table{
  width:100%!important;min-width:0!important;max-width:100%!important;table-layout:fixed!important;
  border-collapse:separate!important;border-spacing:0!important;color:#5b431f
}
.twmpw-wom-capture-ranking table,.twmpw-wom-capture-journal table{font-size:11px!important}
.twmpw-wom-capture-expanded-wrap table{font-size:12px!important}
.twmpw-wom-capture-ranking thead th,.twmpw-wom-capture-journal thead th,
.twmpw-wom-capture-expanded-wrap thead th{
  height:44px!important;padding:8px 7px!important;background:#ead39a!important;color:#5a3d12!important;
  border-right:1px solid rgba(190,147,67,.34)!important;border-bottom:1px solid #c89b49!important;
  font-size:10.5px!important;font-weight:900!important;line-height:1.14!important;white-space:normal!important;
  overflow-wrap:normal!important;word-break:normal!important;vertical-align:middle!important
}
.twmpw-wom-capture-expanded-wrap thead th{height:48px!important;padding:8px 8px!important;font-size:11.5px!important}
.twmpw-wom-capture-ranking thead th:last-child,.twmpw-wom-capture-journal thead th:last-child,
.twmpw-wom-capture-expanded-wrap thead th:last-child{border-right:0!important}
.twmpw-wom-capture-expanded-wrap thead th>button{
  min-height:32px!important;width:100%!important;padding:2px 1px!important;font-size:11.5px!important;line-height:1.14!important;
  justify-content:space-between!important;white-space:normal!important;text-align:left!important
}
.twmpw-wom-capture-ranking tbody tr:not(.twmpw-wom-stat-spacer-row){height:48px!important}
.twmpw-wom-capture-journal tbody tr:not(.twmpw-wom-stat-spacer-row),
.twmpw-wom-capture-expanded-wrap table.is-journal tbody tr:not(.twmpw-wom-stat-spacer-row){height:92px!important}
.twmpw-wom-capture-expanded-wrap table.is-ranking tbody tr:not(.twmpw-wom-stat-spacer-row){height:48px!important}
.twmpw-wom-capture-ranking tbody td,.twmpw-wom-capture-journal tbody td,
.twmpw-wom-capture-expanded-wrap tbody td{
  min-width:0!important;padding:8px 8px!important;border-bottom:1px solid rgba(210,181,123,.48)!important;
  font-size:inherit!important;line-height:1.3!important;white-space:normal!important;vertical-align:middle!important;
  overflow:visible!important;text-overflow:clip!important;overflow-wrap:anywhere!important;word-break:normal!important
}
.twmpw-wom-capture-expanded-wrap tbody td{padding:9px 9px!important}
.twmpw-wom-capture-ranking tbody tr:not(.twmpw-wom-stat-spacer-row):nth-child(even),
.twmpw-wom-capture-journal tbody tr:not(.twmpw-wom-stat-spacer-row):nth-child(even),
.twmpw-wom-capture-expanded-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):nth-child(even){background:#fff7e7!important}
.twmpw-wom-capture-ranking tbody tr:not(.twmpw-wom-stat-spacer-row):hover,
.twmpw-wom-capture-journal tbody tr:not(.twmpw-wom-stat-spacer-row):hover,
.twmpw-wom-capture-expanded-wrap tbody tr:not(.twmpw-wom-stat-spacer-row):hover{
  background:#f4e2b8!important;box-shadow:inset 3px 0 0 #a96b12!important
}
.twmpw-wom-capture-ranking td>button,.twmpw-wom-capture-journal td>button:not(.twmpw-wom-capture-row-action),
.twmpw-wom-capture-expanded-wrap td>button:not(.twmpw-wom-capture-row-action){
  max-width:100%!important;width:100%!important;white-space:normal!important;overflow:visible!important;text-overflow:clip!important;
  overflow-wrap:anywhere!important;line-height:1.22!important
}
.twmpw-wom-capture-current small{display:block;max-width:none!important;margin-top:4px;white-space:normal!important;overflow:visible!important;text-overflow:clip!important;line-height:1.25!important}
.twmpw-wom-capture-row-action{
  display:flex!important;align-items:center!important;justify-content:center!important;width:100%!important;min-height:34px!important;
  padding:5px 4px!important;font-size:10px!important;font-weight:800!important;line-height:1.08!important;white-space:normal!important;text-align:center!important
}
.twmpw-wom-capture-expanded-wrap .twmpw-wom-capture-row-action{font-size:10.5px!important}
.twmpw-wom-capture-continent{font-size:9px!important;min-width:31px!important;min-height:20px!important}
.twmpw-wom-capture-type,.twmpw-wom-capture-flag,.twmpw-wom-capture-current>b{font-size:9px!important;min-height:19px!important;padding:3px 6px!important}
.twmpw-wom-capture-expanded-wrap .twmpw-wom-capture-type,
.twmpw-wom-capture-expanded-wrap .twmpw-wom-capture-flag,
.twmpw-wom-capture-expanded-wrap .twmpw-wom-capture-current>b{font-size:9.5px!important}
.twmpw-wom-capture-table-status{padding:8px 12px!important;font-size:10.5px!important}

/* Harmonious complete column headers in the collapsed ranking. */
.twmpw-wom-capture-ranking th:nth-child(1){width:4%}
.twmpw-wom-capture-ranking th:nth-child(2){width:22%}
.twmpw-wom-capture-ranking th:nth-child(3),.twmpw-wom-capture-ranking th:nth-child(4){width:9%}
.twmpw-wom-capture-ranking th:nth-child(5){width:8%}
.twmpw-wom-capture-ranking th:nth-child(6){width:10%}
.twmpw-wom-capture-ranking th:nth-child(7){width:11%}
.twmpw-wom-capture-ranking th:nth-child(8){width:10%}
.twmpw-wom-capture-ranking th:nth-child(9){width:8%}
.twmpw-wom-capture-ranking th:nth-child(10){width:9%}

/* Journal: all nine fields remain visible and wrap inside their own column. */
.twmpw-wom-capture-journal th:nth-child(1),.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(1){width:10.5%}
.twmpw-wom-capture-journal th:nth-child(2),.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(2){width:17%}
.twmpw-wom-capture-journal th:nth-child(3),.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(3){width:12.5%}
.twmpw-wom-capture-journal th:nth-child(4),.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(4){width:12.5%}
.twmpw-wom-capture-journal th:nth-child(5),.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(5){width:10%}
.twmpw-wom-capture-journal th:nth-child(6),.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(6){width:16%}
.twmpw-wom-capture-journal th:nth-child(7),.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(7){width:7.5%}
.twmpw-wom-capture-journal th:nth-child(8),.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(8){width:7%}
.twmpw-wom-capture-journal th:nth-child(9),.twmpw-wom-capture-expanded-wrap table.is-journal th:nth-child(9){width:7%}

/* Fullscreen ranking has room for readable full names and labels. */
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(1){width:4%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(2){width:21%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(3),
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(4){width:9%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(5){width:8%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(6){width:10%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(7){width:11%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(8){width:10%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(9){width:8%}
.twmpw-wom-capture-expanded-wrap table.is-ranking th:nth-child(10){width:10%}

.twmpw-wom-modal-capture-table>.twmpw-wom-modal-card>main{padding:14px!important;background:#f7edda!important}
.twmpw-wom-capture-table-shell{height:100%;border:1px solid #d8bd82!important;border-radius:13px!important;background:#fffaf0!important;overflow:hidden!important}
.twmpw-wom-capture-expanded-wrap{margin:10px!important;height:calc(100% - 102px)!important;padding:0!important}
.twmpw-wom-capture-table-toolbar{padding:12px 14px!important}

@media(max-width:1280px){
  .twmpw-wom-capture-ranking table,.twmpw-wom-capture-journal table{font-size:10px!important}
  .twmpw-wom-capture-expanded-wrap table{font-size:11px!important}
  .twmpw-wom-capture-ranking thead th,.twmpw-wom-capture-journal thead th{font-size:9.5px!important;padding:7px 4px!important}
  .twmpw-wom-capture-expanded-wrap thead th,.twmpw-wom-capture-expanded-wrap thead th>button{font-size:10.5px!important}
  .twmpw-wom-capture-ranking tbody td,.twmpw-wom-capture-journal tbody td{padding:7px 5px!important}
  .twmpw-wom-capture-expanded-wrap tbody td{padding:8px 6px!important}
}
@media(max-width:900px){
  .twmpw-wom-capture-ranking table,.twmpw-wom-capture-journal table{font-size:9.5px!important}
  .twmpw-wom-capture-expanded-wrap table{font-size:10px!important}
  .twmpw-wom-capture-row-action{font-size:9px!important}
}

/* World Map Stage 2 V14.19.2 — stable fullscreen capture grids and route-label-safe noble tooltip */
.twmpw-wom-capture-expanded-wrap{
  position:relative!important;
  scroll-padding-top:48px!important;
  overflow-anchor:none!important;
}
.twmpw-wom-capture-expanded-wrap table{
  width:100%!important;
  table-layout:fixed!important;
}
.twmpw-wom-capture-expanded-wrap colgroup col{
  min-width:0!important;
}
.twmpw-wom-capture-expanded-wrap thead th{
  position:sticky!important;
  top:0!important;
  z-index:7!important;
  background:#ead39a!important;
  background-clip:padding-box!important;
  box-shadow:0 1px 0 #c89b49,0 5px 9px rgba(92,61,17,.10)!important;
}
.twmpw-wom-capture-expanded-wrap thead th>button{
  position:relative!important;
  z-index:1!important;
}
.twmpw-wom-capture-expanded-wrap tbody td{
  box-sizing:border-box!important;
}
.twmpw-wom-capture-expanded-wrap{
  contain:none!important;
}
.twmpw-wom-capture-expanded-grid{
  display:grid!important;
  grid-template-rows:auto minmax(0,1fr)!important;
  min-width:0!important;
  min-height:0!important;
  height:calc(100% - 102px)!important;
  margin:10px!important;
  overflow:hidden!important;
  border:1px solid #e0ca98!important;
  border-radius:10px!important;
  background:#fffaf0!important;
}
.twmpw-wom-capture-expanded-head{
  min-width:0!important;
  overflow:hidden!important;
  padding-right:var(--capture-scrollbar-gutter,9px)!important;
  background:#ead39a!important;
  border-bottom:1px solid #c89b49!important;
  box-shadow:0 4px 9px rgba(92,61,17,.10)!important;
  z-index:3!important;
}
.twmpw-wom-capture-expanded-head table,
.twmpw-wom-capture-expanded-wrap table{
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  table-layout:fixed!important;
  border:0!important;
  border-radius:0!important;
}
.twmpw-wom-capture-expanded-head thead th{
  position:static!important;
  height:48px!important;
  padding:8px 8px!important;
  background:#ead39a!important;
  color:#5a3d12!important;
  border-right:1px solid rgba(190,147,67,.34)!important;
  font-size:11.5px!important;
  font-weight:900!important;
  line-height:1.14!important;
  white-space:normal!important;
  vertical-align:middle!important;
}
.twmpw-wom-capture-expanded-head thead th:last-child{border-right:0!important}
.twmpw-wom-capture-expanded-head thead th>button{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:5px!important;
  width:100%!important;
  min-height:32px!important;
  padding:2px 1px!important;
  border:0!important;
  border-radius:6px!important;
  background:transparent!important;
  color:inherit!important;
  font:900 11.5px/1.14 inherit!important;
  text-align:left!important;
  white-space:normal!important;
}
.twmpw-wom-capture-expanded-head thead th>button:hover{background:#dfc58d!important}
.twmpw-wom-capture-expanded-head thead th>button.is-active{background:#d8bb7c!important;color:#4d320b!important}
.twmpw-wom-capture-expanded-head thead th>button i{font-style:normal!important;color:#947037!important}
.twmpw-wom-capture-expanded-wrap{
  min-height:0!important;
  height:auto!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  box-shadow:none!important;
  overflow-x:hidden!important;
  overflow-y:auto!important;
  scroll-padding-top:0!important;
  contain:strict!important;
}
@media(max-width:1280px){
  .twmpw-wom-capture-expanded-head thead th,
  .twmpw-wom-capture-expanded-head thead th>button{font-size:10.5px!important}
}

/* World Map Stage 2 V14.19.2 — inset sortable headers, full-height capture grids and route-safe noble tooltip */
.twmpw-wom-capture-table-shell{
  grid-template-rows:auto minmax(0,1fr)!important;
  min-height:0!important;
}
.twmpw-wom-capture-expanded-grid{
  align-self:stretch!important;
  width:auto!important;
  height:auto!important;
  min-height:0!important;
  margin:10px!important;
  grid-template-rows:auto minmax(0,1fr)!important;
}
.twmpw-wom-capture-expanded-wrap{
  height:100%!important;
  min-height:0!important;
}
.twmpw-wom-capture-expanded-head thead th{
  padding:6px 5px!important;
  background:#ead39a!important;
}
.twmpw-wom-capture-expanded-head thead th>button{
  min-height:34px!important;
  padding:7px 9px!important;
  border:1px solid transparent!important;
  border-radius:8px!important;
  transition:background-color .14s ease,border-color .14s ease,box-shadow .14s ease,color .14s ease!important;
}
.twmpw-wom-capture-expanded-head thead th>button:hover{
  background:#e3ca91!important;
  border-color:rgba(174,126,48,.32)!important;
  box-shadow:0 1px 2px rgba(91,61,17,.08)!important;
}
.twmpw-wom-capture-expanded-head thead th>button.is-active{
  background:#d9bb79!important;
  border-color:#be9143!important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.48),0 2px 5px rgba(91,61,17,.14)!important;
  color:#4d320b!important;
}
.twmpw-wom-tip.is-noble-route{
  max-width:min(330px,calc(100vw - 24px))!important;
}
.twmpw-wom-tip.is-noble-route section{
  padding-block:9px!important;
}
@media(max-width:1280px){
  .twmpw-wom-capture-expanded-head thead th{padding:5px 4px!important}
  .twmpw-wom-capture-expanded-head thead th>button{padding:6px 7px!important}
}

/* World Map Stage 2 V14.20.0 — reactive bidirectional mass-plan bridge, transactional history and live merged forms */

.twmpw-mass-draft-destination-note{display:block;margin-top:5px;color:#84652c;font-size:11px;line-height:1.35;font-weight:600}
.twmpw-mass-draft-grid select[data-mass-draft="destination"]{min-height:40px}

/* World Map Stage 2 V14.20.1 — canonical planner model, live reconciled map view and world-aware mechanics */
.twmpw-wom-context-analytics .is-active-mode{background:#f1dfb8!important;box-shadow:inset 3px 0 0 #a96b10;color:#5a3708!important}
.twmpw-wom-context-analytics .is-reset.is-reset-follow{margin-top:0!important;border-top:0!important}
.twmpw-mass-plan-grid{grid-template-columns:minmax(310px,360px) minmax(0,1fr)}
.twmpw-mass-plan-assets{display:block;margin:10px 14px 0;padding:0;border:1px solid #dec792;border-radius:11px;background:#fffaf0;box-shadow:0 3px 10px rgba(86,54,14,.04);overflow:hidden;color:#5b421d}
.twmpw-mass-plan-assets>header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:9px 11px;border-bottom:1px solid #ead8ad;background:#f0dfbc}
.twmpw-mass-plan-assets>header b{font-size:12px}.twmpw-mass-plan-assets>header small{color:#80663b;font-size:10px}
.twmpw-mass-plan-assets>div{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:8px;padding:9px}
.twmpw-mass-plan-assets button{display:grid;grid-template-columns:30px minmax(0,1fr);align-items:center;gap:8px;min-width:0;padding:8px 10px;border:1px solid #dec792;border-radius:9px;background:#fff8e8;color:#5b421d;text-align:left;cursor:pointer;transition:background-color .14s ease,border-color .14s ease,transform .14s ease}
.twmpw-mass-plan-assets button:hover{background:#f3e2bd;border-color:#c9a762;transform:translateY(-1px)}
.twmpw-mass-plan-assets button>span:first-child{display:grid;place-items:center;width:30px;height:30px;border-radius:8px;background:#ead5a8;color:#78551c}
.twmpw-mass-plan-assets button svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-assets button>span:last-child{min-width:0}.twmpw-mass-plan-assets button b,.twmpw-mass-plan-assets button small{display:block}.twmpw-mass-plan-assets button b{font-size:11px}.twmpw-mass-plan-assets button small{margin-top:2px;color:#80663b;font-size:9.5px;white-space:normal}
.twmpw-mass-plan-empty [data-mass-draft-open-planner]{margin-top:10px}
@media(max-width:820px){.twmpw-mass-plan-grid{grid-template-columns:1fr}.twmpw-mass-plan-assets{margin-inline:10px;overflow:visible}.twmpw-mass-plan-assets>header{align-items:flex-start;flex-direction:column;gap:2px}.twmpw-mass-plan-assets>div{grid-template-columns:1fr 1fr}}
@media(max-width:520px){.twmpw-mass-plan-assets>div{grid-template-columns:1fr}}

/* World Map Stage 2 V14.20.2 — resilient mass-plan bridge, visible change previews and precise tower action target */
.twmpw-towers-input-block{display:grid;gap:9px;min-width:0}
.twmpw-towers-input-block>.twmpw-subhead{margin:0}
.twmpw-towers-builder-action{justify-content:flex-start;align-items:center;margin:0}
.twmpw-towers-builder-action>.twmpw-btn{width:auto;max-width:100%}
.twmpw-towers-input-block>textarea{width:100%;min-width:0;box-sizing:border-box}
.twmpw-wom-changes-output [data-analysis-changes-list]{min-width:0}
.twmpw-wom-changes-output .twmpw-wom-changes-list{max-height:min(390px,42vh);overflow:auto;overscroll-behavior:contain;scrollbar-gutter:stable}
.twmpw-wom-changes-output .twmpw-wom-change-row{flex:0 0 auto}

/* TWMP V14.21.0 — mass-plan tactical map overlay, unit icons and capability-aware settings */
.twmpw-mass-plan-tabs{display:flex;align-items:center;gap:4px;padding:8px 14px 0;border-bottom:1px solid #dec792;background:#fff7e5;flex:0 0 auto}
.twmpw-mass-plan-tabs button{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-width:120px;height:36px;padding:0 14px;border:1px solid transparent;border-bottom:0;border-radius:9px 9px 0 0;background:transparent;color:#765625;font-weight:900;cursor:pointer}
.twmpw-mass-plan-tabs button:hover{background:#f3e2bd}.twmpw-mass-plan-tabs button.is-active{background:#fffaf0;border-color:#d3b779;color:#4d320b;box-shadow:0 -2px 8px rgba(83,53,13,.06)}
.twmpw-mass-plan-tabs svg{width:17px;height:17px;fill:none!important;stroke:currentColor!important;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-mass-plan-tab-panel{display:none;min-height:0;flex:1}.twmpw-mass-plan-tab-panel.is-active{display:flex;flex-direction:column}.twmpw-mass-plan-tab-panel[hidden]{display:none!important}
.twmpw-mass-plan-unit{display:inline-flex;align-items:center;gap:6px;min-width:0;color:#6f501f;font-size:10px;font-weight:850}
.twmpw-mass-plan-unit .twmpw-wom-unit-icon-wrap{width:20px;height:20px;flex-basis:20px}.twmpw-mass-plan-unit .twmpw-wom-unit-icon-fallback{font-size:13px}
.twmpw-mass-plan-row>span>.twmpw-mass-plan-unit{margin-top:4px}.twmpw-mass-plan-row>span>.twmpw-mass-plan-unit+small{margin-top:4px}
.twmpw-mass-plan-link-meta>.twmpw-mass-plan-unit{padding:3px 7px;border:1px solid #dec792;border-radius:999px;background:#fff7e5}.twmpw-mass-plan-link-meta>.twmpw-mass-plan-unit .twmpw-wom-unit-icon-wrap{width:18px;height:18px;flex-basis:18px}
.twmpw-mass-plan-search-popup .twmpw-mass-plan-unit{justify-content:center}.twmpw-mass-plan-search-popup .twmpw-mass-plan-unit .twmpw-wom-unit-icon-wrap{width:22px;height:22px;flex-basis:22px}
.twmpw-mass-plan-settings-panel{height:100%;overflow:auto;padding:14px;display:grid;align-content:start;gap:12px;scrollbar-width:thin;scrollbar-color:#c6a160 #fff7e5}
.twmpw-mass-plan-settings-intro{display:grid;grid-template-columns:42px minmax(0,1fr) auto;align-items:center;gap:12px;padding:14px;border:1px solid #dec792;border-radius:12px;background:#fffaf0;box-shadow:0 3px 10px rgba(86,54,14,.04)}
.twmpw-mass-plan-settings-intro>span{display:grid;place-items:center;width:42px;height:42px;border-radius:11px;background:#ead5a8;color:#78551c}.twmpw-mass-plan-settings-intro svg{width:23px;height:23px;fill:none!important;stroke:currentColor!important;stroke-width:1.8}
.twmpw-mass-plan-settings-intro>div{display:grid;gap:3px;min-width:0}.twmpw-mass-plan-settings-intro b{font-size:14px;color:#4d320b}.twmpw-mass-plan-settings-intro small{font-size:10.5px;line-height:1.4;color:#80663b}.twmpw-mass-plan-settings-intro em{padding:6px 10px;border:1px solid #d6b979;border-radius:999px;background:#fff7e5;color:#6d4d1d;font-size:10px;font-style:normal;font-weight:900;white-space:nowrap}
.twmpw-mass-plan-settings-list{display:grid;gap:9px}
.twmpw-mass-plan-setting{display:flex;align-items:center;justify-content:space-between;gap:18px;min-height:66px;padding:11px 13px;border:1px solid #dec792;border-radius:11px;background:#fffaf0;cursor:pointer;transition:background-color .14s,border-color .14s,transform .14s}.twmpw-mass-plan-setting:hover{background:#fff3d7;border-color:#cba35f;transform:translateY(-1px)}
.twmpw-mass-plan-setting.is-dependent{margin-left:24px;border-left:4px solid #d3b779}.twmpw-mass-plan-setting.is-disabled{opacity:.58;cursor:not-allowed;transform:none}.twmpw-mass-plan-setting>span:first-child{display:grid;gap:3px;min-width:0}.twmpw-mass-plan-setting b{font-size:12px;color:#52370f}.twmpw-mass-plan-setting small{font-size:10px;color:#80663b;line-height:1.4}
.twmpw-mass-plan-settings-note{padding:12px 13px;border:1px solid #dec792;border-radius:11px;background:#fff8e8}.twmpw-mass-plan-settings-note>b{display:block;margin-bottom:8px;color:#5b421d;font-size:12px}.twmpw-mass-plan-settings-note>div{display:flex;align-items:center;gap:14px;flex-wrap:wrap}.twmpw-mass-plan-settings-note span{display:inline-flex;align-items:center;gap:6px;color:#765625;font-size:10px;font-weight:850}.twmpw-mass-plan-settings-note i{display:inline-block;width:22px;height:7px;border-radius:999px}.twmpw-mass-plan-settings-note i.is-route{background:linear-gradient(90deg,#8e5a16,#950404)}.twmpw-mass-plan-settings-note i.is-heat{height:14px;background:radial-gradient(circle,#c0392b 0,rgba(192,57,43,.08) 70%)}.twmpw-mass-plan-settings-note i.is-radius{height:18px;border:2px dashed #2777b8;background:rgba(39,119,184,.08)}.twmpw-mass-plan-settings-note small{display:block;margin-top:9px;color:#80663b;font-size:10px;line-height:1.4}
@media(max-width:820px){.twmpw-mass-plan-tabs{padding-inline:10px}.twmpw-mass-plan-tabs button{flex:1;min-width:0}.twmpw-mass-plan-settings-panel{padding:10px}.twmpw-mass-plan-settings-intro{grid-template-columns:38px minmax(0,1fr)}.twmpw-mass-plan-settings-intro>em{grid-column:1/-1;justify-self:start}.twmpw-mass-plan-setting.is-dependent{margin-left:12px}}
@media(max-width:520px){.twmpw-mass-plan-setting{align-items:flex-start}.twmpw-mass-plan-setting .twmpw-toggle{margin-top:3px}.twmpw-mass-plan-settings-note>div{display:grid;gap:8px}}
/* V14.21.0 modal track correction: generic modal flex rule must not override the mass-plan window grid. */
.twmpw-mass-plan-modal>.twmpw-wom-modal-card{display:grid!important}
/* World Map Stage 2 V14.21.0 */
/* TWMP V14.21.1 — readable tactical mass overlay: operational areas, axes and exact coverage unions */
.twmpw-mass-plan-settings-note i.is-area{height:14px;border:1.5px dashed #3869a8;border-radius:5px;background:rgba(56,105,168,.07)}
.twmpw-wom-tip-travel .twmpw-wom-unit-icon-wrap{vertical-align:middle}
/* World Map Stage 2 V14.21.1 */
/* TWMP V14.21.2 — compact, structured tactical reference cards */
.twmpw-wom-tip>.twmpw-wom-tip-mass{padding:9px 9px 10px;background:linear-gradient(180deg,rgba(255,252,244,.99),rgba(249,239,216,.98))}
.twmpw-wom-tip-mass>h4{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:0 0 7px;color:#4c3513;font-size:11px;line-height:1.25}
.twmpw-wom-tip-mass>h4>span{min-width:0}.twmpw-wom-tip-mass-count{flex:none;padding:2px 6px;border:1px solid #dcc48f;border-radius:999px;background:#fff8e7;color:#735221;font-size:9px;font-weight:900}
.twmpw-wom-tip-mass-list{display:grid;gap:6px;max-height:min(42vh,330px);overflow:auto;padding-right:2px;scrollbar-width:thin;scrollbar-color:#caa96b transparent}
.twmpw-wom-tip-mass-card{--mass-card-color:#8e5a16;position:relative;display:grid;gap:6px;padding:8px 8px 8px 10px;border:1px solid rgba(153,113,48,.28);border-radius:8px;background:rgba(255,253,247,.94);box-shadow:inset 3px 0 0 var(--mass-card-color),0 2px 8px rgba(84,54,14,.05)}
.twmpw-wom-tip-mass-card>header{display:grid;grid-template-columns:24px minmax(0,1fr);align-items:center;gap:7px;min-width:0}.twmpw-wom-tip-mass-card>header>.twmpw-wom-unit-icon-wrap{width:24px;height:24px;flex-basis:24px}.twmpw-wom-tip-mass-card>header>span:last-child{display:grid;gap:1px;min-width:0}.twmpw-wom-tip-mass-card>header small{color:#85683a;font-size:8.5px;font-weight:800;text-transform:uppercase;letter-spacing:.04em}.twmpw-wom-tip-mass-card>header b{color:#3f2b0e;font-size:10.5px;line-height:1.25;white-space:normal;overflow-wrap:anywhere}
.twmpw-wom-tip-mass-head{display:grid;grid-template-columns:24px minmax(0,1fr);align-items:center;gap:7px;min-width:0}.twmpw-wom-tip-mass-head>.twmpw-wom-unit-icon-wrap{width:24px;height:24px;flex-basis:24px}
.twmpw-wom-tip-mass-title{display:grid;gap:1px;min-width:0}.twmpw-wom-tip-mass-title b{color:#3f2b0e;font-size:10.5px;line-height:1.25;white-space:normal;overflow-wrap:anywhere}.twmpw-wom-tip-mass-title small{color:#85683a;font-size:9px;line-height:1.25}
.twmpw-wom-tip-mass-target{display:grid;place-items:center;width:24px;height:24px;border:2px solid var(--mass-card-color);border-radius:50%;background:color-mix(in srgb,var(--mass-card-color) 9%,#fff);color:var(--mass-card-color);font-size:12px;font-weight:950}.twmpw-wom-tip-mass-target::after{content:'';width:5px;height:5px;border-radius:50%;background:currentColor}
.twmpw-wom-tip-mass-metrics{display:flex;flex-wrap:wrap;gap:4px}.twmpw-wom-tip-mass-metric{display:inline-flex;align-items:baseline;gap:3px;padding:2px 5px;border:1px solid rgba(161,124,61,.22);border-radius:999px;background:#fbf2dd;color:#785a2b;font-size:8.5px;line-height:1.25}.twmpw-wom-tip-mass-metric b{color:#4a3313;font-size:9px}
.twmpw-wom-tip-mass-units{display:flex;align-items:center;gap:4px;overflow:hidden}.twmpw-wom-tip-mass-unit{display:inline-flex;align-items:center;gap:2px;color:#5c421d;font-size:9px}.twmpw-wom-tip-mass-units .twmpw-wom-unit-icon-wrap{width:20px;height:20px;flex-basis:20px;border-radius:4px;background:#f4e5c4}
@media(max-width:640px){.twmpw-wom-tip-mass-list{max-height:36vh}.twmpw-wom-tip-mass-card{padding:7px 7px 7px 9px}.twmpw-wom-tip-mass-metrics{gap:3px}}
/* World Map Stage 2 V14.21.2 */
/* TWMP V14.21.3 — compact building reference inside tactical tooltips */
.twmpw-wom-tip-mass-building{position:relative;display:grid;place-items:center;width:24px;height:24px;border:2px solid var(--mass-card-color);border-radius:6px;background:#fff9ea;color:var(--mass-card-color)}
.twmpw-wom-tip-mass-building::before{content:'✚';font-size:14px;font-weight:900;line-height:1}.twmpw-wom-tip-mass-building[data-building="tower"]::before{content:'♜';font-size:16px}.twmpw-wom-tip-mass-building[data-building="cathedral"]{border-radius:50%;box-shadow:inset 0 0 0 2px #fff9ea,inset 0 0 0 3px var(--mass-card-color)}
.twmpw-wom-tip-mass-card.is-building{background:linear-gradient(180deg,rgba(255,253,247,.97),rgba(249,240,219,.95))}
/* World Map Stage 2 V14.21.3 */
/* TWMP V14.21.4 — native Tribal Wars building artwork */
.twmpw-wom-building-icon-wrap{position:relative;display:grid;place-items:center;width:26px;height:26px;overflow:visible;border-radius:5px;background:rgba(255,249,234,.72)}
.twmpw-wom-building-icon{position:relative;z-index:1;display:block;width:26px;height:26px;object-fit:contain;image-rendering:auto;filter:drop-shadow(0 1px 1px rgba(62,39,8,.28))}
.twmpw-wom-building-icon-wrap[data-building="cathedral"]{background:rgba(249,239,255,.72)}
.twmpw-wom-tip-mass-card.is-building>header{grid-template-columns:26px minmax(0,1fr)}
/* World Map Stage 2 V14.21.4 */
/* World Map Stage 2 V14.21.5 — hard tooltip/caption collision exclusion */
/* World Map Stage 2 V14.21.6 — protected attack-scheme cards and independent heatmaps */


/* World Map Stage 2 V14.21.8 — state-aware context menu and unified cancellation zone */
.twmpw-wom-context-sub>[data-c="mass-plan"],.twmpw-wom-context-sub>[data-c="attacks"],.twmpw-wom-context-sub>[data-c="analytics"],.twmpw-wom-context-sub>[data-c="drawing"]{display:grid!important;grid-template-columns:minmax(0,1fr) 30px 16px!important;align-items:center;gap:7px}
.twmpw-wom-context-sub>[data-c="mass-plan"]>span,.twmpw-wom-context-sub>[data-c="attacks"]>span,.twmpw-wom-context-sub>[data-c="analytics"]>span,.twmpw-wom-context-sub>[data-c="drawing"]>span{grid-column:1;min-width:0}
.twmpw-wom-context-sub>[data-c="mass-plan"]>.twmpw-wom-context-active,.twmpw-wom-context-sub>[data-c="attacks"]>.twmpw-wom-context-active,.twmpw-wom-context-sub>[data-c="analytics"]>.twmpw-wom-context-active,.twmpw-wom-context-sub>[data-c="drawing"]>.twmpw-wom-context-active{grid-column:2;justify-self:center;box-sizing:border-box;font-variant-numeric:tabular-nums}
.twmpw-wom-context-sub>[data-c="mass-plan"]>b,.twmpw-wom-context-sub>[data-c="attacks"]>b,.twmpw-wom-context-sub>[data-c="analytics"]>b,.twmpw-wom-context-sub>[data-c="drawing"]>b{grid-column:3;justify-self:end;width:16px;text-align:center}
.twmpw-wom-context-reset-zone{display:grid;gap:2px;margin-top:6px;padding-top:6px;border-top:1px solid #e1c794}
.twmpw-wom-context-reset-zone>.is-reset{margin-top:0!important;border-top:0!important;border-radius:7px!important;background:#fff3e9!important;color:#8a321f!important}
.twmpw-wom-context-reset-zone>.is-reset:hover{background:#f8dfd0!important;color:#742315!important}
.twmpw-wom-context-reset-zone>.is-reset svg{stroke:#a13f29!important}
.twmpw-wom-context>.twmpw-wom-context-reset-zone{margin:5px 0 0;padding:6px 0 0}
.twmpw-wom-context>.twmpw-wom-context-reset-zone button{width:100%;display:grid;grid-template-columns:24px minmax(0,1fr);align-items:center;gap:8px;text-align:left}
.twmpw-wom-context-analytics .is-reset,.twmpw-wom-context-drawing .is-reset,.twmpw-wom-context-attacks .is-reset,.twmpw-wom-context-mass-plan .is-reset,.twmpw-wom-context>.is-reset{margin-top:0!important;border-top:0!important}
.twmpw-wom-changes-filter-notice{display:block;width:100%;padding:7px 9px;border:1px solid #ddb66f;border-radius:8px;background:#fff7df;line-height:1.4}


/* World Map Stage 2 V14.21.9 — focused merged coverage and live change filters */
.twmpw-wom-changes-primary-actions .twmpw-btn:disabled{cursor:progress}
.twmpw-wom-context-reset-zone>.is-reset{min-height:36px}
.twmpw-wom-context-active{font-variant-numeric:tabular-nums}

/* V14.21.10 — defence forecast and collision-safe tactical overlays */
.twmpw-aa-defence-forecast-summary{display:grid;gap:9px;padding:13px 15px;border:1px solid #d7b46e;border-radius:13px;background:linear-gradient(135deg,#fff8e8,#f8ebcf)}
.twmpw-aa-defence-forecast-summary header{display:flex;align-items:center;justify-content:space-between;gap:14px}.twmpw-aa-defence-forecast-summary header span{display:grid;gap:3px}.twmpw-aa-defence-forecast-summary header strong{display:grid;place-items:center;min-width:38px;height:32px;padding:0 8px;border-radius:999px;background:#9b5d0a;color:#fff;font-size:16px}.twmpw-aa-defence-forecast-summary>div{display:flex;gap:8px;flex-wrap:wrap}.twmpw-aa-defence-forecast-summary>div span{padding:6px 8px;border-radius:8px;background:rgba(255,250,240,.9);color:#6a4b1b;font-size:11px}.twmpw-aa-defence-forecast-summary small{color:#7c6238;line-height:1.4}
.twmpw-aa-tip-forecast{display:grid;gap:3px;margin-top:9px;padding:8px 9px;border-left:4px solid #9a7a21;border-radius:8px;background:#f7edd7}.twmpw-aa-tip-forecast.is-high{border-left-color:#c46d16;background:#fff0dc}.twmpw-aa-tip-forecast.is-critical{border-left-color:#a93124;background:#ffebe7}.twmpw-aa-tip-forecast.is-stable{border-left-color:#3c7d55;background:#eaf5ed}.twmpw-aa-tip-forecast span,.twmpw-aa-tip-forecast small{display:block;color:#70552b}


/* World Map Stage 2 V14.21.11 — defence forecast table and target-player grouping */
.twmpw-aa-forecast-table-toolbar{margin-bottom:10px;border:1px solid #dec18a;border-radius:14px;background:#fffaf0;overflow:hidden;box-shadow:0 5px 18px rgba(89,57,12,.05)}
.twmpw-aa-table-forecast-switch{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:13px 15px;cursor:pointer}.twmpw-aa-table-forecast-switch>span{display:grid;gap:3px;min-width:0}.twmpw-aa-table-forecast-switch b{color:#563b12;font-size:13px}.twmpw-aa-table-forecast-switch small{color:#80663b;font-size:10.5px;line-height:1.35;font-weight:650}.twmpw-aa-table-forecast-switch input{position:absolute;opacity:0;pointer-events:none}.twmpw-aa-table-forecast-switch>i{position:relative;flex:0 0 46px;width:46px;height:25px;border-radius:999px;background:#d8c39a;box-shadow:inset 0 0 0 1px #b99555;transition:.18s}.twmpw-aa-table-forecast-switch>i:after{content:"";position:absolute;width:19px;height:19px;left:3px;top:3px;border-radius:50%;background:#fffaf0;box-shadow:0 2px 5px rgba(69,43,8,.28);transition:.18s}.twmpw-aa-table-forecast-switch input:checked+i{background:#a96b10}.twmpw-aa-table-forecast-switch input:checked+i:after{transform:translateX(21px)}
.twmpw-aa-forecast-table-toolbar.is-active .twmpw-aa-table-forecast-switch{background:linear-gradient(90deg,rgba(246,231,199,.75),rgba(255,250,240,.94))}.twmpw-aa-forecast-table-controls{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border-top:1px solid #ead5ac;background:rgba(248,235,207,.45)}
.twmpw-aa-forecast-group,.twmpw-aa-forecast-actions{display:flex;align-items:center;gap:7px;min-width:0}.twmpw-aa-forecast-group>span{font-size:10px;color:#85683d;font-weight:850;margin-right:2px}.twmpw-aa-forecast-group button,.twmpw-aa-forecast-actions button,.twmpw-aa-forecast-row-actions button{border:1px solid #cfaa69;background:#fffaf0;color:#5b3d10;border-radius:9px;padding:7px 10px;font-weight:850;font-size:10.5px;white-space:nowrap;cursor:pointer}.twmpw-aa-forecast-group button.is-active{background:#a96b10;color:#fff8ea;border-color:#8d5708;box-shadow:inset 0 0 0 1px rgba(255,255,255,.16)}.twmpw-aa-forecast-actions button{display:inline-flex;align-items:center;gap:6px}.twmpw-aa-forecast-actions button:disabled{opacity:.5;cursor:not-allowed}
.twmpw-aa-table-wrap.is-defence-forecast{height:calc(94vh - 296px);min-height:360px}.twmpw-aa-forecast-table th:nth-child(1){width:12%}.twmpw-aa-forecast-table th:nth-child(2){width:17%}.twmpw-aa-forecast-table th:nth-child(3){width:15%}.twmpw-aa-forecast-table th:nth-child(4){width:17%}.twmpw-aa-forecast-table th:nth-child(5){width:29%}.twmpw-aa-forecast-table th:nth-child(6){width:10%}.twmpw-aa-forecast-table td{vertical-align:middle;padding:10px}.twmpw-aa-forecast-target-row.is-grouped td:nth-child(2){padding-left:24px}.twmpw-aa-forecast-target-row.is-grouped td:nth-child(2):before{content:"↳";display:inline-block;margin-left:-16px;margin-right:5px;color:#ad7a2b;font-weight:900}
.twmpw-aa-forecast-risk{display:grid;grid-template-columns:42px minmax(0,1fr);gap:3px 7px;align-items:center;min-width:0}.twmpw-aa-forecast-risk>b{grid-row:1/3;display:grid;place-items:center;width:40px;height:40px;border-radius:12px;background:#eef5ee;color:#36714f;font-size:17px;font-variant-numeric:tabular-nums}.twmpw-aa-forecast-risk>span{display:grid;gap:1px;min-width:0}.twmpw-aa-forecast-risk strong{font-size:10px;white-space:nowrap}.twmpw-aa-forecast-risk small{font-size:8.5px;color:#8a6d42;white-space:nowrap}.twmpw-aa-forecast-risk>i{grid-column:1/-1;height:4px;background:#eadfc9;border-radius:99px;overflow:hidden}.twmpw-aa-forecast-risk>i em{display:block;height:100%;background:#4f8b63;border-radius:inherit}.twmpw-aa-forecast-risk.is-watch>b{background:#fff5d8;color:#8c6d12}.twmpw-aa-forecast-risk.is-watch>i em{background:#b58c1a}.twmpw-aa-forecast-risk.is-high>b{background:#fff0dd;color:#a85e12}.twmpw-aa-forecast-risk.is-high>i em{background:#c46d16}.twmpw-aa-forecast-risk.is-critical>b{background:#ffe7e2;color:#a52d22}.twmpw-aa-forecast-risk.is-critical>i em{background:#b83a2d}
.twmpw-aa-forecast-village,.twmpw-aa-forecast-owner,.twmpw-aa-forecast-threat{display:grid;gap:3px;min-width:0}.twmpw-aa-forecast-village>b{font-size:13px;color:#9b5f08;font-variant-numeric:tabular-nums}.twmpw-aa-forecast-village>strong,.twmpw-aa-forecast-owner>b,.twmpw-aa-forecast-threat>b{font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.twmpw-aa-forecast-village small,.twmpw-aa-forecast-owner small,.twmpw-aa-forecast-threat small{font-size:9px;color:#84673b;line-height:1.25}.twmpw-aa-forecast-threat em{font-size:9px;font-style:normal;color:#a46012;font-weight:800}
.twmpw-aa-forecast-weakness{display:grid;gap:6px}.twmpw-aa-forecast-weakness>span{display:flex;gap:4px;flex-wrap:wrap}.twmpw-aa-forecast-weakness>span span{padding:3px 6px;border-radius:999px;background:#f0eadc;color:#806944;font-size:8.5px;font-weight:850}.twmpw-aa-forecast-weakness .is-danger{background:#ffe5df;color:#9d2d22}.twmpw-aa-forecast-weakness .is-warn{background:#fff0d3;color:#9a650d}.twmpw-aa-forecast-weakness .is-ok{background:#e6f2e8;color:#39704c}.twmpw-aa-forecast-weakness .is-unknown{background:#eee9de;color:#7f745f}.twmpw-aa-forecast-weakness>small{font-size:9px;color:#775b31;line-height:1.3}
.twmpw-aa-forecast-row-actions{display:grid;gap:6px}.twmpw-aa-forecast-row-actions button{width:100%;padding:6px 7px}.twmpw-aa-forecast-player-row{background:#f2dfb9!important}.twmpw-aa-forecast-player-row td{border-top:2px solid #c9994b;border-bottom:1px solid #cda45f!important}.twmpw-aa-forecast-player-summary{display:flex;align-items:center;justify-content:space-between;gap:16px}.twmpw-aa-forecast-player-summary>span{display:grid;gap:2px}.twmpw-aa-forecast-player-summary>span>b{font-size:13px;color:#56370c}.twmpw-aa-forecast-player-summary small{font-size:9px;color:#80613a}.twmpw-aa-forecast-player-summary>div{display:flex;align-items:center;gap:12px;flex-wrap:wrap;justify-content:flex-end}.twmpw-aa-forecast-player-summary strong{font-size:11px;color:#8f5709}.twmpw-aa-forecast-player-summary em{font-size:9px;font-style:normal;color:#73572d;font-weight:800}
.twmpw-aa-inline-switch.is-disabled{opacity:.55;cursor:not-allowed}
@media(max-width:1100px){.twmpw-aa-forecast-table-controls{align-items:stretch;flex-direction:column}.twmpw-aa-forecast-actions{justify-content:flex-end}.twmpw-aa-forecast-table th:nth-child(3),.twmpw-aa-forecast-table td:nth-child(3){display:none}.twmpw-aa-forecast-table th:nth-child(1){width:14%}.twmpw-aa-forecast-table th:nth-child(2){width:21%}.twmpw-aa-forecast-table th:nth-child(4){width:20%}.twmpw-aa-forecast-table th:nth-child(5){width:34%}.twmpw-aa-forecast-table th:nth-child(6){width:11%}}
@media(max-width:760px){.twmpw-aa-forecast-group,.twmpw-aa-forecast-actions{flex-wrap:wrap}.twmpw-aa-forecast-table th:nth-child(4),.twmpw-aa-forecast-table td:nth-child(4){display:none}.twmpw-aa-forecast-table th:nth-child(1){width:19%}.twmpw-aa-forecast-table th:nth-child(2){width:25%}.twmpw-aa-forecast-table th:nth-child(5){width:42%}.twmpw-aa-forecast-table th:nth-child(6){width:14%}}


/* World Map Stage 2 V14.21.12 — multi-risk filtering, collapsible players and map-card controls */
.twmpw-aa-forecast-risk-filter{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:10px 12px;border-top:1px solid #ead5ac;background:rgba(255,250,240,.74)}.twmpw-aa-forecast-risk-filter>span{display:grid;gap:2px;min-width:180px}.twmpw-aa-forecast-risk-filter>span b{font-size:11px;color:#5e4012}.twmpw-aa-forecast-risk-filter>span small{font-size:9px;color:#846b43;line-height:1.3}.twmpw-aa-forecast-risk-filter>div{display:flex;align-items:center;justify-content:flex-end;gap:6px;flex-wrap:wrap}.twmpw-aa-risk-chip{position:relative;display:inline-flex;align-items:center;gap:5px;padding:6px 8px;border:1px solid #d6bd8f;border-radius:999px;background:#fffaf0;color:#765a31;cursor:pointer;font-size:9.5px;font-weight:850;transition:.14s}.twmpw-aa-risk-chip input{position:absolute;opacity:0;pointer-events:none}.twmpw-aa-risk-chip i{width:7px;height:7px;border-radius:50%;background:#9a8a6d}.twmpw-aa-risk-chip b{min-width:17px;padding:1px 5px;border-radius:99px;background:rgba(87,61,19,.08);font-size:8.5px;text-align:center;font-variant-numeric:tabular-nums}.twmpw-aa-risk-chip.is-active{box-shadow:inset 0 0 0 1px rgba(255,255,255,.45),0 2px 6px rgba(81,49,8,.08)}.twmpw-aa-risk-chip.is-critical.is-active{background:#ffe7e2;border-color:#d7877e;color:#922d24}.twmpw-aa-risk-chip.is-critical i{background:#b83a2d}.twmpw-aa-risk-chip.is-high.is-active{background:#fff0dd;border-color:#dfa86e;color:#98570f}.twmpw-aa-risk-chip.is-high i{background:#c46d16}.twmpw-aa-risk-chip.is-watch.is-active{background:#fff5d8;border-color:#d8c06c;color:#80640d}.twmpw-aa-risk-chip.is-watch i{background:#b58c1a}.twmpw-aa-risk-chip.is-stable.is-active{background:#e8f3e9;border-color:#9ec0a7;color:#376847}.twmpw-aa-risk-chip.is-stable i{background:#4f8b63}.twmpw-aa-forecast-risk-filter [data-aa-forecast-risk-all]{border:1px solid #cfaa69;background:#fffaf0;color:#5b3d10;border-radius:999px;padding:6px 9px;font-size:9px;font-weight:850;cursor:pointer}.twmpw-aa-forecast-risk-filter [data-aa-forecast-risk-all]:disabled{opacity:.45;cursor:not-allowed}
.twmpw-aa-forecast-player-row td:first-child{padding:0!important}.twmpw-aa-forecast-player-toggle{width:100%;min-height:60px;border:0;background:transparent;color:inherit;display:grid;grid-template-columns:22px minmax(150px,1fr) minmax(300px,2.2fr);align-items:center;gap:9px;padding:9px 10px;text-align:left;cursor:pointer}.twmpw-aa-forecast-player-toggle>i{display:grid;place-items:center;width:20px;height:20px;border-radius:7px;background:#fff6df;color:#905b0e;font-style:normal;font-size:18px;font-weight:900;transform:rotate(90deg);transition:.15s}.twmpw-aa-forecast-player-row.is-collapsed .twmpw-aa-forecast-player-toggle>i{transform:rotate(0)}.twmpw-aa-forecast-player-toggle>span{display:grid;gap:2px;min-width:0}.twmpw-aa-forecast-player-toggle>span b{font-size:13px;color:#56370c;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.twmpw-aa-forecast-player-toggle>span small{font-size:9px;color:#80613a}.twmpw-aa-forecast-player-toggle>div{display:flex;align-items:center;justify-content:flex-end;gap:5px;flex-wrap:wrap}.twmpw-aa-forecast-player-toggle em,.twmpw-aa-forecast-player-toggle strong{font-style:normal;font-size:8.8px;font-weight:850;padding:4px 7px;border-radius:999px;background:rgba(255,250,240,.7);color:#6f542b;white-space:nowrap}.twmpw-aa-forecast-player-toggle em.is-critical{background:#ffe1db;color:#9b2d22}.twmpw-aa-forecast-player-toggle strong{background:#a96b10;color:#fff8e9}.twmpw-aa-forecast-player-row.is-collapsed{background:#edd4a4!important}.twmpw-aa-forecast-player-row.is-collapsed td{border-bottom:2px solid #c9994b!important}
.twmpw-aa-map-settings .twmpw-aa-switch-row:has([data-aa-defence-forecast-cards]){margin-left:18px;background:rgba(246,233,204,.55)}
@media(max-width:900px){.twmpw-aa-forecast-risk-filter{align-items:flex-start;flex-direction:column}.twmpw-aa-forecast-risk-filter>div{justify-content:flex-start}.twmpw-aa-forecast-player-toggle{grid-template-columns:22px 1fr}.twmpw-aa-forecast-player-toggle>div{grid-column:2;justify-content:flex-start}}


/* World Map Stage 2 V14.21.15 — semantic tactical lens */
.twmpw-wom-lens-settings{display:grid;gap:10px;margin-top:12px;padding:13px;border:1px solid #dfc58d;border-radius:13px;background:#fffaf0}
.twmpw-wom-lens-settings .twmpw-toggle-row{margin:0;background:#fffdf8}
.twmpw-wom-lens-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.twmpw-wom-lens-grid label{display:grid;gap:5px;padding:10px 11px;border:1px solid #e4d0a5;border-radius:10px;background:#fffdf8;color:#5b421d;font-weight:850}
.twmpw-wom-lens-grid select{width:100%;min-height:36px;padding:7px 9px;border:1px solid #cda866;border-radius:8px;background:#fffaf0;color:#4f3510;font-weight:800}
.twmpw-wom-lens-grid small,.twmpw-wom-lens-demo small{display:block;color:#80663b;font-weight:650;line-height:1.35}
.twmpw-wom-lens-demo>span{display:grid;gap:3px;min-width:0}
.twmpw-wom-stage>canvas[data-role="world-overview-canvas"].is-lens{cursor:none!important}
@media(max-width:720px){.twmpw-wom-lens-grid{grid-template-columns:1fr}}


/* World Map Stage 2 V14.21.16 — tribe troops and protected tactical lens panel */
.twmpw-tribe-troops-modal>.twmpw-wom-modal-card{width:min(1180px,96vw);height:min(820px,92vh);max-height:92vh}
.twmpw-tribe-troops-modal header>div{display:flex;flex-direction:column;gap:2px}.twmpw-tribe-troops-modal header small{color:#80633a;font-weight:700}
.twmpw-tribe-troops-modal footer>span{color:#71572f;font-size:12px}.twmpw-tribe-troops-shell{display:flex;flex-direction:column;gap:12px;min-width:0}
.twmpw-tribe-troops-tabs,.twmpw-tribe-troops-mode{display:flex;gap:4px;padding:4px;border:1px solid #d6ba80;border-radius:12px;background:#f2e1ba;width:max-content;max-width:100%}
.twmpw-tribe-troops-tabs button,.twmpw-tribe-troops-mode button{border:0;border-radius:9px;background:transparent;padding:9px 16px;font-weight:900;color:#71572f;white-space:nowrap}
.twmpw-tribe-troops-tabs button.is-active,.twmpw-tribe-troops-mode button.is-active{background:#fffaf0;box-shadow:0 1px 5px rgba(69,43,8,.15);color:#4f3510}
.twmpw-tribe-troops-kpis{display:grid;grid-template-columns:repeat(5,minmax(150px,1fr));gap:8px}.twmpw-tribe-troops-kpis article{border:1px solid #dfc58d;border-radius:12px;background:#fff9ea;padding:11px;min-width:0}.twmpw-tribe-troops-kpis span,.twmpw-tribe-troops-kpis small{display:block;color:#806742}.twmpw-tribe-troops-kpis b{display:block;margin:5px 0;color:#4f3510;font-size:20px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.twmpw-tribe-troops-honesty{border:1px solid #d4b16d;border-left:4px solid #a56a1d;border-radius:11px;background:#fff4d9;padding:10px 12px;color:#5b421d}.twmpw-tribe-troops-honesty p{margin:4px 0 0;line-height:1.42}
.twmpw-tribe-troops-toolbar{display:flex;align-items:end;justify-content:space-between;gap:10px}.twmpw-tribe-troops-toolbar label{display:flex;flex-direction:column;gap:4px;flex:1;max-width:460px}.twmpw-tribe-troops-toolbar input{height:38px;border:1px solid #c8a96e;border-radius:9px;background:#fffdf7;padding:0 11px;color:#4f3510}
.twmpw-tribe-troops-table-wrap{border:1px solid #d8bd86;border-radius:12px;overflow:auto;max-height:430px;background:#fffdf7}.twmpw-tribe-troops-table-wrap table{width:100%;border-collapse:separate;border-spacing:0;table-layout:fixed}.twmpw-tribe-troops-table-wrap th{position:sticky;top:0;z-index:2;background:#ead8ad;color:#4f3510;text-align:left;padding:9px;border-bottom:1px solid #c9ad76}.twmpw-tribe-troops-table-wrap td{padding:8px 9px;border-bottom:1px solid rgba(204,171,105,.35);color:#5b421d;vertical-align:middle}.twmpw-tribe-troops-table-wrap td small{display:block;color:#8a7048;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.twmpw-tribe-troops-table-wrap tbody tr:hover{background:#fff3d8}.twmpw-tribe-troops-empty{text-align:center;padding:28px!important;color:#8a7048!important}.twmpw-tribe-troops-state{display:inline-flex;padding:4px 8px;border-radius:999px;border:1px solid #d5bc86;background:#fff8e8;font-size:11px;font-weight:900}.twmpw-tribe-troops-state.is-external{background:#eaf7ee;border-color:#b9ddc2;color:#2f6b3d}.twmpw-tribe-troops-state.is-away{background:#fff2d7;border-color:#e1c17c;color:#845612}.twmpw-tribe-troops-updated{display:block;margin-top:8px;color:#806742}
.twmpw-tribe-troops-import{display:flex;flex-direction:column;gap:12px}.twmpw-tribe-troops-import-note{display:flex;flex-direction:column;gap:3px;border:1px solid #d8bd86;border-radius:11px;background:#fff8e8;padding:11px}.twmpw-tribe-troops-import-note span{color:#806742}.twmpw-tribe-troops-paste{display:flex;flex-direction:column;gap:6px;font-weight:900;color:#5b421d}.twmpw-tribe-troops-paste textarea{min-height:310px;resize:vertical;border:1px solid #c8a96e;border-radius:11px;background:#fffdf7;padding:12px;font:12px/1.45 ui-monospace,SFMono-Regular,Consolas,monospace;color:#3f2c0e}.twmpw-tribe-troops-format{border:1px dashed #c8a96e;border-radius:11px;padding:10px 12px;color:#5b421d}.twmpw-tribe-troops-format span,.twmpw-tribe-troops-format small{display:block;margin-top:4px;color:#806742}.twmpw-tribe-troops-actions{display:flex;flex-wrap:wrap;gap:8px}.twmpw-tribe-troops-actions .is-danger{color:#9d3525;border-color:#d7a095;background:#fff2ef}
@media(max-width:1050px){.twmpw-tribe-troops-kpis{grid-template-columns:repeat(2,minmax(150px,1fr))}.twmpw-tribe-troops-table-wrap table{min-width:900px}}


/* World Map Stage 2 V14.21.17 — polished troop modal and symmetric tactical cards */
.twmpw-tribe-troops-modal{z-index:10090;padding:20px}
.twmpw-tribe-troops-modal>.twmpw-wom-modal-card{width:min(1220px,calc(100vw - 40px));height:min(850px,calc(100vh - 40px));max-height:none;grid-template-rows:auto minmax(0,1fr) auto;border-radius:16px}
.twmpw-tribe-troops-modal>.twmpw-wom-modal-card>header{min-height:66px;box-sizing:border-box;padding:14px 18px;align-items:center;border-radius:16px 16px 0 0}
.twmpw-tribe-troops-modal>.twmpw-wom-modal-card>header>div:first-child{display:grid;gap:3px;min-width:0}
.twmpw-tribe-troops-modal>.twmpw-wom-modal-card>header b{font-size:17px;line-height:1.2}
.twmpw-tribe-troops-modal>.twmpw-wom-modal-card>header small{font-size:12px;line-height:1.35}
.twmpw-tribe-troops-window-actions{display:grid!important;grid-auto-flow:column;grid-auto-columns:36px;gap:3px;align-items:center;flex:0 0 auto}
.twmpw-tribe-troops-window-actions button{box-sizing:border-box!important;display:grid!important;place-items:center!important;width:36px!important;height:36px!important;min-width:36px!important;min-height:36px!important;margin:0!important;padding:0!important;border:0!important;border-radius:9px!important;background:transparent!important;color:#5b421d!important;line-height:0!important}
.twmpw-tribe-troops-window-actions button:hover{background:rgba(255,250,238,.72)!important}
.twmpw-tribe-troops-window-actions svg{display:block;width:18px;height:18px;fill:none!important;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.twmpw-tribe-troops-window-actions [data-tribe-troops-close] svg{width:17px;height:17px}
.twmpw-tribe-troops-modal>.twmpw-wom-modal-card>main{padding:18px!important;background:#f8f1df;overflow:auto}
.twmpw-tribe-troops-modal>.twmpw-wom-modal-card>footer{min-height:62px;box-sizing:border-box;padding:12px 18px;border-radius:0 0 16px 16px}
.twmpw-tribe-troops-shell{gap:14px}
.twmpw-tribe-troops-tabs,.twmpw-tribe-troops-mode{padding:4px;gap:4px;border-radius:12px}
.twmpw-tribe-troops-kpis{gap:10px}
.twmpw-tribe-troops-kpis article{padding:14px;border-radius:12px}
.twmpw-tribe-troops-toolbar{padding:0 2px;gap:12px}
.twmpw-tribe-troops-table-wrap{border-radius:12px;max-height:none;min-height:180px;flex:1 1 auto}
.twmpw-tribe-troops-overview{display:flex;flex-direction:column;gap:12px;min-height:100%}
.twmpw-tribe-troops-import{gap:14px}
.twmpw-tribe-troops-import-note,.twmpw-tribe-troops-paste textarea,.twmpw-tribe-troops-format{border-radius:12px}
.twmpw-tribe-troops-modal.is-fullscreen{padding:0}
.twmpw-tribe-troops-modal.is-fullscreen>.twmpw-wom-modal-card{width:100vw;height:100vh;max-height:none;border:0;border-radius:0}
.twmpw-tribe-troops-modal.is-fullscreen>.twmpw-wom-modal-card>header,.twmpw-tribe-troops-modal.is-fullscreen>.twmpw-wom-modal-card>footer{border-radius:0}
.twmpw-tribe-troops-modal.is-fullscreen .twmpw-tribe-troops-table-wrap{max-height:none}
@media(max-width:760px){.twmpw-tribe-troops-modal{padding:0}.twmpw-tribe-troops-modal>.twmpw-wom-modal-card{width:100vw;height:100vh;border-radius:0}.twmpw-tribe-troops-modal>.twmpw-wom-modal-card>header,.twmpw-tribe-troops-modal>.twmpw-wom-modal-card>footer{border-radius:0}.twmpw-tribe-troops-modal>.twmpw-wom-modal-card>main{padding:12px!important}.twmpw-tribe-troops-kpis{grid-template-columns:1fr 1fr}}
