/* Somente abertura. Não altera tamanho/layout de html, body ou canvas do jogo. */
@font-face{font-family:"R420 Intro";src:url("assets/SuperstudioLLTrialWeb-Bold.woff2") format("woff2");font-display:swap;font-weight:100 900}
#bootScreen,#bootScreen *,#ageGate,#ageGate *{box-sizing:border-box;font-synthesis:none}
#bootScreen{font-family:"R420 Intro",monospace;color:#00ff41}
#bootScreen button,#bootScreen input{font:inherit}
#bootScreen[hidden],#bootScreen [hidden],#ageGate[hidden],#ageGate [hidden]{display:none!important}
    #ageGate {
      position: fixed;
      inset: 0;
      z-index: 1200;
      display: grid;
      place-items: center;
      padding: 12px;
      background: #000;
      color: #000;
      font-family: monospace;
      image-rendering: pixelated;
    }
    #ageGate[hidden] { display: none !important; }
    #ageGateContent {
      position: relative;
      width: min(320px, calc(100vw - 24px));
      min-height: 200px;
      display: grid;
      grid-template-columns: minmax(0, 1fr);
      grid-template-rows: 25px 1fr 53px;
      padding: 3px;
      background: transparent;
      border: 2px solid;
      border-color: transparent;
      box-shadow: none;
      transform-origin: center;
      animation: age-gate-window-in 300ms cubic-bezier(.18,.82,.24,1.08) 1180ms both;
    }
    @keyframes age-gate-window-in {
      from { background: transparent; border-color: transparent; box-shadow: none; transform: translateY(8px) scale(.94); }
      to { background: #c0c0c0; border-color: #fff #404040 #404040 #fff; box-shadow: 2px 2px 0 #808080; transform: translateY(0) scale(1); }
    }
    #ageGateTitle {
      position: relative;
      grid-row: 1;
      grid-column: 1;
      justify-self: stretch;
      align-self: stretch;
      height: 25px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      min-width: 0;
      width: 100%;
      box-sizing: border-box;
      margin-inline: 0;
      padding: 2px 3px 2px 7px;
      background: linear-gradient(90deg, #000080, #1084d0);
      color: #fff;
      font: bold 12px/1 monospace;
      letter-spacing: -.035em;
      text-shadow: 1px 1px #000;
      clip-path: inset(0 100% 0 0);
      -webkit-clip-path: inset(0 100% 0 0);
      animation: age-gate-title-reveal 280ms steps(16, end) 1180ms both;
    }
    @keyframes age-gate-title-reveal {
      from { clip-path: inset(0 100% 0 0); -webkit-clip-path: inset(0 100% 0 0); }
      to { clip-path: inset(0); -webkit-clip-path: inset(0); }
    }
    #ageGateMessage {
      grid-row: 2;
      display: grid;
      grid-template-columns: 110px 1fr;
      align-items: center;
      gap: 10px;
      padding: 12px 17px 4px;
    }
    #ageGateIcon {
      width: 120px;
      height: 60px;
      object-fit: contain;
      image-rendering: pixelated;
      filter: contrast(1.12);
      transform: translateX(-8px);
      opacity: 0;
      animation: age-gate-icon-in 110ms steps(4, end) 1650ms both;
    }
    @keyframes age-gate-icon-in { from { opacity: 0; } to { opacity: 1; } }
    #ageGateQuestion {
      margin: 0;
      font: bold 13px/1.35 monospace;
      letter-spacing: -.055em;
      clip-path: inset(0 100% 0 0);
      animation: age-gate-question-type 350ms steps(19, end) 1650ms both;
    }
    @keyframes age-gate-question-type {
      from { clip-path: inset(0 100% 0 0); }
      to { clip-path: inset(0); }
    }
    #ageGateChoices { grid-row: 3; display: flex; align-items: center; justify-content: center; gap: 18px; padding: 0 0 4px; }
    #ageGateChoices button {
      min-width: 74px;
      min-height: 38px;
      padding: 5px 12px;
      border: 2px solid;
      border-color: #fff #404040 #404040 #fff;
      border-radius: 0;
      background: #c0c0c0;
      color: #000;
      font: bold 13px/1 monospace;
      letter-spacing: -.04em;
      cursor: pointer;
      opacity: 0;
      transform: translateY(4px);
      animation: age-gate-button-in 150ms steps(5, end) 1400ms both;
    }
    #ageGateChoices button:nth-child(2) { animation-delay: 1470ms; }
    @keyframes age-gate-button-in {
      from { opacity: 0; transform: translateY(4px); }
      to { opacity: 1; transform: translateY(0); }
    }
    #ageGateChoices button:hover { background: #d4d4d4; }
    #ageGateChoices button:active { border-color: #404040 #fff #fff #404040; padding: 6px 11px 4px 13px; }
    #ageGateChoices button:focus-visible { outline: 1px dotted #000; outline-offset: -6px; }
    @media (max-width: 360px) {
      #ageGateContent { min-height: 190px; }
      #ageGateMessage { grid-template-columns: 96px 1fr; padding-inline: 11px; gap: 7px; }
      #ageGateIcon { width: 102px; height: 51px; transform: translateX(-6px); }
      #ageGateQuestion { font-size: 12px; }
    }
    @media (prefers-reduced-motion: reduce) {
      #ageGateContent,
      #ageGateTitle,
      #ageGateIcon,
      #ageGateQuestion,
      #ageGateChoices button {
        animation: none;
        opacity: 1;
        clip-path: none;
      }
      #ageGateTitle {
        clip-path: inset(0 100% 0 0);
        -webkit-clip-path: inset(0 100% 0 0);
        animation: age-gate-title-reveal 1ms steps(1, end) 1180ms both;
      }
      #ageGateContent,
      #ageGateChoices button { transform: none; }
      #ageGateContent { background: #c0c0c0; border-color: #fff #404040 #404040 #fff; box-shadow: 2px 2px 0 #808080; }
    }

