/* ==========================================================================
   Ninong Game - compact interface stylesheet
   Prefix contract: every class = layer2e872- , every custom property = --layer2e872-
   Canvas: 320-430px phone frame, centered on wide screens
   Palette anchors: #2E4057 deep / #BDB76B khaki / #E5E5E5 mist /
                    #DAA520 gold / #FFFACD cream
   ========================================================================== */

/* ---------- 1. Tokens & reset ---------- */
:root {
  --layer2e872-deep: #2E4057;
  --layer2e872-deeper: #233145;
  --layer2e872-abyss: #1a2534;
  --layer2e872-panel: #2b3c52;
  --layer2e872-panel-2: #33465f;
  --layer2e872-line: rgba(189, 183, 107, 0.28);
  --layer2e872-line-soft: rgba(229, 229, 229, 0.12);
  --layer2e872-khaki: #BDB76B;
  --layer2e872-gold: #DAA520;
  --layer2e872-gold-hi: #eec04a;
  --layer2e872-cream: #FFFACD;
  --layer2e872-mist: #E5E5E5;
  --layer2e872-muted: #9fb0c2;
  --layer2e872-ink: #1a2534;
  --layer2e872-head-font: "Trebuchet MS", "Gill Sans", "Seravek", "Segoe UI", Verdana, sans-serif;
  --layer2e872-body-font: system-ui, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --layer2e872-r-card: 12px;
  --layer2e872-r-btn: 7px;
  --layer2e872-mast-h: 96px;
  --layer2e872-dock-h: 62px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--layer2e872-body-font);
  font-size: 15px;
  line-height: 1.62;
  color: var(--layer2e872-mist);
  background: #101823;
  min-height: 100vh;
}

img { display: block; max-width: 100%; border: 0; }

button { font-family: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

a { color: var(--layer2e872-khaki); text-decoration: none; }
a:hover, a:focus-visible { color: var(--layer2e872-cream); text-decoration: underline; }

:focus-visible { outline: 2px solid var(--layer2e872-gold-hi); outline-offset: 2px; border-radius: 4px; }

/* ---------- 2. Phone canvas ---------- */
.layer2e872-shell {
  position: relative;
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
  background: linear-gradient(180deg, var(--layer2e872-deep) 0%, var(--layer2e872-deeper) 46%, var(--layer2e872-abyss) 100%);
  min-height: 100vh;
  overflow-x: clip;
}

.layer2e872-page {
  padding: calc(var(--layer2e872-mast-h) + 10px) 12px calc(var(--layer2e872-dock-h) + 34px);
}

/* ---------- 3. Masthead: centered identity bar + action row ---------- */
.layer2e872-masthead {
  position: fixed;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px;
  z-index: 70;
  background: linear-gradient(180deg, #24344a 0%, var(--layer2e872-deep) 100%);
  border-bottom: 1px solid var(--layer2e872-line);
  box-shadow: 0 4px 14px rgba(10, 16, 26, 0.55);
}

.layer2e872-idbar {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 46px;
  padding: 5px 10px 3px;
}

.layer2e872-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--layer2e872-cream);
  text-decoration: none;
}

.layer2e872-brand:hover, .layer2e872-brand:focus-visible { text-decoration: none; color: var(--layer2e872-cream); }

.layer2e872-brand-mark {
  width: 34px; height: 34px;
  border-radius: 9px;
  border: 1px solid var(--layer2e872-khaki);
  background: #0e1622;
  object-fit: cover;
  box-shadow: 0 0 0 2px rgba(218, 165, 32, 0.25);
}

.layer2e872-brand-word {
  font-family: var(--layer2e872-head-font);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.4px;
  color: var(--layer2e872-cream);
}

.layer2e872-brand-word em {
  font-style: normal;
  color: var(--layer2e872-gold-hi);
}

.layer2e872-actrow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 4px 10px 8px;
}

.layer2e872-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  padding: 8px 16px;
  border-radius: var(--layer2e872-r-btn);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.3px;
  transition: transform 0.12s ease, filter 0.12s ease;
}

.layer2e872-btn:active { transform: scale(0.94); }

