/* Shared navigation and battle entry. */
.app-header, .main-nav { background: #0b262b; }
.app-header, .app-header:has(.guide-link) { flex-wrap: nowrap; }
.app-header .brand { white-space: nowrap; }
.app-header .ui-fullscreen, .loan-op-match .game-shell > header .ui-fullscreen {
  border: 1px solid #b39a65;
  border-radius: 8px;
  background: #203d39;
  color: #fff3d4;
  font-size: 13px;
  padding: 6px 10px;
  min-height: 42px;
  white-space: nowrap;
  flex: none;
  margin-inline-start: 0;
}
[data-game-fullscreen] :is(.app-header, .loan-op-match .game-shell > header) .ui-fullscreen { min-inline-size: 104px; }
[data-game-fullscreen] :is(.app-header, .loan-op-match .game-shell > header) {
  position: sticky;
  top: 0;
  z-index: 20;
}
[data-ui-fullscreen][hidden], #battle-recent[hidden] { display: none; }
[data-ui-fullscreen-exit] { display: none; }
:root[data-game-fullscreen] [data-ui-fullscreen-exit] { display: inline-flex; }
.home-help-heading { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; }
.home-help-heading .ui-fullscreen {
  min-height: 44px;
  margin-inline-start: auto;
  padding: 6px 12px;
  font-weight: 700;
}
#save-status:empty, #borrowed-error:empty, #mode-choices:empty, #mode-summary:empty { display: none; }
.prep-header-links { display: flex; align-items: center; gap: 16px; margin-inline: auto 0; }
.prep-header-links a, .battle-menu-help a, .prep-help a { color: #ffe5a8; }
.prep-header-links a:visited, .battle-menu-help a:visited, .prep-help a:visited { color: #ffe5a8; }
@media (min-width: 1000px) {
  .app-header { padding-inline: max(16px, calc((100vw - 1370px) / 2)); }
  .app-header .main-nav, .home-screen .app-header .main-nav {
    position: static;
    height: auto;
    padding: 0;
    border: 0;
    background: none;
    box-shadow: none;
    display: flex !important;
    gap: 5px;
    margin-inline: auto;
  }
  .app-header .main-nav button { display: flex; align-items: center; padding: 8px; white-space: nowrap; }
  .app-header .main-nav button > span:first-child { font-size: 16px; }
  .app-header .guide-link { margin-left: 0; }
  body:has(> .app-header:not(.borrowed-header)) { padding-bottom: 0; }
}
@media (max-width: 1099px) {
  .app-header > .guide-link { display: none; }
}
@media (max-width: 599px) {
  .app-header { min-height: 56px; padding: 5px 10px; gap: 6px; }
  .app-header .brand { font-size: 13px; }
  .app-header .brand > span:first-child { display: none; }
  .app-header .wallet { gap: 5px; }
  .app-header .wallet b { font-size: 14px; }
  .app-header > button { padding-inline: 5px; }
  .app-header .ui-fullscreen { font-size: 12px; padding-inline: 6px; }
  .app-header .brand { min-width: 0; overflow: hidden; }
  .app-header .brand > span:last-child { overflow: hidden; text-overflow: ellipsis; }
  .prep-header-links { gap: 8px; font-size: 13px; }
  .prep-header-links a:not(:first-child) { display: none; }
}
.battle-mode-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; }
.battle-mode-card, .battle-mode-card:visited {
  display: grid;
  align-content: center;
  min-height: 132px;
  gap: 6px;
  padding: 16px;
  border: 1px solid #a7905d;
  border-radius: 12px;
  background: #173a38;
  color: #fff3d5;
  text-decoration: none;
}
.battle-mode-card:hover { background: #244a41; border-color: #ffde9a; }
.battle-mode-card strong { font-size: 18px; }
.battle-mode-card span { color: #ffdfa0; font-size: 14px; font-weight: 700; }
.battle-mode-card small { color: #e3ede2; font-size: 13px; line-height: 1.5; }
.battle-resumes { display: flex; flex-wrap: wrap; gap: 8px; }
.battle-resumes .button { min-height: 48px; }
.battle-resumes > details { flex-basis: 100%; }
.battle-resumes > details > summary { width: fit-content; cursor: pointer; color: #ffe4a8; font-size: 14px; }
.battle-resumes > details .button { margin: 6px 6px 0 0; }
.battle-mission-fold summary, .borrowed-fold summary, .mode-archive summary { cursor: pointer; color: #fff1d1; font-weight: 700; }
.battle-mission-fold summary strong { margin-left: 10px; color: #ffe0a0; font-size: 14px; }
.battle-mission-fold .battle-reward-panel { margin: 10px 0 0; padding: 0; border: 0; background: none; }
.battle-mission-fold .battle-reward-panel h2 { display: none; }
.battle-menu-help { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
#main .cpu-gate { min-height: 0; align-content: start; gap: 8px; }
#main .cpu-gate h2, #main .cpu-gate p { margin: 0; }
.borrowed-main { width: min(100%, 1040px); padding: 22px clamp(12px, 3vw, 32px); gap: 12px; }
.borrowed-main h1, .borrowed-main p { margin-block: 0; }
.borrowed-main #mode-summary { display: grid; gap: 4px; }
.borrowed-launch { display: flex; gap: 8px; flex-wrap: wrap; }
.borrowed-launch button { min-height: 52px; min-width: min(210px,100%); font-size: 17px; }
.borrowed-launch button[hidden] { display: none; }
.borrowed-fold, .borrowed-main .mode-archive {
  border: 1px solid #8c8058;
  background: #153534;
  border-radius: 10px;
  padding: 12px 14px;
}
.borrowed-fold + .borrowed-fold, .mode-archive + .borrowed-fold { margin-top: 6px; }
.borrowed-fold summary small { color: #e3ede2; margin-left: 8px; font-size: 13px; font-weight: 500; }
.borrowed-main .borrowed-setup { margin: 10px 0 0; }
@media (max-width: 950px) {
  .battle-mode-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 599px) {
  .battle-mode-grid { grid-template-columns: minmax(0,1fr); gap: 7px; }
  .battle-mode-card { min-height: 67px; padding: 9px 12px; gap: 1px; }
  .battle-mode-card strong { font-size: 16px; }
  .battle-mode-card span { font-size: 13px; }
  .battle-resumes > .button { width: 100%; }
  .borrowed-launch button { flex: 1 1 auto; min-width: 0; min-height: 48px; font-size: 15px; }
  .borrowed-library { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
}

/* One centered table with two aligned rows and a horizontal hand. */
.battle-v05.loan-op-match[data-fit-battle] { height: auto; display: block; }
.battle-v05.loan-op-match[data-fit-battle] .game-shell {
  height: auto;
  min-height: 0;
  display: block;
}
.loan-op-match .game-shell > header {
  background: #0b262b;
  padding-inline: max(10px,calc((100% - 1380px)/2));
  gap: 6px;
}
.loan-op-match .game-shell > header strong { margin-right: auto; white-space: nowrap; }
.loan-op-match .game-shell > header > :is(button,a) { font-size: 13px; min-height: 42px; white-space: nowrap; }
.loan-op-match .game-shell > header .guide-link { display: none; }
.loan-op-match:has(.result-screen, .welcome, .stop-screen) .history-toggle { display: none; }
[data-game-fullscreen] .loan-op-match {
  --fullscreen-header-height: 70px;
  position: relative;
}
[data-game-fullscreen] .loan-op-match > .prototype-tag {
  position: absolute;
  inset: var(--fullscreen-header-height) 0 auto;
}
[data-game-fullscreen] .loan-op-match .game-shell > header {
  min-height: var(--fullscreen-header-height);
  padding-inline: max(15px, calc((100vw - 1372px) / 2));
}
[data-game-fullscreen] .loan-op-match .game-shell > .battle-main { padding-top: 22px; }
.battle-v05.loan-op-match .r7-arena, body.cpu-match .loan-op-match .r7-arena {
  --board-card: clamp(62px, calc((100dvh - 295px) * .207), 148px);
  --leader-card: var(--board-card);
  --hand-card: clamp(72px, calc((100dvh - 295px) * .233), 164px);
  --table-gap: clamp(4px,.7vw,10px);
  display: grid;
  grid-template-areas: "enemy" "center" "self" "hand";
  grid-template-columns: minmax(0,1fr);
  grid-template-rows: auto auto auto auto;
  width: 100%;
  max-width: 1400px;
  height: auto;
  min-height: 0;
  margin-inline: auto;
  padding: 6px;
  gap: 6px;
}
.battle-v05.loan-op-match .r7-arena.history-open {
  grid-template-areas: "enemy logs" "center logs" "self logs" "hand logs";
  grid-template-columns: minmax(0,1fr) clamp(150px,16vw,218px);
}
.battle-recent {
  grid-area: logs;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 10px 12px;
  border-left: 1px solid #a7905d;
  background: #102d31;
  color: #fff0d1;
  font-size: 14px;
}
.battle-recent h2 { margin: 0; font-size: 16px; }
.battle-recent ol { display: grid; gap: 6px; padding-left: 20px; overflow-wrap: anywhere; }
.battle-recent-actions { display: grid; gap: 6px; margin-top: auto; }
.battle-recent button { min-height: 42px; }
.loan-op-match .r7-arena > .battle-side { grid-template-columns: minmax(0,1fr); min-height: 0; gap: 3px; padding: 3px 5px; }
.loan-op-match .r7-arena > .self-side .side-rail { grid-row: 2; }
.battle-v05.loan-op-match .r7-arena .duel-row {
  grid-template-columns: var(--leader-card) minmax(0,1fr);
  width: min(100%,calc(var(--board-card) * 6 + var(--table-gap) * 5));
  justify-self: center;
  gap: var(--table-gap);
  align-items: start;
}
.battle-v05.loan-op-match .r7-arena .field {
  display: grid;
  grid-template-columns: repeat(5,minmax(0,1fr));
  align-items: start;
  width: 100%;
  max-width: none;
  overflow: visible;
  padding: 0;
  gap: var(--table-gap);
}
.battle-v05.loan-op-match .r7-arena :is(.unit-wrap,.slot,.unit-card) { width: 100%; max-width: none; }
.battle-v05.loan-op-match .r7-arena .leader-wrap { width: 100%; }
.battle-v05.loan-op-match .r7-arena :is(.leader-card,.unit-card) {
  display: grid;
  grid-template-rows: auto auto;
  height: auto;
  min-height: 0;
  aspect-ratio: auto;
}
.battle-v05.loan-op-match .r7-arena :is(.leader-card,.unit-card) > .printed-face {
  position: relative;
  inset: auto;
  width: 100%;
  height: auto;
  aspect-ratio: 5/7;
}
.battle-v05.loan-op-match .r7-arena :is(.leader-card,.unit-card) > .current-state {
  position: static;
  display: flex;
  justify-content: center;
  align-items: baseline;
  gap: 3px;
  width: 100%;
  min-height: 0;
  margin: 2px 0 0;
  padding: 0;
  border: 0;
  color: #fff3d2;
  background: transparent;
  font-size: 16px;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
}
.current-state small { font-size: 11px; color: #ffe3a7; }
.loan-op-match .side-rail { flex-direction: row; align-items: center; flex-wrap: wrap; gap: 4px 12px; }
.loan-op-match .side-rail .status-line {
  display: flex !important;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px 10px !important;
  overflow: visible;
}
.loan-op-match .side-label, .loan-op-match .hand-count-label { color: #fff3d4; font-size: 14px; }
.loan-op-match .side-rail :is(.energy,.barrier) {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 26px;
  padding: 1px 4px;
  font-size: 14px;
  font-weight: 700;
  color: #fff3d4;
  white-space: nowrap;
}
.loan-op-match .side-rail :is(.energy,.barrier) b { font-size: 16px; }
.battle-pips { display: inline-flex; align-items: center; gap: 3px; }
.battle-pips i { display: block; width: 8px; height: 8px; border: 1px solid #abada0; }
.life-pips i { border-radius: 50%; }
.life-pips .filled { background: #ff9c97; border-color: #ff9c97; }
.energy-pips .filled { background: #ffce70; border-color: #ffce70; }
.loan-op-match .side-rail .zone-count { color: #e5ebde; font-size: 12px; }
.loan-op-match .side-rail button.zone-count { padding: 2px 4px; min-height: 27px; }
.loan-op-match .side-rail .feedback-zone { align-self: stretch; min-height: 0; }
.loan-op-match .r7-arena > .center-line { padding-inline: 4px; gap: 7px; min-height: 48px; }
.loan-op-match .r7-arena > .center-line { position: relative; z-index: 11; }
.loan-op-match .r7-arena .phase-cue { position: relative; z-index: 11; background: #123033; border-radius: 6px; padding-inline: 4px; }
.loan-op-match .r7-arena .phase-cue strong { font-size: 16px; white-space: nowrap; }
.loan-op-match .r7-arena .phase-cue small, .loan-op-match .r7-arena .action-tray .hint { font-size: 13px; }
.loan-op-match .r7-arena .playing-card.can-act {
  outline: 3px solid #9ee7b4;
  outline-offset: 1px;
}
.loan-op-match .r7-arena .playing-card.can-attach-only {
  outline: 1px dashed #bbd4c0;
  outline-offset: 1px;
}
.loan-op-match .r7-arena .playing-card.card-drop-ready { outline: 3px solid #ffe199; }
.loan-op-match .r7-arena .playing-card.card-drop-over { outline: 4px solid #fff3ca; }
.loan-op-match .turn-footer button:disabled {
  opacity: 1;
  background: #263c3a;
  border-color: #596965;
  color: #b9c2bf;
  box-shadow: none;
  outline: none;
  cursor: default;
}
.loan-op-match .find-playable {
  color: #ffebb0;
  border-color: #d5bc7b;
  min-height: 30px;
  padding: 2px 7px;
  font-size: 12px;
  white-space: nowrap;
}
.loan-op-match .find-playable[hidden] { display: none; }
.loan-op-match .r7-arena .action-tray .reaction-pass { order: -2; }
.loan-op-match .r7-arena .action-tray .reaction-choices { order: -1; }
.turn-footer { display: flex; align-items: center; gap: 8px; }
.loan-op-match .turn-footer button { min-height: 44px; font-size: 14px; white-space: nowrap; }
.turn-footer .turn-guide { display: none; }
@media (min-width: 800px) {
  .loan-op-match:not(:has(.history-open)) .turn-footer .turn-guide { display: inline-block; }
}
.loan-op-match .r7-arena .hand-rail { display: block; padding-inline: 5px; }
.loan-op-match .r7-arena .hand-toolbar { display: flex; min-height: 28px; padding-inline: 4px; }
.loan-op-match .r7-arena .hand-scroll-controls button { min-height: 28px; min-width: 34px; }
.loan-op-match .r7-arena .hand-feedback-zone { position: relative; inset: auto; height: auto; min-height: 0; }
.battle-v05.loan-op-match .r7-arena .hand {
  display: flex !important;
  justify-content: safe center;
  align-items: center;
  overflow: auto hidden;
  height: auto;
  padding: 4px 4px 7px !important;
}
.battle-v05.loan-op-match .r7-arena .hand > .playing-card {
  flex: 0 0 var(--hand-card);
  width: var(--hand-card);
  height: auto;
  aspect-ratio: auto;
}
.battle-v05.loan-op-match .r7-arena .hand > .playing-card > .printed-face {
  position: relative;
  inset: auto;
  height: auto;
  aspect-ratio: 5/7;
}

/* Card inspection keeps the action and its reason in view. */
.loan-op-match #battle-modal.battle-card-sheet {
  width: min(720px,calc(100% - 24px));
  max-width: none;
  max-height: min(90dvh,760px);
  padding: 0;
  overflow: hidden;
  background: #143231;
}
.loan-op-match #battle-modal.battle-card-sheet #battle-modal-body {
  display: flex;
  flex-direction: column;
  max-height: inherit;
  box-sizing: border-box;
  gap: 8px;
  padding: 12px;
}
.battle-card-sheet .modal-head { flex: none; gap: 6px; }
.battle-card-sheet .modal-head h2 { margin: 0; font-size: clamp(17px,2.5vw,23px); }
.card-sheet-content { flex: 1 1 auto; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 2px; }
.card-sheet-overview { display: grid; grid-template-columns: min(43%,300px,calc((100dvh - 185px) * 5 / 7)) minmax(0,1fr); gap: 14px; }
.loan-op-match .card-sheet-overview .card-zoom { display: block; width: 100%; }
.loan-op-match .card-sheet-overview .loan-printed-face {
  position: relative;
  display: block;
  inset: auto;
  width: 100%;
  height: auto;
  padding: 0;
  border: 0;
  aspect-ratio: 5/7;
}
.card-sheet-overview .runtime-surface:has(img[data-load-state="pending"])::after {
  content: 'カードを読込中';
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff3d4;
  font-size: 13px;
}
.card-sheet-copy p { margin: 0 0 8px; overflow-wrap: anywhere; }
.card-sheet-stats { color: #ffe4a8; font-size: 14px; font-weight: 700; }
.loan-op-match .card-sheet-copy .detail-text { color: #fff4dc; background: none; border: 0; padding: 0; font-size: 15px; line-height: 1.5; }
.loan-op-match .card-sheet-content .sheet-details { margin: 8px 0 0; padding: 6px; }
.loan-op-match .card-sheet-controls { flex: none; gap: 6px; border-top: 1px solid #9d8756; padding-top: 8px; }
.loan-op-match .card-sheet-controls .action-reason {
  flex: 0 0 100%;
  margin: 0;
  padding: 5px 7px;
  border-radius: 5px;
  background: #3d3324;
  color: #fff0cf;
  font-size: 14px;
}
.loan-op-match .card-sheet-controls button { min-height: 44px; }
.loan-op-match .card-sheet-controls .primary { flex: 1 1 auto; }

@media (max-width: 799px) {
  .battle-v05.loan-op-match .r7-arena, body.cpu-match .loan-op-match .r7-arena {
    --board-card: clamp(38px,calc((100vw - 50px) / 6),98px);
    --hand-card: clamp(74px,23vw,112px);
  }
  .battle-v05.loan-op-match .r7-arena.history-open {
    grid-template-areas: "enemy" "center" "self" "hand" "logs";
    grid-template-columns: minmax(0,1fr);
  }
  .battle-recent { border-left: 0; border-top: 1px solid #a7905d; }
  .loan-op-match .game-shell > header {
    flex-wrap: nowrap;
    min-height: 48px;
    gap: 4px;
    padding-inline: 5px;
  }
  .loan-op-match .game-shell > header strong { font-size: 12px; min-width: 0; flex: 1 1 auto; overflow: hidden; text-overflow: ellipsis; }
  .loan-op-match .game-shell > header .ui-fullscreen, .loan-op-match .game-shell > header > button { font-size: 11px; padding: 3px 5px; }
  .loan-op-match .game-shell > header .return-link, .loan-op-match .game-shell > header .operation-guide-entry { display: none; }
  .loan-op-match .r7-arena .current-state strong { font-size: 14px; }
  .loan-op-match .r7-arena .current-state small { font-size: 10px; }
  .loan-op-match .side-rail { gap: 1px 6px; }
  .loan-op-match .side-rail .status-line { gap: 1px 6px !important; }
  .loan-op-match .side-rail .resource-breakdown { display: none; }
  .loan-op-match .side-rail :is(.energy,.barrier) { padding-inline: 3px; }
  .loan-op-match .side-rail .zone-count { font-size: 11px; }
  .battle-pips { gap: 2px; }
  .battle-pips i { width: 6px; height: 6px; }
  .loan-op-match .r7-arena .phase-cue { min-width: max-content; flex: 0 0 auto; }
  .loan-op-match .r7-arena .phase-cue strong { font-size: 14px; }
  .loan-op-match .r7-arena .turn-tools { order: initial; flex: 2 1 170px; }
}
@media (max-width: 599px) and (orientation: portrait) {
  .battle-v05.loan-op-match .r7-arena:has(.turn-footer) {
    min-height: calc(100dvh - 74px);
    grid-template-rows: auto auto auto minmax(min-content,1fr);
    padding-bottom: calc(61px + env(safe-area-inset-bottom));
  }
  .loan-op-match .r7-arena:has(.turn-footer) .hand-rail { align-self: end; }
  .loan-op-match .r7-arena:not([data-phase="mulligan"]) > .center-line {
    block-size: 88px;
    flex-wrap: nowrap;
    align-items: center;
  }
  .loan-op-match .r7-arena:not([data-phase="mulligan"]) .turn-tools { flex: 1 1 0; }
  .loan-op-match .r7-arena:not([data-phase="mulligan"]) .action-tray {
    max-block-size: 80px;
    overflow: auto;
    align-content: flex-start;
  }
  .loan-op-match .r7-arena .duel-row {
    min-block-size: calc(var(--board-card) * 1.4 + 22px);
  }
  .loan-op-match .r7-arena .current-state { white-space: nowrap; }
  .loan-op-match .r7-arena .hand-rail { padding-inline: 2px; }
  .battle-v05.loan-op-match .r7-arena .hand {
    gap: 4px !important;
    padding-inline: 2px !important;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 2px;
  }
  .battle-v05.loan-op-match .r7-arena .hand > .playing-card {
    width: min(122px,calc((100% - 12px) / 4));
    flex-basis: min(122px,calc((100% - 12px) / 4));
    scroll-snap-align: start;
  }
  .loan-op-match .r7-arena[data-phase="mulligan"] > .center-line {
    display: grid;
    grid-template-columns: minmax(0,1fr);
    gap: 4px;
  }
  .loan-op-match .r7-arena[data-phase="mulligan"] .phase-cue { display: block; }
  .loan-op-match .r7-arena[data-phase="mulligan"] .phase-cue small { display: none; }
  .loan-op-match .r7-arena[data-phase="mulligan"] .action-tray {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
  .loan-op-match .r7-arena[data-phase="mulligan"] .action-tray :is(.hint,.last-battle-note) { grid-column: 1 / -1; }
  .loan-op-match .r7-arena[data-phase="mulligan"] .action-tray button { width: 100%; padding-inline: 4px; }
  .loan-op-match .turn-footer {
    position: fixed;
    z-index: 15;
    inset: auto 0 0;
    justify-content: flex-end;
    padding: 6px 10px calc(6px + env(safe-area-inset-bottom));
    border-top: 1px solid #a7905d;
    background: #0b262b;
  }
  .turn-footer .turn-guide { display: block; margin-right: auto; }
  .loan-op-match .turn-footer .end-turn-action { min-width: 116px; }
  .loan-op-match #battle-modal.battle-card-sheet {
    inset: auto 0 0;
    width: 100%;
    max-height: 78dvh;
    margin: 0;
    border-radius: 16px 16px 0 0;
  }
  .loan-op-match #battle-modal.battle-card-sheet #battle-modal-body { padding-bottom: calc(10px + env(safe-area-inset-bottom)); }
  .battle-card-sheet::backdrop { background: #07191a77; }
  .card-sheet-overview { grid-template-columns: min(38%,138px) minmax(0,1fr); gap: 10px; }
}
@media (max-width: 360px) {
  .loan-op-match .r7-arena .current-state small { font-size: 9px; }
  .loan-op-match .side-rail .status-line { gap: 1px 4px !important; }
}
@media (max-width: 360px) and (max-height: 620px) and (orientation: portrait) {
  .battle-v05.loan-op-match .r7-arena, body.cpu-match .loan-op-match .r7-arena {
    --board-card: 40px;
    --hand-card: 63px;
    gap: 4px;
    padding-top: 3px;
  }
  .loan-op-match:not(:has([data-op="puzzle-hints"],[data-op="boss-rule"])) > .prototype-tag { display: none; }
  .battle-v05.loan-op-match .r7-arena .hand > .playing-card { width: var(--hand-card); flex-basis: var(--hand-card); }
  .loan-op-match .r7-arena .hand-toolbar, .loan-op-match .r7-arena .hand-scroll-controls button { min-height: 25px; }
  .loan-op-match .r7-arena:not([data-phase="mulligan"]) > .center-line { block-size: 64px; }
  .loan-op-match .r7-arena:not([data-phase="mulligan"]) .action-tray { max-block-size: 58px; }
}
@media (min-width: 600px) and (max-height: 510px) and (orientation: landscape) {
  .loan-op-match > .prototype-tag { display: none; }
  .battle-v05.loan-op-match .r7-arena, body.cpu-match .loan-op-match .r7-arena {
    --board-card: clamp(39px,calc((100dvh - 290px) * .25),56px);
    --hand-card: calc(var(--board-card) + 5px);
    gap: 3px;
    padding-block: 2px;
  }
  .loan-op-match .r7-arena > .battle-side { padding-block: 1px; gap: 1px; }
  .loan-op-match .r7-arena > .center-line { min-height: 42px; }
  .loan-op-match .r7-arena .action-tray { max-block-size: 52px; overflow: auto; }
  .battle-v05.loan-op-match[data-fit-battle] .game-shell > header { min-height: 42px; height: 42px; }
}
@media (min-width: 600px) and (min-height: 511px) {
  .loan-op-match .r7-arena:not([data-phase="mulligan"]) > .center-line { block-size: 66px; }
  .loan-op-match .r7-arena:not([data-phase="mulligan"]) .action-tray { max-block-size: 60px; overflow: auto; }
}

/* A viewing-only match has its own notice instead of the fixed-height action strip. */
.loan-op-match .r7-arena[data-read-only] > .center-line {
  block-size: auto;
  flex-wrap: wrap;
  padding-block: 5px;
}
.loan-op-match .r7-arena[data-read-only] .action-tray {
  display: block;
  max-block-size: none;
  overflow: visible;
}
.writer-notice {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 10px;
  width: 100%;
}
.writer-notice p {
  flex: 1 1 20ch;
  min-width: 0;
  margin: 0;
  color: #fff3d4;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.writer-notice button { min-height: 44px; white-space: nowrap; }
@media (max-width: 599px) {
  .loan-op-match .r7-arena[data-read-only] > .center-line { display: grid; grid-template-columns: minmax(0,1fr); }
  .loan-op-match .r7-arena[data-read-only] .phase-cue { justify-self: start; }
  .loan-op-match .r7-arena[data-read-only] .action-tray { min-height: 0; }
  [data-game-fullscreen] .loan-op-match { --fullscreen-header-height: 56px; }
  [data-game-fullscreen] .loan-op-match .game-shell > header { padding-inline: 9px; }
  [data-game-fullscreen] .loan-op-match .game-shell > header .ui-fullscreen { font-size: 12px; }
}
@media (max-height: 510px) and (orientation: landscape) {
  [data-game-fullscreen] .loan-op-match { --fullscreen-header-height: 48px; }
  [data-game-fullscreen] .loan-op-match .game-shell > .battle-main { padding-top: 0; }
}
@media (max-width: 599px) and (min-height: 780px) and (orientation: portrait) {
  [data-game-fullscreen] .battle-v05.loan-op-match .r7-arena:has(.turn-footer) {
    --board-card: clamp(45px, calc((100vw - 42px) / 5.7), 105px);
    --hand-card: clamp(86px, 28vw, 134px);
    --table-gap: 3px;
    grid-template-rows: repeat(4,auto);
    align-content: center;
  }
  [data-game-fullscreen] .battle-v05.loan-op-match .r7-arena .hand > .playing-card {
    width: var(--hand-card);
    flex-basis: var(--hand-card);
  }
}

dialog.confirmation-sheet,
.loan-op-match #battle-modal.confirmation-sheet {
  box-sizing: border-box;
  width: min(100% - 24px, 510px);
  max-height: calc(100dvh - 24px);
  margin: auto;
  padding: 16px;
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid #a7905d;
  border-radius: 16px;
  background: #143231;
  color: #fff3d4;
}
dialog.confirmation-sheet::backdrop { background: #07191a77; }
.confirmation-sheet h2 { margin: 0; font-size: 20px; }
.confirmation-sheet p { margin: 8px 0 16px; line-height: 1.5; }
.confirmation-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.confirmation-actions button { min-height: 44px; }
.confirmation-actions .primary { background: #ecd18a; border-color: #f7e2ab; color: #162824; }
.confirmation-actions .confirmation-destructive { flex: 1 0 100%; background: #203d39; color: #fff3d4; }
.loan-op-match .r7-arena .unit-wrap, .loan-op-match .r7-arena .leader-wrap { position: relative; }
.loan-op-match .r7-arena .leader-card > .printed-face {
  border: 2px solid #f2cc75;
  border-radius: 6px;
}
.loan-op-match .combat-rested > .printed-face { filter: brightness(.7) saturate(.78); }
.battle-role, .battle-keyword {
  position: absolute;
  z-index: 6;
  top: 2px;
  left: 2px;
  border-radius: 3px;
  padding: 1px 3px;
  color: #fff8e6;
  background: #143c37;
  line-height: 1.2;
  font-size: clamp(10px,1.1vw,15px);
  font-weight: 800;
  pointer-events: none;
}
.battle-role { background: #f5d786; color: #24261b; }
.battle-keyword.rush { left: auto; right: 2px; background: #783333; }
.loan-op-match .r7-arena .current-state strong { font-size: clamp(15px,1.35vw,22px); }
.loan-op-match .r7-arena .quick-attack {
  position: absolute;
  z-index: 7;
  bottom: 0;
  right: 2px;
  min-height: 30px;
  padding: 2px 5px;
  border-color: #ebc86d;
  background: #213935;
  color: #fff3d2;
  font-size: clamp(11px,1.1vw,14px);
}
.loan-op-match .r7-arena :is(.leader-wrap,.unit-wrap):has(.quick-attack) .current-state { justify-content: flex-start; }
.loan-op-match .playing-card[data-attack-forecast]::after {
  content: attr(data-attack-forecast);
  position: absolute;
  z-index: 8;
  top: 45%;
  inset-inline: 0;
  padding: 4px 1px;
  border-radius: 4px;
  font-size: clamp(10px,1.1vw,15px);
  background: #183c30;
  color: #fff7de;
  font-weight: 750;
  pointer-events: none;
}
.loan-op-match .playing-card[data-attack-forecast-hit="false"]::after { background: #713b35; }
.combat-forecast { color: #ffe7a5; font-weight: 750; }
.loan-op-match .battle-main { position: relative; }
.loan-op-match .game-shell { position: relative; }
.combat-feedback-layer { position: absolute; inset: 0; z-index: 12; pointer-events: none; }
.guide-reason { font-weight: 700; }
.combat-forecast small { display: block; font-weight: 400; }
.loan-op-match .card-sheet-controls .combat-forecast { flex: 0 0 100%; margin: 0; }
.loan-op-match .r7-arena[data-acting-owner="0"]:not([data-read-only]):is([data-phase="block"],[data-phase="counter"]) .action-tray {
  display: grid;
  grid-template-columns: minmax(0,1fr) minmax(0,1fr);
  align-content: center;
  gap: 4px 10px;
}
.loan-op-match .r7-arena[data-acting-owner="0"]:is([data-phase="block"],[data-phase="counter"]) .action-tray > .preview {
  grid-row: 1;
  grid-column: 1 / -1;
  font-size: 15px;
  text-align: center;
  line-height: 1.25;
}
.loan-op-match .r7-arena[data-acting-owner="0"]:is([data-phase="block"],[data-phase="counter"]) .action-tray:has(.preview) .hint { display: none; }
.loan-op-match .r7-arena[data-acting-owner="0"][data-phase="block"] .action-tray > .reaction-pass,
.loan-op-match .r7-arena[data-acting-owner="0"][data-phase="counter"] .action-tray > .reaction-choices { grid-column: 1; }
.loan-op-match .r7-arena[data-acting-owner="0"][data-phase="counter"] .action-tray > .reaction-pass,
.loan-op-match .r7-arena[data-acting-owner="0"][data-phase="block"] .action-tray > .reaction-choices { grid-column: 2; }
.loan-op-match .r7-arena[data-acting-owner="0"] .action-tray > :is(.reaction-pass,.reaction-choices) {
  grid-row: 2;
  min-height: 42px;
  padding: 3px 6px;
  font-weight: 750;
  font-size: clamp(11px,1.2vw,16px);
  line-height: 1.25;
  white-space: normal;
}
.loan-op-match .r7-arena[data-acting-owner="0"]:is([data-phase="block"],[data-phase="counter"]):not([data-read-only]) .action-tray > .last-battle-note { grid-column: 1 / -1; }
.combat-feedback {
  position: absolute;
  z-index: 12;
  top: 41%;
  left: 50%;
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  width: max-content;
  max-width: min(85%, 350px);
  padding: 9px 22px;
  border: 2px solid #efbf68;
  border-radius: 12px;
  background: #372620;
  color: #fff4d3;
  box-shadow: 0 8px 24px #001719a0;
  pointer-events: none;
  animation: combat-appear .18s ease-out both;
}
.combat-feedback.combat-guard { border-color: #9de9cf; background: #173c39; }
.combat-feedback > strong { font-size: clamp(25px,5vw,48px); line-height: 1; }
.combat-feedback > span { font-size: 16px; font-weight: 700; }
.combat-retired { position: absolute; right: calc(100% - 15px); top: 0; width: 46px; animation: combat-retire .9s ease-out both; }
.combat-retired img { display: block; width: 100%; }
.combat-hit-card > .printed-face { animation: combat-shake .32s ease-out; }
.combat-guard-card > .printed-face { animation: combat-shield .38s ease-out; }
.loan-op-match .barrier.revision-life-break { position: relative; }
.loan-op-match .barrier.revision-life-break::after {
  content: "";
  position: absolute;
  inset: 0 20%;
  background: #fff4c0;
  clip-path: polygon(59% 0,65% 0,51% 37%,66% 44%,44% 70%,49% 73%,32% 100%,25% 100%,40% 74%,33% 69%,55% 46%,43% 40%);
  pointer-events: none;
  animation: combat-crack .5s ease-out both;
}
@keyframes combat-appear { from { opacity: .35; transform: translateX(-50%) scale(.8); } to { opacity: 1; transform: translateX(-50%) scale(1); } }
@keyframes combat-shake { 25% { transform: translateX(4px); } 50% { transform: translateX(-4px); } 75% { transform: translateX(2px); } }
@keyframes combat-shield { 35% { outline: 4px solid #abeee1; outline-offset: -3px; } }
@keyframes combat-retire { 50% { opacity: .8; } to { opacity: 0; transform: translateY(12px) scale(.88); } }
@keyframes combat-crack { from { opacity: 0; } 25% { opacity: 1; } to { opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .combat-feedback, .combat-retired, .combat-hit-card > .printed-face, .combat-guard-card > .printed-face { animation: none; }
  .loan-op-match .barrier.revision-life-break::after { display: none; }
}
@media (min-width: 1120px) and (min-height: 700px) {
  .battle-v05.loan-op-match .r7-arena, body.cpu-match .loan-op-match .r7-arena {
    --board-card: clamp(80px,min(8.8vw,calc((100dvh - 255px) * .233)),170px);
    --hand-card: min(173px,calc(var(--board-card) + 3px));
  }
  .loan-op-match .r7-arena > .battle-side {
    grid-template-columns: 152px minmax(0,1fr);
    gap: 8px;
  }
  .loan-op-match .r7-arena > .battle-side .side-rail {
    grid-column: 1;
    grid-row: 1;
    align-self: center;
  }
  .loan-op-match .r7-arena > .battle-side .duel-row {
    grid-column: 2;
    grid-row: 1;
  }
  .battle-v05.loan-op-match .r7-arena :is(.leader-card,.unit-card) > .current-state {
    position: absolute;
    top: 30%;
    right: 3px;
    width: auto;
    padding: 1px 4px;
    border: 1px solid #b79d62;
    border-radius: 4px;
    background: #142d2af7;
    pointer-events: none;
  }
  .loan-op-match .r7-arena:not([data-phase="mulligan"]):not([data-read-only]) > .center-line { block-size: 80px; }
  .loan-op-match .r7-arena:not([data-phase="mulligan"]):not([data-read-only]) .action-tray { max-block-size: 76px; }
}
@media (max-width: 799px) and (min-height: 640px) {
  .loan-op-match .r7-arena .phase-cue small { font-size: 11px; white-space: nowrap; }
  .loan-op-match .r7-arena .quick-attack { min-height: 28px; bottom: 21px; }
  .loan-op-match .r7-arena :is(.leader-wrap,.unit-wrap):has(.quick-attack) .current-state { justify-content: center; }
}
@media (pointer: coarse), (max-width: 799px) {
  .loan-op-match .r7-arena .side-rail :is(.barrier,button.zone-count),
  .loan-op-match .r7-arena .hand-scroll-controls button {
    min-block-size: 44px;
    min-inline-size: 44px;
  }
}
@media (max-width: 599px) and (min-height: 640px) and (orientation: portrait) {
  .loan-op-match .r7-arena:not([data-phase="mulligan"]):not([data-read-only]) > .center-line { block-size: 100px; }
  .loan-op-match .r7-arena:not([data-phase="mulligan"]):not([data-read-only]) .action-tray { max-block-size: 94px; }
}
@media (max-width: 360px) {
  .loan-op-match .r7-arena .quick-attack { min-height: 24px; top: 0; bottom: auto; }
  .loan-op-match .self-side :is(.battle-role,.battle-keyword) { top: 25px; }
}
@media (max-width: 599px) {
  dialog.confirmation-sheet, .loan-op-match #battle-modal.confirmation-sheet {
    inset: auto 0 0;
    width: 100%;
    max-width: none;
    margin: 0;
    padding-bottom: calc(16px + env(safe-area-inset-bottom));
    border-radius: 16px 16px 0 0;
  }
  .confirmation-actions button:not(.confirmation-destructive) { flex: 1 1 0; }
}

/* The backgrounds fill the landscape frame; character sprites retain their original proportions. */
.top-card-picker .ver2-game-thumb .ver2-game-background {
  position:absolute; inset:0; width:100%; height:100%; object-fit:cover; object-position:center;
}
.top-card-picker [data-game="meiling"] .ver2-game-background { object-position:center 48%; }
.top-card-picker [data-game="kakigori1"] .ver2-game-background { object-position:center 61%; }
.top-card-picker [data-game="reisen"] .ver2-game-background { object-position:center 46%; }
.top-card-picker [data-game="aya"] .ver2-game-background { object-position:center 47%; }
.top-card-picker [data-game="typing2"] .ver2-game-background { object-position:center 38%; }
.top-card-picker [data-game="fighter-cpu"] .ver2-game-background { object-fit:contain; background:#1c2440; }

/* The trial keeps the same palette, with visible boundaries between panels. */
body:has(#main) { background-color:#0b232d; }
#main .panel { border-color:#6b8c8d; }
#main .deck-summary { background:#182d3d; }
#main .deck-lists .deck-row { background:#173440; }
.deck-lists:has(.deck-row) { display:grid; grid-template-columns:repeat(auto-fill,minmax(min(140px,100%),1fr)); gap:12px; }
.deck-lists > h2,.deck-lists > p { grid-column:1/-1; }
.home-screen .home-table { grid-template-areas:"intro cards" "start cards" "choices choices" "help help"; }
.home-first-steps { grid-area:start; margin:12px 0 0; padding:14px; border:1px solid #7e8b82; border-radius:12px; background:#183440; }
.home-first-steps h2 { font-size:1.2rem; margin:0 0 5px; }
.home-first-steps p { margin:0 0 10px; }
.home-first-steps ol { display:flex; flex-wrap:wrap; gap:8px; list-style:none; margin:0; padding:0; }
.home-first-steps a { display:block; padding:.65rem .75rem; border:1px solid #a58d55; border-radius:8px; color:#fff5d5; }
@media(max-width:600px){
 .home-screen .home-table { grid-template-areas:"intro" "start" "choices" "help" "cards"; }
 .home-screen .home-table-intro h1 { font-size:clamp(24px,8vw,40px); }
 .home-screen .home-table-intro h1 span { display:inline; }
 .home-first-steps a { font-size:.9rem; padding:.7rem .55rem; }
 .home-screen .home-table-choices { margin-top:12px; }
}
.reward-result { border:2px solid #e4c578!important; scroll-margin-top:5rem; }
.guide-quick-start img { max-width:100%; height:auto; border-radius:12px; }
.modal-header { align-items:center; }
.modal-header button { flex:none; margin-inline-start:auto; display:grid; place-items:center; min-width:44px; min-height:44px; }
.borrowed-header .prep-menu { position:relative; margin-inline-start:auto; z-index:30; }
.prep-menu > summary { display:grid; place-items:center; min-width:44px; min-height:44px; list-style:none; cursor:pointer; color:#fff1c7; }
.prep-menu > summary::-webkit-details-marker { display:none; }
.prep-menu-links { position:absolute; inset-inline-end:0; top:100%; display:grid; min-width:9rem; padding:8px; color:#fff; background:#102b37; border:1px solid #7d9393; border-radius:.6rem; }
.prep-menu-links a { padding:.6rem .7rem; color:#fff1c7; }
.revision-move small { display:block; font-size:.8em; max-width:min(72vw,36rem); }
.result-recap { padding:.5rem .75rem; border:1px solid #789693; border-radius:.6rem; }
.result-recap ul { margin:.35rem 0; padding-inline-start:1.3em; }

/* When a card has no separate material art, keep its face intact and preview the finish on its rim. */
.runtime-surface[data-runtime-finish^="foil"]:not(:has(.runtime-material-window.ready)):has(>img[data-load-state="loaded"])::after {
  content:""; position:absolute; inset:1px; pointer-events:none; box-sizing:border-box; border-radius:inherit;
  border:4px solid #d2e1ee; box-shadow:inset 0 0 6px 1px #e3a6ed;
}
.runtime-surface[data-runtime-finish="foil:gold"]:not(:has(.runtime-material-window.ready)):has(>img[data-load-state="loaded"])::after {
  border-color:#f7c538; box-shadow:inset 0 0 6px 1px #f6c750;
}

.result-learning { max-width:44rem; margin:1rem auto; padding:12px 16px; border:1px solid #dbac64; border-radius:.65rem; background:#212e36; color:#fff1d7; text-align:left; }
.result-learning h2 { margin:0 0 .25rem; font-size:1rem; }
.result-learning p { margin:.25rem 0; }
.turn-guide.guide-invite:not(:disabled) { border:2px solid #f1d185; background:#203f4e; color:#fff4ce; }
.reward-basics { margin:.65rem 0 1rem; padding:.65rem .9rem; background:#18313e; border:1px solid #799397; border-radius:.55rem; }
.reward-basics summary { cursor:pointer; font-weight:700; color:#fff4d1; }
.reward-basics p { margin:.4rem 0; }
.borrowed-header .prep-menu { margin-inline-start:0; }
.borrowed-header .prep-header-links { margin-inline-start:auto; }

/* Ver2 navigation, collection, and preparation surfaces. */
.app-header:not(.borrowed-header), .borrowed-header { background:#101c2d; }
.app-header .main-nav { background-color:#101c2d; }
.app-header > [data-act="menu"], .borrowed-header .prep-menu > summary,
.loan-op-match .game-shell > header [data-op="menu"] { min-width:44px; min-height:44px; }
.borrowed-header .prep-menu { margin-inline-start:auto; }
.borrowed-header:has(> .ui-fullscreen:not([hidden])) > .ui-fullscreen { margin-inline-start:auto; }
.borrowed-header:has(> .ui-fullscreen:not([hidden])) .prep-menu { margin-inline-start:0; }

body:has(#main):not(.cpu-match):not(.home-screen), body:has(.borrowed-main:not([hidden])) {
  background:#0f1a2a;
}
#main .panel, #main .battle-mode-card, #main .deck-lists .deck-row,
body:has(.borrowed-main:not([hidden])) .borrowed-main .panel {
  background:#22354a;
  border-color:#8da8bf;
  color:#f4f7fb;
}
#main :is(.reward-result,.deck-summary), #main .reward-result ul, #main .reward-basics {
  background:#192d43;
}
#main .reward-result { border-color:#dbbd75!important; }
#main :is(.muted,.small), .borrowed-main .small { color:#d8e4ef; }
#main a:not(.button):not(.battle-mode-card), #main a:not(.button):not(.battle-mode-card):visited,
.prep-menu-links a, .prep-menu-links a:visited { color:#ffe4a1; }
#main a.journey-guide { display:inline-flex; align-items:center; min-height:44px; text-underline-offset:.22em; }
#main button:not(.card-tile,.leader-tile,.game-card,.gcard,[role=tab]), #main a.button,
#main select, #main input, #main .battle-mode-card,
.borrowed-main button, .prep-menu > summary, .app-header > [data-act="menu"] {
  background:#314a63;
  border-color:#98b5ce;
  color:#f8fbff;
}
.prep-menu > summary { border:1px solid #98b5ce; border-radius:8px; }
#main :is(button,a.button).primary, .borrowed-main button.primary {
  background:#f9dd93;
  border-color:#ffedbf;
  color:#201b16;
  font-weight:750;
}
#main button[aria-pressed="true"], #main button[aria-selected="true"],
.app-header .main-nav button[aria-current="page"] {
  box-shadow:inset 0 -3px #ffe4a1;
  outline:1px solid #ffe4a1;
  outline-offset:-2px;
}
#main button:disabled:not(.gcard), #main select:disabled, .borrowed-main button:disabled {
  background:#253344;
  border-color:#8394a4;
  color:#c4ced9;
  opacity:1;
  box-shadow:none;
}
#main :is(button,a,select,input,summary):focus-visible, .prep-menu-links a:focus-visible,
.app-header :is(button,a,summary):focus-visible { outline:3px solid #ffecae; outline-offset:3px; }
#main :is(a.button,button):not(:disabled):hover, .borrowed-main button:not(:disabled):hover {
  border-color:#fff2cc;
}
.received-cards > h2 { margin:0 0 10px; }
.received-layout { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:12px; align-items:start; }
.journey-next p, .deck-summary > p { margin:.3rem 0 .55rem; }
.journey-next .button-row, .deck-summary .button-row { gap:6px 12px; }
.received-layout ul { margin:0; padding:0; max-width:100%; list-style:none; }
.received-layout .receipt-card-list { display:flex; flex-wrap:wrap; gap:6px; }
.received-layout .receipt-card-list .card-tile { width:min(112px,23vw); min-width:0; }
.received-layout .receipt-card-list p { margin:.25rem 0; }
.reward-links { display:flex; flex-wrap:wrap; gap:6px 12px; margin-top:8px; }
#main .reward-links .text-button { min-height:44px; border:0; background:none; color:#ffe4a1; text-decoration:underline; text-underline-offset:.2em; }
.deck-conditions { margin:.55rem 0; }
.deck-conditions summary { cursor:pointer; }
.deck-conditions p { margin:.35rem 0; }
.deck-count-strip { background:#142438; border-color:#9bb8cf; }
#main .counter :is(button,b) { min-width:0; }
#main .counter button { min-height:44px; min-width:36px; padding-inline:4px; }
#main .deck-lists .deck-row { border:1px solid #8da8bf; border-radius:10px; }
@media (max-width:420px) {
  .received-layout { gap:8px; }
  .received-layout .receipt-card-list p { max-width:23vw; font-size:11px; }
}
@media (max-width:359px) {
  .app-header .wallet { gap:3px; }
  .app-header .wallet small { font-size:10px; }
  .app-header > [data-ui-fullscreen]:not([hidden]) { max-width:92px; font-size:11px; }
}

.received-layout { grid-template-columns:minmax(0,1fr) minmax(90px,33%); }
.received-layout .receipt-card-list > div { min-width:0; max-width:100%; }
.receipt-card-name { display:block; margin-top:4px; font-size:.85rem; overflow-wrap:anywhere; }
.leader-choice-action { margin:0 0 12px; }
.leader-choice-action .primary { background:#f9dd93; border-color:#ffedbf; color:#201b16; min-height:44px; }

/* The released second edition stays recognizable across every main screen. */
.edition-badge { display:inline-flex; flex:none; align-items:center; justify-content:center; margin-inline-start:5px; padding:3px 7px; border:1px solid #fff1c8; border-radius:7px; background:#ffe09a; color:#1b2926; font:900 12px/1.15 system-ui,sans-serif; letter-spacing:.02em; vertical-align:middle; }
.app-header .brand-label { display:inline-flex; align-items:center; min-width:0; }
.app-header .brand-game-name { min-width:0; overflow:hidden; text-overflow:ellipsis; }
.battle-brand-label { display:inline-flex; align-items:center; flex-wrap:wrap; gap:3px; }
.home-screen .home-table-intro .home-table-edition { display:table; width:fit-content; margin:12px auto 0; padding:7px 20px; border:2px solid #fff2cc; border-radius:999px; background:#ffe09a; color:#1b2926; box-shadow:0 3px 14px #0005; font:900 clamp(20px,3.5vw,30px)/1.15 system-ui,sans-serif; letter-spacing:.05em; text-shadow:none; }
@media(max-width:359px){ .app-header .edition-badge { font-size:10px; padding:3px 5px; margin-inline-start:4px; } }
