/* ============================================
   OFICINANTE — Estilos del Purgatorio de Cristal
   ============================================ */

:root {
  --gris-expediente: #8C8C8C;
  --azul-bsod: #4D4DFF;
  --oro-24k: #FFD700;
  --negro-terminal: #0a0a0a;
  --gris-claro: #c0c0c0;
  --gris-oscuro: #1a1a1a;
  --gris-ventana: #c0c0c0;
  --blanco: #e0e0e0;
  --rojo-error: #ff3333;
  --verde-terminal: #00ff41;
  --font-mono: 'Space Mono', monospace;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-mono);
  background-color: var(--negro-terminal);
  color: var(--blanco);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: var(--oro-24k);
  text-decoration: none;
  transition: opacity 0.2s;
}

a:hover {
  opacity: 0.8;
}

/* UTILIDADES */
.gold {
  color: var(--oro-24k);
  font-weight: 700;
}

.blink {
  animation: blink 1s step-end infinite;
}

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

/* FADE IN (activado por JS) */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   NAV
   ============================================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  background: rgba(10, 10, 10, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 215, 0, 0.15);
}

.nav__logo {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--oro-24k);
  letter-spacing: 0.15em;
}

.nav__links {
  list-style: none;
  display: flex;
  gap: 2rem;
}

.nav__links a {
  color: var(--gris-expediente);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: color 0.2s;
}

.nav__links a:hover {
  color: var(--oro-24k);
  opacity: 1;
}

/* ============================================
   HERO
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 6rem 2rem 4rem;
  position: relative;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(0, 0, 170, 0.15) 0%, transparent 60%),
    var(--negro-terminal);
}

.hero__content {
  max-width: 800px;
  margin-bottom: 3rem;
}

.hero__aliases {
  color: var(--gris-expediente);
  font-size: 0.85rem;
  font-style: italic;
  margin-top: 1.5rem;
}

.hero__tagline {
  color: var(--azul-bsod);
  font-size: 0.8rem;
  margin-top: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.hero__image {
  max-width: 400px;
  width: 100%;
}

.hero__image img {
  width: 100%;
  height: auto;
  border: 2px solid var(--oro-24k);
  filter: saturate(0.8) contrast(1.1);
}

/* GLITCH */
.glitch {
  font-size: clamp(3rem, 10vw, 7rem);
  font-weight: 700;
  color: var(--blanco);
  letter-spacing: 0.15em;
  position: relative;
  text-transform: uppercase;
}

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

.glitch::before {
  color: var(--oro-24k);
  animation: glitch-1 3s infinite linear alternate-reverse;
  clip-path: inset(0 0 80% 0);
}

.glitch::after {
  color: var(--azul-bsod);
  animation: glitch-2 2.5s infinite linear alternate-reverse;
  clip-path: inset(80% 0 0 0);
}

@keyframes glitch-1 {
  0% { clip-path: inset(20% 0 60% 0); transform: translate(0); }
  20% { clip-path: inset(10% 0 70% 0); transform: translate(-3px, 2px); }
  40% { clip-path: inset(50% 0 20% 0); transform: translate(3px, -1px); }
  60% { clip-path: inset(30% 0 40% 0); transform: translate(-2px, 1px); }
  80% { clip-path: inset(70% 0 10% 0); transform: translate(1px, -2px); }
  100% { clip-path: inset(5% 0 85% 0); transform: translate(0); }
}

@keyframes glitch-2 {
  0% { clip-path: inset(60% 0 20% 0); transform: translate(0); }
  20% { clip-path: inset(80% 0 5% 0); transform: translate(2px, -1px); }
  40% { clip-path: inset(10% 0 70% 0); transform: translate(-3px, 2px); }
  60% { clip-path: inset(40% 0 30% 0); transform: translate(1px, 1px); }
  80% { clip-path: inset(60% 0 20% 0); transform: translate(-1px, -2px); }
  100% { clip-path: inset(90% 0 2% 0); transform: translate(0); }
}

