
/* =========================================================
   FORA WAREHOUSE // NIGHT SHIFT
   Автономная пасхалка. Не влияет на рабочий интерфейс.
   ========================================================= */

.fora-easter-armed .brandbox{
  animation:foraSecretPulse .7s ease-in-out infinite alternate;
}
@keyframes foraSecretPulse{
  from{filter:drop-shadow(0 0 0 rgba(32,202,109,0));transform:scale(1)}
  to{filter:drop-shadow(0 0 10px rgba(32,202,109,.8));transform:scale(1.05)}
}

#foraNightShift{
  position:fixed;
  inset:0;
  z-index:10000;
  display:none;
  width:100%;
  height:100%;
  background:#06100b;
  color:#d8ffe8;
  font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,"Liberation Mono",monospace;
  overscroll-behavior:none;
  touch-action:none;
}
#foraNightShift.open{
  display:flex;
  flex-direction:column;
}
body.fora-night-open{
  overflow:hidden !important;
}

/* Terminal intro */
.fora-night-terminal{
  position:absolute;
  inset:0;
  z-index:50;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
  background:
    radial-gradient(circle at center,rgba(17,74,42,.2),transparent 55%),
    #031008;
}
.fora-night-terminal.hidden{display:none}
.fora-night-terminal pre{
  width:min(760px,100%);
  margin:0;
  color:#6bff9d;
  font-size:clamp(13px,2.5vw,21px);
  line-height:1.55;
  white-space:pre-wrap;
  text-shadow:0 0 12px rgba(57,255,127,.28);
}

