/* Bottom navigation (nav() in js/app.js) styled after the owner's wayfinding-sign reference: a white lightbox face in a thick dark rim
 * with a thin black line inside, an extruded back edge below, two ceiling mounts on top, Russian labels only (owner, 2026-11-18: no English sublines),
 * thin dividers, the active item as a black LED plate with glowing digits, a round badge like a metro line number.
 * Palette from the owner's brief: #000 · #7A1E1E · #FF6A00 · #D8C6B2 · #EFEAE3 · #FAFAF6. Overrides components.css / reference-match.css. */

.stc-nav{container-type:inline-size;display:flex;height:74px;padding:9px 9px;gap:0;border:0;border-radius:24px;background:none;box-shadow:none;
  -webkit-backdrop-filter:none;backdrop-filter:none;overflow:visible}
/* Face and rim */
.stc-nav::before{content:"";position:absolute;z-index:-1;inset:0;border-radius:inherit;border:5px solid #1c090b;
  background:radial-gradient(ellipse 80% 120% at 50% 0,#fff 0,rgba(255,255,255,0) 70%),linear-gradient(180deg,#FAFAF6 0%,#F3EFE8 62%,#E9E2D8 100%);
  box-shadow:inset 0 0 0 1px #000,inset 0 -6px 10px -6px rgba(60,40,30,.18),0 1px 0 rgba(255,220,200,.10)}
/* Extruded back edge, seen below the face as on a hanging sign */
.stc-nav::after{content:"";position:absolute;z-index:-2;left:5px;right:5px;top:8px;bottom:-7px;border-radius:22px;
  background:linear-gradient(180deg,#2a0e12,#140507 70%,#0b0304);box-shadow:0 16px 30px -8px rgba(0,0,0,.75),0 4px 10px rgba(0,0,0,.4)}
/* Two ceiling mounts on the top edge */
.stc-nav__mounts{position:absolute;top:-5px;left:0;right:0;height:6px;pointer-events:none}
.stc-nav__mounts::before,.stc-nav__mounts::after{content:"";position:absolute;top:0;width:12px;height:6px;border-radius:3px 3px 0 0;
  background:linear-gradient(180deg,#3a161b,#1c090b)}
.stc-nav__mounts::before{left:27%}
.stc-nav__mounts::after{right:27%}

/* Items: icon like the sign's bold arrows, Russian label. Width follows the label, spare room is shared evenly,
 * so the long «Сохранённое» fits without cutting */
.nav-item{flex:1 1 auto;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:0;min-width:0;padding:0 5px;border-radius:11px;color:#141110;cursor:pointer;
  transition:transform .15s var(--stc-ease,ease)}
.nav-item:active{transform:scale(.95)}
.nav-item:focus-visible{outline:2px solid var(--stc-orange,#FF6A00);outline-offset:-2px}
.nav-item+.nav-item::after{content:"";position:absolute;left:0;top:12px;bottom:12px;width:1px;background:rgba(20,17,16,.14)}
.nav-item.is-active::after,.nav-item.is-active+.nav-item::after{opacity:0}
.nav-item__icon{position:relative;display:grid;place-items:center;height:20px;margin-bottom:4px}
.nav-item .icon-svg{width:18px;height:18px;color:#2d2725;stroke-width:2}
.nav-item__ru{max-width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:10.5px;font-weight:500;line-height:1.15;letter-spacing:-.01em;color:#141110}

/* Active item: black LED plate with glowing orange digits */
.nav-item.is-active::before{content:"";position:absolute;z-index:-1;inset:1px 3px;border-radius:10px;
  background:radial-gradient(ellipse 90% 70% at 50% 40%,rgba(255,106,0,.10),transparent 70%),linear-gradient(180deg,#1b1716,#0b0909);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.08),inset 0 -2px 4px rgba(0,0,0,.6),0 1px 2px rgba(0,0,0,.35)}
.nav-item.is-active .icon-svg{color:#FF6A00;filter:drop-shadow(0 0 4px rgba(255,106,0,.55))}
.nav-item.is-active .nav-item__ru{color:#FF8A3D;text-shadow:0 0 6px rgba(255,106,0,.5)}
.nav-item.is-active 
/* Round badge with the number of saved materials, like the metro line circle */
.nav-item__badge{position:absolute;top:-5px;left:calc(50% + 5px);min-width:16px;height:16px;padding:0 4px;border-radius:8px;
  background:#7A1E1E;box-shadow:0 0 0 1.5px #FAFAF6;color:#FAFAF6;font-size:9px;font-weight:600;line-height:16px;text-align:center;font-variant-numeric:tabular-nums}
.nav-item.is-active .nav-item__badge{box-shadow:0 0 0 1.5px #0b0909}

/* Narrow phones: smaller labels so «Сохранённое» still fits */
@container (max-width:320px){
  .nav-item{padding:0 3px}
  .nav-item__ru{font-size:9.5px;letter-spacing:-.02em}
  }

@media (prefers-reduced-motion:reduce){.nav-item{transition:none}}

/* Menu is on (owner, 2026-11-18; hidden 2026-10-16 → 2026-11-18). To hide it again: .stc-nav{display:none} + :root{--nav-space:0px}.
 * Gate screens (loading, no access) empty it (js/boot.js) — an empty sign is not drawn */
.stc-nav:empty{display:none}
