Files
tuhui.cloud/frontend/src/components/Festival.css
2026-03-08 19:28:32 +08:00

123 lines
1.9 KiB
CSS

.festival {
padding: 20px 20px 30px;
max-width: 1200px;
margin: 0 auto;
}
.festival-container {
position: relative;
}
.festival-scroll {
display: flex;
gap: 12px;
overflow-x: auto;
padding: 10px 0;
scrollbar-width: none;
-ms-overflow-style: none;
}
.festival-scroll::-webkit-scrollbar {
display: none;
}
.festival-card {
flex-shrink: 0;
width: 150px;
background: white;
border-radius: 12px;
padding: 16px;
display: flex;
flex-direction: column;
align-items: center;
gap: 8px;
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
cursor: pointer;
transition: all 0.3s ease;
animation: slideIn 0.5s ease forwards;
animation-delay: var(--delay);
opacity: 0;
transform: translateX(20px);
}
@keyframes slideIn {
to {
opacity: 1;
transform: translateX(0);
}
}
.festival-card:hover {
transform: translateY(-4px);
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}
.festival-emoji {
font-size: 32px;
line-height: 1;
}
.festival-content {
text-align: center;
}
.festival-name {
font-size: 16px;
font-weight: 600;
color: #333;
margin: 0;
}
.festival-date {
font-size: 12px;
color: #999;
margin: 4px 0 0;
}
.festival-days {
display: flex;
align-items: baseline;
gap: 2px;
margin-top: 4px;
}
.days-number {
font-size: 20px;
font-weight: 700;
color: #ff5a5a;
}
.days-text {
font-size: 12px;
color: #999;
}
.festival-scroll-btn {
position: absolute;
right: -10px;
top: 50%;
transform: translateY(-50%);
z-index: 10;
background: white;
border: none;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
width: 36px;
height: 36px;
}
.festival-scroll-btn:hover {
background: #ff5a5a !important;
color: white !important;
}
@media (max-width: 768px) {
.festival-card {
width: 130px;
padding: 12px;
}
.festival-emoji {
font-size: 28px;
}
}