/* Booking-style skeleton + load-elm */

@keyframes load-elm-shimmer {
    0% { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

.load-elm {
    position: relative;
    min-width: 0;
}

.load-elm.is-loading {
    pointer-events: none;
}

.load-elm.is-loaded > .sk {
    display: none;
}

.load-elm.is-error {
    border: 1px solid #f1d0d6;
    background: #fff5f7;
    border-radius: 12px;
    padding: 16px;
    color: #9b1c3a;
    font-size: 14px;
}

/* Skeleton blocks */
.sk {
    display: block;
    width: 100%;
}

.sk-card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.03);
}

.sk-line,
.sk-box,
.sk-avatar,
.sk-btn {
    background: linear-gradient(
        90deg,
        #eceff3 0%,
        #f7f8fa 40%,
        #eceff3 80%
    );
    background-size: 200% 100%;
    animation: load-elm-shimmer 1.15s ease-in-out infinite;
    border-radius: 8px;
}

.sk-line {
    height: 14px;
    margin-bottom: 12px;
    width: 100%;
}

.sk-line-lg {
    height: 22px;
    width: 62%;
    margin-bottom: 16px;
}

.sk-line-md {
    width: 78%;
}

.sk-line-sm {
    width: 44%;
    margin-bottom: 0;
}

.sk-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    flex: 0 0 48px;
}

.sk-box {
    height: 120px;
    width: 100%;
    margin-bottom: 14px;
    border-radius: 10px;
}

.sk-btn {
    height: 40px;
    width: 120px;
    margin-top: 8px;
}

.sk-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.sk-row .sk-lines {
    flex: 1;
    min-width: 0;
}

.sk-row .sk-lines .sk-line:last-child {
    margin-bottom: 0;
}

/* Fade-in treści jak Booking */
.load-elm-content {
    opacity: 0;
    transform: translateY(4px);
    transition: opacity .28s ease, transform .28s ease;
}

.load-elm.is-loaded .load-elm-content {
    opacity: 1;
    transform: none;
}

/* Siatka demo na dashboardzie */
.load-elm-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-top: 24px;
}

@media (min-width: 992px) {
    .load-elm-grid {
        grid-template-columns: 1fr 1fr;
    }

    .load-elm-grid .load-elm-span-2 {
        grid-column: 1 / -1;
    }
}
