/* ==========================================================================
   Battle City Online — decorative "map + tank" system V3.
   Loaded ONLY when BC_ENABLE_BLUEPRINT_BACKGROUND is true (functions.php).
   The decorative layer markup is emitted once in wp_footer (bc_decor_layer()).

   Concept: small, readable, slightly-rotated muted level maps + large colour
   Battle City tank sprites, placed in the free side zones, with clean space
   between. No grid, no texture. Purely decorative: pointer-events:none,
   user-select:none, aria-hidden, always behind content. Fully removable by
   not enqueuing this file / not emitting the layer.

   Intensity (tested A/B/C on the live hero, B shipped):
     A  --bp-map:.18 --bp-tank:.16
     B  --bp-map:.22 --bp-tank:.20   <-- active
     C  --bp-map:.26 --bp-tank:.24
   ========================================================================== */

:root{
  --bp-map:   .22;   /* level-map opacity   (desktop) */
  --bp-tank:  .20;   /* tank opacity        (desktop) */
  --bp-bonus: .20;   /* bonus-icon opacity  (desktop) */
}

/* Reveal the layer: opaque graphite wrapper -> transparent so the decorative
   layer (behind it) shows through. Graphite still comes from <body>. */
body div[style*="min-height:100vh"]{ background-color:transparent !important; }

/* body is the positioning context for the full-document decor layer. Does not
   affect the sticky header or the fixed viewer/lightbox. */
body{ position:relative; }

/* ---- decorative layer (emitted in wp_footer) ------------------------------ */
.bc-decor{
  position:absolute; inset:0; z-index:-1; overflow:hidden;
  pointer-events:none; user-select:none;
}
.bc-decor .bc-d{
  position:absolute; display:block; height:auto;
  width:var(--w);
  image-rendering:pixelated; image-rendering:crisp-edges;
  will-change:auto;
}
.bc-decor .bc-d-map{   opacity:var(--bp-map);  transform:rotate(var(--rot,0deg)); }
.bc-decor .bc-d-tank{  opacity:var(--bp-tank); transform:rotate(var(--rot,0deg)); }
.bc-decor .bc-d-bonus{ opacity:var(--bp-bonus); }  /* bonuses stay upright */

/* The levels "Explored N/35" chip gets a solid graphite frame — like the filter
   buttons — so a decorative tank/map/bonus passing behind it never bleeds through
   and spoils it. Only applied while the decor layer is active (this file loaded). */
body.bc-levels-page .bc-progress{
  background:rgba(19,22,25,.92);
  border:1px solid rgba(255,255,255,.12);
  border-radius:5px;
  padding:7px 13px;
}

/* ---- mobile: fewer objects, a bit smaller, a touch calmer, no overflow ---- */
@media (max-width:640px){
  :root{ --bp-map:.18; --bp-tank:.17; --bp-bonus:.17; }
  .bc-decor .bc-d{ width:calc(var(--w) * .68); }
  .bc-decor .bc-d-mh{ display:none !important; }
}

/* ---- print: hide decoration ---------------------------------------------- */
@media print{ .bc-decor{ display:none !important; } }
