:root {
  --ink: #f4ffff;
  --muted: rgba(218, 252, 252, 0.72);
  --dim: rgba(218, 252, 252, 0.48);
  --black: #050707;
  --wall: #102225;
  --cyan: #17f8f1;
  --cyan-soft: #7dfffb;
  --rose: #ff426f;
  --amber: #ffc35a;
  --line: rgba(159, 255, 251, 0.18);
  --panel: rgba(5, 14, 15, 0.72);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
}

@font-face {
  font-family: "Hasenbar Inter";
  src: url("../fonts/inter-variable.ttf") format("truetype");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Hasenbar Space Grotesk";
  src: url("../fonts/space-grotesk-variable.ttf") format("truetype");
  font-weight: 500 700;
  font-style: normal;
  font-display: swap;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background:
    radial-gradient(circle at 18% 10%, rgba(23, 248, 241, 0.18), transparent 28rem),
    radial-gradient(circle at 87% 26%, rgba(255, 66, 111, 0.13), transparent 24rem),
    linear-gradient(135deg, #050707 0%, #071214 45%, #10090d 100%);
  font-family: "Hasenbar Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  overflow-x: hidden;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 74px 74px;
  mask-image: linear-gradient(to bottom, black, transparent 84%);
}

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

button,
input {
  font: inherit;
}

.grain-field {
  position: fixed;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  opacity: 0.23;
  mix-blend-mode: screen;
  pointer-events: none;
}

.ambient {
  position: fixed;
  z-index: -2;
  pointer-events: none;
  filter: blur(18px);
  opacity: 0.8;
}

.ambient-a {
  top: 12vh;
  left: -12vw;
  width: 42vw;
  height: 42vw;
  background: radial-gradient(circle, rgba(23, 248, 241, 0.18), transparent 62%);
}

.ambient-b {
  right: -10vw;
  bottom: 2vh;
  width: 34vw;
  height: 34vw;
  background: radial-gradient(circle, rgba(255, 195, 90, 0.12), transparent 64%);
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(18px, 4vw, 56px);
  background: linear-gradient(to bottom, rgba(5, 7, 7, 0.76), rgba(5, 7, 7, 0));
}

.brand,
.nav {
  display: flex;
  align-items: center;
}

.brand {
  gap: 12px;
  color: var(--ink);
  font-family: "Hasenbar Space Grotesk", "Hasenbar Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 700;
  letter-spacing: 0;
}

.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid rgba(125, 255, 251, 0.55);
  border-radius: 50%;
  color: var(--cyan-soft);
  text-shadow: 0 0 14px var(--cyan);
  box-shadow: 0 0 28px rgba(23, 248, 241, 0.18), inset 0 0 18px rgba(23, 248, 241, 0.13);
}

.nav {
  gap: clamp(14px, 3vw, 34px);
  color: var(--muted);
  font-size: clamp(0.72rem, 1.15vw, 0.86rem);
  font-weight: 700;
  text-transform: uppercase;
}

.nav a {
  transition: color 180ms ease, text-shadow 180ms ease;
}

.nav a:hover {
  color: var(--cyan-soft);
  text-shadow: 0 0 18px rgba(23, 248, 241, 0.72);
}

.hero {
  position: relative;
  display: grid;
  min-height: 96svh;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
  padding: 92px clamp(18px, 4vw, 56px) 56px;
}

.hero-visual {
  min-width: 0;
}

.wall {
  position: relative;
  isolation: isolate;
  min-height: clamp(360px, 54vw, 660px);
  border: 1px solid rgba(125, 255, 251, 0.14);
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.02), transparent 30%, rgba(255, 255, 255, 0.035)),
    radial-gradient(circle at 52% 42%, rgba(23, 248, 241, 0.24), transparent 28rem),
    linear-gradient(165deg, #102c30 0%, #0c1719 50%, #13090c 100%);
  box-shadow: var(--shadow), inset 0 0 90px rgba(23, 248, 241, 0.08);
  animation: wall-hum 7s ease-in-out infinite;
}

.wall::before,
.wall::after {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
}

.wall::before {
  background-image:
    linear-gradient(92deg, transparent 0 48%, rgba(255, 255, 255, 0.05) 49%, transparent 51%),
    linear-gradient(0deg, transparent 0 45%, rgba(255, 255, 255, 0.035) 46%, transparent 47%),
    radial-gradient(circle at 20% 28%, rgba(255, 255, 255, 0.08) 0 1px, transparent 2px),
    radial-gradient(circle at 68% 44%, rgba(255, 255, 255, 0.08) 0 1px, transparent 2px);
  background-size: 100% 100%, 100% 100%, 82px 82px, 114px 114px;
  opacity: 0.62;
}

