﻿:root {
  --primary: rgba(255, 255, 255, 0.9);
  --secondary: rgba(255, 255, 255, 0.4);
  --dark: #050505;
  --glass-border: rgba(255, 255, 255, 0.15);
  --font-display: 'Orbitron', sans-serif;
  --font-body: 'Inter', sans-serif;
  --success: #00e676;
  --error: #ff1744;
}

[data-theme="cyber"] {
  --dark: #020205;
  --primary: #00f0ff;
  --secondary: #ff00e6;
  --success: #39ff14;
  --error: #ff003c;
  --glass-border: rgba(0, 240, 255, 0.3);
}

[data-theme="solar"] {
  --dark: #0a0400;
  --primary: #ff9100;
  --secondary: #ff3d00;
  --success: #aeea00;
  --error: #ff1744;
  --glass-border: rgba(255, 145, 0, 0.3);
}

[data-theme="ocean"] {
  --dark: #000814;
  --primary: #00e5ff;
  --secondary: #0044ff;
  --success: #00e676;
  --error: #ff1744;
  --glass-border: rgba(0, 229, 255, 0.3);
}

* {
  box-sizing: border-box;
}

body,
html {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  background: var(--dark);
  font-family: var(--font-body);
  overflow-x: hidden;
  overflow-y: auto;
  color: white;
  transition: background-color 0.5s ease;
}

/* Galaxy Background Container */
#galaxy-container {
  position: fixed;
  inset: 0;
  z-index: 0;
}

#galaxy-container canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

/* Retinal Grid Overlay */
.retinal-grid {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 30px 30px;
  mask-image: radial-gradient(ellipse at center, transparent 30%, rgba(0, 0, 0, 0.4) 60%, rgba(0, 0, 0, 0.7) 100%);
  -webkit-mask-image: radial-gradient(ellipse at center, transparent 30%, rgba(0, 0, 0, 0.4) 60%, rgba(0, 0, 0, 0.7) 100%);
  opacity: 0.5;
}

/* Keyframe: fadeIn */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Ambient floating particles */
@keyframes ambientFloat {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.2;
  }

  25% {
    transform: translate(30px, -50px) scale(1.2);
    opacity: 0.4;
  }

  50% {
    transform: translate(-20px, -100px) scale(0.8);
    opacity: 0.15;
  }

  75% {
    transform: translate(40px, -30px) scale(1.1);
    opacity: 0.35;
  }
}

/* Backgrounds */
/* Hyperspace Jump Animation (Kept for compatibility with success sequence) */
.hyperspace-jump {
  animation: hyperspace 1.5s cubic-bezier(0.7, 0, 0.3, 1) forwards !important;
}

@keyframes hyperspace {
  0% {
    transform: perspective(1000px) scale(1) translateZ(0);
    filter: blur(0) brightness(1);
    opacity: 1;
  }

  40% {
    transform: perspective(1000px) scale(0.9) translateZ(-100px);
    filter: blur(2px) brightness(2);
    opacity: 0.8;
  }

  100% {
    transform: perspective(1000px) scale(5) translateZ(500px);
    filter: blur(20px) brightness(5);
    opacity: 0;
  }
}


/* HUD Elements */
.q-clock {
  position: absolute;
  top: 30px;
  left: 40px;
  z-index: 50;
  font-family: var(--font-display);
}

.q-clock-main {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 2px;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.q-clock-sub {
  font-size: 11px;
  color: #888;
  letter-spacing: 2px;
  margin-top: 4px;
}

.q-clock-epoch {
  font-size: 10px;
  color: var(--primary);
  opacity: 0.7;
  margin-top: 2px;
  letter-spacing: 1px;
}

/* Advanced System Status HUD — Top Right */
.sys-hud {
  position: absolute;
  top: 28px;
  right: 36px;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 16px;
  font-family: var(--font-display);
  animation: fadeIn 1.5s ease forwards;
  animation-delay: 1.5s;
  opacity: 0;
}

.sys-hud-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Animated SVG orbital ring */
.sys-hud-orb {
  width: 36px;
  height: 36px;
  position: relative;
  flex-shrink: 0;
}

.sys-hud-ring {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
  filter: drop-shadow(0 0 4px var(--success));
}

.sys-hud-ring-fill {
  transition: stroke-dashoffset 1s ease, stroke 0.5s ease;
}

.sys-hud-orb-dot {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  transform: translate(-50%, -50%);
  box-shadow: 0 0 8px var(--success), 0 0 16px rgba(0, 230, 118, 0.3);
  animation: orbPulse 2s ease-in-out infinite;
}

@keyframes orbPulse {

  0%,
  100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }

  50% {
    transform: translate(-50%, -50%) scale(1.3);
    opacity: 0.7;
  }
}

/* Info section */
.sys-hud-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.sys-hud-label {
  font-size: 9px;
  letter-spacing: 2.5px;
  color: rgba(255, 255, 255, 0.5);
  display: flex;
  align-items: center;
  gap: 6px;
}

.sys-hud-status {
  color: var(--success);
  font-weight: 700;
  font-size: 9px;
  text-shadow: 0 0 6px rgba(0, 230, 118, 0.4);
  transition: color 0.5s, text-shadow 0.5s;
}

.sys-hud-status.warning {
  color: #ffab00;
  text-shadow: 0 0 6px rgba(255, 171, 0, 0.4);
}

/* Live metrics row */
.sys-hud-metrics {
  display: flex;
  align-items: center;
  gap: 5px;
}

.sys-metric {
  font-size: 8px;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.35);
  transition: color 0.3s;
}

.sys-metric b {
  color: rgba(255, 255, 255, 0.7);
  font-weight: 700;
  transition: color 0.3s;
}

.sys-metric-sep {
  color: rgba(255, 255, 255, 0.15);
  font-size: 10px;
}

/* Signal ring + latency */
.sys-hud-signal {
  display: flex;
  align-items: center;
  gap: 6px;
  padding-left: 14px;
  border-left: 1px solid rgba(255, 255, 255, 0.06);
}

.sys-signal-ring {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1.5px solid var(--success);
  position: relative;
  animation: signalPing 3s ease-in-out infinite;
}

.sys-signal-ring::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid var(--success);
  opacity: 0;
  animation: signalExpand 3s ease-out infinite;
}

@keyframes signalPing {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.6;
    transform: scale(0.85);
  }
}

@keyframes signalExpand {
  0% {
    transform: scale(1);
    opacity: 0.6;
  }

  100% {
    transform: scale(2.2);
    opacity: 0;
  }
}

.sys-latency {
  font-size: 10px;
  font-weight: 700;
  color: var(--success);
  letter-spacing: 1px;
  min-width: 28px;
  text-shadow: 0 0 5px rgba(0, 230, 118, 0.3);
  transition: color 0.3s, text-shadow 0.3s;
}

/* Upgraded System HUD — Additional Styles */
.sys-hud-orb {
  width: 44px;
  height: 44px;
}

.sys-hud-ring-inner {
  transition: stroke-dashoffset 1.2s ease, stroke 0.5s ease;
  animation: innerRingSpin 8s linear infinite;
}

@keyframes innerRingSpin {
  from {
    transform: rotate(0deg);
    transform-origin: center;
  }

  to {
    transform: rotate(360deg);
    transform-origin: center;
  }
}

/* Uptime row */
.sys-hud-uptime {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
}

.sys-uptime-label {
  font-size: 7px;
  letter-spacing: 1.5px;
  color: rgba(255, 255, 255, 0.25);
}

.sys-uptime-val {
  font-size: 8px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.5);
  font-family: monospace;
  letter-spacing: 0.5px;
}

.sys-sparkline {
  width: 60px;
  height: 16px;
  overflow: visible;
}

.sys-sparkline polyline {
  filter: drop-shadow(0 0 2px var(--success));
}

/* Right section (shield + signal) */
.sys-hud-right {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-left: 14px;
  border-left: 1px solid rgba(255, 255, 255, 0.06);
}

/* Shield icon with sweep */
.sys-hud-shield {
  position: relative;
  width: 22px;
  height: 24px;
}

.sys-shield-icon {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 4px var(--success));
}

.sys-shield-sweep {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, rgba(0, 230, 118, 0.3), transparent);
  clip-path: polygon(50% 0%, 100% 0%, 100% 100%, 0% 100%, 0% 0%);
  animation: shieldSweep 3s linear infinite;
  opacity: 0.5;
}

@keyframes shieldSweep {
  0% {
    clip-path: polygon(50% 50%, 50% 0%, 50% 0%, 50% 0%, 50% 0%);
  }

  25% {
    clip-path: polygon(50% 50%, 50% 0%, 100% 0%, 100% 50%, 50% 50%);
  }

  50% {
    clip-path: polygon(50% 50%, 50% 0%, 100% 0%, 100% 100%, 50% 100%);
  }

  75% {
    clip-path: polygon(50% 50%, 50% 0%, 100% 0%, 100% 100%, 0% 100%, 0% 50%);
  }

  100% {
    clip-path: polygon(50% 50%, 50% 0%, 100% 0%, 100% 100%, 0% 100%, 0% 0%);
  }
}

/* Life Support & Env */
.life-support {
  position: absolute;
  left: 40px;
  bottom: 40px;
  z-index: 50;
  display: flex;
  gap: 20px;
  background: rgba(0, 0, 0, 0.3);
  padding: 10px 20px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  font-family: var(--font-display);
  font-size: 10px;
  color: #aaa;
}

.ls-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.ls-item i {
  width: 14px;
  color: var(--secondary);
}

/* Ambient Data Flow Container */
.ambient-data-flow {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 600px;
  height: 800px;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 5;
  border-radius: 40px;
  overflow: hidden;
  mask-image: radial-gradient(ellipse at center, transparent 40%, black 100%);
  -webkit-mask-image: radial-gradient(ellipse at center, transparent 40%, black 100%);
}

.data-stream {
  position: absolute;
  width: 1px;
  height: 100px;
  background: linear-gradient(to bottom, transparent, var(--primary), transparent);
  opacity: 0;
}

@keyframes streamDrop {
  0% {
    transform: translateY(-200px);
    opacity: 0;
  }

  10% {
    opacity: 0.5;
  }

  90% {
    opacity: 0.5;
  }

  100% {
    transform: translateY(1000px);
    opacity: 0;
  }
}

/* Glitch removed */

/* Hexagon Particle Field */
.hex-grid {
  position: absolute;
  inset: -100px;
  background-image: url('data:image/svg+xml,%3Csvg width="40" height="40" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg"%3E%3Cpath stroke="rgba(255,255,255,0.03)" stroke-width="1" fill="none" d="M50 0L93.3 25v50L50 100L6.7 75V25z" /%3E%3C/svg%3E');
  background-size: 80px 80px;
  animation: bgPan 40s linear infinite;
  z-index: 2;
  pointer-events: none;
  opacity: 0.6;
}

@keyframes bgPan {
  0% {
    transform: translateY(0);
  }

  100% {
    transform: translateY(100px);
  }
}

/* Digital Cursor Trail */
.cursor-trail {
  position: fixed;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  border: 1px solid var(--primary);
  pointer-events: none;
  transform: translate(-50%, -50%);
  z-index: 9999;
  transition: width 0.3s, height 0.3s, opacity 0.5s;
  animation: trailPulse 0.5s ease-out forwards;
}

@keyframes trailPulse {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.8;
  }

  100% {
    transform: translate(-50%, -50%) scale(2);
    opacity: 0;
  }
}



/* Overlays */
.overlay {
  position: relative;
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  z-index: 10;
  display: flex;
  justify-content: center;
  align-items: center;
  pointer-events: none;
  padding: 20px 0;
}

