:root {
  --bg: #060810;
  --bg-2: #150a1e;
  --card: #0c1018;
  --line: #1e3545;
  --text: #d0f0ff;
  --muted: #7eb8c8;
  --neon: #00fff0;
  --pink: #ff2d9b;
  --lime: #2df8ff;
  --violet: #ff62b8;
  --pointer-x: 50%;
  --pointer-y: 50%;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Courier New", "Lucida Console", monospace;
  color: var(--text);
  background: #020308;
  min-height: 100vh;
  letter-spacing: 0.01em;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    repeating-linear-gradient(0deg, transparent, transparent 1px, rgba(0, 255, 240, 0.015) 1px, rgba(0, 255, 240, 0.015) 2px),
    repeating-linear-gradient(90deg, transparent, transparent 60px, rgba(255, 45, 155, 0.02) 60px, rgba(255, 45, 155, 0.02) 61px),
    radial-gradient(ellipse at 15% 10%, rgba(0, 255, 240, 0.08), transparent 40%),
    radial-gradient(ellipse at 85% 80%, rgba(255, 45, 155, 0.06), transparent 40%);
  animation: splash-pulse 6.4s ease-in-out infinite;
}

h1,
h2,
h3 {
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 900;
}

h1 {
  text-shadow: 0 0 12px rgba(0, 255, 240, 0.3), 0 0 28px rgba(255, 45, 155, 0.15);
}

h2,
h3 {
  text-shadow: none;
}

.scanline {
  display: block;
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 6;
  background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0, 0, 0, 0.04) 2px, rgba(0, 0, 0, 0.04) 4px);
  mix-blend-mode: multiply;
}

.terminal-matrix {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 1;
  opacity: 0.18;
}

.terminal-layer {
  margin: 0;
  position: absolute;
  inset: -8% -6%;
  font-family: "Courier New", "Lucida Console", monospace;
  font-size: clamp(11px, 1vw, 14px);
  line-height: 1.5;
  letter-spacing: 0.08em;
  white-space: pre-wrap;
  word-break: break-word;
  text-transform: uppercase;
  color: rgba(120, 255, 245, 0.95);
  text-shadow: 0 0 8px rgba(0, 255, 240, 0.35), 0 0 20px rgba(255, 45, 155, 0.16);
}

.terminal-layer-a {
  transform: translate3d(0, 0, 0);
  animation: matrix-scroll-a 26s linear infinite;
}

.terminal-layer-b {
  color: rgba(152, 255, 248, 0.8);
  transform: translate3d(0, 0, 0);
  animation: matrix-scroll-b 33s linear infinite;
}

.terminal-layer-c {
  color: rgba(125, 255, 240, 0.72);
  animation: matrix-glitch 2.9s steps(2) infinite;
}

.site-header,
.site-footer {
  background: rgba(4, 6, 14, 0.95);
  border-bottom: 2px solid rgba(0, 255, 240, 0.15);
  backdrop-filter: blur(6px);
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1.2rem;
  position: sticky;
  top: 0;
  z-index: 5;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.6), 0 1px 0 rgba(0, 255, 240, 0.08);
}

.brand {
  color: #fff;
  text-decoration: none;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 1.1rem;
  text-shadow: 0 0 8px rgba(0, 255, 240, 0.5), 0 0 20px rgba(255, 45, 155, 0.3);
  border-bottom: 2px solid var(--pink);
  padding-bottom: 2px;
}

nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.7rem;
}

