Mudanças entre as edições de "Widget:MainPageMenu"
Ir para navegação
Ir para pesquisar
Etiqueta: Revertido |
Etiqueta: Revertido |
||
| Linha 84: | Linha 84: | ||
.home-button-container { | .home-button-container { | ||
display: grid; | display: grid; | ||
grid-template-columns: repeat(4, 1fr); /* sempre 4 colunas */ | |||
grid-template-columns: repeat( | |||
gap: 20px; | gap: 20px; | ||
padding: 10px; | padding: 10px; | ||
| Linha 103: | Linha 102: | ||
box-shadow: 0 1px 3px rgba(0,0,0,0.08); | box-shadow: 0 1px 3px rgba(0,0,0,0.08); | ||
box-sizing: border-box; | box-sizing: border-box; | ||
width: 100%; | width: 100%; | ||
margin: 0; | margin: 0; | ||
} | |||
/* desloca os últimos 3 botões para as colunas 2, 3 e 4, "centralizando" a fileira */ | |||
.home-button-container > .home-button-item:nth-last-child(3) { | |||
grid-column-start: 2; | |||
} | |||
.home-button-container > .home-button-item:nth-last-child(2) { | |||
grid-column-start: 3; | |||
} | |||
.home-button-container > .home-button-item:nth-last-child(1) { | |||
grid-column-start: 4; | |||
} | } | ||
| Linha 133: | Linha 141: | ||
height: 100%; | height: 100%; | ||
object-fit: cover; | object-fit: cover; | ||
transition: filter 0.3s ease; | transition: filter 0.3s ease; | ||
} | } | ||
| Linha 144: | Linha 149: | ||
.home-button-title { | .home-button-title { | ||
font-weight: bold; | font-weight: bold; | ||
text-align: center; | text-align: center; | ||
text-transform: uppercase; | text-transform: uppercase; | ||
| Linha 153: | Linha 156: | ||
color: #0645AD; | color: #0645AD; | ||
box-shadow: inset 0 1px 0 rgba(255,255,255,0.4); | box-shadow: inset 0 1px 0 rgba(255,255,255,0.4); | ||
font-family: "Noto Sans", sans-serif; | |||
} | } | ||
/* responsivo: cai pra 2 colunas em telas bem estreitas */ | |||
@media (max-width: 800px) { | |||
/* | |||
@media (max-width: | |||
.home-button-container { | .home-button-container { | ||
grid-template-columns: repeat( | grid-template-columns: repeat(2, 1fr); | ||
} | } | ||
} | } | ||
@media (max-width: 500px) { | |||
@media (max-width: | |||
.home-button-container { | .home-button-container { | ||
grid-template-columns: 1fr; | grid-template-columns: 1fr; | ||
Edição das 20h22min de 9 de junho de 2025
<style>
.home-button-container {
display: grid;
grid-template-columns: repeat(4, 1fr); /* sempre 4 colunas */
gap: 20px;
padding: 10px;
box-sizing: border-box;
font-family: "Noto Sans", sans-serif;
}
.home-button-item {
position: relative;
display: flex;
flex-direction: column;
overflow: hidden;
border: 1px solid #bbb;
border-radius: 12px;
background: #fff;
transition: transform 0.2s ease-out, box-shadow 0.2s ease-out, border-color 0.2s ease-out;
box-shadow: 0 1px 3px rgba(0,0,0,0.08);
box-sizing: border-box;
width: 100%;
margin: 0;
}
/* desloca os últimos 3 botões para as colunas 2, 3 e 4, "centralizando" a fileira */
.home-button-container > .home-button-item:nth-last-child(3) {
grid-column-start: 2;
}
.home-button-container > .home-button-item:nth-last-child(2) {
grid-column-start: 3;
}
.home-button-container > .home-button-item:nth-last-child(1) {
grid-column-start: 4;
}
.home-button-item:hover {
transform: translateY(-3px);
border-color: #007bff;
box-shadow: 0 4px 10px rgba(0,0,0,0.12);
}
.home-button-item a {
display: block;
color: inherit;
text-decoration: none;
height: 100%;
}
.home-button-image {
width: 100%;
aspect-ratio: 16/9;
overflow: hidden;
flex-shrink: 0;
}
.home-button-image img {
width: 100%;
height: 100%;
object-fit: cover;
transition: filter 0.3s ease;
}
.home-button-item:hover .home-button-image img {
filter: brightness(1.1);
}
.home-button-title {
font-weight: bold;
text-align: center;
text-transform: uppercase;
padding: 10px;
background: #fff;
color: #0645AD;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.4);
font-family: "Noto Sans", sans-serif;
}
/* responsivo: cai pra 2 colunas em telas bem estreitas */
@media (max-width: 800px) {
.home-button-container {
grid-template-columns: repeat(2, 1fr);
}
}
@media (max-width: 500px) {
.home-button-container {
grid-template-columns: 1fr;
}
}
</style>