/**
 * Fourthwall WooCommerce Integration - Frontend Styles
 */

/* Fourthwall Checkout Section */
.fw-woo-checkout-section {
    padding: 20px;
    background: #f9f9f9;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    margin-top: 20px;
}

.fw-woo-checkout-section h3 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #333;
}

.fw-woo-checkout-section select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background: white;
    margin-bottom: 15px;
}

.fw-woo-checkout-section select:focus {
    outline: none;
    border-color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
}

/* Checkout Button */
.fw-checkout-btn {
    display: inline-block;
    width: 100%;
    padding: 15px 30px;
    background-color: #1a1a1a;
    color: white;
    font-size: 16px;
    font-weight: 600;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.fw-checkout-btn:hover:not(:disabled) {
    background-color: #333;
    box-shadow: 0 2px 8px rgba(26, 26, 26, 0.2);
    transform: translateY(-1px);
}

.fw-checkout-btn:active:not(:disabled) {
    transform: translateY(0);
}

.fw-checkout-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* WooCommerce Notice Styles */
.woocommerce-notice {
    padding: 12px 15px;
    margin: 15px 0;
    border-left: 4px solid;
    border-radius: 4px;
    background-color: #fff;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.woocommerce-success {
    border-left-color: #4CAF50;
    background-color: #f1f8f6;
    color: #155724;
}

.woocommerce-error {
    border-left-color: #f44336;
    background-color: #fef5f4;
    color: #721c24;
}

.woocommerce-info {
    border-left-color: #2196F3;
    background-color: #f0f7ff;
    color: #004085;
}

/* Loading State */
.fw-checkout-btn.loading {
    position: relative;
}

.fw-checkout-btn.loading::after {
    content: '';
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-left: 10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    vertical-align: middle;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .fw-woo-checkout-section {
        padding: 15px;
    }
    
    .fw-woo-checkout-section h3 {
        font-size: 14px;
    }
    
    .fw-checkout-btn {
        padding: 12px 20px;
        font-size: 14px;
    }
}

/* Variant Select */
#fw-product-variant {
    border: 1px solid #ddd;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 14px;
}

#fw-product-variant:hover {
    border-color: #999;
}

#fw-product-variant:focus {
    border-color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
}

/* Form Control */
.form-control {
    display: block;
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;
    color: #333;
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
}

/* Print Styles */
@media print {
    .fw-woo-checkout-section,
    .fw-checkout-btn {
        display: none !important;
    }
}
