/* Bandit Hunt — Dwarven Mine style upper layout (2026-10-20)
   Loaded after styles.css, site-ui.css and both shared V2 header stylesheets.
   Hero uses the same fixed page-visual system as Dwarven Mine.
   Article cards, four-language translation hooks and all scripts remain unchanged. */

body.site-ui-page.bandit-visual {
  --page-visual-image: url("/assets/tips/bandit-hunt/bandit-hunt-hero.webp");
  --page-visual-position: 58% top;
  --page-visual-height: 30svh;
}

/* Like Dwarven Mine: the header and page title sit over the fixed artwork. */
body.site-ui-page.bandit-visual .bandit-main {
  margin-top: 0.3rem;
  font-variant-numeric: tabular-nums;
}

body.site-ui-page.bandit-visual .bandit-intro {
  margin-top: 0.75rem;
}

body.site-ui-page.bandit-visual .bandit-kicker {
  color: var(--gold-2);
  font-size: 0.62rem;
  font-weight: 550;
  line-height: 1.35;
  letter-spacing: 0.19em;
}

body.site-ui-page.bandit-visual .bandit-page-title {
  margin: 0.32rem 0 0;
  color: #f0eee9;
  font-size: 1.34rem;
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.008em;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.75);
}

body.site-ui-page.bandit-visual .bandit-page-en {
  margin: 0.18rem 0 0;
  color: rgba(240, 238, 233, 0.72);
  font-size: 0.67rem;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.08em;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.75);
}

body.site-ui-page.bandit-visual .bandit-lead-text {
  margin: 0.48rem 0 0;
  color: #c0c7c0;
  font-size: 0.79rem;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: 0;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.6);
}

/* Restore readability before article starts on very short viewports. */
@media (max-width: 380px) {
  body.site-ui-page.bandit-visual .bandit-page-title { font-size: 1.3rem; }
}

html[lang="ru"] body.site-ui-page.bandit-visual .bandit-page-title {
  font-family: "PT Sans Narrow", "PT Sans", sans-serif;
  font-size: 1.42rem;
  font-weight: 400;
  letter-spacing: 0;
}
html[lang="ru"] body.site-ui-page.bandit-visual .bandit-lead-text {
  font-family: "PT Sans", sans-serif;
  font-weight: 400;
  letter-spacing: 0;
}

/* Typography inherited from the earlier Bandit Hunt article. */
.bandit-section-text,
.bandit-section-note {
  margin: 0.72em 0 0;
  color: rgba(242, 242, 242, 0.68);
  font-size: 11.5px;
  font-weight: 520;
  line-height: 1.55;
}

/* Section headings inside the existing guide */
.bandit-section-kicker {
  margin: 0;
  color: var(--gold-2);
  font-size: 9px;
  font-weight: 780;
  line-height: 1.2;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.bandit-section {
  margin-top: 24px;
}

.bandit-section-title {
  margin: 4px 0 0;
  color: var(--text);
  font-size: 15.5px;
  font-weight: 760;
  line-height: 1.24;
  letter-spacing: -0.012em;
}

.bandit-key-list,
.bandit-flow-list,
.bandit-boss-list,
.bandit-decision-list,
.bandit-rules-list {
  margin-top: 10px;
}

.bandit-key-card {
  display: flex;
  align-items: center;
  min-height: 54px;
  padding: 8px 10px;
  border: 1px solid var(--glass-line);
  border-radius: 13px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.038), rgba(255, 255, 255, 0.01)), rgba(10, 11, 10, 0.52);
}

.bandit-key-card + .bandit-key-card {
  margin-top: 7px;
}

.bandit-key-number,
.bandit-flow-number,
.bandit-rules-list li > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 27px;
  height: 27px;
  border: 1px solid rgba(214, 170, 79, 0.38);
  border-radius: 50%;
  background: rgba(214, 170, 79, 0.08);
  color: var(--gold-2);
  font-size: 10px;
  font-weight: 820;
  line-height: 1;
}

