:root {
  color-scheme: dark;
  --bg: #000000;
  --text: #f4f7f4;
  --muted: #b8c3bd;
  --danger: #c44747;
  --danger-soft: #e16d66;
  --success: #62b77c;
  --success-soft: #9fd6ae;
  --glass: rgba(12, 18, 15, 0.56);
  --glass-line: rgba(184, 255, 205, 0.24);
  --matrix: #76f5a2;
  --video-width: 100vw;
  --video-height: 56.25vw;
  --screen-inline-pad: 18px;
}

@font-face {
  font-family: "MatrixCode";
  src: url("./vendor/cmatrix/Matrix-Code.ttf") format("truetype");
  font-display: swap;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-width: 320px;
  height: 100%;
  min-height: 100dvh;
  margin: 0;
  overflow: hidden;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

button,
input {
  font: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

.app {
  position: fixed;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  min-height: 100dvh;
  overflow: hidden;
  overflow-x: hidden;
  background: transparent;
}

.screen {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-block: max(24px, env(safe-area-inset-top)) max(24px, env(safe-area-inset-bottom));
  padding-inline: var(--screen-inline-pad);
  pointer-events: none;
  opacity: 0;
  transform: translate3d(0, 8px, 0);
  transition:
    opacity 760ms ease,
    transform 760ms ease,
    background-color 900ms ease,
    filter 900ms ease;
}

.screen.is-active {
  pointer-events: auto;
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

.screen > * {
  flex: 0 1 auto;
  margin-inline: auto;
}

.screen-frame {
  width: min(100%, 430px);
  max-width: calc(100vw - (var(--screen-inline-pad) * 2));
  margin-inline: auto;
  display: flex;
  justify-content: center;
  align-items: center;
}

.intro-screen .screen-frame {
  width: min(100%, 320px);
}

.intro-screen {
  background: var(--bg);
}

.pin-screen,
.sound-screen,
.final-screen {
  background: rgba(0, 0, 0, 0.06);
}

.final-screen {
  background: #000000;
}

.intro-trigger {
  position: relative;
  isolation: isolate;
  display: grid;
  width: 100%;
  min-height: 58px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(118, 245, 162, 0.42);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% -30%, rgba(118, 245, 162, 0.26), transparent 60%),
    linear-gradient(180deg, rgba(18, 58, 30, 0.92), rgba(3, 13, 7, 0.96));
  color: #ebfff1;
  cursor: pointer;
  padding: 13px 16px;
  font-size: clamp(14px, 4.1vw, 18px);
  font-weight: 820;
  letter-spacing: 0;
  line-height: 1.18;
  text-align: center;
  text-transform: uppercase;
  text-shadow: 0 0 12px rgba(159, 255, 186, 0.42);
  box-shadow:
    0 18px 42px rgba(0, 0, 0, 0.46),
    0 0 28px rgba(99, 217, 133, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transform: translateZ(0);
  transition:
    transform 160ms ease,
    border-color 240ms ease,
    filter 240ms ease;
}

.intro-trigger::before,
.intro-trigger::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  pointer-events: none;
}

.intro-trigger::before {
  background:
    repeating-linear-gradient(
      90deg,
      rgba(118, 245, 162, 0.12) 0,
      rgba(118, 245, 162, 0.12) 1px,
      transparent 1px,
      transparent 12px
    );
  opacity: 0.5;
}

.intro-trigger::after {
  background: linear-gradient(100deg, transparent 0%, rgba(190, 255, 205, 0.32) 48%, transparent 70%);
  transform: translateX(-115%);
  animation: matrixButtonSweep 3200ms ease-in-out infinite;
}

.intro-trigger:active {
  transform: scale(0.985);
  border-color: rgba(190, 255, 205, 0.56);
  filter: brightness(1.12);
}

.pin-panel,
.sound-panel,
.final-panel {
  width: min(100%, 360px);
  margin-inline: auto;
  display: grid;
  gap: 18px;
  justify-items: center;
}

.pin-label {
  color: var(--muted);
  font-size: 13px;
  text-transform: uppercase;
}

.pin-input {
  width: min(100%, 280px);
  height: 72px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  outline: 0;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  font-size: 32px;
  font-weight: 700;
  text-align: center;
  caret-color: var(--success-soft);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.24);
}

.pin-input::placeholder {
  color: rgba(255, 255, 255, 0.26);
}

.pin-input:focus {
  border-color: rgba(159, 214, 174, 0.72);
  box-shadow:
    0 0 0 4px rgba(98, 183, 124, 0.12),
    inset 0 0 0 1px rgba(0, 0, 0, 0.24);
}

.pin-error {
  min-height: 22px;
  margin: 0;
  color: var(--danger-soft);
  font-size: 14px;
}

.pin-panel.is-invalid {
  animation: shake 300ms ease;
}

.action-button {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  width: min(100%, 320px);
  min-height: 56px;
  border: 1px solid rgba(160, 244, 178, 0.28);
  border-radius: 8px;
  padding: 14px 18px;
  color: #effff1;
  font-weight: 750;
  text-shadow: 0 0 12px rgba(194, 255, 205, 0.34);
  cursor: pointer;
  touch-action: manipulation;
  box-shadow:
    0 16px 34px rgba(0, 0, 0, 0.38),
    0 0 26px rgba(118, 245, 162, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transition:
    transform 180ms ease,
    filter 180ms ease,
    box-shadow 180ms ease;
}

.action-button::before,
.action-button::after,
.video-fallback::before,
.video-fallback::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
}

.action-button::before,
.video-fallback::before {
  z-index: -2;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), transparent 42%),
    repeating-linear-gradient(
      90deg,
      rgba(210, 255, 218, 0.11) 0,
      rgba(210, 255, 218, 0.11) 1px,
      transparent 1px,
      transparent 9px
    ),
    repeating-linear-gradient(
      0deg,
      rgba(180, 230, 190, 0.1) 0,
      rgba(180, 230, 190, 0.1) 1px,
      transparent 1px,
      transparent 12px
    );
}

