/* Wavz Black Mirror Style */

@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@300;400;500&family=Inter:wght@300;400;500;600&family=Space+Grotesk:wght@300;400;500;600&family=Orbitron:wght@400;500;600;700&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg-black: #000000;
  --bg-card: #0a0a0a;
  --text-primary: #ffffff;
  --text-secondary: #888888;
  --text-light: #ffffff;
  --border-subtle: #1a1a1a;
  --glow-white: rgba(255, 255, 255, 0.4);
}

body {
  font-family: 'IBM Plex Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: #000000;
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  overflow-y: auto;
  line-height: 1.6;
  font-size: 15px;
  -webkit-text-size-adjust: 100%;
  font-weight: 400;
  position: relative;
  letter-spacing: -0.01em;
  transition: background 0.5s ease;
}

/* Style switcher buttons */
.style-switcher {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  gap: 8px;
  z-index: 1000;
}

.style-btn {
  width: 35px;
  height: 35px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  font-size: 14px;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.2s ease;
  font-family: 'Space Grotesk', monospace;
  backdrop-filter: blur(10px);
}

.style-btn:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.3);
}

.style-btn.active {
  background: rgba(255, 255, 255, 0.2);
  border-color: #fff;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
}

/* ===== STYLE 1: Subtle Noise + Dark Gradient ===== */
body.bg-style-1::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    repeating-linear-gradient(
      0deg,
      transparent 0px,
      rgba(255, 255, 255, 0.02) 1px,
      transparent 2px
    ),
    linear-gradient(
      135deg,
      rgba(20, 20, 20, 0.8) 0%,
      rgba(0, 0, 0, 0.9) 50%,
      rgba(15, 15, 15, 0.8) 100%
    );
  pointer-events: none;
  z-index: 1;
  animation: subtleShift 8s ease-in-out infinite;
}

@keyframes subtleShift {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 0.8; }
}

/* ===== STYLE 2: Animated Scanlines ===== */
body.bg-style-2::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 200%;
  background: 
    repeating-linear-gradient(
      0deg,
      transparent 0px,
      transparent 2px,
      rgba(255, 255, 255, 0.03) 3px,
      transparent 4px
    ),
    radial-gradient(
      ellipse at center,
      rgba(30, 30, 30, 0.5) 0%,
      rgba(0, 0, 0, 0.8) 100%
    );
  pointer-events: none;
  z-index: 1;
  animation: scanlineMove 10s linear infinite;
}

@keyframes scanlineMove {
  0% { transform: translateY(0); }
  100% { transform: translateY(-50%); }
}

/* ===== STYLE 3: Glitch Distortion (slightly dimmer) ===== */
body.bg-style-3 {
  background: 
    linear-gradient(
      45deg,
      rgba(10, 10, 10, 1) 0%,
      rgba(0, 0, 0, 1) 25%,
      rgba(18, 18, 18, 1) 50%,
      rgba(0, 0, 0, 1) 75%,
      rgba(10, 10, 10, 1) 100%
    );
  background-size: 400% 400%;
  animation: glitchBg 15s ease infinite;
}

body.bg-style-3::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    repeating-linear-gradient(
      90deg,
      transparent 0px,
      rgba(255, 255, 255, 0.015) 1px,
      transparent 2px,
      rgba(255, 255, 255, 0.03) 3px,
      transparent 6px
    );
  pointer-events: none;
  z-index: 1;
  animation: glitchShift 0.3s steps(3) infinite;
}

@keyframes glitchBg {
  0%, 100% { background-position: 0% 50%; }
  25% { background-position: 50% 0%; }
  50% { background-position: 100% 50%; }
  75% { background-position: 50% 100%; }
}

@keyframes glitchShift {
  0%, 100% { transform: translate(0, 0); opacity: 0.7; }
  33% { transform: translate(2px, 0); opacity: 0.9; }
  66% { transform: translate(-2px, 0); opacity: 0.6; }
}

/* ===== STYLE 4: Film Grain + Chromatic ===== */
body.bg-style-4::before {
  content: '';
  position: fixed;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background-image: 
    repeating-radial-gradient(
      circle at 0 0,
      transparent 0px,
      rgba(255, 255, 255, 0.015) 1px,
      transparent 2px
    ),
    repeating-radial-gradient(
      circle at 100% 100%,
      transparent 0px,
      rgba(255, 0, 0, 0.01) 1px,
      transparent 2px
    ),
    repeating-radial-gradient(
      circle at 0 100%,
      transparent 0px,
      rgba(0, 255, 255, 0.01) 1px,
      transparent 2px
    ),
    radial-gradient(
      ellipse at center,
      rgba(10, 10, 10, 0.8) 0%,
      rgba(0, 0, 0, 0.95) 100%
    );
  background-size: 3px 3px, 3px 3px, 3px 3px, 100% 100%;
  pointer-events: none;
  z-index: 1;
  animation: filmGrain 0.2s steps(4) infinite, chromaDrift 20s ease-in-out infinite;
}

@keyframes filmGrain {
  0%, 100% { transform: translate(0, 0); }
  25% { transform: translate(-2%, 2%); }
  50% { transform: translate(2%, -2%); }
  75% { transform: translate(-1%, -1%); }
}

@keyframes chromaDrift {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 0.8; }
}

/* ===== STYLE 5: Mesh Gradient ===== */
body.bg-style-5 {
  background: 
    radial-gradient(
      circle at 10% 20%,
      rgba(30, 30, 30, 0.8) 0%,
      transparent 40%
    ),
    radial-gradient(
      circle at 90% 80%,
      rgba(25, 25, 25, 0.8) 0%,
      transparent 40%
    ),
    radial-gradient(
      circle at 50% 50%,
      rgba(35, 35, 35, 0.6) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 30% 70%,
      rgba(20, 20, 20, 0.7) 0%,
      transparent 45%
    ),
    #000000;
  animation: meshFloat 30s ease-in-out infinite;
}

body.bg-style-5::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    repeating-linear-gradient(
      0deg,
      transparent 0px,
      rgba(255, 255, 255, 0.01) 1px,
      transparent 3px
    );
  pointer-events: none;
  z-index: 1;
  opacity: 0.5;
}

@keyframes meshFloat {
  0%, 100% {
    background-position: 0% 0%, 100% 100%, 50% 50%, 30% 70%;
  }
  33% {
    background-position: 20% 10%, 80% 90%, 60% 40%, 40% 80%;
  }
  66% {
    background-position: -10% 20%, 110% 80%, 40% 60%, 20% 60%;
  }
}

/* Smooth gradient layer - only active without style class */
body:not([class*="bg-style"])::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(
      ellipse 800px 600px at 20% 30%,
      rgba(40, 40, 40, 0.08) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse 700px 500px at 80% 70%,
      rgba(35, 35, 35, 0.08) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at center,
      transparent 40%,
      rgba(0, 0, 0, 0.3) 100%
    );
  pointer-events: none;
  z-index: 0;
  animation: smoothGradientFloat 25s ease-in-out infinite;
}

@keyframes smoothGradientFloat {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.7;
  }
  33% {
    transform: translate(30px, -20px) scale(1.05);
    opacity: 0.8;
  }
  66% {
    transform: translate(-20px, 30px) scale(0.95);
    opacity: 0.75;
  }
}

/* Subtle noise texture - only active without style class */
body:not([class*="bg-style"])::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    repeating-linear-gradient(
      0deg,
      transparent 0px,
      rgba(255, 255, 255, 0.015) 1px,
      transparent 2px
    ),
    repeating-linear-gradient(
      90deg,
      transparent 0px,
      rgba(255, 255, 255, 0.015) 1px,
      transparent 2px
    );
  background-size: 2px 2px, 2px 2px;
  pointer-events: none;
  z-index: 1;
  opacity: 0.4;
  animation: subtleNoise 3s ease-in-out infinite;
}

