:root {
  --cta: #00a667;
  --green: #6fd4a5;
  --green-ink: #3a9a6c;
  --green-deep: #1e3d2e;
  --green-soft: #eaf8f1;
  --green-mid: #c8edd9;
  --cream: #f5f5f5;
  --card: #ffffff;
  --ink: #171717;
  --mute: #6b6b6b;
  --line: #e5e5e5;
  --bar: #6fd4a5;
  --bar-track: #eaf8f1;
  --map: #102318;
  --map-empty: #1c382b;
  --map-stroke: #3d5c4a;
  --shadow: 0 12px 32px rgba(0, 0, 0, .08);
  --font: "Plus Jakarta Sans", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--cream); color: var(--ink); font-family: var(--font); }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 800; letter-spacing: -.03em; }
h1 { font-size: 1.55rem; }
h2 { font-size: 1.15rem; }
.mute { color: var(--mute); }
.hidden { display: none !important; }
.kicker {
  margin: 0 0 4px; color: var(--mute); font-size: .72rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .12em;
}

.brand { display: flex; align-items: center; gap: 8px; }
.brand-mark {
  width: 32px; height: 32px; border-radius: 10px; background: var(--green-deep); color: #fff;
  display: grid; place-items: center; font-weight: 800;
}
.brand-name { font-size: 1.02rem; font-weight: 800; }
.brand-name span { color: var(--mute); }
.nav { display: flex; align-items: center; gap: 8px; font-size: .88rem; font-weight: 700; }
.nav-sep { color: var(--line); font-weight: 500; }
.nav-link { color: var(--mute); }
.nav-link.is-on, .nav-link:hover { color: var(--ink); }