.layer2e872-btn-gold {
  background: linear-gradient(160deg, var(--layer2e872-gold-hi) 0%, var(--layer2e872-gold) 62%, #b5861a 100%);
  color: var(--layer2e872-ink);
  box-shadow: 0 3px 0 rgba(122, 89, 15, 0.75), 0 5px 12px rgba(0, 0, 0, 0.35);
}

.layer2e872-btn-ghost {
  background: rgba(189, 183, 107, 0.08);
  color: var(--layer2e872-cream);
  border: 1px solid var(--layer2e872-khaki);
}

.layer2e872-menubtn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 8px 13px;
  border-radius: var(--layer2e872-r-btn);
  font-size: 13.5px;
  font-weight: 700;
  color: var(--layer2e872-cream);
  background: rgba(255, 250, 205, 0.06);
  border: 1px solid var(--layer2e872-line-soft);
  transition: transform 0.12s ease;
}

.layer2e872-menubtn:active { transform: scale(0.94); }

.layer2e872-menubtn-ico { width: 16px; height: 16px; fill: var(--layer2e872-khaki); }

/* ---------- 4. Sectioned menu panel ---------- */
.layer2e872-menuveil {
  position: fixed;
  inset: 0;
  z-index: 65;
  background: rgba(9, 14, 22, 0.66);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.layer2e872-menuveil[data-open] { opacity: 1; pointer-events: auto; }

.layer2e872-menupanel {
  position: absolute;
  top: 100%; left: 0; right: 0;
  background: linear-gradient(180deg, var(--layer2e872-panel) 0%, #223046 100%);
  border-bottom: 2px solid var(--layer2e872-gold);
  border-radius: 0 0 14px 14px;
  padding: 14px 12px 18px;
  max-height: calc(100vh - var(--layer2e872-mast-h));
  overflow-y: auto;
  animation: layer2e872-panel-drop 0.22s ease both;
}

@keyframes layer2e872-panel-drop {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.layer2e872-menucat {
  font-family: var(--layer2e872-head-font);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--layer2e872-khaki);
  margin: 12px 4px 6px;
}

.layer2e872-menucat:first-child { margin-top: 2px; }

.layer2e872-menurow {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.layer2e872-menulink {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 9px 11px;
  border-radius: 9px;
  background: rgba(229, 229, 229, 0.05);
  border: 1px solid var(--layer2e872-line-soft);
  color: var(--layer2e872-mist);
  font-size: 13.5px;
  font-weight: 600;
  transition: transform 0.12s ease, background 0.12s ease;
}

.layer2e872-menulink:active { transform: scale(0.97); }

.layer2e872-menulink:hover, .layer2e872-menulink:focus-visible {
  background: rgba(189, 183, 107, 0.14);
  color: var(--layer2e872-cream);
  text-decoration: none;
}

.layer2e872-menulink-ico { width: 17px; height: 17px; flex: none; fill: var(--layer2e872-gold-hi); }

.layer2e872-menulink-note {
  display: block;
  font-size: 10.5px;
  font-weight: 400;
  color: var(--layer2e872-muted);
}

/* ---------- 5. Hero stage (banner carousel) ---------- */
.layer2e872-stage {
  position: relative;
  margin: 2px 0 14px;
}

.layer2e872-viewport {
  position: relative;
  aspect-ratio: 5 / 3;
  border-radius: var(--layer2e872-r-card);
  overflow: hidden;
  border: 1px solid var(--layer2e872-line);
  background: var(--layer2e872-abyss);
}

.layer2e872-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.55s ease;
}

.layer2e872-slide.layer2e872-is-on { opacity: 1; z-index: 2; }

.layer2e872-slide-hit {
  display: block;
  width: 100%; height: 100%;
  text-align: left;
}

.layer2e872-slide-hit img {
  width: 100%; height: 100%;
  object-fit: cover;
}

.layer2e872-slide-tag {
  position: absolute;
  left: 10px; right: 10px; bottom: 10px;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 11px;
  border-radius: 8px;
  background: rgba(26, 37, 52, 0.86);
  border: 1px solid var(--layer2e872-line);
  font-family: var(--layer2e872-head-font);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--layer2e872-cream);
  backdrop-filter: blur(2px);
}

.layer2e872-slide-tag::before {
  content: "";
  width: 7px; height: 7px;
  flex: none;
  border-radius: 50%;
  background: var(--layer2e872-gold-hi);
  box-shadow: 0 0 6px var(--layer2e872-gold-hi);
}

.layer2e872-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 9px;
}

.layer2e872-dot {
  width: 26px; height: 6px;
  border-radius: 4px;
  background: rgba(189, 183, 107, 0.3);
  transition: background 0.2s ease, width 0.2s ease;
}

