/**
 * WooCommerce Varyasyon Konfiguratörü - Frontend Stilleri
 * @package WC_Variation_Configurator
 * @since 2.0.0
 */

/* ==========================================================================
   LOADER - AJAX YÜKLEME ANIMASYONU
   ========================================================================== */

.wvc-loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wvc-loader {
    background: #fff;
    padding: 30px 40px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.wvc-spinner {
    width: 50px;
    height: 50px;
    margin: 0 auto 15px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #0073aa;
    border-radius: 50%;
    animation: wvc-spin 1s linear infinite;
}

@keyframes wvc-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.wvc-loader span {
    display: block;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

/* ==========================================================================
   KOŞULLU ALANLAR - GENEL
   ========================================================================== */

.wvc-conditional-field {
    transition: opacity 0.3s ease-in-out, max-height 0.3s ease-in-out;
    overflow: hidden;
}

.wvc-conditional-field[style*="display: none"] {
    opacity: 0;
    max-height: 0;
}

/* ==========================================================================
   VARYASYON TABLOSU DÜZENLEMELERİ
   ========================================================================== */

.variations_form .variations {
    margin-bottom: 1.5em;
    position: relative;
}

.variations_form .variations .wvc-conditional-field {
    margin-top: 0;
}

/* TR elementi olarak gizlenen satırlar */
.variations_form .variations tr.wvc-conditional-field {
    transition: all 0.3s ease;
}

.variations_form .variations tr.wvc-conditional-field td {
    padding: 12px 0;
}

/* ==========================================================================
   RESPONSIVE DÜZENLEMELER
   ========================================================================== */

@media (max-width: 768px) {
    .variations_form .variations tr.wvc-conditional-field {
        display: block;
        width: 100%;
    }
    
    .variations_form .variations tr.wvc-conditional-field td {
        display: block;
        width: 100%;
        padding: 10px 0;
    }
    
    .wvc-loader {
        padding: 20px 30px;
    }
    
    .wvc-spinner {
        width: 40px;
        height: 40px;
    }
}

/* ==========================================================================
   TEMA UYUMLULUK
   ========================================================================== */

/* Storefront teması */
body.theme-storefront .variations_form .variations tr.wvc-conditional-field {
    background: inherit;
}

/* Astra teması */
body.theme-astra .variations_form .variations tr.wvc-conditional-field {
    background: inherit;
}

/* OceanWP teması */
body.theme-oceanwp .variations_form .variations tr.wvc-conditional-field {
    background: inherit;
}

/* GeneratePress teması */
body.theme-generatepress .variations_form .variations tr.wvc-conditional-field {
    background: inherit;
}

/* Woodmart teması */
body.theme-woodmart .variations_form .variations tr.wvc-conditional-field {
    background: inherit;
}

/* ==========================================================================
   LABEL VE SELECT DÜZENLEMELERİ
   ========================================================================== */

.wvc-conditional-field label {
    font-weight: 600;
    display: block;
    margin-bottom: 5px;
}

.wvc-conditional-field select {
    width: 100%;
    max-width: 100%;
}

/* ==========================================================================
   YARDIMCI SINIFLAR
   ========================================================================== */

.wvc-hidden {
    display: none !important;
    opacity: 0 !important;
}

.wvc-visible {
    display: block !important;
    opacity: 1 !important;
}

/* ==========================================================================
   ANIMASYONLAR
   ========================================================================== */

@keyframes wvcSlideDown {
    from {
        opacity: 0;
        max-height: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        max-height: 500px;
        transform: translateY(0);
    }
}

@keyframes wvcSlideUp {
    from {
        opacity: 1;
        max-height: 500px;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        max-height: 0;
        transform: translateY(-10px);
    }
}

.wvc-conditional-field.wvc-animating-in {
    animation: wvcSlideDown 0.3s ease forwards;
}

.wvc-conditional-field.wvc-animating-out {
    animation: wvcSlideUp 0.3s ease forwards;
}