.action-button::after,
.video-fallback::after {
  z-index: -1;
  opacity: 0.18;
  background:
    linear-gradient(90deg, transparent, rgba(236, 255, 240, 0.55), transparent),
    linear-gradient(180deg, transparent 0%, rgba(255, 255, 255, 0.1) 48%, transparent 52%);
  transform: translateX(-112%);
  animation: matrixButtonSweep 2600ms ease-in-out infinite;
}

.action-button:active {
  transform: translateY(1px) scale(0.99);
  filter: brightness(0.96);
  box-shadow:
    0 10px 22px rgba(0, 0, 0, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.action-button--danger {
  background:
    radial-gradient(circle at 50% -20%, rgba(150, 255, 170, 0.28), transparent 58%),
    linear-gradient(180deg, rgba(17, 68, 33, 0.95), rgba(7, 24, 13, 0.97));
  border-color: rgba(255, 128, 128, 0.48);
  box-shadow:
    0 16px 34px rgba(0, 0, 0, 0.38),
    0 0 18px rgba(255, 112, 112, 0.18),
    0 0 28px rgba(99, 217, 133, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.action-button--success {
  background:
    radial-gradient(circle at 50% -20%, rgba(158, 255, 178, 0.34), transparent 58%),
    linear-gradient(180deg, rgba(22, 74, 38, 0.95), rgba(8, 29, 15, 0.96));
  color: #effff1;
  border-color: rgba(160, 244, 178, 0.48);
}

.action-button--file {
  background:
    radial-gradient(circle at 50% -20%, rgba(224, 255, 160, 0.36), transparent 58%),
    linear-gradient(180deg, rgba(50, 88, 28, 0.95), rgba(13, 35, 13, 0.96));
  color: #f6ffe9;
  border-color: rgba(218, 255, 154, 0.48);
}

.action-button--finish {
  background:
    radial-gradient(circle at 50% -20%, rgba(210, 230, 218, 0.24), transparent 58%),
    linear-gradient(180deg, rgba(49, 61, 56, 0.96), rgba(15, 20, 18, 0.97));
  color: #eef6f0;
  border-color: rgba(207, 229, 214, 0.32);
}

.sound-text {
  width: min(100%, 320px);
  margin: 0;
  color: #ff5d5d;
  font-size: 15px;
  font-weight: 760;
  line-height: 1.35;
  text-align: center;
  text-shadow: 0 0 12px rgba(255, 80, 80, 0.36);
  animation: blink 780ms steps(2, end) infinite;
}

.matrix-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  min-height: 100dvh;
  opacity: 0;
  pointer-events: none;
  background: #000000;
  transition:
    opacity 800ms ease,
    filter 800ms ease;
}

.matrix-canvas.is-active {
  opacity: 1;
  filter: contrast(1.34) brightness(1.48) saturate(1.18);
}

.matrix-canvas.is-shutdown-hidden {
  opacity: 0 !important;
  filter: none !important;
  transition: none !important;
}

.loading-screen,
.chat-screen {
  z-index: 1;
  background: rgba(0, 0, 0, 0.04);
}

.chat-screen.is-shutdown-hidden {
  opacity: 0 !important;
  filter: brightness(0) !important;
  pointer-events: none !important;
  transition: none !important;
}

.glass-modal {
  position: relative;
  width: 100%;
  overflow: hidden;
  border: 1px solid var(--glass-line);
  border-radius: 8px;
  background: var(--glass);
  box-shadow:
    0 30px 70px rgba(0, 0, 0, 0.48),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(18px);
}

.glass-modal::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(118, 245, 162, 0.045) 1px, transparent 1px);
  background-size: 100% 18px, 24px 100%;
  opacity: 0.52;
}

.loading-modal {
  display: grid;
  gap: 14px;
  padding: 28px 22px 24px;
}

.loading-modal.is-complete {
  border-color: rgba(118, 245, 162, 0.5);
  box-shadow:
    0 30px 70px rgba(0, 0, 0, 0.48),
    0 0 30px rgba(99, 217, 133, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.loading-modal h1 {
  position: relative;
  z-index: 1;
  margin: 0;
  color: #ebfff1;
  font-size: 20px;
  line-height: 1.25;
  text-align: center;
}

.progress-track {
  position: relative;
  z-index: 1;
  height: 12px;
  overflow: hidden;
  border: 1px solid rgba(118, 245, 162, 0.32);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.46);
}

.progress-fill {
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #33b962, #63d985, #9bf2ad);
  box-shadow: 0 0 18px rgba(99, 217, 133, 0.48);
  transition: width 120ms linear;
}

.progress-text,
.load-error {
  position: relative;
  z-index: 1;
  min-height: 20px;
  margin: 0;
  color: rgba(235, 255, 241, 0.72);
  font-size: 14px;
  text-align: center;
}

.load-error {
  color: var(--danger-soft);
}

.video-screen {
  z-index: 2;
  overflow: hidden;
  background: #ffffff;
}

.video-screen.is-whiteout,
.video-shell,
.video-screen.is-whiteout .main-video {
  background: #ffffff;
}

.video-screen.is-ending {
  background: #ffffff;
  filter: brightness(1);
}

.video-shell {
  width: 10px;
  height: 10px;
  overflow: hidden;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.34);
  transform: translate3d(0, 0, 0) rotate(0);
  transition:
    width 1000ms cubic-bezier(0.16, 1, 0.3, 1),
    height 1000ms cubic-bezier(0.16, 1, 0.3, 1),
    transform 950ms cubic-bezier(0.7, 0, 0.84, 0),
    opacity 760ms ease,
    border-radius 1000ms ease;
}

.video-screen.is-open .video-shell {
  width: var(--video-width);
  height: var(--video-height);
  border-radius: 0;
}

.video-screen.is-ending .video-shell {
  width: 10px;
  height: 10px;
  opacity: 0;
  transform: translate3d(0, 44vh, 0) rotate(8deg);
}

.main-video {
  display: block;
  width: 100%;
  height: 100%;
  background: #ffffff;
  object-fit: contain;
  object-position: center;
}

.video-fallback {
  position: fixed;
  left: 50%;
  bottom: max(28px, env(safe-area-inset-bottom));
  z-index: 4;
  isolation: isolate;
  overflow: hidden;
  width: min(calc(100vw - 36px), 320px);
  min-height: 54px;
  border: 1px solid rgba(160, 244, 178, 0.38);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% -20%, rgba(158, 255, 178, 0.3), transparent 58%),
    linear-gradient(180deg, rgba(22, 74, 38, 0.96), rgba(8, 29, 15, 0.97));
  color: #effff1;
  font-weight: 760;
  text-shadow: 0 0 12px rgba(194, 255, 205, 0.34);
  transform: translateX(-50%);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.36);
}

