/* Forest Frontier v0.10.0-rc26 — compact combat/shop pass */
body.theme-ashen .legacy-auto-controls{display:none!important}
body.theme-ashen .battle-stage{margin-top:4px}
body.theme-ashen .combat-mechanics-status{grid-template-columns:minmax(0,1fr) auto;align-items:center;padding:7px 9px;margin:5px 0;gap:5px}
body.theme-ashen .combat-mechanics-line{display:grid;gap:2px;align-items:center}
body.theme-ashen .combat-mechanics-line strong{font-size:11px}
body.theme-ashen .combat-mechanics-line span{font-size:10px}
body.theme-ashen .crushing-charge-row{display:grid;justify-items:end;gap:3px}
body.theme-ashen .crushing-charge-row>span:first-child{font-size:9px;max-width:120px;text-align:right;line-height:1.1}
body.theme-ashen .crushing-charge-segments{width:76px}
body.theme-ashen .combat-effect-state,body.theme-ashen .combat-preview-state,body.theme-ashen .heavy-sequence-state{grid-column:1/-1;font-size:10px;padding-top:3px}
body.theme-ashen .enemy-armor-wrap{display:grid;gap:2px;margin-top:3px}
body.theme-ashen .combatant.poisoned::after{content:'☠ ЯД';position:absolute;left:7px;top:7px;padding:2px 5px;border:1px solid rgba(96,198,103,.6);border-radius:999px;background:rgba(15,53,22,.86);color:#8be693;font-size:8px;font-weight:900;letter-spacing:.08em;z-index:8}
body.theme-ashen .final-reward-intro{margin:5px 0 10px;color:#aab0aa;font-size:12px}
body.theme-ashen .final-reward-option{min-height:0;padding:0;overflow:hidden}
body.theme-ashen .final-reward-select{display:grid;width:100%;min-height:132px;align-content:start;gap:5px;padding:12px;border:0;background:transparent;color:inherit;text-align:left}
body.theme-ashen .final-reward-select strong{font-size:16px;color:#ecd8ff}
body.theme-ashen .final-reward-select span{font-size:10px;color:#a99ab4;text-transform:uppercase;letter-spacing:.08em}
body.theme-ashen .final-reward-select em{font-style:normal;color:#dcb6ff;font-weight:800}
body.theme-ashen .final-reward-select b{margin-top:7px;padding:8px;border:1px solid rgba(213,166,255,.62);border-radius:8px;background:rgba(122,70,157,.32);text-align:center;color:#fff}
body.theme-ashen .final-reward-option details{border-top:1px solid rgba(188,130,255,.25);padding:0 12px 10px;color:#bdb2c4;font-size:11px}
body.theme-ashen .final-reward-option summary{padding:8px 0;cursor:pointer;color:#d3c1dd;font-weight:800}
body.theme-ashen .final-reward-option details p{margin:5px 0 0;line-height:1.35}
@media(max-width:620px){body.theme-ashen .combat-mechanics-line{display:grid!important;gap:1px!important}body.theme-ashen .crushing-charge-row{display:grid!important;align-items:end!important;gap:2px!important}body.theme-ashen .final-reward-grid{gap:7px}}

/* RC25: trial style selection and explicit trial result */

/* v0.10.0-rc26: critical progression, Patrol and Ruins forge fixes */
/* Forest Frontier v0.10.0-rc26 — viewport-safe dialogs, readable poison and compact Patrol */

/* Long dialogs share one viewport-safe composition. */
body.theme-ashen .boss-choice-card,
body.theme-ashen .item-detail-card,
body.theme-ashen .battle-result-card,
body.theme-ashen .reward-result-card {
  width:min(94vw,620px)!important;
  max-width:620px!important;
  max-height:min(88dvh,860px)!important;
  overflow:hidden!important;
  display:grid!important;
  grid-template-rows:auto minmax(0,1fr) auto!important;
  align-content:stretch!important;
  padding:16px!important;
}

/* Final chapter reward: one readable column inside the scrolling center. */
body.theme-ashen .final-reward-note {font-size:11px;line-height:1.35}

/* Potion and poison feedback. */
body.theme-ashen .combatant.poisoned::after {content:attr(data-poison-label)!important;white-space:nowrap}
body.theme-ashen #enemyIntent.poison-intent,
body.theme-ashen .heavy-sequence-state.poison-telegraph {
  border-color:rgba(73,205,92,.76)!important;
  background:linear-gradient(90deg,rgba(20,87,31,.82),rgba(12,49,21,.88))!important;
  color:#a9f2b0!important;
  box-shadow:0 0 16px rgba(47,190,70,.24)!important;
  animation:rc25PoisonTelegraph 1.25s ease-in-out infinite alternate;
}
body.theme-ashen .combat-effect-state {line-height:1.35}

/* Compact Patrol. */

@media(max-width:620px) {
  body.theme-ashen .boss-choice-card,
  body.theme-ashen .item-detail-card,
  body.theme-ashen .battle-result-card,
  body.theme-ashen .reward-result-card {
    width:100%!important;
    max-width:none!important;
    max-height:calc(100dvh - env(safe-area-inset-top) - 12px)!important;
    border-radius:18px 18px 8px 8px!important;
    padding:13px!important;
  }
}
@media(prefers-reduced-motion:reduce) {
  body.theme-ashen .combatant.heal-pulse,
  body.theme-ashen #enemyIntent.poison-intent,
  body.theme-ashen .heavy-sequence-state.poison-telegraph {animation:none!important}
}

/* Forest Frontier v0.10.0-rc26 — final compact Patrol and server-state feedback */

/* RC26: one-offer Shop and readable two-row combat mechanics. */
body.theme-ashen .combat-mechanics-status{
  grid-template-columns:minmax(0,1fr)!important;
  align-items:stretch!important;
  gap:6px!important;
}
body.theme-ashen .combat-mechanics-line,
body.theme-ashen .crushing-charge-row{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto!important;
  align-items:center!important;
  justify-items:stretch!important;
  gap:8px!important;
  min-width:0!important;
}
body.theme-ashen .combat-mechanics-line strong,
body.theme-ashen .combat-mechanics-line span,
body.theme-ashen .crushing-charge-row>span:first-child{
  min-width:0!important;
  max-width:none!important;
  margin:0!important;
  line-height:1.25!important;
  overflow-wrap:anywhere;
}
body.theme-ashen .combat-mechanics-line span,
body.theme-ashen .crushing-charge-row>span:first-child{text-align:right!important}
body.theme-ashen .crushing-charge-row{padding-top:5px;border-top:1px solid rgba(151,165,143,.14)}
@media(max-width:430px){
  body.theme-ashen .combat-mechanics-line,
  body.theme-ashen .crushing-charge-row{grid-template-columns:minmax(0,1fr) auto!important}
  body.theme-ashen .combat-mechanics-line strong,
  body.theme-ashen .combat-mechanics-line span,
  body.theme-ashen .crushing-charge-row>span:first-child{font-size:9.5px!important}
}

/* v0.10.0-rc28 — единая витрина и руна дня */


/* RC28: compact Trial list and pre-attempt briefing */
.trial-briefing-last{display:grid;gap:4px;padding:9px 11px;border-radius:10px;border:1px solid rgba(208,102,77,.42);background:rgba(100,38,30,.22)}
.trial-briefing-last.success{border-color:rgba(109,190,108,.42);background:rgba(37,91,44,.2)}
.hero-trials-collapse-body>.hero-trials-rule,.hero-trials-collapse-body>.hero-trial-last-result{display:none!important}