@keyframes subtleNoise {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1.0; }
}


.screen {
  display: none;
  min-height: 100vh;
  padding: 110px 24px 90px;
  position: relative;
  z-index: 10;
  align-items: flex-start;
  justify-content: center;
}

.screen.active {
  display: flex;
}


/* Floating particle */
.screen::after {
  content: '';
  position: fixed;
  width: 2px;
  height: 2px;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  bottom: 0;
  left: 20%;
  animation: floatParticle 15s ease-in infinite;
  pointer-events: none;
  z-index: 0;
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.4);
}

/* Black Mirror animations */
@keyframes blink {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

@keyframes pulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 0.8; }
}

@keyframes fadeIn {
  from { 
    opacity: 0;
    transform: translateY(10px);
  }
  to { 
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes gentlePulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 0.8; }
}

@keyframes pulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}



@keyframes starTwinkle {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 0.7; }
}


@keyframes floatParticle {
  0% {
    transform: translateY(100vh) translateX(0);
    opacity: 0;
  }
  10% {
    opacity: 0.3;
  }
  90% {
    opacity: 0.3;
  }
  100% {
    transform: translateY(-100px) translateX(50px);
    opacity: 0;
  }
}

.container {
  max-width: 420px;
  width: 100%;
  margin: 0 auto;
  padding: 0;
  text-align: center;
  background: transparent;
  border: none;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

/* Multiple floating particles */
.container::before,
.container::after {
  content: '';
  position: fixed;
  width: 2px;
  height: 2px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  bottom: 0;
  animation: floatParticle 12s ease-in infinite;
  pointer-events: none;
  z-index: 0;
  box-shadow: 0 0 6px rgba(255, 255, 255, 0.3);
}

.container::before {
  left: 60%;
  animation-delay: 3s;
  animation-duration: 18s;
}

.container::after {
  left: 80%;
  animation-delay: 7s;
  animation-duration: 20s;
}

.console-line {
  margin-bottom: 10px;
  min-height: 18px;
}

/* Header */
.terminal-header {
  color: var(--text-primary);
  font-size: 13px;
  margin-bottom: 24px;
  letter-spacing: 2px;
  line-height: 1.4;
  font-weight: 500;
  opacity: 0.7;
  text-transform: uppercase;
}

.terminal-prompt {
  color: var(--text-secondary);
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 400;
  opacity: 0.6;
}

.cursor {
  display: none; /* Removed blinking cursor from all screens */
  width: 2px;
  height: 20px;
  background: var(--text-primary);
  animation: pulse 2s ease-in-out infinite;
  margin-left: 4px;
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.6);
}

/* Typing animation effects */
.animate-type {
  opacity: 0;
}

/* Hide images */
.psi-symbol,
.avatar-circle,
.waveform {
  display: none;
}

.avatar-img {
  display: none;
}

/* Typography */
.global-logo {
  position: fixed;
  top: 36px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  pointer-events: none;
  opacity: 1;
  width: 100%;
  text-align: center;
}

.title {
  font-size: 64px;
  font-weight: 400;
  margin-bottom: 20px;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  font-family: 'Orbitron', sans-serif;
  position: relative;
  z-index: 1;
  
  /* Start with calm, subtle glow */
  text-shadow: 
    0 0 10px rgba(255, 255, 255, 0.3),
    0 0 20px rgba(255, 255, 255, 0.2),
    0 0 30px rgba(255, 255, 255, 0.1);
  
  animation: psiCycle 8s ease-in-out infinite;
}

/* Cycle: Calm → Shine → Vibrate → Calm */
@keyframes psiCycle {
  /* 0-35%: Calm phase - subtle glow, no vibration */
  0%, 35% {
    text-shadow: 
      0 0 10px rgba(255, 255, 255, 0.3),
      0 0 20px rgba(255, 255, 255, 0.2),
      0 0 30px rgba(255, 255, 255, 0.1);
  }
  
  /* 40-45%: Build up - glow intensifies */
  40% {
    text-shadow: 
      0 0 20px rgba(255, 255, 255, 0.6),
      0 0 40px rgba(255, 255, 255, 0.4),
      0 0 60px rgba(255, 255, 255, 0.3);
  }
  
  45% {
    text-shadow: 
      0 0 30px rgba(255, 255, 255, 0.8),
      0 0 50px rgba(255, 255, 255, 0.6),
      0 0 70px rgba(255, 255, 255, 0.4);
  }
  
  /* 48-52%: Peak vibration - intense glow + double vision */
  48% {
    text-shadow: 
      0 0 40px rgba(255, 255, 255, 0.9),
      0 0 60px rgba(255, 255, 255, 0.7),
      0 0 80px rgba(255, 255, 255, 0.5),
      2px 0 0 rgba(255, 255, 255, 0.6),
      -2px 0 0 rgba(255, 255, 255, 0.6),
      0 2px 0 rgba(255, 255, 255, 0.4),
      0 -2px 0 rgba(255, 255, 255, 0.4),
      3px 3px 0 rgba(255, 255, 255, 0.3),
      -3px -3px 0 rgba(255, 255, 255, 0.3);
  }
  
  49% {
    text-shadow: 
      0 0 45px rgba(255, 255, 255, 1),
      0 0 65px rgba(255, 255, 255, 0.8),
      0 0 85px rgba(255, 255, 255, 0.6),
      -2px 0 0 rgba(255, 255, 255, 0.7),
      2px 0 0 rgba(255, 255, 255, 0.5),
      0 -2px 0 rgba(255, 255, 255, 0.5),
      0 2px 0 rgba(255, 255, 255, 0.3),
      -3px 3px 0 rgba(255, 255, 255, 0.4),
      3px -3px 0 rgba(255, 255, 255, 0.4);
  }
  
  50% {
    text-shadow: 
      0 0 40px rgba(255, 255, 255, 0.9),
      0 0 60px rgba(255, 255, 255, 0.7),
      0 0 80px rgba(255, 255, 255, 0.5),
      0 2px 0 rgba(255, 255, 255, 0.6),
      0 -2px 0 rgba(255, 255, 255, 0.6),
      2px 0 0 rgba(255, 255, 255, 0.4),
      -2px 0 0 rgba(255, 255, 255, 0.4),
      3px -3px 0 rgba(255, 255, 255, 0.3),
      -3px 3px 0 rgba(255, 255, 255, 0.3);
  }
  
  51% {
    text-shadow: 
      0 0 45px rgba(255, 255, 255, 1),
      0 0 65px rgba(255, 255, 255, 0.8),
      0 0 85px rgba(255, 255, 255, 0.6),
      2px 0 0 rgba(255, 255, 255, 0.7),
      -2px 0 0 rgba(255, 255, 255, 0.5),
      0 2px 0 rgba(255, 255, 255, 0.5),
      0 -2px 0 rgba(255, 255, 255, 0.3),
      -3px -3px 0 rgba(255, 255, 255, 0.4),
      3px 3px 0 rgba(255, 255, 255, 0.4);
  }
  
  52% {
    text-shadow: 
      0 0 40px rgba(255, 255, 255, 0.9),
      0 0 60px rgba(255, 255, 255, 0.7),
      0 0 80px rgba(255, 255, 255, 0.5),
      -2px 0 0 rgba(255, 255, 255, 0.6),
      2px 0 0 rgba(255, 255, 255, 0.6),
      0 -2px 0 rgba(255, 255, 255, 0.4),
      0 2px 0 rgba(255, 255, 255, 0.4),
      3px 3px 0 rgba(255, 255, 255, 0.3),
      -3px -3px 0 rgba(255, 255, 255, 0.3);
  }
  
  /* 55-60%: Wind down - glow reduces */
  55% {
    text-shadow: 
      0 0 30px rgba(255, 255, 255, 0.7),
      0 0 50px rgba(255, 255, 255, 0.5),
      0 0 70px rgba(255, 255, 255, 0.3);
  }
  
  60% {
    text-shadow: 
      0 0 20px rgba(255, 255, 255, 0.5),
      0 0 40px rgba(255, 255, 255, 0.3),
      0 0 60px rgba(255, 255, 255, 0.2);
  }
  
  /* 65-100%: Back to calm */
  65%, 100% {
    text-shadow: 
      0 0 10px rgba(255, 255, 255, 0.3),
      0 0 20px rgba(255, 255, 255, 0.2),
      0 0 30px rgba(255, 255, 255, 0.1);
  }
}

