/* ==========================================
   CONFIGURACIÓN GENERAL
========================================== */

html{
    scroll-behavior:smooth;
}

body{
    margin:0;
    padding:0;
    overflow-x:hidden;
    background:#0b0f19;
    color:#e2e8f0;
    font-family:system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
}

/* ==========================================
   NAVBAR
========================================== */

.navbar-dark-custom{
    background:rgba(0,0,0,.45);
    backdrop-filter:blur(12px);
    border-bottom:1px solid rgba(255,255,255,.08);
}

.navbar-dark-custom .nav-link{
    color:#e2e8f0 !important;
    transition:.3s;
}

.navbar-dark-custom .nav-link:hover,
.navbar-dark-custom .nav-link.active{
    color:#38bdf8 !important;
}

.btn-tech-primary{
    background:#0080ff;
    border:none;
    color:#fff;
    box-shadow:0 0 20px rgba(0,128,255,.35);
    transition:.3s;
}

.btn-tech-primary:hover{
    background:#0066cc;
    color:#fff;
    box-shadow:0 0 30px rgba(0,128,255,.6);
}

/* ==========================================
   HERO SECTION
========================================== */

.hero-section{
    position:relative;
    min-height:100vh;
    display:flex;
    align-items:center;
    overflow:hidden;
    background:#0b0f19;
}

/* ==========================================
   FONDO PRINCIPAL
========================================== */

.hero-banner-container{
    position: absolute;
    inset: 0;
    z-index: 1;
}

.jarallax-img{
    position: absolute;
    inset: 0;
    /* Por defecto para escritorios y pantallas grandes */
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;

    filter:
    brightness(1.18)
    contrast(1.08)
    saturate(1.15);
}

/* Ajuste específico para celulares (pantallas verticales estrechas) */
@media (max-width: 991px) {
    .jarallax-img {
        /* Cambiamos a 'contain' o un tamaño porcentual alto para forzar que se vea completa la ilustración */
        background-size: 110% auto; 
        /* Centramos la imagen horizontalmente y la anclamos un poco más arriba para que la columna y la cumbre salgan en pantalla */
        background-position: center 30%; 
    }
}

/* En pantallas de escritorio grandes mantenemos el comportamiento normal */
@media (min-width: 992px) {
    .jarallax-img {
        background-size: cover;
        background-position: center center;
    }
}
/* ==========================================
   OVERLAY CASI INVISIBLE
========================================== */

.hero-overlay{
    position:absolute;
    inset:0;

    background:
    linear-gradient(
        to bottom,
        rgba(0,0,0,.01),
        rgba(0,0,0,.07)
    );

    z-index:3;
}

/* ==========================================
   ATMÓSFERA TECNOLÓGICA
========================================== */

.star-field{
    position:absolute;
    inset:0;
    z-index:2;
    pointer-events:none;
}

.star-field span{
    position:absolute;
    width: 2.5px;
    height: 2.5px;
    border-radius:50%;
    background: white;
    box-shadow: 0 0 8px rgba(255,255,255,.9);
    /* Mezclamos tiempos diferentes para que parpadeen y floten de forma totalmente independiente (random) */
    animation: floatStar 9s ease-in-out infinite alternate, twinkle 2.5s ease-in-out infinite alternate;
}

.star-field::before{
    content:"";

    position:absolute;
    inset:-10%;

    background:
        radial-gradient(circle at 15% 25%, rgba(0,180,255,.16), transparent 25%),
        radial-gradient(circle at 75% 15%, rgba(120,90,255,.12), transparent 20%),
        radial-gradient(circle at 65% 60%, rgba(56,189,248,.10), transparent 30%);

    filter:blur(40px);

    animation:fogMove 8s ease-in-out infinite alternate;
}