.login-container {
  pointer-events: auto;
  background: transparent;
  border: none;
  border-radius: 28px;
  padding: 50px 40px;
  width: 90%;
  max-width: 420px;
  position: relative;
  overflow: hidden;
  animation: formFloat 10s ease-in-out infinite, formAppear 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  opacity: 0;
  transform: perspective(1000px) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg)) translateY(20px) scale(0.95);
  transition: filter 0.3s ease;
  transform-style: preserve-3d;
  flex-shrink: 0;
}

/* Liquid glass shadow layer — matching 21st.dev component's complex inset shadows */
.liquid-glass-shadow {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  border-radius: 28px;
  pointer-events: none;
  box-shadow:
    0 0 8px rgba(0, 0, 0, 0.03),
    0 2px 6px rgba(0, 0, 0, 0.08),
    inset 3px 3px 0.5px -3.5px rgba(255, 255, 255, 0.09),
    inset -3px -3px 0.5px -3.5px rgba(255, 255, 255, 0.85),
    inset 1px 1px 1px -0.5px rgba(255, 255, 255, 0.6),
    inset -1px -1px 1px -0.5px rgba(255, 255, 255, 0.6),
    inset 0 0 6px 6px rgba(255, 255, 255, 0.12),
    inset 0 0 2px 2px rgba(255, 255, 255, 0.06),
    0 0 12px rgba(0, 0, 0, 0.15);
  transition: box-shadow 0.3s ease;
}

/* Liquid glass backdrop — SVG filter for the liquid distortion refraction */
.liquid-glass-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  isolation: isolate;
  overflow: hidden;
  border-radius: 28px;
  -webkit-backdrop-filter: url(#liquid-glass);
  backdrop-filter: url(#liquid-glass);
}

.login-container:hover {
  filter: brightness(1.1);
}

.login-container:hover .liquid-glass-shadow {
  box-shadow:
    0 0 8px rgba(0, 0, 0, 0.03),
    0 4px 12px rgba(0, 0, 0, 0.12),
    inset 3px 3px 0.5px -3.5px rgba(255, 255, 255, 0.12),
    inset -3px -3px 0.5px -3.5px rgba(255, 255, 255, 0.9),
    inset 1px 1px 1px -0.5px rgba(255, 255, 255, 0.7),
    inset -1px -1px 1px -0.5px rgba(255, 255, 255, 0.7),
    inset 0 0 8px 8px rgba(255, 255, 255, 0.15),
    inset 0 0 3px 3px rgba(255, 255, 255, 0.08),
    0 0 20px rgba(255, 255, 255, 0.1);
}

.login-container.shake {
  animation: shake 0.5s cubic-bezier(.36, .07, .19, .97) both;
}

@keyframes formAppear {
  to {
    opacity: 1;
    transform: perspective(1000px) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg)) translateY(0) scale(1);
  }
}

@keyframes formFloat {

  0%,
  100% {
    transform: perspective(1000px) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg)) translateY(0);
  }

  50% {
    transform: perspective(1000px) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg)) translateY(-15px);
  }
}

@keyframes shake {

  10%,
  90% {
    transform: translate3d(-2px, 0, 0);
  }

  20%,
  80% {
    transform: translate3d(4px, 0, 0);
  }

  30%,
  50%,
  70% {
    transform: translate3d(-8px, 0, 0);
  }

  40%,
  60% {
    transform: translate3d(8px, 0, 0);
  }
}

/* Cursor-following light on hover */
.login-container::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(500px circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
      rgba(255, 255, 255, 0.08), transparent 40%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
  z-index: 1;
  mix-blend-mode: overlay;
  border-radius: 28px;
}

.login-container:hover::after {
  opacity: 1;
}

.login-container.authorized {
  animation: authPulse 0.8s ease-in-out;
}

@keyframes authPulse {

  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.6), inset 0 0 20px rgba(255, 255, 255, 0.05);
  }

  50% {
    transform: scale(1.05);
    box-shadow: 0 0 100px var(--primary), inset 0 0 50px var(--glass-border);
    border-color: var(--primary);
  }
}

.scanline {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 20%;
  background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.1), transparent);
  opacity: 0;
  animation: scan 4s linear infinite;
  pointer-events: none;
}

@keyframes scan {
  0% {
    top: -20%;
    opacity: 0;
  }

  10% {
    opacity: 1;
  }

  90% {
    opacity: 1;
  }

  100% {
    top: 120%;
    opacity: 0;
  }
}

/* Hyperspace sequence replaced in Backgrounds section to maintain structure */

/* Shared view utilities */
.view {
  display: none;
}

.view.active {
  display: block;
  animation: fadeIn 0.4s ease forwards;
}

.hidden {
  display: none !important;
}

/* Text */
h1 {
  margin: 0 0 5px;
  font-size: 32px;
  font-weight: 900;
  font-family: var(--font-display);
  text-align: center;
  letter-spacing: 4px;
  text-transform: uppercase;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

p.subtitle {
  text-align: center;
  color: #666;
  font-size: 13px;
  margin-bottom: 25px;
  letter-spacing: 2px;
  font-family: var(--font-display);
  text-transform: uppercase;
}

.ai-greeting {
  height: 16px;
  font-family: monospace;
  font-size: 11px;
  color: var(--primary);
  text-align: center;
  margin-bottom: 30px;
}

.ai-cursor {
  display: inline-block;
  width: 6px;
  height: 12px;
  background: var(--primary);
  margin-left: 2px;
  animation: blink 1s step-end infinite;
  vertical-align: middle;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

/* Inputs */
.input-group {
  margin-bottom: 22px;
  position: relative;
}

.input-group input {
  width: 100%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-top-color: rgba(255, 255, 255, 0.25);
  border-radius: 14px;
  padding: 18px 50px 18px 50px;
  color: white;
  font-size: 16px;
  outline: none;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  font-family: var(--font-body);
  backdrop-filter: blur(10px);
}

.input-group input:focus {
  border-color: rgba(255, 255, 255, 0.35);
  border-top-color: rgba(255, 255, 255, 0.5);
  box-shadow: 0 0 25px rgba(255, 255, 255, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.2), inset 0 0 15px rgba(255, 255, 255, 0.04);
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.input-group input.error {
  border-color: var(--error);
  box-shadow: 0 0 15px rgba(255, 23, 68, 0.2);
}

.input-group input.success {
  border-color: var(--success);
}

.input-icon {
  position: absolute;
  left: 18px;
  top: 18px;
  color: #555;
  transition: color 0.3s, filter 0.3s;
  width: 20px;
  height: 20px;
}

.input-group input:focus+.input-icon,
.input-group input:not(:placeholder-shown)+.input-icon {
  color: var(--primary);
  filter: drop-shadow(0 0 5px var(--primary));
}

.error-msg {
  color: var(--error);
  font-size: 11px;
  margin-top: 6px;
  font-family: var(--font-display);
  letter-spacing: 1px;
  opacity: 0;
  height: 0;
  overflow: hidden;
  transition: all 0.3s;
}

.error-msg.visible {
  opacity: 1;
  height: 16px;
}

.quantum-prediction {
  position: absolute;
  top: 18px;
  left: 50px;
  pointer-events: none;
  font-family: var(--font-body);
  font-size: 16px;
  color: rgba(255, 255, 255, 0.2);
  white-space: nowrap;
  overflow: hidden;
  z-index: 10;
}

.pass-toggle {
  position: absolute;
  right: 50px;
  top: 20px;
  background: none;
  border: none;
  color: #444;
  cursor: pointer;
  transition: color 0.3s;
  padding: 0;
}

.pass-toggle:hover {
  color: rgba(255, 255, 255, 0.7);
}

.biometric-btn {
  position: absolute;
  right: 15px;
  top: 18px;
  color: #444;
  cursor: pointer;
  transition: all 0.3s;
  background: none;
  border: none;
  padding: 0;
}

.biometric-btn:hover {
  color: rgba(255, 255, 255, 0.8);
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.5));
}

/* Password Strength */
.strength-bar {
  display: flex;
  gap: 4px;
  margin-top: 10px;
  height: 4px;
}

.strength-seg {
  flex: 1;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  transition: background 0.3s;
}

.strength-seg.s1 {
  background: var(--error);
  box-shadow: 0 0 8px var(--error);
}

.strength-seg.s2 {
  background: #ff9100;
  box-shadow: 0 0 8px #ff9100;
}

.strength-seg.s3 {
  background: #ffeb3b;
  box-shadow: 0 0 8px #ffeb3b;
}

.strength-seg.s4 {
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
}

.strength-label {
  font-size: 10px;
  font-family: var(--font-display);
  letter-spacing: 1px;
  margin-top: 6px;
  text-align: right;
  transition: color 0.3s;
}

/* Remember Toggle */
.remember-row {
  margin-bottom: 25px;
}

.remember-label {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  font-family: var(--font-display);
  letter-spacing: 1px;
  color: #aaa;
  cursor: pointer;
  user-select: none;
  transition: color 0.3s;
}

.remember-label:hover {
  color: white;
}

.toggle-track {
  width: 36px;
  height: 20px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  position: relative;
  transition: all 0.3s;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.toggle-track.on {
  background: rgba(255, 255, 255, 0.2);
  border-color: var(--primary);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.1);
}

.toggle-thumb {
  width: 14px;
  height: 14px;
  background: #666;
  border-radius: 50%;
  position: absolute;
  top: 2px;
  left: 2px;
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.toggle-track.on .toggle-thumb {
  left: 18px;
  background: var(--primary);
  box-shadow: 0 0 8px var(--primary);
}

/* Buttons */
.btn-primary {
  width: 100%;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-top-color: rgba(255, 255, 255, 0.35);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
  color: white;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 2px;
  font-family: var(--font-display);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s, background 0.3s, border-color 0.3s;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  z-index: 1;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: -1;
  background: linear-gradient(45deg, var(--primary), var(--secondary));
  opacity: 0;
  transition: opacity 0.3s;
  border-radius: 12px;
}

.btn-primary::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
  transform: skewX(-20deg);
  transition: none;
  z-index: -1;
}

.btn-primary:hover::after {
  animation: btnShine 0.8s ease;
}

@keyframes btnShine {
  100% {
    left: 200%;
  }
}

.btn-primary:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3), 0 0 20px var(--glass-border);
  border-color: transparent;
}

.btn-primary:hover::before {
  opacity: 0.8;
}

.btn-primary:active {
  transform: translateY(2px) scale(0.98);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

.btn-primary:disabled::before {
  opacity: 0;
}

/* Threat Bar */
.threat-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 25px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.threat-icon {
  color: var(--success);
  transition: color 0.3s;
}

.threat-bar.alert .threat-icon {
  color: var(--error);
  animation: blink 1s infinite;
}

.threat-text {
  font-family: var(--font-display);
  font-size: 10px;
  letter-spacing: 1px;
  color: #888;
  flex: 1;
}

.threat-dots {
  display: flex;
  gap: 3px;
}

.threat-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  transition: background 0.3s, box-shadow 0.3s;
}

.threat-dot.active {
  background: var(--success);
  box-shadow: 0 0 5px var(--success);
}

.threat-bar.alert .threat-dot.active {
  background: var(--error);
  box-shadow: 0 0 5px var(--error);
}

.threat-level {
  font-family: var(--font-display);
  font-size: 10px;
  letter-spacing: 1px;
  color: var(--success);
  font-weight: bold;
  width: 40px;
  text-align: right;
}

.threat-bar.alert .threat-level {
  color: var(--error);
}

/* Aux */
.aux-actions {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
}

.aux-actions a {
  color: #666;
  text-decoration: none;
  transition: color 0.3s, text-shadow 0.3s;
  display: flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  font-size: 12px;
  font-family: var(--font-body);
}

