/* ==========================================================================
   SICAS Lite - Componentes de Inicio (Index)
   Aquí residirán las secciones exclusivas de la página principal.
   ========================================================================== */

.btn-modal {
    width: 100%;
    padding: 1rem;
    border-radius: 14px;
    font-family: 'Outfit';
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.btn-modal-primary {
    background: var(--navy);
    color: white;
}

.btn-modal-primary:hover {
    background: var(--navy-dark);
    transform: translateY(-1px);
}

.color-success { color: #10B981; border: 4px solid rgba(16, 185, 129, 0.1); background: rgba(16, 185, 129, 0.05); }
.color-error { color: #EF4444; border: 4px solid rgba(239, 68, 68, 0.1); background: rgba(239, 68, 68, 0.05); }
.color-info { color: var(--cyan); border: 4px solid rgba(56, 189, 248, 0.1); background: rgba(56, 189, 248, 0.05); }

@keyframes fadeInModal {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ==========================================================================
   INTELIGENCIA COMERCIAL INTERACTIVA
   ========================================================================== */

.intel-section {
    background: radial-gradient(circle at 50% 100%, #334F90 0%, #1C2B50 18%, #111A2E 35%, #0F172A 50%);
    padding: 6rem 0 0 0;
    color: var(--white);
    overflow: hidden;
    position: relative;
    font-family: 'Outfit', sans-serif;
}

.intel-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 5%;
}

.intel-header {
    text-align: center;
    margin-bottom: 4rem;
}

.intel-eyebrow {
    color: #38BDF8; /* Cyan */
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.intel-title {
    font-size: 2.2rem;
    font-weight: 900; /* Font weight Black for a "fuller" look */
    line-height: 1.3;
    color: var(--white);
}

.intel-title-highlight {
    color: #38BDF8; /* Cyan */
    font-size: 2rem;
    font-weight: 900; /* Font weight Black */
}

/* Interactive Area Layout */
.intel-interactive-area {
    position: relative;
    width: 100%;
    min-height: 550px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.intel-center-img-wrapper {
    position: absolute;
    bottom: -1px; /* Pin strictly to the base of the container */
    left: 50%;
    transform: translateX(-50%);
    z-index: 5; /* Above background, but cards might overlap */
    height: 100%; /* Spacing fixed to full container height */
    width: auto;
}

.intel-center-img {
    height: 100%;
    width: auto;
    display: block;
}

/* Floating Cards Base */
.intel-card {
    position: absolute;
    background: rgba(15, 23, 42, 0.7); /* Deep dark with transparency */
    border: 1px solid transparent; 
    background-clip: padding-box;
    border-radius: 12px;
    padding: 1rem 1.25rem;
    backdrop-filter: blur(8px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
    cursor: default;
    
    /* Collapsed state constraints */
    max-width: 320px;
    width: auto;
    display: flex;
    flex-direction: column;
}

/* Animated Border Glow (Propuesta 2) */
.intel-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 12px;
    padding: 1px; /* border thickness */
    background: linear-gradient(90deg, rgba(56,189,248,0.2) 0%, rgba(56,189,248,0.9) 50%, rgba(56,189,248,0.2) 100%);
    background-size: 200% auto;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: borderGlowSweep 3s linear infinite;
    pointer-events: none;
    z-index: -1;
}

@keyframes borderGlowSweep {
    to { background-position: 200% center; }
}

.intel-card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0px; /* Initially no bottom margin as body is hidden */
    transition: margin-bottom 0.4s ease;
}

.intel-card-icon {
    width: 40px;
    height: 40px;
    background: rgba(56, 189, 248, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.intel-card-title {
    font-size: 1.15rem; /* Aumentado de 0.95rem */
    font-weight: 800;
    color: var(--white);
    margin: 0;
    letter-spacing: 0.5px;
    white-space: normal; 
    line-height: 1.2;
}

.intel-card-body {
    max-height: 0;
    opacity: 0;
    transition: max-height 0.4s ease, opacity 0.4s ease, margin-top 0.4s ease;
    overflow: hidden;
}

.intel-card-body p {
    font-size: 1rem; /* Aumentado de 0.85rem para mejor lectura */
    color: #E2E8F0; /* Un tono más claro (Slate 200) para mayor contraste */
    line-height: 1.6;
    margin: 0;
}

/* Hover State - Expansion */
.intel-card:hover {
    border-color: #38BDF8;
    background: rgba(15, 23, 42, 0.9);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 15px rgba(56, 189, 248, 0.3);
    z-index: 20; /* Bring to very front on hover */
    /* On hover, let it expand as needed, width fixed for reading */
    width: 360px;
    white-space: normal;
}

/* Hide animated border on hover */
.intel-card:hover::before {
    opacity: 0;
    animation: none;
}

.intel-card:hover .intel-card-header {
    margin-bottom: 1rem;
}

.intel-card:hover .intel-card-title {
    white-space: normal; /* Let title wrap if needed on expansion */
}

.intel-card:hover .intel-card-body {
    max-height: 500px; /* Incrementado para evitar que el texto se corte */
    opacity: 1;
}

/* Positioning */
.intel-card-tl {
    top: 10%;
    left: 10%;
}

.intel-card-tr {
    top: 15%;
    right: 5%;
}

.intel-card-bl {
    bottom: 25%;
    left: 5%;
}

.intel-card-br {
    bottom: 20%;
    right: 10%;
}

/* Responsive Overrides */
@media (max-width: 1024px) {
    .intel-section {
        padding-bottom: 2.625rem; /* Exactly 42px as requested */
    }

    .intel-interactive-area {
        min-height: auto;
        flex-direction: column;
        display: block;
    }
    
    .intel-center-img-wrapper {
        display: none; /* Hide woman image on mobile as requested */
    }

    .intel-card {
        position: relative;
        top: auto !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
        width: 100% !important;
        max-width: 100%;
        margin-bottom: 1rem;
        
        /* Always expanded on mobile for readability, or keep hover but it's hard on touch */
        border-color: rgba(56, 189, 248, 0.3);
    }
    
    .intel-card-title {
        white-space: normal;
    }
    
    .intel-card-header {
        margin-bottom: 1rem;
    }
    
    .intel-card-body {
        max-height: 600px;
        opacity: 1;
    }
}
