/* ==========================================================================
   CSS PRINCIPAL - NEURAL DEGEN ($NDGN) - ESTILO CIBERPUNK DE ULTRA LUJO
   ========================================================================== */

/* Variables del Sistema de Diseño (HSL tailoreado) */
:root {
    --bg-main: hsl(260, 20%, 4%);
    --bg-card: hsla(260, 25%, 8%, 0.7);
    --bg-terminal: hsla(260, 30%, 5%, 0.95);
    
    --primary: hsl(175, 90%, 50%); /* Cian neón */
    --primary-glow: hsla(175, 90%, 50%, 0.35);
    --secondary: hsl(280, 85%, 60%); /* Violeta neón */
    --secondary-glow: hsla(280, 85%, 60%, 0.35);
    
    --text-main: hsl(0, 0%, 95%);
    --text-muted: hsl(260, 10%, 70%);
    --text-dark: hsl(260, 20%, 15%);
    
    --success: hsl(140, 80%, 50%);
    --warning: hsl(40, 90%, 55%);
    --error: hsl(0, 85%, 55%);
    
    --border-glass: hsla(260, 30%, 25%, 0.4);
    --border-active: hsla(175, 90%, 50%, 0.6);
    
    --font-orbitron: 'Orbitron', monospace;
    --font-outfit: 'Outfit', sans-serif;
    
    --glow-shadow: 0 0 20px var(--primary-glow);
    --glow-shadow-secondary: 0 0 20px var(--secondary-glow);
}

/* Reset y Estilos Globales */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

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

/* Red de Fondo y Canvas Holográfico */
.hologram-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle at 50% 50%, hsla(280, 50%, 8%, 0.5) 0%, var(--bg-main) 80%);
    z-index: -2;
    pointer-events: none;
}

#particles-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    opacity: 0.4;
}

/* Tipografías Especiales */
.font-orbitron {
    font-family: var(--font-orbitron);
    letter-spacing: 0.05em;
}

