/* Only overlay and loader styles. Battle itself uses the ORIGINAL, approved
   .battle-fullscreen-v11 CSS from game.html, including fan-shaped hand. */
#ttbSoloV210{position:fixed;inset:0;z-index:120;pointer-events:none}
#ttbSoloV210>*{pointer-events:auto}
#ttbSoloV210 .battle-fullscreen-v11{z-index:121}
#ttbSoloV210 .ttb-v211-busy{cursor:progress}
#ttbSoloV210 .ttb-v211-busy button{pointer-events:none!important}
#ttbSoloV210 .ttb-v211-loader{pointer-events:auto;position:fixed;inset:0;z-index:122;background:#05080d;color:#f9feff;padding:24px;display:grid;place-items:center;text-align:center}
#ttbSoloV210 .ttb-v211-loader-body{width:min(440px,100%);padding:28px 16px;border:1px solid rgba(255,255,255,.14);border-radius:20px;background:#0b121a}
#ttbSoloV210 .ttb-v211-loader-body .primary{width:100%;margin-top:16px}
#ttbSoloV210 .ttb-v211-back{position:absolute;left:14px;top:14px;width:42px;height:42px;border:1px solid rgba(255,255,255,.2);border-radius:12px;background:#121b26;color:white;font-size:28px}
#ttbSoloV210 .ttb-v211-alert{color:#ff9fae;font-size:12px;margin-top:12px}

