/* ===========================
   Variables CSS
   =========================== */
:root {
    --color-bg: #0a0e27;
    --color-brain: #d4af77;
    --color-neuron: #4a5f7f;
    --color-node-active: #ffd700;
    --color-node-visited: #5a7fa5;
    --color-node-pending: #e8e8e8;
    --color-text: #f5f5f0;
    --color-text-dim: #b8b8b0;
    --color-accent: #ffd700;
    --color-panel-bg: rgba(20, 25, 50, 0.85);
    
    --font-display: 'Crimson Pro', serif;
    --font-body: 'IBM Plex Sans', sans-serif;
    
    --transition-speed: 400ms;
    --transition-ease: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===========================
   Reset y Base
   =========================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--color-bg);
    color: var(--color-text);
    overflow-x: hidden;
    min-height: 100vh;
}

/* ===========================
   Partículas de Fondo
   =========================== */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 3px;
    height: 3px;
    background: var(--color-accent);
    border-radius: 50%;
    opacity: 0;
    animation: float 8s infinite ease-in-out;
    box-shadow: 0 0 10px var(--color-accent);
}

@keyframes float {
    0%, 100% {
        opacity: 0;
        transform: translateY(0) translateX(0);
    }
    50% {
        opacity: 0.6;
        transform: translateY(-100px) translateX(50px);
    }
}

/* ===========================
   Header y Navegación
   =========================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: linear-gradient(180deg, rgba(10, 14, 39, 0.95) 0%, rgba(10, 14, 39, 0) 100%);
    backdrop-filter: blur(10px);
    padding: 1.5rem 2rem;
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.title {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-accent);
    margin-bottom: 0.5rem;
    text-align: center;
}

.progress-info {
    flex: 1;
    max-width: 500px;
}

.progress-text {
    font-size: 0.9rem;
    color: var(--color-text-dim);
    text-align: center;
    margin-bottom: 0.75rem;
}

.progress-text span {
    color: var(--color-accent);
    font-weight: 500;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background: rgba(255, 215, 0, 0.2);
    border-radius: 2px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--color-accent);
    border-radius: 2px;
    transition: width var(--transition-speed) var(--transition-ease);
    box-shadow: 0 0 10px var(--color-accent);
}

.nav-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 215, 0, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 8px;
    color: var(--color-accent);
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-speed) var(--transition-ease);
}

.nav-btn:hover {
    background: rgba(255, 215, 0, 0.2);
    border-color: var(--color-accent);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3);
}

.nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    transform: none;
}

.nav-btn:disabled:hover {
    background: rgba(255, 215, 0, 0.1);
    border-color: rgba(255, 215, 0, 0.3);
    box-shadow: none;
}

/* ===========================
   Contenedor Principal
   =========================== */
.main-container {
    position: relative;
    display: flex;
    min-height: 100vh;
    padding-top: 120px;
    z-index: 10;
}

/* ===========================
   Cerebro
   =========================== */