nav a,
.link-btn {
  color: var(--text);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border: 1px solid rgba(0, 255, 240, 0.12);
  border-radius: 0.2rem;
  padding: 0.3rem 0.7rem;
  background: rgba(0, 255, 240, 0.04);
  transition: border-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

nav a:hover,
.link-btn:hover {
  border-color: var(--neon);
  color: #fff;
  background: rgba(0, 255, 240, 0.1);
  box-shadow: 0 0 10px rgba(0, 255, 240, 0.2), 0 4px 12px rgba(0, 0, 0, 0.4);
  transform: translateY(-1px);
}

.inline-form {
  display: inline;
}

.danger-form {
  margin-top: 0.5rem;
}

.link-btn {
  background: transparent;
  cursor: pointer;
}

.container {
  width: min(1300px, 95vw);
  margin: 1rem auto 3rem;
  position: relative;
  z-index: 3;
}

.webgl-bg {
  position: relative;
  inset: auto;
  z-index: 2;
  margin: 0 auto 1rem;
  width: 100%;
  pointer-events: none;
  opacity: 1;
  display: flex;
  justify-content: center;
}

.home-ascii-art {
  --cursor-x: 50%;
  --cursor-y: 50%;
  margin: 0;
  width: 100%;
  padding: 1rem 1.35rem;
  font-family: "Courier New", "Consolas", monospace;
  font-size: clamp(8px, 1.15vw, 16px);
  line-height: 1.08;
  white-space: pre;
  color: rgba(161, 255, 248, 0.96);
  text-shadow: 0 0 10px rgba(0, 255, 240, 0.44), 0 0 22px rgba(255, 45, 155, 0.22);
  user-select: none;
  max-width: none;
  overflow: hidden;
  border: 1px solid rgba(0, 255, 240, 0.12);
  border-top: 2px solid rgba(0, 255, 240, 0.2);
  border-radius: 0.15rem;
  background: rgba(4, 8, 16, 0.95);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
  animation: none;
}

.panel {
  --cursor-x: 50%;
  --cursor-y: 50%;
  background: linear-gradient(168deg, rgba(8, 14, 24, 0.98), rgba(4, 6, 14, 0.95));
  border: 1px solid rgba(0, 255, 240, 0.1);
  border-left: 3px solid rgba(0, 255, 240, 0.25);
  border-radius: 0.2rem;
  padding: 1.2rem 1.3rem;
  margin-bottom: 1.1rem;
  backdrop-filter: none;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(0, 255, 240, 0.04);
  position: relative;
  overflow: hidden;
  animation: none;
}

.panel::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, var(--neon), transparent 60%);
  opacity: 0.3;
}

.panel::after {
  content: "";
  position: absolute;
  bottom: 0;
  right: 0;
  width: 40px;
  height: 40px;
  border-right: 2px solid rgba(255, 45, 155, 0.15);
  border-bottom: 2px solid rgba(255, 45, 155, 0.15);
  border-radius: 0 0 0.2rem 0;
  pointer-events: none;
}

.panel.interactive-active::before,
.card.interactive-active::before,
.home-ascii-art.interactive-active::before {
  opacity: 0.9;
}

.hero {
  min-height: clamp(240px, 24vw, 360px);
  display: block;
  padding-block: clamp(1.4rem, 3.2vw, 2.4rem);
  background: linear-gradient(175deg, rgba(10, 16, 28, 0.98), rgba(4, 6, 14, 0.96));
  border-color: rgba(0, 255, 240, 0.15);
  border-left: 3px solid rgba(255, 45, 155, 0.3);
  animation: none;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, var(--pink), var(--neon) 50%, transparent);
  opacity: 0.4;
}

.hero h1 {
  margin: 0.15rem 0 0.2rem;
  font-size: clamp(2rem, 4.3vw, 3.35rem);
  line-height: 1.08;
  max-width: 28ch;
  text-wrap: balance;
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
  gap: clamp(0.9rem, 2vw, 1.6rem);
  align-items: start;
}

.hero-copy-block {
  display: grid;
  gap: 1rem;
}

.kicker {
  color: var(--pink);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: clamp(0.8rem, 1.3vw, 1rem);
  font-weight: 800;
  margin: 0;
  text-shadow: 0 0 10px rgba(255, 45, 155, 0.4);
  border-left: 3px solid var(--pink);
  padding-left: 0.6rem;
}

.pulse-text {
  animation: pulse-text 4.4s ease-in-out infinite;
}

.hero-title-glow {
  animation: hero-glow 4s ease-in-out infinite;
}

.hero-copy {
  text-wrap: pretty;
  font-size: clamp(1.05rem, 1.7vw, 1.32rem);
  line-height: 1.58;
  margin: 0.2rem 0 0.55rem;
  max-width: 52ch;
}

[data-animate="rise"] {
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.58s ease,
    transform 0.58s cubic-bezier(0.2, 0.8, 0.2, 1);
  transition-delay: var(--rise-delay, 0ms);
}

[data-animate="rise"].in-view {
  opacity: 1;
  transform: translateY(0);
}

.btn {
  display: inline-block;
  background: linear-gradient(180deg, rgba(0, 255, 240, 0.08), rgba(0, 255, 240, 0.02));
  border: 1px solid rgba(0, 255, 240, 0.2);
  color: #fff;
  border-radius: 0.15rem;
  padding: 0.55rem 1rem;
  text-decoration: none;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 800;
  font-size: 0.85rem;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease, border-color 0.18s ease;
  animation: none;
}

