/**
 * CONTENT LOADING STYLES
 * Skeleton loading, shimmer animations, and loading states
 * Consistent with the existing Visio Architecture design
 */

/* ============================================
   SKELETON BASE STYLES
   ============================================ */
.content-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s ease-in-out infinite;
    border-radius: 4px;
    position: relative;
    overflow: hidden;
}

@keyframes skeleton-shimmer {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* ============================================
   SKELETON CARD STYLES
   ============================================ */
.skeleton-card {
    opacity: 1;
    pointer-events: none;
}

.skeleton-card .hentry-wrap {
    position: relative;
}

.skeleton-card .skeleton-image {
    width: 100%;
    height: 0;
    padding-bottom: 66.67%;
    /* 3:2 aspect ratio */
    display: block;
}

.skeleton-card .skeleton-title {
    display: block;
    height: 24px;
    width: 80%;
    margin: 15px auto 0;
}

/* ============================================
   LOADING STATE STYLES
   ============================================ */
.is-loading {
    position: relative;
}

.is-loading::before {
    display: none;
    /* Remove overlay for cleaner look */
}

/* ============================================
   CONTENT FADE IN ANIMATION
   ============================================ */
@keyframes content-fade-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.content-loaded .hentry {
    animation: content-fade-in 0.3s ease-out forwards;
}

.content-loaded .hentry:nth-child(1) {
    animation-delay: 0.05s;
}

.content-loaded .hentry:nth-child(2) {
    animation-delay: 0.1s;
}

.content-loaded .hentry:nth-child(3) {
    animation-delay: 0.15s;
}

.content-loaded .hentry:nth-child(4) {
    animation-delay: 0.2s;
}

.content-loaded .hentry:nth-child(5) {
    animation-delay: 0.25s;
}

.content-loaded .hentry:nth-child(6) {
    animation-delay: 0.3s;
}

.content-loaded .hentry:nth-child(n+7) {
    animation-delay: 0.35s;
}

/* ============================================
   ERROR STATE STYLES
   ============================================ */
.content-error {
    background: #fff3f3;
    border: 1px solid #ffcdd2;
    border-radius: 8px;
    padding: 40px 20px;
    text-align: center;
    width: 100%;
    grid-column: 1 / -1;
}

.content-error h3 {
    color: #c62828;
    margin: 0 0 10px;
    font-size: 18px;
}

.content-error p {
    color: #b71c1c;
    margin: 0;
    opacity: 0.8;
}

.content-error button {
    margin-top: 20px;
    padding: 12px 28px;
    background: #333;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.content-error button:hover {
    background: #000;
    transform: translateY(-1px);
}

/* ============================================
   EMPTY STATE STYLES
   ============================================ */
.content-empty {
    text-align: center;
    padding: 60px 20px;
    width: 100%;
    grid-column: 1 / -1;
    background: rgba(0, 0, 0, 0.02);
    border-radius: 8px;
}

.content-empty h3 {
    color: #333;
    margin: 0 0 10px;
    font-size: 20px;
    font-weight: 600;
}

.content-empty p {
    color: #666;
    margin: 0;
}

/* ============================================
   FILTER SKELETON
   ============================================ */
.filters-skeleton {
    display: flex;
    justify-content: center;
    gap: 30px;
    padding: 0;
    margin: 0 0 60px 0;
}

.filters-skeleton .skeleton-filter {
    display: inline-block;
    height: 16px;
    width: 60px;
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */
@media screen and (max-width: 991px) {
    .skeleton-card .skeleton-title {
        height: 20px;
        margin-top: 12px;
    }
}

@media screen and (max-width: 680px) {

    .content-error,
    .content-empty {
        padding: 30px 15px;
    }

    .content-error h3,
    .content-empty h3 {
        font-size: 16px;
    }
}