.brain-container {
    flex: 1;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.brain-svg {
    width: 100%;
    max-width: 800px;
    height: auto;
    filter: drop-shadow(0 0 20px rgba(212, 175, 119, 0.3));
}

@media (max-width: 768px) {
    .brain-svg {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .brain-svg {
        max-width: 95%;
        margin: 0 auto;
    }
}

.brain-outline {
    fill: none;
    stroke: #26c6da;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0.9;
    filter: drop-shadow(0 0 8px #26c6da) drop-shadow(0 0 12px #00acc1);
}

/* Líneas del cerebro (estructura anatómica) */
.brain-line {
    fill: none;
    stroke: #26c6da;
    stroke-width: 1.8;
    stroke-miterlimit: 10;
    opacity: 0.6;
    filter: drop-shadow(0 0 2px #26c6da);
    transition: all 0.5s ease;
}

/* Líneas iluminadas cuando un nodo está activo */
.brain-line.active {
    stroke: #00e5ff;
    opacity: 1;
    stroke-width: 2.5;
    filter: drop-shadow(0 0 8px #00e5ff) 
            drop-shadow(0 0 12px rgba(0, 229, 255, 0.6));
    animation: lineGlow 2s ease-in-out infinite;
}

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

.brain-structure {
    animation: brainPulse 4s infinite ease-in-out;
}

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

/* Red Neuronal */
.neural-connection {
    stroke: #4dd0e1;
    stroke-width: 1.5;
    fill: none;
    opacity: 0.25;
    transition: all var(--transition-speed) var(--transition-ease);
}

.neural-connection.active {
    stroke: #00e5ff;
    stroke-width: 2.5;
    opacity: 0.9;
    filter: drop-shadow(0 0 5px #00e5ff);
    animation: electricPulse 1.5s ease-in-out;
}

@keyframes electricPulse {
    0%, 100% {
        stroke-dashoffset: 1000;
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
}

/* ===========================
   ACTIVACIONES NEURONALES
   ========================== */

/* Grupo de activación neural */
.neural-activation {
    cursor: pointer;
    transition: all 0.5s ease;
    opacity: 0.8;
}

/* Núcleo de la activación - el punto central */
.activation-core {
    fill: rgba(38, 198, 218, 0.9);
    filter: blur(0.5px) drop-shadow(0 0 3px rgba(38, 198, 218, 1));
    transition: all 0.5s ease;
}

/* Halo de difusión alrededor */
.activation-halo {
    fill: rgba(38, 198, 218, 0.15);
    stroke: rgba(38, 198, 218, 0.4);
    stroke-width: 0.8;
    filter: blur(2.5px);
    transition: all 0.5s ease;
}

/* Número de evento - tipografía orgánica */
.activation-number {
    fill: rgba(255, 255, 255, 0.98);
    font-family: 'IBM Plex Sans', system-ui, sans-serif;
    font-size: 9px;
    font-weight: 700;
    text-anchor: middle;
    dominant-baseline: middle;
    pointer-events: none;
    letter-spacing: 0.3px;
    opacity: 1;
    transition: all 0.5s ease;
    filter: drop-shadow(0 0 3px rgba(38, 198, 218, 1));
}

/* Círculo de fondo para los números */
.number-background {
    fill: rgba(10, 14, 39, 0.88);
    stroke: rgba(38, 198, 218, 0.45);
    stroke-width: 0.6;
    transition: all 0.5s ease;
}

/* Estado: Pendiente - casi invisible, como neurona dormida */
.neural-activation.pending .activation-core {
    fill: rgba(38, 198, 218, 0.3);
    filter: blur(1px) drop-shadow(0 0 1px rgba(38, 198, 218, 0.5));
    r: 3;
}

.neural-activation.pending .activation-halo {
    fill: rgba(38, 198, 218, 0.08);
    stroke: rgba(38, 198, 218, 0.2);
    r: 7;
}

.neural-activation.pending .activation-number {
    fill: rgba(255, 255, 255, 0.75);
    font-size: 7.5px;
    opacity: 0.85;
}

.neural-activation.pending .number-background {
    fill: rgba(10, 14, 39, 0.75);
    stroke: rgba(38, 198, 218, 0.25);
    r: 9;
}

/* Estado: Visitado - activación moderada */
.neural-activation.visited .activation-core {
    fill: rgba(77, 208, 225, 0.8);
    filter: blur(0.8px) drop-shadow(0 0 5px rgba(77, 208, 225, 0.8));
    r: 4;
}

.neural-activation.visited .activation-halo {
    fill: rgba(77, 208, 225, 0.2);
    stroke: rgba(77, 208, 225, 0.45);
    r: 9;
}

.neural-activation.visited .activation-number {
    fill: rgba(255, 255, 255, 0.95);
    opacity: 1;
    font-size: 8.5px;
    font-weight: 700;
}

.neural-activation.visited .number-background {
    fill: rgba(10, 14, 39, 0.85);
    stroke: rgba(77, 208, 225, 0.5);
    r: 10;
}

/* Estado: Activo - NEURONA DISPARANDO */
.neural-activation.active {
    opacity: 1;
}

.neural-activation.active .activation-core {
    fill: rgba(0, 229, 255, 1);
    filter: blur(0.3px) 
           drop-shadow(0 0 10px rgba(0, 229, 255, 1))
           drop-shadow(0 0 18px rgba(0, 229, 255, 0.8))
           drop-shadow(0 0 28px rgba(38, 198, 218, 0.5));
    r: 6;
    animation: neuralPulse 2s ease-in-out infinite;
}

.neural-activation.active .activation-halo {
    fill: rgba(0, 229, 255, 0.35);
    stroke: rgba(0, 229, 255, 0.75);
    stroke-width: 1.2;
    filter: blur(4px);
    r: 16;
    animation: haloPulse 2s ease-in-out infinite;
}

.neural-activation.active .activation-number {
    fill: #ffffff;
    font-size: 10px;
    font-weight: 800;
    opacity: 1;
    filter: drop-shadow(0 0 4px rgba(0, 229, 255, 1))
            drop-shadow(0 0 8px rgba(0, 229, 255, 0.7));
    animation: textGlow 2s ease-in-out infinite;
}

.neural-activation.active .number-background {
    fill: rgba(10, 14, 39, 0.9);
    stroke: rgba(0, 229, 255, 0.8);
    stroke-width: 1;
    r: 12;
    filter: drop-shadow(0 0 6px rgba(0, 229, 255, 0.5));
    animation: backgroundPulse 2s ease-in-out infinite;
}

/* Animaciones de activación neural */
@keyframes neuralPulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

@keyframes haloPulse {
    0%, 100% {
        opacity: 0.3;
        r: 12;
    }
    50% {
        opacity: 0.15;
        r: 15;
    }
}

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

@keyframes backgroundPulse {
    0%, 100% {
        opacity: 0.9;
        r: 12;
    }
    50% {
        opacity: 0.7;
        r: 13;
    }
}

/* Hover - activación sutil */
.neural-activation:hover .activation-core {
    fill: rgba(0, 229, 255, 0.95);
    filter: blur(0.4px) drop-shadow(0 0 12px rgba(0, 229, 255, 0.95));
    r: 5;
}

.neural-activation:hover .activation-halo {
    fill: rgba(0, 229, 255, 0.3);
    stroke: rgba(0, 229, 255, 0.65);
    r: 13;
}

.neural-activation:hover .activation-number {
    fill: #ffffff;
    opacity: 1;
    font-size: 9.5px;
    font-weight: 800;
}

.neural-activation:hover .number-background {
    fill: rgba(10, 14, 39, 0.9);
    stroke: rgba(0, 229, 255, 0.7);
    r: 11;
}

/* Mini-mapa */
.mini-activation {
    fill: rgba(38, 198, 218, 0.4);
    transition: all 0.3s ease;
}

.mini-activation.active {
    fill: rgba(0, 229, 255, 1);
    filter: drop-shadow(0 0 2px rgba(0, 229, 255, 0.8));
}

/* Tooltip */
.node-tooltip {
    position: absolute;
    background: rgba(10, 14, 39, 0.95);
    border: 1px solid var(--color-accent);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    font-size: 0.85rem;
    color: var(--color-text);
    pointer-events: none;
    white-space: nowrap;
    z-index: 1000;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.node-tooltip.visible {
    opacity: 1;
    transform: translateY(0);
}

.tooltip-year {
    color: var(--color-accent);
    font-weight: 600;
    display: block;
    margin-bottom: 0.25rem;
}

/* ===========================
   Mini-mapa
   =========================== */
.mini-map {
    position: absolute;
    bottom: 2rem;
    right: 2rem;
    width: 150px;
    height: 112px;
    background: rgba(10, 14, 39, 0.9);
    border: 1px solid rgba(212, 175, 119, 0.3);
    border-radius: 8px;
    padding: 0.5rem;
    backdrop-filter: blur(10px);
}

.mini-map svg {
    width: 100%;
    height: 100%;
}

#miniMapNodes circle {
    fill: var(--color-node-pending);
    opacity: 0.6;
}

#miniMapNodes circle.active {
    fill: var(--color-accent);
    opacity: 1;
}

/* ===========================
   Botón de Información
   =========================== */
.info-btn {
    position: absolute;
    bottom: 2rem;
    left: 2rem;
    width: 50px;
    height: 50px;
    background: rgba(255, 215, 0, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 50%;
    color: var(--color-accent);
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all var(--transition-speed) var(--transition-ease);
    z-index: 10;
}

.info-btn:hover {
    background: rgba(255, 215, 0, 0.2);
    border-color: var(--color-accent);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.4);
}

/* Estilos táctiles para móviles */
@media (hover: none) and (pointer: coarse) {
    .info-btn:active {
        background: rgba(255, 215, 0, 0.25);
        transform: scale(0.95);
    }
    
    .nav-btn:active {
        transform: scale(0.95);
    }
    
    .info-modal-close:active {
        transform: scale(0.9) rotate(90deg);
    }
    
    .neural-activation:active .activation-core {
        r: 6;
    }
}

/* ===========================
   Modal de Información
   =========================== */
.info-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 14, 39, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

.info-modal.active {
    display: flex;
}

.info-modal-content {
    background: var(--color-panel-bg);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(212, 175, 119, 0.3);
    border-radius: 12px;
    padding: 2.5rem;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.4s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.info-modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 36px;
    height: 36px;
    background: rgba(255, 215, 0, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 50%;
    color: var(--color-accent);
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
}

.info-modal-close:hover {
    background: rgba(255, 215, 0, 0.2);
    border-color: var(--color-accent);
    transform: rotate(90deg);
}

.info-modal-title {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-accent);
    margin-bottom: 2rem;
    text-align: center;
}

.info-modal-body {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.info-section {
    padding: 1.25rem;
    background: rgba(10, 14, 39, 0.5);
    border-radius: 8px;
    border: 1px solid rgba(38, 198, 218, 0.2);
}

.info-section h3 {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--color-accent);
    margin-bottom: 1rem;
}

.info-section p {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--color-text);
    margin-bottom: 0.5rem;
}

.info-section p:last-child {
    margin-bottom: 0;
}

.info-section strong {
    color: rgba(77, 208, 225, 1);
    font-weight: 600;
}

.reference {
    font-style: italic;
    padding-left: 1rem;
    border-left: 3px solid var(--color-accent);
}

.info-note {
    background: rgba(255, 215, 0, 0.05);
    border-color: rgba(255, 215, 0, 0.3);
}

.info-note p {
    color: rgba(255, 215, 0, 0.9);
    font-size: 0.95rem;
}

/* ===========================
   Panel de Información
   =========================== */
.info-panel {
    width: 450px;
    background: var(--color-panel-bg);
    backdrop-filter: blur(20px);
    border-left: 1px solid rgba(212, 175, 119, 0.2);
    padding: 2rem;
    overflow-y: auto;
    max-height: calc(100vh - 120px);
    position: sticky;
    top: 120px;
}

.info-content {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.event-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(212, 175, 119, 0.2);
}

.event-number {
    display: inline-block;
    width: 40px;
    height: 40px;
    background: var(--color-accent);
    color: var(--color-bg);
    border-radius: 50%;
    font-size: 1.2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3);
}

.event-title {
    font-family: var(--font-display);
    font-size: 1.6rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--color-accent);
}

.event-body {
    margin-bottom: 1.5rem;
}

.event-description {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--color-text);
    margin-bottom: 1rem;
}

.event-description:last-child {
    margin-bottom: 0;
}

/* ===========================
   Responsive
   =========================== */
@media (max-width: 1200px) {
    .header-content {
        gap: 1.5rem;
    }
    
    .title {
        font-size: 1.3rem;
    }
    
    .info-panel {
        width: 400px;
    }
}

@media (max-width: 1024px) {
    .main-container {
        flex-direction: column;
    }
    
    .info-panel {
        width: 100%;
        max-height: none;
        position: relative;
        top: 0;
        border-left: none;
        border-top: 1px solid rgba(212, 175, 119, 0.2);
    }
    
    .brain-container {
        min-height: 60vh;
    }
    
    .mini-map {
        width: 130px;
        height: 100px;
        bottom: 1.5rem;
        right: 1.5rem;
    }
    
    .info-btn {
        bottom: 1.5rem;
        left: 1.5rem;
        width: 48px;
        height: 48px;
    }
    
    /* Aumentar tamaño de números en tablets */
    .activation-number {
        font-size: 11px;
        stroke-width: 2.8px;
    }
    
    .neural-activation.pending .activation-number {
        font-size: 9px;
        stroke-width: 2.3px;
    }
    
    .neural-activation.visited .activation-number {
        font-size: 10px;
        stroke-width: 2.5px;
    }
    
    .neural-activation.active .activation-number {
        font-size: 12px;
        stroke-width: 3.2px;
    }
}

@media (max-width: 768px) {
    .header {
        padding: 1rem;
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
        max-width: 100%;
        margin: 0;
    }
    
    .title {
        font-size: 1.1rem;
        text-align: left;
        width: 100%;
    }
    
    .progress-info {
        width: 100%;
        max-width: 100%;
    }
    
    .progress-text {
        text-align: left;
    }
    
    .progress-bar {
        width: 100%;
    }
    
    .nav-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.85rem;
    }
    
    .nav-btn span {
        display: none;
    }
    
    .main-container {
        padding-top: 180px;
        flex-direction: column;
    }
    
    .brain-container {
        padding: 1rem;
        min-height: 55vh;
        order: 1;
    }
    
    .info-panel {
        padding: 1.5rem;
        order: 2;
        width: 100%;
    }
    
    .event-title {
        font-size: 1.25rem;
    }
    
    .event-description {
        font-size: 0.95rem;
    }
    
    .mini-map {
        width: 110px;
        height: 85px;
        bottom: 1rem;
        right: 1rem;
    }
    
    .info-btn {
        bottom: 1rem;
        left: 1rem;
        width: 44px;
        height: 44px;
    }
    
    /* Números más grandes y visibles en móviles */
    .activation-number {
        font-size: 12px;
        stroke-width: 3px;
    }
    
    .neural-activation.pending .activation-number {
        font-size: 10px;
        stroke-width: 2.5px;
    }
    
    .neural-activation.visited .activation-number {
        font-size: 11px;
        stroke-width: 2.8px;
    }
    
    .neural-activation.active .activation-number {
        font-size: 14px;
        stroke-width: 3.5px;
    }
    
    /* Nodos más grandes en móvil para mejor interacción táctil */
    .neural-activation.pending .activation-core {
        r: 4;
    }
    
    .neural-activation.pending .activation-halo {
        r: 9;
    }
    
    .neural-activation.visited .activation-core {
        r: 5;
    }
    
    .neural-activation.visited .activation-halo {
        r: 11;
    }
    
    .neural-activation.active .activation-core {
        r: 7;
    }
    
    .neural-activation.active .activation-halo {
        r: 18;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 1rem;
    }
    
    .header-content {
        align-items: flex-start;
        margin: 0;
    }
    
    .title {
        font-size: 1rem;
        text-align: left;
    }
    
    .progress-text {
        font-size: 0.85rem;
        text-align: left;
    }
    
    .nav-btn {
        padding: 0.5rem 1rem;
    }
    
    .main-container {
        padding-top: 200px;
    }
    
    .brain-container {
        padding: 0.5rem;
        min-height: 50vh;
    }
    
    .info-panel {
        padding: 1.25rem;
    }
    
    .event-title {
        font-size: 1.1rem;
    }
    
    .event-description {
        font-size: 0.9rem;
    }
    
    .event-number {
        width: 35px;
        height: 35px;
        font-size: 1.1rem;
    }
    
    .mini-map {
        width: 90px;
        height: 70px;
    }
    
    .info-btn {
        width: 40px;
        height: 40px;
        bottom: 1rem;
        left: 1rem;
    }
    
    .info-btn svg {
        width: 18px;
        height: 18px;
    }
    
    .info-modal-content {
        padding: 1.5rem;
        width: 95%;
        max-height: 85vh;
    }
    
    .info-modal-title {
        font-size: 1.4rem;
        margin-bottom: 1.5rem;
    }
    
    .info-modal-close {
        width: 32px;
        height: 32px;
        top: 0.75rem;
        right: 0.75rem;
    }
    
    .info-modal-close svg {
        width: 18px;
        height: 18px;
    }
    
    .info-section {
        padding: 1rem;
    }
    
    .info-section h3 {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
    }
    
    .info-section p {
        font-size: 0.9rem;
        line-height: 1.5;
    }
    
    .info-modal-body {
        gap: 1.25rem;
    }
    
    /* Números extra grandes en pantallas muy pequeñas */
    .activation-number {
        font-size: 13px;
        stroke-width: 3.5px;
    }
    
    .neural-activation.pending .activation-number {
        font-size: 11px;
        stroke-width: 3px;
    }
    
    .neural-activation.visited .activation-number {
        font-size: 12px;
        stroke-width: 3.2px;
    }
    
    .neural-activation.active .activation-number {
        font-size: 15px;
        stroke-width: 4px;
    }
    
    /* Nodos aún más grandes para pantallas pequeñas */
    .neural-activation.pending .activation-core {
        r: 5;
    }
    
    .neural-activation.pending .activation-halo {
        r: 10;
    }
    
    .neural-activation.visited .activation-core {
        r: 6;
    }
    
    .neural-activation.visited .activation-halo {
        r: 12;
    }
    
    .neural-activation.active .activation-core {
        r: 8;
    }
    
    .neural-activation.active .activation-halo {
        r: 20;
    }
}

/* ===========================
   Pantallas muy pequeñas (320px)
   =========================== */
@media (max-width: 380px) {
    .header {
        padding: 0.85rem;
    }
    
    .header-content {
        align-items: flex-start;
        margin: 0;
    }
    
    .title {
        font-size: 0.95rem;
        text-align: left;
    }
    
    .progress-text {
        font-size: 0.8rem;
        text-align: left;
    }
    
    .nav-btn {
        padding: 0.5rem 0.8rem;
        font-size: 0.8rem;
    }
    
    .main-container {
        padding-top: 210px;
    }
    
    .mini-map {
        width: 80px;
        height: 60px;
        bottom: 0.75rem;
        right: 0.75rem;
    }
    
    .info-btn {
        width: 38px;
        height: 38px;
        bottom: 0.75rem;
        left: 0.75rem;
    }
    
    .info-btn svg {
        width: 16px;
        height: 16px;
    }
    
    .info-modal-content {
        padding: 1.25rem;
        width: 96%;
        max-height: 88vh;
        border-radius: 10px;
    }
    
    .info-modal-title {
        font-size: 1.25rem;
        margin-bottom: 1.25rem;
    }
    
    .info-modal-close {
        width: 30px;
        height: 30px;
        top: 0.5rem;
        right: 0.5rem;
    }
    
    .info-modal-close svg {
        width: 16px;
        height: 16px;
    }
    
    .info-section {
        padding: 0.85rem;
    }
    
    .info-section h3 {
        font-size: 1rem;
        margin-bottom: 0.65rem;
    }
    
    .info-section p {
        font-size: 0.85rem;
        line-height: 1.5;
        margin-bottom: 0.4rem;
    }
    
    .info-modal-body {
        gap: 1rem;
    }
    
    .reference {
        font-size: 0.85rem;
        padding-left: 0.75rem;
    }
    
    .info-note p {
        font-size: 0.85rem;
    }
    
    .event-title {
        font-size: 1rem;
    }
    
    .event-description {
        font-size: 0.85rem;
    }
}

/* ===========================
   Scrollbar Custom
   =========================== */
.info-panel::-webkit-scrollbar {
    width: 8px;
}

.info-panel::-webkit-scrollbar-track {
    background: rgba(10, 14, 39, 0.5);
}

.info-panel::-webkit-scrollbar-thumb {
    background: rgba(212, 175, 119, 0.5);
    border-radius: 4px;
}

.info-panel::-webkit-scrollbar-thumb:hover {
    background: var(--color-brain);
}

.info-modal-content::-webkit-scrollbar {
    width: 6px;
}

.info-modal-content::-webkit-scrollbar-track {
    background: rgba(10, 14, 39, 0.3);
}

.info-modal-content::-webkit-scrollbar-thumb {
    background: rgba(212, 175, 119, 0.5);
    border-radius: 3px;
}

.info-modal-content::-webkit-scrollbar-thumb:hover {
    background: var(--color-brain);
}