/* ============================================
   VENTANA WIN95
   ============================================ */
.window {
  background: var(--gris-oscuro);
  border: 2px solid var(--gris-expediente);
  border-top-color: var(--gris-claro);
  border-left-color: var(--gris-claro);
  max-width: 700px;
  width: 100%;
}

.window__bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.3rem 0.5rem;
  background: linear-gradient(90deg, #0000AA, #0000cc);
  user-select: none;
}

.window__title {
  color: white;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.window__buttons {
  display: flex;
  gap: 3px;
}

.window__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  background: var(--gris-claro);
  border: 1px solid;
  border-color: #fff #808080 #808080 #fff;
  color: #000;
  font-size: 0.6rem;
  line-height: 1;
  cursor: default;
}

.window__body {
  padding: 1.5rem;
  font-size: 0.9rem;
  line-height: 1.7;
}

/* ============================================
   MANIFIESTO
   ============================================ */
.manifiesto {
  display: flex;
  justify-content: center;
  padding: 4rem 2rem;
  background: var(--negro-terminal);
}

.manifiesto .window__body p {
  font-style: italic;
  color: var(--gris-claro);
  font-size: 1rem;
  line-height: 1.8;
}

/* ============================================
   SECCIONES GENERALES
   ============================================ */
.section {
  padding: 6rem 2rem;
}

.section__title {
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  color: var(--oro-24k);
  margin-bottom: 3rem;
  text-align: center;
  letter-spacing: 0.1em;
}

/* ============================================
   ORIGEN
   ============================================ */
.origen {
  background:
    linear-gradient(180deg, var(--negro-terminal) 0%, rgba(0, 0, 170, 0.05) 50%, var(--negro-terminal) 100%);
}

.origen__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  max-width: 1100px;
  margin: 0 auto;
  align-items: start;
}

.origen__text p {
  margin-bottom: 1.2rem;
  font-size: 0.95rem;
  color: var(--gris-claro);
}

/* TERMINAL */
.terminal {
  background: #0c0c0c;
  border: 1px solid #333;
  border-radius: 8px;
  overflow: hidden;
  font-size: 0.8rem;
}

.terminal__header {
  display: flex;
  gap: 6px;
  padding: 0.6rem 0.8rem;
  background: #1a1a1a;
}