.star-field::after{
    content:"";

    position:absolute;
    inset:0;

    background-image:

    radial-gradient(circle, rgba(255,255,255,.9) 1px, transparent 1.5px),

    radial-gradient(circle, rgba(255,255,255,.7) 1px, transparent 1.5px),

    radial-gradient(circle, rgba(56,189,248,.8) 1px, transparent 2px);

    background-size:
        280px 280px,
        430px 430px,
        610px 610px;

    background-position:
        40px 120px,
        190px 330px,
        110px 280px;

    animation:starDrift 60s linear infinite;

    opacity:.8;
}

/* Distribución variada en todo el espacio con duraciones y retardos aleatorios */
.star-field span:nth-child(1)  { left: 8%;  top: 15%; animation-duration: 7s;  animation-delay: 0.2s; }
.star-field span:nth-child(2)  { left: 18%; top: 75%; animation-duration: 11s; animation-delay: 1.5s; }
.star-field span:nth-child(3)  { left: 28%; top: 35%; animation-duration: 8s;  animation-delay: 3.1s; }
.star-field span:nth-child(4)  { left: 42%; top: 12%; animation-duration: 13s; animation-delay: 0.8s; }
.star-field span:nth-child(5)  { left: 53%; top: 65%; animation-duration: 9s;  animation-delay: 2.3s; }
.star-field span:nth-child(6)  { left: 68%; top: 25%; animation-duration: 10s; animation-delay: 4.0s; }
.star-field span:nth-child(7)  { left: 78%; top: 85%; animation-duration: 12s; animation-delay: 1.1s; }
.star-field span:nth-child(8)  { left: 88%; top: 45%; animation-duration: 7.5s; animation-delay: 2.9s; }
.star-field span:nth-child(9)  { left: 35%Y; top: 90%; animation-duration: 9.5s; animation-delay: 0.5s; }
.star-field span:nth-child(10) { left: 95%; top: 10%; animation-duration: 11.5s;animation-delay: 3.6s; }

/* Pequeño ajuste para la posición de la décima estrella por sintaxis limpia */
.star-field span:nth-child(9)  { left: 35%; top: 90%; }

@keyframes starDrift{

    from{
        transform:translateY(0);
    }

    to{
        transform:translateY(-60px);
    }

}
@keyframes fogMove{

    from{
        transform:translateX(-1%) translateY(-1%);
    }

    to{
        transform:translateX(1%) translateY(1%);
    }
}

@keyframes twinkle{
    0%, 100%{
        opacity: 0.2;
        transform: scale(0.8);
    }
    50%{
        opacity: 1;
        transform: scale(1.4);
    }
}

@keyframes floatStar{
    0%{
        transform: translateY(0px) translateX(0px);
    }
    50%{
        transform: translateY(-15px) translateX(5px);
    }
    100%{
        transform: translateY(0px) translateX(0px);
    }
}

/* ==========================================
   GLOW DE LA COLUMNA
========================================== */

.columna-glow{
    position:absolute;

    top:0;
    left:0;

    width:100%;
    height:100%;

    pointer-events:none;

    z-index:2;
    background:none;
}

.columna-glow::before{

    content:"";

    position:absolute;

    /*
       AJUSTA ESTOS DOS VALORES
       HASTA COINCIDIR CON LA COLUMNA
    */

    left:63%;
    top:12%;

    width:120px;
    height:75%;

    background:
    radial-gradient(
        ellipse,
        rgba(56,189,248,.55) 0%,
        rgba(56,189,248,.20) 35%,
        transparent 15%
    );

    filter:blur(25px);

    animation:spineGlow 3s ease-in-out infinite;
}

@keyframes spineGlow{

    0%,100%{
        opacity:.55;
        transform:scale(1);
    }

    50%{
        opacity:1;
        transform:scale(1.08);
    }
}

/* ==========================================
   CONTENIDO HERO
========================================== */

.hero-content{
    position:relative;
    z-index:10;
}

.hero-content h1{
    text-shadow:
        0 4px 25px rgba(0,0,0,.55);
}