.font-outfit {
    font-family: var(--font-outfit);
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Header Principal */
.main-header {
    width: 100%;
    position: sticky;
    top: 0;
    z-index: 100;
    background: hsla(260, 20%, 4%, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-glass);
}

.header-container {
    max-width: 1280px;
    margin: 0 auto;
    height: 80px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 24px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-logo {
    height: 48px;
    width: 48px;
    border-radius: 50%;
    border: 2px solid var(--primary);
    box-shadow: var(--glow-shadow);
    transition: transform 0.3s ease;
}

.brand-logo:hover {
    transform: rotate(360deg);
}

.brand-name {
    font-size: 1.25rem;
    font-weight: 800;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.ticker {
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--secondary);
    -webkit-text-fill-color: initial;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.nav-link:hover {
    color: var(--primary);
    text-shadow: 0 0 10px var(--primary-glow);
}

/* Botón Conectar Wallet Premium */
.wallet-btn {
    position: relative;
    padding: 12px 24px;
    background: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
    font-weight: 700;
    font-size: 0.85rem;
    border-radius: 4px;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 0 10px hsla(175, 90%, 50%, 0.1);
}

.wallet-btn:hover {
    background: var(--primary);
    color: var(--bg-main);
    box-shadow: var(--glow-shadow);
}

/* Grid del Dashboard */
.hero-dashboard {
    padding: 40px 0;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 24px;
    align-items: start;
}

/* Estilo Base de los Paneles */
.dashboard-panel {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    overflow: hidden;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    height: 600px;
    transition: border-color 0.3s ease;
}

.dashboard-panel:hover {
    border-color: var(--border-active);
}

.panel-header {
    height: 50px;
    background: hsla(260, 20%, 5%, 0.8);
    border-bottom: 1px solid var(--border-glass);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 16px;
}

.panel-title {
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-indicator.online {
    background-color: var(--success);
    box-shadow: 0 0 8px var(--success);
    animation: pulse 2s infinite;
}

.status-indicator.live {
    background-color: var(--primary);
    box-shadow: 0 0 8px var(--primary);
    animation: pulse 1.5s infinite;
}

.panel-controls {
    display: flex;
    gap: 6px;
}

.control-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.control-dot.red { background-color: var(--error); }
.control-dot.yellow { background-color: var(--warning); }
.control-dot.green { background-color: var(--success); }

/* Panel: Consola de la IA */
.panel-terminal .panel-body {
    flex: 1;
    background-color: var(--bg-terminal);
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
    font-size: 0.85rem;
    line-height: 1.5;
}

.log-line {
    word-break: break-all;
}

.text-system { color: var(--text-muted); }
.text-success { color: var(--success); }
.text-warning { color: var(--warning); }
.text-error { color: var(--error); }
.text-primary { color: var(--primary); }
.text-secondary { color: var(--secondary); }

.panel-terminal .panel-footer {
    height: 50px;
    background: hsla(260, 20%, 3%, 0.9);
    border-top: 1px solid var(--border-glass);
    display: flex;
    align-items: center;
    padding: 0 16px;
    gap: 12px;
}

.terminal-prompt {
    color: var(--primary);
    font-weight: 800;
    font-size: 1.1rem;
}

#terminal-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-main);
    font-family: var(--font-orbitron);
    font-size: 0.85rem;
}

/* Panel: Terminal de Trading */
.market-badge {
    padding: 6px 12px;
    background: hsla(175, 90%, 50%, 0.1);
    border: 1px solid var(--primary);
    color: var(--primary);
    font-size: 0.8rem;
    font-weight: 800;
    border-radius: 4px;
    box-shadow: 0 0 10px hsla(175, 90%, 50%, 0.15);
}

.trading-layout {
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    flex: 1;
    min-height: 0; /* Permite scroll adecuado */
    border-bottom: 1px solid var(--border-glass);
}

.chart-container {
    border-right: 1px solid var(--border-glass);
    position: relative;
    background: hsla(260, 20%, 4%, 0.4);
    display: flex;
    flex-direction: column;
    padding: 10px;
}

#trading-chart {
    flex: 1;
    width: 100%;
    height: 100%;
}

.chart-overlay-info {
    position: absolute;
    top: 15px;
    left: 15px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    pointer-events: none;
}

.chart-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 600;
}

.chart-change {
    font-size: 0.9rem;
    font-weight: 800;
}

/* Controles de Swap */
.trading-panel-controls {
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: hsla(260, 25%, 6%, 0.5);
}

.swap-card {
    background: hsla(260, 25%, 3%, 0.6);
    border: 1px solid var(--border-glass);
    border-radius: 6px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.swap-header {
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--text-main);
    border-bottom: 1px solid var(--border-glass);
    padding-bottom: 8px;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.input-group label {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: 600;
}

.input-wrapper {
    display: flex;
    background: hsla(260, 25%, 8%, 0.8);
    border: 1px solid var(--border-glass);
    border-radius: 4px;
    padding: 8px 12px;
    align-items: center;
}

.input-wrapper input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-main);
    font-family: var(--font-orbitron);
    font-size: 0.9rem;
}

.currency-tag {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--primary);
}

.swap-arrow {
    text-align: center;
    color: var(--text-muted);
    font-weight: 800;
    font-size: 1.1rem;
    margin: -4px 0;
}

.action-btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border: none;
    outline: none;
    color: var(--bg-main);
    font-weight: 800;
    font-size: 0.85rem;
    border-radius: 4px;
    cursor: pointer;
    box-shadow: var(--glow-shadow);
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.action-btn:hover {
    transform: translateY(-1px);
    opacity: 0.95;
}

.action-btn:active {
    transform: translateY(1px);
}

/* Enlaces Rápidos de Trading */
.quick-trading-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
}