.chat-modal {
  position: relative;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  height: 100%;
  max-height: none;
  min-height: 0;
  padding: 0;
  opacity: 0;
  pointer-events: none;
  transform: translate3d(0, 14px, 0) scale(0.985);
  transition:
    opacity 620ms ease,
    transform 620ms cubic-bezier(0.16, 1, 0.3, 1);
}

.chat-stage {
  display: grid;
  grid-template-rows: auto minmax(238px, 1fr);
  align-content: center;
  gap: 10px;
  width: min(100%, 430px);
  max-height: calc(100dvh - 36px);
}

.chat-screen.is-messenger-open .chat-modal {
  opacity: 1;
  pointer-events: auto;
  transform: translate3d(0, 0, 0) scale(1);
}

.chat-intro {
  position: relative;
  z-index: 1;
  display: grid;
  overflow: hidden;
  border: 1px solid var(--glass-line);
  border-radius: 8px;
  background: rgba(6, 18, 10, 0.72);
  box-shadow:
    0 20px 52px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
}

.chat-intro-avatar {
  display: block;
  width: 48px;
  height: 48px;
  margin: 8px auto 10px;
  border: 1px solid rgba(99, 217, 133, 0.44);
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  background: rgba(0, 0, 0, 0.55);
  box-shadow:
    0 0 18px rgba(99, 217, 133, 0.24),
    0 0 26px rgba(255, 80, 80, 0.12);
}