.btn:hover {
  filter: brightness(1.1);
  transform: translateY(-2px);
  border-color: var(--neon);
  box-shadow: 0 0 16px rgba(0, 255, 240, 0.2), 0 8px 20px rgba(0, 0, 0, 0.5);
}

.hero .btn {
  width: min(25%, 280px);
  min-width: 170px;
  justify-self: center;
  text-align: center;
  border: 2px solid var(--pink);
  color: #fff;
  background: linear-gradient(180deg, rgba(255, 45, 155, 0.12), rgba(255, 45, 155, 0.04));
  box-shadow: 0 0 0 1px rgba(255, 45, 155, 0.2), 0 0 20px rgba(255, 45, 155, 0.25), 0 8px 20px rgba(0, 0, 0, 0.5);
  animation: read-blog-pulse 1.7s ease-in-out infinite;
}

.hero .btn:hover {
  filter: brightness(1.2);
  box-shadow: 0 0 0 1px rgba(255, 45, 155, 0.4), 0 0 30px rgba(255, 45, 155, 0.4), 0 10px 24px rgba(0, 0, 0, 0.6);
}

.danger-btn {
  background: linear-gradient(180deg, rgba(255, 45, 100, 0.15), rgba(255, 45, 100, 0.06));
  border: 1px solid rgba(255, 77, 120, 0.4);
  color: #ffeaf3;
  border-radius: 0.15rem;
  padding: 0.5rem 0.8rem;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 700;
  font-size: 0.82rem;
}

.danger-btn:hover {
  filter: brightness(1.12);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.9rem;
}

.stack {
  display: grid;
  gap: 0.8rem;
}

.card {
  --cursor-x: 50%;
  --cursor-y: 50%;
  background: rgba(8, 12, 22, 0.9);
  border: 1px solid rgba(0, 255, 240, 0.08);
  border-top: 2px solid rgba(0, 255, 240, 0.18);
  border-radius: 0.15rem;
  padding: 0.9rem;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
  will-change: transform;
  transform-style: preserve-3d;
  position: relative;
  overflow: hidden;
  animation: none;
}

.project-card {
  position: relative;
}

.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: linear-gradient(180deg, var(--neon), var(--pink));
  opacity: 0.2;
  transition: opacity 0.2s ease;
}

.card:hover::before {
  opacity: 0.5;
}

.card.tilting {
  border-color: rgba(0, 255, 240, 0.25);
  box-shadow: 0 0 20px rgba(0, 255, 240, 0.08), 0 14px 24px rgba(0, 0, 0, 0.5);
}

.project-hover-pop {
  position: absolute;
  left: 0.55rem;
  right: 0.55rem;
  top: 0.55rem;
  z-index: 3;
  background: rgba(4, 6, 14, 0.97);
  border: 1px solid rgba(0, 255, 240, 0.3);
  border-left: 3px solid var(--neon);
  border-radius: 0.15rem;
  padding: 0.65rem 0.85rem;
  color: var(--text);
  font-size: 0.84rem;
  line-height: 1.35;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.16s ease, transform 0.16s ease;
  pointer-events: none;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
}

.project-card:hover .project-hover-pop,
.project-card:focus-within .project-hover-pop {
  opacity: 1;
  transform: translateY(0);
}

.meta {
  color: #6cc0c8;
  font-size: 0.88rem;
}

.formatted-text {
  line-height: 1.7;
}

.formatted-text p {
  margin: 0 0 0.8rem;
}

.formatted-text .paragraph-header {
  margin: 0.95rem 0 0.5rem;
}

.thumb,
.full-image {
  width: 100%;
  border-radius: 0.15rem;
  border: 1px solid rgba(0, 255, 240, 0.1);
  margin-bottom: 0.65rem;
}

.full-image {
  max-height: 480px;
  object-fit: cover;
}

.media-player {
  width: 100%;
  margin-top: 0.55rem;
  min-height: 220px;
  border: 1px solid rgba(0, 255, 240, 0.1);
  border-radius: 0.15rem;
}

.retro-arcade-border {
  position: fixed;
  top: 0;
  bottom: 0;
  width: clamp(72px, 9vw, 124px);
  pointer-events: none;
  z-index: 1;
  opacity: 0.08;
  overflow: hidden;
}