.layer2e872-dot.layer2e872-is-on {
  width: 34px;
  background: linear-gradient(90deg, var(--layer2e872-gold), var(--layer2e872-khaki));
}

/* ---------- 6. Page title & quick chips ---------- */
.layer2e872-h1 {
  font-family: var(--layer2e872-head-font);
  font-size: 23px;
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: 0.2px;
  color: var(--layer2e872-cream);
  margin: 6px 0 4px;
}

.layer2e872-h1 em { font-style: normal; color: var(--layer2e872-gold-hi); }

.layer2e872-kicker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--layer2e872-khaki);
  margin-top: 2px;
}

.layer2e872-kicker::before {
  content: "";
  width: 18px; height: 2px;
  background: var(--layer2e872-gold);
}

.layer2e872-chiprail {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 12px 2px 14px;
  scrollbar-width: none;
}

.layer2e872-chiprail::-webkit-scrollbar { display: none; }

.layer2e872-chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(189, 183, 107, 0.1);
  border: 1px solid var(--layer2e872-line);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--layer2e872-cream);
  white-space: nowrap;
  transition: transform 0.12s ease;
}

.layer2e872-chip:active { transform: scale(0.95); }
.layer2e872-chip:hover, .layer2e872-chip:focus-visible { text-decoration: none; background: rgba(218, 165, 32, 0.18); }

.layer2e872-chip-ico { width: 14px; height: 14px; fill: var(--layer2e872-gold-hi); }

/* ---------- 7. Section headings ---------- */
.layer2e872-h2 {
  font-family: var(--layer2e872-head-font);
  font-size: 18.5px;
  line-height: 1.3;
  font-weight: 700;
  color: var(--layer2e872-cream);
  margin: 0 0 6px;
}

.layer2e872-lede {
  font-size: 14px;
  color: var(--layer2e872-mist);
  margin: 6px 0 10px;
}

.layer2e872-lede b, .layer2e872-prose b { color: var(--layer2e872-cream); }

.layer2e872-prose { font-size: 14px; color: var(--layer2e872-mist); }
.layer2e872-prose + .layer2e872-prose { margin-top: 9px; }

/* ---------- 8. Category layers (fact strip -> expandable) ---------- */
.layer2e872-catlayer {
  margin: 20px 0 6px;
  scroll-margin-top: calc(var(--layer2e872-mast-h) + 14px);
}

.layer2e872-cathead {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 10px 10px 0 0;
  background: linear-gradient(120deg, rgba(189, 183, 107, 0.16), rgba(218, 165, 32, 0.08));
  border: 1px solid var(--layer2e872-line);
  border-bottom: 0;
}

.layer2e872-cathead-ico {
  flex: none;
  width: 30px; height: 30px;
  margin-top: 2px;
  border-radius: 8px;
  padding: 5px;
  background: rgba(26, 37, 52, 0.7);
  border: 1px solid var(--layer2e872-line);
  fill: var(--layer2e872-gold-hi);
}

.layer2e872-catfacts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 10px;
}

.layer2e872-fact {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(229, 229, 229, 0.07);
  border: 1px solid var(--layer2e872-line-soft);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--layer2e872-muted);
}

.layer2e872-fact b { color: var(--layer2e872-cream); font-weight: 700; }

.layer2e872-fact-key {
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(218, 165, 32, 0.16);
  border: 1px solid rgba(218, 165, 32, 0.45);
  color: var(--layer2e872-cream);
}

.layer2e872-expand {
  margin: 0 0 12px;
  border: 1px dashed var(--layer2e872-line);
  border-radius: 10px;
  background: rgba(26, 37, 52, 0.5);
}

.layer2e872-expand > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 44px;
  padding: 10px 12px;
  font-family: var(--layer2e872-head-font);
  font-size: 13px;
  font-weight: 700;
  color: var(--layer2e872-khaki);
}

.layer2e872-expand > summary::-webkit-details-marker { display: none; }
.layer2e872-expand > summary::marker { content: ""; }

.layer2e872-expand > summary::after {
  content: "+";
  font-size: 16px;
  color: var(--layer2e872-gold-hi);
  transition: transform 0.15s ease;
}

.layer2e872-expand[open] > summary::after { transform: rotate(45deg); }

.layer2e872-expand-body {
  padding: 2px 12px 12px;
  font-size: 13.5px;
  color: var(--layer2e872-mist);
  border-top: 1px solid var(--layer2e872-line-soft);
  padding-top: 10px;
}