.chat-threat {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 8px;
  justify-items: center;
  padding: 12px 18px 10px;
  border-bottom: 1px solid rgba(118, 245, 162, 0.18);
  background:
    linear-gradient(180deg, rgba(5, 26, 12, 0.76), rgba(0, 0, 0, 0.42)),
    repeating-linear-gradient(
      90deg,
      rgba(99, 217, 133, 0.08) 0,
      rgba(99, 217, 133, 0.08) 1px,
      transparent 1px,
      transparent 18px
    );
}

.chat-threat p {
  margin: 0;
  color: #ff6b6b;
  font-size: 15px;
  font-weight: 850;
  line-height: 1.18;
  text-align: center;
  text-shadow:
    0 0 10px rgba(255, 80, 80, 0.38),
    0 0 18px rgba(99, 217, 133, 0.12);
}

.chat-threat-logo {
  display: block;
  width: 64px;
  height: 64px;
  object-fit: contain;
  filter:
    drop-shadow(0 0 10px rgba(99, 217, 133, 0.35))
    drop-shadow(0 0 14px rgba(255, 80, 80, 0.18));
}

.agent-smith-frame {
  position: relative;
  z-index: 1;
  width: 100%;
  height: clamp(112px, 27dvh, 180px);
  overflow: hidden;
  border-bottom: 1px solid rgba(118, 245, 162, 0.18);
  background: rgba(0, 0, 0, 0.48);
}

.agent-smith-gif {
  display: block;
  width: 100%;
  height: 100%;
  margin-inline: auto;
  object-fit: cover;
  object-position: center;
}

.chat-header {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 7px;
  padding: 18px 18px 14px;
  border-bottom: 1px solid rgba(118, 245, 162, 0.18);
}

.chat-header p,
.chat-header span {
  margin: 0;
}

.chat-header p {
  color: #e9fff0;
  font-size: 18px;
  font-weight: 760;
  line-height: 1.2;
}

.chat-header strong {
  color: #ff7474;
  font-size: 16px;
  animation: blink 780ms steps(2, end) infinite;
}

.chat-header span {
  color: rgba(235, 255, 241, 0.68);
  font-size: 14px;
}