.retro-arcade-border-left {
  left: 0;
  border-right: 1px solid rgba(116, 255, 241, 0.14);
  background: linear-gradient(to right, rgba(116, 255, 241, 0.1), rgba(116, 255, 241, 0.02) 70%, transparent);
}

.retro-arcade-border-right {
  right: 0;
  border-left: 1px solid rgba(116, 255, 241, 0.14);
  background: linear-gradient(to left, rgba(116, 255, 241, 0.1), rgba(116, 255, 241, 0.02) 70%, transparent);
}

.retroAsciiSide {
  margin: 0;
  font-family: "Courier New", monospace;
  font-size: clamp(10px, 0.88vw, 12px);
  line-height: 1.1;
  color: #74fff1;
  transform: translate3d(0, 0, 0);
  white-space: pre;
  width: 100%;
  height: 100%;
  padding: 0.4rem;
}

.album-card {
  padding: 1rem;
}

.album-summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.album-summary::-webkit-details-marker {
  display: none;
}

.admin-collapsible {
  width: 100%;
}

.admin-summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.admin-summary::-webkit-details-marker {
  display: none;
}

.admin-summary h2 {
  margin: 0;
}

.admin-arrow {
  color: var(--neon);
  font-size: 0.95rem;
  transform: rotate(0deg);
  transition: transform 0.18s ease;
}

details[open] .admin-arrow {
  transform: rotate(90deg);
}

.admin-content {
  margin-top: 0.8rem;
}

.album-arrow {
  color: var(--neon);
  font-size: 0.95rem;
  transform: rotate(0deg);
  transition: transform 0.18s ease;
}

details[open] .album-arrow {
  transform: rotate(90deg);
}

.album-header {
  display: flex;
  gap: 0.9rem;
  align-items: center;
  margin-bottom: 0;
}

.album-cover {
  width: 86px;
  height: 86px;
  border-radius: 0.15rem;
  object-fit: cover;
  border: 1px solid rgba(0, 255, 240, 0.1);
}

.track-row {
  border-top: 1px solid rgba(0, 255, 240, 0.08);
  padding-top: 0.55rem;
}

.album-tracks {
  margin-top: 0.7rem;
}

.track-title {
  margin: 0 0 0.4rem;
  color: var(--text);
}

.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.7rem;
}

.image-tile {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 0.15rem;
  border: 1px solid rgba(0, 255, 240, 0.1);
}

.about-profile {
  display: flex;
  justify-content: center;
  margin-bottom: 0.7rem;
}

.profile-avatar {
  width: 108px;
  height: 108px;
  border-radius: 0.2rem;
  object-fit: cover;
  border: 2px solid var(--neon);
  box-shadow: 0 0 12px rgba(0, 255, 240, 0.15);
}

.home-about-summary {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1rem;
  align-items: center;
}

.home-avatar {
  margin: 0;
}

.home-about-copy h2 {
  margin: 0 0 0.3rem;
}

.home-about-copy p {
  margin: 0 0 0.5rem;
}

.about-socials {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  justify-content: center;
}