@media (max-width: 768px) {
  .title {
    font-size: 60px;
  }
  .global-logo {
    top: max(env(safe-area-inset-top), 44px);
  }
  .screen {
    padding: 120px 18px 80px;
  }
}

@media (max-width: 480px) {
  .title {
    font-size: 50px;
  }
  .global-logo {
    top: max(env(safe-area-inset-top), 36px);
  }
  .screen {
    padding: 110px 16px 70px;
  }
}

.subtitle {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 32px;
  font-weight: 400;
  line-height: 1.6;
}

.message {
  font-family: 'IBM Plex Sans', 'Space Grotesk', 'Inter', sans-serif;
  font-size: 17px;
  line-height: 1.65;
  color: var(--text-primary);
  margin-bottom: 6px;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-rendering: geometricPrecision;
  font-feature-settings: 'ss01' 1, 'salt' 1;
}

.message + .message {
  margin-top: 2px;
}

.mission-message {
  margin: 18px auto;
  text-align: center;
  max-width: 520px;
  letter-spacing: 0.02em;
}

.message.grouped {
  margin-bottom: 0;
}

.message.grouped + .message.grouped {
  margin-top: 0;
}

.message span,
.mission-paragraph span {
  display: inline-block;
  font-family: 'Space Grotesk', 'IBM Plex Sans', sans-serif;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
  padding-bottom: 2px;
  text-shadow: 0 0 25px rgba(255, 255, 255, 0.35);
}

.mission-paragraph {
  font-family: 'IBM Plex Sans', 'Space Grotesk', 'Inter', sans-serif;
  font-size: 17px;
  line-height: 1.65;
  letter-spacing: 0.04em;
  margin-bottom: 18px;
  color: var(--text-primary);
  font-weight: 400;
  text-rendering: geometricPrecision;
  font-feature-settings: 'ss01' 1, 'salt' 1;
}

.mission-button-group {
  margin-top: 16px;
}

/* Info message styles - completely rewritten */
#infoMessage {
  text-align: left;
  max-width: 500px;
  width: 100%;
  margin: 28px auto 0;
  padding: 0 8px;
}

#infoMessage .button-group {
  margin-top: 30px;
}

.info-block {
  margin-bottom: 20px;
}

.info-text {
  font-family: 'IBM Plex Sans', 'Space Grotesk', 'Inter', sans-serif;
  font-size: 17px;
  line-height: 1.65;
  color: var(--text-primary);
  margin-bottom: 18px;
  opacity: 0;
  transition: opacity 0.3s ease;
  width: 100%;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-rendering: geometricPrecision;
  font-feature-settings: 'ss01' 1, 'salt' 1;
}

.info-text:last-child {
  margin-bottom: 0;
}

.info-paragraph strong {
  font-weight: 600;
  letter-spacing: 0.02em;
}

.info-image-wrap {
  margin: 10px auto;
  opacity: 0;
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: flex;
  justify-content: center;
  transform: scale(0.95);
}

.connected-notification {
  max-width: 100%;
  width: auto;
  height: auto;
  max-height: 90px;
  display: inline-block;
}

@media (max-width: 768px) {
  #infoMessage {
    max-width: 360px;
  }
  
  .info-block {
    margin-bottom: 10px;
  }
  
  .info-text {
    font-size: 15px;
    line-height: 1.3;
  }
  
  .connected-notification {
    max-height: 78px;
  }
}

@media (max-width: 480px) {
  #infoMessage {
    max-width: 320px;
  }
  
  .info-block {
    margin-bottom: 12px;
  }
  
  .info-text {
    font-size: 14px;
    line-height: 1.25;
    margin-bottom: 1px;
  }
  
  .info-image-wrap {
    margin: 10px 0;
  }
  
  .connected-notification {
    max-height: 65px;
  }
}

/* Screen 2 */
.title-scan {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.5px;
  margin-bottom: 20px;
  color: var(--text-primary);
}

.waveform-container {
  display: none;
}

.waveform {
  display: none;
}

/* ASCII Art */
.ascii-art {
  display: none;
}

/* Instructions */
.instructions {
  width: 100%;
  margin-top: 24px;
}

.instruction-title {
  font-size: 15px;
  margin-bottom: 16px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.3px;
  opacity: 0.9;
}

.step {
  display: block;
  margin-bottom: 12px;
  padding-left: 0;
  position: relative;
}

.step::before {
  content: attr(data-num) ". ";
  color: var(--accent-dim);
  font-weight: 400;
}

.step-icon {
  display: none;
}

.step-icon-img {
  display: none;
}

.step-text {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-primary);
  font-weight: 400;
}

.step-text strong {
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 0.05em;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.step-2 {
  display: block;
  text-align: left;
  font-size: 15px;
  line-height: 1.7;
  margin-top: 12px;
  padding-left: 0;
  position: relative;
  font-weight: 400;
  color: var(--text-primary);
}

.step-2::before {
  content: "2. ";
  color: var(--accent-dim);
  font-weight: 400;
}

.disclaimer {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin: 24px 0;
  padding: 0;
  border: none;
  background: transparent;
  font-weight: 400;
  opacity: 0.7;
}

.disclaimer span {
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* PWA Install Screen Styles */
.pwa-install-instructions {
  margin-top: 0;
  position: relative;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.pwa-instruction-line {
  /* Uses mission-paragraph styling - inherits from .mission-paragraph class */
  text-align: center;
  margin-bottom: 14px;
}

.pwa-instruction-line span {
  display: inline;
  font-family: 'Space Grotesk', 'IBM Plex Sans', sans-serif;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: 0.02em;
  text-transform: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
  padding-bottom: 2px;
}

/* PWA Install Screen - Refined Black Mirror Style */
.pwa-install-content {
  max-width: 400px;
  margin: 0 auto;
  text-align: center;
}

.pwa-main-message {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 18px;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 20px;
}

.pwa-instructions-header {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 40px;
}

/* Steps Container */
.pwa-steps-container {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.pwa-step {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 18px 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.pwa-step:first-child {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.pwa-step-num {
  font-family: 'Courier New', monospace;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.5);
  font-weight: 700;
  letter-spacing: 0.08em;
  min-width: 26px;
  text-align: right;
  flex-shrink: 0;
}

.pwa-step-content {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.02em;
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.pwa-step-content strong {
  font-weight: 700;
  color: rgba(255, 255, 255, 1);
}

/* Share icon - PNG */
.pwa-share-icon {
  display: inline-block;
  vertical-align: middle;
  width: 18px;
  height: 18px;
  margin: 0 4px;
  position: relative;
  top: 1px;
  filter: brightness(0) invert(1) opacity(0.9);
}

/* Install button container */
.pwa-install-button-container {
  margin-top: 32px;
  text-align: center;
}

/* Mobile responsive */
@media (max-width: 480px) {
  .pwa-main-message {
    font-size: 16px;
  }
  
  .pwa-instructions-header {
    font-size: 13px;
    margin-bottom: 32px;
  }
  
  .pwa-step {
    gap: 14px;
    padding: 16px 16px;
  }
  
  .pwa-step-num {
    font-size: 13px;
    min-width: 24px;
  }
  
  .pwa-step-content {
    font-size: 14px;
  }
}


/* Password Input */
.password-input-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 100%;
}

#passwordInput {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 2px;
  color: var(--text-primary);
  font-family: 'Space Grotesk', monospace;
  font-size: 16px;
  padding: 12px 20px;
  width: 100%;
  max-width: 280px;
  text-align: center;
  letter-spacing: 0.1em;
  transition: all 0.2s ease;
  outline: none;
}

#passwordInput::placeholder {
  color: var(--text-secondary);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-size: 14px;
}

#passwordInput:focus {
  border-color: rgba(255, 255, 255, 0.6);
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.02);
}

.password-error {
  color: #ff4444;
  font-family: 'Space Grotesk', monospace;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  animation: errorShake 0.4s ease;
}

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

/* Button Group */
.button-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
  margin: 18px 0 0;
  width: 100%;
}

