/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

:root {
  --bg-color: #050505;
  --text-color: #e0e0e0;
  --neon-cyan: #00f3ff;
  --neon-pink: #ff00ff;
  --neon-purple: #bc13fe;
  --neon-green: #0aff9d;
  --glass-bg: rgba(255, 255, 255, 0.05);
  --border-color: #333;
  --font-header: "Orbitron", sans-serif;
  --font-body: "Inter", sans-serif;
  --font-mono: "Space Mono", monospace;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text-color);
  background: #0b0b0b;
}

.welcome-body {
  background: radial-gradient(circle at top, #140f1f 0%, #050505 40%, #020202 100%);
  overflow-x: hidden;
  min-height: 100vh;
}

.welcome-main {
  padding: 0;
}

.scanline,
.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 5;
}

.scanline {
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0),
    rgba(255, 255, 255, 0) 50%,
    rgba(0, 0, 0, 0.2) 50%,
    rgba(0, 0, 0, 0.2)
  );
  background-size: 100% 4px;
  opacity: 0.6;
  animation: scanline-shift 6s linear infinite;
}

.noise {
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

.particle-field {
  position: fixed;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}

.particle {
  position: absolute;
  width: 2px;
  height: 2px;
  background: var(--neon-cyan);
  opacity: 0.7;
  animation: particle-float linear infinite;
}

.welcome-hero {
  min-height: 90vh;
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(240px, 1fr);
  align-items: center;
  gap: 3rem;
  padding: 6rem 10%;
  position: relative;
  z-index: 10;
}

.welcome-content {
  max-width: 640px;
}

.welcome-kicker {
  font-family: var(--font-mono);
  color: var(--neon-green);
  letter-spacing: 2px;
  margin-bottom: 1rem;
  text-transform: uppercase;
}

.glitch-title {
  font-family: var(--font-header);
  font-size: clamp(2.8rem, 6vw, 5rem);
  text-transform: uppercase;
  position: relative;
  color: #ffffff;
  text-shadow: 2px 2px var(--neon-purple), -2px -2px var(--neon-cyan);
  margin: 0 0 1rem;
}

.glitch-title::before,
.glitch-title::after {
  content: attr(data-text);
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  overflow: hidden;
  opacity: 0.7;
}

.glitch-title::before {
  color: var(--neon-pink);
  transform: translate(2px, -2px);
  animation: glitch 2.5s infinite;
}

.glitch-title::after {
  color: var(--neon-cyan);
  transform: translate(-2px, 2px);
  animation: glitch 3s infinite;
}

.typing-effect {
  font-family: var(--font-mono);
  font-size: 1.2rem;
  letter-spacing: 2px;
  color: var(--neon-cyan);
  margin: 0 0 1.5rem;
  min-height: 1.6rem;
}

.welcome-subtitle {
  font-size: 1.05rem;
  color: #b9b9b9;
  margin-bottom: 2rem;
}

.welcome-actions {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.welcome-hint {
  font-size: 0.85rem;
  color: #8a8a8a;
  font-family: var(--font-mono);
}

.cyber-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 32px;
  font-family: var(--font-header);
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
  color: var(--bg-color);
  background: var(--neon-cyan);
  clip-path: polygon(10% 0, 100% 0, 100% 70%, 90% 100%, 0 100%, 0 30%);
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
  box-shadow: 0 0 15px rgba(0, 243, 255, 0.4);
}

.cyber-btn:hover {
  background: var(--neon-pink);
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--neon-purple);
}

.welcome-visual {
  position: relative;
  min-height: 320px;
}

.neon-orb {
  width: 260px;
  height: 260px;
  border-radius: 50%;
  border: 2px solid var(--neon-cyan);
  box-shadow: 0 0 30px var(--neon-cyan), inset 0 0 30px var(--neon-cyan);
  animation: pulse 4s ease-in-out infinite;
  margin: 0 auto;
}

.neon-ring {
  position: absolute;
  inset: 20px;
  border-radius: 50%;
  border: 2px dashed var(--neon-pink);
  animation: spin 12s linear infinite;
}

.neon-grid {
  position: absolute;
  inset: -40px;
  background-image: linear-gradient(transparent 70%, rgba(0, 243, 255, 0.1)),
    linear-gradient(90deg, transparent 70%, rgba(188, 19, 254, 0.12));
  background-size: 30px 30px;
  transform: rotateX(60deg);
  opacity: 0.3;
}

