@font-face { font-family: "Cinzel"; src: url("fonts/Cinzel.woff2") format("woff2"); font-weight: 400 900; font-display: swap; }
@font-face { font-family: "Garamond"; src: url("fonts/EBGaramond.woff2") format("woff2"); font-weight: 400 800; font-display: swap; }

:root {
  --gold: #c9a74a; --gold2: #f0d68a; --gold-dk: #7a5c1e;
  --wood: #2a1f16; --wood2: #3b2c1f; --leather: #4a3523;
  --parch: #e8d9b5; --parch2: #d9c59a; --ink: #2b1d10; --ink2: #5b4630;
  --red: #a8322a; --green: #3f7a32; --blue: #2c5a8c;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #0e1a24; font-family: "Garamond", Georgia, serif; color: var(--ink); }
#map { position: fixed; inset: 0; width: 100vw; height: 100vh; cursor: grab; display: block; }
#map.drag { cursor: grabbing; }

/* ---------- loading ---------- */
#loading { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center;
  background: radial-gradient(ellipse at center, #3a2b1c 0%, #150e08 75%); }
.ld-box { text-align: center; color: var(--gold2); }
.ld-title { font-family: "Cinzel", serif; font-size: 54px; letter-spacing: .18em; text-shadow: 0 2px 0 #000, 0 0 24px rgba(240,200,110,.25); }
.ld-sub { font-family: "Cinzel", serif; letter-spacing: .3em; color: var(--gold); margin: 6px 0 22px; }
#ld-msg { font-style: italic; color: #d8c79c; margin-bottom: 10px; }
.ld-bar { width: 360px; height: 10px; border: 1px solid var(--gold-dk); background: #1b130c; margin: 0 auto; }
#ld-fill { height: 100%; width: 0; background: linear-gradient(90deg, #8a6420, #e7c36a); transition: width .2s; }

/* ---------- top bar ---------- */
#topbar { position: fixed; top: 0; left: 0; right: 0; height: 58px; z-index: 20; display: flex; align-items: center; gap: 10px;
  background: linear-gradient(#4a3826, #2a1d12 60%, #1d140c); border-bottom: 2px solid var(--gold-dk);
  box-shadow: 0 3px 10px rgba(0,0,0,.6), inset 0 1px 0 rgba(255,220,150,.15); padding: 0 10px 0 6px; color: #f3e5c0; }
.shield { width: 50px; height: 54px; flex: 0 0 auto; margin-top: 8px; cursor: pointer; position: relative;
  clip-path: polygon(0 0, 100% 0, 100% 62%, 50% 100%, 0 62%); background: #3a2c1e center/cover no-repeat;
  box-shadow: inset 0 0 0 2px var(--gold); }
.shield::after { content: ""; position: absolute; inset: 0; background: linear-gradient(135deg, rgba(255,255,255,.35), transparent 40%, rgba(0,0,0,.35)); }
.shield.big { width: 74px; height: 82px; }
.shield.small { width: 22px; height: 25px; margin: 0; display: inline-block; vertical-align: middle; box-shadow: inset 0 0 0 1px var(--gold); }
#tb-res { display: flex; gap: 4px; align-items: center; flex: 1 1 auto; overflow: hidden; }
.res { display: flex; align-items: center; gap: 4px; padding: 4px 7px 4px 4px; border: 1px solid rgba(201,167,74,.35); border-radius: 3px;
  background: linear-gradient(#3a2a1b, #22180f); font-size: 15px; white-space: nowrap; cursor: help; min-width: 0; }
.res svg { width: 20px; height: 20px; flex: 0 0 auto; }
.res .lbl { display: none; }
.res .val { font-weight: 600; line-height: 1.05; color: #fff4d8; }
.res .val.neg { color: #ff8f7a; } .res .val.pos { color: #a8e08a; }
.res.na .val { color: #8f8166; font-weight: 400; font-style: italic; }
.mp { display: flex; gap: 3px; }
.mp span { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 14px; color: #fff;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.25), 0 1px 2px #000; cursor: help; }
.mp .adm { background: radial-gradient(#3f8a3f, #1d4a1d); } .mp .dip { background: radial-gradient(#3f6aa8, #1c3560); } .mp .mil { background: radial-gradient(#b0473a, #5c1d16); }
#tb-right { display: flex; align-items: center; gap: 8px; position: relative; }
#tb-name { font-family: "Cinzel", serif; font-size: 17px; margin-right: 6px; color: var(--gold2); white-space: nowrap; max-width: 220px; overflow: hidden; text-overflow: ellipsis; }
.btn { font-family: "Cinzel", serif; font-size: 13px; color: #f6e6b8; background: linear-gradient(#6a4c2a, #3a2714); border: 1px solid var(--gold);
  padding: 6px 12px; border-radius: 3px; cursor: pointer; box-shadow: inset 0 1px 0 rgba(255,230,160,.3), 0 1px 2px #000; }
.btn:hover { filter: brightness(1.2); }
#tb-date { display: flex; flex-direction: column; align-items: center; padding: 3px 12px; border: 1px solid var(--gold-dk);
  background: linear-gradient(#1a120b, #2e2115); border-radius: 3px; }
#tb-date .date { font-family: "Cinzel", serif; font-size: 14px; color: #fff0c8; }
#tb-date .speed { font-size: 10px; color: var(--gold); letter-spacing: .3em; }
#search { width: 200px; padding: 6px 9px; background: #1a120b; color: #f3e5c0; border: 1px solid var(--gold-dk); border-radius: 3px; font-family: inherit; font-size: 14px; }
#search-res { position: absolute; top: 40px; left: 0; width: 320px; max-height: 60vh; overflow: auto; z-index: 40; }
#search-res div { padding: 6px 10px; background: #2a1d12; color: #f3e5c0; border-bottom: 1px solid #3d2c1c; cursor: pointer; font-size: 14px; }
#search-res div:hover { background: #4a3523; }
#search-res small { color: #b9a678; }

/* ---------- windows (parchment) ---------- */
.window { position: fixed; z-index: 15; color: var(--ink);
  background: linear-gradient(rgba(255,255,255,.08), rgba(0,0,0,.06)), radial-gradient(ellipse at 30% 20%, #efe2c0, #dcc79a 70%, #c9b07c);
  border: 2px solid var(--gold-dk); box-shadow: 0 0 0 1px #000, 0 0 0 4px #3a2a1a, 0 0 0 5px var(--gold), 0 10px 30px rgba(0,0,0,.7); }
#panel { left: 12px; top: 72px; bottom: 12px; width: 430px; display: flex; flex-direction: column; overflow: hidden; }
.hidden { display: none !important; }
.win-head { position: relative; padding: 10px 40px 10px 14px; background: linear-gradient(#5a4029, #2f2114); color: #f8e7bd;
  border-bottom: 2px solid var(--gold); display: flex; gap: 12px; align-items: center; min-height: 78px; }
.win-head h2 { margin: 0; font-family: "Cinzel", serif; font-size: 21px; letter-spacing: .03em; line-height: 1.1; }
.win-head .sub { font-size: 14px; color: #dcc58e; margin-top: 3px; }
.win-head .sub a { color: #f3d98f; }
.x { position: absolute; top: 8px; right: 8px; width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--gold); background: radial-gradient(#8a2a20, #4a120c); color: #fff; cursor: pointer; font-size: 13px; }
.tabs { display: flex; flex-wrap: wrap; gap: 2px; padding: 6px 8px 0; background: #2f2114; border-bottom: 1px solid var(--gold-dk); }
.tabs button { font-family: "Cinzel", serif; font-size: 12px; padding: 6px 9px; background: linear-gradient(#5b4129, #36261a); color: #e9d5a0;
  border: 1px solid var(--gold-dk); border-bottom: none; border-radius: 4px 4px 0 0; cursor: pointer; }
.tabs button.on { background: linear-gradient(#efe2c0, #dcc79a); color: var(--ink); }
.win-body { overflow-y: auto; padding: 12px 14px 18px; flex: 1 1 auto; font-size: 15px; line-height: 1.35; }
.win-body h3 { font-family: "Cinzel", serif; font-size: 14px; letter-spacing: .06em; margin: 14px 0 6px; padding-bottom: 3px; border-bottom: 1px solid rgba(90,60,20,.4); color: #4a2f12; }
.win-body h3:first-child { margin-top: 2px; }
.kv { display: grid; grid-template-columns: 44% 56%; gap: 3px 8px; }
.kv > div:nth-child(odd) { color: var(--ink2); }
.kv > div:nth-child(even) { font-weight: 600; }
.src { font-size: 10.5px; font-weight: 400; color: #7a6040; border: 1px solid rgba(122,96,64,.45); border-radius: 2px; padding: 0 3px; margin-left: 4px; white-space: nowrap; cursor: help; vertical-align: 1px; }
.note { font-size: 12.5px; color: #6b5636; font-style: italic; }
.devbox { display: flex; gap: 8px; margin: 6px 0; }
.devbox > div { flex: 1; text-align: center; padding: 6px 4px; border: 1px solid rgba(90,60,20,.45); background: rgba(255,255,255,.25); border-radius: 3px; }
.devbox .n { font-family: "Cinzel", serif; font-size: 24px; font-weight: 700; }
.devbox .t { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink2); }
.devbox .r { font-size: 11.5px; color: #6b5636; }
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 2px 7px; border-radius: 10px; background: rgba(60,40,20,.12); border: 1px solid rgba(90,60,20,.3); margin: 2px 3px 2px 0; font-size: 13.5px; cursor: default; }
.chip.click { cursor: pointer; } .chip.click:hover { background: rgba(60,40,20,.25); }
.sw { width: 12px; height: 12px; display: inline-block; border: 1px solid rgba(0,0,0,.5); border-radius: 2px; vertical-align: -1px; }
.good-ic { width: 34px; height: 34px; border-radius: 6px; display: grid; place-items: center; font-family: "Cinzel", serif; font-weight: 700; font-size: 12px; color: #fff; text-shadow: 0 1px 2px #000; border: 2px solid rgba(0,0,0,.4); box-shadow: inset 0 0 0 1px rgba(255,255,255,.35); flex: 0 0 auto; }
.row { display: flex; gap: 10px; align-items: center; }
.idea { display: flex; gap: 10px; padding: 7px 6px; border-bottom: 1px dashed rgba(90,60,20,.3); }
.idea .ic { width: 38px; height: 38px; flex: 0 0 auto; border-radius: 4px; display: grid; place-items: center; font-family: "Cinzel", serif; font-weight: 700; color: #f8e7bd; background: radial-gradient(#6a4c2a, #2a1c10); border: 1px solid var(--gold); font-size: 12px; }
.idea .nm { font-family: "Cinzel", serif; font-size: 14px; font-weight: 700; }
.idea .ds { font-size: 13.5px; }
.idea.trad .ic { background: radial-gradient(#3f6a3f, #1c331c); }
.idea.amb .ic { background: radial-gradient(#7a3f8a, #321a3a); }
.bar { height: 8px; background: rgba(0,0,0,.15); border-radius: 4px; overflow: hidden; margin-top: 2px; }
.bar > i { display: block; height: 100%; background: linear-gradient(90deg, #8a6420, #d9b350); }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; }
table.t th { font-family: "Cinzel", serif; font-size: 11.5px; text-align: left; padding: 5px 6px; background: rgba(60,40,20,.18); cursor: pointer; white-space: nowrap; position: sticky; top: 0; background-clip: padding-box; }
table.t th.num, table.t td.num { text-align: right; }
table.t td { padding: 4px 6px; border-bottom: 1px solid rgba(90,60,20,.18); }
table.t tr:hover td { background: rgba(255,255,255,.25); }
table.t tr.click { cursor: pointer; }
a { color: #6a3d10; }

/* ---------- ruler portrait frame ---------- */
.ruler { display: flex; gap: 10px; align-items: center; padding: 8px; border: 1px solid rgba(90,60,20,.4); background: rgba(255,255,255,.2); border-radius: 4px; margin-bottom: 6px; }
.portrait { width: 58px; height: 70px; flex: 0 0 auto; border: 2px solid var(--gold); border-radius: 4px; background: radial-gradient(circle at 50% 35%, #8a7050 0 18%, transparent 19%), radial-gradient(ellipse at 50% 100%, #5a4632 0 45%, transparent 46%), linear-gradient(#2e3d4a, #172029); box-shadow: inset 0 0 8px #000; }
.ruler .nm { font-family: "Cinzel", serif; font-weight: 700; font-size: 15px; }

/* ---------- bottom right ---------- */
#bottomright { position: fixed; right: 12px; bottom: 12px; z-index: 15; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
#minimap { width: 300px; height: 153px; border: 2px solid var(--gold-dk); box-shadow: 0 0 0 1px #000, 0 0 0 3px #3a2a1a, 0 0 0 4px var(--gold), 0 6px 18px rgba(0,0,0,.6); cursor: pointer; background: #0e1a24; }
#mapmodes { display: grid; grid-template-columns: repeat(7, 38px); gap: 5px; padding: 8px; background: linear-gradient(#3b2a1b, #1e150d); border: 1px solid var(--gold); border-radius: 6px; box-shadow: 0 4px 12px rgba(0,0,0,.6); }
#mapmodes button { width: 38px; height: 38px; border-radius: 50%; border: 2px solid var(--gold-dk); cursor: pointer; padding: 0; display: grid; place-items: center;
  background: radial-gradient(circle at 35% 30%, #6d5236, #2a1d12); box-shadow: inset 0 1px 0 rgba(255,230,160,.3), 0 1px 3px #000; }
#mapmodes button svg { width: 22px; height: 22px; }
#mapmodes button.on { border-color: var(--gold2); box-shadow: 0 0 0 2px var(--gold2), 0 0 12px rgba(255,220,120,.6); background: radial-gradient(circle at 35% 30%, #9a7646, #4a3420); }
#mm-name { font-family: "Cinzel", serif; color: var(--gold2); font-size: 14px; text-shadow: 0 1px 2px #000; padding-right: 6px; }
#legend { position: fixed; right: 330px; bottom: 12px; z-index: 14; max-width: 300px; max-height: 40vh; overflow: auto; padding: 8px 10px; font-size: 13px; }
#legend .li { display: flex; align-items: center; gap: 6px; margin: 2px 0; }
#legend h4 { margin: 0 0 6px; font-family: "Cinzel", serif; font-size: 13px; }
.grad { height: 10px; border: 1px solid rgba(0,0,0,.4); margin: 4px 0; }
#zoomhint { position: fixed; left: 50%; bottom: 10px; transform: translateX(-50%); z-index: 10; color: #e8d9b5; font-size: 13px; text-shadow: 0 1px 2px #000; opacity: .8; pointer-events: none; }

/* ---------- tooltip ---------- */
#tooltip { position: fixed; z-index: 50; pointer-events: none; display: none; max-width: 340px; padding: 7px 10px; font-size: 14px; line-height: 1.3;
  color: #f6e7c0; background: rgba(28,20,12,.95); border: 1px solid var(--gold); box-shadow: 0 4px 12px rgba(0,0,0,.6); border-radius: 2px; }
#tooltip b { color: #fff; } #tooltip .tt-h { font-family: "Cinzel", serif; font-size: 15px; color: var(--gold2); }
#tooltip .dim { color: #bfae84; font-size: 12.5px; }

/* ---------- ledger ---------- */
#ledger { position: fixed; inset: 0; z-index: 60; background: rgba(0,0,0,.55); display: grid; place-items: center; }
.ledger-book { width: min(1300px, 96vw); height: min(860px, 92vh); display: flex; flex-direction: column;
  background: linear-gradient(90deg, rgba(0,0,0,.08), transparent 3%, transparent 49.6%, rgba(0,0,0,.18) 50%, transparent 50.4%, transparent 97%, rgba(0,0,0,.08)), radial-gradient(ellipse at center, #f1e4c2, #d8c193 80%);
  border: 3px solid #3a2414; box-shadow: 0 0 0 6px #5a3a1e, 0 0 0 8px var(--gold), 0 20px 60px #000; }
.ledger-head { position: relative; padding: 12px 16px; background: linear-gradient(#5a3a1e, #2f1d0e); color: var(--gold2); border-bottom: 2px solid var(--gold); }
.ledger-title { font-family: "Cinzel", serif; font-size: 24px; letter-spacing: .12em; }
#ledger-tabs { display: flex; flex-wrap: wrap; gap: 3px; padding: 6px 10px; background: #3a2414; }
#ledger-tabs button { font-family: "Cinzel", serif; font-size: 12.5px; padding: 6px 11px; border: 1px solid var(--gold-dk); background: linear-gradient(#6a4a26, #3a2614); color: #f0dca5; cursor: pointer; border-radius: 3px; }
#ledger-tabs button.on { background: linear-gradient(#f1e4c2, #d8c193); color: var(--ink); }
#ledger-body { flex: 1 1 auto; overflow: auto; padding: 10px 18px 20px; font-size: 14.5px; }
#ledger-body h2 { font-family: "Cinzel", serif; font-size: 18px; margin: 8px 0; }
.l-intro { margin: 0 0 10px; color: #5b4630; font-style: italic; }
.src-list li { margin: 4px 0; }
.method { columns: 2; column-gap: 32px; }
.method p, .method li { break-inside: avoid; }
.warcard { border: 1px solid rgba(90,60,20,.4); padding: 8px 10px; margin: 8px 0; background: rgba(255,255,255,.25); border-radius: 3px; }
.warcard .vs { display: flex; gap: 10px; align-items: flex-start; }
.warcard .side { flex: 1; }
.warcard .mid { font-family: "Cinzel", serif; font-weight: 700; color: var(--red); padding-top: 4px; }
.pill { display: inline-block; padding: 0 6px; border-radius: 8px; font-size: 12px; color: #fff; background: #7a5a3a; margin-left: 4px; }
.pill.war { background: #8a2a20; } .pill.minor { background: #a87a2a; }

/* ---------- narrow screens ---------- */
@media (max-width: 760px) {
  #topbar { height: 52px; gap: 6px; }
  #tb-res { display: none; }
  #tb-right { margin-left: auto; gap: 5px; }
  #search { width: 120px; }
  #tb-date { display: none; }
  .btn { padding: 5px 8px; font-size: 12px; }
  #panel { left: 0; right: 0; width: auto; top: 52px; bottom: 0; }
  #minimap { display: none; }
  #mapmodes { grid-template-columns: repeat(7, 32px); gap: 4px; padding: 6px; }
  #mapmodes button { width: 32px; height: 32px; }
  #legend { right: 8px; left: 8px; bottom: 100px; max-height: 30vh; }
  #zoomhint { display: none; }
  .ledger-book { width: 100vw; height: 100vh; }
  .method { columns: 1; }
  #search-res { width: 88vw; left: auto; right: 0; }
}

/* ---------- v2: buildings, estates, institutions ---------- */
.bslots { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; }
.bslot { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 10px; color: #7a6a50; text-align: center; line-height: 1.1; }
.bslot span { width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; font-size: 18px; border: 1px solid #5a4a30;
  background: #2a2016; border-radius: 3px; filter: grayscale(1) opacity(.35); }
.bslot.on { color: #2a1a0a; font-weight: 600; }
.bslot.on span { filter: none; border-color: var(--gold); box-shadow: inset 0 0 6px rgba(0,0,0,.5), 0 0 4px rgba(240,204,85,.4); }
.bslot i { font-style: normal; }
.estate { display: flex; gap: 8px; align-items: flex-start; margin: 6px 0; }
.estate .ic { width: 30px; height: 30px; flex: 0 0 30px; display: flex; align-items: center; justify-content: center; border-radius: 50%;
  background: #5a4a3a; border: 1px solid var(--gold); font-size: 14px; color: #fff; font-weight: 700; }
.cot { color: #f0cc55; font-size: 14px; letter-spacing: -2px; text-shadow: 0 1px 2px #000; }
#legend select, #legend .btn { width: 100%; margin: 2px 0 4px; background: #2a2016; color: #f3e5c0; border: 1px solid var(--gold-dk); padding: 3px; font: inherit; }
#panel .tabs { flex-wrap: wrap; }
#panel .bslot i { color: #6a5a40; }
#panel .bslot.on i { color: #1e140a; font-weight: 700; }
/* ---------- v3: SVG medallion icons, portraits, universities ---------- */
.ico { display: inline-block; vertical-align: middle; flex: 0 0 auto; filter: drop-shadow(0 1px 1px rgba(0,0,0,.35)); }
.bslot span { background: none !important; border: none !important; box-shadow: none !important; width: 36px; height: 36px; }
.bslot:not(.on) span { filter: grayscale(1) opacity(.28) !important; }
.bslot.on span { filter: none !important; }
.estate .ic.ic-svg { background: none; border: none; width: 34px; height: 34px; flex-basis: 34px; }
table.t th .ico { margin-right: 2px; }
.portrait.photo { background-repeat: no-repeat; background-color: #2e3d4a; }
.portrait-credit { font-size: 10.5px; color: #7a6040; }
.uni-row { display: flex; gap: 8px; align-items: center; padding: 4px 0; border-bottom: 1px dashed rgba(90,60,20,.25); }
.uni-rank { min-width: 44px; text-align: center; font-family: "Cinzel", serif; font-weight: 700; font-size: 15px; color: #f8e7bd;
  background: radial-gradient(#6a4c2a, #2a1c10); border: 1px solid var(--gold); border-radius: 4px; padding: 2px 4px; }
.uni-rank.top { background: radial-gradient(#d8b04a, #6a4a10); color: #24160a; }
/* ---------- v4: decluttered chrome, tabs, history, comparison ---------- */
#minimap { width: 240px; height: 122px; }
#mapmodes { grid-template-columns: repeat(11, 34px); gap: 4px; padding: 6px 7px; }
#mapmodes button { width: 34px; height: 34px; }
#mapmodes button svg { width: 20px; height: 20px; }
#mm-more { border-style: dashed !important; }
#mm-wrap { position: relative; }
#mm-pop { position: absolute; right: 0; bottom: calc(100% + 8px); display: grid; grid-template-columns: repeat(4, auto); gap: 4px 14px; padding: 10px 12px; z-index: 30; }
.mmg-h { font-family: "Cinzel", serif; font-size: 12px; letter-spacing: .08em; color: #4a2f12; border-bottom: 1px solid rgba(90,60,20,.4); margin-bottom: 3px; }
#mm-pop button { display: flex; align-items: center; gap: 6px; width: 100%; background: none; border: 0; padding: 3px 4px; cursor: pointer; font: 14px "Garamond", Georgia, serif; color: var(--ink); text-align: left; border-radius: 3px; white-space: nowrap; }
#mm-pop button:hover { background: rgba(90,60,20,.15); } #mm-pop button.on { background: rgba(90,60,20,.28); font-weight: 700; }
#mm-pop .mmi { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 35% 30%, #6d5236, #2a1d12); border: 1px solid var(--gold-dk); flex: 0 0 auto; }
#mm-pop .mmi svg { width: 15px; height: 15px; }
#mm-pop kbd { margin-left: auto; font: 11px system-ui, sans-serif; color: #7a6040; border: 1px solid rgba(90,60,20,.4); border-radius: 3px; padding: 0 4px; }
#mm-foot { display: flex; align-items: center; gap: 10px; }
#mini-toggle { background: none; border: 0; color: #c9b07c; font: 12px "Garamond", Georgia, serif; cursor: pointer; text-shadow: 0 1px 2px #000; padding: 0; }
#mini-toggle:hover { color: var(--gold2); }
#legend { position: static; max-width: 300px; min-width: 200px; max-height: 34vh; padding: 8px 26px 8px 10px; }
#legend.min { padding: 4px 26px 4px 10px; } #legend.min h4 { margin: 0; }
.lg-min { position: absolute; top: 4px; right: 4px; width: 18px; height: 18px; line-height: 14px; padding: 0; border-radius: 50%; border: 1px solid var(--gold-dk); background: #3a2a1b; color: var(--gold2); cursor: pointer; font-size: 13px; }
#legend .li.click { cursor: pointer; border-radius: 3px; padding: 1px 3px; } #legend .li.click:hover { background: rgba(90,60,20,.15); }
.hl-top { margin: 6px 0 4px; } .hl-r { width: 16px; text-align: right; color: #7a6040; font-size: 12px; }
#zoomhint { transition: opacity 1.2s; }
/* timeline */
#timeline { left: 50%; transform: translateX(-50%); bottom: 14px; width: min(560px, 60vw); padding: 8px 12px 6px; z-index: 16; }
#timeline select { width: 100%; background: #2a2016; color: #f3e5c0; border: 1px solid var(--gold-dk); padding: 3px; font: 14px "Garamond", Georgia, serif; }
.tl-row { display: flex; align-items: center; gap: 10px; margin-top: 6px; }
#tl-play { width: 40px; padding: 4px 0; font-size: 14px; }
#tl-year { flex: 1; accent-color: #8a6420; }
#tl-ylabel { font-family: "Cinzel", serif; font-size: 26px; font-weight: 700; min-width: 70px; text-align: right; color: #3a2410; }
.tl-foot { font-size: 11.5px; color: #6b5636; font-style: italic; text-align: center; }
/* banner (compare picking) */
#banner { position: fixed; top: 66px; left: 50%; transform: translateX(-50%); z-index: 25; padding: 7px 12px; background: rgba(28,20,12,.95); color: #f6e7c0; border: 1px solid var(--gold); border-radius: 3px; box-shadow: 0 4px 14px rgba(0,0,0,.6); font-size: 15px; display: flex; align-items: center; gap: 8px; }
#map.picking { cursor: crosshair; }
.btn.mini { font-size: 11px; padding: 3px 8px; }
.win-head .btn.mini { margin-left: 8px; vertical-align: 1px; }
/* province window */
.dimsub { color: #c9b483 !important; font-size: 13px !important; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin: 8px 0 2px; }
.fact { border: 1px solid rgba(90,60,20,.3); background: rgba(255,255,255,.18); border-radius: 3px; padding: 4px 6px; min-width: 0; }
.fact[data-ptab] { cursor: pointer; } .fact[data-ptab]:hover { background: rgba(255,255,255,.35); }
.fact .fl { font-size: 10.5px; text-transform: uppercase; letter-spacing: .06em; color: #7a6040; }
.fact .fv { font-weight: 600; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: flex; align-items: center; gap: 4px; }
.good-ic.tiny { width: 18px; height: 18px; font-size: 7.5px; border-width: 1px; border-radius: 3px; }
.sec { margin: 6px 0 8px; }
.more-btn { display: inline-block; font-size: 12.5px; color: #6a3d10; cursor: pointer; text-decoration: underline dotted; margin: 2px 4px; }
.rest { display: contents; } .rest.hidden { display: none !important; }
.devbox .r { white-space: nowrap; }
/* history sparks + charts */
.sparks { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.spark { border: 1px solid rgba(90,60,20,.3); background: rgba(255,255,255,.18); border-radius: 3px; padding: 4px 6px; cursor: pointer; }
.spark:hover { background: rgba(255,255,255,.35); }
.spark .sl { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: #7a6040; }
.spark .sv { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spk { width: 100%; height: 30px; display: block; } .spk path { fill: none; stroke: #7a3a14; stroke-width: 1.6; vector-effect: non-scaling-stroke; }
.chart { width: 100%; height: auto; display: block; background: rgba(255,255,255,.22); border: 1px solid rgba(90,60,20,.3); border-radius: 3px; margin: 6px 0; }
.chart .cg { stroke: rgba(90,60,20,.18); stroke-width: 1; vector-effect: non-scaling-stroke; }
.chart .ct { font: 11px "Garamond", Georgia, serif; fill: #6b5636; }
.chart .cl { fill: none; stroke-width: 2.4; vector-effect: non-scaling-stroke; stroke-linejoin: round; } .chart .cl.thin { stroke-width: 1.2; }
.chart .ch-x { stroke: rgba(40,20,0,.55); stroke-width: 1; vector-effect: non-scaling-stroke; stroke-dasharray: 3 3; }
.hg-controls { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.hg-controls select { background: #2a2016; color: #f3e5c0; border: 1px solid var(--gold-dk); padding: 4px; font: 14px "Garamond", Georgia, serif; max-width: 360px; }
.hg-chk { font-size: 14px; display: flex; gap: 4px; align-items: center; }
.hg-chips { margin: 6px 0; } .hg-rm { text-decoration: none; color: #8a2a20; font-size: 11px; margin-left: 2px; }
/* ledger groups */
#ledger-tabs { flex-direction: column; gap: 0; padding: 0; }
.lg-groups { display: flex; gap: 3px; padding: 6px 10px 0; background: #3a2414; }
.lg-groups button { font-family: "Cinzel", serif; font-size: 13.5px; padding: 7px 14px; border: 1px solid var(--gold-dk); border-bottom: none; background: linear-gradient(#6a4a26, #3a2614); color: #f0dca5; cursor: pointer; border-radius: 4px 4px 0 0; }
.lg-groups button.on { background: linear-gradient(#8a6436, #5a3c1c); color: #fff3cf; }
.lg-sub { display: flex; gap: 3px; flex-wrap: wrap; padding: 6px 10px; background: #5a3c1c; border-top: 1px solid var(--gold-dk); }
.lg-sub button { font-family: "Cinzel", serif; font-size: 12px; padding: 5px 10px; border: 1px solid var(--gold-dk); background: linear-gradient(#6a4a26, #3a2614); color: #f0dca5; cursor: pointer; border-radius: 3px; }
.lg-sub button.on { background: linear-gradient(#f1e4c2, #d8c193); color: var(--ink); }
/* comparison */
#panel.wide { width: 640px; }
.cmp-t { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; } .cmp-t.r { justify-content: flex-end; text-align: right; }
.cmp-t h2 { font-size: 18px !important; } .cmp-vs { font-family: "Cinzel", serif; font-size: 22px; color: var(--gold2); text-shadow: 0 2px 2px #000; }
.cmp-rel { display: flex; flex-wrap: wrap; gap: 2px; margin-bottom: 6px; }
.cmp-tools { display: flex; gap: 6px; margin: 4px 0 8px; }
.cmp-sec { font-family: "Cinzel", serif; font-size: 13px; letter-spacing: .06em; color: #4a2f12; border-bottom: 1px solid rgba(90,60,20,.4); margin: 10px 0 3px; }
.cmp-row { display: grid; grid-template-columns: 92px 1fr 150px 1fr 92px; align-items: center; gap: 6px; padding: 2px 0; font-size: 13.5px; }
.cmp-row:hover { background: rgba(255,255,255,.22); }
.cmp-row .cl { text-align: center; color: var(--ink2); font-size: 12.5px; line-height: 1.1; }
.cmp-row .cv { text-align: right; white-space: nowrap; } .cmp-row .cv.r { text-align: left; } .cmp-row .cv.win { font-weight: 700; color: #1e4a14; }
.cb { height: 9px; background: rgba(0,0,0,.08); border-radius: 4px; overflow: hidden; display: flex; } .cb.l { justify-content: flex-end; }
.cb.l i { background: linear-gradient(90deg, #e08a7a, #c0392b); } .cb.r i { background: linear-gradient(90deg, #2c6fbb, #7aaee0); } .cb i { display: block; height: 100%; }
#cmp-ind { width: 100%; background: #2a2016; color: #f3e5c0; border: 1px solid var(--gold-dk); padding: 3px; font: 14px "Garamond", Georgia, serif; }
@media (max-width: 760px) {
  #mapmodes { grid-template-columns: repeat(11, 28px); gap: 3px; } #mapmodes button { width: 28px; height: 28px; }
  #mm-pop { grid-template-columns: repeat(2, auto); }
  #timeline { width: 94vw; bottom: 64px; } #panel.wide { width: auto; }
  .cmp-row { grid-template-columns: 70px 1fr 100px 1fr 70px; }
  #legend { max-width: 70vw; }
}
.cmp-t a { display: block; line-height: 0; } .cmp-t .shield { display: block; margin-top: 0; }
.chart { background: rgba(250,244,228,.92); }
/* ---------- v5: start dates ---------- */
#tb-date { cursor: pointer; } #tb-date:hover { filter: brightness(1.25); }
#tb-date.past { border-color: #d8a040; box-shadow: 0 0 8px rgba(240,190,80,.45); } #tb-date.past .date { color: #ffd98a; }
#start-menu { position: absolute; top: 46px; right: 0; z-index: 45; padding: 6px; min-width: 210px; }
#start-menu .sm-h { font-family: "Cinzel", serif; font-size: 13px; color: #4a2f12; border-bottom: 1px solid rgba(90,60,20,.4); margin: 0 4px 4px; }
#start-menu button { display: block; width: 100%; text-align: left; background: none; border: 0; padding: 5px 8px; font: 15px "Garamond", Georgia, serif; color: var(--ink); cursor: pointer; border-radius: 3px; }
#start-menu button:hover { background: rgba(90,60,20,.15); } #start-menu button.on { background: rgba(90,60,20,.28); font-weight: 700; }
.past-note { font-size: 12.5px; font-style: italic; color: #5a3a10; background: rgba(240,200,110,.25); border: 1px solid rgba(160,110,30,.45); border-radius: 3px; padding: 4px 7px; margin-bottom: 6px; }
#paper { position: fixed; left: 0; right: 0; top: 58px; bottom: 0; pointer-events: none; background: url("data/paper.jpg") repeat; mix-blend-mode: multiply; opacity: .6; z-index: 1; }
/* ---------- v6: speed + phones ---------- */
#map { touch-action: none; }
html, body { overscroll-behavior: none; -webkit-tap-highlight-color: transparent; }
#refine { position: fixed; left: 12px; bottom: 12px; z-index: 12; font: italic 13px "Garamond", Georgia, serif; color: #e8d9b5; text-shadow: 0 1px 2px #000; opacity: 0; transition: opacity .6s; pointer-events: none; }
@media (max-width: 760px) {
  #topbar { height: calc(52px + env(safe-area-inset-top)); padding-top: env(safe-area-inset-top); }
  #tb-flag { width: 38px; height: 42px; margin-top: 4px; }
  #tb-right { gap: 4px; }
  #search { width: 92px; font-size: 13px; padding: 5px 6px; }
  #tb-date { display: flex !important; padding: 2px 6px; } #tb-date .date { font-size: 11px; } #tb-date .speed { display: none; }
  #start-menu { position: fixed; top: 56px; right: 6px; }
  #btn-sources { display: none; }
  /* province / nation window = bottom sheet over the map */
  #panel { left: 0 !important; right: 0; width: auto !important; top: auto; bottom: 0; height: 56vh; border-radius: 12px 12px 0 0; padding-bottom: env(safe-area-inset-bottom); transition: height .25s; }
  #panel.full { height: calc(100vh - 56px); }
  #panel::before { content: ""; display: block; flex: 0 0 auto; width: 46px; height: 5px; border-radius: 3px; background: var(--gold); margin: 5px auto 3px; opacity: .9; }
  #panel .win-head { min-height: 58px; padding: 6px 38px 6px 10px; cursor: pointer; } #panel .win-head h2 { font-size: 17px; }
  #panel .shield.big { width: 46px; height: 52px; }
  .win-body { font-size: 14.5px; padding: 8px 10px 16px; }
  .tabs button { font-size: 11px; padding: 5px 7px; }
  .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); } .fact .fv { font-size: 12.5px; }
  .bslots { grid-template-columns: repeat(4, 1fr); }
  #bottomright { right: 6px; bottom: calc(6px + env(safe-area-inset-bottom)); gap: 4px; }
  #mapmodes { grid-template-columns: repeat(11, 26px); gap: 3px; padding: 5px; }
  #mapmodes button { width: 26px; height: 26px; } #mapmodes button svg { width: 16px; height: 16px; }
  #mm-pop { grid-template-columns: repeat(2, auto); max-height: 62vh; overflow: auto; right: -2px; }
  #mm-foot { display: none; }
  #legend { max-width: 76vw; min-width: 0; max-height: 30vh; font-size: 12px; }
  #timeline { top: calc(58px + env(safe-area-inset-top)); bottom: auto; width: 96vw; padding: 5px 8px; }
  #tl-ylabel { font-size: 20px; min-width: 54px; }
  #banner { top: 58px; width: 94vw; font-size: 13px; flex-wrap: wrap; }
  .ledger-book { width: 100vw; height: 100dvh; }
  .lg-groups button { font-size: 11.5px; padding: 6px 8px; } .lg-sub button { font-size: 11px; padding: 4px 7px; }
  #ledger-body { padding: 8px; font-size: 13.5px; } table.t { font-size: 12.5px; }
  #panel.wide { width: auto !important; }
  .cmp-row { grid-template-columns: 64px 1fr 92px 1fr 64px; font-size: 12px; gap: 4px; } .cmp-t h2 { font-size: 14px !important; } .cmp-vs { font-size: 16px; }
  .sparks { grid-template-columns: 1fr 1fr; }
  #refine { bottom: auto; top: calc(60px + env(safe-area-inset-top)); left: 8px; }
}
@media (max-width: 760px) { #mm-pop { position: fixed; left: 6px; right: 6px; bottom: calc(58px + env(safe-area-inset-bottom)); grid-template-columns: 1fr 1fr; gap: 2px 8px; } #mm-pop button { font-size: 13px; white-space: normal; } }
/* ---------- v7: icon tabs, top-bar cards, past rulers, finder, outliner, share ---------- */
.tabs.itabs { flex-wrap: nowrap; gap: 3px; padding: 6px 6px 0; }
.tabs.itabs button { flex: 1 1 0; display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 4px 2px 3px; min-width: 0; }
.tabs.itabs button i { font-style: normal; font-size: 10.5px; letter-spacing: .02em; }
.tabs.itabs button .ico { filter: none; }
.tab-sep { height: 1px; background: rgba(90,60,20,.3); margin: 14px 0 4px; }
.pin { background: none; border: 0; color: var(--gold2); font-size: 16px; cursor: pointer; padding: 0 2px; vertical-align: -1px; }
#tb-res .res { cursor: default; }
.tbc-spark { width: 220px; margin: 4px 0 1px; } .tbc-spark .spk path { stroke: #f0cc55; }
.btn.icon { padding: 5px 7px; line-height: 0; }
.prs .pr { display: flex; gap: 8px; align-items: center; padding: 3px 0; border-bottom: 1px dashed rgba(90,60,20,.22); }
.pp { width: 40px; height: 48px; flex: 0 0 auto; border: 1px solid var(--gold); border-radius: 3px; background-color: #2e3d4a; background-repeat: no-repeat; display: block; }
.pp.none { background: radial-gradient(circle at 50% 35%, #8a7050 0 18%, transparent 19%), radial-gradient(ellipse at 50% 100%, #5a4632 0 45%, transparent 46%), linear-gradient(#2e3d4a, #172029); }
.pr-credits { margin-top: 4px; font-size: 12px; } .pr-credits summary { cursor: pointer; color: #6a3d10; }
.prod { font-size: 13px; padding: 2px 0; display: flex; gap: 6px; } .prod b { margin-left: auto; white-space: nowrap; }
#outliner, #finder { right: 12px; top: 70px; width: 250px; max-height: calc(100vh - 380px); display: flex; flex-direction: column; overflow: hidden; z-index: 14; }
#finder { width: 340px; max-height: calc(100vh - 90px); z-index: 16; }
.ol-head, .fd-head { display: flex; justify-content: space-between; align-items: center; padding: 5px 10px; background: linear-gradient(#5a4029, #2f2114); color: #f8e7bd; font-family: "Cinzel", serif; font-size: 13px; cursor: pointer; position: relative; }
.fd-head { cursor: default; padding-right: 40px; } .fd-head .x { top: 3px; right: 6px; width: 22px; height: 22px; font-size: 11px; }
.ol-body, .fd-body { overflow-y: auto; padding: 4px 8px 8px; font-size: 13.5px; }
.ol-sec { font-family: "Cinzel", serif; font-size: 11.5px; letter-spacing: .06em; color: #4a2f12; border-bottom: 1px solid rgba(90,60,20,.35); margin: 7px 0 2px; }
.ol-i { display: flex; align-items: center; gap: 5px; padding: 2px 3px; cursor: pointer; border-radius: 3px; white-space: nowrap; overflow: hidden; }
.ol-i:hover { background: rgba(90,60,20,.15); } .ol-v { margin-left: auto; font-weight: 700; } .ol-t { overflow: hidden; text-overflow: ellipsis; }
.ol-note { padding: 2px 3px; }
.fd-presets { display: flex; flex-wrap: wrap; gap: 2px; margin: 2px 0 6px; } .fd-presets .chip { font-size: 12px; }
.fd-row { display: grid; grid-template-columns: 1fr 62px 90px 22px; gap: 3px; margin: 3px 0; }
.fd-row select, .fd-row input { min-width: 0; background: #2a2016; color: #f3e5c0; border: 1px solid var(--gold-dk); padding: 3px; font: 13px "Garamond", Georgia, serif; }
.x-sm { background: none; border: 0; color: #8a2a20; cursor: pointer; }
.fd-count { margin: 8px 0 4px; font-size: 13.5px; }
.fd-list { border-top: 1px solid rgba(90,60,20,.3); }
.fd-item { display: flex; gap: 5px; align-items: center; padding: 2px 3px; cursor: pointer; font-size: 13.5px; border-radius: 3px; } .fd-item:hover { background: rgba(90,60,20,.15); }
.fd-item span:first-of-type { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .fd-item b { margin-left: auto; }
#share-box { top: 66px; right: 12px; width: min(460px, 94vw); padding: 8px 10px; z-index: 46; font-size: 14px; }
#share-url { width: 100%; margin-top: 4px; padding: 4px; font: 12px ui-monospace, monospace; background: #fff8e8; border: 1px solid var(--gold-dk); }
@media (max-width: 760px) {
  #outliner { top: calc(60px + env(safe-area-inset-top)); right: 6px; width: auto; max-width: 70vw; max-height: 40vh; }
  #finder { left: 6px; right: 6px; width: auto; top: calc(58px + env(safe-area-inset-top)); max-height: 60vh; }
  .tabs.itabs button i { font-size: 9.5px; }
  .btn.icon { padding: 4px 5px; }
}
/* ---------- v8b: nothing in a window may be squeezed ---------- */
/* window headers / tab rows are fixed-size rows of a column flexbox: they must never shrink when the body is long */
#panel > .win-head, #panel > .tabs, .ledger-head, #ledger-tabs, .ol-head, .fd-head, #panel::before { flex: 0 0 auto; }
.win-head { min-height: 78px; align-items: center; }
.win-head > div { min-width: 0; }
.win-head h2 { overflow-wrap: anywhere; }
.win-head .sub { line-height: 1.25; }
.win-head .sub.dimsub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fact .fv { white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.15; align-items: flex-start; }
.fact .fv .good-ic.tiny { margin-top: 1px; }
.devbox .r { white-space: normal; }
#tb-name { max-width: 260px; }
.win-head .sub.dimsub { white-space: normal; overflow: visible; }
.ol-i { white-space: normal; } .ol-t { overflow: visible; }
#tb-name { white-space: normal; line-height: 1.05; font-size: 15px; max-width: 160px; overflow: visible; }
#ledger-tabs { min-width: 0; max-width: 100%; }
.lg-groups { flex-wrap: wrap; row-gap: 3px; }
@media (max-width: 760px) { .lg-groups { padding: 5px 6px 0; } .lg-groups button { border-radius: 4px; border-bottom: 1px solid var(--gold-dk); } .lg-sub { padding: 5px 6px; } }
/* ---------- v9: Centers of Trade ---------- */
.cot-badge { display: inline-flex; align-items: center; gap: 4px; font: 600 12.5px "Cinzel", serif; letter-spacing: .03em; vertical-align: 3px; padding: 1px 8px 1px 3px; border-radius: 10px; border: 1px solid; margin-left: 6px; white-space: nowrap; }
.cot-badge.l3 { color: #2a1806; background: linear-gradient(#f6dc7a, #c9a43a); border-color: #7a5a12; }
.cot-badge.l2 { color: #1e2228; background: linear-gradient(#eef0f4, #aab0b8); border-color: #5a6068; }
.cot-badge.l1 { color: #2a1406; background: linear-gradient(#e8b48a, #b0703a); border-color: #6a3a14; }
.cot-card { display: flex; gap: 10px; align-items: flex-start; padding: 8px; border-radius: 4px; border: 1px solid rgba(90,60,20,.35); background: rgba(255,255,255,.2); }
.cot-card.l3 { background: linear-gradient(90deg, rgba(240,204,85,.3), rgba(255,255,255,.15)); border-color: #c9a74a; }
.cot-card .kv { margin-top: 3px; } .cot-t { font-family: "Cinzel", serif; font-weight: 700; font-size: 14px; }

/* ---------- v9b: show-on-map toggles ---------- */
#show-toggles { display: inline-flex; gap: 3px; margin-right: 6px; }
#show-toggles button { width: 26px; height: 26px; padding: 0; border-radius: 50%; border: 1px solid var(--gold-dk); background: #2a1d12; cursor: pointer; display: grid; place-items: center; opacity: .45; filter: grayscale(.8); }
#show-toggles button.on { opacity: 1; filter: none; border-color: var(--gold2); }

/* ---------- v10: search results, help card ---------- */
#search-res div { display: flex; align-items: center; gap: 6px; }
#search-res div.sel { background: #5a3f28; box-shadow: inset 3px 0 0 var(--gold2); }
#search-res .sr-l { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#search-res small { flex: 0 0 auto; font-size: 12px; }
#search-res .sr-none { color: #b9a678; cursor: default; font-style: italic; }
#search-res .shield.small { flex: 0 0 auto; }
#help { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 80; width: min(640px, 94vw); max-height: 86vh; display: flex; flex-direction: column;
  background: #2a1d12; color: #f3e5c0; border: 2px solid var(--gold-dk); border-radius: 6px; box-shadow: 0 10px 40px rgba(0,0,0,.6); }
#help.hidden { display: none; }
#help .help-head { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px; border-bottom: 1px solid var(--gold-dk); flex: 0 0 auto; font-family: Cinzel, serif; }
#help .help-body { overflow: auto; padding: 8px 14px 12px; font-size: 14px; }
#help .help-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
#help h4 { margin: 10px 0 4px; color: var(--gold2); font-family: Cinzel, serif; font-size: 13px; }
#help .help-mm { columns: 2; column-gap: 10px; } #help .help-mm div { break-inside: avoid; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#help kbd { display: inline-block; min-width: 18px; padding: 0 4px; margin-right: 3px; border: 1px solid var(--gold-dk); border-radius: 3px; background: #1a1209; font: 600 12px/18px Garamond, Georgia, serif; text-align: center; }
#help .note { margin-top: 10px; }
#btn-help { min-width: 30px; padding-left: 8px; padding-right: 8px; }
@media (max-width: 760px) { #help .help-cols { grid-template-columns: 1fr; } #btn-help { display: none; } }

.mh { margin: 14px 0 6px; padding-bottom: 3px; border-bottom: 1px solid rgba(160,120,60,.45); font-family: Cinzel, serif; font-size: 15px; color: #6b3a14; }
#search-res { width: min(420px, 92vw); }
#search-res .sr-l { white-space: normal; line-height: 1.2; }
#help .note { color: #cdb98a; }

/* ---------- v11: phone polish ---------- */
@media (max-width: 760px) {
  .win-body { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }      /* clear the map-mode bar */
  #tb-date { max-width: 74px; } #tb-date .date { font-size: 10.5px; line-height: 1.15; text-align: center; }
}
#tb-res .res { flex: 0 0 auto; }
#tb-name { flex: 0 0 auto; }
#tb-res.compact { gap: 3px; } #tb-res.compact .res { padding: 3px 5px 3px 3px; font-size: 14px; gap: 3px; } #tb-res.compact .res svg { width: 17px; height: 17px; }
#tb-more { cursor: pointer; color: #f2cf5a; font: 600 14px/1 Garamond, Georgia, serif; padding: 6px 8px; }
#tb-more:hover { filter: brightness(1.3); }
.tb-more-list { min-width: 200px; } .tb-more-list > div:not(.note) { display: flex; justify-content: space-between; gap: 16px; padding: 2px 0; }
@media (max-width: 1500px) and (min-width: 761px) { #search { width: 150px; } #tb-name { max-width: 140px; font-size: 14px; } #tb-right { gap: 6px; } }