.wall::after {
  z-index: 1;
  background:
    linear-gradient(
      to bottom,
      transparent 0%,
      rgba(125, 255, 251, 0.08) 43%,
      transparent 46%,
      rgba(0, 0, 0, 0.56) 100%
    ),
    repeating-linear-gradient(
      to bottom,
      rgba(255, 255, 255, 0.035) 0 1px,
      transparent 1px 7px
    );
  mix-blend-mode: screen;
  opacity: 0.34;
  animation: scanline-drift 5.4s linear infinite;
}

.neon-sign {
  position: absolute;
  top: 17%;
  left: 50%;
  z-index: 2;
  transform: translateX(-50%) rotate(-1.2deg);
  width: min(88%, 780px);
  color: var(--cyan-soft);
  font-family: "Hasenbar Space Grotesk", "Hasenbar Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: clamp(4.1rem, 9vw, 8.6rem);
  font-weight: 500;
  line-height: 0.78;
  text-align: center;
  overflow: visible;
  text-shadow:
    0 0 5px #dfffff,
    0 0 14px var(--cyan),
    0 0 38px rgba(23, 248, 241, 0.96),
    0 0 85px rgba(23, 248, 241, 0.58);
  animation: neon-pulse 3.8s infinite, neon-jitter 8.5s steps(1, end) infinite;
}

.neon-sign::before {
  position: absolute;
  inset: -12% -4%;
  z-index: -1;
  content: "HASEN\A BAR";
  white-space: pre;
  color: transparent;
  -webkit-text-stroke: 7px rgba(23, 248, 241, 0.18);
  filter: blur(6px);
}

.neon-sign span {
  display: block;
}

.neon-sign span + span {
  margin-top: 0.04em;
}

.hidden-knock {
  position: absolute;
  right: 8%;
  bottom: 13%;
  z-index: 3;
  display: grid;
  width: 104px;
  height: 104px;
  place-items: center;
  border: 1px solid rgba(125, 255, 251, 0.34);
  border-radius: 50%;
  color: var(--cyan-soft);
  background:
    radial-gradient(circle at 50% 50%, rgba(125, 255, 251, 0.18), transparent 32%),
    conic-gradient(from 120deg, transparent 0 16%, rgba(125, 255, 251, 0.34) 18% 23%, transparent 25% 52%, rgba(255, 66, 111, 0.24) 54% 58%, transparent 60% 100%),
    rgba(0, 0, 0, 0.16);
  cursor: pointer;
  box-shadow:
    0 0 34px rgba(23, 248, 241, 0.14),
    inset 0 0 36px rgba(23, 248, 241, 0.09);
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease, filter 180ms ease;
}

.hidden-knock::before,
.hidden-knock::after {
  position: absolute;
  content: "";
  border-radius: 50%;
  pointer-events: none;
}

.hidden-knock::before {
  inset: 11px;
  border: 1px dashed rgba(125, 255, 251, 0.46);
  animation: dial-turn 10s linear infinite;
}

.hidden-knock::after {
  inset: -10px;
  border: 1px solid rgba(125, 255, 251, 0.18);
  box-shadow: 0 0 28px rgba(23, 248, 241, 0.18);
}

.hidden-knock:hover,
.hidden-knock:focus-visible {
  border-color: rgba(125, 255, 251, 0.88);
  box-shadow:
    0 0 48px rgba(23, 248, 241, 0.34),
    0 0 90px rgba(255, 66, 111, 0.14),
    inset 0 0 44px rgba(23, 248, 241, 0.16);
  filter: brightness(1.25);
  outline: none;
  transform: scale(1.05) rotate(-2deg);
}

.hidden-knock span {
  position: absolute;
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 16px currentColor, 0 0 34px currentColor;
}

.hidden-knock span:nth-child(1) {
  transform: translate(-12px, -8px);
}

.hidden-knock span:nth-child(2) {
  transform: translate(12px, -8px);
}

.hidden-knock span:nth-child(3) {
  transform: translate(0, 13px);
}

.hero-copy {
  max-width: 620px;
}

.kicker,
.section-label {
  margin: 0 0 18px;
  color: var(--cyan-soft);
  font-size: 0.78rem;
  font-weight: 800;
  text-shadow: 0 0 18px rgba(23, 248, 241, 0.64);
}

.kicker {
  text-transform: none;
}