/* Button - Black & White Style */
.btn-primary {
  background: transparent;
  color: var(--text-light);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 2px;
  padding: 14px 32px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-block;
  letter-spacing: 0.02em;
  text-align: center;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  position: relative;
  font-family: 'Space Grotesk', sans-serif;
  min-width: 220px;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-icon {
  display: none;
}

/* Hover effects only on devices that support hover */
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover::before {
    width: 300px;
    height: 300px;
  }

  .btn-primary:hover {
    border-color: var(--text-light);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
  }
}

/* Active/tap state for all devices */
.btn-primary:active {
  transform: scale(0.98);
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--text-light);
}

/* Mobile tap animation sequence */
.btn-primary.tap-animating {
  animation: mobileTapSequence 0.8s ease-out forwards;
  pointer-events: none;
}

@keyframes mobileTapSequence {
  0% {
    transform: scale(0.98);
    opacity: 1;
  }
  15% {
    transform: scale(1);
    border-color: var(--text-light);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
  }
  30% {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.5);
  }
  50% {
    transform: translateY(-2px) scale(1.02);
    opacity: 1;
  }
  70% {
    transform: scale(0.95);
    opacity: 0.7;
  }
  85% {
    transform: scale(0.9);
    opacity: 0.3;
    filter: blur(2px);
  }
  100% {
    transform: scale(0.8);
    opacity: 0;
    filter: blur(4px);
  }
}

/* Secondary Button */
.btn-secondary {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  padding: 12px 28px;
  font-size: 13px;
  font-weight: 400;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-block;
  letter-spacing: 0.02em;
  text-align: center;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  font-family: 'Inter', sans-serif;
  min-width: 220px;
  opacity: 0.7;
  position: relative;
  overflow: hidden;
}

.btn-secondary::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

/* Hover effects only on devices that support hover */
@media (hover: hover) and (pointer: fine) {
  .btn-secondary:hover::before {
    width: 300px;
    height: 300px;
  }

  .btn-secondary:hover {
    border-color: rgba(255, 255, 255, 0.5);
    opacity: 1;
    transform: translateY(-2px);
  }
}

/* Active/tap state for all devices */
.btn-secondary:active {
  transform: scale(0.98);
  opacity: 1;
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.1);
}

/* Mobile tap animation sequence for secondary button */
.btn-secondary.tap-animating {
  animation: mobileTapSequence 0.8s ease-out forwards;
  pointer-events: none;
}

/* Sign-in Buttons */
.sign-in-container {
  margin-top: 32px;
  transition: opacity 0.4s ease;
}

.sign-in-buttons {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 300px;
  margin: 0 auto;
}

.sign-in-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 14px 24px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.03);
  color: rgba(255, 255, 255, 0.95);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: all 0.25s ease;
}

.sign-in-btn:hover {
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.08);
}

.sign-in-icon {
  flex-shrink: 0;
}

/* ===== SESSION RESUME SCREEN ===== */
/* Shown while restoring session after iOS PWA reload */
#resumeScreen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000000;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.resume-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
}

.resume-spinner {
  position: relative;
  width: 60px;
  height: 60px;
}

.spinner-ring {
  position: absolute;
  width: 100%;
  height: 100%;
  border: 3px solid transparent;
  border-top-color: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  animation: spin 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}

.spinner-ring:nth-child(1) {
  animation-delay: -0.45s;
  border-top-color: rgba(255, 255, 255, 0.5);
}

.spinner-ring:nth-child(2) {
  animation-delay: -0.3s;
  border-top-color: rgba(255, 255, 255, 0.4);
}

.spinner-ring:nth-child(3) {
  animation-delay: -0.15s;
  border-top-color: rgba(255, 255, 255, 0.3);
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.resume-text {
  font-family: 'Space Grotesk', monospace;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.8);
  letter-spacing: 0.08em;
  text-align: center;
}
/* ===== END SESSION RESUME SCREEN =====  */

/* Responsive */
/* Responsive */
@media (max-width: 768px) {
  .message,
  .mission-paragraph {
    font-size: 15px;
  }
  
  .btn-primary,
  .btn-secondary {
    min-width: 200px;
  }
}

@media (max-width: 480px) {
  body {
    font-size: 14px;
  }
  
  .message,
  .mission-paragraph {
    font-size: 14px;
  }
  
  .btn-primary {
    font-size: 13px;
    padding: 13px 28px;
    min-width: 180px;
  }
  
  .btn-secondary {
    font-size: 12px;
    padding: 11px 24px;
    min-width: 180px;
  }
}

/* Modal Overlay */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(10px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  display: flex;
  opacity: 1;
}

.modal-content {
  max-width: 500px;
  width: 90%;
  background: 
    linear-gradient(
      45deg,
      rgba(10, 10, 10, 1) 0%,
      rgba(0, 0, 0, 1) 25%,
      rgba(15, 15, 15, 1) 50%,
      rgba(0, 0, 0, 1) 75%,
      rgba(10, 10, 10, 1) 100%
    );
  background-size: 400% 400%;
  animation: glitchBg 15s ease infinite;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 40px 30px;
  border-radius: 4px;
  position: relative;
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
  transform: scale(1);
}

/* Modal glitch effect */
.modal-content::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    repeating-linear-gradient(
      90deg,
      transparent 0px,
      rgba(255, 255, 255, 0.01) 1px,
      transparent 2px,
      rgba(255, 255, 255, 0.02) 3px,
      transparent 6px
    );
  pointer-events: none;
  animation: glitchShift 0.3s steps(3) infinite;
  border-radius: 4px;
}

.modal-text {
  color: var(--text-primary);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  line-height: 1.8;
  margin-bottom: 30px;
}

.modal-text p {
  margin-bottom: 16px;
}

.modal-text strong {
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.03em;
}

.modal-highlight {
  font-family: 'Orbitron', monospace;
  font-size: 18px;
  color: #ffffff;
  text-align: center;
  padding: 20px;
  margin: 20px 0;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.02);
  letter-spacing: 0.05em;
}

.modal-btn {
  display: block;
  margin: 0 auto;
}

@media (max-width: 480px) {
  .modal-content {
    padding: 30px 20px;
  }
  
  .modal-text {
    font-size: 15px;
  }
  
  .modal-highlight {
    font-size: 16px;
    padding: 15px;
  }
}

/* ========================================
   FACE SCANNER (Beautiful Minimal)
   ======================================== */

.face-scanner-container {
  width: 100%;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0;
  gap: 60px;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

/* Status text above circle - console style */
.scanner-status {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 17px;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.75);
  text-align: center;
  transition: color 0.6s ease, text-shadow 0.6s ease;
  order: 1;
  margin: 0;
  padding: 0 24px;
  flex-shrink: 0;
}

.scanner-status.scanning {
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
}

.scanner-status.face-detected {
  color: rgba(255, 200, 120, 0.95);
  text-shadow: 0 0 15px rgba(255, 150, 60, 0.5);
}

.scanner-status.completed {
  color: rgba(255, 255, 255, 1);
  text-shadow: 0 0 18px rgba(255, 255, 255, 0.8);
}

