/* Wire to Wire — Stable screen. Original "midnight & brass" console look. */
:root { --brass: #d8b45a; --brass2: #8a6a26; --ink: #07131d; --pn: rgba(10, 32, 48, .9); --pn2: #12344b; --cell: #0a1c2a; --txt: #eef4f7; --mut: #9fb6c4;
  --gSS: #ff5fe0; --gS: #ff5b5b; --gA: #ff9e2c; --gB: #ffd84a; --gC: #7fe07a; --gD: #5fd0ff; --gE: #b3c0cb;
  --safeB: env(safe-area-inset-bottom, 0px); --safeT: env(safe-area-inset-top, 0px); --hintH: 40px; --num: 'Bahnschrift', 'DIN Alternate', 'Roboto Condensed', 'Arial Narrow', system-ui, sans-serif; }
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: #120b06; color: var(--txt); font: 14px/1.3 system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; overflow: hidden; overscroll-behavior: none; }
button { font: inherit; color: inherit; cursor: pointer; touch-action: manipulation; }
#stage { position: fixed; inset: 0; } #gl { display: block; width: 100%; height: 100%; touch-action: pan-y; }
.legal { position: fixed; left: 0; right: 0; bottom: calc(var(--hintH) + var(--safeB)); margin: 0; text-align: center; font-size: 10px; color: rgba(255, 255, 255, .45); pointer-events: none; z-index: 3; }
/* ---------- panels ---------- */
.pnl { position: absolute; background: linear-gradient(180deg, rgba(18, 52, 75, .94), rgba(8, 26, 40, .94)); border: 2px solid var(--brass); border-radius: 10px; box-shadow: inset 0 0 0 2px rgba(0, 0, 0, .55), inset 0 2px 0 3px rgba(255, 255, 255, .07), 0 10px 30px rgba(0, 0, 0, .5); }
.pnl::before, .pnl::after { content: ''; position: absolute; top: 6px; width: 7px; height: 7px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #fff3c4, var(--brass) 45%, var(--brass2)); box-shadow: 0 1px 1px #000; }
.pnl::before { left: 6px; } .pnl::after { right: 6px; }
.ttl { display: flex; align-items: center; justify-content: center; gap: 8px; margin: -2px -2px 8px; padding: 5px 22px; font: 800 15px/1.1 var(--num); letter-spacing: .14em; text-transform: uppercase; color: #2a1a00; background: linear-gradient(180deg, #ffe9a6, var(--brass) 55%, #a57b26); border-radius: 8px 8px 3px 3px; text-shadow: 0 1px 0 rgba(255, 255, 255, .5); }
.ttl .fl { font-size: 13px; opacity: .8; }
#ui { position: fixed; inset: 0 0 calc(var(--hintH) + var(--safeB)); pointer-events: none; z-index: 2; } #ui > * { pointer-events: auto; }
/* landscape layout (iPad, desktop) */
.info { left: 12px; top: calc(10px + var(--safeT)); width: 290px; padding: 0 10px 10px; }
.menu { left: 12px; top: calc(150px + var(--safeT)); width: 290px; padding: 10px 10px 10px 36px; display: flex; flex-direction: column; gap: 7px; }
.abil { left: 12px; bottom: 12px; width: 290px; padding: 0 10px 10px; }
.stat { right: 12px; top: calc(10px + var(--safeT)); bottom: 12px; width: 420px; padding: 0 10px 10px; overflow: auto; }
.hs { left: 316px; right: 446px; bottom: 12px; padding: 10px 14px; display: grid; grid-template-columns: auto 1fr auto; gap: 4px 12px; align-items: center; min-height: 92px; }
/* info box */
.irow { display: flex; gap: 8px; } .icell { flex: 1; background: var(--cell); border: 1px solid rgba(216, 180, 90, .4); border-radius: 6px; padding: 5px 9px; font: 700 20px/1.1 var(--num); text-align: center; box-shadow: inset 0 2px 6px rgba(0, 0, 0, .6); }
.icell small { display: block; font: 600 9px/1 system-ui; letter-spacing: .12em; color: var(--mut); text-transform: uppercase; margin-bottom: 2px; }
.ipts { margin-top: 7px; display: flex; justify-content: space-between; align-items: baseline; background: var(--cell); border-radius: 6px; padding: 6px 10px; border: 1px solid rgba(216, 180, 90, .4); box-shadow: inset 0 2px 6px rgba(0, 0, 0, .6); }
.ipts span { color: var(--mut); font-size: 12px; } .ipts b { font: 700 19px var(--num); color: #fff4cf; } .ipts em { font-style: normal; font-size: 12px; color: var(--mut); }
/* menu buttons: beveled */
.mb { position: relative; display: block; width: 100%; text-align: left; padding: 8px 14px; border-radius: 8px; border: 1px solid #0b2536; font: 800 16px/1.1 var(--num); letter-spacing: .04em; color: #dbeefa;
  background: linear-gradient(180deg, #5f9bc4 0%, #2d6b96 48%, #1d4f74 52%, #2a628a 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), inset 0 -2px 0 rgba(0, 0, 0, .35), 0 2px 3px rgba(0, 0, 0, .5); text-shadow: 0 1px 1px #04121c; }
.mb.cur { color: #3a2300; background: linear-gradient(180deg, #fff1b8 0%, #f3c84e 48%, #d9a62c 52%, #f0c454 100%); text-shadow: 0 1px 0 rgba(255, 255, 255, .6); }
.mb.off { opacity: .38; filter: grayscale(.7); }
.mb .hand { position: absolute; left: -34px; top: 50%; transform: translateY(-50%); font-size: 26px; filter: drop-shadow(0 2px 2px #000); animation: poke 0.9s ease-in-out infinite; display: none; }
.mb.cur .hand { display: block; }
@keyframes poke { 50% { transform: translate(5px, -50%); } }
/* abilities */
.slot { height: 30px; margin-top: 5px; border-radius: 7px; border: 1px solid rgba(216, 180, 90, .35); background: var(--cell); display: flex; align-items: center; box-shadow: inset 0 2px 6px rgba(0, 0, 0, .6); width: 100%; padding: 0; }
.slot.empty { justify-content: center; color: rgba(255, 255, 255, .25); font-size: 11px; letter-spacing: .2em; }
.ab { margin: 0 5px; flex: 1; height: 23px; border-radius: 13px 4px 13px 4px; display: flex; align-items: center; gap: 6px; padding: 0 10px; color: #fff; font: italic 800 14px/1 var(--num); letter-spacing: .02em; text-shadow: 0 1px 2px rgba(0, 0, 0, .75), 0 0 6px rgba(0, 0, 0, .3); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55), 0 0 10px rgba(255, 255, 255, .08); position: relative; overflow: hidden; }
.ab::after { content: ''; position: absolute; inset: 0 0 55% 0; background: linear-gradient(180deg, rgba(255, 255, 255, .45), transparent); }
.ab i { font-style: normal; } .ab small { margin-left: auto; font: 700 8px system-ui; letter-spacing: .14em; opacity: .9; color: #fffbe0; }
/* stat panel */
.sgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 5px 8px; }
.sb { display: grid; grid-template-columns: 1fr 58px; align-items: stretch; border-radius: 5px; overflow: hidden; border: 1px solid #061520; background: linear-gradient(180deg, #2f6283, #1b4361); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25); position: relative; }
.sb .l { padding: 5px 8px 7px; font: 700 13px/1.1 var(--num); letter-spacing: .05em; color: #e3f2fb; display: flex; align-items: center; justify-content: center; text-shadow: 0 1px 1px #000; }
.sb .n { background: var(--cell); display: flex; align-items: center; justify-content: center; font: 800 22px/1 var(--num); letter-spacing: .02em; box-shadow: inset 0 2px 6px rgba(0, 0, 0, .7); position: relative; }
.sb .n sup { position: absolute; right: 3px; top: 3px; font: 700 8px system-ui; color: #ffe08a; }
.sb .cap { position: absolute; left: 6px; right: 64px; bottom: 3px; height: 3px; background: rgba(0, 0, 0, .45); border-radius: 2px; }
.sb .cap b { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 2px; } .sb .cap i { position: absolute; top: -2px; width: 2px; height: 7px; background: #fff; box-shadow: 0 0 3px #fff; }
.gSS { color: var(--gSS); } .gS { color: var(--gS); } .gA { color: var(--gA); } .gB { color: var(--gB); } .gC { color: var(--gC); } .gD { color: var(--gD); } .gE { color: var(--gE); }
.bSS { background: var(--gSS); } .bS { background: var(--gS); } .bA { background: var(--gA); } .bB { background: var(--gB); } .bC { background: var(--gC); } .bD { background: var(--gD); } .bE { background: var(--gE); }
.srow { margin-top: 5px; display: grid; grid-template-columns: 92px 1fr; border-radius: 5px; overflow: hidden; border: 1px solid #061520; }
.srow > span { padding: 6px 8px; font: 700 13px/1.1 var(--num); letter-spacing: .05em; background: linear-gradient(180deg, #2f6283, #1b4361); text-align: center; display: flex; align-items: center; justify-content: center; }
.srow > div { background: var(--cell); padding: 5px 10px; display: flex; align-items: center; gap: 12px; font: 700 16px var(--num); box-shadow: inset 0 2px 6px rgba(0, 0, 0, .7); flex-wrap: wrap; }
.apt { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--mut); } .apt b { font-size: 20px; color: #fff; line-height: 1; } .apt b.m2 { color: var(--gC); } .apt b.m3 { color: var(--gA); } .apt b.m4 { color: var(--gSS); } .apt b.m1 { color: var(--gE); }
.legs { display: flex; gap: 3px; } .legs i { width: 24px; height: 16px; clip-path: polygon(0 0, 60% 0, 100% 50%, 60% 100%, 0 100%, 35% 50%); background: #33495a; }
.legs i.l1 { background: #e7a23a; } .legs i.l2 { background: linear-gradient(90deg, #ffef9a, #ff8a1e); filter: drop-shadow(0 0 4px #ffb347); }
.legs + em { font-style: normal; font: 600 12px system-ui; color: var(--mut); }
.grow { margin-top: 5px; display: grid; grid-template-columns: 120px 1fr; gap: 6px; }
.gtype { border-radius: 5px; overflow: hidden; border: 1px solid #061520; display: flex; flex-direction: column; }
.gtype span { padding: 5px; text-align: center; font: 700 12px var(--num); letter-spacing: .05em; background: linear-gradient(180deg, #2f6283, #1b4361); }
.gtype b { flex: 1; background: var(--cell); display: flex; flex-direction: column; align-items: center; justify-content: center; font: 800 19px var(--num); color: #9ff3a8; box-shadow: inset 0 2px 6px rgba(0, 0, 0, .7); padding: 4px; }
.gtype b small { font: 600 10px system-ui; color: var(--mut); margin-top: 2px; text-align: center; }
.gchart { background: #0a2230; border-radius: 5px; border: 1px solid #061520; padding: 4px; } .gchart svg { width: 100%; height: 100%; display: block; min-height: 96px; }
.legend { margin-top: 6px; font-size: 10.5px; color: var(--mut); text-align: center; } .legend b { color: #fff; }
/* Hs Info */
.cls { font: italic 900 50px/0.9 var(--num); min-width: 64px; text-align: center; text-shadow: 0 2px 0 #000, 0 0 14px currentColor; letter-spacing: -.04em; }
.hsn { min-width: 0; } .hsn .nm { font: 800 24px/1.05 var(--num); letter-spacing: .06em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 2px 2px #000; }
.hsn .sub { color: var(--mut); font-size: 13px; margin-top: 2px; } .hsn .sub b { color: #fff; }
.sex { display: inline-grid; place-items: center; width: 26px; height: 20px; border-radius: 4px; border: 1px solid #fff8; font: 700 11px var(--num); margin-right: 6px; vertical-align: 2px; background: #1b4361; }
.cond { display: flex; flex-direction: column; align-items: center; gap: 2px; background: linear-gradient(180deg, #c8612b, #7d3311); border: 2px solid #ffd39a; border-radius: 10px; padding: 4px 6px 3px; font: 800 11px var(--num); letter-spacing: .08em; text-transform: uppercase; color: #fff4df; box-shadow: 0 3px 8px rgba(0, 0, 0, .5); }
.cond svg { width: 52px; height: 46px; display: block; }
.entry { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; font: 700 13px var(--num); letter-spacing: .04em; }
.entry .chip { padding: 3px 10px; border-radius: 999px; background: #1b4361; border: 1px solid #fff3; } .entry .chip.in { background: #2e7d32; border-color: #a5e887; } .entry .chip.nom { background: #6a3fa0; } .entry .chip.inj { background: #a8322a; }
.entry .tier { margin-left: auto; color: var(--mut); font-weight: 600; font-family: system-ui; font-size: 12px; }
/* flip arrows */
.flip { position: absolute; top: 45%; z-index: 3; width: 54px; height: 70px; border-radius: 12px; border: 2px solid var(--brass); background: linear-gradient(180deg, #2d6b96, #133a56); color: #ffe9a6; font-size: 26px; box-shadow: 0 4px 12px rgba(0, 0, 0, .5); }
.flip.prev { left: 316px; } .flip.next { right: 446px; } .flip:active { transform: scale(.94); }
.count { position: absolute; top: calc(12px + var(--safeT)); left: 50%; transform: translateX(-55%); z-index: 3; padding: 5px 14px; border-radius: 999px; background: rgba(7, 19, 29, .8); border: 1px solid var(--brass); font: 700 13px var(--num); letter-spacing: .1em; color: #ffe9a6; white-space: nowrap; }
.count a { color: #9fd8ff; text-decoration: none; margin-left: 10px; }
/* controller-hint bar */
.hint { position: fixed; left: 0; right: 0; bottom: 0; height: calc(var(--hintH) + var(--safeB)); padding-bottom: var(--safeB); z-index: 4; display: flex; align-items: center; justify-content: center; gap: 22px; background: linear-gradient(180deg, #3b2a17, #1d140a); border-top: 2px solid var(--brass); box-shadow: 0 -4px 14px rgba(0, 0, 0, .5); font: 700 14px var(--num); letter-spacing: .06em; color: #f5e6c4; white-space: nowrap; overflow-x: auto; }
.hint span { display: inline-flex; align-items: center; gap: 6px; } .hint button { background: none; border: 0; padding: 0; display: inline-flex; align-items: center; gap: 6px; font: inherit; color: inherit; }
.key { display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 6px; border-radius: 50%; font: 900 12px system-ui; color: #1d140a; box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .3), 0 1px 0 rgba(255, 255, 255, .3); }
.k1 { background: #f2c14e; } .k2 { background: #6fc3ff; } .k3 { background: #8fe388; } .k4 { background: #ff8d7a; border-radius: 6px; }
/* sheet (modal) */
.sheet { position: fixed; inset: 0; z-index: 10; display: none; align-items: center; justify-content: center; background: rgba(3, 9, 14, .55); padding: 14px; }
.sheet.show { display: flex; }
.sheet .pnl { position: relative; width: min(560px, 100%); max-height: calc(100% - 20px); display: flex; flex-direction: column; padding: 0 12px 12px; }
.sheet .body { overflow: auto; padding: 2px 2px 4px; } .sheet .x { position: absolute; right: 10px; top: 4px; z-index: 2; width: 30px; height: 30px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .3); color: #2a1a00; font-size: 16px; font-weight: 900; }
.sheet h4 { margin: 12px 0 6px; font: 800 12px var(--num); letter-spacing: .14em; text-transform: uppercase; color: var(--brass); }
.sheet p { margin: 6px 0; color: #d7e4ec; }
.opt { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; margin-top: 6px; border-radius: 8px; background: var(--cell); border: 1px solid rgba(216, 180, 90, .35); text-align: left; }
.opt.on { border-color: #ffd84a; box-shadow: 0 0 0 2px rgba(255, 216, 74, .35) inset; } .opt b { display: block; } .opt small { color: var(--mut); } .opt .r { margin-left: auto; text-align: right; font-weight: 700; color: #ffe9a6; white-space: nowrap; }
.btn { padding: 9px 16px; border-radius: 8px; border: 1px solid #0b2536; font: 800 14px var(--num); letter-spacing: .05em; color: #3a2300; background: linear-gradient(180deg, #fff1b8, #f3c84e 48%, #d9a62c 52%, #f0c454); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .5), 0 2px 3px rgba(0, 0, 0, .5); }
.btn.alt { color: #dbeefa; background: linear-gradient(180deg, #5f9bc4, #2d6b96 48%, #1d4f74 52%, #2a628a); } .btn:disabled { opacity: .4; }
.btns { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; font-size: 13px; } .kv span { color: var(--mut); }
table.pp { width: 100%; border-collapse: collapse; font-size: 12px; } .pp td, .pp th { padding: 4px 5px; border-bottom: 1px solid rgba(255, 255, 255, .08); text-align: left; } .pp th { color: var(--mut); font-weight: 600; }
.range { width: 100%; accent-color: #f3c84e; }
.bids p { margin: 3px 0; padding: 5px 8px; border-radius: 6px; background: rgba(255, 255, 255, .05); font-size: 13px; } .bids p:first-child { background: rgba(243, 200, 78, .22); }
.res { margin-top: 10px; padding: 10px; border-radius: 8px; background: rgba(0, 0, 0, .25); font-weight: 700; }
.toast { position: fixed; left: 50%; top: calc(54px + var(--safeT)); transform: translate(-50%, -10px); opacity: 0; transition: .25s; z-index: 20; padding: 9px 16px; border-radius: 10px; background: rgba(7, 19, 29, .94); border: 1px solid var(--brass); max-width: min(92vw, 520px); text-align: center; pointer-events: none; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.loading { position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, #3a2814, #0b0704 70%); transition: opacity .5s; text-align: center; }
.loading b { display: block; font: 800 28px var(--num); letter-spacing: .14em; color: var(--brass); } .loading span { color: #e8d6b0; } .loading.hide { opacity: 0; pointer-events: none; }
.empty { padding: 20px; text-align: center; }
.abil-in { display: none; }
/* ---------- compact landscape (phones on their side) ---------- */
@media (max-height: 560px) and (orientation: landscape) {
  :root { --hintH: 30px; }
  .info { width: 210px; top: calc(6px + var(--safeT)); left: calc(6px + env(safe-area-inset-left, 0px)); padding: 0 6px 6px; } .info .ttl { font-size: 11px; padding: 3px 14px; margin-bottom: 4px; }
  .icell { font-size: 14px; padding: 3px 5px; } .ipts { margin-top: 4px; padding: 3px 7px; } .ipts b { font-size: 14px; }
  .menu { left: calc(6px + env(safe-area-inset-left, 0px)); width: 210px; top: calc(102px + var(--safeT)); bottom: 6px; overflow: auto; padding: 6px 6px 6px 26px; gap: 4px; }
  .mb { font-size: 12px; padding: 6px 9px; } .mb .hand { font-size: 18px; left: -24px; }
  .abil { display: none; } .abil-in { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; } .abil-in .ab { flex: 0 0 auto; height: 20px; font-size: 10px; margin: 0; border: 0; } .abil-in small { color: var(--mut); font-size: 10px; }
  .stat { width: 300px; right: calc(6px + env(safe-area-inset-right, 0px)); top: calc(6px + var(--safeT)); bottom: 6px; padding: 0 6px 6px; } .stat .ttl { font-size: 11px; padding: 3px 14px; margin-bottom: 5px; }
  .sb .l { font-size: 10px; padding: 3px 4px 6px; } .sb { grid-template-columns: 1fr 40px; } .sb .n { font-size: 16px; } .sb .cap { right: 46px; }
  .srow { grid-template-columns: 64px 1fr; } .srow > span { font-size: 10px; padding: 4px; } .srow > div { font-size: 12px; padding: 3px 6px; gap: 8px; } .apt b { font-size: 15px; }
  .grow { grid-template-columns: 84px 1fr; } .gchart svg { min-height: 64px; } .legs i { width: 16px; height: 11px; }
  .hs { left: 224px; right: 314px; bottom: 6px; padding: 6px 8px; min-height: 0; gap: 2px 8px; } .cls { font-size: 32px; min-width: 38px; } .hsn .nm { font-size: 15px; } .hsn .sub { font-size: 10.5px; } .cond svg { width: 30px; height: 27px; } .cond { padding: 2px 4px; font-size: 8px; } .entry { font-size: 10.5px; } .entry .tier { display: none; }
  .flip { width: 40px; height: 52px; font-size: 18px; top: 36%; } .flip.prev { left: 224px; } .flip.next { right: 314px; }
  .count { font-size: 10px; padding: 3px 10px; } .hint { font-size: 11px; gap: 14px; } .key { min-width: 18px; height: 18px; font-size: 10px; } .legal { display: none; }
}
/* ---------- portrait phones and narrow tablets ---------- */
@media (orientation: portrait), (max-width: 760px) and (min-height: 561px) {
  #stage { bottom: auto; height: 46vh; height: 46svh; }
  #ui { position: fixed; top: 46vh; top: 46svh; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 8px 8px 14px; display: flex; flex-direction: column; gap: 9px; }
  .pnl { position: relative; inset: auto; width: auto; flex-shrink: 0; }
  .hs { order: 0; margin-top: -2px; } .menu { order: 1; display: grid; grid-template-columns: 1fr 1fr; padding: 8px; gap: 6px; } .stat { order: 2; overflow: visible; } .abil { order: 3; } .info { order: 4; }
  .mb { font-size: 14px; padding: 10px; text-align: center; } .mb .hand { display: none !important; }
  .sb { grid-template-columns: 1fr 46px; } .sb .l { font-size: 12px; } .sb .n { font-size: 19px; } .sb .cap { right: 52px; }
  .grow { grid-template-columns: 100px 1fr; } .srow { grid-template-columns: 78px 1fr; }
  .flip { top: auto; bottom: 10px; width: 46px; height: 46px; font-size: 20px; } .flip.prev { left: 10px; } .flip.next { right: 10px; }
  .cls { font-size: 40px; min-width: 46px; } .hsn .nm { font-size: 19px; } .legal { display: none; }
  .hint { font-size: 12px; gap: 14px; }
}
@media (orientation: portrait) and (min-width: 700px) { .menu { grid-template-columns: 1fr 1fr 1fr 1fr; } }

/* Breeding 2.0: hidden genetic cap */
.sb .cap em.q { position: absolute; right: -2px; top: -9px; font: 800 10px/1 var(--num); color: #ffd84a; font-style: normal; }

/* ---- shared theme integration: header from nav.js sits above the 3D stall ---- */
body.w2w-game #stage, body.w2w-game #ui { top: calc(var(--w-h) + var(--w-safeT)); }
body.w2w-game .sheet { top: calc(var(--w-h) + var(--w-safeT)); }

/* ---- barn: trophy cabinet sheet + tapped-stall horse panel ---- */
.count .trbtn { margin-left: 10px; border: 1px solid var(--brass); background: rgba(201, 160, 74, .18); color: #ffe9a6; border-radius: 999px; padding: 2px 10px; font: 800 12px var(--num); cursor: pointer; }
.trsum { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 6px 0 10px; } .trsum span { background: rgba(0, 0, 0, .25); border: 1px solid rgba(201, 160, 74, .35); border-radius: 10px; padding: 6px; text-align: center; font-size: 11px; color: #cfdbe3; } .trsum b { display: block; font: 800 20px var(--num); color: #ffd84a; }
.trrow { display: grid; grid-template-columns: 34px 1fr auto; gap: 8px; align-items: center; padding: 8px 4px; border-bottom: 1px solid rgba(255, 255, 255, .08); } .trrow .ti { font-size: 22px; text-align: center; } .trrow b { color: #ffe9a6; } .trrow small { display: block; color: #cfdbe3; } .trrow .td { font: 700 11px var(--num); color: #9fb6c4; text-align: right; }
.trrow .gr { font-style: normal; margin-left: 6px; padding: 1px 6px; border-radius: 6px; background: #b8860b; color: #fff; font: 800 10px var(--num); }
.sheet.side { justify-content: flex-start; align-items: stretch; background: rgba(3, 9, 14, .25); } .sheet.side .pnl { width: min(380px, 92vw); max-height: none; height: 100%; border-radius: 0 16px 16px 0; }
.sheet.bottom { align-items: flex-end; padding: 0; } .sheet.bottom .pnl { width: 100%; max-height: 62%; border-radius: 18px 18px 0 0; animation: w2wUp .22s ease-out; }
@keyframes w2wUp { from { transform: translateY(40%); opacity: .4; } to { transform: none; opacity: 1; } }
.hpc { display: flex; gap: 10px; align-items: center; margin: 6px 0; } .hpc .cls { font-size: 34px; min-width: 44px; } .hpc .nm { font: 800 19px Georgia, serif; color: #ffe9a6; } .hpc small { display: block; color: #cfdbe3; }
.hpstats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; margin: 8px 0; } .hpstats span { background: rgba(0, 0, 0, .28); border-radius: 8px; padding: 4px 6px; display: flex; justify-content: space-between; align-items: baseline; } .hpstats small { font-size: 10px; color: #9fb6c4; } .hpstats b { font: 800 16px var(--num); }
.hplist { display: flex; flex-direction: column; gap: 5px; } .hplist button { text-align: left; border: 1px solid rgba(255, 255, 255, .1); background: rgba(0, 0, 0, .22); color: #e8f0f4; border-radius: 10px; padding: 7px 10px; cursor: pointer; } .hplist button.on { border-color: var(--brass); background: rgba(201, 160, 74, .2); } .hplist small { display: block; color: #9fb6c4; font-size: 11px; }
body.barnview #ui { display: none; } body.barnview.w2w-game #stage, body.barnview #stage { bottom: 0; height: auto; }
@media (orientation: portrait), (max-width: 760px) and (min-height: 561px) { body.barnview #stage { height: auto; bottom: 0; } }
body.bvsheet .flip { display: none; }
/* portrait: keep the 3D barn visible above the panels (the shared header rule used to pull the panels over it) */
@media (orientation: portrait), (max-width: 760px) and (min-height: 561px) {
  body.w2w-game #stage { bottom: auto; height: calc(44svh - var(--w-h)); min-height: 230px; }
  body.w2w-game #ui { top: calc(var(--w-h) + var(--w-safeT) + max(230px, 44svh - var(--w-h))); }
  body.w2w-game.barnview #stage { height: auto; bottom: 0; }
}
/* barn view: arrows sit at the screen edges so they never cover the horse over its door */
body.barnview .flip { top: 52%; } body.barnview .flip.prev { left: 14px; } body.barnview .flip.next { right: 14px; }
@media (max-width: 700px) and (orientation: portrait) { body.barnview .flip { top: auto; bottom: 10px; } }