.intrusion-alert {
  position: absolute;
  left: 16px;
  right: 16px;
  top: 50%;
  z-index: 8;
  display: grid;
  gap: 5px;
  justify-items: center;
  padding: 16px 14px;
  border: 1px solid rgba(255, 213, 92, 0.72);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(70, 47, 5, 0.94), rgba(25, 18, 3, 0.96)),
    repeating-linear-gradient(
      90deg,
      rgba(255, 213, 92, 0.16) 0,
      rgba(255, 213, 92, 0.16) 1px,
      transparent 1px,
      transparent 12px
    );
  box-shadow:
    0 22px 52px rgba(0, 0, 0, 0.54),
    0 0 24px rgba(255, 213, 92, 0.22);
  color: #ffe68a;
  text-align: center;
  transform: translateY(-50%);
  animation: alertPulse 900ms ease-in-out infinite;
}

.intrusion-alert-icon {
  position: relative;
  width: 0;
  height: 0;
  border-right: 18px solid transparent;
  border-bottom: 32px solid #ffd85c;
  border-left: 18px solid transparent;
  filter: drop-shadow(0 0 10px rgba(255, 216, 92, 0.52));
}

.intrusion-alert-icon::after {
  position: absolute;
  top: 8px;
  left: -3px;
  color: #2e2100;
  content: "!";
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
}

.intrusion-alert strong {
  color: #fff0a8;
  font-size: 22px;
  line-height: 1;
  text-transform: uppercase;
}

.intrusion-alert span,
.intrusion-alert small {
  font-size: 15px;
  line-height: 1.25;
}

.intrusion-alert small {
  color: rgba(255, 236, 166, 0.78);
  font-size: 13px;
}

.chat-log {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
  overflow: auto;
  padding: 16px;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.44)),
    repeating-linear-gradient(
      0deg,
      rgba(118, 245, 162, 0.06) 0,
      rgba(118, 245, 162, 0.06) 1px,
      transparent 1px,
      transparent 11px
    );
  scrollbar-width: thin;
  scrollbar-color: rgba(99, 217, 133, 0.45) rgba(0, 0, 0, 0.2);
}

.chat-line {
  width: 100%;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: end;
  column-gap: 8px;
  animation: messageIn 360ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.chat-line.is-removing {
  opacity: 0;
  transform: translateY(-6px);
  transition:
    opacity 420ms ease,
    transform 420ms ease;
}

.chat-line--system,
.chat-line--status {
  display: flex;
  justify-content: center;
}

.chat-avatar {
  width: 32px;
  height: 32px;
  border: 1px solid rgba(99, 217, 133, 0.42);
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  background: rgba(0, 0, 0, 0.55);
  box-shadow: 0 0 14px rgba(99, 217, 133, 0.18);
}

.chat-message-stack {
  display: grid;
  justify-items: start;
  min-width: 0;
}

.chat-name {
  margin: 0 0 4px;
  color: rgba(210, 255, 222, 0.68);
  font-size: 11px;
  font-weight: 750;
  line-height: 1;
}

.chat-bubble {
  width: fit-content;
  max-width: 100%;
  min-height: 40px;
  border: 1px solid rgba(99, 217, 133, 0.34);
  border-radius: 8px 8px 8px 3px;
  padding: 9px 11px;
  color: #effff1;
  background: rgba(5, 24, 12, 0.78);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.24),
    0 8px 20px rgba(0, 0, 0, 0.22);
  line-height: 1.32;
  overflow-wrap: anywhere;
  transform-origin: left bottom;
}

.chat-line--system .chat-bubble,
.chat-line--status .chat-bubble {
  max-width: min(78%, 300px);
  min-height: 34px;
  border-radius: 8px;
  text-align: center;
}

.chat-line--system .chat-bubble {
  border-color: rgba(190, 220, 200, 0.2);
  color: rgba(235, 255, 241, 0.74);
  background: rgba(255, 255, 255, 0.045);
}

.chat-line--status .chat-bubble {
  border-color: rgba(99, 217, 133, 0.22);
  color: rgba(235, 255, 241, 0.62);
  background: rgba(5, 16, 9, 0.64);
  font-size: 14px;
}