.aux-actions a:hover {
  color: var(--primary);
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.4);
}

.shortcut-badge {
  background: rgba(255, 255, 255, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 9px;
  font-family: var(--font-display);
  margin-left: 5px;
}

/* 2FA view */
.otp-view {
  text-align: center;
}

.otp-title {
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: 2px;
  margin-bottom: 10px;
}

.otp-sub {
  color: #888;
  font-size: 13px;
  margin-bottom: 30px;
}

.otp-grid {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 25px;
}

.otp-digit {
  width: 45px;
  height: 55px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  text-align: center;
  font-size: 24px;
  color: white;
  font-family: var(--font-display);
  outline: none;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.otp-digit:focus {
  border-color: var(--primary);
  box-shadow: 0 0 25px var(--glass-border);
  transform: scale(1.1);
  background: rgba(255, 255, 255, 0.05);
}

.otp-digit.filled {
  border-color: var(--primary);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 10px var(--glass-border);
  text-shadow: 0 0 10px var(--primary);
}

.otp-resend {
  background: none;
  border: none;
  color: var(--primary);
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 1.5px;
  cursor: pointer;
  opacity: 0.8;
  transition: opacity 0.3s;
  margin-top: 10px;
}

.otp-resend:hover:not(:disabled) {
  opacity: 1;
  text-shadow: 0 0 8px var(--primary);
}

.otp-resend:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.otp-timer {
  font-size: 11px;
  color: #555;
  margin-top: 15px;
}

.dna-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-bottom: 30px;
}

.dna-pair {
  display: flex;
  align-items: center;
  animation: dnaTwist 3s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.dna-dot {
  width: 10px;
  height: 10px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.dna-line {
  width: 80px;
  height: 2px;
  background: rgba(255, 255, 255, 0.1);
  transition: all 0.5s ease-out;
  position: relative;
  overflow: hidden;
}

.dna-line::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.dna-dot.matched {
  background: var(--primary);
  box-shadow: 0 0 15px var(--primary), 0 0 5px white;
  transform: scale(1.3);
}

.dna-line.matched {
  background: rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
}

.dna-line.matched::after {
  opacity: 1;
  animation: dnaEnergy 1.5s linear infinite;
}

@keyframes dnaEnergy {
  0% {
    left: -100%;
  }

  100% {
    left: 200%;
  }
}

@keyframes dnaTwist {
  0% {
    transform: rotateY(0deg);
  }

  100% {
    transform: rotateY(360deg);
  }
}

/* Success View */
.success-screen {
  text-align: center;
}

.success-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 3px solid var(--success);
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0 auto 20px;
  box-shadow: 0 0 30px rgba(0, 230, 118, 0.3);
  animation: successPop 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes successPop {
  from {
    transform: scale(0.5);
    opacity: 0;
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}

.success-title {
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: 3px;
  margin-bottom: 20px;
  color: var(--success);
}

.holo-card {
  perspective: 1000px;
  margin-top: 20px;
}

.holo-card-inner {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0.05));
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 25px;
  position: relative;
  overflow: hidden;
  transform-style: preserve-3d;
  animation: floatCard 4s ease-in-out infinite alternate;
  backdrop-filter: blur(8px);
  box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.05);
}

.holo-card-inner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transform: skewX(-20deg) translateX(-150%);
  animation: holoShine 3s infinite;
}

@keyframes holoShine {
  to {
    transform: skewX(-20deg) translateX(150%);
  }
}

@keyframes floatCard {
  from {
    transform: rotateX(5deg) rotateY(-5deg);
    box-shadow: -15px 15px 30px rgba(0, 0, 0, 0.4), 0 0 20px var(--glass-border);
  }

  to {
    transform: rotateX(-5deg) rotateY(5deg);
    box-shadow: 15px -15px 30px rgba(0, 0, 0, 0.4), 0 0 20px var(--glass-border);
  }
}

.holo-header {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: #aaa;
  font-family: var(--font-display);
  margin-bottom: 15px;
}

.holo-name {
  font-size: 24px;
  font-weight: 900;
  letter-spacing: 2px;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
  margin-bottom: 5px;
  text-align: left;
}

.holo-id {
  font-size: 11px;
  color: #888;
  text-align: left;
  font-family: monospace;
  margin-bottom: 25px;
}

.holo-stats {
  display: flex;
  justify-content: space-between;
}

.holo-stat {
  text-align: center;
}

.holo-stat-val {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: bold;
  color: var(--primary);
}

.holo-stat-lbl {
  font-size: 9px;
  color: #666;
  margin-top: 4px;
  letter-spacing: 1px;
}

/* System Panel */
.sys-panel {
  margin-top: 25px;
  text-align: left;
}

.sys-row {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 8px;
  font-family: var(--font-display);
  font-size: 11px;
}

.sys-label {
  width: 40px;
  color: #aaa;
}

.sys-bar-bg {
  flex: 1;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.sys-bar-fill {
  height: 100%;
  background: var(--primary);
  transition: width 1s ease;
}

.sys-val {
  width: 35px;
  text-align: right;
  color: white;
}

/* Modals */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
  z-index: 100;
  display: flex;
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.3s ease;
}

.modal-panel {
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  padding: 40px;
  width: 420px;
  text-align: center;
  position: relative;
  animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
  from {
    transform: translateY(30px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 18px;
  background: none;
  border: none;
  color: #666;
  cursor: pointer;
  transition: color 0.3s;
  padding: 5px;
}

.modal-close:hover {
  color: white;
}

.modal-title {
  font-family: var(--font-display);
  font-size: 18px;
  letter-spacing: 3px;
  margin-bottom: 25px;
  font-weight: 700;
  text-transform: uppercase;
}

.modal-input {
  width: 100%;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 14px 16px;
  color: white;
  font-size: 14px;
  outline: none;
  transition: all 0.3s;
  font-family: var(--font-body);
  margin-bottom: 15px;
}

.modal-input:focus {
  border-color: rgba(255, 255, 255, 0.4);
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.08);
}

.modal-btn {
  width: 100%;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  color: white;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 2px;
  font-family: var(--font-display);
  cursor: pointer;
  transition: all 0.3s;
  margin-top: 5px;
}

.modal-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.15);
  box-shadow: 0 5px 20px rgba(255, 255, 255, 0.1);
}

/* Bio Ring */
.bio-ring {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.15);
  margin: 0 auto 25px;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.5);
}

.bio-ring.scanning {
  border-color: rgba(255, 255, 255, 0.4);
  animation: pulse-ring 1.5s ease-in-out infinite;
}

.bio-ring.success {
  border-color: var(--success);
  box-shadow: 0 0 30px rgba(0, 230, 118, 0.3);
}

@keyframes pulse-ring {

  0%,
  100% {
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.1);
  }

  50% {
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.3);
  }
}

.bio-scan-line {
  position: absolute;
  left: 10%;
  width: 80%;
  height: 2px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 2px;
  animation: scanBio 2s ease-in-out infinite;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.6);
  display: none;
}

.bio-ring.scanning .bio-scan-line {
  display: block;
}

@keyframes scanBio {
  0% {
    top: 15%;
  }

  50% {
    top: 80%;
  }

  100% {
    top: 15%;
  }
}

.bio-status {
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 2px;
  color: #888;
  margin-top: 10px;
}

.bio-status.ok {
  color: var(--success);
}

/* Toasts */
.toast-container {
  position: fixed;
  top: 30px;
  right: 30px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  background: rgba(15, 15, 20, 0.8);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 14px;
  padding: 16px 24px;
  min-width: 280px;
  font-family: var(--font-body);
  font-size: 14px;
  animation: toastIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  gap: 12px;
  pointer-events: auto;
}

.toast.success {
  border-left: 3px solid var(--success);
}

.toast.error {
  border-left: 3px solid var(--error);
}

.toast.fadeOut {
  animation: toastOut 0.4s ease forwards;
}

@keyframes toastIn {
  from {
    transform: translateX(100px);
    opacity: 0;
  }

  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes toastOut {
  to {
    transform: translateX(100px);
    opacity: 0;
  }
}

.toast-close {
  margin-left: auto;
  background: none;
  border: none;
  color: #666;
  cursor: pointer;
  padding: 0;
  transition: color 0.3s;
}

.toast-close:hover {
  color: white;
}

/* Floating Buttons */
.floating-actions {
  position: fixed;
  bottom: 30px;
  right: 30px;
  display: flex;
  gap: 15px;
  z-index: 50;
}

.float-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #888;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  backdrop-filter: blur(5px);
  transition: all 0.3s;
}

.float-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: white;
  transform: scale(1.1);
}

.float-btn.active {
  color: var(--primary);
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.1);
}

.theme-wrapper {
  position: relative;
}

.theme-menu {
  position: absolute;
  bottom: 60px;
  right: 0;
  background: rgba(10, 10, 15, 0.9);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 160px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.theme-wrapper:hover .theme-menu,
.theme-menu.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.voice-transcript {
  position: absolute;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(10px);
  padding: 15px 30px;
  border-radius: 30px;
  border: 1px solid var(--primary);
  color: var(--primary);
  font-family: var(--font-display);
  font-size: 14px;
  letter-spacing: 2px;
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
  z-index: 100;
  white-space: nowrap;
  animation: fadeIn 0.3s ease;
}

.theme-opt {
  background: none;
  border: none;
  padding: 10px 15px;
  color: #aaa;
  font-family: var(--font-display);
  font-size: 11px;
  letter-spacing: 1px;
  text-align: left;
  cursor: pointer;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.2s;
}

.theme-opt:hover {
  background: rgba(255, 255, 255, 0.05);
  color: white;
}

.theme-opt.active {
  color: white;
  background: rgba(255, 255, 255, 0.1);
}

.theme-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.voice-btn.listening {
  color: var(--error);
  border-color: var(--error);
  animation: pulse-ring 1.5s infinite;
}

.voice-transcript {
  position: fixed;
  bottom: 90px;
  right: 30px;
  background: rgba(0, 0, 0, 0.8);
  border: 1px solid var(--primary);
  padding: 10px 20px;
  border-radius: 12px;
  font-family: monospace;
  color: var(--primary);
  z-index: 50;
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
}

/* Command Palette */
.cmd-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 150;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 15vh;
}

.cmd-box {
  background: rgba(20, 20, 25, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  width: 500px;
  max-width: 90vw;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  transform: translateY(-20px);
  animation: fadeInDown 0.2s ease forwards;
}

@keyframes fadeInDown {
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.cmd-input {
  width: 100%;
  padding: 20px 25px;
  background: none;
  border: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: white;
  font-size: 18px;
  outline: none;
  font-family: var(--font-body);
}

.cmd-results {
  max-height: 300px;
  overflow-y: auto;
  padding: 10px;
}

.cmd-item {
  padding: 12px 15px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 15px;
  color: #aaa;
  transition: all 0.2s;
  font-family: var(--font-body);
  font-size: 14px;
}

.cmd-item.selected,
.cmd-item:hover {
  background: rgba(255, 255, 255, 0.1);
  color: white;
}

.cmd-item-key {
  margin-left: auto;
  font-size: 10px;
  font-family: monospace;
  background: rgba(255, 255, 255, 0.1);
  padding: 3px 6px;
  border-radius: 4px;
}

.cmd-ite.form-header p {
  color: var(--text-muted);
  font-size: 14px;
  font-family: monospace;
}

/* Threat Level Analysis */
.threat-level {
  margin-bottom: 20px;
}

.tl-label {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 2px;
  margin-bottom: 5px;
}

#tl-eval {
  color: var(--primary);
}

.tl-bar-bg {
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
  position: relative;
}

.tl-bar-fill {
  height: 100%;
  width: 0%;
  background: var(--primary);
  box-shadow: 0 0 10px var(--primary);
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.5s;
}

.input-group {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
}

/* Boot Sequence */
.boot-overlay {
  position: fixed;
  inset: 0;
  background: var(--dark);
  z-index: 999;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transition: opacity 0.8s;
}

.boot-overlay.done {
  opacity: 0;
  pointer-events: none;
}

.boot-hex {
  position: absolute;
  inset: 0;
  color: rgba(255, 255, 255, 0.03);
  font-family: monospace;
  font-size: 12px;
  line-height: 1.2;
  overflow: hidden;
  white-space: pre;
  pointer-events: none;
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  padding: 20px;
}

.boot-title {
  font-family: var(--font-display);
  font-size: 32px;
  letter-spacing: 10px;
  margin-bottom: 40px;
  color: white;
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.5), 0 0 60px rgba(255, 255, 255, 0.2);
  z-index: 2;
  animation: bootGlow 2s ease-in-out infinite alternate;
}