/* Circular viewport - perfectly centered, minimal (no extra circles) */
.scanner-viewport {
  position: relative;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  overflow: hidden;
  background: #000000;
  z-index: 1;
  order: 2;
  margin: 0;
  flex-shrink: 0;
  /* White glow (default - face outside) - 30% smaller */
  box-shadow: 
    0 0 0 1px rgba(255, 255, 255, 0.15),
    0 0 24px 5px rgba(255, 255, 255, 0.5),
    0 0 35px 10px rgba(255, 255, 255, 0.25);
  animation: whiteGlowPulse 4s ease-in-out infinite;
  transition: box-shadow 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

#cameraFeed {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transform: scaleX(-1);
  object-fit: cover;
}

/* Animations for white glow (face outside) - 30% smaller */
@keyframes whiteGlowPulse {
  0%, 100% {
    box-shadow: 
      0 0 0 1px rgba(255, 255, 255, 0.15),
      0 0 21px 4px rgba(255, 255, 255, 0.45),
      0 0 31px 8px rgba(255, 255, 255, 0.2);
  }
  50% {
    box-shadow: 
      0 0 0 1px rgba(255, 255, 255, 0.2),
      0 0 28px 7px rgba(255, 255, 255, 0.6),
      0 0 42px 12px rgba(255, 255, 255, 0.3);
  }
}

/* Sunset/sunrise sun-like glow (face inside circle) - warm, organic, alive */
.scanner-viewport.face-detected {
  box-shadow: 
    0 0 0 1px rgba(255, 180, 100, 0.4),
    0 0 28px 8px rgba(255, 150, 60, 0.7),
    0 0 42px 14px rgba(255, 120, 40, 0.5),
    0 0 56px 21px rgba(255, 100, 20, 0.3);
  animation: sunsetGlowPulse 4s ease-in-out infinite;
}

@keyframes sunsetGlowPulse {
  0%, 100% {
    box-shadow: 
      0 0 0 1px rgba(255, 180, 100, 0.35),
      0 0 26px 7px rgba(255, 150, 60, 0.65),
      0 0 40px 13px rgba(255, 120, 40, 0.45),
      0 0 54px 19px rgba(255, 100, 20, 0.25);
  }
  25% {
    box-shadow: 
      0 0 0 1px rgba(255, 200, 120, 0.4),
      0 0 31px 9px rgba(255, 170, 80, 0.75),
      0 0 45px 15px rgba(255, 140, 60, 0.55),
      0 0 59px 22px rgba(255, 110, 30, 0.35);
  }
  50% {
    box-shadow: 
      0 0 0 1px rgba(255, 190, 110, 0.45),
      0 0 29px 9px rgba(255, 160, 70, 0.8),
      0 0 43px 14px rgba(255, 130, 50, 0.6),
      0 0 57px 21px rgba(255, 105, 25, 0.4);
  }
  75% {
    box-shadow: 
      0 0 0 1px rgba(255, 185, 105, 0.4),
      0 0 28px 8px rgba(255, 155, 65, 0.7),
      0 0 42px 14px rgba(255, 125, 45, 0.5),
      0 0 56px 21px rgba(255, 100, 20, 0.3);
  }
}

/* Completion state - bright white glow (30% smaller) */
.scanner-viewport.completed {
  box-shadow: 
    0 0 0 1px rgba(255, 255, 255, 0.4),
    0 0 35px 10px rgba(255, 255, 255, 0.8),
    0 0 49px 17px rgba(255, 255, 255, 0.6),
    0 0 63px 24px rgba(255, 255, 255, 0.4);
  animation: completedGlowPulse 2s ease-in-out infinite;
}

@keyframes completedGlowPulse {
  0%, 100% {
    box-shadow: 
      0 0 0 1px rgba(255, 255, 255, 0.4),
      0 0 35px 10px rgba(255, 255, 255, 0.8),
      0 0 49px 17px rgba(255, 255, 255, 0.6),
      0 0 63px 24px rgba(255, 255, 255, 0.4);
  }
  50% {
    box-shadow: 
      0 0 0 1px rgba(255, 255, 255, 0.5),
      0 0 42px 12px rgba(255, 255, 255, 1),
      0 0 56px 19px rgba(255, 255, 255, 0.7),
      0 0 70px 28px rgba(255, 255, 255, 0.5);
  }
}

/* Progress text inside circle */
.scan-progress-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: 'Space Grotesk', monospace;
  font-size: 36px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.05em;
  text-shadow: 0 0 28px rgba(255, 255, 255, 0.6);
  opacity: 0;
  z-index: 3;
  pointer-events: none;
  transition: opacity 0.5s ease, color 0.6s ease, text-shadow 0.6s ease;
}

.scanner-viewport.scanning .scan-progress-text {
  opacity: 1;
}

.scanner-viewport.face-detected .scan-progress-text {
  color: rgba(255, 210, 140, 1);
  text-shadow: 0 0 22px rgba(255, 150, 60, 0.8);
}

.scanner-viewport.completed .scan-progress-text {
  color: rgba(255, 255, 255, 1);
  text-shadow: 0 0 30px rgba(255, 255, 255, 1);
}

/* Mobile responsive */
@media (max-width: 768px) {
  .scanner-viewport {
    width: 280px;
    height: 280px;
  }
  
  .scan-progress-text {
    font-size: 32px;
  }
  
  .instruction-text {
    font-size: 15px;
  }
  
  .scanner-status {
    font-size: 16px;
  }
}

@media (max-width: 480px) {
  .face-scanner-container {
    padding: 0;
    gap: 50px;
  }
  
  .scanner-viewport {
    width: 260px;
    height: 260px;
  }
  
  .scan-progress-text {
    font-size: 28px;
  }
  
  .instruction-text {
    font-size: 14px;
  }
  
  .scanner-status {
    font-size: 16px;
    padding: 0 20px;
  }
}

@media (max-width: 380px) {
  .scanner-viewport {
    width: 240px;
    height: 240px;
  }
  
  .scan-progress-text {
    font-size: 24px;
  }
  
  .scanner-status {
    font-size: 15px;
  }
}

/* ========================================
   PHONE CALL SIMULATION (Voice Scan)
   ======================================== */

.phone-call-container {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 20px;
  min-height: 70vh;
}

.pickup-instruction {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 17px;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 50px;
  text-align: center;
  font-weight: 400;
}

.pickup-text {
  /* Removed text-transform: uppercase - use sentence case */
}

.pickup-dots {
  display: inline-block;
  width: 20px;
  text-align: left;
  animation: pickupDots 1.6s steps(4, end) infinite;
}

@keyframes pickupDots {
  0% { content: ''; }
  25% { content: '.'; }
  50% { content: '..'; }
  75% { content: '...'; }
}

.phone-screen {
  width: 100%;
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  animation: fadeIn 0.5s ease;
}

.phone-screen.active {
  display: flex;
}

@keyframes fadeIn {
  from {  opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.typing-dots {
  display: inline-flex;
  margin-left: 2px;
}

.typing-dots .dot {
  animation: dotFade 1.5s ease-in-out infinite;
  opacity: 0.3;
}

.typing-dots .dot:nth-child(1) {
  animation-delay: 0s;
}

.typing-dots .dot:nth-child(2) {
  animation-delay: 0.3s;
}

.typing-dots .dot:nth-child(3) {
  animation-delay: 0.6s;
}

.phone-icon-clickable {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  animation: phoneBuzz 4s ease-in-out infinite;
  position: relative;
}

.phone-icon-clickable::before,
.phone-icon-clickable::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0);
  opacity: 0;
  pointer-events: none;
}

