/* Ultimate PIMD v10.08 — Hit Help approved-mockup fidelity desktop composition */
body[data-page="battle"] {
  --hh-pink:#ff3f9b;
  --hh-pink-bright:#ff72bd;
  --hh-blue:#43b9ff;
  --hh-cyan:#55deff;
  --hh-violet:#9d55ff;
  --hh-green:#6fe397;
  --hh-gold:#f6bd57;
  --hh-red:#ff5979;
  --hh-ink:#02050d;
  --hh-panel:rgba(4,8,19,.94);
  --hh-panel-soft:rgba(7,11,26,.88);
  --hh-line:rgba(255,68,159,.54);
  --hh-blue-line:rgba(67,185,255,.50);
}
body[data-page="battle"] .main-content {
  padding-top:12px!important;
  background:
    radial-gradient(circle at 67% 7%,rgba(88,43,189,.11),transparent 31rem),
    radial-gradient(circle at 29% 42%,rgba(255,49,145,.08),transparent 32rem),
    #02040b!important;
}
body[data-page="battle"] #page-battle.hit-help-rebuild {
  display:none;
  width:100%;
  max-width:none;
  gap:10px;
  padding:0;
  color:#fff8fc;
  font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
body[data-page="battle"] #page-battle.hit-help-rebuild.active { display:grid!important; }
.hh-sr-only {
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  padding:0!important;
  margin:-1px!important;
  overflow:hidden!important;
  clip:rect(0,0,0,0)!important;
  white-space:nowrap!important;
  border:0!important;
}
.hh-panel {
  border:1px solid rgba(255,68,159,.66);
  border-radius:11px;
  background:
    radial-gradient(circle at 92% -12%,rgba(255,54,151,.17),transparent 16rem),
    radial-gradient(circle at 12% 112%,rgba(71,120,255,.055),transparent 18rem),
    linear-gradient(180deg,rgba(8,10,24,.98),rgba(2,6,15,.98));
  box-shadow:inset 0 1px rgba(255,255,255,.055),inset 0 0 22px rgba(255,48,145,.025),0 0 26px rgba(255,37,140,.10);
}
.hh-kicker,
.hh-label {
  color:var(--hh-pink-bright);
  font-size:.68rem;
  font-weight:900;
  letter-spacing:.115em;
  text-transform:uppercase;
}
.hh-header {
  display:grid;
  grid-template-columns:minmax(320px,.84fr) minmax(560px,1.16fr);
  gap:14px;
  min-height:124px;
  padding:0!important;
  border:0!important;
  background:transparent!important;
  box-shadow:none!important;
}
.hh-heading {
  position:relative;
  display:flex;
  flex-direction:column;
  justify-content:center;
  min-width:0;
  padding:8px 12px;
  overflow:hidden;
}
.hh-heading::before {
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  opacity:.64;
  background:
    linear-gradient(90deg,rgba(2,4,11,.03),rgba(2,4,11,.10) 58%,rgba(2,4,11,.74)),
    url("../images/ui/my-build-sakura-city-backdrop-v896.png?v=9.19") 38% 58%/cover no-repeat;
  filter:saturate(1.24) contrast(1.08) brightness(1.08);
}
.hh-heading::after {
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  opacity:.76;
  background:
    radial-gradient(circle at 74% 25%,rgba(255,84,171,.56) 0 2px,transparent 3px),
    radial-gradient(circle at 86% 64%,rgba(255,84,171,.44) 0 1px,transparent 2px),
    linear-gradient(90deg,transparent 64%,rgba(255,48,145,.055));
}
.hh-heading > * { position:relative; z-index:1; }
.hh-concept-badge {
  align-self:flex-start;
  margin:0 0 2px;
  padding:4px 13px 3px;
  border:1px solid rgba(255,112,190,.62);
  border-radius:7px;
  background:rgba(67,20,58,.46);
  color:#f28bc3!important;
  font-size:.67rem!important;
  font-weight:900;
  letter-spacing:.16em;
  line-height:1;
  text-transform:uppercase;
  box-shadow:inset 0 0 12px rgba(255,71,164,.12),0 0 12px rgba(255,55,154,.12);
}
.hh-heading h1 {
  display:flex;
  align-items:center;
  gap:12px;
  margin:5px 0 4px!important;
  color:#fff!important;
  font-family:"Arial Narrow","Roboto Condensed",Impact,sans-serif;
  font-size:clamp(2.8rem,4vw,4.8rem)!important;
  font-weight:900;
  letter-spacing:.025em!important;
  line-height:.9!important;
  text-transform:uppercase;
  text-shadow:0 0 18px rgba(255,255,255,.12);
}
.hh-heading h1 img { width:42px; height:42px; object-fit:contain; filter:drop-shadow(0 0 10px rgba(255,62,157,.7)); }
.hh-heading p { margin:5px 0 0!important; color:#a69eaa!important; font-size:.92rem; }
.hh-build {
  display:grid;
  grid-template-columns:minmax(150px,.75fr) minmax(0,2.25fr);
  grid-template-rows:auto 1fr;
  gap:9px 12px;
  min-width:0;
  padding:11px 13px;
}
.hh-build-title {
  grid-column:1 / -1;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.hh-build-title strong { color:var(--hh-pink-bright); font-size:.7rem; letter-spacing:.12em; }
.hh-build-edit {
  border:0;
  background:transparent;
  color:#af8aa1;
  font-size:.7rem;
  cursor:pointer;
}
.hh-current-build {
  position:relative;
  display:grid;
  align-content:center;
  gap:2px;
  min-width:0;
  padding:10px 12px;
  border:1px solid rgba(255,82,168,.82);
  border-radius:8px;
  background:linear-gradient(135deg,rgba(255,45,145,.16),rgba(5,8,18,.90));
  box-shadow:inset 0 0 20px rgba(255,45,145,.10),0 0 18px rgba(255,45,145,.15);
}
.hh-current-build .hh-crown {
  position:absolute;
  top:10px;
  right:11px;
  width:18px;
  height:18px;
  object-fit:contain;
}
.hh-current-build span { color:#bd9cae; font-size:.61rem; letter-spacing:.08em; text-transform:uppercase; }
.hh-current-build strong { overflow:hidden; font-size:1.22rem; text-overflow:ellipsis; white-space:nowrap; }
.hh-current-build small { overflow:hidden; color:#8f8794; font-size:.65rem; text-overflow:ellipsis; white-space:nowrap; }
.hh-build-metrics {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  min-width:0;
  border:1px solid rgba(255,255,255,.075);
  border-radius:8px;
  background:rgba(3,7,16,.64);
}
.hh-build-metric {
  display:grid;
  grid-template-columns:40px minmax(0,1fr);
  align-content:center;
  gap:1px 8px;
  min-width:0;
  padding:9px 12px;
  border-right:1px solid rgba(255,255,255,.09);
}
.hh-build-metric:last-child { border-right:0; }
.hh-build-metric img { grid-row:1 / 3; align-self:center; width:34px; height:34px; object-fit:contain; filter:drop-shadow(0 0 7px currentColor); }
.hh-build-metric span { color:#9a91a0; font-size:.59rem; font-weight:800; letter-spacing:.08em; text-transform:uppercase; }
.hh-build-metric strong { overflow:hidden; color:#f3e8f0; font-size:1.08rem; text-overflow:ellipsis; white-space:nowrap; }
.hh-build-metric.int span { color:var(--hh-blue); }
.hh-build-metric.now span { color:var(--hh-green); }
.hh-build-metric.now strong { color:#d9ffe5; }
.hh-build-metric.now::before {
  content:"";
  grid-row:1 / 3;
  align-self:center;
  width:13px;
  height:13px;
  margin-left:9px;
  border:2px solid var(--hh-green);
  border-radius:50%;
  box-shadow:0 0 15px rgba(111,227,151,.78);
}
.hh-build-metric.now { grid-template-columns:40px minmax(0,1fr); }

.hh-form { display:grid; gap:10px; }
.hh-duel {
  position:relative;
  min-height:320px;
  max-height:480px;
  aspect-ratio:4.30 / 1;
  display:grid;
  grid-template-columns:minmax(0,1.24fr) 156px minmax(0,1fr);
  padding-right:14%;
  overflow:hidden;
  border:1px solid rgba(255,62,155,.76);
  border-radius:11px;
  background:#02040b;
  box-shadow:0 0 34px rgba(255,34,137,.15),inset 0 0 22px rgba(255,44,147,.025);
}
.hh-duel-art {
  position:absolute;
  inset:0 auto 0 0;
  z-index:0;
  width:86%;
  height:100%;
  object-fit:cover;
  object-position:center;
  opacity:1;
  filter:saturate(1.20) contrast(1.08) brightness(1.14);
  transform:scaleX(1.10);
  transform-origin:center;
}
.hh-duel::after {
  content:"";
  position:absolute;
  inset:0;
  z-index:1;
  pointer-events:none;
  background:
    radial-gradient(circle at 45.7% 50%,rgba(255,255,255,.82) 0 1px,rgba(255,118,203,.48) 2px,rgba(83,151,255,.24) 7px,transparent 36px),
    linear-gradient(90deg,rgba(2,4,11,0),rgba(2,4,11,.02) 28%,rgba(2,4,11,.06) 46%,rgba(2,4,11,.04) 54%,rgba(2,4,11,.02) 72%,rgba(2,4,11,0)),
    linear-gradient(180deg,rgba(2,4,11,0),transparent 48%,rgba(2,4,11,.04));
}
.hh-fighter,
.hh-matchup,
.hh-opponent-rail { position:relative; z-index:2; min-width:0; }
.hh-fighter {
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  gap:14px;
  padding:clamp(24px,1.6vw,34px) 24px;
}
.hh-fighter.you { padding-left:50%; padding-right:4%; }
.hh-fighter.opponent { padding-left:4%; padding-right:50%; text-align:right; }
.hh-fighter-head { display:grid; gap:2px; }
.hh-fighter.opponent .hh-fighter-head { justify-items:end; }
.hh-fighter-head span { color:var(--hh-pink-bright); font-size:.68rem; font-weight:900; letter-spacing:.09em; }
.hh-fighter-head strong {
  max-width:100%;
  overflow:hidden;
  color:#f4eaf1;
  font-size:1.12rem;
  font-weight:700;
  letter-spacing:.055em;
  text-overflow:ellipsis;
  text-transform:uppercase;
  white-space:nowrap;
}
.hh-fighter-head small {
  width:max-content;
  padding:3px 12px;
  border:1px solid rgba(255,58,153,.45);
  border-radius:4px;
  color:#ff8fc7;
  font-size:.6rem;
  text-transform:uppercase;
}
.hh-fighter.opponent .hh-fighter-head span { color:#d37cff; }
.hh-fighter.opponent .hh-fighter-head small { border-color:rgba(179,78,255,.48); color:#d594ff; }
body[data-page="battle"] .hh-opponent-name {
  width:min(100%,220px);
  padding:0 0 4px!important;
  border:0!important;
  border-bottom:1px solid rgba(202,105,255,.45)!important;
  border-radius:0!important;
  outline:0;
  background:transparent!important;
  color:#f6ecfa!important;
  font-size:1.12rem!important;
  font-weight:750;
  letter-spacing:.045em;
  text-align:right;
  text-transform:uppercase;
  box-shadow:none!important;
}
.hh-power-stack { display:grid; gap:11px; }
.hh-power-row { display:grid; grid-template-columns:42px minmax(0,1fr); gap:0 10px; align-items:center; }
.hh-fighter.opponent .hh-power-row { grid-template-columns:minmax(0,1fr) 42px; }
.hh-power-row img { grid-row:1 / 3; width:38px; height:38px; object-fit:contain; filter:drop-shadow(0 0 8px currentColor); }
.hh-fighter.opponent .hh-power-row img { grid-column:2; }
.hh-power-copy { min-width:0; }
.hh-fighter.opponent .hh-power-copy { text-align:left; }
.hh-power-copy span { display:block; color:#ff6bb4; font-size:.68rem; font-weight:850; letter-spacing:.08em; text-transform:uppercase; }
.hh-power-copy strong,
.hh-power-copy output { display:block; overflow:hidden; color:#fff0f7; font-size:clamp(1.34rem,1.35vw,1.70rem); text-overflow:ellipsis; white-space:nowrap; }
.hh-power-copy.int span { color:var(--hh-blue); }
body[data-page="battle"] .hh-power-input {
  width:100%;
  min-width:0;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  outline:0;
  background:transparent!important;
  color:#f4e7ef!important;
  font-size:clamp(1.28rem,1.32vw,1.66rem)!important;
  text-align:right;
  box-shadow:none!important;
}
body[data-page="battle"] .hh-fighter.opponent .hh-power-input { text-align:left; }
.hh-power-track {
  grid-column:2;
  position:relative;
  height:8px;
  margin-top:6px;
  overflow:hidden;
  border-radius:99px;
  background:rgba(255,255,255,.10);
}
.hh-fighter.opponent .hh-power-track { grid-column:1; }
.hh-power-track i {
  display:block;
  width:0;
  height:100%;
  border-radius:inherit;
  background:linear-gradient(90deg,#ff3c96,#ff7ebd);
  box-shadow:0 0 10px rgba(255,65,157,.85);
  transition:width .25s ease;
}
.hh-power-row.int .hh-power-track i {
  background:linear-gradient(90deg,#35a8ff,#6de2ff);
  box-shadow:0 0 10px rgba(55,180,255,.85);
}
.hh-fighter-foot {
  display:grid;
  grid-template-columns:1fr auto;
  gap:6px 10px;
  color:#8e8791;
  font-size:.64rem;
}
.hh-fighter-foot strong { color:#ff6aae; font-weight:800; }
.hh-fighter.opponent .hh-fighter-foot { text-align:left; }
.hh-fighter.opponent .hh-fighter-foot strong { color:#c47dff; text-align:right; }
.hh-fighter-foot .wide { grid-column:1 / -1; }

.hh-matchup {
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:space-between;
  gap:0;
  padding-block:clamp(20px,1.5vw,30px);
  isolation:isolate;
  border-inline:1px solid rgba(255,255,255,.06);
  background:linear-gradient(180deg,rgba(4,7,16,.18),rgba(3,6,14,.65));
}
.hh-matchup::before {
  content:"";
  position:absolute;
  inset:0;
  z-index:0;
  pointer-events:none;
  background:
    linear-gradient(to bottom right,transparent 49.55%,rgba(255,61,151,.34) 49.85%,transparent 50.15%) left top / 50% 50% no-repeat,
    linear-gradient(to top right,transparent 49.55%,rgba(255,61,151,.28) 49.85%,transparent 50.15%) left bottom / 50% 50% no-repeat,
    linear-gradient(to bottom left,transparent 49.55%,rgba(75,168,255,.31) 49.85%,transparent 50.15%) right top / 50% 50% no-repeat,
    linear-gradient(to top left,transparent 49.55%,rgba(75,168,255,.25) 49.85%,transparent 50.15%) right bottom / 50% 50% no-repeat;
}
.hh-matchup > * { position:relative; z-index:1; }
.hh-matchup > span { color:#9c939f; font-size:.66rem; font-weight:850; letter-spacing:.09em; text-transform:uppercase; }
.hh-action-buttons { display:grid; gap:7px; }
.hh-action-button {
  width:clamp(76px,5vw,98px);
  height:clamp(76px,5vw,98px);
  display:grid;
  place-items:center;
  gap:2px;
  padding:8px;
  border:1px solid rgba(255,103,184,.82);
  border-radius:50%;
  background:radial-gradient(circle,rgba(255,45,145,.22),rgba(9,9,22,.92) 68%);
  color:#ff8bc7;
  box-shadow:0 0 24px rgba(255,53,151,.40),inset 0 0 25px rgba(255,53,151,.18);
  cursor:pointer;
}
.hh-action-button img { width:clamp(31px,1.8vw,38px); height:clamp(31px,1.8vw,38px); object-fit:contain; }
.hh-action-button span { font-size:.64rem; font-weight:850; letter-spacing:.08em; }
.hh-action-button[data-hit-stat="intelligence"] {
  margin:-5px 0 -3px;
  border-color:rgba(72,181,255,.58);
  border-radius:11px;
  color:#60caff;
  transform:rotate(45deg) scale(.78);
}
.hh-action-button[data-hit-stat="intelligence"] > * { transform:rotate(-45deg) scale(1.16); }
.hh-action-button[aria-pressed="true"] {
  border-color:#ff7bbd;
  background:radial-gradient(circle,rgba(255,60,154,.22),rgba(8,9,21,.94) 70%);
  box-shadow:0 0 17px rgba(255,53,151,.52),inset 0 0 18px rgba(255,53,151,.14);
}
.hh-action-button[data-hit-stat="intelligence"][aria-pressed="true"] {
  border-color:#64caff;
  background:radial-gradient(circle,rgba(55,164,255,.22),rgba(8,9,21,.94) 70%);
  box-shadow:0 0 17px rgba(60,181,255,.5),inset 0 0 18px rgba(60,181,255,.13);
}
.hh-versus { color:#fff2f9; font-size:1.18rem; font-weight:900; font-style:italic; text-shadow:0 0 10px rgba(255,255,255,.20); }
.hh-result-toggle { display:grid; grid-template-columns:1fr 1fr; gap:5px; width:126px; }
.hh-result-toggle button {
  min-height:28px;
  padding:4px;
  border:1px solid rgba(255,255,255,.17);
  border-radius:5px;
  background:rgba(2,5,13,.80);
  color:#948d98;
  font-size:.58rem;
  font-weight:900;
  letter-spacing:.05em;
  cursor:pointer;
}
.hh-result-toggle button[aria-pressed="true"][data-hit-result="win"] { border-color:rgba(111,227,151,.65); color:#8af0aa; background:rgba(64,182,102,.13); }
.hh-result-toggle button[aria-pressed="true"][data-hit-result="loss"] { border-color:rgba(255,83,122,.68); color:#ff86a2; background:rgba(255,58,105,.13); }
.hh-hit-time { color:#938a95; font-size:.60rem; text-align:center; }

.hh-opponent-rail {
  position:absolute;
  top:0;
  right:0;
  bottom:0;
  width:14%;
  display:flex;
  flex-direction:column;
  gap:clamp(18px,1.5vw,28px);
  padding:clamp(22px,1.6vw,30px) clamp(14px,1vw,20px) clamp(12px,.8vw,16px);
  border-left:1px solid rgba(255,67,158,.58);
  background:
    radial-gradient(circle at 25% 42%,rgba(255,45,145,.07),transparent 12rem),
    linear-gradient(180deg,rgba(5,8,19,.92),rgba(3,5,12,.97));
}
.hh-opponent-rail strong { color:#ff7abd; font-size:clamp(.72rem,.72vw,.90rem); letter-spacing:.10em; }
.hh-rail-stat { display:grid; grid-template-columns:clamp(22px,1.45vw,28px) minmax(0,1fr); gap:3px 9px; align-items:center; }
.hh-rail-stat img { grid-row:1 / 3; width:clamp(24px,1.45vw,30px); height:clamp(24px,1.45vw,30px); object-fit:contain; filter:drop-shadow(0 0 7px currentColor); }
.hh-rail-stat span { color:#ff6bb3; font-size:clamp(.68rem,.68vw,.82rem); font-weight:850; }
.hh-rail-stat b { color:#f1e5ed; font-size:clamp(1.04rem,1.02vw,1.28rem); }
.hh-rail-stat.int span { color:#53bfff; }

.hh-relation {
  display:grid;
  grid-template-columns:clamp(30px,1.8vw,36px) minmax(0,1fr);
  grid-template-rows:auto 1fr auto;
  gap:2px 9px;
  min-height:clamp(96px,6.2vw,138px);
  margin-top:auto;
  padding:clamp(14px,1vw,20px) clamp(10px,.8vw,16px);
  border:1px solid rgba(255,80,165,.55);
  border-radius:7px;
  background:linear-gradient(135deg,rgba(255,45,145,.07),rgba(7,8,18,.68));
}
.hh-relation > span { grid-column:1 / -1; color:#ff5fab; font-size:.56rem; font-weight:850; letter-spacing:.06em; }
.hh-relation svg { grid-row:2 / 4; align-self:center; width:clamp(28px,1.7vw,34px); height:clamp(28px,1.7vw,34px); color:#ff62ac; filter:drop-shadow(0 0 6px rgba(255,70,156,.4)); }
.hh-relation b { align-self:end; color:#e6dbe3; font-size:.72rem; }
.hh-relation small { align-self:start; color:#837b85; font-size:.57rem; }

.hh-midrow {
  display:grid;
  grid-template-columns:1.08fr .58fr .78fr;
  gap:10px;
}
.hh-result-signal {
  display:grid;
  grid-template-columns:1.1fr .7fr .9fr;
  min-height:142px;
  padding:16px 18px;
}
.hh-result-signal > div { display:grid; align-content:center; min-width:0; border-right:1px solid rgba(255,255,255,.07); padding-right:14px; }
.hh-result-signal > div + div { padding-left:16px; }
.hh-result-signal > div:last-child { border-right:0; }
.hh-result-signal span { color:var(--hh-pink-bright); font-size:.62rem; font-weight:900; letter-spacing:.08em; }
.hh-result-signal strong { overflow:hidden; margin-top:7px; color:#d6cbd3; font-size:1.85rem; text-overflow:ellipsis; white-space:nowrap; }
.hh-result-signal small { margin-top:5px; color:#807985; font-size:.66rem; }
.hh-result-signal .hh-outcome strong { color:#ff5b96; font-family:"Arial Narrow",Impact,sans-serif; font-size:2rem; letter-spacing:.035em; }
.hh-result-signal[data-result="win"] .hh-outcome strong { color:#79e7a0; }
.hh-context { min-height:142px; padding:12px 14px; }
.hh-context-grid { display:grid; grid-template-columns:1fr; gap:4px; margin-top:8px; }
.hh-context-grid > label {
  display:grid;
  grid-template-columns:minmax(92px,.9fr) minmax(72px,1fr);
  align-items:center;
  min-height:24px;
  padding:0 7px;
  border:1px solid rgba(255,255,255,.075);
  border-radius:5px;
  background:rgba(2,6,14,.58);
  color:#918893;
  font-size:.61rem;
}
.hh-context-label { display:flex; align-items:center; gap:6px; min-width:0; }
.hh-context-label svg { width:15px; height:15px; flex:0 0 auto; }
.hh-context-grid > label:nth-child(1) .hh-context-label { color:var(--hh-green); }
.hh-context-grid > label:nth-child(2) .hh-context-label { color:var(--hh-blue); }
.hh-context-grid > label:nth-child(3) .hh-context-label { color:var(--hh-gold); }
.hh-context-grid > label:nth-child(4) .hh-context-label { color:var(--hh-pink-bright); }
body[data-page="battle"] .hh-context-grid > label input,
body[data-page="battle"] .hh-context-grid > label textarea {
  min-width:0;
  height:22px;
  padding:2px 4px!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  color:#d8cfd6!important;
  font-size:.64rem!important;
  text-align:right;
  box-shadow:none!important;
}
body[data-page="battle"] .hh-context-grid > label textarea { resize:none; }
.hh-advanced-grid label {
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(64px,.55fr);
  align-items:center;
  gap:7px;
  color:#918893;
  font-size:.61rem;
}
.hh-advanced-grid input,
.hh-advanced-grid select {
  min-width:0;
  height:28px;
  padding:4px 7px!important;
  border:1px solid rgba(255,255,255,.10)!important;
  border-radius:5px!important;
  background:rgba(2,6,14,.76)!important;
  color:#d8cfd6!important;
  font-size:.64rem!important;
  box-shadow:none!important;
}
.hh-advanced {
  grid-column:1 / -1;
  margin-top:2px;
}
.hh-advanced summary {
  color:#8e8390;
  font-size:.58rem;
  cursor:pointer;
}
.hh-advanced-grid { display:grid; grid-template-columns:1fr 1fr; gap:7px 10px; margin-top:8px; }
.hh-save-panel {
  min-height:142px;
  display:grid;
  place-items:center;
  padding:14px;
  border-color:rgba(255,88,172,.86);
  box-shadow:0 0 26px rgba(255,43,143,.15),inset 0 0 24px rgba(255,48,149,.05);
  background:
    radial-gradient(circle at 50% 50%,rgba(255,52,153,.21),transparent 64%),
    url("../images/ui/icon-sakura-v916.png?v=9.16") 94% 12%/30px no-repeat,
    linear-gradient(180deg,rgba(14,8,22,.96),rgba(5,6,16,.97));
}
.hh-save-copy { text-align:center; }
.hh-save-copy strong { display:block; color:#ff70b5; font-size:.73rem; letter-spacing:.08em; }
.hh-save-copy small { display:block; margin:5px 0 11px; color:#9c8e9a; font-size:.63rem; }
.hh-submit {
  width:100%;
  min-height:48px;
  border:1px solid rgba(255,126,201,.94);
  border-radius:7px;
  background:
    url("../images/ui/icon-save-sakura-v916.png?v=9.16") calc(100% - 16px) 50%/25px no-repeat,
    linear-gradient(90deg,rgba(111,18,74,.58),rgba(255,56,153,.28),rgba(92,18,79,.58));
  color:white;
  font-size:.98rem;
  font-weight:750;
  box-shadow:0 0 27px rgba(255,57,155,.52),inset 0 0 22px rgba(255,93,177,.10);
  cursor:pointer;
}
.hh-submit:disabled { opacity:.55; cursor:wait; }

.hh-bottom {
  display:grid;
  grid-template-columns:minmax(0,1.18fr) minmax(170px,.42fr) minmax(0,1.14fr);
  gap:10px;
}
.hh-answer { min-height:226px; padding:14px 16px; }
.hh-answer-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.hh-answer-heading h2 { margin:0; color:#ff70b5; font-size:.78rem; letter-spacing:.08em; }
.answer-badge {
  padding:4px 8px;
  border:1px solid rgba(255,255,255,.12);
  border-radius:99px;
  color:#9f96a0;
  background:rgba(255,255,255,.035);
  font-size:.58rem;
}
#battleAnalysis { min-height:170px; }
#battleAnalysis.empty-state {
  display:grid;
  place-content:center;
  gap:5px;
  color:#8e8690;
  text-align:center;
}
#battleAnalysis.empty-state strong { color:#d9cdd5; }
.hh-analysis-live {
  display:grid;
  grid-template-columns:1.15fr .65fr .65fr .86fr;
  min-height:170px;
  margin-top:10px;
  border:1px solid rgba(255,255,255,.07);
  border-radius:7px;
  overflow:hidden;
}
.hh-analysis-live > div {
  display:grid;
  align-content:center;
  gap:6px;
  min-width:0;
  padding:12px;
  border-right:1px solid rgba(255,255,255,.07);
}
.hh-analysis-live > div:last-child { border-right:0; }
.hh-analysis-live span { color:#9a8f9a; font-size:.57rem; font-weight:800; letter-spacing:.06em; }
.hh-analysis-live strong { color:#e1d5de; font-size:.95rem; }
.hh-analysis-live p { margin:0; color:#8f8791; font-size:.65rem; line-height:1.4; }
.hh-analysis-live .reason strong { font-size:1.18rem; }
.hh-confidence-ring {
  width:66px;
  height:66px;
  display:grid;
  place-items:center;
  margin:auto;
  border:5px solid rgba(255,70,159,.62);
  border-radius:50%;
  color:white;
  box-shadow:0 0 12px rgba(255,55,151,.28),inset 0 0 10px rgba(255,55,151,.08);
}
.hh-risk-mark { color:var(--hh-gold)!important; font-size:1.02rem!important; }
.hh-farm {
  position:relative;
  min-height:226px;
  display:grid;
  place-content:center;
  gap:10px;
  padding:14px;
  border-color:var(--hh-blue-line);
  text-align:center;
  background:
    radial-gradient(circle at 50% 34%,rgba(47,157,255,.12),transparent 9rem),
    linear-gradient(180deg,rgba(5,13,27,.98),rgba(3,8,17,.98));
}
.hh-farm-kicker {
  position:absolute;
  top:12px;
  left:14px;
  color:var(--hh-blue);
  font-size:.58rem;
  font-weight:850;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.hh-farm-icon {
  width:43px;
  height:43px;
  display:grid;
  place-items:center;
  margin:auto;
  border:1px solid rgba(75,187,255,.54);
  border-radius:50%;
  color:var(--hh-blue);
  box-shadow:0 0 13px rgba(64,174,255,.2);
}
.hh-farm-icon svg { width:24px; height:24px; }
.hh-farm strong { color:#64caff; font-size:.76rem; letter-spacing:.07em; }
.hh-farm small { color:#7e8492; font-size:.63rem; line-height:1.45; }
.hh-farm button {
  min-height:34px;
  border:1px solid rgba(73,184,255,.54);
  border-radius:6px;
  background:rgba(34,117,181,.12);
  color:#62c9ff;
  font-size:.7rem;
  cursor:pointer;
}
.hh-saved { min-height:226px; padding:12px 14px; }
.hh-saved-head { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:8px; }
.hh-saved-title { display:flex; align-items:baseline; gap:9px; min-width:0; }
.hh-saved-title strong { color:#ff70b5; font-size:.76rem; letter-spacing:.07em; }
.hh-saved-title small { overflow:hidden; color:#847b85; font-size:.59rem; text-overflow:ellipsis; white-space:nowrap; }
.hh-saved-count { color:#9b8f99; font-size:.58rem; }
.hh-saved-tools summary {
  list-style:none;
  padding:4px 7px;
  border:1px solid rgba(255,255,255,.10);
  border-radius:5px;
  color:#a99fab;
  font-size:.58rem;
  cursor:pointer;
}
.hh-saved-tools summary::-webkit-details-marker { display:none; }
.hh-history-controls {
  display:grid;
  grid-template-columns:1fr 100px auto;
  gap:6px;
  margin-bottom:7px;
}
.hh-history-controls input,
.hh-history-controls select {
  min-width:0;
  height:29px;
  padding:4px 7px!important;
  border:1px solid rgba(255,255,255,.10)!important;
  border-radius:5px!important;
  background:#030712!important;
  color:#c9bec6!important;
  font-size:.6rem!important;
}
.hh-history-controls button {
  border:1px solid rgba(255,84,122,.28);
  border-radius:5px;
  background:rgba(255,49,91,.07);
  color:#ff809a;
  font-size:.58rem;
  cursor:pointer;
}
.hh-saved:not(:has(.hh-saved-tools[open])) .hh-history-controls { display:none; }
.hh-saved:has(.hh-saved-tools[open]) .hh-saved-list { max-height:118px; }
.hh-saved-list { display:grid; gap:6px; max-height:177px; overflow:auto; scrollbar-width:thin; scrollbar-color:rgba(255,65,157,.35) transparent; }
.hh-hit-row {
  display:grid;
  grid-template-columns:100px minmax(70px,1fr) 70px 58px 48px 28px;
  align-items:center;
  gap:8px;
  min-height:31px;
  padding:4px 8px;
  border:1px solid rgba(255,255,255,.065);
  border-radius:5px;
  background:rgba(3,7,16,.66);
  color:#a399a2;
  font-size:.59rem;
}
.hh-hit-row strong { min-width:0; overflow:hidden; color:#d9cdd5; text-overflow:ellipsis; white-space:nowrap; }
.hh-hit-row .hh-hit-opponent { display:block; width:100%; max-width:100%; }
.hh-hit-row .win { color:#7ae49d; }
.hh-hit-row .loss { color:#ff6f91; }
.hh-hit-row button {
  width:24px;
  height:24px;
  padding:0;
  border:0;
  background:transparent;
  color:#766e78;
  cursor:pointer;
}
.hh-hit-empty { display:grid; min-height:95px; place-items:center; color:#827984; font-size:.68rem; }

@media (min-width:1900px) {
  .hh-duel {
    grid-template-columns:minmax(0,1.15fr) clamp(238px,12vw,276px) minmax(0,1fr);
  }
  .hh-fighter.you {
    padding-left:54%;
    padding-right:4%;
    transform:translateY(-18px);
  }
  .hh-fighter.opponent {
    padding-left:8%;
    padding-right:50%;
    transform:translateY(-18px);
  }
  .hh-action-button {
    width:clamp(104px,5.5vw,116px);
    height:clamp(104px,5.5vw,116px);
  }
  .hh-action-button img {
    width:clamp(38px,2vw,46px);
    height:clamp(38px,2vw,46px);
  }
  .hh-result-toggle { width:144px; }
}

@media (min-width:1600px) and (min-height:1050px) {
  .hh-header { min-height:160px; }
  .hh-duel { min-height:380px; }
  .hh-answer,
  .hh-farm,
  .hh-saved { min-height:270px; }
  #battleAnalysis,
  .hh-analysis-live { min-height:214px; }
  .hh-saved-list { max-height:221px; }
  .hh-hit-row { min-height:38px; }
}

/* v9.69 — Hit Help approved-mockup fidelity desktop composition.
   Preserves the full desktop workspace while matching the approved panel ratio,
   compact height, original rival art, typography, icons, and control geometry. */
@media (min-width:1181px) {
  body[data-page="battle"] #page-battle.hit-help-rebuild {
    width:100%!important;
    max-width:none!important;
    margin-inline:0!important;
    gap:6px!important;
    overflow-x:hidden;
  }

  body[data-page="battle"] :is(.hh-header,.hh-form,.hh-midrow,.hh-bottom) {
    width:100%;
    max-width:100%;
    min-width:0;
    box-sizing:border-box;
  }

  body[data-page="battle"] .hh-header {
    height:132px;
    min-height:132px;
    grid-template-columns:minmax(360px,.66fr) minmax(620px,1fr);
    gap:14px;
  }

  body[data-page="battle"] .hh-heading {
    height:132px;
    min-height:0;
    padding:7px 12px;
  }

  body[data-page="battle"] .hh-heading h1 {
    font-size:clamp(3.55rem,3.8vw,4.05rem)!important;
  }

  body[data-page="battle"] .hh-heading > .hh-kicker {
    display:inline-flex;
    align-items:center;
    width:max-content;
    min-height:20px;
    padding:2px 9px;
    border:1px solid rgba(255,76,164,.62);
    border-radius:4px;
    background:rgba(21,8,23,.72);
    box-shadow:0 0 12px rgba(255,54,151,.10),inset 0 0 10px rgba(255,54,151,.05);
    line-height:1;
  }

  body[data-page="battle"] .hh-build {
    height:132px;
    min-height:0;
    grid-template-rows:18px minmax(0,1fr);
    padding:10px 12px;
  }

  body[data-page="battle"] .hh-current-build,
  body[data-page="battle"] .hh-build-metrics {
    min-height:0;
  }

  body[data-page="battle"] .hh-build-metric {
    padding:8px 11px;
  }

  body[data-page="battle"] .hh-form {
    gap:10px;
  }

  body[data-page="battle"] .hh-duel {
    width:100%;
    height:336px;
    min-height:336px;
    max-height:336px;
    aspect-ratio:auto;
    box-sizing:border-box;
    grid-template-columns:minmax(0,1.14fr) minmax(156px,.414fr) minmax(0,1fr);
    padding-right:14%;
    isolation:isolate;
  }

  /*
   * Safari and Chromium resolve grid-item min-content height differently.
   * Force the three duel tracks to the panel's fixed desktop coordinate box
   * so text metrics can never push their positions beyond the 336px frame.
   */
  body[data-page="battle"] .hh-duel > :is(.hh-fighter,.hh-matchup) {
    height:100%;
    min-height:0;
    max-height:100%;
    align-self:stretch;
    overflow:hidden;
    box-sizing:border-box;
  }

  body[data-page="battle"] .hh-duel::before {
    content:"";
    position:absolute;
    inset:0 14% 0 0;
    z-index:0;
    pointer-events:none;
    background:
      radial-gradient(circle at 53% 50%,rgba(255,255,255,.26),transparent 34px),
      linear-gradient(90deg,rgba(18,3,13,.18),rgba(2,5,14,.42) 48%,rgba(3,7,19,.34));
  }

  body[data-page="battle"] .hh-duel-art {
    inset:0 14% 0 0;
    width:86%;
    height:100%;
    opacity:.24;
    object-fit:fill;
    object-position:center;
    transform:none;
    filter:saturate(1.05) contrast(1.04) brightness(.76);
  }

  body[data-page="battle"] .hh-fighter {
    isolation:isolate;
  }

  body[data-page="battle"] .hh-fighter::before {
    content:"";
    position:absolute;
    inset:0;
    z-index:-1;
    pointer-events:none;
    background-repeat:no-repeat;
    filter:saturate(1.05) contrast(1.04) brightness(.84);
  }

  body[data-page="battle"] .hh-fighter.you::before {
    background:
      linear-gradient(90deg,transparent 0 38%,rgba(2,4,11,.24) 58%,rgba(2,4,11,.90) 100%),
      url("../images/ui/hit-help-duel-v917.png?v=9.69") -48px 0% / auto 100% no-repeat;
  }

  body[data-page="battle"] .hh-fighter.opponent::before {
    background:
      linear-gradient(90deg,rgba(2,4,11,.90) 0,rgba(2,4,11,.24) 46%,transparent 70%),
      url("../images/ui/hit-help-duel-v917.png?v=9.69") calc(100% + 48px) 0% / auto 100% no-repeat;
  }

  body[data-page="battle"] .hh-fighter {
    padding:20px 24px;
    transform:none;
  }

  body[data-page="battle"] .hh-fighter.you {
    padding-left:55%;
    padding-right:4%;
    transform:none;
  }

  body[data-page="battle"] .hh-fighter.you > * {
    width:100%;
  }

  body[data-page="battle"] .hh-fighter.opponent {
    padding-left:12%;
    padding-right:46%;
    transform:none;
  }

  body[data-page="battle"] .hh-fighter.opponent > * {
    width:100%;
  }

  body[data-page="battle"] .hh-matchup {
    padding-block:16px;
  }

  body[data-page="battle"] .hh-action-button {
    width:86px;
    height:86px;
    padding:7px;
  }

  body[data-page="battle"] .hh-action-button img,
  body[data-page="battle"] .hh-action-button svg {
    width:32px;
    height:32px;
  }

  body[data-page="battle"] .hh-result-toggle {
    width:116px;
    gap:2px;
    padding:2px;
    border:1px solid rgba(255,255,255,.10);
    border-radius:8px;
    background:rgba(2,5,13,.70);
  }

  body[data-page="battle"] .hh-opponent-rail {
    gap:18px;
    padding:20px 14px 12px;
  }

  body[data-page="battle"] .hh-relation {
    min-height:96px;
    padding:14px 10px;
  }

  body[data-page="battle"] .hh-midrow {
    height:146px;
    min-height:146px;
  }

  body[data-page="battle"] :is(.hh-result-signal,.hh-context,.hh-save-panel) {
    height:146px;
    min-height:0;
    overflow:hidden;
  }

  body[data-page="battle"] .hh-bottom {
    height:234px;
    min-height:234px;
    align-items:stretch;
  }

  body[data-page="battle"] :is(.hh-answer,.hh-farm,.hh-saved) {
    height:234px;
    min-height:234px;
  }

  body[data-page="battle"] #battleAnalysis,
  body[data-page="battle"] .hh-analysis-live {
    min-height:178px;
  }

  body[data-page="battle"] .hh-saved-list {
    max-height:179px;
  }

  body[data-page="battle"] #page-battle.hit-help-rebuild {
    font-family:"UPIMD Condensed","Arial Narrow","Segoe UI",sans-serif;
    font-stretch:condensed;
    -webkit-font-smoothing:antialiased;
    -moz-osx-font-smoothing:grayscale;
    text-rendering:geometricPrecision;
  }

  body[data-page="battle"] .hh-heading::before {
    opacity:.52;
    filter:saturate(1.05) contrast(1.04) brightness(.82);
  }

  body[data-page="battle"] .hh-heading h1 {
    font-family:"UPIMD Condensed","Arial Narrow",Impact,sans-serif;
    font-size:3.65rem!important;
    font-weight:650;
    letter-spacing:.055em!important;
  }

  body[data-page="battle"] .hh-heading h1 img {
    width:40px;
    height:40px;
  }

  body[data-page="battle"] .hh-build-title strong {
    font-size:.76rem;
  }

  body[data-page="battle"] .hh-current-build strong {
    font-size:1.34rem;
  }

  body[data-page="battle"] .hh-current-build small {
    font-size:.70rem;
  }

  body[data-page="battle"] .hh-build-metric {
    grid-template-columns:44px minmax(0,1fr);
  }

  body[data-page="battle"] .hh-build-metric img {
    width:38px;
    height:38px;
  }

  body[data-page="battle"] .hh-build-metric strong {
    font-size:1.18rem;
  }

  body[data-page="battle"] .hh-build-metric.now::before {
    width:15px;
    height:15px;
    background:radial-gradient(circle,var(--hh-green) 0 2px,transparent 2.6px);
  }

  body[data-page="battle"] .hh-fighter {
    padding:18px 24px 16px;
  }

  body[data-page="battle"] .hh-fighter-head span {
    font-size:.74rem;
  }

  body[data-page="battle"] .hh-fighter-head strong,
  body[data-page="battle"] .hh-opponent-name {
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
    font-size:1.30rem!important;
    font-weight:650;
    letter-spacing:.055em;
  }

  body[data-page="battle"] .hh-fighter.you .hh-fighter-head strong::after {
    content:"";
    display:inline-block;
    width:18px;
    height:18px;
    margin-left:7px;
    vertical-align:-4px;
    background:url("../images/ui/icon-sakura-v916.png?v=9.16") center / contain no-repeat;
    filter:drop-shadow(0 0 7px rgba(255,76,164,.62));
  }

  body[data-page="battle"] .hh-opponent-name-line {
    display:flex;
    align-items:center;
    justify-content:flex-end;
    gap:7px;
    width:100%;
  }

  body[data-page="battle"] .hh-opponent-name {
    width:min(100%,180px);
  }

  body[data-page="battle"] .hh-opponent-mark {
    display:grid;
    flex:0 0 18px;
    width:18px;
    height:18px;
    place-items:center;
    color:#b46cff;
    filter:drop-shadow(0 0 6px rgba(178,94,255,.48));
  }

  body[data-page="battle"] .hh-opponent-mark svg {
    width:17px;
    height:17px;
  }

  body[data-page="battle"] .hh-fighter-head small {
    font-size:.64rem;
    font-weight:750;
  }

  body[data-page="battle"] .hh-power-row {
    grid-template-columns:52px minmax(0,1fr);
    gap:0 11px;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-power-row {
    grid-template-columns:minmax(0,1fr) 52px;
  }

  body[data-page="battle"] .hh-power-row img {
    width:46px;
    height:46px;
  }

  body[data-page="battle"] .hh-power-copy span {
    font-size:.74rem;
  }

  body[data-page="battle"] .hh-power-copy strong,
  body[data-page="battle"] .hh-power-copy output,
  body[data-page="battle"] .hh-power-input {
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
    font-size:1.92rem!important;
    font-weight:500;
  }

  body[data-page="battle"] .hh-power-track {
    height:9px;
    margin-top:7px;
  }

  body[data-page="battle"] .hh-fighter-foot {
    font-size:.70rem;
  }

  body[data-page="battle"] .hh-matchup > span {
    display:flex;
    align-items:center;
    gap:6px;
    font-size:.70rem;
  }

  body[data-page="battle"] .hh-help-dot {
    display:grid;
    width:16px;
    height:16px;
    place-items:center;
    border:1px solid rgba(255,120,188,.62);
    border-radius:50%;
    color:#ff86c0;
    font-size:.62rem;
    font-style:normal;
    line-height:1;
  }

  body[data-page="battle"] .hh-action-buttons {
    position:relative;
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:0;
  }

  body[data-page="battle"] .hh-action-button {
    position:relative;
    border-radius:50%;
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
  }

  body[data-page="battle"] .hh-action-button[data-hit-stat="intelligence"] {
    width:72px;
    height:72px;
    margin-top:-6px;
    margin-bottom:0;
    border-color:rgba(72,181,255,.72);
    border-radius:50%;
    color:#5fc8ff;
    transform:none;
    background:radial-gradient(circle,rgba(44,155,255,.18),rgba(7,10,25,.94) 69%);
    box-shadow:0 0 22px rgba(55,168,255,.38),inset 0 0 22px rgba(55,168,255,.16);
  }

  body[data-page="battle"] .hh-action-button[data-hit-stat="intelligence"] > * {
    transform:none;
  }

  body[data-page="battle"] .hh-action-button svg {
    color:#53c4ff;
    filter:drop-shadow(0 0 7px rgba(67,185,255,.68));
  }

  body[data-page="battle"] .hh-action-buttons::after {
    content:"";
    position:absolute;
    top:51%;
    left:50%;
    z-index:3;
    width:11px;
    height:11px;
    transform:translate(-50%,-50%) rotate(45deg);
    background:#fff;
    box-shadow:0 0 6px #fff,0 0 14px #ff5cad,0 0 22px #4dbfff;
    pointer-events:none;
  }

  body[data-page="battle"] .hh-versus {
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
    font-size:1.14rem;
    font-weight:800;
  }

  body[data-page="battle"] .hh-result-toggle button {
    min-height:22px;
    border:0;
    border-radius:5px;
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
  }

  body[data-page="battle"] .hh-opponent-rail {
    background:
      radial-gradient(circle at 18% 38%,rgba(255,45,145,.055),transparent 12rem),
      linear-gradient(180deg,rgba(5,8,19,.94),rgba(3,5,12,.98));
  }

  body[data-page="battle"] .hh-opponent-rail > strong {
    color:#f3eaf0;
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
    font-size:1rem;
    letter-spacing:.07em;
  }

  body[data-page="battle"] .hh-rail-stat {
    grid-template-columns:42px minmax(0,1fr);
    gap:3px 10px;
  }

  body[data-page="battle"] .hh-rail-stat img {
    width:40px;
    height:40px;
  }

  body[data-page="battle"] .hh-rail-stat span {
    font-size:.78rem;
  }

  body[data-page="battle"] .hh-rail-stat b {
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
    font-size:1.48rem;
    font-weight:500;
  }

  body[data-page="battle"] .hh-relation {
    grid-template-columns:40px minmax(0,1fr);
  }

  body[data-page="battle"] .hh-relation svg {
    width:38px;
    height:38px;
  }

  body[data-page="battle"] .hh-relation b {
    font-size:.78rem;
  }

  body[data-page="battle"] .hh-relation small {
    font-size:.64rem;
  }

  body[data-page="battle"] .hh-result-signal strong,
  body[data-page="battle"] .hh-save-panel strong,
  body[data-page="battle"] .hh-answer-heading h2,
  body[data-page="battle"] .hh-farm,
  body[data-page="battle"] .hh-saved {
    font-family:"UPIMD Condensed","Arial Narrow","Segoe UI",sans-serif;
  }
}

/* v9.69 — Hit Help proportional desktop browser parity.
   Approved mockup proportions are viewport-anchored so Safari, Edge, and Chrome
   keep the same composition without shrinking the Hit Help workspace. */
@media (min-width:1181px) {
  body[data-page="battle"] #page-battle.hit-help-rebuild {
    gap:.386vw!important;
  }

  body[data-page="battle"] .hh-panel {
    border-radius:.707vw;
  }

  body[data-page="battle"] .hh-header {
    height:8.483vw;
    min-height:8.483vw;
    grid-template-columns:minmax(23.136vw,.66fr) minmax(39.846vw,1fr);
    gap:.9vw;
  }

  body[data-page="battle"] .hh-heading {
    height:8.483vw;
    padding:.45vw .771vw;
  }

  body[data-page="battle"] .hh-heading h1 {
    gap:.771vw;
    margin:.321vw 0 .257vw!important;
  }

  body[data-page="battle"] .hh-heading h1 img {
    width:2.571vw;
    height:2.571vw;
  }

  body[data-page="battle"] .hh-heading p {
    margin:.321vw 0 0!important;
  }

  body[data-page="battle"] .hh-heading > .hh-kicker {
    min-height:1.285vw;
    padding:.129vw .578vw;
    border-radius:.257vw;
  }

  body[data-page="battle"] .hh-build {
    height:8.483vw;
    grid-template-columns:minmax(9.69vw,.75fr) minmax(0,2.25fr);
    grid-template-rows:1.157vw minmax(0,1fr);
    gap:.578vw .771vw;
    padding:.643vw .771vw;
  }

  body[data-page="battle"] .hh-build-title {
    gap:.771vw;
  }

  body[data-page="battle"] .hh-current-build {
    gap:.129vw;
    padding:.643vw .771vw;
    border-radius:.514vw;
  }

  body[data-page="battle"] .hh-current-build .hh-crown {
    top:.643vw;
    right:.707vw;
    width:1.157vw;
    height:1.157vw;
  }

  body[data-page="battle"] .hh-build-metrics {
    border-radius:.514vw;
  }

  body[data-page="battle"] .hh-build-metric {
    grid-template-columns:2.828vw minmax(0,1fr);
    gap:.064vw .514vw;
    padding:.514vw .707vw;
  }

  body[data-page="battle"] .hh-build-metric img {
    width:2.442vw;
    height:2.442vw;
  }

  body[data-page="battle"] .hh-build-metric.now {
    grid-template-columns:2.828vw minmax(0,1fr);
  }

  body[data-page="battle"] .hh-build-metric.now::before {
    width:.964vw;
    height:.964vw;
    margin-left:.578vw;
  }

  body[data-page="battle"] .hh-form,
  body[data-page="battle"] .hh-midrow,
  body[data-page="battle"] .hh-bottom {
    gap:.643vw;
  }

  body[data-page="battle"] .hh-duel {
    height:auto;
    min-height:0;
    max-height:none;
    aspect-ratio:3.49 / 1;
    grid-template-columns:minmax(0,1.14fr) minmax(0,.414fr) minmax(0,1fr);
    border-radius:.707vw;
  }

  body[data-page="battle"] .hh-fighter {
    gap:.9vw;
    padding:1.157vw 1.542vw 1.028vw;
  }

  body[data-page="battle"] .hh-fighter-head {
    gap:.129vw;
  }

  body[data-page="battle"] .hh-fighter-head small {
    padding:.193vw .771vw;
    border-radius:.257vw;
  }

  body[data-page="battle"] .hh-fighter.you .hh-fighter-head strong::after {
    width:1.157vw;
    height:1.157vw;
    margin-left:.45vw;
    vertical-align:-.257vw;
  }

  body[data-page="battle"] .hh-opponent-name-line {
    gap:.45vw;
  }

  body[data-page="battle"] .hh-opponent-name {
    width:min(100%,11.568vw);
    padding-bottom:.257vw!important;
    line-height:1;
  }

  body[data-page="battle"] .hh-opponent-mark {
    flex-basis:1.157vw;
    width:1.157vw;
    height:1.157vw;
  }

  body[data-page="battle"] .hh-opponent-mark svg {
    width:1.093vw;
    height:1.093vw;
  }

  body[data-page="battle"] .hh-power-stack {
    gap:.707vw;
  }

  body[data-page="battle"] .hh-power-row {
    grid-template-columns:3.342vw minmax(0,1fr);
    gap:0 .707vw;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-power-row {
    grid-template-columns:minmax(0,1fr) 3.342vw;
  }

  body[data-page="battle"] .hh-power-row img {
    width:2.956vw;
    height:2.956vw;
  }

  body[data-page="battle"] :is(.hh-power-copy strong,.hh-power-copy output,.hh-power-input) {
    line-height:1;
  }

  body[data-page="battle"] .hh-power-track {
    height:.578vw;
    margin-top:.45vw;
  }

  body[data-page="battle"] .hh-fighter-foot {
    gap:.386vw .643vw;
  }

  body[data-page="battle"] .hh-matchup {
    padding-block:1.028vw;
  }

  body[data-page="battle"] .hh-matchup > span {
    gap:.386vw;
  }

  body[data-page="battle"] .hh-help-dot {
    width:1.028vw;
    height:1.028vw;
  }

  body[data-page="battle"] .hh-action-button {
    width:5.526vw;
    height:5.526vw;
    padding:.45vw;
  }

  body[data-page="battle"] .hh-action-button img,
  body[data-page="battle"] .hh-action-button svg {
    width:2.057vw;
    height:2.057vw;
  }

  body[data-page="battle"] .hh-action-button[data-hit-stat="intelligence"] {
    width:4.626vw;
    height:4.626vw;
    margin-top:-.386vw;
  }

  body[data-page="battle"] .hh-action-buttons::after {
    width:.707vw;
    height:.707vw;
  }

  body[data-page="battle"] .hh-result-toggle {
    width:7.456vw;
    gap:.129vw;
    padding:.129vw;
    border-radius:.514vw;
  }

  body[data-page="battle"] .hh-result-toggle button {
    min-height:1.414vw;
    padding:.257vw;
    border-radius:.321vw;
    line-height:1;
    -webkit-appearance:none;
    appearance:none;
  }

  body[data-page="battle"] .hh-opponent-rail {
    gap:1.157vw;
    padding:1.285vw .9vw .771vw;
  }

  body[data-page="battle"] .hh-rail-stat {
    grid-template-columns:2.699vw minmax(0,1fr);
    gap:.193vw .643vw;
  }

  body[data-page="battle"] .hh-rail-stat img {
    width:2.571vw;
    height:2.571vw;
  }

  body[data-page="battle"] .hh-relation {
    grid-template-columns:2.571vw minmax(0,1fr);
    gap:.129vw .578vw;
    min-height:6.169vw;
    padding:.9vw .643vw;
    border-radius:.45vw;
  }

  body[data-page="battle"] .hh-relation svg {
    width:2.442vw;
    height:2.442vw;
  }

  body[data-page="battle"] .hh-midrow,
  body[data-page="battle"] :is(.hh-result-signal,.hh-context,.hh-save-panel) {
    height:7.3vw;
    min-height:7.3vw;
  }

  body[data-page="battle"] .hh-result-signal {
    padding:.78vw .92vw;
  }

  body[data-page="battle"] .hh-result-signal > div {
    padding-right:.9vw;
  }

  body[data-page="battle"] .hh-result-signal > div + div {
    padding-left:1.028vw;
  }

  body[data-page="battle"] .hh-result-signal strong {
    margin-top:.45vw;
  }

  body[data-page="battle"] .hh-result-signal small {
    margin-top:.321vw;
  }

  body[data-page="battle"] .hh-context {
    padding:.5vw .7vw;
  }

  body[data-page="battle"] .hh-context-grid {
    gap:.257vw;
    margin-top:.514vw;
  }

  body[data-page="battle"] .hh-context-grid > label {
    grid-template-columns:minmax(5.913vw,.9fr) minmax(4.626vw,1fr);
    min-height:1.542vw;
    padding:0 .45vw;
    border-radius:.321vw;
  }

  body[data-page="battle"] .hh-context-label {
    gap:.386vw;
  }

  body[data-page="battle"] .hh-context-label svg {
    width:.964vw;
    height:.964vw;
  }

  body[data-page="battle"] .hh-context-grid > label :is(input,textarea) {
    height:1.414vw;
    padding:.129vw .257vw!important;
  }

  body[data-page="battle"] .hh-save-panel {
    padding:.7vw;
    background-size:auto,1.928vw,auto;
  }

  body[data-page="battle"] .hh-save-copy small {
    margin:.321vw 0 .707vw;
  }

  body[data-page="battle"] .hh-submit {
    min-height:2.65vw;
    border-radius:.45vw;
    background-size:auto,1.607vw,auto;
    background-position:center,calc(100% - 1.028vw) 50%,center;
  }

  body[data-page="battle"] .hh-bottom,
  body[data-page="battle"] :is(.hh-answer,.hh-farm,.hh-saved) {
    height:11.5vw;
    min-height:11.5vw;
  }

  body[data-page="battle"] .hh-bottom {
    grid-template-columns:minmax(0,1.18fr) minmax(10.925vw,.42fr) minmax(0,1.14fr);
  }

  body[data-page="battle"] .hh-answer {
    padding:.7vw .8vw;
  }

  body[data-page="battle"] .hh-answer-heading {
    gap:.771vw;
  }

  body[data-page="battle"] #battleAnalysis,
  body[data-page="battle"] .hh-analysis-live {
    min-height:8.95vw;
  }

  body[data-page="battle"] .hh-analysis-live {
    margin-top:.643vw;
    border-radius:.45vw;
  }

  body[data-page="battle"] .hh-analysis-live > div {
    gap:.386vw;
    padding:.771vw;
  }

  body[data-page="battle"] .hh-farm {
    gap:.35vw;
    padding:.7vw;
  }

  body[data-page="battle"] .hh-farm-kicker {
    top:.771vw;
    left:.9vw;
  }

  body[data-page="battle"] .hh-farm-icon {
    width:2.764vw;
    height:2.764vw;
  }

  body[data-page="battle"] .hh-farm-icon svg {
    width:1.542vw;
    height:1.542vw;
  }

  body[data-page="battle"] .hh-farm button {
    min-height:1.75vw;
    border-radius:.386vw;
  }

  body[data-page="battle"] .hh-saved {
    padding:.65vw .75vw;
  }

  body[data-page="battle"] .hh-saved-head {
    gap:.643vw;
    margin-bottom:.514vw;
  }

  body[data-page="battle"] .hh-saved-title {
    gap:.578vw;
  }

  body[data-page="battle"] .hh-saved-tools summary {
    padding:.257vw .45vw;
    border-radius:.321vw;
  }

  body[data-page="battle"] .hh-saved-list {
    gap:.386vw;
    max-height:8.8vw;
  }
  /* Content-scoped desktop type: stable without resizing the sidebar or shell. */
  body[data-page="battle"] #page-battle .hh-kicker,
  body[data-page="battle"] #page-battle .hh-label {
    font-size:.699vw;
  }

  body[data-page="battle"] #page-battle .hh-heading h1 {
    font-size:clamp(2.878vw,4vw,4.933vw)!important;
  }

  body[data-page="battle"] #page-battle .hh-heading p {
    font-size:.946vw;
  }

  body[data-page="battle"] #page-battle .hh-build-title strong {
    font-size:.719vw;
  }

  body[data-page="battle"] #page-battle .hh-build-edit {
    font-size:.719vw;
  }

  body[data-page="battle"] #page-battle .hh-current-build span {
    font-size:.626vw;
  }

  body[data-page="battle"] #page-battle .hh-current-build strong {
    font-size:1.254vw;
  }

  body[data-page="battle"] #page-battle .hh-current-build small {
    font-size:.668vw;
  }

  body[data-page="battle"] #page-battle .hh-build-metric span {
    font-size:.607vw;
  }

  body[data-page="battle"] #page-battle .hh-build-metric strong {
    font-size:1.11vw;
  }

  body[data-page="battle"] #page-battle .hh-fighter-head span {
    font-size:.699vw;
  }

  body[data-page="battle"] #page-battle .hh-fighter-head strong {
    font-size:1.151vw;
  }

  body[data-page="battle"] #page-battle .hh-fighter-head small {
    font-size:.617vw;
  }

  body[data-page="battle"] .hh-opponent-name {
    font-size:1.151vw!important;
  }

  body[data-page="battle"] #page-battle .hh-power-copy span {
    font-size:.699vw;
  }

  body[data-page="battle"] #page-battle .hh-power-copy strong,
  body[data-page="battle"] #page-battle .hh-power-copy output {
    font-size:clamp(1.378vw,1.35vw,1.749vw);
  }

  body[data-page="battle"] .hh-power-input {
    font-size:clamp(1.317vw,1.319vw,1.706vw)!important;
  }

  body[data-page="battle"] #page-battle .hh-fighter-foot {
    font-size:.658vw;
  }

  body[data-page="battle"] #page-battle .hh-matchup > span {
    font-size:.678vw;
  }

  body[data-page="battle"] #page-battle .hh-action-button span {
    font-size:.658vw;
  }

  body[data-page="battle"] #page-battle .hh-versus {
    font-size:1.213vw;
  }

  body[data-page="battle"] #page-battle .hh-result-toggle button {
    font-size:.596vw;
  }

  body[data-page="battle"] #page-battle .hh-hit-time {
    font-size:.617vw;
  }

  body[data-page="battle"] #page-battle .hh-opponent-rail strong {
    font-size:clamp(.74vw,.719vw,.925vw);
  }

  body[data-page="battle"] #page-battle .hh-rail-stat span {
    font-size:clamp(.699vw,.681vw,.843vw);
  }

  body[data-page="battle"] #page-battle .hh-rail-stat b {
    font-size:clamp(1.069vw,1.019vw,1.317vw);
  }

  body[data-page="battle"] #page-battle .hh-relation > span {
    font-size:.576vw;
  }

  body[data-page="battle"] #page-battle .hh-relation b {
    font-size:.74vw;
  }

  body[data-page="battle"] #page-battle .hh-relation small {
    font-size:.586vw;
  }

  body[data-page="battle"] #page-battle .hh-result-signal span {
    font-size:.638vw;
  }

  body[data-page="battle"] #page-battle .hh-result-signal strong {
    font-size:1.901vw;
  }

  body[data-page="battle"] #page-battle .hh-result-signal small {
    font-size:.678vw;
  }

  body[data-page="battle"] #page-battle .hh-result-signal .hh-outcome strong {
    font-size:2.056vw;
  }

  body[data-page="battle"] #page-battle .hh-context-grid > label {
    font-size:.626vw;
  }

  body[data-page="battle"] .hh-context-grid > label input,
  body[data-page="battle"] .hh-context-grid > label textarea {
    font-size:.658vw!important;
  }

  body[data-page="battle"] #page-battle .hh-advanced-grid label {
    font-size:.626vw;
  }

  body[data-page="battle"] #page-battle .hh-advanced-grid input,
  body[data-page="battle"] #page-battle .hh-advanced-grid select {
    font-size:.658vw!important;
  }

  body[data-page="battle"] #page-battle .hh-advanced summary {
    font-size:.596vw;
  }

  body[data-page="battle"] #page-battle .hh-save-copy strong {
    font-size:.75vw;
  }

  body[data-page="battle"] #page-battle .hh-save-copy small {
    font-size:.649vw;
  }

  body[data-page="battle"] #page-battle .hh-submit {
    font-size:1.007vw;
  }

  body[data-page="battle"] #page-battle .hh-answer-heading h2 {
    font-size:.801vw;
  }

  body[data-page="battle"] #page-battle .hh-analysis-live span {
    font-size:.586vw;
  }

  body[data-page="battle"] #page-battle .hh-analysis-live strong {
    font-size:.976vw;
  }

  body[data-page="battle"] #page-battle .hh-analysis-live p {
    font-size:.668vw;
  }

  body[data-page="battle"] #page-battle .hh-analysis-live .reason strong {
    font-size:1.213vw;
  }

  body[data-page="battle"] #page-battle .hh-risk-mark {
    font-size:1.049vw!important;
  }

  body[data-page="battle"] #page-battle .hh-farm-kicker {
    font-size:.596vw;
  }

  body[data-page="battle"] #page-battle .hh-farm strong {
    font-size:.781vw;
  }

  body[data-page="battle"] #page-battle .hh-farm small {
    font-size:.649vw;
  }

  body[data-page="battle"] #page-battle .hh-farm button {
    font-size:.719vw;
  }

  body[data-page="battle"] #page-battle .hh-saved-title strong {
    font-size:.781vw;
  }

  body[data-page="battle"] #page-battle .hh-saved-title small {
    font-size:.607vw;
  }

  body[data-page="battle"] #page-battle .hh-saved-count {
    font-size:.596vw;
  }

  body[data-page="battle"] #page-battle .hh-saved-tools summary {
    font-size:.596vw;
  }

  body[data-page="battle"] #page-battle .hh-history-controls input,
  body[data-page="battle"] #page-battle .hh-history-controls select {
    font-size:.617vw!important;
  }

  body[data-page="battle"] #page-battle .hh-history-controls button {
    font-size:.596vw;
  }

  body[data-page="battle"] #page-battle .hh-hit-row {
    font-size:.607vw;
  }

  body[data-page="battle"] #page-battle .hh-hit-empty {
    font-size:.699vw;
  }

  body[data-page="battle"] .hh-heading h1 {
    font-size:3.751vw!important;
  }

  body[data-page="battle"] .hh-build-title strong {
    font-size:.781vw;
  }

  body[data-page="battle"] .hh-current-build strong {
    font-size:1.378vw;
  }

  body[data-page="battle"] .hh-current-build small {
    font-size:.719vw;
  }

  body[data-page="battle"] .hh-build-metric strong {
    font-size:1.213vw;
  }

  body[data-page="battle"] .hh-fighter-head span {
    font-size:.761vw;
  }

  body[data-page="battle"] .hh-fighter-head strong,
  body[data-page="battle"] .hh-opponent-name {
    font-size:1.336vw!important;
  }

  body[data-page="battle"] .hh-fighter-head small {
    font-size:.658vw;
  }

  body[data-page="battle"] .hh-power-copy span {
    font-size:.761vw;
  }

  body[data-page="battle"] .hh-power-copy strong,
  body[data-page="battle"] .hh-power-copy output,
  body[data-page="battle"] .hh-power-input {
    font-size:1.974vw!important;
  }

  body[data-page="battle"] .hh-fighter-foot {
    font-size:.719vw;
  }

  body[data-page="battle"] .hh-matchup > span {
    font-size:.719vw;
  }

  body[data-page="battle"] .hh-help-dot {
    font-size:.638vw;
  }

  body[data-page="battle"] .hh-versus {
    font-size:1.172vw;
  }

  body[data-page="battle"] .hh-opponent-rail > strong {
    font-size:1.028vw;
  }

  body[data-page="battle"] .hh-rail-stat span {
    font-size:.801vw;
  }

  body[data-page="battle"] .hh-rail-stat b {
    font-size:1.521vw;
  }

  body[data-page="battle"] .hh-relation b {
    font-size:.801vw;
  }

  body[data-page="battle"] .hh-relation small {
    font-size:.658vw;
  }


}