/* v21.5.5: server-only Solo action visuals. Never fabricate a defender. */
#ttbSoloV210 .battle-board-v11 .cypher-slot.ttb-v2155-spot-place,
#ttbSoloV210 .battle-board-v11 .cypher-slot.ttb-v2155-spot-takeover{
 animation:ttb2155PlaceLight .95s ease-out both;
}
#ttbSoloV210 .battle-board-v11 .cypher-slot.ttb-v2155-spot-place::after,
#ttbSoloV210 .battle-board-v11 .cypher-slot.ttb-v2155-spot-takeover::after{
 content:"";position:absolute;inset:0;border:2px solid rgba(104,239,255,.85);
 border-radius:inherit;box-shadow:0 0 24px rgba(65,223,249,.45);
 animation:ttb2155Ripple 1s ease-out both;pointer-events:none;
}
#ttbSoloV210 .battle-board-v11 .cypher-slot.ttb-v2155-spot-place .field-card,
#ttbSoloV210 .battle-board-v11 .cypher-slot.ttb-v2155-spot-takeover .field-card{
 animation:ttb2155CardIn .7s ease-out both;
}
#ttbSoloV210 .battle-board-v11 .cypher-slot.ttb-v2155-spot-gear{
 animation:ttb2155GearGlow 1s ease-out both;
}
#ttbSoloV210 .battle-board-v11 .cypher-slot.ttb-v2155-spot-burn{
 animation:ttb2155BurnGlow 1s ease-out both;
}
@keyframes ttb2155PlaceLight{0%{box-shadow:inset 0 0 8px rgba(80,235,251,.15)}35%{box-shadow:0 0 28px rgba(80,235,251,.55),inset 0 0 24px rgba(80,235,251,.26)}100%{box-shadow:inset 0 0 14px rgba(80,235,251,.05)}}
@keyframes ttb2155Ripple{0%{opacity:0;transform:scale(.84)}28%{opacity:1}100%{opacity:0;transform:scale(1.08)}}
@keyframes ttb2155CardIn{0%{opacity:.3;filter:brightness(1.8) saturate(1.4)}50%{opacity:1;filter:brightness(1.32)}100%{filter:none}}
@keyframes ttb2155GearGlow{0%{box-shadow:inset 0 0 0 rgba(255,207,92,0)}38%{box-shadow:0 0 26px rgba(255,207,92,.42),inset 0 0 25px rgba(255,207,92,.14)}100%{box-shadow:none}}
@keyframes ttb2155BurnGlow{0%{box-shadow:none}35%{box-shadow:0 0 28px rgba(255,106,45,.44),inset 0 0 24px rgba(255,106,45,.25)}100%{box-shadow:none}}
@media(prefers-reduced-motion:reduce){#ttbSoloV210 .cypher-slot[class*="ttb-v2155-spot-"] ,#ttbSoloV210 .cypher-slot[class*="ttb-v2155-spot-"]::after,#ttbSoloV210 .cypher-slot[class*="ttb-v2155-spot-"] .field-card{animation:none!important}}

/* v21.5.6 — Solo dialogs are direct <body> children. The server Solo arena
   is z-index 120, so generic modals at z-index 80 were hidden UNDER it.
   Scope this fix to an active Solo battle; do not change other battle layers. */
body:has(#ttbSoloV210 .battle-fullscreen-v11) > .modal-backdrop,
body > .modal-backdrop.ttb-v211-history,
body > .modal-backdrop.ttb-v211-burn {
  z-index:240!important;
  pointer-events:auto!important;
}
body > .modal-backdrop.ttb-v211-history .modal,
body > .modal-backdrop.ttb-v211-burn .modal {
  max-height:calc(100dvh - 24px);
  overflow-y:auto;
  overscroll-behavior:contain;
}

/* Keep the Solo history and Burn It dialog readable on narrow phones. */
body > .modal-backdrop.ttb-v211-history .modal,
body > .modal-backdrop.ttb-v211-burn .modal{padding:18px 16px 16px;}
body > .modal-backdrop.ttb-v211-history .action-history-v13{margin-top:12px;max-height:min(48dvh,460px);overflow-y:auto;overscroll-behavior:contain;}
@media(max-width:360px){body > .modal-backdrop.ttb-v211-history .modal,body > .modal-backdrop.ttb-v211-burn .modal{padding:15px 12px;}}

/* v21.5.20 — common footer and readable Solo arena on mobile */
#ttbSoloV210 .battle-fullscreen-v11{
 grid-template-rows:42px 25px 26px minmax(120px,1fr) 27px 34px 126px 44px 40px!important;
}
#ttbSoloV210 .ttb21520-solo-tools{
 display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;
 gap:6px!important;width:100%!important;min-width:0!important;align-items:stretch!important;
}
#ttbSoloV210 .ttb21520-solo-tools button{
 min-width:0!important;width:100%!important;min-height:35px!important;
 display:flex!important;align-items:center!important;justify-content:center!important;
 gap:6px!important;padding:5px 6px!important;border-radius:13px!important;
 color:#d9f7ff!important;background:#0d2232!important;border:1px solid #31596c!important;
 box-sizing:border-box!important;white-space:nowrap!important;
}
#ttbSoloV210 .ttb21520-solo-tools button:first-child{border-color:#36c6d8!important;background:#103340!important}
#ttbSoloV210 .ttb21520-solo-tools .ttb21520-danger{border-color:#a64156!important;background:#45131e!important;color:#ffccd6!important}
#ttbSoloV210 .ttb21520-solo-tools button>span{font-size:16px;line-height:1}
#ttbSoloV210 .ttb21520-solo-tools button>small{font-size:8px;font-weight:900;letter-spacing:.05em;overflow:hidden;text-overflow:ellipsis}
#ttbSoloV210 .battle-energy-v11 .energy-chip{cursor:pointer;width:20px!important;height:23px!important;min-width:20px!important;flex-basis:20px!important;transform-origin:50% 50%}
#ttbSoloV210 .battle-energy-v11 .energy-chip.used{transform:rotate(38deg)!important}
@media(max-height:710px){#ttbSoloV210 .battle-fullscreen-v11{grid-template-rows:38px 21px 23px minmax(95px,1fr) 23px 27px 96px 38px 36px!important;gap:4px!important}}
@media(max-width:360px){#ttbSoloV210 .ttb21520-solo-tools{gap:4px!important}#ttbSoloV210 .ttb21520-solo-tools button>small{font-size:7px}}
.ttb21520-energy-preview,.ttb21520-solo-reactions{position:fixed;inset:0;z-index:100130;background:#020810e8;display:grid;place-items:center;padding:18px;box-sizing:border-box;color:#ecfaff}
.ttb21520-energy-preview>div{position:relative;width:min(380px,92vw);padding:48px 14px 18px;border-radius:20px;background:#0b1928;border:1px solid #396f87;display:grid;place-items:center}
.ttb21520-energy-preview img{width:auto;max-width:100%;max-height:65dvh;object-fit:contain;aspect-ratio:1102/1500}
.ttb21520-energy-preview button{position:absolute;top:8px;right:10px;border:1px solid #48697c;background:#122e41;color:white;border-radius:10px;padding:5px 12px;font-size:24px}
.ttb21520-solo-reactions section{width:min(380px,100%);padding:18px;background:#0a1a29;border-radius:20px;border:1px solid #3a9eb4}
.ttb21520-solo-reactions h3{margin:0 0 7px;font-size:17px}.ttb21520-solo-reactions p{font-size:11px;color:#b6cbd6}
.ttb21520-solo-reactions section>div{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}
.ttb21520-solo-reactions [data-react]{background:#10293c;border:1px solid #3f6577;border-radius:12px;color:#fff;padding:7px;display:grid;justify-items:center;gap:5px}
.ttb21520-solo-reactions [data-react] img{width:70px;height:75px;object-fit:contain;max-width:100%}.ttb21520-solo-reactions [data-react] small{font-size:10px}
.ttb21520-solo-reactions [data-close]{display:block;margin-top:12px;width:100%;height:39px;background:#e7faff;border:0;border-radius:10px;color:#081622;font-weight:900}
.ttb21520-solo-pop{position:fixed;z-index:100131;top:20%;left:50%;transform:translateX(-50%);background:#0b1c2f;border:1px solid #43cce0;border-radius:15px;padding:10px;display:grid;justify-items:center;gap:5px;box-shadow:0 10px 40px #0009;pointer-events:none}
.ttb21520-solo-pop img{height:95px;width:80px;object-fit:contain}.ttb21520-solo-pop strong{white-space:nowrap;font-size:11px}

/* v21.6.1 — Solo server CPU portraits, visible on small Android viewports. */
#ttbSoloV210 .battle-player-v11.cpu{display:grid;grid-template-columns:30px minmax(0,1fr);grid-template-rows:15px 12px;column-gap:6px;align-items:center;min-width:0;padding:3px 5px;height:42px;overflow:hidden}
#ttbSoloV210 .battle-player-v11.cpu .ttb216-rival-avatar{grid-column:1;grid-row:1 / 3;float:none;width:29px;height:29px;margin:0;object-fit:cover;border-radius:50%;border:1px solid #5cdae9;display:block}
#ttbSoloV210 .battle-player-v11.cpu>b{grid-column:2;grid-row:1;font-size:9px;min-width:0;line-height:13px}
#ttbSoloV210 .battle-player-v11.cpu>span{grid-column:2;grid-row:2;font-size:6px;min-width:0;margin:0;line-height:10px}
body>.modal-backdrop.ttb-v211-history .action-row-v13{display:flex;align-items:center;gap:7px}
body>.modal-backdrop.ttb-v211-history .ttb216-rival-avatar{width:26px;height:26px;flex:0 0 26px;border-radius:50%;object-fit:cover;border:1px solid #5cdae9}

/* v21.6.3: both player identities and per-action avatar in Server Solo */
#ttbSoloV210 .battle-top-v11 .battle-player-v11:not(.cpu){display:grid;grid-template-columns:30px minmax(0,1fr);grid-template-rows:15px 12px;column-gap:6px;align-items:center;min-width:0;overflow:hidden;padding:3px 5px;height:42px}
#ttbSoloV210 .battle-player-v11:not(.cpu)>.ttb216-player-avatar,#ttbSoloV210 .battle-player-v11:not(.cpu)>.ttb216-player-avatar-wrap{grid-column:1;grid-row:1 / 3;width:29px;height:29px;object-fit:cover;border-radius:50%;overflow:hidden;border:1px solid #40d6f0;display:grid;place-items:center}
#ttbSoloV210 .battle-player-v11:not(.cpu)>b{grid-column:2;grid-row:1;min-width:0;font-size:9px;line-height:13px}
#ttbSoloV210 .battle-player-v11:not(.cpu)>span:not(.ttb216-player-avatar):not(.ttb216-player-avatar-wrap){grid-column:2;grid-row:2;min-width:0;font-size:6px;line-height:10px}
.ttb-v211-history .action-row-v13 .ttb216-player-avatar,.ttb-v211-history .action-row-v13 .ttb216-rival-avatar,.ttb-v211-history .action-row-v13 .ttb216-player-avatar-wrap{flex:0 0 27px;width:27px;height:27px;object-fit:cover;border-radius:50%;overflow:hidden;border:1px solid #56dce9;display:inline-grid;place-items:center;font-size:13px}
.ttb216-player-avatar-wrap img{width:100%;height:100%;object-fit:cover}

/* v21.7.7: authoritative Solo Foundation inspection with all Gear artwork */
.ttb2177-solo-inspect{position:fixed;inset:0;z-index:2147483000;background:#030810e8;backdrop-filter:blur(8px);display:flex;justify-content:center;align-items:center;padding:12px;box-sizing:border-box}
.ttb2177-solo-inspect-panel{position:relative;display:flex;flex-direction:column;align-items:center;gap:7px;width:min(96vw,470px);max-height:calc(100dvh - 24px);overflow-y:auto;padding:13px;border-radius:24px;background:linear-gradient(#101a26,#060b11);border:1px solid #ffffff30;color:#fff;box-sizing:border-box;text-align:center}
.ttb2177-solo-close{position:absolute;right:9px;top:9px;z-index:2;background:#1c2c3c;border:1px solid #ffffff55;border-radius:50%;color:#fff;font-size:25px;width:40px;height:40px}
.ttb2177-solo-main{display:block;width:auto;max-width:100%;height:auto;max-height:50dvh;object-fit:contain;border-radius:9px}
.ttb2177-solo-inspect-panel>strong{font-size:20px}.ttb2177-solo-inspect-panel>small{font-size:10px;color:#afcce3}
.ttb2177-solo-equipped{width:100%;text-align:left}.ttb2177-solo-equipped h3{font-size:11px;color:#70d8ff;letter-spacing:.1em;margin:5px 0}
.ttb2177-solo-gear-list{display:flex;gap:6px;overflow-x:auto;padding-bottom:6px;scroll-snap-type:x proximity}
.ttb2177-solo-gear-list figure{flex:0 0 clamp(57px,17vw,79px);margin:0;scroll-snap-align:start;text-align:center}.ttb2177-solo-gear-list img{display:block;width:100%;aspect-ratio:1102/1500;object-fit:contain;border-radius:6px}.ttb2177-solo-gear-list figcaption{font-size:9px;line-height:1.35;margin-top:3px;overflow-wrap:anywhere}.ttb2177-solo-gear-list b{color:#59dcff}.ttb2177-solo-empty{font-size:10px;color:#7c90a5}


/* v23.28 — Solo/CPU battle uses the same responsive field strategy */
#ttbSoloV210 .battle-fullscreen-v11{height:100svh!important;min-height:100svh!important;grid-template-rows:auto auto auto minmax(0,1fr) auto clamp(96px,18svh,126px) clamp(38px,7svh,44px) clamp(30px,6svh,36px)!important;align-content:stretch!important}
#ttbSoloV210 .battle-message-v11{display:none!important}
#ttbSoloV210 .battle-hand-v11{padding:4px 4px 2px!important;overflow:visible!important}
#ttbSoloV210 .battle-hand-v11 .zone-title{display:none!important}
#ttbSoloV210 .battle-hand-v11 .battle-hand{min-height:90px!important;height:auto!important;padding-top:6px!important;padding-bottom:1px!important}
#ttbSoloV210 .battle-board-v11{height:100%!important;min-height:0!important;align-self:stretch!important}
#ttbSoloV210 .battle-board-v11 .cypher-slots{height:100%!important;align-items:stretch!important}
#ttbSoloV210 .battle-board-v11 .cypher-slot{height:100%!important}
@media(max-height:710px){#ttbSoloV210 .battle-fullscreen-v11{grid-template-rows:auto auto auto minmax(0,1fr) auto clamp(82px,16svh,102px) clamp(34px,6svh,40px) clamp(28px,5.5svh,32px)!important;gap:4px!important}#ttbSoloV210 .battle-hand-v11 .battle-hand{min-height:76px!important}}
