Template:BentoGrid/styles.css
Jump to navigation
Jump to search
.bento-grid {
display: grid;
gap: 16px;
max-width: 1000px;
}
.bento-grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
.bento-grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
.bento-grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
.bento-grid-cols-5 { grid-template-columns: repeat(5, 1fr); }
.bento-grid-cols-6 { grid-template-columns: repeat(6, 1fr); }
.bento-box {
position: relative;
overflow: hidden;
border: 1px solid #333338;
background-color: #1a1a1c;
min-height: 120px;
transition: border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}
.bento-box:hover {
border-color: #ff540c;
transform: translateY(-2px);
box-shadow: 0 8px 20px rgba(255, 84, 12, 0.1);
}
.bento-box::after {
content: '';
position: absolute;
bottom: -1px;
right: -1px;
width: 10px;
height: 10px;
border-bottom: 2px solid #888891;
border-right: 2px solid #888891;
transition: border-color 0.3s;
z-index: 2;
}
.bento-box:hover::after {
border-color: #ff540c;
}
.bento-box-bg {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background-size: cover;
background-position: center;
opacity: 0.4;
z-index: 0;
}
.bento-box-content {
position: relative;
z-index: 1;
padding: 20px;
display: flex;
flex-direction: column;
justify-content: flex-start;
height: 100%;
}
.bento-box-link {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
z-index: 5;
}
.bento-box-link a {
display: block;
width: 100%;
height: 100%;
color: transparent !important;
text-decoration: none !important;
}
.bento-box-title {
font-size: 1.2rem;
font-weight: bold;
color: #ffffff;
margin-bottom: 4px;
}
.bento-box-subtitle {
font-size: 0.7rem;
color: #ff540c;
text-transform: uppercase;
letter-spacing: 1px;
}
.bento-box-subtitle-tag {
background: #ff540c;
color: #fff;
padding: 2px 8px;
display: inline-block;
width: fit-content;
}
.bento-colspan-1 { grid-column: span 1; }
.bento-colspan-2 { grid-column: span 2; }
.bento-colspan-3 { grid-column: span 3; }
.bento-colspan-4 { grid-column: span 4; }
.bento-colspan-5 { grid-column: span 5; }
.bento-colspan-6 { grid-column: span 6; }
.bento-rowspan-1 { grid-row: span 1; }
.bento-rowspan-2 { grid-row: span 2; }
.bento-rowspan-3 { grid-row: span 3; }
.bento-h-sm { min-height: 100px; }
.bento-h-md { min-height: 120px; }
.bento-h-lg { min-height: 200px; }
.bento-h-xl { min-height: 260px; }
.bento-valign-start .bento-box-content { justify-content: flex-start; }
.bento-valign-center .bento-box-content { justify-content: center; align-items: center; text-align: center; }
.bento-valign-end .bento-box-content { justify-content: flex-end; }
.bento-pad-sm .bento-box-content { padding: 12px; }
.bento-pad-md .bento-box-content { padding: 20px; }
.bento-pad-lg .bento-box-content { padding: 30px; }
.bento-title-sm .bento-box-title { font-size: 1rem; }
.bento-title-md .bento-box-title { font-size: 1.2rem; }
.bento-title-lg .bento-box-title { font-size: 1.6rem; }
.bento-title-xl .bento-box-title { font-size: 2rem; }
.bento-has-image .bento-box-title {
text-shadow: 2px 2px 0 #000;
}
.bento-style-accent {
background-color: rgba(255, 84, 12, 0.08);
border-color: #ff540c;
}
.bento-style-accent:hover {
background-color: #ff540c;
}
.bento-style-accent:hover .bento-box-title {
color: #0f0f11;
}
.bento-style-accent:hover .bento-box-subtitle {
color: #0f0f11;
}
.bento-style-dark {
background-color: #111113;
}
.bento-bg-opacity-20 .bento-box-bg { opacity: 0.2; }
.bento-bg-opacity-40 .bento-box-bg { opacity: 0.4; }
.bento-bg-opacity-60 .bento-box-bg { opacity: 0.6; }
.bento-bg-opacity-80 .bento-box-bg { opacity: 0.8; }
@media (max-width: 768px) {
.bento-grid-cols-4,
.bento-grid-cols-5,
.bento-grid-cols-6 {
grid-template-columns: repeat(2, 1fr);
}
.bento-colspan-3,
.bento-colspan-4,
.bento-colspan-5,
.bento-colspan-6 {
grid-column: span 2;
}
.bento-title-xl .bento-box-title {
font-size: 1.4rem;
}
.bento-h-xl {
min-height: 180px;
}
}
@media (max-width: 480px) {
.bento-grid {
grid-template-columns: 1fr !important;
}
.bento-colspan-1,
.bento-colspan-2,
.bento-colspan-3,
.bento-colspan-4,
.bento-colspan-5,
.bento-colspan-6 {
grid-column: span 1;
}
.bento-h-xl {
min-height: 140px;
}
.bento-title-xl .bento-box-title {
font-size: 1.2rem;
}
}