/* FULCRUMAXE — Top Secret Teaser */

@import url('https://fonts.googleapis.com/css2?family=Fira+Mono:wght@400;500;700&display=swap');

:root {
  --bg: #000;
  --fg: #a7ffcb;
  --accent: #00ff66;
  --accent-faint: #00ff6620;
  --accent-dim: #00ff6640;
  --muted: #1a3d2a;
  --border: #0f2f1a;
  --radius: 4px;
  --transition: 0.2s cubic-bezier(.42,0,.58,1);
}

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

html, body {
  background: var(--bg);
  color: var(--fg);
  font-family: 'Fira Mono', monospace;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Matrix Canvas */
#matrix-canvas {
  position: fixed;
  z-index: 0;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  pointer-events: none;
  opacity: 0.18;
}

/* Scanline overlay */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 255, 102, 0.015) 2px,
    rgba(0, 255, 102, 0.015) 4px
  );
}

/* Main container */
.container {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 2rem;
}

/* Classification banner */
.classification-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: #0a0a0a;
  border-bottom: 1px solid var(--border);
  padding: 0.4rem 1rem;
  text-align: center;
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: #1a5e35;
}

/* Logo */
.logo-container {
  margin-bottom: 1rem;
}
.logo-container img {
  height: 2.5rem;
  filter: drop-shadow(0 0 8px var(--accent-faint));
}

/* Glitch title */
.glitch-title {
  font-size: clamp(2rem, 8vw, 4.5rem);
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--accent);
  text-shadow: 0 0 20px var(--accent-faint);
  position: relative;
  text-align: center;
  margin-bottom: 2rem;
  animation: flicker 4s infinite;
}

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

.glitch-title::before {
  color: #ff0040;
  animation: glitch-1 3s infinite linear;
  clip-path: polygon(0 0, 100% 0, 100% 33%, 0 33%);
  opacity: 0.6;
}

.glitch-title::after {
  color: #00d4ff;
  animation: glitch-2 3s infinite linear;
  clip-path: polygon(0 66%, 100% 66%, 100% 100%, 0 100%);
  opacity: 0.6;
}

@keyframes glitch-1 {
  0%, 90%, 100% { transform: none; }
  92% { transform: translate(3px, -1px); }
  94% { transform: translate(-3px, 1px); }
  96% { transform: translate(2px, 2px); }
  98% { transform: translate(-1px, -2px); }
}

@keyframes glitch-2 {
  0%, 88%, 100% { transform: none; }
  90% { transform: translate(-3px, 2px); }
  93% { transform: translate(3px, -1px); }
  95% { transform: translate(-2px, -1px); }
  97% { transform: translate(1px, 3px); }
}

@keyframes flicker {
  0%, 95%, 100% { opacity: 1; }
  96% { opacity: 0.8; }
  97% { opacity: 1; }
  98% { opacity: 0.85; }
}

/* Tagline / terminal prompt */
.terminal-line {
  font-size: clamp(0.75rem, 2.5vw, 1rem);
  color: var(--accent);
  opacity: 0.7;
  margin-bottom: 3rem;
  text-align: center;
  letter-spacing: 0.08em;
}

.terminal-line .prompt {
  color: #1a5e35;
}

.terminal-line .cursor {
  display: inline-block;
  width: 0.6em;
  height: 1.1em;
  background: var(--accent);
  margin-left: 0.2em;
  vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* Redacted blocks */
.classified-section {
  max-width: 520px;
  width: 100%;
  margin-bottom: 3rem;
}

.redacted-block {
  background: #050a07;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem 1.5rem;
  margin-bottom: 1rem;
  position: relative;
  overflow: hidden;
}

.redacted-block::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(0,255,102,0.02) 50%, transparent 100%);
  animation: scan 3s ease-in-out infinite;
}

@keyframes scan {
  0%, 100% { transform: translateX(-100%); }
  50% { transform: translateX(100%); }
}

.redacted-label {
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: #1a3d2a;
  margin-bottom: 0.6rem;
}

.redacted-text {
  position: relative;
  display: inline;
}

.redacted-text .visible {
  color: var(--fg);
  font-size: 0.9rem;
  line-height: 1.6;
  opacity: 0.6;
}