.hero-content p{
    text-shadow:
        0 2px 12px rgba(0,0,0,.45);
}

/* ==========================================
   SERVICIOS
========================================== */

#servicios{
    position:relative;

    background:#0b0f19;

    margin:0;
    padding-top:5rem;

    z-index:20;
}

/* ==========================================
   TARJETAS
========================================== */

.bg-dark-card{

    background:
    linear-gradient(
        145deg,
        #131a29,
        #0c1220
    );
}

.border-relieve{

    border:1px solid rgba(56,189,248,.10);

    box-shadow:
        0 12px 30px rgba(0,0,0,.55),
        inset 0 1px 0 rgba(255,255,255,.05);
}
`


/* ==========================================
   CARATERISTICAS
========================================== */

.feature-item{
    padding:1.5rem;
    border-radius:1rem;

    background:
    linear-gradient(
        145deg,
        rgba(19,26,41,.9),
        rgba(12,18,32,.9)
    );

    border:1px solid rgba(56,189,248,.12);

    transition:.3s;
}

.feature-item:hover{
    transform:translateY(-4px);

    box-shadow:
        0 10px 30px rgba(56,189,248,.15);
}

.feature-item h4{
    margin-bottom:.8rem;
}

.feature-item p{
    margin-bottom:0;
    color:#cbd5e1;
}

/* FAQ */

.accordion-item{
    background:transparent !important;
}

.accordion-button{

    background:
    linear-gradient(
        145deg,
        rgba(19,26,41,.90),
        rgba(12,18,32,.90)
    ) !important;

    color:#e2e8f0 !important;

    font-weight:600;

    box-shadow:none !important;

    transition:.3s;
}

.accordion-button:hover{
    color:#38bdf8 !important;
}

.accordion-button:not(.collapsed){

    color:#38bdf8 !important;

    background:
    linear-gradient(
        145deg,
        rgba(19,26,41,.95),
        rgba(12,18,32,.95)
    ) !important;
}

.accordion-button::after{
    filter:invert(1);
}

.accordion-body{

    background:transparent;

    color:#cbd5e1;

    line-height:1.8;
}

/* ==========================================================================
   5. BOTÓN FLOTANTE VOLVER AL INICIO (ARCOÍRIS SPECTRA CORREGIDO)
   ========================================================================== */

/* 1. Registrar la variable de ángulo para que la animación conic-gradient funcione */
@property --angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

@keyframes rotarBorde {
  to {
    --angle: 360deg;
  }
}

.btn-scroll-top {
    position: fixed; 
    bottom: 30px; 
    right: 30px; 
    width: 48px; 
    height: 48px; 
    color: #38bdf8; /* Color cian neón de ChiroFull por defecto */
    background: linear-gradient(#0b0f19, #0b0f19) padding-box,
                conic-gradient(from var(--angle), #00f2ff, #a600ff, #39ff14, #ff0055, #00f2ff) border-box;
    border: 2px solid transparent; 
    border-radius: 50%; 
    font-size: 1.1rem; 
    cursor: pointer;
    display: flex; 
    align-items: center; 
    justify-content: center; 
    z-index: 9999; /* Asegurar que quede por encima de todo */
    
    /* Estado oculto */
    opacity: 0; 
    visibility: hidden;
    transform: translateY(15px);
    
    /* Animación del borde continuo + transiciones */
    animation: rotarBorde 3s linear infinite;
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, color 0.2s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}

/* Estado visible al hacer scroll */
.btn-scroll-top.show { 
    opacity: 1; 
    visibility: visible; 
    transform: translateY(0); 
}

/* Efectos al pasar el mouse (Hover) */
.btn-scroll-top.show:hover { 
    color: #ffffff; 
    transform: translateY(-5px); 
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.5); 
}

.btn-scroll-top:active { 
    transform: translateY(-2px); 
}