body.r420-opening-active #gameFrame{--screen-pixel:2px}
#bootScreen{position:absolute;inset:0;background:#000;overflow:hidden;isolation:isolate}
#crtStage{position:absolute;background:#000;overflow:visible;isolation:isolate}
#crtCanvas{position:absolute;z-index:1;inset:0;display:block;image-rendering:pixelated;image-rendering:crisp-edges;filter:brightness(.82) drop-shadow(-1px 0 0 #ac63792c) drop-shadow(1px 0 0 #789da934) drop-shadow(0 0 2px #c0a7de38)}
#crtStage::before{display:none}
/* Black backdrop on screens 2/3, like the age gate. Dark scanlines retain
   the lettering's CRT finish without adding grain or colored background ink. */
#crtGlass{position:absolute;inset:0;z-index:4;pointer-events:none;overflow:hidden;background:transparent}
#crtGlass::before{content:"";position:absolute;inset:0;background:repeating-linear-gradient(0deg,#00000059 0 .55px,transparent .55px 2px);opacity:.82}
#crtGlass::after{display:none}
#crtStage{animation:crt-phosphor 6.3s steps(1,end) infinite}
@keyframes crt-phosphor{0%,37%,100%{opacity:.995}11%{opacity:.983}63%{opacity:1}76%{opacity:.989}}
#bootScreen.is-screen-warming #crtStage{animation:crt-surface-in var(--boot-frame-draw-duration,1500ms) linear both}
@keyframes crt-surface-in{0%{opacity:0}16%{opacity:.24}33%{opacity:.63}42%{opacity:.52}68%{opacity:.88}100%{opacity:1}}
#bootPanel{position:absolute;inset:0;z-index:2;pointer-events:none}
#bootBrand,#bootText{display:none}
#bootInfo,#bootPasswordForm.is-visible{position:absolute;inset:0;pointer-events:none}
#bootPasswordForm{display:none}#bootPasswordForm.is-visible{display:block}
#bootHint,#bootPasswordForm input,#bootPasswordForm button{position:absolute;display:block;margin:0;padding:0;border:0;border-radius:0;background:transparent;box-shadow:none;color:transparent;outline:0;opacity:.01;pointer-events:auto}
#bootHint,#bootPasswordForm button{cursor:pointer}
#bootPasswordForm input{font-size:16px;caret-color:transparent;letter-spacing:0;min-width:0}
#bootHint:focus-visible,#bootPasswordForm button:focus-visible,#bootPasswordForm input:focus{outline:0}
#bootPasswordForm label,#bootPasswordError,#bootLoading{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);clip-path:inset(50%);white-space:nowrap;border:0}
#readyArt,#enterArt{display:none}
@media(prefers-reduced-motion:reduce){#bootScreen,#bootScreen *,#bootScreen *::before,#bootScreen *::after,#crtStage::before,#crtGlass::before,#crtGlass::after,#ageGate,#ageGate *,#ageGate *::before,#ageGate *::after{animation:none!important;transition:none!important}}

#bootFrameTrace{display:none;position:absolute;inset:0;z-index:7;pointer-events:none}
#bootScreen.is-frame-drawing #bootFrameTrace{display:block}
#bootFrameTrace svg{display:block;width:100%;height:100%;overflow:visible}
#bootFrameTrace path{fill:none;stroke:var(--frame-ink);stroke-width:1;stroke-linecap:square;vector-effect:non-scaling-stroke;stroke-dasharray:1;stroke-dashoffset:1}
#bootScreen.is-frame-drawing #bootFrameTrace path{animation:boot-frame-trace var(--boot-frame-draw-duration,1500ms) linear both}
@keyframes boot-frame-trace{to{stroke-dashoffset:0}}
@media(prefers-reduced-motion:reduce){#bootFrameTrace path{stroke-dashoffset:0}}

body.r420-opening-active,body.r420-opening-active *{cursor:url("assets/cursor-pedra-24x36.png") 2 0,default!important}

#bootScreen.is-finishing #crtGlass{opacity:0}
#bootScreen.is-finishing #crtStage{background:#000;animation:none}