.section-label {
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  font-family: "Hasenbar Space Grotesk", "Hasenbar Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

h1 {
  max-width: 12ch;
  margin-bottom: 24px;
  font-size: clamp(3.2rem, 7vw, 7.4rem);
  line-height: 0.88;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(2.25rem, 5vw, 5.2rem);
  line-height: 0.92;
}

h3 {
  margin-bottom: 10px;
  font-size: 1.18rem;
}

.lead,
.hero-copy p:not(.kicker),
.split-section p,
.invite-copy p,
.signal-text p,
.revealed-card p {
  color: var(--muted);
  font-size: clamp(1rem, 1.5vw, 1.16rem);
  line-height: 1.75;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  padding: 0 18px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 800;
  text-transform: uppercase;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
  outline: none;
}

.button.primary {
  border-color: rgba(125, 255, 251, 0.7);
  color: #021112;
  background: linear-gradient(135deg, var(--cyan-soft), var(--cyan));
  box-shadow: 0 0 28px rgba(23, 248, 241, 0.22);
}

.button.ghost {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.035);
}

.intro-band {
  padding: 30px clamp(18px, 4vw, 56px);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(1, 8, 9, 0.46);
}

.intro-band p {
  max-width: 980px;
  margin: 0 auto;
  color: var(--ink);
  font-family: "Hasenbar Space Grotesk", "Hasenbar Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: clamp(1.35rem, 3vw, 2.65rem);
  line-height: 1.14;
  text-align: center;
}

.split-section,
.signal-section {
  display: grid;
  grid-template-columns: minmax(280px, 0.72fr) minmax(0, 1fr);
  gap: clamp(30px, 7vw, 96px);
  padding: clamp(72px, 12vw, 150px) clamp(18px, 4vw, 56px);
}

.steps {
  display: grid;
  gap: 1px;
  background: var(--line);
}

.step {
  min-height: 190px;
  padding: clamp(22px, 4vw, 34px);
  background: rgba(5, 14, 15, 0.76);
}

.step span,
.signal-grid span {
  display: block;
  margin-bottom: 28px;
  color: var(--dim);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.step p {
  margin-bottom: 0;
}

.invitation-section {
  padding: 0 clamp(18px, 4vw, 56px) clamp(72px, 12vw, 150px);
}

.invite-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(300px, 0.85fr);
  gap: clamp(28px, 5vw, 70px);
  align-items: start;
  max-width: 1240px;
  margin: 0 auto;
  padding: clamp(28px, 5vw, 58px);
  border: 1px solid rgba(125, 255, 251, 0.22);
  background:
    linear-gradient(135deg, rgba(23, 248, 241, 0.08), transparent 42%),
    rgba(5, 14, 15, 0.78);
  box-shadow: var(--shadow), inset 0 0 72px rgba(23, 248, 241, 0.06);
}

.invite-copy h2 {
  margin-bottom: 22px;
}

.invite-form {
  display: grid;
  gap: 12px;
}