.welcome-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  padding: 0 10% 5rem;
  position: relative;
  z-index: 10;
}

.feature-card {
  padding: 1.5rem;
  border: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(6px);
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.feature-card h3 {
  margin: 0 0 0.75rem;
  color: var(--neon-pink);
  font-family: var(--font-header);
  font-size: 1.1rem;
}

.feature-card p {
  margin: 0;
  text-transform: none;
  font-family: var(--font-body);
  color: #b5b5b5;
}

.welcome-setup {
  padding: 0 10% 6rem;
  position: relative;
  z-index: 10;
}

.setup-title {
  font-family: var(--font-header);
  font-size: clamp(1.6rem, 4vw, 2.6rem);
  margin: 0 0 1.5rem;
  color: var(--neon-purple);
  text-transform: uppercase;
  letter-spacing: 2px;
}

.setup-steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 1rem;
  font-family: var(--font-body);
}

.setup-steps li {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  padding: 1rem 1.2rem;
  border-left: 3px solid var(--neon-cyan);
}

.setup-steps a {
  color: var(--neon-cyan);
  text-decoration: none;
}

.setup-steps a:hover {
  color: var(--neon-pink);
}

.setup-fields {
  margin-top: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: #c8c8c8;
  display: grid;
  gap: 0.3rem;
}

.setup-note {
  margin-top: 1rem;
  font-family: var(--font-mono);
  color: #9f9f9f;
  font-size: 0.85rem;
}

.credential-panel {
  min-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 8%;
  position: relative;
  z-index: 10;
}

.credential-card {
  width: min(560px, 100%);
  background: rgba(8, 8, 10, 0.9);
  border: 1px solid var(--border-color);
  padding: 2.5rem;
  box-shadow: 0 0 35px rgba(0, 243, 255, 0.12);
}

.credential-form {
  display: grid;
  gap: 1.2rem;
  margin-top: 1.5rem;
}

.field-group {
  display: grid;
  gap: 0.35rem;
  font-family: var(--font-mono);
  color: #c9c9c9;
}

.cyber-input {
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(0, 243, 255, 0.3);
  padding: 0.65rem 0.75rem;
  color: #f5f5f5;
  font-family: var(--font-mono);
  outline: none;
}

.cyber-input:focus {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 243, 255, 0.4);
}

.field-hint {
  font-size: 0.8rem;
  color: #9c9c9c;
}

.credential-links {
  margin-top: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: #9a9a9a;
  display: flex;
  gap: 0.6rem;
  align-items: center;
}

.credential-links a {
  color: var(--neon-cyan);
  text-decoration: none;
}

.credential-links a:hover {
  color: var(--neon-pink);
}

.divider {
  color: #666;
}

.auth-choice {
  margin-top: 1.5rem;
  display: grid;
  gap: 0.5rem;
}

.choice-title {
  font-family: var(--font-header);
  color: var(--neon-pink);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.choice-detail {
  font-size: 0.85rem;
  color: #b0b0b0;
  font-family: var(--font-body);
}

.cyber-btn.secondary {
  background: transparent;
  color: var(--neon-cyan);
  border: 1px solid var(--neon-cyan);
  box-shadow: none;
}

.cyber-btn.secondary:hover {
  background: rgba(0, 243, 255, 0.12);
  box-shadow: 0 0 10px rgba(0, 243, 255, 0.4);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 30px var(--neon-cyan);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 0 45px var(--neon-cyan), 0 0 18px var(--neon-pink);
  }
}

@keyframes glitch {
  0%,
  100% {
    clip-path: inset(0 0 0 0);
  }
  20% {
    clip-path: inset(10% 0 40% 0);
  }
  40% {
    clip-path: inset(50% 0 20% 0);
  }
  60% {
    clip-path: inset(30% 0 60% 0);
  }
  80% {
    clip-path: inset(70% 0 10% 0);
  }
}

@keyframes scanline-shift {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(4px);
  }
}

@keyframes particle-float {
  0% {
    transform: translateY(0);
    opacity: 0.1;
  }
  20% {
    opacity: 0.8;
  }
  100% {
    transform: translateY(-120vh);
    opacity: 0;
  }
}

@media (max-width: 900px) {
  .welcome-hero {
    grid-template-columns: 1fr;
    padding: 5rem 8%;
  }

  .welcome-visual {
    order: -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .scanline,
  .noise,
  .particle,
  .glitch-title::before,
  .glitch-title::after,
  .neon-ring,
  .neon-orb {
    animation: none !important;
  }
}