.bandit-key-copy {
  min-width: 0;
  margin-left: 9px;
}

.bandit-key-copy h3,
.bandit-flow-copy h3,
.bandit-boss-copy h3 {
  margin: 0;
  color: #ffffff;
  font-size: 12.8px;
  font-weight: 760;
  line-height: 1.32;
}

.bandit-key-copy p,
.bandit-flow-copy p,
.bandit-boss-copy p,
.bandit-warning p,
.bandit-tip-card p,
.bandit-rules-list p {
  margin: 3px 0 0;
  color: rgba(242, 242, 242, 0.66);
  font-size: 10.8px;
  font-weight: 500;
  line-height: 1.5;
}

.bandit-core-message {
  margin: 9px 0 0;
  padding: 8px 9px;
  border-left: 2px solid var(--gold);
  background: rgba(214, 170, 79, 0.055);
  color: rgba(242, 242, 242, 0.78);
  font-size: 11.2px;
  font-weight: 650;
  line-height: 1.5;
}

.bandit-flow-row {
  display: grid;
  grid-template-columns: 27px 50px minmax(0, 1fr);
  align-items: center;
  min-height: 62px;
  padding: 7px 9px;
  border: 1px solid var(--glass-line-soft);
  border-radius: 12px;
  background: rgba(9, 10, 9, 0.48);
}

.bandit-flow-row + .bandit-flow-row {
  margin-top: 6px;
}

.bandit-flow-art {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 48px;
  margin-left: 4px;
  overflow: hidden;
}

.bandit-flow-art img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.bandit-flow-art-thief img {
  width: 45px;
  height: auto;
}

.bandit-flow-coin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 31px;
  height: 31px;
  margin-left: 11px;
  border: 2px solid #f3d27a;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 32%, #ffe69b 0%, #d6aa4f 34%, #8e6424 72%, #5e4219 100%);
  color: rgba(255, 255, 255, 0.6);
  box-shadow: inset 0 0 0 2px rgba(73, 49, 10, 0.42);
  font-size: 0;
}

.bandit-flow-copy {
  min-width: 0;
  margin-left: 8px;
}

.bandit-range-card,
.bandit-shift-card,
.bandit-tip-card,
.bandit-boss-card,
.bandit-decision-list,
.bandit-rules-list {
  border: 1px solid var(--glass-line);
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.034), rgba(255, 255, 255, 0.009)), rgba(9, 10, 9, 0.62);
}

.bandit-range-card,
.bandit-shift-card {
  margin-top: 10px;
  padding: 10px 8px 9px;
}

.bandit-range-heading,
.bandit-shift-header {
  display: flex;
  align-items: center;
  min-width: 0;
}

.bandit-range-heading span,
.bandit-shift-header span {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(214, 170, 79, 0.1);
  color: var(--gold-2);
  font-size: 9px;
  font-weight: 820;
  line-height: 1;
}

.bandit-range-heading strong,
.bandit-shift-header strong {
  margin-left: 8px;
  color: rgba(242, 242, 242, 0.88);
  font-size: 11.5px;
  font-weight: 740;
  line-height: 1.25;
}

.bandit-range-list {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: end;
  margin-top: 12px;
}

.bandit-range-item {
  position: relative;
  min-width: 0;
  padding: 13px 2px 5px;
  text-align: center;
}

.bandit-range-item.is-base {
  border: 1px solid rgba(243, 210, 122, 0.4);
  border-radius: 10px;
  background: rgba(214, 170, 79, 0.07);
}

.bandit-base-tag {
  position: absolute;
  top: 3px;
  left: 50%;
  color: var(--gold-2);
  font-size: 7.5px;
  font-weight: 840;
  line-height: 1;
  letter-spacing: 0.08em;
  transform: translateX(-50%);
}

.bandit-range-art {
  display: block;
  width: min(100%, 52px);
  height: 31px;
  margin: 0 auto;
  overflow: hidden;
}