/* Main shell */
.fora-night-shell{
  position:relative;
  display:grid;
  grid-template-rows:auto minmax(0,1fr) auto;
  gap:8px;
  width:100%;
  height:100%;
  min-height:0;
  padding:10px;
  box-sizing:border-box;
  background:
    radial-gradient(circle at 30% 0%,rgba(16,95,53,.22),transparent 36%),
    #06100b;
}
.fora-night-hud{
  display:grid;
  grid-template-columns:auto auto auto auto 1fr auto;
  gap:7px;
  align-items:center;
  min-width:0;
}
.fora-night-chip{
  display:flex;
  align-items:center;
  gap:6px;
  min-height:34px;
  padding:6px 10px;
  border:1px solid rgba(122,255,170,.2);
  border-radius:10px;
  background:rgba(3,29,16,.84);
  white-space:nowrap;
}
.fora-night-chip strong{color:#8effb5}
.fora-night-wallet strong{color:#ffd96b}
.fora-night-title{
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  color:#8effb5;
  font-weight:800;
  letter-spacing:.04em;
}
.fora-night-close{
  width:38px;
  height:38px;
  border:1px solid rgba(255,255,255,.18);
  border-radius:10px;
  background:#101d16;
  color:#e5fff0;
  font:700 20px/1 inherit;
  cursor:pointer;
}

/* Stage */
.fora-night-stage{
  position:relative;
  display:flex;
  align-items:center;
  justify-content:center;
  min-width:0;
  min-height:0;
  overflow:hidden;
  border:1px solid rgba(122,255,170,.18);
  border-radius:14px;
  background:#08140e;
  box-shadow:inset 0 0 45px rgba(0,0,0,.5);
}
#foraNightCanvas{
  display:block;
  max-width:100%;
  max-height:100%;
  width:auto;
  height:auto;
  aspect-ratio:16/10;
  image-rendering:auto;
  touch-action:none;
}

.fora-night-message{
  position:absolute;
  top:12px;
  left:50%;
  transform:translateX(-50%);
  z-index:9;
  max-width:calc(100% - 30px);
  padding:7px 12px;
  border:1px solid rgba(255,255,255,.14);
  border-radius:999px;
  background:rgba(0,0,0,.78);
  color:#fff;
  font:700 13px/1.3 system-ui,sans-serif;
  text-align:center;
  opacity:0;
  transition:opacity .15s ease;
  pointer-events:none;
}
.fora-night-message.show{opacity:1}

/* Start / End / Garage */
.fora-night-layer{
  position:absolute;
  inset:0;
  z-index:20;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:18px;
  overflow:auto;
  background:rgba(2,11,7,.82);
  backdrop-filter:blur(5px);
}
.fora-night-layer.hidden{display:none}
.fora-night-card{
  width:min(610px,100%);
  max-height:100%;
  overflow:auto;
  padding:20px;
  border:1px solid rgba(114,255,166,.28);
  border-radius:16px;
  background:#071b10;
  box-shadow:0 20px 70px rgba(0,0,0,.55);
  box-sizing:border-box;
}
.fora-night-card.wide{width:min(860px,100%)}
.fora-night-card h2{
  margin:0 0 8px;
  color:#8effb5;
  font:800 clamp(22px,4vw,36px)/1.05 system-ui,sans-serif;
}
.fora-night-card h3{
  margin:18px 0 8px;
  color:#d9f8e4;
  font:800 17px/1.2 system-ui,sans-serif;
}
.fora-night-card p{
  margin:7px 0;
  color:#c2dbc9;
  font:14px/1.42 system-ui,sans-serif;
}
.fora-night-card .secret-help{
  margin-top:13px;
  padding:10px;
  border-radius:10px;
  background:rgba(255,255,255,.045);
  color:#93ad9c;
  font:12px/1.4 system-ui,sans-serif;
}

.fora-night-card-actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
  margin-top:14px;
}
.fora-night-primary,
.fora-night-secondary{
  min-height:48px;
  border-radius:11px;
  font:800 15px/1 system-ui,sans-serif;
  cursor:pointer;
}
.fora-night-primary{
  border:0;
  background:#1fa760;
  color:white;
}
.fora-night-primary:hover{background:#16894e}
.fora-night-secondary{
  border:1px solid rgba(255,255,255,.17);
  background:#11271b;
  color:#d8ffe8;
}
.fora-night-secondary:hover{background:#183625}

.fora-night-start-stats{
  display:flex;
  flex-wrap:wrap;
  gap:7px;
  margin-top:11px;
}
.fora-night-start-stats span{
  padding:6px 9px;
  border-radius:999px;
  background:#102b1c;
  color:#c7e6d2;
  font:700 12px/1 system-ui,sans-serif;
}

.fora-night-kpis{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:8px;
  margin:13px 0;
}
.fora-night-kpis div{
  padding:9px;
  border-radius:10px;
  background:rgba(255,255,255,.05);
}
.fora-night-kpis small{
  display:block;
  color:#86a992;
  font:12px/1.2 system-ui,sans-serif;
}
.fora-night-kpis b{
  display:block;
  margin-top:3px;
  color:#fff;
  font:800 20px/1 system-ui,sans-serif;
}
.fora-night-earned{
  color:#ffd96b !important;
}

/* Garage */
.fora-garage-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}
.fora-garage-wallet{
  flex:0 0 auto;
  padding:7px 10px;
  border-radius:999px;
  background:#2d2711;
  color:#ffd96b;
  font:800 14px/1 system-ui,sans-serif;
}
.fora-shop-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
}
.fora-shop-item{
  display:grid;
  grid-template-columns:48px minmax(0,1fr);
  gap:9px;
  min-width:0;
  padding:10px;
  border:1px solid rgba(255,255,255,.1);
  border-radius:12px;
  background:rgba(255,255,255,.035);
}
.fora-shop-item.selected{
  border-color:#42d486;
  box-shadow:0 0 0 2px rgba(66,212,134,.12);
}
.fora-shop-preview{
  width:48px;
  height:48px;
  border-radius:10px;
  border:1px solid rgba(255,255,255,.12);
  display:flex;
  align-items:center;
  justify-content:center;
  font:900 16px/1 system-ui,sans-serif;
}
.fora-shop-info{
  min-width:0;
}
.fora-shop-info b{
  display:block;
  color:#fff;
  font:800 14px/1.2 system-ui,sans-serif;
}
.fora-shop-info small{
  display:block;
  min-height:30px;
  margin-top:3px;
  color:#8fa99a;
  font:11px/1.3 system-ui,sans-serif;
}
.fora-shop-action{
  width:100%;
  min-height:36px;
  margin-top:7px;
  border:1px solid rgba(255,255,255,.14);
  border-radius:8px;
  background:#132b1d;
  color:#d8ffe8;
  font:800 12px/1 system-ui,sans-serif;
}
.fora-shop-action.buy{background:#514418;color:#ffe07b}
.fora-shop-action:disabled{
  opacity:.45;
  cursor:not-allowed;
}
.fora-upgrade-icon{
  width:48px;
  height:48px;
  border-radius:10px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#102c1e;
  font-size:24px;
}

/* Controls */
.fora-night-controls{
  display:grid;
  grid-template-columns:auto 1fr auto;
  gap:10px;
  align-items:end;
  min-height:0;
}
.fora-night-dpad{
  display:grid;
  grid-template-columns:repeat(3,48px);
  grid-template-rows:repeat(2,48px);
  gap:4px;
}
.fora-night-btn{
  display:flex;
  align-items:center;
  justify-content:center;
  min-width:48px;
  min-height:48px;
  border:1px solid rgba(146,255,187,.18);
  border-radius:10px;
  background:#102319;
  color:#d8ffe8;
  font:800 20px/1 system-ui,sans-serif;
  user-select:none;
  -webkit-user-select:none;
  touch-action:none;
}
.fora-night-btn:active,
.fora-night-btn.active{
  background:#1d5f3b;
  transform:translateY(1px);
}
.fora-night-up{grid-column:2}
.fora-night-left{grid-column:1;grid-row:2}
.fora-night-down{grid-column:2;grid-row:2}
.fora-night-right{grid-column:3;grid-row:2}

.fora-night-tip{
  align-self:center;
  justify-self:center;
  color:#70917b;
  font-size:12px;
  text-align:center;
}
.fora-night-action{
  min-width:126px;
  min-height:52px;
  padding:8px 14px;
  border:1px solid #2bc473;
  border-radius:12px;
  background:#174d31;
  color:#fff;
  font:800 14px/1.15 system-ui,sans-serif;
  touch-action:none;
}
.fora-night-action:active{background:#237547}
.fora-night-golden{color:#ffd95c !important}

/* Mobile */
@media (hover:hover) and (pointer:fine){
  .fora-night-dpad,
  .fora-night-action{opacity:.38}
}
@media(max-width:700px){
  .fora-night-shell{padding:6px;gap:6px}
  .fora-night-hud{
    grid-template-columns:repeat(4,auto) 1fr auto;
    gap:4px;
  }
  .fora-night-chip{
    min-height:30px;
    padding:5px 7px;
    font-size:11px;
  }
  .fora-night-title{display:none}
  .fora-night-controls{grid-template-columns:auto 1fr auto;gap:7px}
  .fora-night-dpad{
    grid-template-columns:repeat(3,44px);
    grid-template-rows:repeat(2,44px);
    gap:3px;
  }
  .fora-night-btn{min-width:44px;min-height:44px}
  .fora-night-action{min-width:110px;min-height:50px}
  .fora-night-tip{font-size:10px}
  .fora-shop-grid{grid-template-columns:1fr}
  .fora-night-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:460px){
  .fora-night-hud{
    grid-template-columns:repeat(4,minmax(0,1fr)) auto;
  }
  .fora-night-chip{
    justify-content:center;
    padding:4px;
    gap:3px;
  }
  .fora-night-tip{display:none}
  .fora-night-controls{grid-template-columns:auto 1fr}
  .fora-night-action{width:100%;min-width:0}
  .fora-night-card-actions{grid-template-columns:1fr}
}


/* v0.6.66 — мобильный секретный long-press без меню браузера */
.brand .brandbox{
  -webkit-touch-callout:none !important;
  -webkit-user-select:none !important;
  user-select:none !important;
  -webkit-tap-highlight-color:transparent;
  touch-action:manipulation;
}

.brand .brandbox *,
.brand > span:not(.brandbox){
  -webkit-touch-callout:none !important;
  -webkit-user-select:none !important;
  user-select:none !important;
}

.fora-easter-armed .brandbox{
  touch-action:none !important;
}

/* v0.6.119 — touch anti-menu hardening */
.fora-night-dpad,
.fora-night-btn,
.fora-night-action{
  -webkit-touch-callout:none;
  -webkit-user-select:none;
  user-select:none;
  -webkit-tap-highlight-color:transparent;
}
.fora-night-btn,
.fora-night-action{
  touch-action:none;
}