.chat-time {
  min-width: 38px;
  padding-bottom: 5px;
  color: rgba(235, 255, 241, 0.5);
  font-size: 11px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.chat-caret::after {
  content: "";
  display: inline-block;
  width: 8px;
  height: 1em;
  margin-left: 3px;
  vertical-align: -0.16em;
  background: rgba(235, 255, 241, 0.72);
  animation: caretBlink 780ms steps(2, end) infinite;
}

.chat-actions {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 14px 16px 16px;
  border-top: 1px solid rgba(118, 245, 162, 0.14);
  background: rgba(0, 0, 0, 0.2);
}

.final-panel {
  gap: 12px;
  text-align: center;
}

.final-panel h1 {
  margin: 0;
  color: #ff4f4f;
  font-size: 24px;
  font-weight: 900;
  line-height: 1.15;
  text-shadow:
    0 0 10px rgba(255, 50, 50, 0.52),
    0 0 22px rgba(255, 50, 50, 0.22);
  animation: finalBlink 900ms steps(2, end) infinite;
}

.final-panel p {
  margin: 0;
  color: rgba(255, 255, 255, 0.68);
}

.countdown {
  color: #ff7474;
  font-variant-numeric: tabular-nums;
  font-size: 36px;
  font-weight: 820;
}

.shutdown-overlay {
  position: fixed;
  inset: 0;
  z-index: 99;
  pointer-events: none;
  opacity: 0;
  background: #000000;
  transform: scaleY(1);
}

.shutdown-overlay.is-visible {
  opacity: 1;
}

.shutdown-overlay.is-running {
  background:
    radial-gradient(ellipse at center, rgba(118, 245, 162, 0.94) 0%, rgba(118, 245, 162, 0.68) 5%, transparent 7%),
    linear-gradient(180deg, transparent 0%, rgba(118, 245, 162, 0.22) 48%, rgba(118, 245, 162, 0.72) 50%, rgba(118, 245, 162, 0.22) 52%, transparent 100%),
    #000000;
  animation: crtShutdown 820ms cubic-bezier(0.7, 0, 0.84, 0) both;
}

[hidden] {
  display: none !important;
}

@keyframes blink {
  0%,
  44% {
    opacity: 1;
  }

  45%,
  100% {
    opacity: 0.24;
  }
}

@keyframes finalBlink {
  0%,
  44% {
    opacity: 1;
  }

  45%,
  100% {
    opacity: 0.28;
  }
}

@keyframes alertPulse {
  0%,
  100% {
    filter: brightness(1);
  }

  50% {
    filter: brightness(1.22);
  }
}

@keyframes messageIn {
  0% {
    opacity: 0;
    transform: translate3d(-10px, 8px, 0) scale(0.98);
  }

  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

@keyframes crtShutdown {
  0% {
    opacity: 1;
    transform: scaleY(1);
    filter: brightness(0.7);
  }

  18% {
    opacity: 1;
    transform: scaleY(1);
    filter: brightness(1.35);
  }

  58% {
    opacity: 1;
    transform: scaleY(0.025);
    filter: brightness(1.9);
  }

  82% {
    opacity: 1;
    transform: scaleY(0.003);
    filter: brightness(2.4);
  }

  100% {
    opacity: 0;
    transform: scaleY(0);
    filter: brightness(0);
  }
}

@keyframes caretBlink {
  0%,
  48% {
    opacity: 1;
  }

  49%,
  100% {
    opacity: 0;
  }
}

@keyframes shake {
  0%,
  100% {
    transform: translateX(0);
  }

  25% {
    transform: translateX(-8px);
  }

  75% {
    transform: translateX(8px);
  }
}

@keyframes matrixButtonSweep {
  0%,
  42% {
    transform: translateX(-112%);
  }

  72%,
  100% {
    transform: translateX(112%);
  }
}

@media (min-width: 740px) {
  .screen {
    padding: 32px;
  }

  .loading-modal h1 {
    font-size: 22px;
  }

  .chat-header p {
    font-size: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}