.social-icon {
  width: 40px;
  height: 40px;
  border-radius: 0.15rem;
  border: 1px solid rgba(0, 255, 240, 0.12);
  background: rgba(0, 255, 240, 0.04);
  color: var(--text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  transition: transform 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.social-icon:hover {
  border-color: var(--neon);
  color: var(--neon);
  transform: translateY(-1px);
}

.social-icon img {
  display: block;
  width: 22px;
  height: 22px;
}

.typewriter-line {
  min-height: 1.4em;
}

.typewriter-line.typing-active::after {
  content: "_";
  margin-left: 0.1rem;
  color: var(--neon);
  animation: blink-caret 0.75s step-end infinite;
}

[data-typewriter].typing-active::after {
  content: "_";
  margin-left: 0.08rem;
  color: var(--neon);
  animation: blink-caret 0.75s step-end infinite;
}

.hero [data-typewriter] {
  position: relative;
  display: inline-block;
}

.hero [data-typewriter].typing-glitch::before,
.hero [data-typewriter].typing-glitch::after {
  content: attr(data-glitch-text);
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.36;
}

.hero [data-typewriter].typing-glitch {
  animation: glitch-spectrum 5.2s linear infinite;
}

.hero [data-typewriter].typing-glitch::before {
  color: #ffffff;
  text-shadow: -1px 0 rgba(255, 255, 255, 0.4);
  transform: translate3d(-1px, 0, 0);
  animation: hero-text-glitch-a 1.9s steps(2) infinite;
}

.hero [data-typewriter].typing-glitch::after {
  color: var(--pink);
  text-shadow: 1px 0 rgba(255, 45, 155, 0.4);
  transform: translate3d(1px, 0, 0);
  animation: hero-text-glitch-b 2.3s steps(2) infinite;
}

.hero-neural-ascii {
  margin: 0;
  width: fit-content;
  max-width: 100%;
  height: auto;
  min-height: 0;
  display: inline-block;
  align-self: start;
  justify-self: end;
  padding: 0.3rem;
  border: 1px solid rgba(0, 255, 240, 0.12);
  border-right: 3px solid rgba(255, 45, 155, 0.25);
  border-radius: 0.15rem;
  background: rgba(4, 6, 14, 0.95);
  color: #a3edff;
  font-family: "Courier New", "Lucida Console", monospace;
  font-size: clamp(8px, 1.02vw, 14px);
  line-height: 0.98;
  letter-spacing: -0.02em;
  text-shadow: 0 0 8px rgba(0, 255, 240, 0.35), 0 0 14px rgba(255, 45, 155, 0.2);
  white-space: pre;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(0, 255, 240, 0.12), 0 10px 22px rgba(0, 0, 0, 0.42);
  animation: neural-ascii-glitch 2.8s steps(2) infinite;
  transition: filter 0.08s linear, text-shadow 0.08s linear;
}

.hero-neural-ascii.ascii-burst {
  color: #e9f8ff;
  filter: hue-rotate(var(--panel-hue, 0deg)) saturate(1.25) brightness(1.1);
  text-shadow: 0 0 10px rgba(0, 255, 240, 0.58), 0 0 20px rgba(255, 45, 155, 0.45);
}

.hero-neural-ascii.ascii-interact {
  filter: hue-rotate(var(--panel-hue, 0deg)) saturate(1.7) brightness(1.28) contrast(1.16);
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.26), 0 0 22px rgba(0, 255, 240, 0.62), 0 0 30px rgba(255, 45, 155, 0.52);
}

.hero [data-typewriter].glitch-burst {
  filter: hue-rotate(var(--glitch-hue, 0deg)) saturate(1.28) brightness(1.16);
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.34), 0 0 18px rgba(255, 45, 155, 0.5);
}

@keyframes blink-caret {
  from,
  to {
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
}

@keyframes pulse-text {
  0%,
  100% {
    text-shadow: 0 0 4px rgba(255, 45, 155, 0.2);
    opacity: 0.92;
  }
  50% {
    text-shadow: 0 0 16px rgba(255, 45, 155, 0.5);
    opacity: 1;
  }
}

@keyframes hero-glow {
  0%,
  100% {
    text-shadow: 0 0 7px rgba(87, 212, 255, 0.22), 0 0 0 rgba(87, 212, 255, 0);
  }
  50% {
    text-shadow: 0 0 14px rgba(87, 212, 255, 0.45), 0 0 24px rgba(87, 212, 255, 0.2);
  }
}

@keyframes hero-text-glitch-a {
  0%,
  90%,
  100% {
    clip-path: inset(0 0 0 0);
    opacity: 0.2;
    transform: translate3d(-1px, 0, 0);
  }
  92% {
    clip-path: inset(14% 0 63% 0);
    opacity: 0.38;
    transform: translate3d(1px, 0, 0);
  }
  94% {
    clip-path: inset(58% 0 20% 0);
    opacity: 0.32;
    transform: translate3d(-2px, 0, 0);
  }
}

@keyframes hero-text-glitch-b {
  0%,
  88%,
  100% {
    clip-path: inset(0 0 0 0);
    opacity: 0.16;
    transform: translate3d(1px, 0, 0);
  }
  90% {
    clip-path: inset(8% 0 70% 0);
    opacity: 0.3;
    transform: translate3d(-1px, 0, 0);
  }
  93% {
    clip-path: inset(64% 0 10% 0);
    opacity: 0.26;
    transform: translate3d(2px, 0, 0);
  }
}

@keyframes glitch-spectrum {
  0% {
    color: #d0f0ff;
  }
  25% {
    color: #e9f8ff;
  }
  50% {
    color: #ff2d9b;
  }
  75% {
    color: #8eedff;
  }
  100% {
    color: #d0f0ff;
  }
}

@keyframes neural-ascii-glitch {
  0%,
  80%,
  100% {
    transform: translate3d(0, 0, 0);
    filter: brightness(1);
  }
  84% {
    transform: translate3d(1px, 0, 0);
    filter: brightness(1.16);
  }
  88% {
    transform: translate3d(-1px, 1px, 0);
    filter: brightness(1.06);
  }
}

.narrow {
  max-width: 500px;
  margin-inline: auto;
}

label {
  display: grid;
  gap: 0.38rem;
  font-size: 0.92rem;
}

input,
textarea,
select {
  width: 100%;
  background: rgba(4, 8, 16, 0.9);
  color: var(--text);
  border: 1px solid rgba(0, 255, 240, 0.1);
  border-radius: 0.15rem;
  padding: 0.56rem;
  box-shadow: none;
  transition: border-color 0.2s;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: rgba(0, 255, 240, 0.3);
}

textarea {
  resize: vertical;
}

.error {
  color: #ff9797;
}

.mini-list {
  margin: 0.6rem 0 1rem;
  padding-left: 1rem;
}

.site-footer {
  border-top: 2px solid rgba(0, 255, 240, 0.1);
  border-bottom: none;
  padding: 0.75rem 1rem;
  text-align: center;
  color: var(--muted);
}

@keyframes read-blog-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 1px rgba(255, 45, 155, 0.2), 0 0 20px rgba(255, 45, 155, 0.25), 0 8px 20px rgba(0, 0, 0, 0.5);
  }
  50% {
    box-shadow: 0 0 0 1px rgba(255, 45, 155, 0.45), 0 0 36px rgba(255, 45, 155, 0.45), 0 12px 24px rgba(0, 0, 0, 0.55);
  }
}