.bandit-range-art img {
  display: block;
  width: 100%;
  height: auto;
}

.bandit-range-item strong {
  display: block;
  margin-top: 4px;
  color: rgba(242, 242, 242, 0.78);
  font-size: 9.5px;
  font-weight: 720;
  line-height: 1.1;
  white-space: nowrap;
}

.bandit-range-item.is-base strong {
  color: var(--gold-2);
}

.bandit-range-formula {
  margin: 10px 0 0;
  color: #ffffff;
  font-size: 12px;
  font-weight: 760;
  line-height: 1.3;
  text-align: center;
}

.bandit-range-note {
  margin: 5px 0 0;
  color: rgba(242, 242, 242, 0.5);
  font-size: 9.5px;
  font-weight: 520;
  line-height: 1.4;
  text-align: center;
}

.bandit-range-list-compact {
  margin-top: 8px;
}

.bandit-range-list-compact .bandit-range-item {
  padding-top: 12px;
}

.bandit-shift-trigger {
  position: relative;
  margin: 11px 0;
  padding: 8px 60px 8px 8px;
  border: 1px solid rgba(214, 170, 79, 0.22);
  border-radius: 10px;
  background: rgba(214, 170, 79, 0.045);
}

.bandit-shift-trigger-label {
  display: block;
  color: rgba(242, 242, 242, 0.67);
  font-size: 10.4px;
  font-weight: 560;
  line-height: 1.42;
}

.bandit-shift-trigger > strong:not(.bandit-shift-plus) {
  position: absolute;
  top: 8px;
  right: 31px;
  color: var(--gold-2);
  font-size: 14px;
  font-weight: 840;
  line-height: 1;
}

.bandit-shift-arrow {
  position: absolute;
  top: 24px;
  right: 37px;
  color: rgba(243, 210, 122, 0.62);
  font-size: 11px;
  line-height: 1;
}

.bandit-shift-plus {
  position: absolute;
  top: 38px;
  right: 26px;
  color: var(--gold-2);
  font-size: 16px;
  font-weight: 860;
  line-height: 1;
}

.bandit-shift-header-after {
  margin-top: 2px;
}

.bandit-shift-summary {
  margin: 9px 0 0;
  color: rgba(242, 242, 242, 0.72);
  font-size: 10.7px;
  font-weight: 540;
  line-height: 1.5;
  text-align: center;
}

.bandit-warning {
  margin-top: 9px;
  padding: 8px 9px;
  border: 1px solid rgba(214, 170, 79, 0.22);
  border-radius: 11px;
  background: rgba(214, 170, 79, 0.035);
}

.bandit-warning strong {
  display: block;
  color: #ffffff;
  font-size: 11.5px;
  font-weight: 760;
  line-height: 1.35;
}

.bandit-tip-card {
  display: flex;
  align-items: center;
  margin-top: 10px;
  padding: 10px;
}

.bandit-coin-stack {
  position: relative;
  flex: 0 0 auto;
  width: 46px;
  height: 40px;
  margin-right: 10px;
}

