/* ============================================================
   terminal.css - Estilos para emulaciones de terminal/consola
   Versión: 2.0 - Variables con prefijo único
   ============================================================ */

/* ============================================================
   VARIABLES: Con prefijo --term- para no colisionar
   ============================================================ */
:root {
  --term-bg: #0a0e27;
  --term-bg-card: #0e0e18;
  --term-bg-term: #030308;
  --term-text: #d8d4c8;
  --term-text-dim: #7a7568;
  --term-accent: #00e87a;
  --term-accent-dim: #007a40;
  --term-gold: #c9a96e;
  --term-rule: #1e1e2e;
  --term-dim: #6a6560;
}

/* ============================================================
   TERMINAL BASE
   ============================================================ */
.terminal {
  background: var(--term-bg-term);
  border: 2px solid var(--term-accent-dim);
  border-radius: 6px;
  padding: 0.9rem 1.4rem;
  margin: 1.8rem 0;
  border-radius: 0 3px 3px 0;
}

.terminal .run-line {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  color: var(--term-accent);
  letter-spacing: 0.04em;
  line-height: 1.9;
  display: block;
  white-space: pre-wrap;
}

.terminal .run-line.dim {
  color: var(--term-accent-dim);
}

.terminal .run-line.bad {
  color: #e85050;
}

.terminal .run-line.warn {
  color: #e8b450;
}

.cursor {
  display: inline-block;
  width: 0.55em;
  height: 1em;
  background: var(--term-accent);
  vertical-align: text-bottom;
  animation: blink 1.1s step-end infinite;
  margin-left: 2px;
  opacity: 0.8;
}

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

/* ============================================================
   BASE: .quote - Sistema unificado de citas/recuadros
   ============================================================ */

.quote {
    margin: 1.5rem 0;
    padding: 1.5rem 2rem;
    border-radius: 0;
    position: relative;
    transition: all 0.3s ease;
    overflow: hidden;
    word-wrap: break-word;
}

.quote .quote-text {
    font-size: 1.05rem;
    line-height: 1.7;
    padding: 0.5rem 0;
}

.quote .quote-author {
    display: block;
    text-align: right;
    font-size: 0.85rem;
    font-weight: 600;
    margin-top: 0.8rem;
    letter-spacing: 0.5px;
    opacity: 0.8;
}

.quote .quote-source {
    display: block;
    text-align: right;
    font-size: 0.75rem;
    opacity: 0.6;
    margin-top: 0.2rem;
}

/* ============================================================
   TERMINAL / CONSOLA (estilo quote.terminal)
   ============================================================ */

.quote.terminal {
    background: #0a0a0a;
    padding: 25px 30px;
    border-left: 4px solid #8b7a5a;
    font-family: 'Courier New', monospace;
    font-size: 0.95em;
    line-height: 1.8;
    color: var(--term-accent);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
    border-radius: 0;
}

.quote.terminal .quote-text {
    color: var(--term-accent);
    font-size: 0.95em;
    font-family: 'Courier New', monospace;
    padding: 0;
}

.quote.terminal .quote-author {
    color: #4ecdc4;
    opacity: 0.7;
}

.quote.terminal .quote-source {
    color: #4ecdc4;
    opacity: 0.5;
}

.quote.terminal.odd {
    border-left-color: #2d5a2d;
}

.quote.terminal.odd .quote-text {
    color: #88ff88;
}

.quote.terminal.even {
    border-left-color: #1a3a5a;
}

.quote.terminal.even .quote-text {
    color: #88ddff;
}

/* ---- Pregunta en terminal ---- */
.quote .terminal-question {
    color: #00ccff;
    margin: 12px 0 6px 0;
    font-family: 'Courier New', monospace;
    word-wrap: break-word;
    display: block;
}

.quote .terminal-question.last-line {
    margin-bottom: 0;
}

/* ---- Respuesta en terminal ---- */
.quote .terminal-answer {
    color: var(--term-accent);
    margin: 6px 0 12px 20px;
    padding-left: 10px;
    border-left: 2px solid #2a4a3a;
    font-family: 'Courier New', monospace;
    word-wrap: break-word;
    display: block;
}

.quote .terminal-answer.last-line {
    margin-bottom: 0;
}

.quote.terminal.odd .terminal-answer {
    background: rgba(0, 30, 0, 0.3);
    border-left-color: #2d8a2d;
    color: #ffffff;
    background: #41553c;
}

.quote.terminal.even .terminal-answer {
    background: rgba(0, 0, 40, 0.3);
    border-left-color: #00ffff;
    color: #ffffff;
    background: #3f5a90;
}

/* ---- Cursor parpadeante ---- */
.blink-cursor {
    display: none;
    animation: blink 1s step-end infinite;
    color: #7bc87b;
    margin-left: 2px;
    font-weight: 400;
}

.quote .last-line .blink-cursor {
    display: inline-block;
}

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

/* ---- Terminal dentro de acordeones (entrevistas) ---- */
.entrevistas-container .quote.terminal .terminal-question {
    color: #00ccff !important;
    margin: 15px 0 5px 0;
    word-wrap: break-word;
}

.entrevistas-container .quote.terminal .terminal-answer {
    color: #4ecdc4 !important;
    margin: 5px 0 15px 20px;
    padding-left: 10px;
    border-left: 2px solid #4ecdc4;
    word-wrap: break-word;
}

.entrevistas-container .quote.terminal .last-line {
    margin-bottom: 0;
}

.entrevistas-container .quote.terminal .blink-cursor {
    animation: blink 1s step-end infinite;
    display: inline-block;
    color: #00ff41;
}

/* ---- Terminal en estilo oscuro tipo consola ---- */
.entrevistas-container .acordeon-item .quote.terminal {
    background: #0a0a0a;
    color: #00ff41;
    font-family: 'Courier New', monospace;
    border-left-color: #00ff41;
}

.entrevistas-container .acordeon-item .quote.terminal .quote-text {
    color: #00ff41;
}

.entrevistas-container .acordeon-item .quote.terminal p {
    color: #cccccc !important;
    margin: 10px 0;
    line-height: 1.6;
    word-wrap: break-word;
    max-width: 90%;
    box-sizing: border-box;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 768px) {
    .quote {
        padding: 1.2rem 1.5rem;
    }
    .quote .quote-text {
        font-size: 1rem;
    }
    .quote.terminal {
        padding: 18px 20px;
        font-size: 0.9em;
    }
    .quote .terminal-question,
    .quote .terminal-answer {
        font-size: 0.9em;
    }
    .quote .terminal-answer {
        margin-left: 12px;
        padding-left: 8px;
    }
    .entrevistas-container .acordeon-item .quote.terminal p {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .quote {
        padding: 1rem;
    }
    .quote .quote-text {
        font-size: 0.9rem;
    }
    .quote.terminal {
        padding: 12px 14px;
        font-size: 0.8em;
        border-left-width: 3px;
    }
    .quote .terminal-question {
        margin: 8px 0 4px 0;
    }
    .quote .terminal-answer {
        margin: 4px 0 8px 8px;
        padding-left: 6px;
        border-left-width: 2px;
    }
}