@keyframes bootGlow {
  from {
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.5), 0 0 60px rgba(255, 255, 255, 0.2);
  }

  to {
    text-shadow: 0 0 30px rgba(255, 255, 255, 0.8), 0 0 80px rgba(255, 255, 255, 0.4), 0 0 120px rgba(255, 255, 255, 0.1);
  }
}

.boot-progress {
  width: 300px;
  height: 2px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 1px;
  position: relative;
  overflow: hidden;
  z-index: 2;
}

.boot-progress-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: white;
  width: 0%;
  transition: width 0.3s linear;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

.boot-log {
  font-family: monospace;
  font-size: 12px;
  color: #888;
  margin-top: 20px;
  height: 16px;
  z-index: 2;
  letter-spacing: 1px;
}

.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
  box-sizing: border-box;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.enc-viz {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 15px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 12px;
  margin-bottom: 20px;
  justify-content: center;
}

.enc-cell {
  width: 30px;
  height: 30px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: monospace;
  font-size: 12px;
  color: #555;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  transition: all 0.2s;
}

.enc-cell.locked {
  color: var(--primary);
  background: rgba(255, 255, 255, 0.1);
  text-shadow: 0 0 5px var(--primary);
  box-shadow: inset 0 0 10px rgba(255, 255, 255, 0.05);
}

/* Ripple */
.ripple {
  position: absolute;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.4);
  transform: scale(0);
  animation: rippleEffect 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
  z-index: 9999;
}

@keyframes rippleEffect {
  to {
    transform: scale(2);
    opacity: 0;
  }
}

/* Particle Burst */
.particle {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  z-index: 900;
  animation: particleOut ease-out forwards;
}

@keyframes particleOut {
  0% {
    opacity: 1;
    transform: scale(1);
  }

  100% {
    opacity: 0;
    transform: scale(0);
  }
}


/* Advanced Registration Flow CSS */
.reg-step {
  animation: fadeIn 0.4s ease forwards;
}

.dna-seq-container {
  margin: 30px 0;
}

.dna-seq-bar {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 12px;
  position: relative;
}

.dna-seq-fill {
  height: 100%;
  width: 0%;
  background: var(--primary);
  box-shadow: 0 0 10px var(--primary);
  transition: width 0.2s ease-out;
}

.dna-seq-status {
  font-family: var(--font-display);
  font-size: 11px;
  color: var(--primary);
  text-align: center;
  letter-spacing: 1px;
}

.neural-cal-visual {
  position: relative;
  width: 120px;
  height: 120px;
  margin: 30px auto;
  display: flex;
  justify-content: center;
  align-items: center;
}

.cal-ring {
  position: absolute;
  inset: 0;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  animation: spin 10s linear infinite;
  transition: border-color 0.5s, box-shadow 0.5s;
}

.cal-ring.ring-2 {
  inset: 15px;
  animation-duration: 7s;
  animation-direction: reverse;
  border-style: dotted;
}

.cal-ring.ring-3 {
  inset: 30px;
  animation-duration: 4s;
}

.cal-ring.synced {
  border-color: var(--primary);
  border-style: solid;
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.2) inset;
}

.cal-icon {
  width: 40px;
  height: 40px;
  color: #555;
  transition: color 0.5s;
}

.cal-status {
  text-align: center;
  font-family: monospace;
  font-size: 12px;
  color: var(--secondary);
  letter-spacing: 1px;
}

/* ===== CREATIVE FEATURE 1: Holographic Focus Ring ===== */
/* ===== HYPERSPACE WARP TRANSITION — ENHANCED ===== */
.warp-overlay {
  position: fixed;
  inset: 0;
  z-index: 8000;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  perspective: 800px;
  background: radial-gradient(circle at center, transparent 30%, rgba(0, 0, 0, 0.4) 100%);
}

.warp-overlay.active {
  opacity: 1;
  pointer-events: all;
}

/* Tunnel vignette — closes in during warp */
.warp-tunnel {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0) 20%, rgba(0, 0, 0, 0.7) 100%);
  opacity: 0;
}

.warp-overlay.active .warp-tunnel {
  animation: warpTunnel 4s cubic-bezier(0.25, 0.1, 0.25, 1) forwards;
}

@keyframes warpTunnel {
  0% {
    opacity: 0;
    background: radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0) 40%, rgba(0, 0, 0, 0.3) 100%);
  }

  30% {
    opacity: 1;
    background: radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0) 25%, rgba(0, 0, 0, 0.8) 100%);
  }

  70% {
    opacity: 1;
    background: radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0) 10%, rgba(0, 0, 0, 0.95) 100%);
  }

  85% {
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

/* White flash — two-stage: mid-jump flicker + final bright burst */
.warp-flash {
  position: absolute;
  inset: 0;
  background: white;
  opacity: 0;
  z-index: 4;
}

.warp-overlay.active .warp-flash {
  animation: warpFlash 4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes warpFlash {
  0% {
    opacity: 0;
  }

  35% {
    opacity: 0;
  }

  42% {
    opacity: 0.5;
  }

  48% {
    opacity: 0;
  }

  82% {
    opacity: 0;
  }

  90% {
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

/* Speed lines — longer, more varied */
.warp-lines {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
}

.warp-line {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1.5px;
  height: 0;
  background: linear-gradient(to bottom, transparent 0%, rgba(255, 255, 255, 0.3) 20%, rgba(255, 255, 255, 0.9) 80%, white 100%);
  transform-origin: top center;
  animation: warpLineShoot 2s cubic-bezier(0.2, 0, 0, 1) forwards;
}

@keyframes warpLineShoot {
  0% {
    height: 0;
    opacity: 0;
  }

  10% {
    height: 5px;
    opacity: 0.8;
  }

  40% {
    height: 30px;
    opacity: 1;
  }

  100% {
    height: 150vh;
    opacity: 0.15;
  }
}

/* Expanding pulse rings — staggered */
.warp-pulse-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.5);
  transform: translate(-50%, -50%) scale(1);
  opacity: 0;
  z-index: 2;
  pointer-events: none;
}

.warp-overlay.active .warp-pulse-1 {
  animation: pulseRingExpand 2s cubic-bezier(0.2, 0, 0, 1) 0.2s forwards;
}

.warp-overlay.active .warp-pulse-2 {
  animation: pulseRingExpand 2.2s cubic-bezier(0.2, 0, 0, 1) 0.6s forwards;
}

.warp-overlay.active .warp-pulse-3 {
  animation: pulseRingExpand 2.4s cubic-bezier(0.2, 0, 0, 1) 1s forwards;
}

@keyframes pulseRingExpand {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.7;
    border-width: 2px;
  }

  60% {
    opacity: 0.3;
  }

  100% {
    transform: translate(-50%, -50%) scale(80);
    opacity: 0;
    border-width: 0.5px;
  }
}

/* Main text — appears mid-warp */
.warp-text {
  position: relative;
  z-index: 5;
  font-family: var(--font-display);
  font-size: 16px;
  letter-spacing: 8px;
  color: white;
  text-shadow: 0 0 40px rgba(255, 255, 255, 0.9), 0 0 80px rgba(255, 255, 255, 0.3);
  opacity: 0;
  transform: scale(0.7);
}

.warp-overlay.active .warp-text {
  animation: warpTextIn 4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes warpTextIn {
  0% {
    opacity: 0;
    transform: scale(0.5);
    letter-spacing: 3px;
  }

  45% {
    opacity: 0;
    transform: scale(0.5);
  }

  55% {
    opacity: 1;
    transform: scale(1.08);
    letter-spacing: 10px;
  }

  65% {
    opacity: 1;
    transform: scale(1);
    letter-spacing: 8px;
  }

  85% {
    opacity: 1;
    transform: scale(1);
  }

  100% {
    opacity: 0;
    transform: scale(1.5);
    letter-spacing: 20px;
  }
}

/* Sub text — appears slightly after main text */
.warp-sub-text {
  position: relative;
  z-index: 5;
  font-family: var(--font-display);
  font-size: 9px;
  letter-spacing: 4px;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 12px;
  opacity: 0;
}

.warp-overlay.active .warp-sub-text {
  animation: warpSubIn 4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes warpSubIn {

  0%,
  58% {
    opacity: 0;
    transform: translateY(10px);
  }

  68% {
    opacity: 0.7;
    transform: translateY(0);
  }

  85% {
    opacity: 0.7;
  }

  100% {
    opacity: 0;
  }
}

/* Galaxy warp — slow buildup */
.hyperspace-jump canvas {
  animation: galaxyWarp 4s cubic-bezier(0.4, 0, 0.2, 1) forwards !important;
}

@keyframes galaxyWarp {
  0% {
    filter: brightness(1) saturate(1);
    transform: scale(1);
  }

  15% {
    filter: brightness(1.2) saturate(0.8);
    transform: scale(1.02);
  }

  35% {
    filter: brightness(2) saturate(0.3);
    transform: scale(1.08);
  }

  50% {
    filter: brightness(4) saturate(0) blur(3px);
    transform: scale(1.2);
  }

  65% {
    filter: brightness(6) saturate(0) blur(10px);
    transform: scale(1.35);
  }

  80% {
    filter: brightness(0.2) saturate(0) blur(5px);
    transform: scale(1.4);
  }

  90% {
    filter: brightness(0) saturate(0);
    transform: scale(1.5);
  }

  100% {
    filter: brightness(1) saturate(1);
    transform: scale(1);
  }
}

/* Login container — smooth warp zoom out */
.login-container.warping {
  animation: containerWarp 3s cubic-bezier(0.4, 0, 0.2, 1) forwards !important;
}

@keyframes containerWarp {
  0% {
    transform: perspective(1000px) translateZ(0) scale(1);
    opacity: 1;
    filter: blur(0);
  }

  20% {
    transform: perspective(1000px) translateZ(20px) scale(1.01);
    opacity: 1;
    filter: blur(0);
  }

  50% {
    transform: perspective(1000px) translateZ(150px) scale(1.06);
    opacity: 0.8;
    filter: blur(1px);
  }

  75% {
    transform: perspective(1000px) translateZ(500px) scale(1.2);
    opacity: 0.3;
    filter: blur(5px);
  }

  100% {
    transform: perspective(1000px) translateZ(1000px) scale(1.4);
    opacity: 0;
    filter: blur(12px);
  }
}

/* Success view — warp-in from depth */
.view-success-enter {
  animation: successWarpIn 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes successWarpIn {
  0% {
    opacity: 0;
    transform: perspective(1000px) translateZ(-200px) scale(0.8);
    filter: blur(5px);
  }

  100% {
    opacity: 1;
    transform: perspective(1000px) translateZ(0) scale(1);
    filter: blur(0);
  }
}

.input-group input:focus~.holo-ring,
.input-group input:focus-visible~.holo-ring {
  opacity: 1;
}

.holo-ring {
  position: absolute;
  inset: -3px;
  border-radius: 16px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: -1;
}

.holo-ring::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 16px;
  padding: 2px;
  background: conic-gradient(from var(--holo-angle, 0deg),
      #ff006e, #fb5607, #ffbe0b, #00f5d4, #00bbf9, #9b5de5, #ff006e);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  animation: holoSpin 2s linear infinite;
  filter: blur(1px);
}

.holo-ring::after {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 20px;
  background: conic-gradient(from var(--holo-angle, 0deg),
      rgba(255, 0, 110, 0.15), rgba(0, 245, 212, 0.15), rgba(0, 187, 249, 0.15), rgba(255, 0, 110, 0.15));
  filter: blur(12px);
  animation: holoSpin 2s linear infinite;
}

@keyframes holoSpin {
  to {
    --holo-angle: 360deg;
  }
}

@property --holo-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

/* ===== CREATIVE FEATURE 2: Typing Shockwave ===== */
.typing-shockwave {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%) scale(1);
  animation: shockwaveExpand 0.6s ease-out forwards;
  pointer-events: none;
  z-index: 5;
}

@keyframes shockwaveExpand {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.8;
    border-width: 2px;
  }

  100% {
    transform: translate(-50%, -50%) scale(25);
    opacity: 0;
    border-width: 0.5px;
  }
}

/* ===== CREATIVE FEATURE 4: Button Gravitational Pull ===== */
.btn-primary.gravitating {
  box-shadow: 0 0 30px rgba(255, 255, 255, 0.15), inset 0 0 20px rgba(255, 255, 255, 0.05);
}

.btn-shockwave {
  position: fixed;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.4);
  pointer-events: none;
  z-index: 999;
  animation: btnShockwave 0.8s ease-out forwards;
}

@keyframes btnShockwave {
  0% {
    width: 0;
    height: 0;
    opacity: 1;
  }

  100% {
    width: 600px;
    height: 600px;
    opacity: 0;
    margin-left: -300px;
    margin-top: -300px;
  }
}

/* ===== CREATIVE FEATURE 7: Command Palette ===== */
.cmd-palette-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 15vh;
  animation: fadeIn 0.2s ease;
}