/* ---------- 9. Game grids: spotlight tile + compact tiles ---------- */
.layer2e872-catgrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 6px;
}

.layer2e872-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: var(--layer2e872-r-card);
  background: linear-gradient(180deg, var(--layer2e872-panel) 0%, #22304a 100%);
  border: 1px solid var(--layer2e872-line-soft);
  padding: 5px 5px 7px;
  text-align: center;
  transition: transform 0.12s ease, border-color 0.12s ease;
}

.layer2e872-tile:active { transform: scale(0.94); border-color: var(--layer2e872-gold); }
.layer2e872-tile:hover, .layer2e872-tile:focus-visible { border-color: var(--layer2e872-khaki); }

.layer2e872-tile-frame {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  overflow: hidden;
  background: #0e1622;
}

.layer2e872-tile-frame img {
  width: 100%; height: 100%;
  object-fit: cover;
}

.layer2e872-tile-name {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 5px;
  font-size: 11px;
  line-height: 1.3;
  font-weight: 600;
  color: var(--layer2e872-mist);
  overflow-wrap: break-word;
}

.layer2e872-tile-xl {
  grid-column: span 2;
  padding: 7px;
  border-color: var(--layer2e872-line);
  background: linear-gradient(165deg, #3a4f6b 0%, var(--layer2e872-panel) 55%, #1f2c40 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 250, 205, 0.08);
}

.layer2e872-tile-xl .layer2e872-tile-name {
  font-family: var(--layer2e872-head-font);
  font-size: 14px;
  font-weight: 700;
  color: var(--layer2e872-cream);
  -webkit-line-clamp: 1;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

.layer2e872-tile-xl .layer2e872-tile-tag {
  display: block;
  margin-top: 2px;
  font-size: 10.5px;
  line-height: 1.35;
  color: var(--layer2e872-khaki);
}

.layer2e872-tile-flag {
  position: absolute;
  top: 9px; left: 9px;
  padding: 2px 7px;
  border-radius: 5px;
  background: linear-gradient(140deg, var(--layer2e872-gold-hi), var(--layer2e872-gold));
  color: var(--layer2e872-ink);
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  z-index: 2;
}

/* ---------- 10. Editorial modules (tricks / ladder / Q&A) ---------- */
.layer2e872-module {
  margin: 26px 0 8px;
  padding: 14px 13px;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(43, 60, 82, 0.9), rgba(30, 42, 58, 0.92));
  border: 1px solid var(--layer2e872-line-soft);
}

.layer2e872-module-gold { border-color: rgba(218, 165, 32, 0.4); }

.layer2e872-trick {
  display: flex;
  gap: 10px;
  padding: 11px 2px;
  border-bottom: 1px solid var(--layer2e872-line-soft);
}

.layer2e872-trick:last-of-type { border-bottom: 0; }

.layer2e872-tricknum {
  flex: none;
  width: 30px; height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  background: rgba(218, 165, 32, 0.16);
  border: 1px solid rgba(218, 165, 32, 0.5);
  font-family: var(--layer2e872-head-font);
  font-size: 14px;
  font-weight: 800;
  color: var(--layer2e872-gold-hi);
}

.layer2e872-trick h3 {
  font-family: var(--layer2e872-head-font);
  font-size: 14.5px;
  color: var(--layer2e872-cream);
  margin-bottom: 3px;
}

.layer2e872-trick p { font-size: 13px; color: var(--layer2e872-mist); }

/* milestone ladder */
.layer2e872-ladder { margin-top: 4px; }

.layer2e872-step {
  display: flex;
  gap: 10px;
  align-items: stretch;
  padding: 10px 0;
  border-bottom: 1px solid var(--layer2e872-line-soft);
}

.layer2e872-step:last-child { border-bottom: 0; }

.layer2e872-step-rail {
  flex: none;
  width: 40px;
  text-align: center;
  font-family: var(--layer2e872-head-font);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--layer2e872-khaki);
  border-right: 2px solid var(--layer2e872-line);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.layer2e872-step-gem {
  width: 13px; height: 13px;
  transform: rotate(45deg);
  border-radius: 3px;
  background: rgba(189, 183, 107, 0.35);
  border: 1px solid var(--layer2e872-khaki);
}

.layer2e872-step.layer2e872-step-hot .layer2e872-step-gem {
  background: linear-gradient(140deg, var(--layer2e872-gold-hi), var(--layer2e872-gold));
  border-color: var(--layer2e872-gold-hi);
  box-shadow: 0 0 7px rgba(238, 192, 74, 0.7);
}

.layer2e872-step-main h3 {
  font-family: var(--layer2e872-head-font);
  font-size: 14.5px;
  color: var(--layer2e872-cream);
}

.layer2e872-step-main p { font-size: 12.8px; color: var(--layer2e872-muted); }

.layer2e872-trackbar {
  margin-top: 6px;
  height: 5px;
  border-radius: 4px;
  background: rgba(229, 229, 229, 0.1);
  overflow: hidden;
}

.layer2e872-trackfill {
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--layer2e872-khaki), var(--layer2e872-gold-hi));
}