.pitch { margin: 4px 0 16px; }
.pitch h2 {
  font-size: 1.32rem; line-height: 1.15; margin: 0 0 8px;
}
.pitch p { margin: 0; color: #3d3d3d; font-size: .92rem; line-height: 1.45; font-weight: 500; }
.pitch-lead {
  margin: 8px 0 0; color: #3d3d3d; font-size: .86rem; line-height: 1.4; font-weight: 500;
}

.btn-cta, .dock-cta {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--cta); color: #fff; border: 0; border-radius: 14px;
  padding: 12px 16px; font-weight: 800; cursor: pointer;
  box-shadow: 0 10px 24px rgba(0, 166, 103, .28);
}
.btn-cta:hover, .dock-cta:hover { filter: brightness(1.05); }
.btn-block { width: 100%; margin: 0 0 14px; padding: 14px 18px; font-size: 1rem; }
.btn-cta-top { display: none; }
.btn-reta { background: #25d366; color: #06210e; margin: 10px 0 8px; }

.dock {
  display: none; position: fixed; left: 12px; right: 12px; z-index: 30;
  bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  gap: 8px; align-items: stretch;
}
.dock-btn {
  display: flex; align-items: center; justify-content: center;
  height: 52px; border-radius: 999px; font-weight: 800; cursor: pointer; border: 0;
  text-decoration: none;
}
.dock-rank {
  flex: 0 0 38%; background: #ececec; color: var(--ink);
}
.dock-cta {
  flex: 1; box-shadow: 0 10px 24px rgba(0, 166, 103, .28);
}

.card {
  background: var(--card); border: 1px solid var(--line); border-radius: 20px;
  padding: 16px; box-shadow: var(--shadow); margin-bottom: 12px;
}
.leader-card { border-color: color-mix(in srgb, var(--green) 35%, var(--line)); background: linear-gradient(180deg, #fff 0%, var(--green-soft) 140%); }
.leader-main { display: flex; gap: 14px; align-items: center; }
.hero-score { margin: 2px 0 0; font-size: 1.8rem; font-weight: 800; color: var(--cta); letter-spacing: -.04em; }
.hero-meta { margin: 2px 0 0; color: var(--mute); font-size: .82rem; }
.war-line { margin: 0 0 10px; font-weight: 700; }
.thermo { display: grid; gap: 8px; }
.thermo-row { display: grid; grid-template-columns: 28px 1fr auto; gap: 8px; align-items: center; }
.thermo-track { height: 8px; background: var(--green-soft); border-radius: 99px; overflow: hidden; }
.thermo-track i { display: block; height: 100%; border-radius: 99px; }
.duel-vs { margin: 0; text-align: center; color: var(--green-ink); font-size: .75rem; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; }

.head-stats {
  display: flex; flex-wrap: wrap; gap: 8px 12px; margin: 4px 0 12px;
  font-size: .72rem; color: var(--mute); font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
}
.head-stat b { color: var(--ink); font-size: .95rem; }
.head-stat.is-money b { color: var(--green-ink); }

.ticker {
  overflow: hidden; background: var(--green-soft); border: 1px solid var(--line);
  border-radius: 12px; height: 34px; display: flex; align-items: center; margin-bottom: 10px;
}
.ticker-track { display: flex; gap: 24px; white-space: nowrap; width: max-content; animation: ticker 42s linear infinite; padding-left: 12px; }
.ticker-item { font-size: .78rem; color: var(--green-ink); }
.ticker-item b { color: var(--ink); }
@keyframes ticker { to { transform: translateX(-50%); } }

.topbar {
  display: flex; flex-direction: column; align-items: flex-start; gap: 8px;
  padding: 12px 20px; background: #fff; border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20;
}
.topbar .btn-cta-top { align-self: flex-end; }
.page, .page-narrow { padding: 24px 16px 80px; max-width: 860px; margin: 0 auto; }
.page-narrow { max-width: 640px; }

.board-head { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; margin: 4px 0 12px; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.tab {
  border: 1px solid var(--line); background: #fff; color: var(--mute);
  border-radius: 999px; padding: 6px 12px; cursor: pointer; font-weight: 700; font-size: .82rem;
}
a.tab { display: inline-block; }
.tab.is-on { background: var(--ink); color: #fff; border-color: var(--ink); }

.rank { display: flex; flex-direction: column; gap: 0; }
.rank-row {
  display: grid; grid-template-columns: 28px 36px 1fr auto; gap: 10px; align-items: center;
  background: transparent; border: 0; border-bottom: 1px solid var(--line);
  border-radius: 0; padding: 10px 20px 10px 0; box-shadow: none;
}
.rank-row.is-first { border-color: var(--line); }
.rank-meta { min-width: 0; }
.rank-bar { height: 5px; background: var(--bar-track); border-radius: 99px; margin-top: 6px; overflow: hidden; }
.rank-bar i { display: block; height: 100%; border-radius: 99px; background: var(--bar); }
.rank-pos {
  color: var(--mute); font-size: .8rem; font-weight: 800; text-align: center;
}
.rank-row.is-first .rank-pos { color: var(--ink); }
.rank-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-pot { color: var(--ink); font-weight: 800; }
.text-link {
  display: inline-block; margin: 12px 0 4px; padding: 0; border: 0; background: none;
  color: var(--mute); font-weight: 700; font-size: .82rem; cursor: pointer;
}
.text-link:hover { color: var(--ink); }

.shield, .crest { width: 36px; height: 36px; object-fit: contain; }
.shield { display: grid; place-items: center; font-size: 9px; font-weight: 800; border-radius: 8px; }
.crest--sm { width: 26px; height: 26px; }
.crest--lg { width: 52px; height: 52px; }
.crest--xl, .crest--hero { width: 64px; height: 64px; }

.share { display: flex; flex-wrap: wrap; gap: 6px; }
.share-btn {
  border: 1px solid var(--line); background: #fff; border-radius: 999px;
  padding: 6px 11px; font-weight: 700; font-size: .75rem; cursor: pointer;
}
.share-wa { background: #25d366; color: #06210e; border-color: #25d366; }
.share-x { background: #111; color: #fff; border-color: #111; }

.toast {
  position: fixed; right: 12px; bottom: 80px; z-index: 50;
  width: min(360px, calc(100vw - 24px));
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  padding: 14px; box-shadow: var(--shadow);
}
.toast p { margin: 0 0 10px; font-weight: 700; }

.panel {
  background: #fff; border: 1px solid var(--line); border-radius: 20px;
  padding: 24px; box-shadow: var(--shadow);
}
.panel h1 { margin-bottom: 8px; }
.panel h2 { margin: 22px 0 8px; font-size: 1.1rem; }
.panel p, .panel li { line-height: 1.6; color: #2a3d32; }
.panel input, .panel select, .modal-card input, .modal-card select {
  width: 100%; background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 10px 12px; margin: 8px 0;
}
.eyebrow { color: var(--green-ink); text-transform: uppercase; letter-spacing: .12em; font-size: .75rem; font-weight: 800; margin: 0 0 6px; }
.flash { border-radius: 12px; padding: 10px 12px; margin: 10px 0; }
.flash-ok { background: var(--green-soft); border: 1px solid var(--green-mid); }
.flash-bad { background: #fde8e8; border: 1px solid #f0b4b4; color: #7a1f1f; }
.stat-big { font-size: 2rem; margin: 0; font-weight: 800; }
.stat-big.is-money, .is-money { color: var(--green-ink); }
.admin-grid { display: grid; grid-template-columns: 1fr; gap: 10px; margin-bottom: 20px; }
.admin-grid-4 { grid-template-columns: 1fr; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.table th, .table td { text-align: left; padding: 8px 10px; border-top: 1px solid var(--line); }
.table th { color: var(--mute); font-weight: 700; }
.linkish { background: none; border: 0; color: var(--green-ink); cursor: pointer; text-decoration: underline; }
.chart { width: 100%; height: 180px; display: block; }
.chart-line { stroke: var(--green); stroke-width: 3; fill: none; }
.chart-area { fill: color-mix(in srgb, var(--green) 18%, transparent); stroke: none; }
.chart-cap { margin: 8px 0 0; color: var(--mute); font-size: .8rem; }
.product-split { display: grid; gap: 16px; }
.ref-form { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0; }
.ref-form input { flex: 1; min-width: 140px; }

.foot { padding: 18px 0 28px; }
.foot-notice { margin: 0; color: var(--mute); font-size: .78rem; line-height: 1.55; font-weight: 400; }
.foot-notice .is-money { color: var(--green-ink); font-weight: 800; }

.modal {
  position: fixed; inset: 0; background: rgba(6, 14, 10, .62);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  display: grid; place-items: end center;
  padding: 0; z-index: 40;
}
.modal.hidden { display: none; }
.modal:not(.hidden) .modal-card { animation: modal-in .22s ease; }
@keyframes modal-in {
  from { opacity: 0; transform: translateY(28px); }
  to { opacity: 1; transform: none; }
}
.modal-card {
  background: #fff; border: 1px solid var(--line); border-radius: 22px 22px 0 0;
  width: 100%; height: min(720px, 94dvh); max-height: 94dvh; box-shadow: var(--shadow);
  display: flex; flex-direction: column; overflow: hidden;
}
.modal-top {
  display: grid; grid-template-columns: 40px 1fr 40px; align-items: center;
  padding: 14px 16px 0; gap: 8px; flex-shrink: 0;
}
.modal-top h3 { text-align: center; margin: 0; font-size: 1.05rem; }
.modal-icon {
  width: 40px; height: 40px; padding: 0; border: 0; background: none;
  color: var(--mute); cursor: pointer; display: grid; place-items: center;
  border-radius: 12px;
}
.modal-icon:hover { color: var(--ink); background: var(--cream); }
.modal-icon svg {
  width: 18px; height: 18px; stroke: currentColor; fill: none;
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}
.modal-back.is-off { visibility: hidden; pointer-events: none; }
.modal-body { flex: 1; min-height: 0; overflow: hidden; padding: 8px 16px 16px; display: flex; flex-direction: column; }
.modal-foot { flex-shrink: 0; padding: 12px 16px 16px; border-top: 1px solid var(--line); background: #fff; }
.modal-foot .btn-block { margin: 0; }
.modal-step { display: none; }
.modal-step.is-on { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.modal-card label { display: block; margin: 12px 0 4px; font-size: .75rem; color: var(--mute); font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 8px; }
.chip {
  border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 7px 12px; cursor: pointer; font-weight: 700;
}
.chip.is-on { background: var(--ink); color: #fff; border-color: var(--ink); }
.picker { position: relative; }
.picker-btn, .picker-chosen, .picker #club-search {
  width: 100%;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 10px 12px; margin: 8px 0; text-align: left; font-weight: 700;
}
.picker-btn, .picker-chosen {
  display: flex; align-items: center; gap: 10px; cursor: pointer;
}
.picker #club-search { cursor: text; font-weight: 500; }
.picker-chosen { justify-content: space-between; }
.picker-chosen .picker-main { display: flex; align-items: center; gap: 10px; min-width: 0; }
.picker-chosen .crest, .picker-chosen .shield { width: 28px; height: 28px; }
.picker-clear { background: none; border: 0; color: var(--mute); font-weight: 800; cursor: pointer; padding: 4px 8px; font-size: 1.1rem; }
.picker .suggest {
  position: absolute; left: 0; right: 0; z-index: 5;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  max-height: 240px; overflow: auto; margin-top: 0; box-shadow: var(--shadow);
}
#prov-picker.is-open {
  flex: 1; display: flex; flex-direction: column; min-height: 0;
}
#prov-picker.is-open .suggest {
  position: static; flex: 1; max-height: none; min-height: 180px;
  margin: 0; box-shadow: none;
}
.suggest { background: #fff; border: 1px solid var(--line); border-radius: 12px; max-height: 220px; overflow: auto; margin-top: 4px; box-shadow: var(--shadow); }
.suggest button { display: flex; width: 100%; gap: 8px; align-items: center; background: none; border: 0; padding: 10px 12px; text-align: left; cursor: pointer; }
.suggest button:hover, .suggest button.is-on { background: var(--green-soft); }
.pts-hint { margin: 0 0 10px; color: var(--mute); font-size: .78rem; }
.count { font-size: .75rem; color: var(--mute); margin: 4px 0 0; }

.sheet {
  position: fixed; inset: 0; z-index: 35;
  background: rgba(6, 14, 10, .5);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  display: grid; place-items: end center;
}
.sheet.hidden { display: none; }
.sheet:not(.hidden) .sheet-card { animation: modal-in .22s ease; }
.sheet-card {
  width: 100%; max-height: 82vh; background: #fff;
  border-radius: 22px 22px 0 0; display: flex; flex-direction: column;
  box-shadow: var(--shadow);
}
.sheet-grab { width: 40px; height: 4px; border-radius: 99px; background: var(--line); margin: 10px auto 0; }
.sheet-top { display: flex; justify-content: space-between; align-items: center; padding: 10px 16px 0; }
.sheet-body { overflow: auto; padding: 8px 16px 24px; flex: 1; min-height: 0; }

/* App shell: map is the stage */
body.is-app { height: 100dvh; overflow: hidden; background: var(--cream); }
.shell { display: flex; flex-direction: column; height: 100dvh; }
.rail {
  order: 2; flex: 1; min-height: 0; overflow: hidden;
  display: flex; flex-direction: column;
  padding: 12px 14px 84px; background: var(--cream);
}
.rail-head { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; margin-bottom: 10px; flex-shrink: 0; }
.rail > .btn-block { flex-shrink: 0; margin: 0 0 32px; }
.rail-body { flex: 1; min-height: 0; overflow: auto; }
.rail-view { display: none; }
.rail-view.is-on { display: block; animation: rail-reveal .42s ease; }
@keyframes rail-reveal {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}
.rail-rules h1 { font-size: 1.35rem; margin: 0 0 10px; }
.rail-rules h2 { font-size: 1rem; margin: 20px 0 6px; }
.rail-rules p, .rail-rules li { font-size: .88rem; line-height: 1.55; color: #3d3d3d; }
.rail-rules ul { padding-left: 18px; }
.stage {
  order: 1; position: relative; height: 58vh; flex-shrink: 0;
  background:
    radial-gradient(circle at 50% 28%, #1a3a28 0%, var(--map) 62%);
  overflow: hidden;
}
.map-leader {
  position: absolute; top: 12px; left: 12px; z-index: 8;
  width: min(300px, calc(100% - 86px)); margin: 0; padding: 14px 16px;
  background: #fff; border: 1px solid var(--line); border-radius: 18px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, .18);
}
.map-leader .leader-main { gap: 14px; }
.map-leader .crest--lg { width: 56px; height: 56px; }
.map-leader h1 { font-size: 1.2rem; }
.map-leader .hero-score { font-size: 1.7rem; }
.map-leader .hero-meta { display: none; }
.map-leader.is-empty { width: min(360px, calc(100% - 24px)); }
.map-leader.is-empty h1 { font-size: 1.18rem; line-height: 1.15; }
.map-leader.is-flash { animation: hero-pulse .9s ease; }
@keyframes hero-pulse {
  0%, 100% { box-shadow: 0 16px 40px rgba(0, 0, 0, .18); }
  40% { box-shadow: 0 0 0 6px rgba(255,255,255,.18), 0 18px 44px rgba(0, 0, 0, .28); }
}
.map-hud {
  position: absolute; top: 10px; right: 10px; z-index: 6;
  display: flex; justify-content: flex-end; pointer-events: none;
  opacity: 0; transition: opacity .2s ease;
}
.stage:hover .map-hud, .map-hud:focus-within { opacity: 1; pointer-events: auto; }
.map-tools { display: flex; align-items: center; gap: 8px; pointer-events: auto; }
.tool {
  box-sizing: border-box;
  width: 34px; height: 34px; padding: 0; margin: 0;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); border-radius: 50%;
  background: #fff; color: var(--ink); cursor: pointer;
  box-shadow: 0 6px 16px rgba(16, 48, 32, .08);
  line-height: 0;
}
.tool svg {
  display: block; width: 15px; height: 15px;
  stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round;
  fill: none;
}
.tool .icon-close { display: none; }
body.is-map-wide .tool .icon-expand { display: none; }
body.is-map-wide .tool .icon-close { display: block; }
.tool:hover { color: #000; border-color: #cfcfcf; }
.map-viewport { width: 100%; height: 100%; overflow: hidden; cursor: grab; touch-action: none; }
.map-viewport.is-drag { cursor: grabbing; }
.map-world { width: 100%; transform-origin: 0 0; }
.map-svg { padding: 8px 12px; }
.map-svg svg { width: min(100%, 420px); height: auto; display: block; margin: 0 auto; }
#arg-map .provinces { fill: var(--map-empty); stroke: var(--map-stroke); }
#arg-map #caba-dot { fill: var(--map-empty); stroke: var(--map-stroke); }
.map-svg path, .map-svg #caba-dot { cursor: pointer; }
.map-svg path:hover, .map-svg #caba-dot:hover { stroke: #fff; }
.map-svg .map-crests image, .map-svg .map-crests text, .map-svg .map-crests circle, .map-svg .map-crests path { pointer-events: none; }
.map-crest-halo { fill: #fff; stroke: rgba(20, 20, 20, .08); stroke-width: 0.6; }
.map-crest.is-new { animation: crest-in .45s ease; transform-box: fill-box; transform-origin: center; }
.map-svg path.is-flip, .map-svg circle.is-flip {
  animation: prov-flip 1.6s ease;
}
.map-stats {
  position: absolute; left: 12px; bottom: 12px; z-index: 8;
  display: flex; flex-wrap: wrap; gap: 6px; pointer-events: none;
}
.map-stat {
  display: inline-flex; align-items: baseline; gap: 4px;
  background: rgba(255,255,255,.92); border: 1px solid var(--line); border-radius: 999px;
  padding: 4px 8px; box-shadow: none;
  font-size: .6rem; font-weight: 700; color: var(--mute);
  text-transform: uppercase; letter-spacing: .04em;
}
.map-stat b {
  color: var(--ink); font-size: .72rem; letter-spacing: 0; text-transform: none;
}
.map-stat.is-money b { color: var(--green-ink); }
@keyframes crest-in { from { opacity: 0; transform: scale(.35); } to { opacity: 1; transform: scale(1); } }
@keyframes prov-flip {
  0% { stroke: #fff; stroke-width: 2.6; }
  55% { stroke: #fff; stroke-width: 2.2; }
  100% { stroke: rgba(255,255,255,.22); stroke-width: 1; }
}
.map-tip {
  position: absolute; z-index: 7; min-width: 140px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 8px 10px; pointer-events: none; box-shadow: var(--shadow);
}
.map-tip b { display: block; }
.map-tip span { color: var(--mute); font-size: .78rem; }
.live-toasts {
  position: fixed; right: 16px; bottom: 16px; z-index: 25;
  display: flex; flex-direction: column; gap: 8px; width: min(280px, calc(100vw - 24px));
  pointer-events: none;
}
.live-toast {
  display: flex; align-items: center; gap: 8px;
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 10px 12px; box-shadow: var(--shadow);
  animation: toast-in .35s ease;
}
.live-toast p { margin: 0; font-size: .8rem; line-height: 1.35; }
.live-toast.is-out { animation: toast-out .3s ease forwards; }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes toast-out { to { opacity: 0; transform: translateY(8px); } }

body.is-map-wide .rail { display: none; }
body.is-map-wide .stage { height: 100dvh; }
body.is-map-wide .dock { display: none; }

@media (max-width: 899px) {
  body.is-app .rail { display: none; }
  body.is-app .stage { height: 100dvh; }
  body.is-app .dock { display: flex; }
  .map-hud { opacity: 1; pointer-events: auto; }
  .rank-row { padding: 10px 18px 10px 0; gap: 8px; }
  .map-leader { width: min(280px, calc(100% - 78px)); padding: 12px 14px; }
  .map-leader.is-empty { width: min(340px, calc(100% - 24px)); }
  .map-leader .crest--lg { width: 48px; height: 48px; }
  .map-leader .hero-score { font-size: 1.5rem; }
  .map-stats { bottom: 76px; }
  .live-toasts { bottom: 80px; }
}

@media (min-width: 900px) {
  body.is-app { overflow: hidden; }
  body.is-app .dock { display: none; }
  .shell { flex-direction: row; }
  .rail {
    order: 1; flex: 0 0 440px; width: 440px; max-width: 38vw;
    height: 100dvh; padding: 18px 16px 24px;
    border-right: 1px solid var(--line); background: var(--cream);
  }
  .stage { order: 2; flex: 1 1 auto; min-width: 0; height: 100dvh; }
  .map-svg { padding: 24px 40px; }
  .map-svg svg { width: auto; height: min(88vh, 820px); max-width: 100%; }
  .btn-cta-top { display: inline-flex; }
  .modal { place-items: center; padding: 16px; }
  .modal-card { width: min(560px, 100%); height: min(720px, 90dvh); border-radius: 22px; }
  .modal:not(.hidden) .modal-card { animation-name: modal-in-desk; }
  @keyframes modal-in-desk {
    from { opacity: 0; transform: translateY(12px) scale(.98); }
    to { opacity: 1; transform: none; }
  }
  .sheet { display: none !important; }
  .rank-row { grid-template-columns: 28px 36px 1fr auto; }
  .live-toasts { bottom: 20px; right: 20px; }
  .admin-grid, .admin-grid-4 { grid-template-columns: repeat(2, 1fr); }
  .product-split { grid-template-columns: 1.3fr .7fr; }
  body.is-map-wide .rail { display: none; }
  body.is-map-wide .stage { width: 100%; }
}

@media (min-width: 1100px) {
  .admin-grid-4 { grid-template-columns: repeat(4, 1fr); }
}