.cmd-palette-overlay.hidden {
  display: none;
}

.cmd-palette {
  width: 500px;
  background: rgba(15, 15, 20, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
  animation: cmdSlideIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes cmdSlideIn {
  from {
    transform: translateY(-20px) scale(0.95);
    opacity: 0;
  }

  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

.cmd-input-wrap {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  gap: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.cmd-input-wrap i {
  color: rgba(255, 255, 255, 0.3);
  width: 18px;
  flex-shrink: 0;
}

.cmd-input {
  background: none;
  border: none;
  color: white;
  font-size: 15px;
  font-family: var(--font-body);
  outline: none;
  width: 100%;
}

.cmd-input::placeholder {
  color: rgba(255, 255, 255, 0.25);
}

.cmd-results {
  max-height: 300px;
  overflow-y: auto;
  padding: 8px;
}

.cmd-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.7);
}

.cmd-item:hover,
.cmd-item.active {
  background: rgba(255, 255, 255, 0.08);
  color: white;
}

.cmd-item i {
  color: var(--primary);
  width: 16px;
  flex-shrink: 0;
}

.cmd-item .cmd-shortcut {
  margin-left: auto;
  font-size: 9px;
  padding: 2px 6px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 4px;
  color: rgba(255, 255, 255, 0.3);
  letter-spacing: 0.5px;
}

.cmd-footer {
  padding: 8px 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  gap: 16px;
  font-size: 9px;
  color: rgba(255, 255, 255, 0.2);
  letter-spacing: 1px;
  font-family: var(--font-display);
}

/* ===== CREATIVE FEATURE 8: Screen Edge Glow ===== */
.edge-glow {
  position: fixed;
  pointer-events: none;
  z-index: 2;
}

.edge-glow-top {
  top: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: radial-gradient(ellipse at var(--edge-x, 50%) 0%, rgba(255, 255, 255, 0.06), transparent 70%);
  transition: opacity 0.5s;
}

.edge-glow-bottom {
  bottom: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: radial-gradient(ellipse at var(--edge-x, 50%) 100%, rgba(255, 255, 255, 0.04), transparent 70%);
}

.edge-glow-left {
  top: 0;
  left: 0;
  bottom: 0;
  width: 80px;
  background: radial-gradient(ellipse at 0% var(--edge-y, 50%), rgba(255, 255, 255, 0.04), transparent 70%);
}

.edge-glow-right {
  top: 0;
  right: 0;
  bottom: 0;
  width: 80px;
  background: radial-gradient(ellipse at 100% var(--edge-y, 50%), rgba(255, 255, 255, 0.04), transparent 70%);
}

/* ===== CREATIVE FEATURE 9: Matrix Rain ===== */
.matrix-canvas {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1.5s ease;
}

.matrix-canvas.active {
  opacity: 0.4;
}

/* ===== CREATIVE FEATURE 10: Konami Easter Egg ===== */
.konami-active {
  animation: konamiFlash 0.5s ease;
}

@keyframes konamiFlash {
  0% {
    filter: brightness(1) saturate(1);
  }

  50% {
    filter: brightness(2) saturate(2) hue-rotate(40deg);
  }

  100% {
    filter: brightness(1) saturate(1);
  }
}

.konami-badge {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0);
  font-family: var(--font-display);
  font-size: 28px;
  letter-spacing: 8px;
  color: #ffd700;
  text-shadow: 0 0 30px rgba(255, 215, 0, 0.6), 0 0 60px rgba(255, 215, 0, 0.3);
  z-index: 10000;
  pointer-events: none;
  animation: konamiBadge 2.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes konamiBadge {
  0% {
    transform: translate(-50%, -50%) scale(0) rotate(-10deg);
    opacity: 0;
  }

  20% {
    transform: translate(-50%, -50%) scale(1.2) rotate(2deg);
    opacity: 1;
  }

  30% {
    transform: translate(-50%, -50%) scale(1) rotate(0deg);
  }

  80% {
    opacity: 1;
  }

  100% {
    transform: translate(-50%, -50%) scale(0.8) rotate(-5deg);
    opacity: 0;
  }
}

.konami-supernova #galaxy-container canvas {
  filter: brightness(3) saturate(0) !important;
  transition: filter 0.5s ease;
}

/* ================================================================
   HYPERSPACE WARP TRANSITION — ULTRA-SMOOTH CREATIVE EXPERIENCE
   ================================================================ */

/* --- Warp Overlay Container --- */
.warp-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1),
    visibility 0s linear 0.6s;
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 2000px;
  overflow: hidden;
}

.warp-overlay.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1),
    visibility 0s linear 0s;
}

/* --- Warp Tunnel (Radial Depth Effect) --- */
.warp-tunnel {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at center,
      transparent 0%,
      transparent 15%,
      rgba(100, 180, 255, 0.03) 30%,
      rgba(80, 140, 255, 0.06) 45%,
      rgba(60, 100, 200, 0.1) 60%,
      rgba(20, 40, 80, 0.25) 80%,
      rgba(0, 0, 0, 0.85) 100%);
  opacity: 0;
  transform: scale(0.5);
  transition: none;
}

