/******************************************************************************
 *
 * File...........: trace.css
 * Project........: EnigmaJS
 * Description....: Estilos para el recorrido de la corriente eléctrica (E0029)
 *
 ******************************************************************************/

#traceBoard {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin: 0 0 20px 0;
    padding: 15px;
    background: var(--color-panel-light);
    border: 1px solid #3d3934;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.5), 0 4px 15px rgba(0, 0, 0, 0.3);
    min-height: 80px;
    overflow-x: auto;
}

.visualization-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: #1a1610;
    padding: 8px;
    border: 1px solid #3d3934;
    border-bottom: none;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    margin-top: 20px;
}

.visualization-controls label {
    font-size: 12px;
    color: var(--color-text-dim);
    margin-right: 10px;
}

.btn-speed {
    background: #2a2520;
    border: 1px solid #4a4540;
    color: var(--color-text-dim);
    padding: 4px 12px;
    font-size: 11px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: var(--font-main);
}

.btn-speed:hover {
    background: #3a3530;
    color: var(--color-text);
}

.btn-speed.active {
    background: #4a4030;
    border-color: var(--color-gold);
    color: var(--color-gold);
}

.trace-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 10px;
}

/* Cada nodo de la traza */
.trace-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #111;
    border: 2px solid #333;
    border-radius: 6px;
    padding: 6px 12px;
    min-width: 60px;
    opacity: 0.3; /* Estado apagado */
    transform: scale(0.95);
    transition: all 0.2s cubic-bezier(0.25, 0.1, 0.25, 1);
}

.trace-node.active {
    opacity: 1;
    transform: scale(1);
    border-color: var(--color-gold);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.5), inset 0 0 5px rgba(212, 175, 55, 0.2);
    background: #1a1610;
}

/* La etiqueta del componente (ej. KEYBOARD, ROTOR I) */
.trace-node-label {
    font-size: 9px;
    font-weight: 600;
    color: var(--color-text-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.trace-node.active .trace-node-label {
    color: #e0d0a0;
}

/* La letra que viaja por el componente */
.trace-node-value {
    font-size: 18px;
    font-weight: bold;
    font-family: var(--font-main);
    color: #444; /* Apagado */
}

.trace-node.active .trace-node-value {
    color: var(--color-gold);
    text-shadow: 0 0 8px rgba(255, 220, 100, 0.8);
}

/* Flecha que conecta los nodos */
.trace-arrow {
    color: #444;
    font-size: 14px;
    opacity: 0.3;
    transition: all 0.2s;
}

.trace-arrow.active {
    color: var(--color-gold);
    opacity: 1;
    text-shadow: 0 0 5px rgba(212, 175, 55, 0.5);
}

/* Placeholder cuando no hay traza (esperando entrada) */
.trace-placeholder {
    color: var(--color-text-dim);
    font-size: 14px;
    font-style: italic;
    opacity: 0.7;
    letter-spacing: 1px;
}
