Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

358
Visualizações
Align last 2 level nested divs horizontally

I am trying to override an HTML generated by a software. I cannot change the HTML, but however the software gives the ability to add inline CSS. These are nested blocks inside each other.

<div id='A'> DIV A
  <div id='B'> DIV B
    <div id='C'> DIV C
    </div>
  </div>
</div>

Here A>B>C. I have tried adding

#A > div {display:inline-blocks;} 

&

#A {
display: flex;
flex-direction: row; }

but somehow DIV C is always below DIV B since its coded under DIV B. Is there anyway, I can override the CSS. The output I am looking is something like below, with DIV B & DIV C aligned horizontally, shouldn't overlap different screen sizes

enter image description here

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

The only way to do that with css is to use position absolute on divs and to override something specificly you can use !important.

div a{
 position: relative;
 padding:0 15px;
}

div b {
 witdh:20%
}

div c{
 position: absolute;
 width:70%;
 bottom:0;
 right:15px;
}

This code would work for some resolutions once we're using percentage size, but you will need to check them and also improve the code if needed.

Would also being an option to display none div c and recreate it with Js outside of the div b.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda