/* Opt-in GAME420 layout. No artwork, control geometry or press animation changes. */
html[data-game420-a] body.auth-entry:has(.game420-viewport) {
  display:flex;flex-direction:column;align-items:center;justify-content:flex-start!important;
  padding:max(4px,env(safe-area-inset-top)) max(4px,env(safe-area-inset-right)) max(4px,env(safe-area-inset-bottom)) max(4px,env(safe-area-inset-left))!important;
  gap:0;min-width:0;box-sizing:border-box;
}
html[data-game420-a] .game420-viewport {
  width:100%;max-width:660px;flex:none;overflow:clip;position:relative;
}
/* The source has black lateral margins: remove 40/1086 on each side only.
   The entire photographed casing remains inside this viewport; the inner frame
   keeps the original 1086:1448 ratio and all percentage-mapped hit targets. */
html[data-game420-a] body.auth-entry .game420-viewport>main.game420-console {
  width:107.9522862823%!important;min-width:0;max-width:none!important;
  margin:0 0 0 -3.9761431412%!important;aspect-ratio:3/4;
}
html[data-game420-a] body.auth-entry .game420-test-note {
  flex:none;width:100%;max-width:570px;margin:6px 0 0;box-sizing:border-box;padding:0 6px;
}
html[data-game420-a] body.auth-entry #console-screen {container-type:inline-size;}
html[data-game420-a] body.auth-entry #console-screen>#journey-host {
  flex:1 1 0;min-width:0;min-height:0!important;height:auto!important;overflow:hidden!important;
}
html[data-game420-a] body.auth-entry #console-screen>.screen-hud {
  padding:0 2px;gap:0;max-width:100%;overflow:hidden;
}
html[data-game420-a] body.auth-entry #screen-location {
  margin:0;white-space:normal;overflow-wrap:anywhere;font-size:11px;letter-spacing:0;line-height:1.15;
}
html[data-game420-a] body.auth-entry #screen-shortcuts {padding:0;gap:0;}
html[data-game420-a] body.auth-entry .screen-shortcut {width:40px;min-width:40px;height:44px;padding:9px;}
html[data-game420-a] body.auth-entry #console-screen>.entry-panel:not(#start-panel):not(#journey-host) {
  padding:8px;scroll-padding:8px;overflow-x:hidden;min-width:0;
}
html[data-game420-a] body.auth-entry #destination-title {font-size:20px;margin:0 0 4px;}
html[data-game420-a] body.auth-entry #destination-panel:not([hidden]) {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-rows:max-content;align-content:start;gap:4px;}
html[data-game420-a] body.auth-entry #destination-panel> :is(h2,p) {grid-column:1/-1;}
html[data-game420-a] body.auth-entry #destination-panel>h2 {order:0;}
html[data-game420-a] body.auth-entry #destination-panel>.destination-card {order:1;}
html[data-game420-a] body.auth-entry #destination-panel>p {order:2;}
html[data-game420-a] body.auth-entry #destination-panel .screen-kicker {font-size:11px;line-height:1.35;margin:0 0 4px;}
html[data-game420-a] body.auth-entry #destination-panel .panel-intro {font-size:13px;line-height:1.35;margin:4px 0 8px;}
html[data-game420-a] body.auth-entry #destination-panel .destination-card {position:relative;display:block;min-width:0;min-height:58px;gap:7px;padding:18px 5px 7px;margin:0;box-sizing:border-box;text-align:center;}
html[data-game420-a] body.auth-entry #destination-panel .destination-card strong {font-size:20px;}
html[data-game420-a] body.auth-entry #destination-panel .destination-card small {font-size:13px;line-height:1.3;margin-top:3px;}
html[data-game420-a] body.auth-entry #destination-panel .destination-icon {position:absolute;top:4px;left:5px;font-size:14px;}
html[data-game420-a] body.auth-entry #destination-panel .destination-card>span:last-child {position:absolute;top:5px;right:5px;font-size:10px;}
html[data-game420-a] body.auth-entry #destination-panel .destination-note {font-size:12px;margin:8px 0 0;}
/* The existing filters and Return reserve their own space around the scroll area.
   Product dimensions and reception information stay unchanged. */