@keyframes phoneBuzz {
  0%, 45% {
    transform: translateX(0) rotate(0deg);
    opacity: 0.85;
  }
  50% {
    transform: translateX(-3px) rotate(-5deg);
    opacity: 1;
  }
  52% {
    transform: translateX(3px) rotate(5deg);
    opacity: 1;
  }
  54% {
    transform: translateX(-2px) rotate(-3deg);
    opacity: 1;
  }
  56% {
    transform: translateX(2px) rotate(3deg);
    opacity: 1;
  }
  58% {
    transform: translateX(-1px) rotate(-2deg);
    opacity: 1;
  }
  60%, 100% {
    transform: translateX(0) rotate(0deg);
    opacity: 0.85;
  }
}

.phone-icon-clickable::before {
  animation: waveOut1 4s ease-in-out infinite;
}

.phone-icon-clickable::after {
  animation: waveOut2 4s ease-in-out infinite;
}

@keyframes waveOut1 {
  0%, 48% {
    width: 60px;
    height: 60px;
    border-color: rgba(255, 255, 255, 0);
    opacity: 0;
  }
  50% {
    width: 60px;
    height: 60px;
    border-color: rgba(255, 255, 255, 0.5);
    opacity: 1;
  }
  58% {
    width: 100px;
    height: 100px;
    border-color: rgba(255, 255, 255, 0.2);
    opacity: 0.3;
  }
  62% {
    width: 120px;
    height: 120px;
    border-color: rgba(255, 255, 255, 0);
    opacity: 0;
  }
  100% {
    width: 60px;
    height: 60px;
    border-color: rgba(255, 255, 255, 0);
    opacity: 0;
  }
}

@keyframes waveOut2 {
  0%, 50% {
    width: 60px;
    height: 60px;
    border-color: rgba(255, 255, 255, 0);
    opacity: 0;
  }
  52% {
    width: 60px;
    height: 60px;
    border-color: rgba(255, 255, 255, 0.4);
    opacity: 0.8;
  }
  60% {
    width: 100px;
    height: 100px;
    border-color: rgba(255, 255, 255, 0.15);
    opacity: 0.2;
  }
  64% {
    width: 120px;
    height: 120px;
    border-color: rgba(255, 255, 255, 0);
    opacity: 0;
  }
  100% {
    width: 60px;
    height: 60px;
    border-color: rgba(255, 255, 255, 0);
    opacity: 0;
  }
}

.phone-icon-clickable:hover {
  opacity: 1;
  transform: scale(1.08);
}

/* ===== IN-CALL SCREEN ===== */
.call-timer {
  font-family: 'Space Grotesk', monospace;
  font-size: 17px;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: 0.15em;
  margin-bottom: 20px;
}

.call-dots {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 40px;
  color: rgba(255, 255, 255, 0.7);
  letter-spacing: 0.1em;
  margin-bottom: 80px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.call-dots .dot {
  animation: dotFade 1.5s ease-in-out infinite;
  opacity: 0.3;
}

.call-dots .dot:nth-child(1) {
  animation-delay: 0s;
}

.call-dots .dot:nth-child(2) {
  animation-delay: 0.3s;
}

.call-dots .dot:nth-child(3) {
  animation-delay: 0.6s;
}

@keyframes dotFade {
  0%, 100% {
    opacity: 0.3;
  }
  50% {
    opacity: 1;
  }
}

.hangup-icon-clickable {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  transform: rotate(135deg);
}

.hangup-icon-clickable:hover {
  opacity: 1;
  transform: rotate(135deg) scale(1.08);
}

.scan-complete-wrapper {
  text-align: center;
}

.scan-complete-label {
  font-family: 'Space Grotesk', monospace;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0.15em;
  margin-bottom: 20px;
}

.scan-complete-title {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 24px;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.02em;
  margin-bottom: 50px;
}

.scan-complete-divider {
  width: 1px;
  height: 40px;
  background: rgba(255, 255, 255, 0.2);
  margin: 0 auto 50px;
}

.scan-complete-divider--tall {
  height: 50px;
}

.scan-complete-subtext {
  font-family: 'Space Grotesk', monospace;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: 0.05em;
  line-height: 1.8;
}

.scan-complete-button {
  opacity: 0;
  transition: opacity 0.5s ease;
}

/* User response panel (hidden in minimal UI) */
.user-response-panel {
  display: none;
}

.transcript-display {
  display: none;
}

.manual-input-container {
  display: none;
}

.manual-send {
  display: none;
}

.manual-hint {
  display: none;
}

/* Responsive Phone UI */
@media (max-width: 768px) {
  .phone-call-container {
    max-width: 350px;
    padding: 30px 18px;
  }
  
  .pickup-instruction {
    font-size: 17px;
  }
  
  .incall-agent-name {
    font-size: 26px;
  }
  
  
  .hangup-button {
    width: 65px;
    height: 65px;
  }
}

@media (max-width: 480px) {
  .phone-call-container {
    max-width: 320px;
    padding: 25px 15px;
  }
  
  .pickup-instruction {
    font-size: 16px;
  }
  
  .incall-agent-name {
    font-size: 24px;
  }
  
    padding: 16px 18px;
  }
  
  .agent-text {
    font-size: 15px;
  }
  
  .pickup-button {
    padding: 12px 36px;
    font-size: 14px;
  }
  
  .hangup-button {
    width: 60px;
    height: 60px;
  }
  
  .hangup-button svg {
    width: 28px;
    height: 28px;
  }
}

/* ========================================
   COMMUNICATION PATTERNS SCAN
   ======================================== */

#screen5 {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 60px 20px;
}

.comm-scan-container {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.scan-header {
  margin-bottom: 60px;
}

.scan-label {
  font-family: 'Space Grotesk', monospace;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 0.2em;
  margin-bottom: 24px;
  text-transform: uppercase;
}

.scan-title {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 26px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.95);
  letter-spacing: 0.01em;
}

.scan-description {
  margin-bottom: 60px;
  max-width: 420px;
}

.scan-text {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 15px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.65);
  letter-spacing: 0.01em;
  line-height: 1.8;
  margin-bottom: 16px;
}

.scan-divider {
  width: 1px;
  height: 60px;
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0),
    rgba(255, 255, 255, 0.15),
    rgba(255, 255, 255, 0)
  );
  margin: 0 auto 60px;
}

.scan-instruction {
  margin-bottom: 50px;
}

.instruction-line {
  font-family: 'Space Grotesk', monospace;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0.08em;
  margin-bottom: 10px;
}

.scan-action {
  margin-top: 0;
}

/* Responsive */
@media (max-width: 768px) {
  .comm-scan-container {
    padding: 30px 18px;
  }
  
  .scan-title {
    font-size: 24px;
  }
  
  .scan-text {
    font-size: 16px;
  }
  
  .instruction-line {
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .comm-scan-container {
    padding: 25px 15px;
  }
  
  .scan-header {
    margin-bottom: 40px;
  }
  
  .scan-title {
    font-size: 22px;
  }
  
  .scan-text {
    font-size: 15px;
  }
  
  .scan-description {
    margin-bottom: 40px;
  }
  
  .scan-divider {
    height: 40px;
    margin-bottom: 40px;
  }
  
  .instruction-line {
    font-size: 12px;
  }
}

/* ========================================
   USER PROFILE SCREENS
   ======================================== */

.profile-container {
  width: 100%;
  max-width: 700px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 20px;
  text-align: center;
}

/* ===== SCREEN 6: ARCHETYPE & CHARTS ===== */

.profile-header {
  margin-bottom: 60px;
}

.profile-label {
  font-family: 'Space Grotesk', monospace;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0.15em;
  margin-bottom: 30px;
  text-transform: uppercase;
}

.archetype-text {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 32px;
  color: rgba(255, 255, 255, 0.95);
  letter-spacing: 0.02em;
  line-height: 1.3;
  text-shadow: 0 0 30px rgba(255, 255, 255, 0.3);
}

.charts-section {
  width: 100%;
  max-width: 600px;
  margin-bottom: 60px;
  display: flex;
  flex-direction: column;
  gap: 50px;
}

.chart-item {
  width: 100%;
}

.chart-labels {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  font-family: 'Space Grotesk', monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
}

.label-left,
.label-right {
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  flex: 1;
}

.label-left {
  text-align: left;
}

.label-right {
  text-align: right;
}

.chart-name {
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  font-weight: 500;
  letter-spacing: 0.15em;
  flex: 0 0 auto;
  padding: 0 30px;
}

.chart-bar {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
  position: relative;
}

.chart-fill {
  height: 100%;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.4),
    rgba(255, 255, 255, 0.9)
  );
  border-radius: 2px;
  transition: width 1s ease;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.profile-action {
  margin-top: 20px;
}