.redacted-text .blacked-out {
  background: #0a1a0f;
  color: #0a1a0f;
  padding: 0.1em 0.3em;
  border-radius: 2px;
  user-select: none;
  transition: all 0.5s;
}

.redacted-text .blacked-out:hover {
  background: var(--accent-faint);
  color: var(--accent);
  text-shadow: 0 0 4px var(--accent-faint);
}

/* Hex stream */
.hex-stream {
  font-size: 0.65rem;
  color: #0d2a17;
  letter-spacing: 0.15em;
  text-align: center;
  margin-bottom: 2.5rem;
  word-break: break-all;
  max-width: 500px;
  line-height: 1.8;
  overflow: hidden;
  height: 3.6em;
}

.hex-stream .decoded {
  color: var(--accent);
  text-shadow: 0 0 6px var(--accent-faint);
  transition: color 0.3s;
}

/* CTA / Waitlist */
.waitlist-section {
  text-align: center;
  margin-bottom: 2rem;
}

.waitlist-btn {
  display: inline-block;
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
  padding: 0.8em 2em;
  font-family: 'Fira Mono', monospace;
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

.waitlist-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, var(--accent-faint), transparent);
  transition: left 0.5s;
}

.waitlist-btn:hover::before {
  left: 100%;
}

.waitlist-btn:hover {
  background: var(--accent-faint);
  box-shadow: 0 0 20px var(--accent-faint), inset 0 0 20px var(--accent-faint);
}

/* Footer */
.footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #0a0a0a;
  border-top: 1px solid var(--border);
  padding: 0.5rem 1.5rem;
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #1a3d2a;
}

.footer .classified-stamp {
  color: #1a3d2a;
  border: 1px solid #1a3d2a;
  padding: 0.2em 0.6em;
  font-size: 0.6rem;
  letter-spacing: 0.3em;
}

/* Modal */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(6px);
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.modal-overlay.open { display: flex; }

.modal {
  background: #070c09;
  border: 1px solid var(--border);
  border-radius: 6px;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 2rem;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 0.8rem;
  right: 1rem;
  background: none;
  border: none;
  color: #1a3d2a;
  font-size: 1.5rem;
  cursor: pointer;
  transition: color var(--transition);
}
.modal-close:hover { color: var(--accent); }

.modal-label {
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: #1a3d2a;
  margin-bottom: 0.5rem;
}

.modal-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.1em;
  margin-bottom: 1.5rem;
}

/* Form */
.waitlist-form { display: flex; flex-direction: column; gap: 1.2rem; }

.form-group { display: flex; flex-direction: column; gap: 0.4rem; }

.form-group label {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg);
  opacity: 0.6;
}

.form-group .required { color: var(--accent); }
.form-group .optional { color: #1a3d2a; font-size: 0.65rem; text-transform: none; letter-spacing: 0; }

.form-group input,
.form-group textarea,
.form-group select {
  background: #0a1a0f;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--fg);
  font-family: 'Fira Mono', monospace;
  font-size: 0.85rem;
  padding: 0.6rem 0.8rem;
  transition: border-color var(--transition);
  outline: none;
  width: 100%;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #1a3d2a;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--accent-dim);
}

.form-group select { cursor: pointer; }
.form-group select option { background: #0a1a0f; color: var(--fg); }

.form-group textarea { resize: vertical; min-height: 70px; }

.submit-btn {
  margin-top: 0.5rem;
  width: 100%;
}
.submit-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Success / Error states */
.form-success, .form-error {
  text-align: center;
  padding: 2rem 0;
}

.success-icon {
  font-size: 1rem;
  color: var(--accent);
  margin-bottom: 1rem;
  letter-spacing: 0.1em;
}

.form-success p { color: var(--fg); opacity: 0.7; font-size: 0.9rem; }
.form-error p { color: #ff4040; font-size: 0.9rem; }

/* Responsive */
@media (max-width: 600px) {
  .container { padding: 4rem 1rem 4rem; }
  .glitch-title { letter-spacing: 0.08em; }
  .redacted-block { padding: 0.9rem 1rem; }
  .footer { flex-direction: column; gap: 0.5rem; padding: 0.8rem; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  #matrix-canvas { display: none !important; }
  .glitch-title::before, .glitch-title::after { animation: none; }
  .glitch-title { animation: none; }
  .redacted-block::before { animation: none; }
  .terminal-line .cursor { animation: none; }
}