html[data-game420-a] body.auth-entry #screen3-container #menu3Scroll {
  inset:50px 0 48px;min-height:0;height:auto;max-height:none;padding:3px 4px 8px;
  display:flex;flex-direction:column;gap:6px;overflow-x:hidden;overflow-y:auto;
  overscroll-behavior:contain;scrollbar-width:thin;scroll-padding:4px;
}
html[data-game420-a] body.auth-entry .game420-carousel {
  position:relative;flex:none;width:100%;height:clamp(110px,50cqw,240px);min-height:110px;
}
html[data-game420-a] body.auth-entry .game420-carousel:has(>#menu3Grid[hidden]) {display:none;}
html[data-game420-a] body.auth-entry #screen3-container #menu3Grid {height:100%;min-height:0;width:100%;}
html[data-game420-a] body.auth-entry #screen3-container #catalogNav {inset:0;height:100%;}
html[data-game420-a] body.auth-entry #screen3-container #catalogPosition {top:0;right:2px;}
html[data-game420-a] body.auth-entry #screen3-container #catalogSummary {margin:0;padding:4px;}
html[data-game420-a] body.auth-entry #screen3-container #catalogName {font-size:15px;}
html[data-game420-a] body.auth-entry #screen3-container :is(#catalogThumbs,.reception-compact) {
  position:relative;inset:auto;width:100%;flex:none;margin:0;box-sizing:border-box;
}
html[data-game420-a] body.auth-entry #screen3-container #filtersBar {
  position:absolute;inset:2px 4px auto;width:auto;height:44px;margin:0;padding:0;
  display:grid;grid-template-columns:minmax(0,3fr) minmax(0,3fr) minmax(0,4fr);gap:5px;
}
html[data-game420-a] body.auth-entry #screen3-container #filtersBar .catalog-filter {color:#F3F5E9;}
html[data-game420-a] body.auth-entry #screen3-container #filtersBar .catalog-filter>span {
  left:6px;right:5px;font:10px/1.1 Arial,sans-serif;
}
html[data-game420-a] body.auth-entry #screen3-container #filtersBar select {
  appearance:none;-webkit-appearance:none;display:block;width:100%;min-width:0;
  height:44px;min-height:44px;box-sizing:border-box;padding:17px 12px 3px 5px;
  border:1px solid #A8FF4580;border-radius:4px;background-color:#07120Df5;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='m1 1 4 4 4-4' fill='none' stroke='%23A8FF45' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:right 3px bottom 11px;background-size:7px 5px;
  color:#F3F5E9;font:14px/1.3 Arial,sans-serif;text-overflow:ellipsis;cursor:pointer;
  box-shadow:inset 0 1px 0 #A855F726;text-shadow:none;
}
html[data-game420-a] body.auth-entry #screen3-container #filtersBar select:is(:focus-visible,.console-selected) {
  color:#A8FF45;border-color:#A8FF45;outline:1px solid #A855F7!important;outline-offset:1px;
  box-shadow:0 0 4px #A855F733!important;filter:none!important;
}
html[data-game420-a] body.auth-entry #screen3-container #filtersBar option {background:#07120D;color:#F3F5E9;}
html[data-game420-a] body.auth-entry #screen3-container #filtersBar option:checked {background:#19301A;color:#A8FF45;}
html[data-game420-a] body.auth-entry #screen3-container .reception-compact>button {grid-column:2;}
html[data-game420-a] body.auth-entry #screen3-container .reception-status {font-size:12px;overflow-wrap:anywhere;}
html[data-game420-a] body.auth-entry #screen3-container .catalog-return {position:absolute;inset:auto auto 3px 5px;width:auto;height:44px;}
html[data-game420-a] body.auth-entry #screen3-container #menuBackBtn {color:#A8FF45;background:#07120Dee;border-radius:4px;}
html[data-game420-a] body.auth-entry #screen3-container #menuBackBtn:focus-visible {outline:1px solid #A855F7;outline-offset:-1px;}
html[data-game420-a] body.auth-entry #screen3-container .catalog-back {font-size:14px;}
/* MENU-only visual polish: keep the existing media, controls and block spacing. */
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogSummary {
  display:grid;grid-template-columns:minmax(12px,1fr) minmax(0,auto) minmax(12px,1fr);column-gap:10px;
  background:transparent;border:0;box-shadow:none;
}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogName {
  grid-column:2;grid-row:1;min-width:0;font:400 20px/19.5px 'Silkscreen',monospace;
  color:#A8FF45;font-synthesis:none;text-shadow:0 1px 2px #000,0 0 6px #A8FF4533;
}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogSummary::before,
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogSummary::after {
  content:'';grid-row:1;align-self:center;width:min(28px,100%);height:1px;pointer-events:none;
  background:linear-gradient(90deg,transparent,#A855F7);box-shadow:0 0 4px #A855F766;
}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogSummary::before {grid-column:1;justify-self:end;}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogSummary::after {grid-column:3;transform:rotate(180deg);}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogFarm {
  grid-column:1/-1;color:#F3F5E9;text-shadow:0 1px 2px #000;
}
/* Auto margins centre a short strip, but resolve to zero for a scrollable strip. */
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogThumbs>.catalog-thumb:first-child {margin-inline-start:auto;}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogThumbs>.catalog-thumb:last-child {margin-inline-end:auto;}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogThumbs>.catalog-thumb {
  background:#080B14CC;border-color:#A855F726;
}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #catalogThumbs>.catalog-thumb.is-active {
  border-color:#A8FF45;background:#112018CC;box-shadow:inset 0 0 3px #A8FF4533;
}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #menuBackBtn {
  position:relative;background:transparent;border:0;border-radius:0;box-shadow:none;
  color:#A8FF45;font-family:'DM Sans',Arial,sans-serif;font-weight:500;
  text-shadow:0 1px 2px #000,0 0 4px #A8FF4526;
}
html[data-game420-a] body.auth-entry[data-stage=menu] #screen3-container #menuBackBtn::after {
  content:'';position:absolute;left:4px;right:4px;bottom:8px;height:1px;pointer-events:none;
  background:linear-gradient(90deg,#A855F700,#A855F7,#A855F700);box-shadow:0 0 4px #A855F780;
}
html[data-game420-a] body.auth-entry #screen3-container .item-panel {padding:5px 6px 8px;scroll-padding:5px;}
html[data-game420-a] body.auth-entry #screen3-container .item-media {height:clamp(110px,50cqw,240px);}
html[data-game420-a] body.auth-entry #screen3-container .item-return {flex-basis:44px;min-height:44px;padding:0 6px;}
html[data-game420-a] body.auth-entry #screen2-container .links-page {padding:5px 6px 4px;}
html[data-game420-a] body.auth-entry #screen2-container #links-voyage {flex-basis:24px;min-height:24px;}
html[data-game420-a] body.auth-entry #screen2-container #links-voyage-telegram {flex-basis:32px;min-height:32px;}
@media(min-width:700px) {
  html[data-game420-a] .game420-viewport {max-width:min(660px,calc((100svh - 48px) * .695));}
}
