/* ============================================
   GRID CAPACITY MAP - ALVRISOLUTIONS
   Versión corregida: Febrero 2026
   - Imágenes centradas sin recorte
   - Sin fondo blanco en PNGs
   - Popups más cerca de imagen principal
   - Menos espacio encima del texto
   Colores de marca: #227c7c #d9f2e6 #2b3c56 #469595
   ============================================ */

:root {
    --gc-primary: #2b3c56;
    --gc-primary-light: #3d5270;
    --gc-accent: #227c7c;
    --gc-accent-light: #469595;
    --gc-accent-soft: #d9f2e6;
    --gc-blue: #3b82f6;
    --gc-text: #1f2937;
    --gc-text-secondary: #6b7280;
    --gc-text-light: #9ca3af;
    --gc-bg: #ffffff;
    --gc-bg-alt: #f9fafb;
    --gc-border: #e5e7eb;
    --gc-radius: 12px;
    --gc-radius-lg: 20px;
    --gc-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
    --gc-shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1);
    --gc-shadow-xl: 0 25px 50px -12px rgba(0,0,0,0.15);
    --gc-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ========================================
   HERO SECTION - TEXTO IZQUIERDA, IMAGEN DERECHA (ESTÁTICA)
   ======================================== */
.gc-hero {
    min-height: 80vh;
    display: flex;
    align-items: center;
    padding: 120px 5% 80px;
    background: linear-gradient(135deg, var(--gc-accent-soft) 0%, #f8fafc 50%, #ffffff 100%);
    overflow: hidden;
}

.gc-hero-container {
    max-width: 1300px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 50px;
    align-items: center;
}

/* Contenido a la izquierda */
.gc-hero-content {
    max-width: 620px;
}

.gc-hero-title {
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-weight: 800;
    line-height: 1.15;
    color: var(--gc-text);
    margin: 0 0 24px 0;
}

.gc-gradient-text {
    background: linear-gradient(135deg, var(--gc-accent) 0%, var(--gc-accent-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.gc-hero-description {
    font-size: 1.05rem;
    line-height: 1.75;
    color: var(--gc-text-secondary);
    margin: 0 0 16px 0;
}

.gc-hero-description strong {
    color: var(--gc-text);
}

.gc-hero-cta {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    margin-top: 28px;
}

/* Imagen a la derecha - ESTÁTICA (sin animación) */
.gc-hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.gc-hero-visual img {
    width: 100%;
    max-width: 380px;
    height: auto;
}

/* Botones */
.gc-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 26px;
    background: var(--gc-primary);
    color: white;
    border-radius: var(--gc-radius);
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: var(--gc-transition);
    box-shadow: var(--gc-shadow);
}

.gc-btn-primary:hover {
    background: var(--gc-primary-light);
    transform: translateY(-2px);
    box-shadow: var(--gc-shadow-lg);
}

.gc-btn-secondary {
    display: inline-flex;
    align-items: center;
    padding: 14px 26px;
    background: transparent;
    color: var(--gc-primary);
    border: 2px solid var(--gc-border);
    border-radius: var(--gc-radius);
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: var(--gc-transition);
}

.gc-btn-secondary:hover {
    border-color: var(--gc-accent);
    color: var(--gc-accent);
    background: rgba(34, 124, 124, 0.05);
}

/* ========================================
   FEATURES SECTION
   ======================================== */
.gc-features {
    padding: 60px 5%;
    background: var(--gc-bg);
}

.gc-features-container {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.gc-feature-card {
    display: flex;
    gap: 16px;
    padding: 24px;
    background: var(--gc-bg-alt);
    border-radius: var(--gc-radius);
    border: 1px solid var(--gc-border);
}

.gc-feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.gc-feature-icon.green {
    background: rgba(34, 124, 124, 0.1);
    color: var(--gc-accent);
}

.gc-feature-icon.blue {
    background: rgba(59, 130, 246, 0.1);
    color: var(--gc-blue);
}

.gc-feature-card p {
    font-size: 0.95rem;
    line-height: 1.65;
    color: var(--gc-text-secondary);
    margin: 0;
}

/* ========================================
   FRAMEWORK SECTION
   ======================================== */
.gc-framework {
    padding: 80px 5%;
    background: linear-gradient(180deg, var(--gc-bg-alt) 0%, white 100%);
}

.gc-framework-container {
    max-width: 1000px;
    margin: 0 auto;
}

.gc-section-title {
    font-size: clamp(1.5rem, 3vw, 2.25rem);
    font-weight: 700;
    color: var(--gc-text);
    text-align: center;
    margin: 0 0 40px 0;
}

/* ========================================
   LOGOS COLLAGE - ALTURAS ESCALONADAS, MÁS GRANDES
   ======================================== */
.gc-logos-collage {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 50px;
    padding: 30px 0;
    position: relative;
    min-height: 160px;
}

.gc-logo-bubble {
    width: 95px;
    height: 95px;
    border-radius: 50%;
    background: white;
    border: 3px solid #f0f0f0;
    overflow: hidden;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
    margin-left: -20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.gc-logo-bubble:first-child {
    margin-left: 0;
}

/* Alturas escalonadas para cada burbuja */
.gc-logo-bubble:nth-child(1) { transform: translateY(18px); }
.gc-logo-bubble:nth-child(2) { transform: translateY(-12px); }
.gc-logo-bubble:nth-child(3) { transform: translateY(8px); }
.gc-logo-bubble:nth-child(4) { transform: translateY(-18px); }
.gc-logo-bubble:nth-child(5) { transform: translateY(14px); }
.gc-logo-bubble:nth-child(6) { transform: translateY(-8px); }
.gc-logo-bubble:nth-child(7) { transform: translateY(16px); }

.gc-logo-bubble.large {
    width: 115px;
    height: 115px;
    z-index: 2;
}

.gc-logo-bubble img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gc-logo-bubble:hover {
    transform: scale(1.18) translateY(0) !important;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
    z-index: 10;
}

/* ========================================
   CAROUSEL - AUTO TEMPORIZADO (CORREGIDO)
   ======================================== */
.gc-carousel {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.gc-carousel-item {
    background: white;
    border-radius: var(--gc-radius-lg);
    border: 1px solid var(--gc-border);
    overflow: hidden;
    transition: var(--gc-transition);
}

.gc-carousel-item:hover {
    box-shadow: var(--gc-shadow);
}

.gc-carousel-item.active {
    border-color: var(--gc-accent);
    box-shadow: 0 6px 25px rgba(34, 124, 124, 0.12);
}

.gc-carousel-header {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 18px 22px;
    background: transparent;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: var(--gc-transition);
    position: relative;
}

.gc-carousel-item.active .gc-carousel-header {
    background: linear-gradient(135deg, var(--gc-primary) 0%, var(--gc-primary-light) 100%);
}

.gc-carousel-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: rgba(34, 124, 124, 0.1);
    color: var(--gc-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: var(--gc-transition);
}

.gc-carousel-item.active .gc-carousel-icon {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.gc-carousel-title {
    flex: 1;
}

.gc-carousel-title h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--gc-text);
    margin: 0;
    transition: color 0.3s ease;
}

.gc-carousel-item.active .gc-carousel-title h3 {
    color: white;
}

/* Progress bar */
.gc-carousel-progress {
    width: 60px;
    height: 4px;
    background: rgba(0,0,0,0.1);
    border-radius: 2px;
    overflow: hidden;
    flex-shrink: 0;
}

.gc-carousel-item.active .gc-carousel-progress {
    background: rgba(255,255,255,0.3);
}

.gc-progress-bar {
    height: 100%;
    width: 0;
    background: var(--gc-accent);
    border-radius: 2px;
}

.gc-carousel-item.active .gc-progress-bar {
    background: white;
}

@keyframes progressFill {
    from { width: 0; }
    to { width: 100%; }
}

/* Carousel Content - MENOS ESPACIO ARRIBA */
.gc-carousel-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.gc-carousel-item.active .gc-carousel-content {
    max-height: 550px;
}

/* Body del carrusel - CENTRADO VERTICAL */
.gc-carousel-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 20px 28px 28px; /* Reducido el padding superior de 24px a 20px */
    background: linear-gradient(180deg, #f8fafc 0%, white 100%);
    align-items: center; /* Centrado vertical */
}

.gc-carousel-text {
    display: flex;
    flex-direction: column;
    justify-content: center; /* Centrar verticalmente el texto */
}

.gc-carousel-text p {
    font-size: 0.92rem;
    line-height: 1.7;
    color: var(--gc-text-secondary);
    margin: 0 0 12px 0;
}

.gc-carousel-text p:last-of-type {
    margin-bottom: 0;
}

.gc-carousel-text strong {
    color: var(--gc-accent);
}

/* Tags */
.gc-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 16px;
}

.gc-tags span {
    padding: 5px 12px;
    background: rgba(34, 124, 124, 0.1);
    color: var(--gc-accent);
    font-size: 0.8rem;
    font-weight: 600;
    border-radius: 16px;
}

/* ========================================
   CAROUSEL VISUALS - CORREGIDOS SIN FONDO
   ======================================== */
.gc-carousel-visual {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 280px; /* Altura mínima para evitar saltos */
}

/* Slide 1: Imagen sola, más grande, SIN FONDO */
.gc-carousel-visual > img {
    max-width: 100%;
    max-height: 280px;
    width: auto;
    height: auto;
    object-fit: contain;
    /* SIN border-radius ni fondo para mostrar transparencia */
}

/* Slides 2 y 3: Wrapper con imagen base + popup */
.gc-visual-wrapper {
    position: relative;
    width: 100%;
    max-width: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Imagen base - SIN FONDO BLANCO */
.gc-main-img {
    width: 100%;
    height: auto;
    max-height: 260px;
    object-fit: contain;
    /* Sin box-shadow ni background para preservar transparencia PNG */
}

/* Popup pequeño - MÁS CERCA de la imagen principal */
.gc-popup-img {
    position: absolute;
    width: 110px;
    bottom: -15px; /* Más cerca (era -30px) */
    left: -20px;   /* Más cerca (era -35px) */
    border-radius: 10px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    /* SIN background para preservar transparencia */
    opacity: 0;
    transform: scale(0.3) translateY(20px);
}

/* Animación de aparición del popup */
@keyframes popupAppear {
    0% {
        opacity: 0;
        transform: scale(0.3) translateY(20px);
    }
    60% {
        opacity: 1;
        transform: scale(1.06) translateY(-5px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Reiniciar animación cuando el item NO está activo */
.gc-carousel-item:not(.active) .gc-popup-img {
    opacity: 0;
    transform: scale(0.3) translateY(20px);
    animation: none;
}

/* Activar animación cuando el item está activo */
.gc-carousel-item.active .gc-popup-img {
    animation: popupAppear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    animation-delay: 0.4s;
}

/* Framework CTA */
.gc-framework-cta {
    text-align: center;
    margin-top: 40px;
}

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 1024px) {
    .gc-hero-container {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }
    
    .gc-hero-visual {
        order: -1;
    }
    
    .gc-hero-visual img {
        max-width: 300px;
    }
    
    .gc-hero-content {
        max-width: 100%;
    }
    
    .gc-hero-cta {
        justify-content: center;
    }
    
    .gc-carousel-body {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .gc-carousel-text {
        order: 2;
    }
    
    .gc-carousel-visual {
        order: 1;
        min-height: 220px;
    }
    
    .gc-visual-wrapper {
        max-width: 280px;
        margin: 0 auto;
    }
    
    .gc-popup-img {
        width: 95px;
        bottom: -12px;
        left: -15px;
    }
    
    .gc-carousel-item.active .gc-carousel-content {
        max-height: 650px;
    }
}

@media (max-width: 768px) {
    .gc-hero {
        min-height: auto;
        padding: 100px 5% 60px;
    }
    
    .gc-hero-visual img {
        max-width: 250px;
    }
    
    .gc-features-container {
        grid-template-columns: 1fr;
    }
    
    .gc-framework {
        padding: 60px 5%;
    }
    
    .gc-logos-collage {
        flex-wrap: wrap;
        gap: 10px;
        min-height: auto;
        padding: 20px 0;
    }
    
    .gc-logo-bubble {
        width: 70px;
        height: 70px;
        margin-left: -15px;
    }
    
    .gc-logo-bubble.large {
        width: 85px;
        height: 85px;
    }
    
    /* En móvil, alturas menos pronunciadas */
    .gc-logo-bubble:nth-child(1) { transform: translateY(10px); }
    .gc-logo-bubble:nth-child(2) { transform: translateY(-6px); }
    .gc-logo-bubble:nth-child(3) { transform: translateY(4px); }
    .gc-logo-bubble:nth-child(4) { transform: translateY(-10px); }
    .gc-logo-bubble:nth-child(5) { transform: translateY(7px); }
    .gc-logo-bubble:nth-child(6) { transform: translateY(-4px); }
    .gc-logo-bubble:nth-child(7) { transform: translateY(8px); }
    
    .gc-carousel-header {
        padding: 14px 16px;
    }
    
    .gc-carousel-icon {
        width: 38px;
        height: 38px;
    }
    
    .gc-carousel-title h3 {
        font-size: 0.9rem;
    }
    
    .gc-carousel-progress {
        width: 40px;
    }
    
    .gc-carousel-body {
        padding: 16px;
    }
    
    .gc-carousel-text p {
        font-size: 0.88rem;
    }
    
    .gc-carousel-visual {
        min-height: 180px;
    }
    
    .gc-carousel-visual > img {
        max-height: 180px;
    }
    
    .gc-visual-wrapper {
        max-width: 240px;
    }
    
    .gc-main-img {
        max-height: 200px;
    }
    
    .gc-popup-img {
        width: 80px;
        bottom: -10px;
        left: -12px;
    }
    
    .gc-carousel-item.active .gc-carousel-content {
        max-height: 700px;
    }
}

@media (max-width: 480px) {
    .gc-hero-title {
        font-size: 1.75rem;
    }
    
    .gc-hero-description {
        font-size: 0.95rem;
    }
    
    .gc-btn-primary,
    .gc-btn-secondary {
        width: 100%;
        justify-content: center;
    }
    
    .gc-logo-bubble {
        width: 58px;
        height: 58px;
        margin-left: -12px;
    }
    
    .gc-logo-bubble.large {
        width: 70px;
        height: 70px;
    }
    
    .gc-carousel-title h3 {
        font-size: 0.85rem;
    }
    
    .gc-carousel-visual {
        min-height: 150px;
    }
    
    .gc-carousel-visual > img {
        max-height: 150px;
    }
    
    .gc-visual-wrapper {
        max-width: 200px;
    }
    
    .gc-main-img {
        max-height: 170px;
    }
    
    .gc-popup-img {
        width: 65px;
        bottom: -8px;
        left: -10px;
    }
}
