Template:Main Page/Sandbox/card/styles.css: Difference between revisions
Template page
More actions
No edit summary |
Tag: Undo |
||
| Line 10: | Line 10: | ||
.home-card { | .home-card { | ||
position: relative; | position: relative; | ||
background: #161b22; | background: #161b22; | ||
border: 1px solid #30363d; | border: 1px solid #30363d; | ||
| Line 37: | Line 36: | ||
margin-bottom: 12px; | margin-bottom: 12px; | ||
line-height: 1; | line-height: 1; | ||
} | } | ||
/* Label styling and the "Full Click" trick */ | |||
.home-card__label a { | .home-card__label a { | ||
color: #c9d1d9 !important; | color: #c9d1d9 !important; | ||
font-weight: bold; | font-weight: bold; | ||
text-decoration: none !important; | text-decoration: none !important; | ||
font-size: 0.95em; | font-size: 0.95em; | ||
} | } | ||
| Line 84: | Line 54: | ||
.home-card--orange .home-card__icon { | .home-card--orange .home-card__icon { | ||
filter: none; | filter: none; | ||
} | |||
/* Expanding the link to cover the whole card */ | |||
.home-card__label a::after { | |||
content: ""; | |||
position: absolute; | |||
top: 0; left: 0; right: 0; bottom: 0; | |||
z-index: 1; | |||
} | } | ||
Revision as of 18:56, 3 February 2026
/* Container for the tile grid */
.resonite-home-grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
gap: 12px;
margin: 1em 0 2em 0;
}
/* The Card/Tile */
.home-card {
position: relative;
background: #161b22;
border: 1px solid #30363d;
border-radius: 8px;
padding: 24px 10px;
text-align: center;
transition: background 0.2s, transform 0.1s;
display: flex;
flex-direction: column;
align-items: center;
}
.home-card:hover {
transform: translateY(-2px);
}
/* Default hover when no solid background */
.home-card:not(.home-card--red):not(.home-card--orange):hover {
background: #21262d;
border-color: #8b949e;
}
/* Icon size and spacing */
.home-card__icon {
font-size: 2.5em;
margin-bottom: 12px;
line-height: 1;
}
/* Label styling and the "Full Click" trick */
.home-card__label a {
color: #c9d1d9 !important;
font-weight: bold;
text-decoration: none !important;
font-size: 0.95em;
}
/* White text on solid dark cards (red, orange) */
.home-card--red .home-card__label a,
.home-card--orange .home-card__label a {
color: #fff !important;
}
.home-card--red .home-card__icon,
.home-card--orange .home-card__icon {
filter: none;
}
/* Expanding the link to cover the whole card */
.home-card__label a::after {
content: "";
position: absolute;
top: 0; left: 0; right: 0; bottom: 0;
z-index: 1;
}
/* Color variants: Your first day (solid dark red), Rules (solid dark brown/maroon) */
.home-card--red {
background: #5c1a1a;
border: 1px solid #7a2222;
border-top: 3px solid #f85149;
}
.home-card--red:hover {
background: #6e2222;
border-color: #8b3030;
}
.home-card--orange {
background: #4a2c1a;
border: 1px solid #5c3820;
border-top: 3px solid #f0883e;
}
.home-card--orange:hover {
background: #5a3620;
border-color: #6e4428;
}
/* What now?: dark grey + yellow border. Creation & technical: grey + green. Advanced: grey + blue. */
.home-card--yellow {
background: #161b22;
border: 1px solid #30363d;
border-top: 3px solid #d4a72c;
}
.home-card--green {
background: #161b22;
border: 1px solid #30363d;
border-top: 3px solid #3fb950;
}
.home-card--blue {
background: #161b22;
border: 1px solid #30363d;
border-top: 3px solid #58a6ff;
}
.home-card--purple {
background: #161b22;
border: 1px solid #30363d;
border-top: 3px solid #bc8cff;
}