nexora / frontend /src /skeletons /HeroSection.css
ChandimaPrabath's picture
0.0.0.2 Alpha
3b85fd7
raw
history blame
No virus
2.17 kB
/* SkeletonLoader.css */
.skeleton-container {
position: relative;
width: 100%;
height: 480px; /* Set height to auto for responsiveness */
display: flex;
flex-direction: column;
justify-content: flex-end;
background-color: #1b1d2b; /* Dark purple background */
padding: 1rem;
padding-bottom: 2rem;
overflow: hidden;
}
.skeleton-image {
width: 100%;
height: 100%; /* Adjust height to fit container */
max-height: 400px; /* Maximum height to maintain aspect ratio */
border-radius: 4px;
background: linear-gradient(90deg, #3b3f5c 25%, #2b2d43 50%, #3b3f5c 75%);
background-size: 200% 100%;
animation: shimmer 1.5s infinite;
}
.skeleton-text {
display: flex;
flex-direction: column;
gap: 0.4rem;
position: relative;
z-index: 1;
padding-top: 10px;
}
.skeleton-title, .skeleton-description {
background: linear-gradient(90deg, #3b3f5c 25%, #2b2d43 50%, #3b3f5c 75%);
background-size: 200% 100%;
border-radius: 4px;
animation: shimmer 1.5s infinite;
}
.skeleton-title {
width: 50%;
height: 2rem;
}
.skeleton-description {
width: 70%;
height: 1.2rem;
}
/* Responsive Styles */
@media (max-width: 1200px) {
.skeleton-title {
width: 60%;
}
.skeleton-description {
width: 80%;
}
}
@media (max-width: 992px) {
.skeleton-container {
height: 400px;
}
.skeleton-title {
width: 70%;
height: 1.8rem;
}
.skeleton-description {
width: 85%;
height: 1.1rem;
}
}
@media (max-width: 768px) {
.skeleton-container {
height: 300px;
}
.skeleton-title {
width: 80%;
height: 1.6rem;
}
.skeleton-description {
width: 90%;
height: 1rem;
}
}
@media (max-width: 576px) {
.skeleton-container {
height: 200px;
}
.skeleton-title {
width: 90%;
height: 1.4rem;
}
.skeleton-description {
width: 95%;
height: 0.9rem;
}
}
@keyframes shimmer {
0% {
background-position: -200% 0;
}
100% {
background-position: 200% 0;
}
}