.trading-link {
    text-align: center;
    padding: 10px;
    font-size: 0.75rem;
    font-weight: 800;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.photon-btn {
    border: 1px solid var(--primary);
    color: var(--primary);
}

.photon-btn:hover {
    background: var(--primary-glow);
    box-shadow: var(--glow-shadow);
}

.pump-btn {
    border: 1px solid var(--secondary);
    color: var(--secondary);
}

.pump-btn:hover {
    background: var(--secondary-glow);
    box-shadow: var(--glow-shadow-secondary);
}

/* Feed de Transacciones Recientes */
.live-transactions {
    height: 160px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: hsla(260, 20%, 3%, 0.8);
    font-size: 0.75rem;
}

.tx-header {
    display: grid;
    grid-template-columns: 1fr 1fr 1.2fr 1.5fr;
    color: var(--text-muted);
    font-weight: 800;
    border-bottom: 1px solid var(--border-glass);
    padding-bottom: 4px;
}

.tx-rows {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.tx-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1.2fr 1.5fr;
    align-items: center;
    border-bottom: 1px solid hsla(260, 20%, 20%, 0.15);
    padding-bottom: 4px;
}

.tx-row .buy { color: var(--success); font-weight: 600; }
.tx-row .sell { color: var(--error); font-weight: 600; }

/* Sección Tokenomics */
.tokenomics-section {
    padding: 80px 24px;
}

.section-title {
    font-size: 2rem;
    font-weight: 900;
    text-align: center;
    margin-bottom: 48px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.grid-tokenomics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 48px;
}

.token-card {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    padding: 32px 24px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.token-card:hover {
    border-color: var(--border-active);
    transform: translateY(-4px);
}

.card-icon {
    font-size: 2rem;
    margin-bottom: 16px;
}

.token-card h3 {
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: 12px;
}

.token-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* Caja de Distribución en Barra */
.solana-distribution-box {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    padding: 24px;
}

.dist-title {
    font-size: 0.9rem;
    font-weight: 800;
    margin-bottom: 16px;
    text-align: center;
}

.dist-bar {
    height: 36px;
    border-radius: 18px;
    overflow: hidden;
    display: flex;
    border: 1px solid var(--border-glass);
}

.dist-segment {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.75rem;
    font-weight: 900;
    color: var(--bg-main);
}

.dist-segment.lp { background: var(--primary); }
.dist-segment.creator { background: var(--secondary); }
.dist-segment.marketing { background: hsl(0, 0%, 90%); }

.dist-legend {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-top: 16px;
    flex-wrap: wrap;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.legend-color {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 2px;
    margin-right: 4px;
    vertical-align: middle;
}

.lp-color { background: var(--primary); }
.creator-color { background: var(--secondary); }
.marketing-color { background: hsl(0, 0%, 90%); }

/* Sección Misiones / Raids */
.raids-section {
    padding: 40px 24px 80px 24px;
}

.section-subtitle {
    text-align: center;
    color: var(--text-muted);
    margin-top: -36px;
    margin-bottom: 40px;
    font-size: 1rem;
}

.raids-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 800px;
    margin: 0 auto;
}

.raid-item {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    transition: all 0.3s ease;
}

.raid-item:hover {
    border-color: var(--border-active);
}

.raid-details {
    flex: 1;
}

.raid-title {
    font-size: 0.95rem;
    font-weight: 800;
    margin-bottom: 6px;
    color: var(--primary);
}

.raid-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.raid-action-btn {
    padding: 10px 20px;
    background: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
    font-weight: 800;
    font-size: 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.raid-action-btn:hover {
    background: var(--primary);
    color: var(--bg-main);
    box-shadow: var(--glow-shadow);
}

/* Footer */
.main-footer {
    border-top: 1px solid var(--border-glass);
    padding: 40px 24px;
    background: hsl(260, 20%, 2%);
}

.footer-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    text-align: center;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--primary);
}

.footer-logo {
    height: 32px;
    width: 32px;
    border-radius: 50%;
}

.disclaimer {
    max-width: 800px;
    font-size: 0.75rem;
    color: hsl(260, 10%, 45%);
    line-height: 1.5;
}

.copyright {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Animaciones */
@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(175, 90, 50, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 6px rgba(175, 90, 50, 0);
    }
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(175, 90, 50, 0);
    }
}

/* Estilos del Visualizador de CA (Dirección del Contrato) */
.ca-container {
    display: flex;
    align-items: center;
    background: hsla(260, 25%, 3%, 0.7);
    border: 1px solid var(--border-glass);
    border-radius: 4px;
    padding: 6px 12px;
    gap: 8px;
    font-size: 0.75rem;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
}
.ca-label {
    color: var(--secondary);
    font-weight: 800;
}
.ca-value {
    color: var(--text-main);
    font-family: monospace;
}
.ca-copy-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--primary);
    transition: transform 0.15s ease;
    font-size: 0.8rem;
    outline: none;
}
.ca-copy-btn:hover {
    transform: scale(1.2);
}

/* Adaptabilidad Móvil */
@media (max-width: 992px) {
    .ca-container {
        display: none !important; /* Ocultar en móviles para evitar colisiones en el header */
    }
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    .grid-tokenomics {
        grid-template-columns: 1fr;
    }
    .main-header {
        position: relative;
    }
    .nav-links {
        display: none; /* Simplificado para móviles */
    }
    .dashboard-panel {
        height: auto;
        min-height: 500px;
    }
    .panel-terminal .panel-body {
        height: 350px;
    }
    .trading-layout {
        grid-template-columns: 1fr;
    }
    .chart-container {
        border-right: none;
        border-bottom: 1px solid var(--border-glass);
        height: 250px;
    }
    .raid-item {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    .raid-action-btn {
        width: 100%;
    }
}
