/**
 * Loading Designer Content Styles
 * Styles for displaying designer content in customer loading screens
 */

/* Two-Column Layout for Loading Overlay */
.loading-content-wrapper {
    display: flex;
    gap: 3rem;
    /* GPU-Optimierung: stretch statt center - Spalten dehnen sich gleich */
    /* Innere Zentrierung erfolgt in den Kind-Elementen */
    align-items: stretch;
    justify-content: center;
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
    z-index: 10;
    /* GPU-Optimierung: Stabile Container-Höhe verhindert Layout-Shift */
    min-height: 320px;
}

.loading-content-left {
    flex: 1 1 400px;
    max-width: 400px;
    min-width: 280px;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* GPU-Optimierung: Innere Zentrierung (ersetzt align-items:center auf Wrapper) */
    justify-content: center;
    text-align: center;
}

.loading-content-right {
    flex: 1 1 380px;
    max-width: 380px;
    min-width: 280px;
    min-height: 300px;
    opacity: 1; /* Ensure visibility even if animation doesn't complete */
    animation: slideInRight 0.6s ease-out forwards;
    /* GPU-Optimierung: Smooth Entry-Animation */
    will-change: opacity, transform;
    /* GPU-Optimierung: Innere Zentrierung (ersetzt align-items:center auf Wrapper) */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

@keyframes slideInRight {
    0% {
        opacity: 0;
        transform: translateX(30px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* GPU-Optimierung: Problematischer !important Selector entfernt - verursachte Animation-Konflikte */

/* Designer Content Card */
.designer-content-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    /* GPU-Optimierung: Spezifische Properties statt "all" für bessere Performance */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    will-change: opacity, transform;
    contain: layout style;
}

.designer-content-image {
    height: 180px;
    overflow: hidden;
    background: #f0f0f0;
    /* GPU-Optimierung: visibility statt display für stabile Höhe (kein CLS) */
    visibility: visible;
}

/* GPU-Optimierung: Visibility hidden reserviert den Platz im Layout */
.designer-content-image.hidden {
    visibility: hidden;
}

.designer-content-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.designer-content-card:hover .designer-content-image img {
    transform: scale(1.02);
}

.designer-content-body {
    padding: 1.5rem;
}

.designer-content-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a2e;
    margin: 0 0 0.75rem 0;
    line-height: 1.3;
}

.designer-content-text {
    color: #4a4a68;
    line-height: 1.6;
    margin: 0 0 1rem 0;
    font-size: 0.95rem;
}

.designer-content-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color, #4facfe);
    font-weight: 500;
    text-decoration: none;
    transition: gap 0.3s ease;
    font-size: 0.95rem;
}

.designer-content-link:hover {
    gap: 0.75rem;
    color: var(--primary-color, #4facfe);
}

/* Content Rotation Dots */
.content-rotation-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 1rem;
}

.rotation-dot {
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    /* GPU-Optimierung: Spezifische Properties statt "all" */
    transition: transform 0.3s ease, background-color 0.3s ease;
    cursor: pointer;
    will-change: transform;
    position: relative;
}

.rotation-dot.active {
    background: #4facfe;
    transform: scale(1.2);
}

/* GPU-Optimierung: Glow-Effekt via Pseudo-Element statt box-shadow (GPU-freundlich) */
.rotation-dot.active::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    background: #4facfe;
    opacity: 0.4;
    filter: blur(4px);
    z-index: -1;
}

.rotation-dot:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Content Fade Animation */
/* GPU-Optimierung: Reduzierte translateY (5px statt 10px) für weniger Layout-Bewegung */
@keyframes contentFadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.designer-content-card.rotating {
    animation: contentFadeIn 0.4s ease-out;
}

/* No Content Message */
.no-content-message {
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    padding: 2rem;
}

/* Mobile Responsive */
@media (max-width: 900px) {
    .loading-content-wrapper {
        flex-direction: column;
        gap: 2rem;
        padding: 1.5rem;
    }

    .loading-content-left {
        max-width: 100%;
        width: 100%;
    }

    .loading-content-right {
        max-width: 100%;
        width: 100%;
        opacity: 1;
        animation: slideInUp 0.6s ease-out forwards;
    }

    @keyframes slideInUp {
        from {
            opacity: 0;
            transform: translateY(30px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}

@media (max-width: 480px) {
    .loading-content-wrapper {
        padding: 1rem;
        gap: 1.5rem;
    }

    .designer-content-image {
        height: 140px;
    }

    .designer-content-body {
        padding: 1rem;
    }

    .designer-content-title {
        font-size: 1.1rem;
    }

    .designer-content-text {
        font-size: 0.9rem;
    }

    /* On very small screens, hide designer content to prioritize loading info */
    .loading-content-right {
        display: none;
    }
}

/* If no designer content, center the loading content */
.loading-content-wrapper:has(.loading-content-right[style*="display: none"]) {
    justify-content: center;
}

.loading-content-wrapper:has(.loading-content-right[style*="display: none"]) .loading-content-left {
    max-width: 100%;
}