.hh-matchup-summary { display:none; }

/* Keep the v10 username wrappers neutral outside the locked desktop layout. */
body[data-page="battle"] .hh-player-name-line .hh-player-name-text {
  color:inherit!important;
  font:inherit!important;
  letter-spacing:inherit!important;
  text-transform:inherit;
}
body[data-page="battle"] .hh-opponent-name-field { display:contents; }
body[data-page="battle"] .hh-opponent-name-display { display:none; }

/* v10.05 — removed unused opponent tag placeholder */
@media (min-width:1181px) {
  body[data-page="battle"] .sidebar .tab .nav-icon {
    width:1.35vw;
    height:1.35vw;
    color:#cec8bd;
  }

  body[data-page="battle"] .sidebar .tab .nav-icon svg {
    width:100%;
    height:100%;
    stroke-width:1.85;
  }

  body[data-page="battle"] .sidebar .tab.active .nav-icon {
    color:#fff2fa;
    filter:drop-shadow(0 0 .28vw rgba(255,112,188,.55));
  }

  body[data-page="battle"] .sidebar .tab.active::after {
    content:"";
    width:1.9vw;
    height:1.9vw;
    top:50%;
    right:.92vw;
    transform:translateY(-50%);
    background:url("../images/ui/icon-sakura-v916.png?v=9.16") center / contain no-repeat;
    filter:drop-shadow(0 0 .38vw rgba(255,104,184,.9));
  }

  body[data-page="battle"] .hh-heading h1 img {
    width:2.5vw;
    height:2.5vw;
    flex:0 0 2.5vw;
  }

  body[data-page="battle"] .hh-current-build .hh-crown {
    width:.95vw;
    height:.95vw;
  }

  body[data-page="battle"] .hh-build-metric:not(.now) {
    grid-template-columns:2.75vw minmax(0,1fr);
  }

  body[data-page="battle"] .hh-build-metric img {
    width:2.45vw;
    height:2.45vw;
  }

  body[data-page="battle"] .hh-build-metric.now {
    grid-template-columns:2.5vw minmax(0,1fr);
  }

  body[data-page="battle"] .hh-build-metric.now::before {
    width:1vw;
    height:1vw;
    margin-left:.48vw;
  }

  body[data-page="battle"] .hh-fighter.you .hh-fighter-head strong::after {
    width:1.12vw;
    height:1.12vw;
    margin-left:.38vw;
    vertical-align:-.25vw;
  }

  body[data-page="battle"] .hh-opponent-mark {
    flex-basis:1.16vw;
    width:1.16vw;
    height:1.16vw;
  }

  body[data-page="battle"] .hh-opponent-mark svg {
    width:1.1vw;
    height:1.1vw;
  }

  body[data-page="battle"] .hh-power-row {
    grid-template-columns:3.3vw minmax(0,1fr);
    column-gap:.55vw;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-power-row {
    grid-template-columns:minmax(0,1fr) 3.3vw;
  }

  body[data-page="battle"] .hh-power-row img {
    width:3vw;
    height:3vw;
  }

  /*
   * Use the duel's centerline as the single vertical datum for both fighters.
   * This removes flex/text-metric drift between output text and editable inputs.
   */
  body[data-page="battle"] .hh-fighter .hh-power-stack {
    position:absolute;
    inset:0;
    display:block;
    width:auto;
  }

  /*
   * Output elements and editable inputs use different native line boxes.
   * Give both copies the same measured box so labels, values, and bars align.
   */
  body[data-page="battle"] .hh-fighter .hh-power-copy {
    height:3.95vw;
    box-sizing:border-box;
  }

  body[data-page="battle"] .hh-fighter :is(.hh-power-copy strong,.hh-power-copy output,.hh-power-input) {
    height:2.1vw;
    line-height:2.1vw!important;
    box-sizing:border-box;
  }

  body[data-page="battle"] .hh-fighter .hh-power-row {
    position:absolute;
    margin:0;
  }

  body[data-page="battle"] .hh-fighter.you .hh-power-row {
    right:4%;
    left:55%;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-power-row {
    right:46%;
    left:12%;
  }

  body[data-page="battle"] .hh-fighter .hh-power-row:not(.int) {
    top:auto;
    bottom:calc(50% + .75vw);
  }

  body[data-page="battle"] .hh-fighter .hh-power-row.int {
    top:calc(50% + .4vw);
    bottom:auto;
  }

  /*
   * Opponent values are editable fields, so show a persistent input affordance
   * instead of presenting their empty state like read-only zero statistics.
   */
  body[data-page="battle"] .hh-fighter.opponent .hh-power-input {
    padding:0 .5vw!important;
    border:1px solid rgba(255,105,181,.46)!important;
    border-radius:.35vw!important;
    background:linear-gradient(90deg,rgba(255,61,151,.10),rgba(4,7,16,.62))!important;
    box-shadow:inset 0 0 .65vw rgba(255,66,157,.08)!important;
    cursor:text;
    transition:border-color .16s ease,box-shadow .16s ease,background .16s ease;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-power-row.int .hh-power-input {
    border-color:rgba(77,190,255,.48)!important;
    background:linear-gradient(90deg,rgba(53,168,255,.10),rgba(4,7,16,.62))!important;
    box-shadow:inset 0 0 .65vw rgba(53,168,255,.08)!important;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-power-input::placeholder {
    color:rgba(255,178,216,.88);
    opacity:1;
    font-size:.78vw!important;
    font-weight:800;
    line-height:1;
    letter-spacing:.06em;
    text-align:center;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-power-row.int .hh-power-input::placeholder {
    color:rgba(125,211,255,.88);
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-power-input:is(:hover,:focus) {
    border-color:#ff72b8!important;
    box-shadow:0 0 .7vw rgba(255,64,157,.28),inset 0 0 .65vw rgba(255,66,157,.12)!important;
    outline:0;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-power-row.int .hh-power-input:is(:hover,:focus) {
    border-color:#64caff!important;
    box-shadow:0 0 .7vw rgba(53,168,255,.28),inset 0 0 .65vw rgba(53,168,255,.12)!important;
  }

  /*
   * The absolute stat canvas spans the entire fighter. Let clicks pass through
   * its empty areas while keeping its two actual input rows interactive.
   */
  body[data-page="battle"] .hh-fighter-head {
    position:relative;
    z-index:3;
  }

  body[data-page="battle"] .hh-fighter .hh-power-stack {
    pointer-events:none;
  }

  body[data-page="battle"] .hh-fighter .hh-power-row {
    pointer-events:auto;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-opponent-name {
    height:2.1vw;
    box-sizing:border-box;
    padding:0 .5vw!important;
    border:1px solid rgba(190,104,255,.48)!important;
    border-radius:.35vw!important;
    background:linear-gradient(90deg,rgba(164,73,255,.10),rgba(4,7,16,.62))!important;
    box-shadow:inset 0 0 .65vw rgba(168,76,255,.08)!important;
    cursor:text;
    text-align:center!important;
    transition:border-color .16s ease,box-shadow .16s ease,background .16s ease;
  }

  body[data-page="battle"] .hh-fighter.you .hh-player-name-line {
    display:inline-flex;
    align-items:center;
    width:var(--hh-player-line-width,max-content);
    max-width:calc(100% + 6vw);
    overflow:visible!important;
    font-size:1.336vw!important;
    letter-spacing:.055em!important;
    transform:translateX(var(--hh-player-line-shift,0));
    transition:width .16s ease,transform .16s ease;
  }

  body[data-page="battle"] .hh-fighter.you .hh-player-name-line::after {
    flex:0 0 1.12vw;
  }

  body[data-page="battle"] .hh-fighter.you .hh-player-name-text {
    display:inline-block;
    flex:0 1 auto;
    min-width:0;
    overflow:visible;
    color:inherit!important;
    font-family:inherit;
    font-size:inherit!important;
    font-weight:inherit;
    letter-spacing:inherit!important;
    line-height:inherit;
    text-transform:inherit;
    white-space:nowrap;
    transform:scaleX(var(--hh-player-name-scale,1));
    transform-origin:left center;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-opponent-name-line {
    justify-content:flex-start;
    overflow:visible;
    transform:translateX(var(--hh-opponent-line-shift,0));
    transition:transform .16s ease;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-opponent-name-field {
    position:relative;
    display:block;
    flex:0 0 var(--hh-opponent-field-width,11.568vw);
    width:var(--hh-opponent-field-width,11.568vw);
    max-width:18vw;
    height:2.1vw;
    min-width:0;
    transition:width .16s ease,flex-basis .16s ease;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-opponent-name {
    width:100%!important;
    max-width:none;
    font-size:1.336vw!important;
    letter-spacing:.055em!important;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-opponent-name-display {
    position:absolute;
    inset:0 .5vw;
    display:flex;
    align-items:center;
    justify-content:center;
    overflow:visible;
    pointer-events:none;
    color:#f6ecfa!important;
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
    font-size:1.336vw!important;
    font-weight:650;
    letter-spacing:.055em!important;
    line-height:2.1vw;
    text-transform:uppercase;
    white-space:nowrap;
    transform:scaleX(var(--hh-opponent-name-scale,1));
    transform-origin:center center;
  }

  body[data-page="battle"] .hh-opponent-name-field:not(.has-value) .hh-opponent-name-display,
  body[data-page="battle"] .hh-opponent-name-field:focus-within .hh-opponent-name-display {
    visibility:hidden;
  }

  body[data-page="battle"] .hh-opponent-name-field.has-value:not(:focus-within) .hh-opponent-name {
    color:transparent!important;
    text-shadow:none!important;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-opponent-name::placeholder {
    color:rgba(214,162,255,.9);
    opacity:1;
    font-size:.78vw!important;
    font-weight:800;
    letter-spacing:.06em;
    text-align:center;
  }

  body[data-page="battle"] .hh-fighter.opponent .hh-opponent-name:is(:hover,:focus) {
    border-color:#c77cff!important;
    box-shadow:0 0 .7vw rgba(173,76,255,.30),inset 0 0 .65vw rgba(168,76,255,.12)!important;
    outline:0;
  }

  body[data-page="battle"] .hh-duel {
    grid-template-columns:minmax(0,1.14fr) minmax(0,.414fr) minmax(0,1fr);
  }

  body[data-page="battle"] .hh-matchup {
    position:relative;
    display:block;
    padding:0;
    overflow:hidden;
  }

  body[data-page="battle"] .hh-action-buttons {
    position:absolute;
    inset:0;
    width:auto;
    height:100%;
    display:block;
    margin:0;
    transform:none;
  }

  body[data-page="battle"] .hh-action-button {
    position:absolute;
    top:10.35%;
    left:25%;
    width:50%;
    height:auto;
    aspect-ratio:1 / 1;
    grid-template-rows:32.8% 15.5%;
    align-content:center;
    gap:5px;
    padding:7px;
    line-height:1;
  }

  body[data-page="battle"] .hh-action-button[aria-pressed="true"] {
    box-shadow:
      0 0 0 2px rgba(255,91,174,.16),
      0 0 20px rgba(255,53,151,.55),
      inset 0 0 20px rgba(255,53,151,.20);
  }

  body[data-page="battle"] .hh-action-button[data-hit-stat="intelligence"] {
    top:39.45%;
    width:50%;
    height:auto;
    aspect-ratio:1 / 1;
    margin:0;
    box-shadow:
      0 0 0 1px rgba(95,198,255,.14),
      0 0 18px rgba(55,168,255,.42),
      inset 0 0 20px rgba(55,168,255,.17);
  }

  body[data-page="battle"] .hh-action-button img,
  body[data-page="battle"] .hh-action-button svg {
    width:32%;
    height:auto;
    aspect-ratio:1 / 1;
    object-fit:contain;
  }

  body[data-page="battle"] .hh-action-button[data-hit-stat="intelligence"] svg {
    transform:translateY(-1px);
  }

  body[data-page="battle"] .hh-action-button span {
    font-size:13px;
    line-height:1;
  }

  body[data-page="battle"] .hh-action-buttons::after {
    top:37.25%;
    width:12px;
    height:12px;
    box-shadow:0 0 4px #fff,0 0 10px #ff5cad,0 0 16px #4dbfff;
  }

  body[data-page="battle"] .hh-versus {
    display:none;
  }

  body[data-page="battle"] .hh-matchup-summary {
    position:absolute;
    top:65.8%;
    right:5%;
    left:5%;
    display:grid;
    grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);
    grid-template-areas:
      "own vs opponent"
      "gap gap gap";
    grid-template-rows:minmax(0,1fr) auto;
    align-items:center;
    gap:2px 8px;
    height:11.8%;
    box-sizing:border-box;
    margin:0;
    padding:0 6px;
    border:0;
    border-radius:0;
    background:transparent;
    box-shadow:none;
    text-align:center;
  }

  body[data-page="battle"] .hh-match-side {
    min-width:0;
    display:grid;
    gap:1px;
  }

  body[data-page="battle"] .hh-match-side.own { grid-area:own; }
  body[data-page="battle"] .hh-match-side.opponent { grid-area:opponent; }

  body[data-page="battle"] .hh-match-side small {
    overflow:hidden;
    color:#a99fac;
    font-size:clamp(9px,.5vw,11px);
    font-style:normal;
    font-weight:800;
    letter-spacing:.06em;
    line-height:1;
    text-overflow:ellipsis;
    text-transform:uppercase;
    white-space:nowrap;
  }

  body[data-page="battle"] .hh-match-side.own small { color:#ff82bd; }
  body[data-page="battle"] .hh-match-side.opponent small { color:#c58aff; }

  body[data-page="battle"] .hh-match-side strong {
    overflow:hidden;
    color:#f4edf3;
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
    font-size:clamp(13px,.76vw,16px);
    font-weight:700;
    line-height:1;
    text-overflow:ellipsis;
    white-space:nowrap;
  }

  body[data-page="battle"] .hh-matchup-summary > b {
    grid-area:vs;
    color:#fff;
    font-family:"UPIMD Condensed","Arial Narrow",sans-serif;
    font-size:clamp(20px,1.15vw,24px);
    font-style:italic;
    line-height:1;
    text-shadow:0 0 10px rgba(255,255,255,.24);
  }

  body[data-page="battle"] .hh-matchup-summary > em {
    grid-area:gap;
    color:#9c939f;
    font-size:clamp(9px,.48vw,10.5px);
    font-style:normal;
    font-weight:800;
    letter-spacing:.055em;
    line-height:1.1;
    text-transform:uppercase;
  }

  body[data-page="battle"] .hh-matchup-summary[data-lead="you"] > em { color:#ff7ab9; }
  body[data-page="battle"] .hh-matchup-summary[data-lead="them"] > em { color:#bd86ff; }
  body[data-page="battle"] .hh-matchup-summary[data-lead="even"] > em { color:#70d3ff; }

  body[data-page="battle"] .hh-result-toggle {
    position:absolute;
    top:79.2%;
    left:50%;
    width:66%;
    height:7.2%;
    display:grid;
    grid-template-columns:1fr 1fr;
    margin:0;
    transform:translateX(-50%);
  }

  body[data-page="battle"] .hh-hit-time {
    position:absolute;
    top:88.5%;
    right:0;
    left:0;
    width:118px;
    margin:0 auto;
    line-height:1.25;
    white-space:normal;
    text-align:center;
    text-transform:none;
  }

  body[data-page="battle"] .hh-hit-time.has-value span {
    display:block;
  }

  body[data-page="battle"] .hh-matchup > span {
    position:absolute;
    top:4.87%;
    right:0;
    left:0;
    display:flex;
    justify-content:center;
    font-size:12px;
    line-height:16px;
    text-align:center;
  }

  body[data-page="battle"] .hh-help-dot {
    width:16px;
    height:16px;
    font-size:10px;
  }

  body[data-page="battle"] .hh-versus {
    font-size:18px;
  }

  body[data-page="battle"] .hh-result-toggle button {
    font-size:.65vw;
  }

  body[data-page="battle"] .hh-matchup > small {
    font-size:10px;
  }

  body[data-page="battle"] .hh-rail-stat img {
    width:2.25vw;
    height:2.25vw;
  }

  body[data-page="battle"] .hh-relation {
    grid-template-columns:2.45vw minmax(0,1fr);
  }

  body[data-page="battle"] .hh-relation svg {
    width:2.3vw;
    height:2.3vw;
  }

  body[data-page="battle"] .hh-save-panel {
    background-size:auto,1.9vw,auto;
  }

  body[data-page="battle"] .hh-submit {
    background-size:1.6vw 1.6vw,100% 100%;
    background-position:calc(100% - .78vw) center,center;
    background-repeat:no-repeat,no-repeat;
  }

  body[data-page="battle"] .hh-farm-icon {
    width:2.3vw;
    height:2.3vw;
  }

  body[data-page="battle"] .hh-farm-icon svg {
    width:1.28vw;
    height:1.28vw;
  }

  /*
   * Farm Watch uses explicit rows. The kicker is no longer absolutely positioned,
   * so it cannot occupy the icon's row or drift into it across desktop engines.
   */
  body[data-page="battle"] .hh-farm {
    display:grid;
    grid-template-rows:auto 2.3vw auto minmax(0,1fr) 1.75vw;
    place-content:initial;
    align-content:stretch;
    align-items:center;
    justify-items:stretch;
    gap:.25vw;
    padding:.7vw;
  }

  body[data-page="battle"] .hh-farm-kicker {
    position:static;
    top:auto;
    left:auto;
    justify-self:start;
    align-self:start;
    line-height:1;
  }

  body[data-page="battle"] .hh-farm-icon {
    grid-row:2;
    justify-self:center;
    align-self:center;
    margin:0;
  }

  body[data-page="battle"] .hh-farm > strong {
    justify-self:center;
    line-height:1;
  }

  body[data-page="battle"] .hh-farm > small {
    justify-self:center;
    align-self:center;
    line-height:1.3;
  }

  body[data-page="battle"] .hh-farm > button {
    width:100%;
    align-self:end;
  }

  /*
   * The Answer heading owns a separate row. This keeps the status badge clear
   * of the dashed analysis frame instead of letting both occupy the same edge.
   */
  body[data-page="battle"] .hh-answer {
    display:grid;
    grid-template-rows:auto minmax(0,1fr);
    align-content:stretch;
    gap:.35vw;
  }

  body[data-page="battle"] .hh-answer-heading {
    min-height:1.55vw;
  }

  body[data-page="battle"] #battleAnalysis,
  body[data-page="battle"] .hh-analysis-live {
    min-height:0;
    height:100%;
    margin-top:0;
    box-sizing:border-box;
  }

  /* v10.07 — Final Hit Help header; height and column geometry intentionally unchanged. */
  body[data-page="battle"] .hh-heading {
    justify-content:center;
  }

  body[data-page="battle"] .hh-heading::before {
    opacity:.72;
    filter:saturate(1.18) contrast(1.08) brightness(.98);
  }

  body[data-page="battle"] .hh-heading::after {
    opacity:.66;
  }

  body[data-page="battle"] .hh-heading h1 {
    color:#fff!important;
    text-shadow:0 0 .7vw rgba(255,255,255,.16);
  }

  body[data-page="battle"] .hh-heading h1 img {
    opacity:1;
    filter:saturate(1.12) drop-shadow(0 0 .38vw rgba(255,62,157,.72));
  }

  body[data-page="battle"] .hh-heading p {
    color:#c8bdc6!important;
    text-shadow:0 0 .35vw rgba(255,255,255,.07);
  }

  /* v10.06 — Build in Use visual hierarchy; geometry intentionally unchanged. */
  body[data-page="battle"] .hh-build {
    border-color:rgba(255,85,166,.68);
    background:
      radial-gradient(circle at 88% 0,rgba(129,40,105,.18),transparent 44%),
      linear-gradient(135deg,rgba(7,11,25,.97),rgba(13,8,20,.96));
    box-shadow:inset 0 0 1.5vw rgba(255,71,158,.035),0 0 1.25vw rgba(255,47,145,.08);
  }

  body[data-page="battle"] .hh-build-title strong {
    color:#f7edf4;
    text-shadow:0 0 .55vw rgba(255,255,255,.10);
  }

  body[data-page="battle"] .hh-build-edit {
    color:#c7a7ba;
  }

  body[data-page="battle"] .hh-build-edit:is(:hover,:focus-visible) {
    color:#ff8bc5;
    text-shadow:0 0 .45vw rgba(255,87,174,.35);
    outline:0;
  }

  body[data-page="battle"] .hh-current-build {
    border-color:rgba(255,81,169,.92);
    background:linear-gradient(135deg,rgba(73,23,63,.54),rgba(7,10,22,.94));
    box-shadow:inset 0 0 1.2vw rgba(255,53,151,.12),0 0 .8vw rgba(255,50,151,.16);
  }

  body[data-page="battle"] .hh-current-build span {
    color:#d2b7c8;
  }

  body[data-page="battle"] .hh-current-build strong {
    color:#fff4fa;
    text-shadow:0 0 .45vw rgba(255,255,255,.10);
  }

  body[data-page="battle"] .hh-current-build small {
    color:#aca3b0;
  }

  body[data-page="battle"] .hh-current-build .hh-crown {
    filter:drop-shadow(0 0 .35vw rgba(248,196,65,.55));
  }

  body[data-page="battle"] .hh-build-metrics {
    border-color:rgba(123,133,166,.20);
    background:linear-gradient(90deg,rgba(4,8,18,.90),rgba(8,9,20,.88));
    box-shadow:inset 0 0 1vw rgba(92,116,180,.035);
  }

  body[data-page="battle"] .hh-build-metric {
    border-right-color:rgba(148,154,180,.16);
  }

  body[data-page="battle"] .hh-build-metric.str span {
    color:#ff7dbd;
  }

  body[data-page="battle"] .hh-build-metric.int span {
    color:#69caff;
  }

  body[data-page="battle"] .hh-build-metric.now span {
    color:#79e49d;
  }

  body[data-page="battle"] .hh-build-metric strong {
    color:#fff3f8;
    text-shadow:0 0 .35vw rgba(255,255,255,.08);
  }

  body[data-page="battle"] .hh-build-metric.now strong {
    color:#f0fff4;
  }

  body[data-page="battle"] .hh-build-metric.str img {
    filter:drop-shadow(0 0 .55vw rgba(255,89,174,.82));
  }

  body[data-page="battle"] .hh-build-metric.int img {
    filter:drop-shadow(0 0 .55vw rgba(85,190,255,.78));
  }

  body[data-page="battle"] .hh-build-metric.now::before {
    border-color:#7aeba0;
    background:radial-gradient(circle,#85f0a8 0 .14vw,transparent .18vw);
    box-shadow:0 0 .7vw rgba(111,227,151,.76),inset 0 0 .3vw rgba(111,227,151,.18);
  }

  body[data-page="battle"] .hh-context-grid {
    gap:.15vw;
    margin-top:.25vw;
    max-height:5.2vw;
    overflow:hidden;
  }

  body[data-page="battle"] .hh-context-grid > label {
    min-height:1.05vw;
  }

  body[data-page="battle"] .hh-context-grid > label :is(input,textarea) {
    height:.95vw;
  }

  body[data-page="battle"] .hh-context-grid > label textarea {
    overflow-y:auto!important;
    scrollbar-width:none;
  }

  body[data-page="battle"] .hh-context-grid > label textarea::-webkit-scrollbar {
    width:0;
    height:0;
    display:none;
  }
}

@media (max-width:1180px) {
  body[data-page="battle"] #page-battle.hit-help-rebuild { gap:12px; }
  .hh-header { grid-template-columns:1fr; }
  .hh-build { min-height:122px; }
  .hh-duel { max-height:none; aspect-ratio:auto; grid-template-columns:minmax(0,1fr) 132px minmax(0,1fr); padding-right:0; }
  .hh-duel-art { inset:0; width:100%; transform:none; }
  .hh-fighter.you { padding-left:34%; }
  .hh-fighter.opponent { padding-right:34%; }
  .hh-opponent-rail { display:none; }
  .hh-midrow { grid-template-columns:1fr 1fr; }
  .hh-save-panel { grid-column:1 / -1; min-height:108px; }
  .hh-bottom { grid-template-columns:1fr .46fr; }
  .hh-saved { grid-column:1 / -1; }
}
@media (max-width:790px) {
  body[data-page="battle"] .main-content { padding:8px 12px 90px!important; }
  .hh-header { min-height:0; }
  .hh-heading { padding:8px 4px; }
  .hh-heading h1 { font-size:2.7rem!important; }
  .hh-build { grid-template-columns:1fr; }
  .hh-build-metrics { grid-template-columns:repeat(3,minmax(150px,1fr)); overflow:auto; }
  .hh-duel {
    min-height:690px;
    grid-template-columns:1fr;
    grid-template-rows:1fr auto 1fr;
  }
  .hh-duel-art { object-fit:cover; object-position:center; opacity:.52; }
  .hh-duel::after { background:linear-gradient(180deg,rgba(2,4,11,.18),rgba(2,4,11,.78) 34%,rgba(2,4,11,.72) 66%,rgba(2,4,11,.18)); }
  .hh-fighter { min-height:250px; }
  .hh-fighter.you,
  .hh-fighter.opponent { padding:18px; text-align:left; }
  .hh-fighter.opponent .hh-fighter-head { justify-items:start; }
  .hh-opponent-name { text-align:left; }
  .hh-matchup { min-height:150px; justify-content:center; gap:8px; padding-block:12px; border:1px solid rgba(255,255,255,.06); }
  .hh-action-buttons { grid-template-columns:1fr 1fr; }
  .hh-fighter.opponent .hh-power-row { grid-template-columns:34px minmax(0,1fr); }
  .hh-fighter.opponent .hh-power-row img { grid-column:1; }
  .hh-fighter.opponent .hh-power-track { grid-column:2; }
  .hh-power-input { text-align:left; }
  .hh-midrow,
  .hh-bottom { grid-template-columns:1fr; }
  .hh-save-panel,
  .hh-saved { grid-column:auto; }
  .hh-result-signal { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .hh-analysis-live { grid-template-columns:1fr 1fr; }
  .hh-analysis-live > div:nth-child(2) { border-right:0; }
  .hh-analysis-live > div:nth-child(-n+2) { border-bottom:1px solid rgba(255,255,255,.07); }
  .hh-history-controls { grid-template-columns:1fr 1fr; }
  .hh-history-controls button { grid-column:1 / -1; min-height:30px; }
  .hh-hit-row { grid-template-columns:75px minmax(80px,1fr) 60px 45px 24px; }
  .hh-hit-row .hh-row-stat { display:none; }
}
@media (max-width:520px) {
  .hh-build-metrics { grid-template-columns:repeat(3,150px); }
  .hh-current-build strong { font-size:1.05rem; }
  .hh-context-grid,
  .hh-advanced-grid { grid-template-columns:1fr; }
  .hh-result-signal { grid-template-columns:1fr; }
  .hh-result-signal > div { min-height:84px; border-right:0; border-bottom:1px solid rgba(255,255,255,.07); padding:10px 0; }
  .hh-result-signal > div + div { padding-left:0; }
  .hh-result-signal > div:last-child { border-bottom:0; }
  .hh-analysis-live { grid-template-columns:1fr; }
  .hh-analysis-live > div { border-right:0!important; border-bottom:1px solid rgba(255,255,255,.07); }
  .hh-analysis-live > div:last-child { border-bottom:0; }
  .hh-saved-title small { display:none; }
  .hh-hit-row { grid-template-columns:70px minmax(65px,1fr) 55px 24px; }
  .hh-hit-row .hh-row-action { display:none; }
}

/* v10.14: desktop-only Hit Help intro treatment; intentionally isolated from all other panels */
@media (min-width:1181px) {
  html:has(body[data-page="battle"]),
  body[data-page="battle"] {
    height:100%;
    overflow-y:hidden!important;
  }
  body[data-page="battle"] .sidebar {
    height:100vh!important;
    height:100dvh!important;
    overflow-x:hidden!important;
    overflow-y:auto!important;
    scrollbar-gutter:stable;
    scrollbar-width:thin;
    scrollbar-color:rgba(255,83,174,.58) rgba(4,6,15,.72);
  }
  body[data-page="battle"] .sidebar::-webkit-scrollbar {
    width:8px;
  }
  body[data-page="battle"] .sidebar::-webkit-scrollbar-track {
    background:rgba(4,6,15,.72);
  }
  body[data-page="battle"] .sidebar::-webkit-scrollbar-thumb {
    border:2px solid rgba(4,6,15,.72);
    border-radius:999px;
    background:rgba(255,83,174,.58);
  }
  body[data-page="battle"] .command-secondary-nav {
    position:absolute!important;
    top:60.65vw!important;
    left:.829vw!important;
    right:.829vw!important;
    display:flex!important;
    flex-direction:column!important;
    gap:0!important;
    margin:0!important;
    padding:0!important;
  }
  body[data-page="battle"] .command-secondary-nav .tab {
    display:flex!important;
    width:100%!important;
    height:3.045vw!important;
    min-height:0!important;
  }
  body[data-page="battle"] .command-secondary-nav .tab[data-page="guides"],
  body[data-page="battle"] .command-secondary-nav .tab[data-page="profiles"] {
    display:none!important;
  }
  body[data-page="battle"] .premium-sidebar-card {
    position:absolute!important;
    top:67.05vw!important;
    left:.829vw!important;
    width:16.437vw!important;
    height:10.912vw!important;
    min-height:0!important;
    display:flex!important;
    margin:0!important;
    opacity:1!important;
  }
  body[data-page="battle"] .sidebar-footer {
    position:absolute!important;
    top:78.35vw!important;
    left:.829vw!important;
    right:.829vw!important;
    display:flex!important;
    padding:.55vw .35vw 1vw!important;
  }
  body[data-page="battle"] .sidebar::after {
    content:""!important;
    position:absolute!important;
    top:81.5vw!important;
    left:0!important;
    width:1px!important;
    height:1px!important;
    display:block!important;
  }
  body[data-page="battle"] .workspace {
    position:relative!important;
    height:100vh!important;
    height:100dvh!important;
    min-height:0!important;
    overflow:hidden!important;
  }
  body[data-page="battle"] .site-footer {
    position:absolute!important;
    left:0!important;
    right:0!important;
    bottom:0!important;
    z-index:8!important;
  }
  body[data-page="battle"] .main-content {
    padding-bottom:0!important;
  }
  body[data-page="battle"] .site-footer {
    min-height:0!important;
    margin-top:0!important;
    padding:5px 16px 6px!important;
    line-height:1.2!important;
  }
  body[data-page="battle"] #page-battle > .hh-header {
    grid-template-columns:minmax(0,1fr)!important;
  }
  body[data-page="battle"] #page-battle > .hh-header > .hh-heading {
    display:none!important;
  }
  body[data-page="battle"] #page-battle > .hh-header > .hh-heading {
    padding:18px 22px!important;
    border:1px solid rgba(255,68,159,.56)!important;
    border-radius:11px!important;
    background:
      radial-gradient(circle at 82% 18%,rgba(157,85,255,.16),transparent 12rem),
      radial-gradient(circle at 12% 112%,rgba(255,63,155,.11),transparent 14rem),
      linear-gradient(180deg,rgba(8,10,24,.98),rgba(2,6,15,.98))!important;
    box-shadow:inset 0 1px rgba(255,255,255,.05),0 0 22px rgba(255,37,140,.08)!important;
  }
  body[data-page="battle"] #page-battle > .hh-header > .hh-heading::before {
    opacity:1!important;
    filter:none!important;
    background:
      linear-gradient(110deg,transparent 0 60%,rgba(255,72,166,.055)),
      repeating-linear-gradient(90deg,transparent 0 31px,rgba(255,93,181,.025) 32px,transparent 33px 64px)!important;
  }
  body[data-page="battle"] #page-battle > .hh-header > .hh-heading::after {
    opacity:.62!important;
    background:
      radial-gradient(circle at 78% 24%,rgba(255,84,171,.52) 0 2px,transparent 3px),
      radial-gradient(circle at 88% 68%,rgba(157,85,255,.44) 0 1px,transparent 2px)!important;
  }
  body[data-page="battle"] #page-battle > .hh-header > .hh-heading h1 {
    margin:0 0 7px!important;
    font-size:clamp(2.15rem,2.75vw,3rem)!important;
    line-height:.94!important;
  }
  body[data-page="battle"] #page-battle > .hh-header > .hh-heading h1 img {
    width:34px!important;
    height:34px!important;
  }
  body[data-page="battle"] #page-battle > .hh-header > .hh-heading > p {
    margin:0!important;
    color:#aaa2af!important;
    font-size:.82rem!important;
    line-height:1.35!important;
  }
}

/* One shared clash scene, centered on the matchup diamond. */
@media (min-width:1181px) {
  body[data-page="battle"] .hh-fighter.you::before {
    clip-path:none;
    transform:translateY(-.69%);
    -webkit-mask-image:linear-gradient(90deg,#000 0 28%,transparent 45%);
    mask-image:linear-gradient(90deg,#000 0 28%,transparent 45%);
  }
  body[data-page="battle"] .hh-fighter.opponent::before {
    clip-path:none;
    transform:translateY(-.69%);
    -webkit-mask-image:linear-gradient(90deg,transparent 55%,#000 72% 100%);
    mask-image:linear-gradient(90deg,transparent 55%,#000 72% 100%);
  }
  body[data-page="battle"] .hh-duel-art {
    -webkit-mask-image:linear-gradient(90deg,transparent 34%,#000 43%,#000 57%,transparent 66%);
    mask-image:linear-gradient(90deg,transparent 34%,#000 43%,#000 57%,transparent 66%);
    inset:-.69% auto auto 1.95%;
    width:86%;
    height:100%;
    object-fit:fill;
    opacity:1;
    transform:none;
    filter:saturate(1.05) contrast(1.04) brightness(.84);
  }
  body[data-page="battle"] .hh-duel::after {
    background:
      linear-gradient(90deg,transparent 8%,#ff408f 17%,#ff80bf 43%,#fff 45.36%,#68bcff 48%,#398bff 76%,transparent 86%) left 50% / 100% 2px no-repeat;
    filter:drop-shadow(0 0 5px #bd59c5);
  }
  body[data-page="battle"] .hh-matchup { background:transparent; }
  body[data-page="battle"] .hh-action-button {
    left:27%;
    width:46%;
    top:calc(50% - 9px);
    transform:translateY(-100%);
  }
  body[data-page="battle"] .hh-action-button[data-hit-stat="intelligence"] {
    left:27%;
    width:46%;
    top:calc(50% + 9px);
    transform:none;
  }
  body[data-page="battle"] .hh-action-buttons::after { top:50%; }
  body[data-page="battle"] .hh-matchup-summary { top:76%; height:8%; }
  body[data-page="battle"] .hh-result-toggle { top:85%; }
  body[data-page="battle"] .hh-hit-time { top:93%; }
  body[data-page="battle"] .hh-matchup > span { top:13%; }
}

/* Hit Help desktop alignment: content-sized text rows, aligned panel edges. */
@media (min-width:1181px) {
  body[data-page="battle"] .hh-midrow {
    grid-template-columns:minmax(0,1.08fr) minmax(0,.58fr) minmax(0,.78fr);
    height:auto;
    min-height:9.8vw;
    align-items:stretch;
  }
  body[data-page="battle"] .hh-midrow > :is(.hh-result-signal,.hh-context,.hh-save-panel) {
    height:auto;
    min-height:9.8vw;
    box-sizing:border-box;
  }
  body[data-page="battle"] .hh-context { overflow:auto; }
  body[data-page="battle"] .hh-context-grid { max-height:none; overflow:visible; }
  body[data-page="battle"] .hh-context-grid > label { min-height:1.35vw; }
  body[data-page="battle"] .hh-context-grid > label :is(input,textarea) { height:1.2vw; }
  body[data-page="battle"] .hh-result-signal > div {
    grid-template-rows:2.1em minmax(2.5em,1fr) 3em;
    align-content:stretch;
    align-items:start;
  }
  body[data-page="battle"] .hh-result-signal > div > strong { align-self:center; margin:0; }
  body[data-page="battle"] .hh-result-signal > div > small { margin:0; line-height:1.35; }
  body[data-page="battle"] .hh-bottom {
    grid-template-columns:minmax(0,1.08fr) minmax(0,.40fr) minmax(0,.96fr);
  }
  body[data-page="battle"] .hh-matchup-summary {
    top:77%;
    height:auto;
    grid-template-rows:auto auto;
    gap:3px 6px;
    align-items:center;
    line-height:1.1;
  }
  body[data-page="battle"] .hh-matchup-summary > em { white-space:normal; }
  body[data-page="battle"] .hh-result-toggle { top:auto; bottom:3%; }
  body[data-page="battle"] .hh-hit-time {
    top:3%;
    width:100%;
    font-size:clamp(9px,.55vw,12px);
    line-height:1.2;
  }
  body[data-page="battle"] .hh-matchup > span { top:16%; }
}

/* Size the desktop composition from available height as well as width. */
@media (min-width:1181px) {
  body[data-page="battle"] .app-frame { position:fixed!important; inset:0!important; height:100dvh!important; }
  body[data-page="battle"] .workspace { display:flex!important; flex-direction:column; height:100%!important; }
  body[data-page="battle"] .topbar { flex:0 0 auto; }
  body[data-page="battle"] .main-content { flex:1 1 0!important; min-height:0!important; height:auto!important; overflow:auto!important; padding-bottom:8px!important; }
  body[data-page="battle"] .site-footer { position:static!important; flex:0 0 auto; }
  body[data-page="battle"] #page-battle.hit-help-rebuild {
    height:100%!important; min-height:0!important;
    grid-template-rows:min(8.483vw,12dvh) minmax(0,1fr);
    overflow:visible;
  }
  body[data-page="battle"] #page-battle .hh-header,
  body[data-page="battle"] #page-battle .hh-build { height:100%; min-height:0; }
  body[data-page="battle"] #page-battle .hh-form {
    height:100%; min-height:0;
    grid-template-rows:minmax(260px,1fr) min(9.8vw,20dvh) min(11.5vw,23dvh);
  }
  body[data-page="battle"] #page-battle :is(.hh-duel,.hh-midrow,.hh-bottom) {
    height:100%; min-height:0; max-height:none;
  }
  body[data-page="battle"] #page-battle :is(.hh-result-signal,.hh-context,.hh-save-panel,.hh-answer,.hh-farm,.hh-saved) {
    height:100%; min-height:0; overflow:auto;
  }
  body[data-page="battle"] #page-battle .hh-result-signal > div { grid-template-rows:2em minmax(0,1fr) 2.8em; }
  body[data-page="battle"] #page-battle .hh-answer { grid-template-rows:auto minmax(0,1fr); }
  body[data-page="battle"] #page-battle #battleAnalysis,
  body[data-page="battle"] #page-battle .hh-analysis-live { min-height:0; height:100%; overflow:auto; padding:8px; }
  body[data-page="battle"] #page-battle .hh-context-grid { margin-top:4px; gap:2px; }
  body[data-page="battle"] #page-battle .hh-context-grid > label { min-height:min(1.35vw,2.7dvh); }
  body[data-page="battle"] #page-battle .hh-context-grid > label :is(input,textarea) { height:min(1.2vw,2.4dvh); }
  body[data-page="battle"] #page-battle .hh-submit { min-height:min(2.65vw,5dvh); }
  body[data-page="battle"] #page-battle .hh-farm { gap:3px; }
  body[data-page="battle"] #page-battle .hh-relation { min-height:min(6.169vw,14dvh); }
  body[data-page="battle"] #page-battle .hh-action-button {
    width:min(46%,18dvh); left:50%; margin-left:0;
    transform:translate(-50%,-100%);
  }
  body[data-page="battle"] #page-battle .hh-action-button[data-hit-stat="intelligence"] { transform:translateX(-50%); }
}

@media (min-width:1181px) {
  body[data-page="battle"] #page-battle .hh-result-signal { grid-template-rows:minmax(0,1fr); }
  body[data-page="battle"] #page-battle .hh-result-signal > div {
    min-height:0; grid-template-rows:24% 43% 33%;
  }
  body[data-page="battle"] #page-battle .hh-result-signal > div > * { min-height:0; }
  body[data-page="battle"] #page-battle .hh-context { display:flex; flex-direction:column; }
  body[data-page="battle"] #page-battle .hh-context > .hh-kicker { flex:0 0 auto; line-height:1.2; }
  body[data-page="battle"] #page-battle .hh-context-grid { min-height:0; flex:1 1 auto; }
  body[data-page="battle"] #page-battle .hh-context-grid > label { min-height:0; }
  body[data-page="battle"] #page-battle .hh-context-grid > label :is(input,textarea) { min-height:0!important; }
}

/* Keep build text at its natural line height inside the compact header. */
@media (min-width:1181px) {
  body[data-page="battle"] #page-battle .hh-current-build {
    display:flex; flex-direction:column; justify-content:center; align-items:flex-start;
    gap:2px; padding:4px .771vw;
  }
  body[data-page="battle"] #page-battle .hh-current-build > :is(span,strong,small) {
    flex:0 0 auto; width:100%; line-height:1.15!important;
  }
  body[data-page="battle"] #page-battle .hh-current-build strong { font-size:min(1.254vw,2.6dvh)!important; }
  body[data-page="battle"] #page-battle .hh-current-build :is(span,small) { font-size:min(.67vw,1.4dvh)!important; }
  body[data-page="battle"] #page-battle .hh-context-grid #battleNotes {
    line-height:1.2!important; padding:0 4px!important;
    height:1.3em; min-height:1.3em!important;
  }
}

body[data-page="battle"] #page-battle .hh-context-launcher { justify-content:space-between; gap:6px; }
.hh-context-launcher > p,.hh-context-launcher > small { margin:0; color:#b8adbf; font-size:12px; }
.hh-context-launcher > button { padding:9px 14px; border:1px solid #a44079; border-radius:8px; background:#351329; color:#ffe6f3; cursor:pointer; }
body #hitContextDialog {
  position:fixed; inset:0; margin:auto; width:min(720px,calc(100vw - 32px));
  height:fit-content; max-height:calc(100dvh - 40px); box-sizing:border-box;
  padding:24px; overflow:auto; border:1px solid #a44079; border-radius:20px;
  background:linear-gradient(145deg,#201226,#080d19); color:#f8edf5;
  font:15px/1.4 Inter,system-ui,sans-serif; text-align:left;
}
body #hitContextDialog:not([open]) { display:none; }
#hitContextDialog::backdrop { background:rgba(0,0,0,.72); backdrop-filter:blur(5px); }
body #hitContextDialog header,body #hitContextDialog footer { display:flex; align-items:center; justify-content:space-between; gap:16px; }
body #hitContextDialog h2 { font-size:24px!important; margin:0; color:#ffd1e9; }
body #hitContextDialog p { margin:6px 0; font-size:14px; color:#bcb1c5; }
body #hitContextDialog button { border:1px solid #a44079; border-radius:9px; background:#52203e; color:#fff; padding:10px 20px; font:inherit; cursor:pointer; }
body #hitContextDialog .hit-context-fields,
body #hitContextDialog .hit-context-extra-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
body #hitContextDialog .hit-context-fields { margin:24px 0; }
body #hitContextDialog label { display:flex; flex-direction:column; align-items:stretch; gap:7px; font:14px/1.4 Inter,system-ui,sans-serif; color:#e4d5e5; min-width:0; }
body #hitContextDialog .hh-context-label { font:inherit; }
body #hitContextDialog .hh-context-label svg { width:18px; height:18px; }
body #hitContextDialog :is(input,select,textarea) {
  width:100%!important; min-width:0; height:42px!important; min-height:42px!important;
  box-sizing:border-box; border:1px solid #62415f!important; border-radius:8px!important;
  background:#090c16!important; color:#fff!important; padding:10px 12px!important;
  font:15px/1.4 Inter,system-ui,sans-serif!important; text-align:left!important;
}
body #hitContextDialog #battleNotes { height:130px!important; min-height:130px!important; resize:vertical; }
body #hitContextDialog .hit-context-fields > label:has(textarea),
body #hitContextDialog .hit-context-extra { grid-column:1/-1; }
body #hitContextDialog footer { border-top:1px solid #503347; padding-top:16px; }
body #hitContextDialog footer small { font-size:13px; color:#bcb1c5; }
@media(max-width:600px) {
  body #hitContextDialog .hit-context-fields,body #hitContextDialog .hit-context-extra-grid { grid-template-columns:1fr; }
  body #hitContextDialog { padding:18px; }
}