/* ===== SCREEN 7: MATCHES ===== */

.matches-header {
  margin-bottom: 60px;
}

.matches-grid {
  width: 100%;
  max-width: 600px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  margin-bottom: 60px;
}

.match-card {
  padding: 30px 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.02);
  border-radius: 4px;
  transition: all 0.3s ease;
}

.match-card:hover {
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
}

.match-label {
  font-family: 'Space Grotesk', monospace;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 15px;
}

.match-name {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 20px;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.02em;
}

.profile-divider {
  width: 1px;
  height: 60px;
  background: rgba(255, 255, 255, 0.2);
  margin: 0 auto 50px;
}

.profile-complete {
  margin-bottom: 20px;
}

.complete-text {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 24px;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.02em;
  margin-bottom: 10px;
}

.complete-subtext {
  font-family: 'Space Grotesk', monospace;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: 0.1em;
}

/* Main Screen - Black Mirror App Style with Bottom Tabs */
.main-app-container {
  max-width: 480px;
  margin: 0 auto;
  height: 100vh;
  height: 100dvh; /* Dynamic viewport height for mobile */
  display: flex;
  flex-direction: column;
  background: transparent;
  position: relative;
  overflow: hidden;
}

/* Hide global logo and adjust positioning when main screen (screen8) is active */
#screen8.active {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  z-index: 1000;
  padding: 0 !important;
}

body:has(#screen8.active) .global-logo {
  display: none !important;
}

/* Top Header with Minimized Logo */
.main-app-header {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02) 0%, transparent 100%);
  flex-shrink: 0;
}

.main-app-logo {
  font-family: 'Orbitron', sans-serif;
  font-size: 18px;
  letter-spacing: 0.3em;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 600;
}

/* Content Area (scrollable) */
.main-content-area {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  position: relative;
  -webkit-overflow-scrolling: touch;
}

/* Tab Content Areas */
.main-tab-content {
  display: none;
  min-height: 100%;
  padding: 20px 20px 100px;
  animation: fadeInTab 0.3s ease;
}

.main-tab-content-active {
  display: block;
}

@keyframes fadeInTab {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Bottom Navigation Tabs */
.main-bottom-tabs {
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 12px 0 max(24px, calc(env(safe-area-inset-bottom) + 22px));
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: transparent;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  flex-shrink: 0;
  position: relative;
  z-index: 100;
  margin-bottom: 0;
}

.main-tab-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: all 0.25s ease;
  color: rgba(255, 255, 255, 0.45);
  max-width: 100px;
  position: relative;
}

/* Unread indicator for Chat tab */
.main-tab-btn.has-unread::after {
  content: '';
  position: absolute;
  top: 4px;
  right: 22px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff3b3b;
  box-shadow: 0 0 8px rgba(255, 59, 59, 0.9);
}

.main-tab-btn .tab-icon {
  transition: all 0.25s ease;
}

.tab-label {
  font-size: 11px;
  letter-spacing: 0.05em;
  font-weight: 500;
  transition: all 0.25s ease;
}

.main-tab-btn.main-tab-active {
  color: rgba(255, 255, 255, 0.95);
}

.main-tab-btn.main-tab-active .tab-icon {
  transform: scale(1.1);
}

.main-tab-btn.main-tab-active .tab-label {
  color: rgba(255, 255, 255, 1);
  font-weight: 600;
}

/* Profile Tab Content */
.main-profile-section {
  display: flex;
  flex-direction: column;
  gap: 36px;
}

.main-avatar-area {
  display: flex;
  align-items: center;
  gap: 18px;
}

.main-avatar-circle {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.02));
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Orbitron', sans-serif;
  font-size: 24px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  box-shadow: 0 0 30px rgba(255, 255, 255, 0.1);
}

.main-user-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.main-user-name {
  font-size: 20px;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.95);
}

.main-user-vibe {
  font-size: 13px;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.5);
}

.main-user-credits {
  font-size: 12px;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.45);
  margin-top: 8px;
  display: flex;
  gap: 6px;
  align-items: baseline;
}

.credits-label {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 400;
}

.credits-count {
  font-family: 'Courier New', monospace;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
  font-size: 12px;
}

/* I'm Looking For Section */
.main-looking-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.looking-label {
  font-size: 11px;
  letter-spacing: 0.3em;
  color: rgba(255, 255, 255, 0.4);
  text-transform: uppercase;
  font-weight: 600;
}

.looking-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.looking-checkbox {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.looking-checkbox:hover {
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.04);
}

.looking-checkbox::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.05), transparent);
  transition: left 0.5s ease;
}

.looking-checkbox:hover::before {
  left: 100%;
}

.looking-checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

/* Techy X-mark checkbox */
.checkbox-tech,
.checkbox-custom {
  width: 20px;
  height: 20px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
  flex-shrink: 0;
  position: relative;
}

.looking-checkbox:hover .checkbox-tech,
.looking-checkbox:hover .checkbox-custom {
  border-color: rgba(255, 255, 255, 0.4);
}

.looking-checkbox input[type="checkbox"]:checked + .checkbox-tech,
.looking-checkbox input[type="checkbox"]:checked + .checkbox-custom {
  border-color: rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 
    0 0 0 1px rgba(255, 255, 255, 0.1),
    inset 0 0 20px rgba(255, 255, 255, 0.05);
}

/* Techy X mark - two diagonal lines */
.looking-checkbox input[type="checkbox"]:checked + .checkbox-tech::before,
.looking-checkbox input[type="checkbox"]:checked + .checkbox-tech::after {
  content: '';
  position: absolute;
  width: 12px;
  height: 1.5px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 0 4px rgba(255, 255, 255, 0.3);
}

.looking-checkbox input[type="checkbox"]:checked + .checkbox-tech::before {
  transform: rotate(45deg);
}

.looking-checkbox input[type="checkbox"]:checked + .checkbox-tech::after {
  transform: rotate(-45deg);
}

.checkbox-label {
  font-size: 14px;
  letter-spacing: 0.05em;
  color: rgba(255, 255, 255, 0.8);
  transition: all 0.2s ease;
}

.looking-checkbox input[type="checkbox"]:checked ~ .checkbox-label {
  color: rgba(255, 255, 255, 1);
  text-shadow: 0 0 6px rgba(255, 255, 255, 0.2);
}

/* Call Tab Styles */
.call-tab-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 400px;
  gap: 32px;
  padding: 40px 20px;
}

.call-instruction {
  font-size: 15px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.7);
  text-align: center;
  letter-spacing: 0.04em;
  max-width: 320px;
}

.call-start-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 32px;
  border-radius: 50px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: radial-gradient(circle at top left, rgba(255, 255, 255, 0.08), transparent 70%);
  color: rgba(255, 255, 255, 0.95);
  font-size: 16px;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: all 0.3s ease;
}

.call-start-btn:hover {
  border-color: rgba(255, 255, 255, 0.4);
  background: radial-gradient(circle at top left, rgba(255, 255, 255, 0.12), transparent 70%);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
}

.call-btn-icon {
  flex-shrink: 0;
}

/* Chat Interface Styles */
.chat-container {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 160px);
  height: calc(100dvh - 160px);
  max-height: 600px;
  background: transparent;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
  -webkit-overflow-scrolling: touch;
}

.chat-welcome {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 40px 20px;
  text-align: center;
}