.warp-overlay.active .warp-tunnel {
  animation: warpTunnelOpen 5.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes warpTunnelOpen {
  0% {
    opacity: 0;
    transform: scale(0.3) rotate(0deg);
  }

  15% {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }

  40% {
    transform: scale(1.05) rotate(2deg);
    background:
      radial-gradient(ellipse at center,
        transparent 0%,
        rgba(150, 200, 255, 0.08) 10%,
        rgba(100, 160, 255, 0.12) 25%,
        rgba(80, 120, 255, 0.15) 40%,
        rgba(40, 60, 180, 0.2) 60%,
        rgba(10, 20, 60, 0.5) 80%,
        rgba(0, 0, 0, 0.95) 100%);
  }

  70% {
    transform: scale(1.2) rotate(-1deg);
  }

  85% {
    transform: scale(2) rotate(0deg);
  }

  100% {
    opacity: 0;
    transform: scale(6) rotate(0deg);
  }
}

/* --- Warp Speed Lines --- */
.warp-lines {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.warp-line {
  position: absolute;
  top: 50%;
  left: 50%;
  height: 0;
  background: linear-gradient(to right,
      transparent 0%,
      rgba(180, 220, 255, 0.1) 10%,
      rgba(200, 230, 255, 0.6) 40%,
      rgba(255, 255, 255, 0.95) 60%,
      rgba(200, 230, 255, 0.6) 80%,
      transparent 100%);
  transform-origin: 0% 50%;
  border-radius: 4px;
  will-change: height, opacity;
  animation: warpLineFly 3s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-fill-mode: both;
}

@keyframes warpLineFly {
  0% {
    height: 0;
    opacity: 0;
    box-shadow: none;
  }

  10% {
    opacity: 0.4;
    height: 5vh;
  }

  30% {
    opacity: 0.8;
    height: 25vh;
    box-shadow: 0 0 8px rgba(180, 220, 255, 0.4);
  }

  60% {
    height: 65vh;
    opacity: 1;
    box-shadow: 0 0 15px rgba(180, 220, 255, 0.6),
      0 0 4px rgba(255, 255, 255, 0.9);
  }

  80% {
    height: 100vh;
    opacity: 0.6;
  }

  100% {
    height: 140vh;
    opacity: 0;
    box-shadow: none;
  }
}

/* --- Warp Flash (White-out with chromatic aberration) --- */
.warp-flash {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center,
      rgba(255, 255, 255, 1) 0%,
      rgba(200, 230, 255, 0.8) 30%,
      rgba(100, 180, 255, 0.3) 60%,
      transparent 100%);
  opacity: 0;
  mix-blend-mode: screen;
  will-change: opacity, transform;
}

.warp-overlay.active .warp-flash {
  animation: warpFlashBurst 5.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes warpFlashBurst {
  0% {
    opacity: 0;
    transform: scale(0.2);
    filter: blur(30px);
  }

  40% {
    opacity: 0;
    transform: scale(0.5);
    filter: blur(20px);
  }

  55% {
    opacity: 0.15;
    transform: scale(0.8);
    filter: blur(10px);
  }

  70% {
    opacity: 0.7;
    transform: scale(1);
    filter: blur(0px);
  }

  82% {
    opacity: 1;
    transform: scale(1.1);
    filter: blur(0px);
  }

  90% {
    opacity: 1;
    transform: scale(1.2);
    filter: blur(0px);
  }

  100% {
    opacity: 0;
    transform: scale(1.5);
    filter: blur(5px);
  }
}

/* --- Warp Pulse Rings (Expanding concentric rings from center) --- */
.warp-pulse-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid rgba(180, 220, 255, 0.6);
  transform: translate(-50%, -50%) scale(0);
  opacity: 0;
  will-change: transform, opacity;
  box-shadow: 0 0 15px rgba(150, 200, 255, 0.3),
    inset 0 0 10px rgba(150, 200, 255, 0.1);
}

.warp-overlay.active .warp-pulse-1 {
  animation: warpPulseExpand 3.5s cubic-bezier(0.16, 1, 0.3, 1) 0.2s forwards;
}

.warp-overlay.active .warp-pulse-2 {
  animation: warpPulseExpand 3.2s cubic-bezier(0.16, 1, 0.3, 1) 0.6s forwards;
}

.warp-overlay.active .warp-pulse-3 {
  animation: warpPulseExpand 2.8s cubic-bezier(0.16, 1, 0.3, 1) 1.1s forwards;
}

@keyframes warpPulseExpand {
  0% {
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    border-width: 3px;
    border-color: rgba(200, 230, 255, 0.9);
    box-shadow: 0 0 20px rgba(150, 200, 255, 0.5),
      inset 0 0 15px rgba(150, 200, 255, 0.2);
  }

  10% {
    opacity: 0.9;
  }

  40% {
    opacity: 0.6;
    border-width: 2px;
    border-color: rgba(180, 220, 255, 0.6);
  }

  70% {
    opacity: 0.3;
    border-width: 1px;
  }

  100% {
    transform: translate(-50%, -50%) scale(80);
    opacity: 0;
    border-width: 0.5px;
    border-color: rgba(150, 200, 255, 0.1);
    box-shadow: none;
  }
}

/* --- Warp Text (Central status text) --- */
.warp-text {
  position: absolute;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: 12px;
  color: rgba(220, 240, 255, 0);
  text-shadow: 0 0 30px rgba(150, 200, 255, 0.5),
    0 0 60px rgba(100, 150, 255, 0.3);
  white-space: nowrap;
  will-change: opacity, transform, letter-spacing;
  z-index: 10;
}

.warp-overlay.active .warp-text {
  animation: warpTextReveal 5.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes warpTextReveal {
  0% {
    color: rgba(220, 240, 255, 0);
    letter-spacing: 20px;
    transform: translate(-50%, -50%) scale(0.8);
    filter: blur(10px);
  }

  15% {
    color: rgba(220, 240, 255, 0.9);
    letter-spacing: 12px;
    transform: translate(-50%, -50%) scale(1);
    filter: blur(0px);
    text-shadow: 0 0 40px rgba(150, 200, 255, 0.7),
      0 0 80px rgba(100, 150, 255, 0.4),
      0 0 120px rgba(80, 120, 255, 0.2);
  }

  60% {
    color: rgba(220, 240, 255, 0.9);
    letter-spacing: 10px;
    transform: translate(-50%, -50%) scale(1);
    filter: blur(0px);
  }

  75% {
    color: rgba(255, 255, 255, 1);
    letter-spacing: 4px;
    transform: translate(-50%, -50%) scale(1.15);
    filter: blur(0px);
  }

  90% {
    letter-spacing: 0px;
    transform: translate(-50%, -50%) scale(2);
    filter: blur(5px);
  }

  100% {
    color: rgba(255, 255, 255, 0);
    letter-spacing: -5px;
    transform: translate(-50%, -50%) scale(3);
    filter: blur(15px);
  }
}

/* --- Warp Sub-text --- */
.warp-sub-text {
  position: absolute;
  top: 47%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-display);
  font-size: 11px;
  letter-spacing: 6px;
  color: rgba(150, 200, 255, 0);
  white-space: nowrap;
  z-index: 10;
}

.warp-overlay.active .warp-sub-text {
  animation: warpSubTextReveal 5.5s cubic-bezier(0.16, 1, 0.3, 1) 0.3s forwards;
}

@keyframes warpSubTextReveal {
  0% {
    color: rgba(150, 200, 255, 0);
    transform: translate(-50%, -50%) translateY(10px);
    filter: blur(5px);
  }

  12% {
    color: rgba(150, 200, 255, 0.7);
    transform: translate(-50%, -50%) translateY(0px);
    filter: blur(0px);
  }

  55% {
    color: rgba(150, 200, 255, 0.7);
    transform: translate(-50%, -50%) translateY(0px);
    filter: blur(0px);
  }

  70% {
    color: rgba(200, 230, 255, 0.9);
  }

  85% {
    transform: translate(-50%, -50%) translateY(0px) scale(1.5);
    filter: blur(3px);
  }

  100% {
    color: rgba(200, 230, 255, 0);
    transform: translate(-50%, -50%) translateY(-10px) scale(2);
    filter: blur(10px);
  }
}

/* --- Login Container Warping Effect --- */
.login-container.warping {
  animation: containerWarp 5.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes containerWarp {
  0% {
    transform: perspective(1000px) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg)) scale(1);
    filter: blur(0px) brightness(1);
    opacity: 1;
  }

  15% {
    transform: perspective(1000px) rotateX(0deg) rotateY(0deg) scale(1.02);
    filter: blur(0px) brightness(1.1);
    opacity: 1;
  }

  35% {
    transform: perspective(1000px) rotateX(0deg) rotateY(0deg) scale(0.97);
    filter: blur(1px) brightness(1.3);
    opacity: 0.9;
  }

  55% {
    transform: perspective(800px) rotateX(0deg) rotateY(0deg) scale(0.9) translateZ(-50px);
    filter: blur(3px) brightness(1.8);
    opacity: 0.7;
  }

  75% {
    transform: perspective(600px) rotateX(0deg) rotateY(0deg) scale(0.6) translateZ(-150px);
    filter: blur(8px) brightness(3);
    opacity: 0.3;
  }

  100% {
    transform: perspective(400px) rotateX(0deg) rotateY(0deg) scale(0.1) translateZ(-400px);
    filter: blur(20px) brightness(5);
    opacity: 0;
  }
}

/* --- Galaxy Hyperspace Jump Effect --- */
#galaxy-container.hyperspace-jump canvas {
  animation: galaxyHyperspace 5.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes galaxyHyperspace {
  0% {
    filter: brightness(1) saturate(1) blur(0px);
    transform: scale(1);
  }

  10% {
    filter: brightness(1.2) saturate(1.3) blur(0px);
    transform: scale(1);
  }

  25% {
    filter: brightness(1.5) saturate(1.6) blur(0.5px);
    transform: scale(1.02);
  }

  45% {
    filter: brightness(2) saturate(2) blur(1px);
    transform: scale(1.05);
  }

  65% {
    filter: brightness(3) saturate(0.5) blur(3px);
    transform: scale(1.15);
  }

  80% {
    filter: brightness(5) saturate(0) blur(8px);
    transform: scale(1.3);
  }

  90% {
    filter: brightness(8) saturate(0) blur(15px);
    transform: scale(1.6);
  }

  100% {
    filter: brightness(10) saturate(0) blur(25px);
    transform: scale(2);
  }
}

/* --- View Success Enter (from warp) --- */
.view-success-enter {
  animation: successFromWarp 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes successFromWarp {
  0% {
    opacity: 0;
    transform: scale(0.7) translateZ(-200px);
    filter: blur(15px) brightness(3);
  }

  30% {
    opacity: 0.5;
    filter: blur(6px) brightness(1.5);
  }

  60% {
    opacity: 0.85;
    transform: scale(1.02) translateZ(0);
    filter: blur(1px) brightness(1.1);
  }

  80% {
    transform: scale(0.99);
    filter: blur(0px) brightness(1);
  }

  100% {
    opacity: 1;
    transform: scale(1) translateZ(0);
    filter: blur(0px) brightness(1);
  }
}

/* --- Extra: Chromatic Aberration Ring during warp --- */
.warp-overlay.active::before {
  content: '';
  position: absolute;
  inset: -5%;
  background: conic-gradient(from 0deg at 50% 50%,
      rgba(255, 0, 100, 0.08),
      rgba(255, 100, 0, 0.06),
      rgba(255, 255, 0, 0.04),
      rgba(0, 255, 100, 0.04),
      rgba(0, 100, 255, 0.06),
      rgba(100, 0, 255, 0.08),
      rgba(255, 0, 100, 0.08));
  animation: warpChromatic 4s linear infinite;
  mix-blend-mode: screen;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0;
  animation: warpChromaticFade 5.5s ease forwards;
}

@keyframes warpChromaticFade {
  0% {
    opacity: 0;
    transform: scale(0.5) rotate(0deg);
  }

  20% {
    opacity: 0.6;
    transform: scale(1) rotate(30deg);
  }

  50% {
    opacity: 0.8;
    transform: scale(1.2) rotate(90deg);
  }

  75% {
    opacity: 0.5;
    transform: scale(1.5) rotate(180deg);
  }

  100% {
    opacity: 0;
    transform: scale(2) rotate(360deg);
  }
}

/* --- Extra: Particle Streaks during warp (via box-shadows) --- */
.warp-overlay.active::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 4px;
  height: 4px;
  background: white;
  border-radius: 50%;
  animation: warpParticleStreaks 3s cubic-bezier(0.16, 1, 0.3, 1) 0.5s forwards;
  opacity: 0;
}

@keyframes warpParticleStreaks {
  0% {
    opacity: 0;
    box-shadow:
      0 0 0 rgba(255, 255, 255, 0),
      0 0 0 rgba(200, 230, 255, 0),
      0 0 0 rgba(150, 200, 255, 0);
    transform: translate(-50%, -50%) scale(1);
  }

  20% {
    opacity: 1;
    box-shadow:
      20px -30px 4px rgba(255, 255, 255, 0.6),
      -40px 20px 3px rgba(200, 230, 255, 0.5),
      30px 50px 3px rgba(180, 220, 255, 0.4),
      -60px -40px 2px rgba(150, 200, 255, 0.6),
      70px 10px 4px rgba(220, 240, 255, 0.5),
      -20px 80px 3px rgba(200, 230, 255, 0.3),
      50px -70px 2px rgba(180, 220, 255, 0.5),
      -80px 60px 3px rgba(150, 200, 255, 0.4);
    transform: translate(-50%, -50%) scale(1);
  }

  100% {
    opacity: 0;
    box-shadow:
      200px -300px 2px rgba(255, 255, 255, 0),
      -400px 200px 2px rgba(200, 230, 255, 0),
      300px 500px 2px rgba(180, 220, 255, 0),
      -600px -400px 2px rgba(150, 200, 255, 0),
      700px 100px 2px rgba(220, 240, 255, 0),
      -200px 800px 2px rgba(200, 230, 255, 0),
      500px -700px 2px rgba(180, 220, 255, 0),
      -800px 600px 2px rgba(150, 200, 255, 0);
    transform: translate(-50%, -50%) scale(1);
  }
}

/* ========================================================================
   INSTAGRAM CREATOR LINK — Trigger Button
   ======================================================================== */

.ig-creator-link {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 25px;
  opacity: 0.75;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.ig-creator-link:hover {
  opacity: 1;
}

.ig-creator-line {
  flex-grow: 1;
  height: 1px;
  background: linear-gradient(90deg,
      transparent,
      rgba(225, 48, 108, 0.4),
      rgba(131, 58, 180, 0.4),
      rgba(240, 148, 51, 0.3),
      transparent);
  animation: igLineShimmer 3s ease-in-out infinite;
}

@keyframes igLineShimmer {

  0%,
  100% {
    opacity: 0.4;
  }

  50% {
    opacity: 1;
  }
}

.ig-creator-trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #e1306c;
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 3px;
  text-decoration: none;
  padding: 10px 20px;
  border-radius: 24px;
  border: 1px solid transparent;
  background:
    linear-gradient(rgba(10, 10, 10, 0.9), rgba(10, 10, 10, 0.9)) padding-box,
    linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888, #833ab4) border-box;
  box-shadow:
    0 0 15px rgba(225, 48, 108, 0.15),
    inset 0 0 15px rgba(225, 48, 108, 0.03);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.ig-creator-trigger::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 24px;
  background: linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888, #833ab4);
  opacity: 0;
  transition: opacity 0.4s;
  z-index: -1;
}

.ig-creator-trigger::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg,
      transparent 40%,
      rgba(255, 255, 255, 0.08) 50%,
      transparent 60%);
  animation: igTriggerShimmer 3s ease-in-out infinite;
}

