@charset "UTF-8";
@import url("https://fonts.googleapis.com/css2?family=Orbitron:wght@400;500&display=swap");

:root {
  --gate-bg: #050505;
  --gate-text: #f6faf7;
  --gate-text-soft: rgba(255, 255, 255, 0.82);
  --gate-line: rgba(255, 255, 255, 0.14);
  --gate-panel: rgba(255, 255, 255, 0.06);
  --gate-danger: rgba(255, 110, 122, 0.14);
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

body {
  margin: 0;
  font-family: "Yu Gothic", "YuGothic", "Hiragino Kaku Gothic ProN", Meiryo, system-ui, sans-serif;
  background: var(--gate-bg);
  color: var(--gate-text);
}

a {
  color: inherit;
  text-decoration: none;
}

.btn,
.input {
  font: inherit;
}

.input {
  width: 100%;
  padding: 0.42rem 0.68rem;
  border: 1px solid var(--gate-line);
  background: transparent;
  color: #ffffff;
  font-size: 0.74rem;
  line-height: 1.2;
  outline: none;
}

.input::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.input:focus {
  border-color: rgba(255, 255, 255, 0.32);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.16);
}

.gateScreen__input--error {
  border-color: rgba(255, 95, 109, 0.9);
  box-shadow: 0 0 0 1px rgba(255, 95, 109, 0.28);
}

.label {
  display: block;
  margin-bottom: 5px;
  font-size: 0.74rem;
  color: rgba(255, 255, 255, 0.78);
}

.field {
  margin-bottom: 6px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  padding: 0.38rem 0.56rem;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: transparent;
  color: #ffffff;
  font-size: 0.68rem;
  font-weight: 600;
  cursor: pointer;
}

.btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.gateBody {
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  background: var(--gate-bg);
}

.gateScreen {
  width: 100%;
  height: 100vh;
  height: 100dvh;
  display: grid;
  place-items: center;
  padding: 0;
}

.gateScreen__frame {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  background: var(--gate-bg);
  isolation: isolate;
}

.gateScreen__videoWrap,
.gateScreen__shade,
.gateScreen__video {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.gateScreen__videoWrap {
  z-index: 0;
}

.gateScreen__fallback {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(10px, 2.2vw, 22px);
  padding: 24px;
  background:
    radial-gradient(circle at 50% 44%, rgba(126, 255, 130, 0.12), transparent 24%),
    radial-gradient(circle at 50% 50%, rgba(204, 255, 126, 0.08), transparent 32%),
    #050505;
  color: #f5f8d8;
  text-align: center;
  pointer-events: none;
  opacity: 1;
  transition: opacity 220ms ease;
}

.gateScreen__frame--video-ready .gateScreen__fallback {
  opacity: 0;
}

.gateScreen__frame--static .gateScreen__videoWrap {
  display: none;
}

.gateScreen__frame--static .gateScreen__fallback {
  opacity: 1;
  background:
    radial-gradient(circle at 50% 52%, rgba(126, 255, 130, 0.14), transparent 23%),
    radial-gradient(circle at 50% 52%, rgba(204, 255, 126, 0.09), transparent 31%),
    #050505;
}

.gateScreen__fallbackEyebrow {
  margin: 0;
  font-size: clamp(0.9rem, 2vw, 1.5rem);
  font-family: "Orbitron", "Segoe UI", system-ui, sans-serif;
  font-weight: 400;
  letter-spacing: 0.42em;
  color: rgba(236, 239, 171, 0.88);
  text-transform: uppercase;
  text-shadow: 0 0 18px rgba(231, 234, 145, 0.38);
}

.gateScreen__fallbackLogo {
  width: min(980px, 86vw);
  height: auto;
  filter: drop-shadow(0 0 22px rgba(100, 255, 110, 0.2)) drop-shadow(0 0 44px rgba(100, 255, 110, 0.12));
}

.gateScreen__content {
  position: absolute;
  inset: 0;
  z-index: 10;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.gateScreen__content > * {
  pointer-events: auto;
}

.gateScreen__video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center 34%;
  background: var(--gate-bg);
  opacity: 0;
  transition: opacity 220ms ease;
}

.gateScreen__frame--video-ready .gateScreen__video {
  opacity: 1;
}

.gateScreen__shade {
  background: transparent;
}

.gateScreen__content {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  padding: clamp(20px, 4vw, 40px);
  color: var(--gate-text);
}

.gateScreen__loginForm {
  position: relative;
  z-index: 3;
  width: min(180px, calc(100vw - 40px));
  margin: 0 auto;
  padding: 0;
  pointer-events: auto;
}

.gateScreen__loginForm--error {
  animation: gateShake 180ms ease-out 1;
}

.gateScreen__actions {
  margin-top: 12px;
  display: flex;
  justify-content: center;
  position: relative;
  z-index: 3;
  pointer-events: auto;
}

.gateScreen__loginBtn {
  width: auto;
  pointer-events: auto;
  touch-action: manipulation;
}

.adminGate__content {
  justify-content: flex-end;
}

.adminGate__content--locked {
  justify-content: flex-end;
  padding-bottom: clamp(56px, 12vh, 112px);
}

.adminGate__stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
}

.adminGate__cta {
  min-width: 140px;
  padding: 0.52rem 1.1rem;
  font-size: 0.76rem;
  letter-spacing: 0.06em;
}

.adminGate__cta--error {
  border-color: rgba(255, 95, 109, 0.9);
  box-shadow: 0 0 0 1px rgba(255, 95, 109, 0.28);
}

.adminGate__label {
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
}

.adminGate__panel {
  display: none;
}

.adminGate__panel--visible {
  display: block;
}

.adminGate__homeLink {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.adminGate__homeLink:hover {
  color: #ffffff;
}

@media (max-width: 720px) {
  .gateScreen__fallback {
    justify-content: center;
    gap: 14px;
    padding: 20px 16px 32px;
  }

  .gateScreen__frame--static .gateScreen__fallback {
    animation: gateLogoFade 2.6s ease-in-out infinite alternate;
    background:
      radial-gradient(circle at 50% 51%, rgba(126, 255, 130, 0.16), transparent 24%),
      radial-gradient(circle at 50% 51%, rgba(204, 255, 126, 0.1), transparent 32%),
      #050505;
  }

  .gateScreen__fallbackEyebrow {
    margin-bottom: 4px;
    font-size: clamp(0.76rem, 3.6vw, 1rem);
    letter-spacing: 0.24em;
  }

  .gateScreen__fallbackLogo {
    width: min(92vw, 520px);
  }

  .gateScreen__content {
    padding: 20px 16px 20px;
  }

  .gateScreen__actions {
    margin-top: 16px;
  }

  .gateScreen__loginForm {
    width: min(180px, calc(100vw - 40px));
  }

  .adminGate__cta {
    min-width: 132px;
  }
}

@keyframes gateLogoFade {
  from {
    opacity: 0.72;
  }
  to {
    opacity: 1;
  }
}

@keyframes gateShake {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-3px);
  }
  75% {
    transform: translateX(3px);
  }
}