.chat-welcome-icon {
  font-size: 40px;
  opacity: 0.5;
}

.chat-welcome-text {
  font-size: 15px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: 0.04em;
  max-width: 280px;
}

.chat-message {
  display: flex;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 16px;
  max-width: 85%;
  word-wrap: break-word;
  animation: messageSlideIn 0.3s ease;
}

@keyframes messageSlideIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.chat-message.user {
  align-self: flex-end;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  margin-left: auto;
}

.chat-message.assistant {
  align-self: flex-start;
  background: rgba(0, 255, 150, 0.05);
  border: 1px solid rgba(0, 255, 150, 0.15);
}

.chat-message-text {
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.02em;
}

.chat-input-area {
  display: flex;
  gap: 10px;
  padding: 12px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: transparent !important;
}

.chat-input {
  flex: 1;
  padding: 12px 16px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: transparent;
  color: rgba(255, 255, 255, 0.95);
  font-size: 14px;
  letter-spacing: 0.03em;
  outline: none;
  transition: all 0.2s ease;
}

.chat-input:focus {
  border-color: rgba(255, 255, 255, 0.3);
  background: transparent;
}

.chat-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.chat-send-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: transparent;
  color: rgba(255, 255, 255, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.chat-send-btn:hover {
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.08);
}

.chat-send-btn:active {
  transform: scale(0.95);
}

.chat-typing-indicator {
  display: flex;
  gap: 4px;
  padding: 12px 16px;
  align-self: flex-start;
}

.typing-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  animation: typingBounce 1.4s infinite;
}

.typing-dot:nth-child(2) {
  animation-delay: 0.2s;
}

.typing-dot:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes typingBounce {
  0%, 60%, 100% {
    transform: translateY(0);
    opacity: 0.4;
  }
  30% {
    transform: translateY(-8px);
    opacity: 1;
  }
}


.contacts-stub {
  border: 1px dashed rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  padding: 20px;
}

.contact-name {
  font-size: 16px;
  letter-spacing: 0.1em;
}

.contact-subtext {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  margin-top: 6px;
}

.inbox-card {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 18px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.02);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.inbox-title {
  font-size: 17px;
  letter-spacing: 0.15em;
}

.inbox-body {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.6;
}

.inbox-button {
  align-self: flex-start;
}

/* Responsive */
@media (max-width: 768px) {
  .profile-container {
    padding: 30px 18px;
  }
  
  .archetype-text {
    font-size: 28px;
  }
  
  .charts-section {
    gap: 40px;
  }
  
  .chart-name {
    padding: 0 20px;
    font-size: 10px;
  }
  
  .matches-grid {
    gap: 20px;
  }
  
  .match-card {
    padding: 25px 15px;
  }
  
  .match-name {
    font-size: 18px;
  }
}

@media (max-width: 480px) {
  .profile-container {
    padding: 25px 15px;
  }
  
  .archetype-text {
    font-size: 24px;
  }
  
  .charts-section {
    gap: 35px;
    margin-bottom: 50px;
  }
  
  .chart-labels {
    font-size: 10px;
  }
  
  .chart-name {
    padding: 0 15px;
    font-size: 9px;
  }
  
  .matches-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .match-card {
    padding: 20px 15px;
  }
  
  .match-name {
    font-size: 17px;
  }
  
  .complete-text {
    font-size: 22px;
  }
}

.record-button-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  margin-bottom: 40px;
}

.record-button {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: transparent;
  border: 3px solid rgba(255, 255, 255, 0.4);
  cursor: pointer;
  position: relative;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 
    0 0 20px rgba(255, 255, 255, 0.1),
    inset 0 0 20px rgba(255, 255, 255, 0.05);
}

.record-button:hover {
  border-color: rgba(255, 255, 255, 0.6);
  box-shadow: 
    0 0 30px rgba(255, 255, 255, 0.2),
    inset 0 0 30px rgba(255, 255, 255, 0.1);
}

.record-icon {
  width: 50px;
  height: 50px;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  transition: all 0.3s ease;
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.4);
}

.record-button:hover .record-icon {
  background: rgba(255, 255, 255, 1);
  box-shadow: 0 0 25px rgba(255, 255, 255, 0.6);
}

/* Recording state */
.record-button.recording {
  border-color: rgba(255, 255, 255, 0.8);
  animation: recordPulse 1.5s ease-in-out infinite;
}

.record-button.recording .record-icon {
  border-radius: 8px;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.9);
  animation: iconPulse 1.5s ease-in-out infinite;
}

@keyframes recordPulse {
  0%, 100% {
    box-shadow: 
      0 0 20px rgba(255, 255, 255, 0.2),
      inset 0 0 20px rgba(255, 255, 255, 0.1);
  }
  50% {
    box-shadow: 
      0 0 40px rgba(255, 255, 255, 0.4),
      inset 0 0 30px rgba(255, 255, 255, 0.15);
  }
}

@keyframes iconPulse {
  0%, 100% {
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.4);
  }
  50% {
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.7);
  }
}

.timer-display {
  font-family: 'Space Grotesk', monospace;
  font-size: 32px;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.1em;
  font-weight: 300;
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
  min-width: 120px;
  text-align: center;
}

.timer-display.recording {
  animation: timerPulse 1s ease-in-out infinite;
}

@keyframes timerPulse {
  0%, 100% {
    opacity: 0.9;
  }
  50% {
    opacity: 1;
    text-shadow: 0 0 30px rgba(255, 255, 255, 0.5);
  }
}

/* Phrase prompt */
.phrase-prompt {
  width: 100%;
  max-width: 600px;
  text-align: center;
  margin-bottom: 50px;
}

.prompt-text {
  font-family: 'IBM Plex Sans', 'Space Grotesk', sans-serif;
  font-size: 17px;
  color: var(--text-primary);
  letter-spacing: 0.04em;
  line-height: 1.65;
  margin-bottom: 30px;
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
}

.phrase-display {
  width: 100%;
  max-width: 500px;
  margin: 0 auto;
  padding: 40px 30px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.02);
  box-shadow: 
    0 0 30px rgba(255, 255, 255, 0.1),
    inset 0 0 30px rgba(0, 0, 0, 0.3);
}

.phrase-text {
  font-family: 'Space Grotesk', 'IBM Plex Sans', sans-serif;
  font-size: 24px;
  color: rgba(255, 255, 255, 0.95);
  letter-spacing: 0.02em;
  line-height: 1.5;
  font-weight: 400;
  font-style: normal;
  text-shadow: 0 0 25px rgba(255, 255, 255, 0.3);
}

/* Responsive */
@media (max-width: 768px) {
  .voice-scan-container {
    padding: 30px 18px;
  }
  
  .record-button {
    width: 100px;
    height: 100px;
  }
  
  .record-icon {
    width: 40px;
    height: 40px;
  }
  
  .record-button.recording .record-icon {
    width: 32px;
    height: 32px;
  }
  
  .timer-display {
    font-size: 28px;
  }
  
  .prompt-text {
    font-size: 15px;
  }
  
  .phrase-text {
    font-size: 20px;
  }
  
  .phrase-display {
    padding: 35px 25px;
  }
}

@media (max-width: 480px) {
  .voice-scan-container {
    padding: 20px 16px;
  }
  
  .voice-instruction {
    margin-bottom: 30px;
  }
  
  .phrase-prompt {
    margin-bottom: 40px;
  }
  
  .record-button {
    width: 90px;
    height: 90px;
  }
  
  .record-icon {
    width: 36px;
    height: 36px;
  }
  
  .record-button.recording .record-icon {
    width: 28px;
    height: 28px;
  }
  
  .timer-display {
    font-size: 24px;
  }
  
  .prompt-text {
    font-size: 14px;
  }
  
  .phrase-text {
    font-size: 18px;
  }
  
  .phrase-display {
    padding: 30px 20px;
  }
}