/* Q&A blocks */
.layer2e872-qa {
  margin-top: 10px;
  padding: 11px 12px;
  border-radius: 10px;
  background: rgba(26, 37, 52, 0.65);
  border: 1px solid var(--layer2e872-line-soft);
  border-left: 3px solid var(--layer2e872-gold);
}

.layer2e872-qa-q {
  font-family: var(--layer2e872-head-font);
  font-size: 13.5px;
  font-weight: 700;
  color: var(--layer2e872-cream);
}

.layer2e872-qa-a {
  display: block;
  margin: 6px 0 4px;
  font-size: 13px;
  font-weight: 700;
  color: var(--layer2e872-gold-hi);
}

.layer2e872-qa p { font-size: 12.8px; color: var(--layer2e872-mist); }

/* role chips */
.layer2e872-rolechips {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  margin-top: 12px;
}

.layer2e872-rolechip {
  padding: 9px 8px;
  border-radius: 10px;
  text-align: center;
  background: rgba(189, 183, 107, 0.09);
  border: 1px solid var(--layer2e872-line-soft);
}

.layer2e872-rolechip-ico { width: 18px; height: 18px; margin: 0 auto 4px; fill: var(--layer2e872-gold-hi); }

.layer2e872-rolechip span {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--layer2e872-cream);
}

/* ---------- 11. Extended footer (homepage directory) ---------- */
.layer2e872-xfoot {
  margin: 28px 0 14px;
  border-top: 2px solid var(--layer2e872-line);
  padding-top: 16px;
}

.layer2e872-xf-kicker {
  font-family: var(--layer2e872-head-font);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--layer2e872-khaki);
  margin-bottom: 8px;
}

.layer2e872-dirgrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.layer2e872-dirlink {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 8px 10px;
  border-radius: 9px;
  background: rgba(229, 229, 229, 0.05);
  border: 1px solid var(--layer2e872-line-soft);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--layer2e872-mist);
  transition: transform 0.12s ease;
}

.layer2e872-dirlink:active { transform: scale(0.97); }
.layer2e872-dirlink:hover, .layer2e872-dirlink:focus-visible { text-decoration: none; color: var(--layer2e872-cream); border-color: var(--layer2e872-khaki); }

.layer2e872-dirlink-ico { width: 15px; height: 15px; flex: none; fill: var(--layer2e872-khaki); }

.layer2e872-brandnote {
  margin: 16px 0;
  padding: 11px 12px;
  border-radius: 10px;
  background: rgba(26, 37, 52, 0.6);
  border: 1px solid var(--layer2e872-line-soft);
  font-size: 12.8px;
  color: var(--layer2e872-muted);
}

.layer2e872-brandnote b { color: var(--layer2e872-cream); }

.layer2e872-promogrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.layer2e872-promo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: 56px;
  padding: 9px 8px;
  border-radius: 10px;
  background: linear-gradient(160deg, rgba(218, 165, 32, 0.2), rgba(189, 183, 107, 0.08));
  border: 1px solid rgba(218, 165, 32, 0.5);
  font-family: var(--layer2e872-head-font);
  font-size: 13px;
  font-weight: 800;
  color: var(--layer2e872-cream);
  transition: transform 0.12s ease;
}

.layer2e872-promo:active { transform: scale(0.95); }
.layer2e872-promo:hover, .layer2e872-promo:focus-visible { text-decoration: none; color: var(--layer2e872-cream); border-color: var(--layer2e872-gold-hi); }

.layer2e872-promo-ico { width: 17px; height: 17px; fill: var(--layer2e872-gold-hi); }

.layer2e872-promo small {
  font-family: var(--layer2e872-body-font);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.4px;
  color: var(--layer2e872-muted);
}