.bandit-coin-stack i {
  position: absolute;
  display: block;
  width: 28px;
  height: 10px;
  border: 1px solid #d6aa4f;
  border-radius: 50%;
  background: linear-gradient(180deg, #f3d27a 0%, #b47d25 100%);
  box-shadow: inset 0 -2px 0 rgba(91, 58, 11, 0.42);
}

.bandit-coin-stack i:nth-child(1) { left: 2px; bottom: 2px; }
.bandit-coin-stack i:nth-child(2) { left: 15px; bottom: 11px; }
.bandit-coin-stack i:nth-child(3) { left: 5px; bottom: 20px; }

.bandit-tip-card > div {
  min-width: 0;
}

.bandit-tip-card p {
  margin-top: 0;
}

.bandit-tip-card strong {
  display: block;
  margin-top: 5px;
  color: var(--gold-2);
  font-size: 10.8px;
  font-weight: 740;
  line-height: 1.45;
}

.bandit-boss-card {
  display: grid;
  grid-template-columns: 102px minmax(0, 1fr);
  align-items: center;
  min-height: 118px;
  padding: 8px 10px 8px 5px;
}

.bandit-boss-card + .bandit-boss-card {
  margin-top: 8px;
}

.bandit-boss-art {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 96px;
  height: 102px;
  overflow: hidden;
}

.bandit-boss-art img {
  display: block;
  max-width: 92px;
  max-height: 100px;
  object-fit: contain;
}

.bandit-boss-art-high img {
  max-width: 98px;
  max-height: 92px;
}

.bandit-boss-copy {
  min-width: 0;
  margin-left: 5px;
}

.bandit-boss-level {
  display: inline-flex;
  align-items: center;
  min-height: 21px;
  padding: 0 7px;
  border: 1px solid rgba(214, 170, 79, 0.28);
  border-radius: 999px;
  background: rgba(214, 170, 79, 0.07);
  color: var(--gold-2);
  font-size: 9.5px;
  font-weight: 780;
  line-height: 1;
}

.bandit-boss-copy h3 {
  margin-top: 5px;
}

.bandit-section-note {
  margin-top: 8px;
  padding-left: 8px;
  border-left: 2px solid rgba(214, 170, 79, 0.45);
}

.bandit-decision-list {
  overflow: hidden;
}

.bandit-decision-row {
  display: grid;
  grid-template-columns: 50% 50%;
  min-height: 42px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.bandit-decision-row:last-child {
  border-bottom: 0;
}

.bandit-decision-row span,
.bandit-decision-row strong {
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 7px 8px;
  font-size: 10.5px;
  line-height: 1.42;
}

.bandit-decision-row span {
  color: rgba(242, 242, 242, 0.6);
  font-weight: 520;
}

.bandit-decision-row strong {
  border-left: 1px solid rgba(255, 255, 255, 0.06);
  color: rgba(242, 242, 242, 0.88);
  font-weight: 720;
}

.bandit-rules-list {
  margin-bottom: 0;
  padding: 5px 9px;
  list-style: none;
}

.bandit-rules-list li {
  display: flex;
  align-items: flex-start;
  min-height: 38px;
  padding: 6px 0;
}

.bandit-rules-list li + li {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.bandit-rules-list li > span {
  width: 23px;
  height: 23px;
  margin-top: 1px;
  border-radius: 7px;
  font-size: 9px;
}

.bandit-rules-list p {
  flex: 1 1 auto;
  min-width: 0;
  margin: 2px 0 0 8px;
  color: rgba(242, 242, 242, 0.74);
}

html[lang="en"] .bandit-section-title,
html[lang="es"] .bandit-section-title {
  font-size: 15px;
}

html[lang="ru"] .bandit-section-title {
  font-size: 14.5px;
  line-height: 1.27;
}

html[lang="en"] .bandit-key-copy h3,
html[lang="en"] .bandit-flow-copy h3,
html[lang="en"] .bandit-boss-copy h3 {
  font-size: 12.3px;
}

html[lang="ru"] .bandit-key-copy h3,
html[lang="ru"] .bandit-flow-copy h3,
html[lang="ru"] .bandit-boss-copy h3,
html[lang="es"] .bandit-key-copy h3,
html[lang="es"] .bandit-flow-copy h3,
html[lang="es"] .bandit-boss-copy h3 {
  font-size: 11.8px;
  line-height: 1.34;
}

html[lang="ru"] .bandit-key-copy p,
html[lang="ru"] .bandit-flow-copy p,
html[lang="ru"] .bandit-boss-copy p,
html[lang="ru"] .bandit-page-text,
html[lang="ru"] .bandit-section-text,
html[lang="es"] .bandit-key-copy p,
html[lang="es"] .bandit-flow-copy p,
html[lang="es"] .bandit-boss-copy p,
html[lang="es"] .bandit-page-text,
html[lang="es"] .bandit-section-text {
  font-size: 10.5px;
}

@media (max-width: 380px) {

  .bandit-page-title {
    font-size: 20px;
  }

  .bandit-section-title {
    font-size: 15px;
  }

  .bandit-key-copy h3,
  .bandit-flow-copy h3,
  .bandit-boss-copy h3 {
    font-size: 12.2px;
  }

  .bandit-key-copy p,
  .bandit-flow-copy p,
  .bandit-boss-copy p,
  .bandit-warning p,
  .bandit-tip-card p,
  .bandit-rules-list p {
    font-size: 10.4px;
  }

  .bandit-flow-row {
    grid-template-columns: 25px 44px minmax(0, 1fr);
    padding-left: 7px;
    padding-right: 7px;
  }

  .bandit-flow-number {
    width: 25px;
    height: 25px;
  }

  .bandit-flow-art {
    width: 42px;
    height: 44px;
    margin-left: 2px;
  }

  .bandit-flow-copy {
    margin-left: 6px;
  }

  .bandit-range-card,
  .bandit-shift-card {
    padding-left: 6px;
    padding-right: 6px;
  }

  .bandit-range-item {
    padding-left: 1px;
    padding-right: 1px;
  }

  .bandit-range-art {
    width: min(100%, 47px);
    height: 28px;
  }

  .bandit-range-item strong {
    font-size: 9px;
  }

  .bandit-boss-card {
    grid-template-columns: 92px minmax(0, 1fr);
    padding-right: 8px;
  }

  .bandit-boss-art {
    width: 88px;
    height: 96px;
  }

  .bandit-boss-art img {
    max-width: 84px;
    max-height: 92px;
  }

  .bandit-boss-art-high img {
    max-width: 90px;
    max-height: 86px;
  }

  .bandit-decision-row span,
  .bandit-decision-row strong {
    padding-left: 7px;
    padding-right: 7px;
    font-size: 10px;
  }

  html[lang="ru"] .bandit-section-title,
  html[lang="es"] .bandit-section-title {
    font-size: 14px;
  }
}

@media (max-width: 330px) {

  .bandit-page-title {
    font-size: 19px;
  }

  .bandit-section-title {
    font-size: 14.5px;
  }

  .bandit-range-heading strong,
  .bandit-shift-header strong {
    font-size: 10.8px;
  }

  .bandit-range-art {
    width: min(100%, 42px);
    height: 25px;
  }

  .bandit-range-item strong {
    font-size: 8.5px;
  }

  .bandit-boss-card {
    grid-template-columns: 84px minmax(0, 1fr);
  }

  .bandit-boss-art {
    width: 80px;
  }

  .bandit-boss-art img {
    max-width: 78px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bandit-main * {
    scroll-behavior: auto;
  }
}

/* KEY POINTS onward: keep the black layer ABOVE the fixed page image. */
body.site-ui-page.bandit-visual .bandit-content {
  position: relative;
  isolation: isolate;
  display: flow-root;
  margin-top: 24px;
  padding: 14px 0 24px;
}

body.site-ui-page.bandit-visual .bandit-content::before {
  content: "";
  position: absolute;
  z-index: 0;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  background: rgba(5, 5, 5, 0.98);
  pointer-events: none;
}

body.site-ui-page.bandit-visual .bandit-content > .bandit-section {
  position: relative;
  z-index: 1;
}

body.site-ui-page.bandit-visual .bandit-content > .bandit-section:first-child {
  margin-top: 0;
}

body.site-ui-page.bandit-visual .bandit-content :is(
  .bandit-key-copy p, .bandit-flow-copy p, .bandit-boss-copy p,
  .bandit-warning p, .bandit-tip-card p, .bandit-rules-list p,
  .bandit-section-text, .bandit-section-note
) {
  color: rgba(242, 242, 242, 0.92);
}
