/* --- Sinergia Estratégica en Diseño Bento Grid --- */
.sinergia-section {
    margin-top: 0px;
    padding: 40px 0;
    background-color: #f8f9fa;
    width: 100%;
    box-sizing: border-box;
}

.sinergia-header {
    text-align: center;
    margin-bottom: 30px !important;
    padding: 0 20px;
}

.sinergia-header h2 {
    font-size: clamp(1.8rem, 4vw, 2.3rem);
    color: #1a1a1a;
    margin: 0 0 10px 0 !important;
    font-weight: 800;
}

.sinergia-header p {
    font-size: 1rem;
    color: var(--text-secondary, #616161);
    max-width: 800px;
    margin: 0 auto;
}

.icon-geo { 
    width: 14px; 
    height: 14px; 
    fill: #0067b8; 
    margin-right: 5px; 
    flex-shrink: 0;
}

/* El truco definitivo: Margen interior lateral absoluto en el contenedor */
.bento-container {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 16px !important; /* Esto obliga a que la caja siempre deje 16px libres a cada lado */
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    box-sizing: border-box;
}

/* Estilo Base de las Tarjetas (Bento Box) */
.aliado-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 22px 20px;
    width: 100%;
    text-align: left;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 16px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-sizing: border-box;
}

.aliado-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.06);
}

/* Tarjeta Principal Destacada */
.principal-consultor {
    grid-column: 1 / -1;
    border: 2px solid #0067b8 !important;
    box-shadow: 0 6px 20px rgba(0, 103, 184, 0.1) !important;
    background: linear-gradient(135deg, #ffffff 0%, #f0f7ff 100%);
}

.bento-main-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
    width: 100%;
}

.bento-actions {
    width: 100%;
    display: flex;
    justify-content: center;
}

.aliado-foto-container {
    width: 75px;
    height: 75px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    border: 2px solid #0067b8;
    margin: 0 auto;
}

.aliado-img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
}

.aliado-info {
    width: 100%;
    text-align: center;
}

.aliado-info h4 {
    font-size: 1.15rem;
    color: #1a1a1a;
    margin-bottom: 4px;
    font-weight: 700;
}

.especialidad {
    font-weight: 600;
    color: #0067b8;
    margin-bottom: 0;
    font-size: 0.9rem;
}

.aliado-zona {
    font-size: 0.85rem;
    color: #666;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 6px;
}

.zona-linea { 
    display: flex; 
    align-items: center; 
    gap: 5px; 
}

/* Acciones múltiples */
.card-multi-actions {
    display: flex;
    gap: 10px;
    width: 100%;
}

.card-multi-actions .aliado-wa,
.card-multi-actions .aliado-web-btn {
    flex: 1;
}

.aliado-web-btn {
    background-color: #64748b !important;
}
.aliado-web-btn:hover {
    background-color: #475569 !important;
}

/* --- Botón de WhatsApp y Acciones --- */
.aliado-wa {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #3b71ca;
    color: #ffffff;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 10px 16px;
    border-radius: 6px;
    text-decoration: none;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    width: 100%;
}

.aliado-wa:hover {
    background-color: #315fb0;
    color: #ffffff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.whatsapp-btn-icon {
    fill: currentColor !important;
    vertical-align: middle !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 8px !important;
    display: inline-block !important;
    flex-shrink: 0 !important;
}

/* Media Query exclusivo para pasar a 1 columna en pantallas chicas */
@media (max-width: 850px) {
    .bento-container {
        grid-template-columns: 1fr !important;
    }
}

@media (min-width: 851px) {
    .principal-consultor {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
    .principal-consultor .bento-main-content {
        flex-direction: row;
        text-align: left;
    }
    .principal-consultor .aliado-info {
        text-align: left;
    }
    .principal-consultor .aliado-zona {
        justify-content: flex-start;
    }
    .principal-consultor .bento-actions {
        width: auto;
    }
    .principal-consultor .aliado-wa {
        width: auto;
        min-width: 160px;
    }
}