.layer2e872-legal {
  margin-top: 16px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px dashed var(--layer2e872-line);
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--layer2e872-muted);
}

/* ---------- 12. Common footer ---------- */
.layer2e872-footer {
  margin: 18px 0 4px;
  padding-top: 12px;
  border-top: 1px solid var(--layer2e872-line-soft);
  text-align: center;
}

.layer2e872-footer p {
  font-size: 11.5px;
  color: var(--layer2e872-muted);
}

.layer2e872-footer b { color: var(--layer2e872-khaki); font-weight: 700; }

/* ---------- 13. Fixed bottom dock (full-width nav rail) ---------- */
.layer2e872-dock {
  position: fixed;
  bottom: 0; left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px;
  z-index: 80;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: linear-gradient(180deg, #1f2c40 0%, #16202f 100%);
  border-top: 1px solid var(--layer2e872-line);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  box-shadow: 0 -6px 16px rgba(8, 13, 21, 0.6);
}

.layer2e872-dockitem {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: var(--layer2e872-dock-h);
  padding: 8px 2px 7px;
  color: var(--layer2e872-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.3px;
  transition: color 0.15s ease, transform 0.12s ease;
}

.layer2e872-dockitem:active { transform: translateY(1px) scale(0.93); }

.layer2e872-dockitem:hover, .layer2e872-dockitem:focus-visible { text-decoration: none; color: var(--layer2e872-cream); }

.layer2e872-dockitem::before {
  /* active indicator: crisp top line */
  content: "";
  position: absolute;
  top: 0; left: 22%; right: 22%;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: transparent;
}

.layer2e872-dockitem.layer2e872-is-here {
  color: var(--layer2e872-cream);
  background: linear-gradient(180deg, rgba(218, 165, 32, 0.14), transparent 70%);
}

.layer2e872-dockitem.layer2e872-is-here::before {
  background: linear-gradient(90deg, var(--layer2e872-gold-hi), var(--layer2e872-khaki));
  box-shadow: 0 1px 6px rgba(238, 192, 74, 0.55);
}

.layer2e872-dockicon { width: 21px; height: 21px; fill: currentColor; }

.layer2e872-dockitem.layer2e872-is-here .layer2e872-dockicon { filter: drop-shadow(0 0 4px rgba(238, 192, 74, 0.6)); }

.layer2e872-dockbadge {
  position: absolute;
  top: 6px; right: 18%;
  min-width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--layer2e872-gold-hi);
  box-shadow: 0 0 5px rgba(238, 192, 74, 0.8);
}

/* ---------- 14. Reveal motion (restrained) ---------- */
.layer2e872-rise {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.layer2e872-rise.layer2e872-in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .layer2e872-rise { opacity: 1; transform: none; transition: none; }
  .layer2e872-menupanel { animation: none; }
  .layer2e872-slide { transition: none; }
}

/* ---------- 15. Breakpoints ---------- */
@media (max-width: 430px) {
  /* core phone band: tighten rhythm so nothing crowds at 320-430px */
  .layer2e872-page { padding-left: 10px; padding-right: 10px; }
  .layer2e872-h1 { font-size: 22px; }
  .layer2e872-catgrid { gap: 7px; }
  .layer2e872-tile-name { font-size: 10.5px; }
  .layer2e872-dirgrid, .layer2e872-promogrid { gap: 6px; }
}

@media (max-width: 359px) {
  .layer2e872-brand-word { font-size: 17px; }
  .layer2e872-brand-mark { width: 30px; height: 30px; }
  .layer2e872-btn { padding: 8px 12px; font-size: 13px; }
  .layer2e872-h1 { font-size: 20px; }
  .layer2e872-h2 { font-size: 17px; }
}

@media (min-width: 375px) {
  .layer2e872-tile-name { font-size: 11.5px; }
  .layer2e872-slide-tag { font-size: 13px; }
  .layer2e872-promogrid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (min-width: 431px) {
  /* wide screens keep the centered phone canvas framed like a device */
  body { background: radial-gradient(120% 90% at 50% 0%, #17222f 0%, #0c1420 70%); }
  .layer2e872-shell {
    box-shadow: 0 0 0 1px rgba(189, 183, 107, 0.22), 0 18px 60px rgba(0, 0, 0, 0.6);
  }
}

@media (min-width: 375px) and (max-width: 430px) {
  .layer2e872-page { padding-left: 12px; padding-right: 12px; }
}

/* smooth anchor jumps unless the visitor asks stillness */
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}
