/* Batumi Estate Tycoon — тёплый яркий мульт-стиль: толстые контуры, «конфетные» кнопки, солнечная палитра */
:root {
  --ink: #4a263a;
  --ink-soft: #7a5566;
  --bg: #ffe8c2;
  --card: #fffaf0;
  --card-2: #fff3dc;
  --sun: #ffc53d;
  --orange: #ff8a3d;
  --coral: #ff6b4a;
  --pink: #ff7eb6;
  --teal: #22c3b5;
  --sea: #3ec9dc;
  --green: #4cc35a;
  --green-dark: #2f9e44;
  --red: #e8453c;
  --purple: #8a6cff;
  --radius: 16px;
  --shadow: 0 4px 0 var(--ink);
  --font: 'Rubik', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  background-image:
    radial-gradient(circle at 20% 10%, rgba(255, 197, 61, 0.35) 0, transparent 40%),
    radial-gradient(circle at 90% 90%, rgba(255, 126, 182, 0.25) 0, transparent 40%);
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
button { font-family: inherit; color: inherit; }
[hidden] { display: none !important; }

#app { display: flex; flex-direction: column; height: 100vh; height: 100dvh; }

/* ---------- HUD ---------- */
.hud {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  background: linear-gradient(180deg, #ffb35c, #ff9a4d);
  border-bottom: 3px solid var(--ink);
  box-shadow: 0 3px 0 rgba(74, 38, 58, 0.25);
  z-index: 5; flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: 8px; margin-right: 6px; }
.brand-logo {
  width: 44px; height: 44px; display: grid; place-items: center; font-size: 26px;
  background: var(--sun); border: 3px solid var(--ink); border-radius: 14px; box-shadow: var(--shadow);
  transform: rotate(-6deg);
}
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-text b { font-size: 20px; font-weight: 900; color: #fff; -webkit-text-stroke: 1.2px var(--ink); paint-order: stroke fill; letter-spacing: 0.5px; }
.brand-text span { font-size: 11px; font-weight: 800; color: var(--ink); text-transform: uppercase; letter-spacing: 1.5px; }

.pill {
  position: relative; display: flex; align-items: center; gap: 8px; padding: 5px 12px 5px 6px;
  background: var(--card); border: 3px solid var(--ink); border-radius: 999px; box-shadow: var(--shadow);
  min-height: 46px;
}
.pill-ico { width: 32px; height: 32px; display: grid; place-items: center; font-size: 20px; background: var(--card-2); border-radius: 50%; border: 2px solid var(--ink); }
.pill-body { display: flex; flex-direction: column; line-height: 1.1; }
.pill-body b { font-size: 17px; font-weight: 800; font-variant-numeric: tabular-nums; }
.pill-body small { font-size: 11px; color: var(--ink-soft); font-weight: 600; }
.pill-cash .pill-ico { background: #d8f5c8; }
.pill-gems .pill-ico { background: #ffd9e8; }
.pill-plus {
  width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--ink); background: var(--green); color: #fff;
  font-weight: 900; font-size: 17px; line-height: 1; cursor: pointer; box-shadow: 0 2px 0 var(--ink); padding: 0;
}
.pill-plus:active { transform: translateY(2px); box-shadow: none; }
.income-up { color: var(--green-dark) !important; }
.income-down { color: var(--red) !important; }
.pill-date .pill-body { padding-bottom: 6px; }
.day-bar { position: absolute; left: 46px; right: 14px; bottom: 4px; height: 4px; background: #f1dfc0; border-radius: 4px; overflow: hidden; }
.day-bar i { display: block; height: 100%; width: 0; background: var(--orange); border-radius: 4px; }

.speed { display: flex; gap: 4px; background: var(--card); border: 3px solid var(--ink); border-radius: 14px; padding: 4px; box-shadow: var(--shadow); }
.speed button {
  width: 36px; height: 32px; border: 2px solid transparent; border-radius: 10px; background: transparent; cursor: pointer; font-size: 15px;
}
.speed button:hover { background: var(--card-2); }
.speed button.on { background: var(--sun); border-color: var(--ink); }
.speed button.locked { opacity: 0.45; }

.pill-level { margin-left: auto; padding-right: 16px; min-width: 210px; }
.lvl-badge {
  width: 36px; height: 36px; display: grid; place-items: center; font-weight: 900; font-size: 18px; color: #fff;
  background: var(--purple); border: 3px solid var(--ink); border-radius: 12px; transform: rotate(-4deg);
}
.xp { height: 8px; background: #f1dfc0; border: 2px solid var(--ink); border-radius: 6px; overflow: hidden; margin: 3px 0 2px; }
.xp i { display: block; height: 100%; background: linear-gradient(90deg, var(--sun), var(--orange)); width: 0; transition: width 0.5s; }

/* ---------- Layout ---------- */
.main { flex: 1; display: flex; min-height: 0; }
.map-wrap { position: relative; flex: 1; min-width: 0; overflow: hidden; border-right: 3px solid var(--ink); }
#city { display: block; width: 100%; height: 100%; cursor: grab; touch-action: none; }
.map-tools { position: absolute; top: 12px; left: 12px; display: flex; flex-direction: column; gap: 6px; }
.map-tools button {
  width: 40px; height: 40px; border-radius: 12px; border: 3px solid var(--ink); background: var(--card);
  box-shadow: 0 3px 0 var(--ink); font-size: 18px; font-weight: 900; cursor: pointer;
}
.map-tools button:active { transform: translateY(3px); box-shadow: none; }
.map-hint {
  position: absolute; bottom: 10px; left: 12px; font-size: 11px; font-weight: 600; color: var(--ink);
  background: rgba(255, 250, 240, 0.8); padding: 4px 10px; border-radius: 99px; border: 2px solid rgba(74, 38, 58, 0.3);
}
.modifiers { position: absolute; top: 12px; right: 12px; display: flex; flex-direction: column; gap: 6px; align-items: flex-end; max-width: 260px; }
.modifiers .mod {
  font-size: 11px; font-weight: 700; background: var(--card); border: 2px solid var(--ink); border-radius: 10px; padding: 4px 9px;
  box-shadow: 0 2px 0 var(--ink);
}

.map-actions { position: absolute; right: 14px; bottom: 14px; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; max-width: calc(100% - 28px); }
.gig-btn, .collect-btn {
  position: relative; display: flex; align-items: center; gap: 10px; text-align: left;
  padding: 8px 16px 8px 8px; border: 3px solid var(--ink); border-radius: 18px; background: var(--card);
  box-shadow: 0 4px 0 var(--ink); cursor: pointer; max-width: 100%; font-family: inherit; color: inherit;
}
.collect-btn { background: linear-gradient(180deg, #b6f5a8, var(--green)); }
.collect-btn b { color: #fff; text-shadow: 0 1px 0 rgba(0,0,0,.35); }
.collect-btn small { color: #fff !important; opacity: .9; }
.collect-btn.full { background: linear-gradient(180deg, #ffb4a2, var(--coral)); animation: pulse 1s ease-in-out infinite; }
.collect-btn:active { transform: translateY(4px); box-shadow: none; }
.gig-btn b, .collect-btn b { display: block; font-size: 15px; font-weight: 900; }
.gig-btn small, .collect-btn small { display: block; font-size: 11.5px; font-weight: 600; color: var(--ink-soft); }
.gig-emoji { width: 40px; height: 40px; flex: none; display: grid; place-items: center; font-size: 22px; border-radius: 12px; border: 2px solid var(--ink); background: var(--card-2); }
.gig-btn.ready { background: linear-gradient(180deg, #ffe08a, var(--sun)); animation: pulse 1.4s ease-in-out infinite; }
.gig-btn.ready .gig-emoji { background: #fff; }
.gig-btn:active:not(:disabled) { transform: translateY(4px); box-shadow: none; animation: none; }
.gig-btn:disabled { cursor: default; opacity: 0.85; }

.district-card {
  position: absolute; left: 64px; top: 12px; width: 300px; max-width: calc(100% - 80px);
  background: var(--card); border: 3px solid var(--ink); border-radius: var(--radius); box-shadow: 0 5px 0 var(--ink);
  padding: 14px; animation: pop 0.25s cubic-bezier(.2, 1.6, .5, 1);
}
.district-card h3 { margin: 0 0 4px; font-size: 20px; font-weight: 900; }
.district-card p { margin: 0 0 10px; font-size: 13px; color: var(--ink-soft); line-height: 1.4; }
.district-card .close { position: absolute; right: 8px; top: 8px; }

.panel { width: 460px; display: flex; flex-direction: column; min-height: 0; background: var(--card-2); }
.tabs { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; padding: 8px; border-bottom: 3px solid var(--ink); background: #ffd79a; }
.tabs button {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 6px 2px 5px;
  font-size: 10.5px; font-weight: 700; background: var(--card); border: 2px solid var(--ink); border-radius: 12px; cursor: pointer;
  box-shadow: 0 3px 0 var(--ink);
}
.tabs button span { font-size: 19px; line-height: 1.1; }
.tabs button.on { background: var(--sun); transform: translateY(2px); box-shadow: 0 1px 0 var(--ink); }
.badge {
  position: absolute; top: -7px; right: -5px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: var(--coral);
  color: #fff; font-size: 11px; font-style: normal; font-weight: 800; line-height: 16px; border: 2px solid var(--ink);
}
.tab-body { flex: 1; overflow-y: auto; padding: 12px 12px 30px; overscroll-behavior: contain; }
.tab-body::-webkit-scrollbar { width: 10px; }
.tab-body::-webkit-scrollbar-thumb { background: #e7c48f; border-radius: 10px; border: 2px solid var(--card-2); }

/* ---------- Карточки ---------- */
.card {
  position: relative; background: var(--card); border: 3px solid var(--ink); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 12px; margin-bottom: 14px;
}
.card.hot { background: linear-gradient(180deg, #fff3c9, var(--card) 60%); }
.card.vip { background: linear-gradient(180deg, #efe5ff, var(--card) 60%); border-color: #5b3fc4; }
.card.sel { outline: 4px solid var(--sun); outline-offset: 2px; }
.card-head { display: flex; gap: 10px; align-items: flex-start; }
.thumb {
  flex: none; width: 52px; height: 52px; display: grid; place-items: center; font-size: 28px;
  border: 3px solid var(--ink); border-radius: 14px; background: #bfeef3; box-shadow: 0 3px 0 var(--ink);
}
.thumb.t-soviet { background: #efdcc4; } .thumb.t-studio { background: #ffd0b5; } .thumb.t-apartment { background: #ffc9c9; }
.thumb.t-seaview { background: #bfeef3; } .thumb.t-commercial { background: #ffe7a0; } .thumb.t-house { background: #d7f5c0; }
.thumb.t-land { background: #e8cfa5; } .thumb.t-hotel { background: #e0d3ff; } .thumb.t-villa { background: #ffd9ec; }
.card-title { flex: 1; min-width: 0; }
.card-title h4 { margin: 0; font-size: 15px; font-weight: 800; line-height: 1.2; }
.meta { font-size: 12px; color: var(--ink-soft); font-weight: 600; margin-top: 2px; }
.story { font-size: 12px; font-style: italic; color: var(--ink-soft); margin: 8px 0 6px; padding: 6px 9px; background: var(--card-2); border-radius: 10px; border: 2px dashed #e6c795; }
.tag { display: inline-block; font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 99px; border: 2px solid var(--ink); background: #fff; white-space: nowrap; }
.tag.hot { background: var(--coral); color: #fff; }
.tag.good { background: #c9f2c7; } .tag.bad { background: #ffd0cc; } .tag.warn { background: #ffe7a0; }
.tag.vip { background: var(--purple); color: #fff; }
.tag.c-black { background: #b9b8c2; } .tag.c-white { background: #fff; } .tag.c-old { background: #e8d3b0; }
.tag.c-basic { background: #c9f2c7; } .tag.c-euro { background: #bfe3ff; } .tag.c-design { background: #f3c6ff; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.spread { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.prices { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 8px 0; }
.prices div { background: var(--card-2); border-radius: 10px; padding: 5px 8px; }
.prices small { display: block; font-size: 10.5px; color: var(--ink-soft); font-weight: 700; text-transform: uppercase; letter-spacing: 0.3px; }
.prices b { font-size: 15px; font-weight: 800; font-variant-numeric: tabular-nums; }
.up { color: var(--green-dark); } .down { color: var(--red); }
.status { font-size: 12.5px; font-weight: 700; padding: 7px 10px; border-radius: 10px; background: var(--card-2); margin: 8px 0; }
.bar { height: 10px; border: 2px solid var(--ink); border-radius: 8px; background: #f1dfc0; overflow: hidden; margin-top: 5px; }
.bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--teal), var(--sea)); transition: width 0.4s; }
.bar.orange i { background: linear-gradient(90deg, var(--sun), var(--orange)); }
.bar.red i { background: linear-gradient(90deg, #ff9f80, var(--red)); }
.locked-overlay {
  position: absolute; inset: 0; border-radius: 13px; background: rgba(255, 243, 220, 0.82); display: grid; place-items: center;
  text-align: center; font-weight: 800; font-size: 13px; backdrop-filter: blur(1.5px);
}
.locked-overlay span { display: block; font-size: 26px; }
.section-title { font-size: 13px; font-weight: 900; text-transform: uppercase; letter-spacing: 1px; margin: 4px 2px 10px; color: var(--ink-soft); }
.empty { text-align: center; padding: 24px 14px; color: var(--ink-soft); font-weight: 600; }
.empty .big { font-size: 46px; display: block; margin-bottom: 6px; }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 12px; font-size: 13px; font-weight: 800;
  border: 2.5px solid var(--ink); border-radius: 12px; background: #fff; box-shadow: 0 3px 0 var(--ink); cursor: pointer;
  transition: transform 0.05s, filter 0.1s; white-space: nowrap; line-height: 1.15;
}
.btn:hover { filter: brightness(1.05); }
.btn:active { transform: translateY(3px); box-shadow: 0 0 0 var(--ink); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; box-shadow: 0 3px 0 var(--ink); }
.btn.primary { background: var(--green); color: #fff; text-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); }
.btn.orange { background: var(--orange); color: #fff; text-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); }
.btn.sun { background: var(--sun); }
.btn.coral { background: var(--coral); color: #fff; }
.btn.purple { background: var(--purple); color: #fff; }
.btn.teal { background: var(--teal); color: #fff; }
.btn.ghost { background: transparent; box-shadow: none; border-color: transparent; }
.btn.sm { padding: 5px 9px; font-size: 12px; border-radius: 10px; }
.btn.big { padding: 12px 18px; font-size: 16px; border-radius: 14px; }
.btn small { font-weight: 600; opacity: 0.85; }
.btn .gem { font-size: 12px; }
.btn-col { display: flex; flex-direction: column; align-items: flex-start; gap: 0; text-align: left; }
.actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.chip {
  font-size: 12px; font-weight: 700; padding: 5px 10px; border-radius: 99px; border: 2px solid var(--ink); background: var(--card); cursor: pointer;
}
.chip.on { background: var(--sun); box-shadow: 0 2px 0 var(--ink); }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; flex-wrap: wrap; }

/* ---------- Модалки ---------- */
.modal-bg {
  position: fixed; inset: 0; background: rgba(74, 38, 58, 0.45); display: grid; place-items: center; z-index: 50; padding: 16px;
  animation: fade 0.15s;
}
.modal {
  position: relative; width: min(480px, 100%); max-height: calc(100dvh - 32px); overflow-y: auto; background: var(--card);
  border: 3px solid var(--ink); border-radius: 22px; box-shadow: 0 7px 0 var(--ink); padding: 20px; animation: pop 0.28s cubic-bezier(.2, 1.6, .5, 1);
}
.modal.wide { width: min(620px, 100%); }
.modal h2 { margin: 0 0 6px; font-size: 22px; font-weight: 900; }
.modal p { line-height: 1.45; }
.modal .close { position: absolute; top: 10px; right: 10px; }
.close { width: 34px; height: 34px; border-radius: 50%; border: 2.5px solid var(--ink); background: #fff; font-size: 16px; font-weight: 900; cursor: pointer; box-shadow: 0 2px 0 var(--ink); }
.hero-emoji { font-size: 56px; text-align: center; display: block; margin: 0 0 4px; animation: bob 2s ease-in-out infinite; }
.bubble {
  position: relative; background: #fff; border: 3px solid var(--ink); border-radius: 16px; padding: 10px 14px; font-weight: 700; margin: 12px 0;
  animation: pop 0.25s cubic-bezier(.2, 1.6, .5, 1);
}
.bubble::after { content: ''; position: absolute; left: 24px; bottom: -12px; border: 9px solid transparent; border-top-color: var(--ink); }
.bubble.good { background: #e3fbe0; } .bubble.bad { background: #ffe3df; }
input[type=range] { width: 100%; accent-color: var(--orange); height: 28px; }
input[type=number], input[type=text] {
  width: 100%; font-family: inherit; font-size: 16px; font-weight: 700; padding: 9px 12px; border: 3px solid var(--ink); border-radius: 12px; background: #fff; color: var(--ink);
}
.offer-price { font-size: 30px; font-weight: 900; text-align: center; margin: 6px 0; font-variant-numeric: tabular-nums; }
.kv { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; font-size: 13.5px; margin: 10px 0; }
.kv span { color: var(--ink-soft); font-weight: 600; }
.kv b { text-align: right; font-variant-numeric: tabular-nums; }
.opt-list { display: flex; flex-direction: column; gap: 10px; margin: 12px 0; }
.opt {
  display: flex; gap: 12px; align-items: center; padding: 10px 12px; border: 3px solid var(--ink); border-radius: 14px; background: var(--card-2); cursor: pointer;
  text-align: left; font-family: inherit; width: 100%;
}
.opt:hover:not(:disabled) { background: #ffeac2; }
.opt.on { background: #ffe08a; box-shadow: 0 3px 0 var(--ink); }
.opt:disabled { opacity: 0.55; cursor: not-allowed; }
.opt .big-emoji { font-size: 32px; }
.opt-body { flex: 1; font-size: 12.5px; color: var(--ink-soft); font-weight: 600; }
.opt-body b { display: block; color: var(--ink); font-size: 15px; font-weight: 800; }

/* ---------- Магазин ---------- */
.shop-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 14px; }
.product { text-align: center; padding: 14px 10px 12px; margin: 0; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.product .p-emoji { font-size: 38px; line-height: 1.1; }
.product .p-name { font-weight: 800; font-size: 14px; }
.product .p-amount { font-weight: 900; font-size: 20px; color: #c2255c; }
.product .ribbon { position: absolute; top: -10px; right: -8px; transform: rotate(8deg); }
.vip-card { background: linear-gradient(135deg, #8a6cff, #ff7eb6); color: #fff; }
.vip-card h3 { margin: 0; font-size: 22px; font-weight: 900; -webkit-text-stroke: 1px var(--ink); paint-order: stroke fill; }
.vip-card ul { margin: 8px 0 12px; padding-left: 18px; font-weight: 600; font-size: 13px; line-height: 1.5; }
.starter-card { background: linear-gradient(135deg, #ffe08a, #ffb35c); }
.mock-note { font-size: 11.5px; color: var(--ink-soft); background: #fff3c9; border: 2px dashed #e6b84d; border-radius: 10px; padding: 7px 10px; font-weight: 600; }

/* ---------- Цели ---------- */
.streak { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; margin: 10px 0; }
.streak div { text-align: center; border: 2px solid var(--ink); border-radius: 10px; padding: 5px 2px; font-size: 10.5px; font-weight: 700; background: var(--card-2); }
.streak div.done { background: #c9f2c7; }
.streak div.next { background: var(--sun); box-shadow: 0 2px 0 var(--ink); }
.streak b { display: block; font-size: 13px; }
.quest.done { background: linear-gradient(180deg, #e3fbe0, var(--card) 70%); }
.quest.claimed { opacity: 0.55; }
.levels { display: flex; flex-direction: column; gap: 6px; }
.lvl-row { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border: 2px solid var(--ink); border-radius: 12px; background: var(--card); font-size: 12.5px; }
.lvl-row.cur { background: var(--sun); box-shadow: 0 3px 0 var(--ink); }
.lvl-row.past { opacity: 0.6; }
.lvl-row .n { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--purple); color: #fff; font-weight: 900; border: 2px solid var(--ink); flex: none; }
.lvl-row .u { color: var(--ink-soft); font-weight: 600; font-size: 11.5px; }

/* ---------- Новости ---------- */
.news-item { display: flex; gap: 10px; padding: 9px 10px; border-radius: 12px; background: var(--card); border: 2px solid rgba(74, 38, 58, 0.25); margin-bottom: 7px; font-size: 13px; line-height: 1.4; }
.news-item .d { flex: none; font-size: 10.5px; font-weight: 800; color: var(--ink-soft); width: 62px; }
.news-item.news { border-color: var(--sea); background: #eafbfd; }
.news-item.good { border-color: var(--green); }
.news-item.bad { border-color: var(--red); background: #fff1ef; }
.news-item.level { border-color: var(--purple); background: #f3eeff; }
.news-item.story { border-color: var(--orange); background: #fff3e0; }

/* ---------- Графики ---------- */
.chart { width: 100%; height: 120px; display: block; }
.spark { width: 100%; height: 46px; display: block; }

/* ---------- Тосты и анимации ---------- */
.toasts { position: fixed; left: 50%; top: 76px; transform: translateX(-50%); z-index: 60; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast {
  background: var(--card); border: 3px solid var(--ink); border-radius: 14px; padding: 9px 16px; font-weight: 700; font-size: 14px; box-shadow: 0 4px 0 var(--ink);
  animation: pop 0.3s cubic-bezier(.2, 1.6, .5, 1); max-width: min(520px, 90vw); text-align: center;
}
.toast.err { background: #ffe3df; }
.toast.good { background: #e3fbe0; }
.toast.out { animation: fadeout 0.3s forwards; }
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 70; width: 100%; height: 100%; }

@keyframes pop { from { transform: scale(0.85); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes fade { from { opacity: 0; } }
@keyframes fadeout { to { opacity: 0; transform: translateY(-10px); } }
@keyframes bob { 50% { transform: translateY(-6px); } }
@keyframes pulse { 50% { transform: scale(1.06); } }
.pulse { animation: pulse 1.2s ease-in-out infinite; }

/* ---------- Адаптив ---------- */
@media (max-width: 1100px) {
  .panel { width: 400px; }
  .pill-level { min-width: 0; }
  .map-hint { display: none; }
}
@media (max-width: 860px) {
  body { overflow: auto; }
  #app { height: auto; min-height: 100dvh; }
  .hud { gap: 6px; padding: 8px; }
  .brand-text { display: none; }
  .brand-logo { width: 38px; height: 38px; font-size: 22px; }
  .pill { min-height: 40px; padding: 3px 9px 3px 4px; }
  .pill-ico { width: 26px; height: 26px; font-size: 16px; }
  .pill-body b { font-size: 14px; }
  .pill-level { margin-left: 0; flex: 1 1 100%; }
  .main { flex-direction: column; }
  .map-wrap { height: 48vh; flex: none; border-right: 0; border-bottom: 3px solid var(--ink); }
  .panel { width: 100%; }
  .tab-body { overflow: visible; }
  .tabs { position: sticky; top: 0; z-index: 4; }
  .tabs button { font-size: 9px; }
  .tabs button span { font-size: 16px; }
  .district-card { left: 60px; width: auto; right: 10px; }
  .modifiers { display: none; }
  .shop-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
}

/* ---------- Заказы, касса, происшествия ---------- */
.order { padding-top: 14px; }
.order.ready { background: linear-gradient(180deg, #e3fbe0, var(--card) 55%); border-color: var(--green-dark); }
.order .client { display: flex; gap: 10px; align-items: center; }
.order .client-ava { width: 50px; height: 50px; flex: none; display: grid; place-items: center; font-size: 28px; border-radius: 50%; border: 3px solid var(--ink); background: #ffe0b5; box-shadow: 0 3px 0 var(--ink); }
.order .client h4 { margin: 0; font-size: 15px; font-weight: 800; }
.order .quote { position: relative; margin: 10px 0 8px; padding: 8px 12px; background: #fff; border: 2px solid var(--ink); border-radius: 14px; font-size: 12.5px; font-weight: 600; font-style: italic; }
.order .quote::before { content: ''; position: absolute; left: 18px; top: -9px; border: 7px solid transparent; border-bottom-color: var(--ink); border-top: 0; }
.reqs { display: flex; flex-wrap: wrap; gap: 5px; margin: 6px 0; }
.reward { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 12px; background: #fff3c9; border: 2px dashed #e6b84d; margin: 8px 0; }
.reward b { font-size: 18px; font-weight: 900; color: var(--green-dark); }
.reward small { display: block; font-size: 11px; color: var(--ink-soft); font-weight: 700; }
.deliver { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.deliver .btn { justify-content: space-between; width: 100%; }
.almost { font-size: 12px; font-weight: 600; color: var(--ink-soft); padding: 6px 10px; background: var(--card-2); border-radius: 10px; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.incident { border: 3px solid var(--coral); background: #fff1ef; border-radius: 14px; padding: 10px; margin: 8px 0; animation: pop .3s cubic-bezier(.2,1.6,.5,1); }
.incident h5 { margin: 0 0 3px; font-size: 14px; font-weight: 900; }
.incident p { margin: 0 0 8px; font-size: 12.5px; color: var(--ink-soft); font-weight: 600; }
.incident .actions { margin-top: 0; }
.cashbox { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.cashbox .bar { flex: 1; margin: 0 6px; }
.cashbox .bar i { background: linear-gradient(90deg, #b6f5a8, var(--green)); }
.cashbox.full .bar i { background: linear-gradient(90deg, #ffb4a2, var(--coral)); }
.tag.order-tag { background: #ffe08a; }

/* Рестарт игры — в блоке скорости, отделён пунктиром */
.speed .restart { margin-left: 4px; border-left: 2px dashed rgba(74, 38, 58, 0.3); border-radius: 0 10px 10px 0; font-size: 18px; font-weight: 900; }
.speed .restart:hover { background: #ffe3df; }
