/**
 * WC State Restrictions - Frontend Styles
 *
 * @package WC_State_Restrictions
 * @since 1.0.0
 */

/* Restriction Notice on Product Page */
.wcsr-restriction-notice {
    margin: 15px 0;
    padding: 12px 15px;
    background: #fef3c7;
    border: 1px solid #fcd34d;
    border-left: 4px solid #f59e0b;
    border-radius: 4px;
    color: #92400e;
}

.wcsr-restriction-notice p {
    margin: 0;
    font-size: 14px;
}

.wcsr-restriction-notice .dashicons {
    vertical-align: middle;
    margin-right: 5px;
    color: #f59e0b;
}

/* Restricted Badge in Product Loop */
.wcsr-restricted-badge {
    display: block;
    margin-top: 10px;
    padding: 6px 12px;
    background: #fef3c7;
    border: 1px solid #fcd34d;
    border-radius: 4px;
    color: #92400e;
    font-size: 12px;
    text-align: center;
}

/* Cart Notice */
.woocommerce-cart .woocommerce-info.wcsr-cart-notice {
    background: #fef3c7;
    border-color: #fcd34d;
    color: #92400e;
}

.woocommerce-cart .woocommerce-info.wcsr-cart-notice::before {
    color: #f59e0b;
}

/* Checkout Error */
.woocommerce-checkout .woocommerce-error li {
    list-style: none;
}

/* Disabled Add to Cart Button */
.wcsr-product-restricted .single_add_to_cart_button,
.wcsr-product-restricted .add_to_cart_button,
.single_add_to_cart_button.wcsr-disabled,
.add_to_cart_button.wcsr-disabled {
    opacity: 0.5 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
    background-color: #9ca3af !important;
    border-color: #9ca3af !important;
    color: #fff !important;
}

/* Restriction Message Before Add to Cart */
.wcsr-add-to-cart-restriction {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 15px 0;
    padding: 15px 18px;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 1px solid #f59e0b;
    border-left: 4px solid #d97706;
    border-radius: 6px;
    color: #92400e;
    box-shadow: 0 2px 4px rgba(217, 119, 6, 0.1);
}

.wcsr-add-to-cart-restriction .dashicons {
    color: #d97706;
    font-size: 20px;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    margin-top: 2px;
}

.wcsr-add-to-cart-restriction p {
    margin: 0;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
}

/* Legacy support */
.wcsr-disabled-product .single_add_to_cart_button {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* State Selection Notice */
.wcsr-state-notice {
    background: #e0f2fe;
    border: 1px solid #7dd3fc;
    border-left: 4px solid #0ea5e9;
    border-radius: 4px;
    padding: 12px 15px;
    margin-bottom: 20px;
    color: #0369a1;
}

.wcsr-state-notice strong {
    color: #0c4a6e;
}

/* Product Grid Overlay for Hidden Products (debug mode) */
.wcsr-debug-hidden {
    position: relative;
}

.wcsr-debug-hidden::after {
    content: 'Restricted in your state';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(239, 68, 68, 0.9);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Responsive */
@media screen and (max-width: 768px) {
    .wcsr-restriction-notice {
        margin: 10px 0;
        padding: 10px 12px;
    }
    
    .wcsr-restriction-notice p {
        font-size: 13px;
    }
    
    .wcsr-restricted-badge {
        font-size: 11px;
        padding: 5px 10px;
    }
}