@keyframes igTriggerShimmer {
  0% {
    transform: translateX(-100%) rotate(45deg);
  }

  100% {
    transform: translateX(100%) rotate(45deg);
  }
}

.ig-creator-trigger:hover {
  border-color: transparent;
  box-shadow:
    0 0 30px rgba(225, 48, 108, 0.35),
    0 0 60px rgba(131, 58, 180, 0.15),
    inset 0 0 20px rgba(225, 48, 108, 0.08);
  transform: translateY(-3px) scale(1.03);
  color: #fff;
  letter-spacing: 4px;
}

.ig-creator-trigger:hover::before {
  opacity: 0.15;
}

/* ========================================================================
   INSTAGRAM CINEMATIC OVERLAY — Full-Screen Takeover
   ======================================================================== */

.ig-cinematic-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
    visibility 0s linear 0.6s;
}

.ig-cinematic-overlay.active {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
    visibility 0s linear 0s;
}

/* Dark glass backdrop */
.ig-cinematic-backdrop {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center,
      rgba(15, 5, 20, 0.92) 0%,
      rgba(5, 2, 10, 0.97) 100%);
  backdrop-filter: blur(30px) saturate(0.5);
  -webkit-backdrop-filter: blur(30px) saturate(0.5);
}

/* Particle canvas layer */
.ig-particle-canvas {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

/* Close btn */
.ig-close-btn {
  position: absolute;
  top: 30px;
  right: 30px;
  z-index: 100;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.03);
  color: rgba(255, 255, 255, 0.5);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
  backdrop-filter: blur(10px);
}

.ig-close-btn:hover {
  border-color: rgba(225, 48, 108, 0.5);
  color: #e1306c;
  box-shadow: 0 0 20px rgba(225, 48, 108, 0.2);
  transform: rotate(90deg);
}

/* Main content container */
.ig-cinematic-content {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 420px;
  width: 100%;
  padding: 20px;
}

/* ========== Phase 1: Scanning Radar ========== */
.ig-radar-container {
  position: relative;
  width: 180px;
  height: 180px;
  margin-bottom: 30px;
}

.ig-radar-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(225, 48, 108, 0.15);
  animation: igRadarPulse 2s ease-out infinite;
}

.ig-radar-ring:nth-child(1) {
  inset: 0;
  animation-delay: 0s;
}

.ig-radar-ring:nth-child(2) {
  inset: 20px;
  animation-delay: 0.3s;
}

.ig-radar-ring:nth-child(3) {
  inset: 40px;
  animation-delay: 0.6s;
}

.ig-radar-ring:nth-child(4) {
  inset: 60px;
  animation-delay: 0.9s;
}

@keyframes igRadarPulse {
  0% {
    border-color: rgba(225, 48, 108, 0.05);
    transform: scale(1);
  }

  50% {
    border-color: rgba(225, 48, 108, 0.3);
  }

  100% {
    border-color: rgba(225, 48, 108, 0.05);
    transform: scale(1.05);
  }
}

.ig-radar-sweep {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(from 0deg,
      transparent 0deg,
      transparent 320deg,
      rgba(225, 48, 108, 0.3) 355deg,
      rgba(131, 58, 180, 0.15) 360deg);
  animation: igRadarSweep 2s linear infinite;
}

@keyframes igRadarSweep {
  to {
    transform: rotate(360deg);
  }
}

.ig-radar-dot {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 8px;
  height: 8px;
  margin: -4px 0 0 -4px;
  background: #e1306c;
  border-radius: 50%;
  box-shadow: 0 0 15px #e1306c, 0 0 30px rgba(225, 48, 108, 0.4);
  animation: igDotPulse 1.5s ease-in-out infinite;
}

@keyframes igDotPulse {

  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 15px #e1306c;
  }

  50% {
    transform: scale(1.5);
    box-shadow: 0 0 30px #e1306c, 0 0 60px rgba(225, 48, 108, 0.3);
  }
}

/* ========== Phase Status Text ========== */
.ig-phase-status {
  font-family: var(--font-display);
  font-size: 11px;
  letter-spacing: 3px;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  min-height: 24px;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.ig-phase-status.active-glow {
  color: #e1306c;
  text-shadow: 0 0 20px rgba(225, 48, 108, 0.5);
}

/* Typewriter cursor */
.ig-cursor {
  display: inline-block;
  width: 2px;
  height: 14px;
  background: #e1306c;
  animation: igCursorBlink 0.6s step-end infinite;
  margin-left: 2px;
  vertical-align: middle;
}

@keyframes igCursorBlink {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }
}

/* ========== Phase 3: Convergence Rings ========== */
.ig-convergence-container {
  position: relative;
  width: 200px;
  height: 200px;
  margin: 20px auto;
}

.ig-conv-ring {
  position: absolute;
  border-radius: 50%;
  border: 1.5px solid;
  opacity: 0;
  transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.ig-conv-ring-1 {
  inset: 0;
  border-color: rgba(225, 48, 108, 0.3);
  animation: igConvSpin 8s linear infinite;
}

.ig-conv-ring-2 {
  inset: 25px;
  border-color: rgba(131, 58, 180, 0.3);
  animation: igConvSpin 6s linear infinite reverse;
  border-style: dashed;
}

.ig-conv-ring-3 {
  inset: 50px;
  border-color: rgba(240, 148, 51, 0.3);
  animation: igConvSpin 4s linear infinite;
  border-style: dotted;
}

.ig-conv-ring-4 {
  inset: 70px;
  border-color: rgba(225, 48, 108, 0.2);
  animation: igConvSpin 3s linear infinite reverse;
}

@keyframes igConvSpin {
  to {
    transform: rotate(360deg);
  }
}

.ig-conv-ring.converged {
  opacity: 1 !important;
  border-color: #e1306c !important;
  border-style: solid !important;
  box-shadow: 0 0 25px rgba(225, 48, 108, 0.25), inset 0 0 15px rgba(225, 48, 108, 0.1);
}

.ig-conv-ring-2.converged {
  border-color: #833ab4 !important;
  box-shadow: 0 0 25px rgba(131, 58, 180, 0.25), inset 0 0 15px rgba(131, 58, 180, 0.1);
}

.ig-conv-ring-3.converged {
  border-color: #f09433 !important;
  box-shadow: 0 0 25px rgba(240, 148, 51, 0.25), inset 0 0 15px rgba(240, 148, 51, 0.1);
}

.ig-conv-ring-4.converged {
  border-color: #fff !important;
  box-shadow: 0 0 30px rgba(255, 255, 255, 0.2), inset 0 0 20px rgba(255, 255, 255, 0.05);
}

/* Center IG icon in convergence */
.ig-conv-center-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: rgba(255, 255, 255, 0.15);
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 5;
}