.terminal__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.terminal__dot--red { background: #ff5f57; }
.terminal__dot--yellow { background: #febc2e; }
.terminal__dot--green { background: #28c840; }

.terminal__body {
  padding: 1rem;
  line-height: 1.8;
}

.terminal__body p {
  margin-bottom: 0.2rem;
}

.terminal__prompt {
  color: var(--verde-terminal);
  font-weight: 700;
}

.terminal__dim {
  color: var(--gris-expediente);
}

.terminal__warn {
  color: #febc2e;
}

.terminal__error {
  color: var(--rojo-error);
}

.terminal__gold {
  color: var(--oro-24k);
  font-weight: 700;
}

/* ============================================
   DISCOGRAFÍA
   ============================================ */
.discografia {
  background: var(--negro-terminal);
}

.discografia__subtitle {
  text-align: center;
  color: var(--gris-expediente);
  font-size: 0.85rem;
  font-style: italic;
  margin-top: -2rem;
  margin-bottom: 3rem;
}

.discografia__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

.window--card {
  max-width: none;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.window--card:hover {
  transform: translateY(-4px);
  border-color: var(--oro-24k);
}

.window__body--card {
  text-align: center;
  padding: 2rem 1.5rem;
}

.card__icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.card__title {
  font-size: 1.1rem;
  color: var(--blanco);
  margin-bottom: 0.5rem;
}

.card__inspiration {
  font-size: 0.75rem;
  color: var(--azul-bsod);
  font-style: italic;
  margin-bottom: 0.5rem;
}

.card__theme {
  font-size: 0.8rem;
  color: var(--gris-expediente);
  margin-bottom: 1.5rem;
}

/* WAVEFORM ANIMADO */
.card__waveform {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 3px;
  height: 30px;
}

.card__waveform span {
  display: inline-block;
  width: 3px;
  background: var(--oro-24k);
  border-radius: 2px;
  animation: waveform 1.2s ease-in-out infinite;
}

.card__waveform span:nth-child(1)  { animation-delay: 0s;    height: 8px; }
.card__waveform span:nth-child(2)  { animation-delay: 0.1s;  height: 14px; }
.card__waveform span:nth-child(3)  { animation-delay: 0.05s; height: 20px; }
.card__waveform span:nth-child(4)  { animation-delay: 0.15s; height: 10px; }
.card__waveform span:nth-child(5)  { animation-delay: 0.2s;  height: 24px; }
.card__waveform span:nth-child(6)  { animation-delay: 0.08s; height: 16px; }
.card__waveform span:nth-child(7)  { animation-delay: 0.25s; height: 12px; }
.card__waveform span:nth-child(8)  { animation-delay: 0.12s; height: 22px; }
.card__waveform span:nth-child(9)  { animation-delay: 0.18s; height: 8px; }
.card__waveform span:nth-child(10) { animation-delay: 0.3s;  height: 18px; }
.card__waveform span:nth-child(11) { animation-delay: 0.06s; height: 26px; }
.card__waveform span:nth-child(12) { animation-delay: 0.22s; height: 14px; }
.card__waveform span:nth-child(13) { animation-delay: 0.14s; height: 10px; }
.card__waveform span:nth-child(14) { animation-delay: 0.28s; height: 20px; }
.card__waveform span:nth-child(15) { animation-delay: 0.02s; height: 16px; }
.card__waveform span:nth-child(16) { animation-delay: 0.16s; height: 12px; }
.card__waveform span:nth-child(17) { animation-delay: 0.24s; height: 24px; }
.card__waveform span:nth-child(18) { animation-delay: 0.1s;  height: 8px; }
.card__waveform span:nth-child(19) { animation-delay: 0.2s;  height: 18px; }
.card__waveform span:nth-child(20) { animation-delay: 0.04s; height: 14px; }

@keyframes waveform {
  0%, 100% { transform: scaleY(0.4); }
  50% { transform: scaleY(1); }
}

/* CARD LOCKED (próximamente) */
.window--card-locked {
  opacity: 0.6;
  border-style: dashed;
}

.window--card-locked:hover {
  transform: none;
  border-color: var(--gris-expediente);
}

.card__status {
  margin-top: 1rem;
  font-size: 0.8rem;
  color: var(--oro-24k);
  letter-spacing: 0.15em;
  animation: blink 2s step-end infinite;
}

/* ============================================
   CONTACTO
   ============================================ */
.contacto {
  background:
    linear-gradient(180deg, var(--negro-terminal) 0%, rgba(0, 0, 170, 0.05) 50%, var(--negro-terminal) 100%);
}

.contacto__grid {
  display: flex;
  justify-content: center;
}

.contacto .window__body p {
  font-size: 0.85rem;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  text-align: center;
  padding: 2rem;
  border-top: 1px solid rgba(255, 215, 0, 0.1);
  font-size: 0.75rem;
  color: var(--gris-expediente);
}

.footer__sub {
  margin-top: 0.5rem;
  font-style: italic;
  font-size: 0.65rem;
  opacity: 0.6;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .nav__links {
    display: none;
  }

  .hero {
    padding: 5rem 1.5rem 3rem;
  }

  .hero__image {
    max-width: 300px;
  }

  .origen__grid {
    grid-template-columns: 1fr;
  }

  .discografia__grid {
    grid-template-columns: 1fr;
    max-width: 400px;
    margin: 0 auto;
  }

  .section {
    padding: 4rem 1.5rem;
  }

  .manifiesto {
    padding: 3rem 1.5rem;
  }

  .window__body {
    padding: 1rem;
  }
}

@media (max-width: 480px) {
  .glitch {
    letter-spacing: 0.08em;
  }

  .hero__aliases {
    font-size: 0.75rem;
  }
}