@keyframes matrix-scroll-a {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-8%, -10%, 0);
  }
}

@keyframes matrix-scroll-b {
  from {
    transform: translate3d(3%, 6%, 0);
  }
  to {
    transform: translate3d(-6%, -4%, 0);
  }
}

@keyframes matrix-glitch {
  0%,
  84%,
  100% {
    transform: translate3d(0, 0, 0);
    opacity: 0.82;
  }
  86% {
    transform: translate3d(2px, 0, 0);
    opacity: 0.62;
  }
  88% {
    transform: translate3d(-3px, 1px, 0);
    opacity: 0.9;
  }
}

@keyframes splash-pulse {
  0%,
  100% {
    opacity: 0.5;
  }
  50% {
    opacity: 0.78;
  }
}

@keyframes neon-breathe {
  0%,
  100% {
    box-shadow:
      0 0 0 1px rgba(45, 240, 255, 0.1),
      0 14px 30px rgba(0, 0, 0, 0.4),
      0 0 22px rgba(255, 107, 170, 0.1);
  }
  50% {
    box-shadow:
      0 0 0 1px rgba(45, 240, 255, 0.3),
      0 18px 36px rgba(0, 0, 0, 0.52),
      0 0 34px rgba(0, 248, 255, 0.22);
  }
}

@keyframes hero-breathe {
  0%,
  100% {
    border-color: rgba(0, 248, 255, 0.32);
    filter: saturate(1);
  }
  50% {
    border-color: rgba(45, 240, 255, 0.52);
    filter: saturate(1.14);
  }
}

@keyframes btn-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 1px rgba(0, 248, 255, 0.25), 0 10px 24px rgba(0, 0, 0, 0.4);
  }
  50% {
    box-shadow: 0 0 0 1px rgba(0, 248, 255, 0.56), 0 0 20px rgba(45, 240, 255, 0.32), 0 14px 28px rgba(0, 0, 0, 0.52);
  }
}

@keyframes panel-glitch {
  0%,
  86%,
  100% {
    transform: translate3d(0, 0, 0);
    opacity: 1;
  }
  88% {
    transform: translate3d(1px, 0, 0);
    opacity: 0.88;
  }
  90% {
    transform: translate3d(-1px, 0, 0);
    opacity: 0.9;
  }
  92% {
    transform: translate3d(0, 0, 0);
    opacity: 1;
  }
}

@keyframes backdrop-drift {
  0% {
    filter: brightness(1) saturate(1.02);
  }
  100% {
    filter: brightness(1.08) saturate(1.18);
  }
}

