problem with CSS
-
I’d like to achieve this result: the green button and icons should always be aligned at the bottom and as low as possible in the post’s square. The icons should not lose their position to the right when the button is not present.
I have this for now, but it doesn’t work well enough./* non comprensibile*/
.prezzo {
display: flex;
align-items: baseline;
}
/**
* icona segnaposto e icona calendario
*/
.prezzo {
display: flex;
justify-content: space-between;
padding-right: 10px;
padding-bottom: 5px;
}
/* icona segnaposto e icona calendario consigli chat GPT */
.prezzo {
display: flex;
align-items: center;
justify-content: flex-end; /* tiene tutto a destra */
gap: 10px; /* spazio costante tra icone e pulsante */
padding-right: 10px;
padding-bottom: 5px;
}
/* L'icona calendario e la mappa devono stare vicine tra loro */
#icona-calendario2 {
order: 1;
}
#puntosumappa {
order: 2;
}
/* Il pulsante “a partire da” (se presente) resta il primo */
.prezzo form {
order: 0;
margin-right: auto; /* lo spinge a sinistra, ma lascia le icone vicine */
}
/* Se vuoi che le icone siano ancora più attaccate tra loro */
#icona-calendario2,
#puntosumappa {
display: inline-flex;
align-items: center;
gap: 6px;
}The page I need help with: [log in to see the link]
The topic ‘problem with CSS’ is closed to new replies.