.invite-form label {
  color: var(--dim);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

.code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

input {
  width: 100%;
  min-height: 56px;
  border: 1px solid rgba(125, 255, 251, 0.24);
  border-radius: 999px;
  padding: 0 18px;
  color: var(--ink);
  background: rgba(0, 0, 0, 0.3);
  outline: none;
  text-transform: uppercase;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

input:focus {
  border-color: rgba(125, 255, 251, 0.72);
  box-shadow: 0 0 28px rgba(23, 248, 241, 0.18);
}

input::placeholder {
  color: rgba(218, 252, 252, 0.34);
}

.form-message {
  min-height: 28px;
  margin: 0;
  color: var(--dim);
  font-size: 0.94rem;
}

.revealed-card {
  grid-column: 1 / -1;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.revealed-card h3 {
  font-size: clamp(1.8rem, 4vw, 3.4rem);
}

.revealed-email {
  display: inline-flex;
  margin-top: 16px;
  color: var(--cyan-soft);
  font-family: "Hasenbar Space Grotesk", "Hasenbar Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: clamp(1.4rem, 4vw, 3.1rem);
  font-weight: 700;
  line-height: 1;
  text-shadow:
    0 0 12px rgba(125, 255, 251, 0.76),
    0 0 42px rgba(23, 248, 241, 0.38);
  word-break: break-word;
}

.signal-section {
  align-items: end;
  padding-top: 0;
}

.signal-text {
  max-width: 650px;
}

.signal-text h2 {
  margin-bottom: 22px;
}

.signal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: 1px solid var(--line);
}

.signal-grid div {
  min-height: 142px;
  padding: 24px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
}

.signal-grid div:nth-child(2n) {
  border-right: 0;
}

.signal-grid div:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.signal-grid strong {
  display: block;
  font-family: "Hasenbar Space Grotesk", "Hasenbar Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: clamp(1.15rem, 2vw, 1.7rem);
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 34px clamp(18px, 4vw, 56px);
  border-top: 1px solid var(--line);
  color: var(--dim);
}

.site-footer p {
  margin: 0;
  color: var(--ink);
  font-family: "Hasenbar Space Grotesk", "Hasenbar Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 700;
}

.site-footer a:hover {
  color: var(--cyan-soft);
}

.footer-menu {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

body.knock-open .neon-sign {
  animation: neon-flare 1200ms steps(1, end) both, neon-pulse 2.9s 1200ms infinite, neon-jitter 7s steps(1, end) infinite;
}

body.knock-open .wall {
  box-shadow: var(--shadow), inset 0 0 140px rgba(23, 248, 241, 0.18);
}

body.knock-burst .wall::after {
  opacity: 0.78;
  animation: scanline-drift 1.6s linear infinite, signal-surge 900ms ease both;
}

body.knock-burst .hidden-knock {
  animation: knock-ring 900ms ease both;
}

@keyframes neon-pulse {
  0% {
    opacity: 1;
    filter: brightness(1);
  }
  7% {
    opacity: 0.72;
    filter: brightness(0.7);
  }
  8%,
  11% {
    opacity: 1;
    filter: brightness(1.5);
  }
  12% {
    opacity: 0.38;
    filter: brightness(0.44);
  }
  13%,
  41% {
    opacity: 1;
    filter: brightness(1);
  }
  42% {
    opacity: 0.82;
    filter: brightness(0.82);
  }
  44% {
    opacity: 1;
    filter: brightness(1.22);
  }
  58% {
    opacity: 0.68;
    filter: brightness(0.7);
  }
  59%,
  100% {
    opacity: 1;
    filter: brightness(1);
  }
}

@keyframes neon-flare {
  0% {
    opacity: 1;
    filter: brightness(1) blur(0);
    transform: translateX(-50%) rotate(-1.2deg) skewX(0);
  }
  8% {
    opacity: 0.12;
    filter: brightness(0.2) blur(2px);
  }
  11% {
    opacity: 1;
    filter: brightness(2.8) blur(0);
  }
  18% {
    opacity: 0.24;
  }
  21% {
    opacity: 1;
    transform: translateX(-50%) rotate(-1.2deg) skewX(-7deg);
  }
  28% {
    opacity: 0.36;
    filter: brightness(0.4);
  }
  32%,
  52% {
    opacity: 1;
    filter: brightness(3.2);
  }
  56% {
    opacity: 0.58;
    transform: translateX(-49.5%) rotate(-1.2deg) skewX(5deg);
  }
  62%,
  78% {
    opacity: 1;
    filter: brightness(2.1);
  }
  100% {
    opacity: 1;
    filter: brightness(1);
    transform: translateX(-50%) rotate(-1.2deg) skewX(0);
  }
}

@keyframes neon-jitter {
  0%,
  92%,
  100% {
    transform: translateX(-50%) rotate(-1.2deg);
  }
  93% {
    transform: translateX(calc(-50% + 3px)) rotate(-1deg);
  }
  94% {
    transform: translateX(calc(-50% - 2px)) rotate(-1.4deg);
  }
  95% {
    transform: translateX(-50%) rotate(-1.2deg);
  }
}

@keyframes scanline-drift {
  from {
    background-position: 0 0, 0 0;
  }
  to {
    background-position: 0 120px, 0 80px;
  }
}

@keyframes wall-hum {
  0%,
  100% {
    filter: saturate(1) brightness(1);
  }
  50% {
    filter: saturate(1.18) brightness(1.06);
  }
}

@keyframes signal-surge {
  0% {
    transform: translateY(-18%);
  }
  100% {
    transform: translateY(18%);
  }
}

@keyframes dial-turn {
  to {
    transform: rotate(360deg);
  }
}

@keyframes knock-ring {
  0% {
    transform: scale(1);
  }
  32% {
    transform: scale(1.18) rotate(10deg);
  }
  100% {
    transform: scale(1);
  }
}

@media (max-width: 980px) {
  .hero,
  .split-section,
  .signal-section,
  .invite-panel {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 82px;
  }

  .hero-copy {
    order: -1;
  }

  h1 {
    max-width: 9ch;
  }
}

@media (max-width: 720px) {
  .site-header {
    position: absolute;
  }

  .nav {
    display: none;
  }

  .hero {
    min-height: auto;
  }

  .wall {
    min-height: 390px;
  }

  .neon-sign {
    top: 24%;
    font-size: clamp(3.3rem, 17vw, 5.8rem);
  }

  .code-row,
  .signal-grid {
    grid-template-columns: 1fr;
  }

  .code-row .button {
    width: 100%;
  }

  .signal-grid div,
  .signal-grid div:nth-child(2n),
  .signal-grid div:nth-last-child(-n + 2) {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .signal-grid div:last-child {
    border-bottom: 0;
  }

  .site-footer {
    flex-direction: column;
  }
}

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