.ig-conv-center-icon.powered {
  color: #fff;
  filter: drop-shadow(0 0 15px #e1306c) drop-shadow(0 0 30px #833ab4);
  transform: translate(-50%, -50%) scale(1.3);
}

/* ========== Phase 4: Profile Card ========== */
.ig-profile-card {
  perspective: 1200px;
  width: 340px;
  margin: 0 auto;
  opacity: 0;
  transform: translateY(40px) scale(0.8);
  transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.ig-profile-card.revealed {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.ig-profile-card-inner {
  position: relative;
  background: linear-gradient(145deg,
      rgba(30, 15, 35, 0.95),
      rgba(15, 8, 20, 0.98));
  border: 1px solid rgba(225, 48, 108, 0.2);
  border-radius: 24px;
  padding: 35px 30px 25px;
  overflow: hidden;
  animation: igCardFloat 4s ease-in-out infinite;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.5),
    0 0 40px rgba(225, 48, 108, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

@keyframes igCardFloat {

  0%,
  100% {
    transform: translateY(0) rotateX(0deg);
  }

  50% {
    transform: translateY(-6px) rotateX(1deg);
  }
}

/* Holographic shimmer on card */
.ig-profile-card-inner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg,
      transparent 30%,
      rgba(225, 48, 108, 0.05) 45%,
      rgba(131, 58, 180, 0.08) 50%,
      rgba(240, 148, 51, 0.05) 55%,
      transparent 70%);
  animation: igHoloShimmer 4s ease-in-out infinite;
  pointer-events: none;
  border-radius: 24px;
}

@keyframes igHoloShimmer {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(200%);
  }
}

/* Border glow animation */
.ig-profile-card-inner::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 25px;
  background: conic-gradient(from var(--ig-border-angle, 0deg),
      #f09433, #e6683c, #dc2743, #cc2366, #bc1888,
      #833ab4, #5851db, #405de6, #833ab4,
      #bc1888, #cc2366, #dc2743, #e6683c, #f09433);
  z-index: -1;
  opacity: 0.4;
  filter: blur(3px);
  animation: igBorderRotate 4s linear infinite;
}

@keyframes igBorderRotate {
  to {
    --ig-border-angle: 360deg;
  }
}

@property --ig-border-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

/* Avatar */
.ig-avatar-container {
  position: relative;
  width: 90px;
  height: 90px;
  margin: 0 auto 18px;
}

.ig-avatar-ring {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  padding: 3px;
  background: conic-gradient(from var(--ig-ring-angle, 0deg),
      #f09433, #e6683c, #dc2743, #cc2366, #bc1888,
      #833ab4, #5851db, #833ab4,
      #bc1888, #dc2743, #f09433);
  animation: igRingRotate 3s linear infinite;
}

@keyframes igRingRotate {
  to {
    --ig-ring-angle: 360deg;
  }
}

@property --ig-ring-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

.ig-avatar-ring-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: #0a0a0a;
  padding: 3px;
}

.ig-avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: linear-gradient(135deg, #1a0a1f, #0f0515);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.ig-avatar-img svg,
.ig-avatar-img i {
  color: rgba(225, 48, 108, 0.6);
  width: 36px;
  height: 36px;
  filter: drop-shadow(0 0 8px rgba(225, 48, 108, 0.3));
}

/* Glow ring behind avatar */
.ig-avatar-glow {
  position: absolute;
  inset: -15px;
  border-radius: 50%;
  background: radial-gradient(circle,
      rgba(225, 48, 108, 0.15) 0%,
      rgba(131, 58, 180, 0.08) 40%,
      transparent 70%);
  animation: igAvatarGlow 2.5s ease-in-out infinite;
  z-index: -1;
}

@keyframes igAvatarGlow {

  0%,
  100% {
    transform: scale(1);
    opacity: 0.6;
  }

  50% {
    transform: scale(1.15);
    opacity: 1;
  }
}

/* Handle / Username */
.ig-handle {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 2px;
  color: #fff;
  margin-bottom: 6px;
  text-shadow: 0 0 20px rgba(225, 48, 108, 0.3);
}

.ig-handle-sub {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 1px;
  margin-bottom: 22px;
}

/* Stats Row */
.ig-stats-row {
  display: flex;
  justify-content: center;
  gap: 25px;
  padding: 18px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 20px;
}

.ig-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  opacity: 0;
  transform: translateY(15px);
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.ig-stat.visible {
  opacity: 1;
  transform: translateY(0);
}

.ig-stat-val {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 900;
  color: #fff;
  letter-spacing: 1px;
}

.ig-stat-label {
  font-family: 'Inter', sans-serif;
  font-size: 9px;
  color: rgba(255, 255, 255, 0.35);
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* Visit Button */
.ig-visit-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 30px;
  border-radius: 14px;
  border: none;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  color: #fff;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #833ab4, #e1306c, #f09433);
  background-size: 200% 200%;
  animation: igBtnGradient 3s ease infinite;
  box-shadow:
    0 4px 20px rgba(225, 48, 108, 0.3),
    0 0 40px rgba(131, 58, 180, 0.1);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  opacity: 0;
  transform: translateY(10px);
}

.ig-visit-btn.visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes igBtnGradient {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

.ig-visit-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg,
      transparent 40%,
      rgba(255, 255, 255, 0.2) 50%,
      transparent 60%);
  animation: igBtnShimmer 2.5s ease-in-out infinite;
}

@keyframes igBtnShimmer {
  0% {
    transform: translateX(-150%);
  }

  100% {
    transform: translateX(150%);
  }
}

.ig-visit-btn:hover {
  transform: translateY(-3px) scale(1.04);
  box-shadow:
    0 8px 30px rgba(225, 48, 108, 0.4),
    0 0 60px rgba(131, 58, 180, 0.2),
    0 0 80px rgba(240, 148, 51, 0.1);
  letter-spacing: 4px;
}

/* ========== Phase 6: Chromatic Burst (Exit) ========== */
.ig-chromatic-burst {
  position: absolute;
  inset: 0;
  z-index: 50;
  opacity: 0;
  pointer-events: none;
  background: radial-gradient(circle at center,
      rgba(225, 48, 108, 0.6) 0%,
      rgba(131, 58, 180, 0.3) 30%,
      rgba(240, 148, 51, 0.1) 60%,
      transparent 100%);
}

.ig-chromatic-burst.active {
  animation: igChromaticBurst 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes igChromaticBurst {
  0% {
    opacity: 0;
    transform: scale(0.5);
    filter: blur(20px);
  }

  40% {
    opacity: 1;
    transform: scale(1);
    filter: blur(0px);
  }

  70% {
    opacity: 1;
    transform: scale(1.3);
    filter: blur(0px);
  }

  100% {
    opacity: 0;
    transform: scale(3);
    filter: blur(15px);
  }
}

/* ========== Glitch text effect ========== */
.ig-glitch {
  position: relative;
  display: inline-block;
}

.ig-glitch::before,
.ig-glitch::after {
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.ig-glitch::before {
  color: #e1306c;
  animation: igGlitch1 0.3s infinite;
  clip-path: inset(0 0 65% 0);
}

.ig-glitch::after {
  color: #833ab4;
  animation: igGlitch2 0.3s infinite;
  clip-path: inset(65% 0 0 0);
}

@keyframes igGlitch1 {
  0% {
    transform: translate(0);
  }

  20% {
    transform: translate(-3px, 2px);
  }

  40% {
    transform: translate(3px, -2px);
  }

  60% {
    transform: translate(-2px, -1px);
  }

  80% {
    transform: translate(2px, 1px);
  }

  100% {
    transform: translate(0);
  }
}

@keyframes igGlitch2 {
  0% {
    transform: translate(0);
  }

  20% {
    transform: translate(3px, -1px);
  }

  40% {
    transform: translate(-2px, 2px);
  }

  60% {
    transform: translate(2px, 1px);
  }

  80% {
    transform: translate(-3px, -2px);
  }

  100% {
    transform: translate(0);
  }
}

/* ========== Data stream lines ========== */
.ig-data-stream {
  position: absolute;
  width: 1px;
  background: linear-gradient(to bottom, transparent, rgba(225, 48, 108, 0.4), transparent);
  animation: igDataFlow 1.5s linear infinite;
  opacity: 0.3;
}

@keyframes igDataFlow {
  0% {
    transform: translateY(-100vh);
  }

  100% {
    transform: translateY(100vh);
  }
}

/* ========== Progress bar phase indicator ========== */
.ig-progress-track {
  width: 200px;
  height: 2px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 2px;
  margin: 20px auto 0;
  overflow: hidden;
  position: relative;
}

.ig-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #e1306c, #833ab4, #f09433);
  border-radius: 2px;
  transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 10px rgba(225, 48, 108, 0.4);
}

/* ========== Floating ambient particles (CSS-only backup) ========== */
.ig-ambient-particle {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  animation: igAmbientFloat linear infinite;
}

@keyframes igAmbientFloat {
  0% {
    transform: translate(0, 0) scale(1);
    opacity: 0;
  }

  10% {
    opacity: 0.6;
  }

  90% {
    opacity: 0.6;
  }

  100% {
    transform: translate(var(--ig-dx), var(--ig-dy)) scale(0.3);
    opacity: 0;
  }
}

/* ========== Scanline effect across overlay ========== */
.ig-scanline {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  background: repeating-linear-gradient(0deg,
      transparent,
      transparent 2px,
      rgba(225, 48, 108, 0.01) 2px,
      rgba(225, 48, 108, 0.01) 4px);
  animation: igScanlineMove 8s linear infinite;
}

@keyframes igScanlineMove {
  0% {
    transform: translateY(0);
  }

  100% {
    transform: translateY(4px);
  }
}

/* ========== Vignette ========== */
.ig-vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  background: radial-gradient(ellipse at center,
      transparent 50%,
      rgba(0, 0, 0, 0.5) 100%);
}

/* ============================================================
   RESPONSIVE DESIGN — All Devices
   ============================================================ */

/* ---- Short viewport (small PC / laptop screens) ---- */
@media (max-height: 750px) {
  .overlay {
    padding: 10px 0;
  }

  .login-container {
    padding: 30px 30px;
    animation: formAppear 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  }

  h1 {
    font-size: 24px;
    margin-bottom: 3px;
  }

  p.subtitle {
    font-size: 11px;
    margin-bottom: 15px;
  }

  .ai-greeting {
    margin-bottom: 15px;
  }

  .input-group {
    margin-bottom: 14px;
  }

  .input-group input {
    padding: 14px 45px;
    font-size: 14px;
  }

  .input-icon {
    top: 15px;
  }

  .pass-toggle {
    top: 17px;
  }

  .biometric-btn {
    top: 15px;
  }

  .btn-primary {
    padding: 14px;
    font-size: 14px;
  }

  .threat-level,
  .threat-bar {
    font-size: 9px;
  }

  .aux-actions {
    margin-top: 12px;
  }

  .aux-actions a {
    font-size: 11px;
  }

  .ig-creator-link {
    margin-top: 10px;
  }

  .otp-title {
    font-size: 16px;
  }

  .otp-sub {
    margin-bottom: 15px;
    font-size: 12px;
  }
}

/* ---- Tablet (max-width: 768px) ---- */
@media (max-width: 768px) {
  .sys-hud {
    display: none !important;
  }

  .q-clock {
    display: none !important;
  }

  .life-support {
    display: none !important;
  }

  .ambient-data-flow {
    display: none;
  }

  .hex-grid {
    opacity: 0.3;
  }

  .floating-actions {
    bottom: 15px;
    right: 15px;
    gap: 8px;
  }

  .float-btn {
    width: 38px;
    height: 38px;
  }

  .login-container {
    padding: 35px 25px;
  }

  .modal-panel {
    width: 90% !important;
    max-width: 500px !important;
    max-height: 85vh !important;
  }

  .edge-glow {
    display: none;
  }
}

/* ---- Phone (max-width: 480px) ---- */
@media (max-width: 480px) {
  .overlay {
    padding: 15px 0;
  }

  .login-container {
    width: 95%;
    padding: 25px 18px;
    border-radius: 20px;
  }

  h1 {
    font-size: 20px;
    letter-spacing: 2px;
    margin-bottom: 2px;
  }

  p.subtitle {
    font-size: 10px;
    letter-spacing: 1.5px;
    margin-bottom: 12px;
  }

  .ai-greeting {
    font-size: 9px;
    margin-bottom: 15px;
    height: 14px;
  }

  .input-group {
    margin-bottom: 14px;
  }

  .input-group input {
    padding: 14px 40px;
    font-size: 14px;
    border-radius: 12px;
  }

  .input-icon {
    left: 14px;
    top: 15px;
    width: 18px;
    height: 18px;
  }

  .pass-toggle {
    right: 42px;
    top: 16px;
  }

  .biometric-btn {
    right: 12px;
    top: 15px;
  }

  .btn-primary {
    padding: 14px;
    font-size: 13px;
    letter-spacing: 1.5px;
    border-radius: 12px;
  }

  .remember-row {
    margin-bottom: 5px;
  }

  .remember-label {
    font-size: 9px;
  }

  .threat-level,
  .threat-bar {
    font-size: 8px;
  }

  .aux-actions {
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin-top: 15px;
  }

  .aux-actions a {
    font-size: 11px;
  }

  .shortcut-badge {
    display: none;
  }

  .ig-creator-link {
    margin-top: 10px;
  }

  .ig-creator-trigger span {
    font-size: 9px;
  }

  .retinal-grid {
    display: none;
  }

  .hex-grid {
    display: none;
  }

  .floating-actions {
    bottom: 10px;
    right: 10px;
    gap: 6px;
  }

  .float-btn {
    width: 34px;
    height: 34px;
  }

  .float-btn i,
  .float-btn svg {
    width: 16px;
    height: 16px;
  }

  .theme-menu {
    right: 0;
    bottom: 45px;
  }

  .modal-panel {
    width: 95% !important;
    max-width: none !important;
    max-height: 90vh !important;
    border-radius: 16px !important;
  }

  /* OTP view mobile */
  .otp-title {
    font-size: 16px;
    letter-spacing: 1px;
  }

  .otp-sub {
    font-size: 11px;
    margin-bottom: 15px;
  }

  .otp-grid {
    gap: 6px;
  }

  .otp-grid input {
    width: 38px;
    height: 44px;
    font-size: 18px;
  }

  /* Success view mobile */
  .holo-card {
    width: 100% !important;
    max-width: 300px;
  }

  .success-title {
    font-size: 18px;
  }

  /* Boot overlay mobile */
  .boot-title {
    font-size: 16px;
  }

  .boot-log {
    font-size: 10px;
  }

  /* Warp overlay mobile */
  .warp-text {
    font-size: 18px !important;
  }

  .warp-sub-text {
    font-size: 10px !important;
  }

  /* Command palette mobile */
  .cmd-palette {
    width: 95%;
  }
}

/* ---- Very small phones (max-width: 360px) ---- */
@media (max-width: 360px) {
  .login-container {
    padding: 20px 14px;
  }

  h1 {
    font-size: 18px;
    letter-spacing: 1.5px;
  }

  p.subtitle {
    font-size: 9px;
  }

  .input-group input {
    padding: 12px 36px;
    font-size: 13px;
  }

  .btn-primary {
    padding: 12px;
    font-size: 12px;
  }

  .otp-grid input {
    width: 32px;
    height: 38px;
    font-size: 16px;
  }
}

/* ---- Landscape phone ---- */
@media (max-height: 500px) and (orientation: landscape) {
  .overlay {
    padding: 5px 0;
  }

  .login-container {
    padding: 15px 25px;
    max-width: 450px;
  }

  h1 {
    font-size: 18px;
    margin-bottom: 2px;
  }

  p.subtitle {
    margin-bottom: 8px;
    font-size: 9px;
  }

  .ai-greeting {
    margin-bottom: 8px;
    height: 12px;
    font-size: 9px;
  }

  .input-group {
    margin-bottom: 8px;
  }

  .input-group input {
    padding: 10px 40px;
    font-size: 13px;
  }

  .input-icon {
    top: 11px;
    width: 16px;
    height: 16px;
  }

  .pass-toggle {
    top: 12px;
  }

  .biometric-btn {
    top: 11px;
  }

  .btn-primary {
    padding: 10px;
    font-size: 12px;
    margin-top: 5px;
  }

  .threat-level,
  .threat-bar {
    display: none;
  }

  .aux-actions {
    margin-top: 6px;
  }

  .aux-actions a {
    font-size: 10px;
  }

  .ig-creator-link {
    margin-top: 6px;
  }

  .sys-hud,
  .q-clock,
  .life-support {
    display: none !important;
  }
}