@keyframes glitch-sweep {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
    opacity: 0.68;
  }
  48% {
    transform: translate3d(0, 0, 0);
    opacity: 0.76;
  }
  49% {
    transform: translate3d(3px, 0, 0);
    opacity: 0.52;
  }
  50% {
    transform: translate3d(-4px, 0, 0);
    opacity: 0.84;
  }
  51% {
    transform: translate3d(0, 0, 0);
    opacity: 0.72;
  }
}

@keyframes noise-jitter {
  0% {
    transform: translate3d(0, 0, 0);
  }
  25% {
    transform: translate3d(1px, -1px, 0);
  }
  50% {
    transform: translate3d(-1px, 1px, 0);
  }
  75% {
    transform: translate3d(1px, 1px, 0);
  }
  100% {
    transform: translate3d(0, 0, 0);
  }
}

@keyframes distortion-drift {
  0%,
  100% {
    filter: contrast(1) brightness(1);
  }
  50% {
    filter: contrast(1.2) brightness(1.08);
  }
}

@media (max-width: 700px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .home-about-summary {
    grid-template-columns: 1fr;
    text-align: center;
    justify-items: center;
  }
}

@media (max-width: 900px) {
  .webgl-bg {
    width: 100%;
  }

  .home-ascii-art {
    font-size: clamp(7px, 1.9vw, 10px);
    padding: 0.8rem 0.9rem;
  }

  .hero .btn {
    width: min(70%, 280px);
  }

  .hero {
    min-height: clamp(220px, 48vw, 320px);
    gap: 0.78rem;
  }

  .hero-layout {
    grid-template-columns: 1fr;
  }

  .hero-copy-block {
    gap: 0.75rem;
  }

  .hero-neural-ascii {
    width: fit-content;
    max-width: 100%;
    justify-self: center;
    min-height: 0;
  }

  .hero h1 {
    font-size: clamp(1.6rem, 6.4vw, 2.3rem);
  }

  .hero-copy {
    font-size: clamp(0.96rem, 3.2vw, 1.1rem);
  }

  .pulse-text,
  .hero-title-glow {
    animation-duration: 6.8s;
  }
}

/* ── Blog card 2-column layout ── */
.blog-card-row {
  display: grid;
  grid-template-columns: clamp(140px, 22vw, 260px) 1fr;
  gap: 1rem;
  align-items: start;
}

.blog-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0.15rem;
  border: 1px solid rgba(0, 255, 240, 0.1);
}

.blog-card-body h2 {
  margin-top: 0;
  text-shadow: none;
}

.blog-card-body h2 a {
  text-shadow: none;
}

@media (max-width: 700px) {
  .blog-card-row {
    grid-template-columns: 1fr;
  }

  .blog-card-img {
    max-height: 220px;
  }
}

/* ── Contact form ── */
.contact-form label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.contact-form input,
.contact-form textarea {
  background: rgba(4, 8, 16, 0.9);
  border: 1px solid rgba(0, 255, 240, 0.1);
  border-radius: 0.15rem;
  color: #c0f0ff;
  padding: 0.5rem 0.65rem;
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color 0.2s;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: #00fff0;
  box-shadow: 0 0 6px rgba(0, 255, 240, 0.25);
}

.contact-form textarea {
  resize: vertical;
  min-height: 100px;
}

.optional-hint {
  opacity: 0.5;
  font-size: 0.82rem;
}

.contact-success {
  background: rgba(0, 255, 240, 0.08);
  border: 1px solid rgba(0, 255, 240, 0.2);
  border-left: 3px solid var(--neon);
  border-radius: 0.15rem;
  padding: 0.65rem 1rem;
  color: #00fff0;
  margin-bottom: 0.75rem;
}

/* ── Admin message list ── */
.message-card {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.message-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.45rem;
}

.message-email {
  opacity: 0.55;
  font-size: 0.85rem;
}

.message-body {
  white-space: pre-wrap;
  margin: 0.25rem 0;
}

@media (prefers-reduced-motion: reduce) {
  [data-animate="rise"] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .pulse-text,
  .hero-title-glow {
    animation: none;
  }

  .hero [data-typewriter].typing-glitch::before,
  .hero [data-typewriter].typing-glitch::after,
  .hero [data-typewriter].typing-glitch,
  .hero-neural-ascii {
    animation: none;
    opacity: 0;
  }

  body,
  body::before,
  .terminal-layer,
  .panel,
  .card,
  .btn,
  .home-ascii-art,
  .panel::after,
  .hero {
    animation: none;
  }

  .card {
    transition: none;
  }
}
