/**
 * UStyle Iframe Styles (product page)
 *
 * Loaded on WooCommerce product pages when the iframe feature is ON.
 * Served from backend — deploy = all stores updated instantly.
 */

/* Main container */
.ustyle-outfit-block {
    margin: 0 auto 50px;
    padding: 0 20px 40px;
    background: transparent;
    border-radius: 8px;
    transition: all 0.3s ease;
    max-width: none;
}

/* Header section */
.ustyle-outfit-header {
    text-align: center;
    margin-bottom: 24px;
}

.ustyle-outfit-title {
    font-size: 1.75rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 8px;
}

.ustyle-outfit-subtitle {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0;
    font-style: italic;
}

/* Iframe wrapper */
.ustyle-iframe-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.ustyle-iframe-wrapper iframe {
    display: block;
    width: 100%;
    border: none;
    border-radius: 8px;
    min-height: 700px;
}

/* Loading state */
.ustyle-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: #666;
}

.ustyle-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #6366f1;
    border-radius: 50%;
    animation: ustyle-spin 1s linear infinite;
}

@keyframes ustyle-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mobile responsive */
@media (max-width: 768px) {
    .ustyle-outfit-block {
        padding: 25px 12px;
        margin: 30px auto;
    }

    .ustyle-outfit-title {
        font-size: 1.25rem;
    }

    .ustyle-iframe-wrapper iframe {
        min-height: 450px;
    }
}

/* Desktop — centered with max width */
@media (min-width: 1141px) {
    .ustyle-iframe-wrapper {
        width: 1024px;
        margin: 0 auto;
    }

    .ustyle-iframe-wrapper iframe {
        width: 820px;
        margin: 0 auto;
        min-height: unset !important;
    }
}
