/* Faida Price Plugin Styles */

.faida-prices {
    display: flex;
    gap: 15px;
    align-items: center;
    margin: 10px 0;
    flex-wrap: wrap;
}

.faida-prices .public-price,
.faida-prices .member-price {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 12px;
    border-radius: 6px;
    font-weight: 600;
}

.faida-prices .wholesale-price {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 12px;
    border-radius: 6px;
    font-weight: 700;
}

.faida-prices .public-price {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    color: #6c757d;
}

.faida-prices .member-price {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.faida-prices .wholesale-price {
    background-color: #e2e3ff;
    border: 1px solid #b8b9ff;
    color: #2f2faa;
}

.faida-prices small {
    font-size: 11px;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

.faida-member-price-info {
    margin-top: 15px;
    padding: 15px;
    background-color: #f8f9fa;
    border-left: 4px solid #28a745;
    border-radius: 4px;
}

.member-price-label {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 600;
    color: #155724;
}

.member-price-amount {
    color: #28a745;
    font-size: 18px;
    font-weight: 700;
}

.wholesale-price-label {
    margin: 8px 0 0 0;
    font-size: 15px;
    font-weight: 600;
    color: #2f2faa;
}

.wholesale-price-amount {
    color: #2f2faa;
    font-size: 17px;
    font-weight: 700;
}

.login-for-member-price {
    margin: 0;
    color: #6c757d;
    font-style: italic;
}

/* Responsive design */
@media (max-width: 768px) {
    .faida-prices {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .faida-prices .public-price,
    .faida-prices .member-price {
        text-align: center;
    }
}

/* Shop page styles */
.woocommerce-page .faida-prices {
    margin: 5px 0;
    gap: 8px;
}

.woocommerce-page .faida-prices .public-price,
.woocommerce-page .faida-prices .member-price {
    padding: 4px 8px;
    font-size: 14px;
}

.woocommerce-page .faida-prices .wholesale-price {
    padding: 4px 8px;
    font-size: 14px;
}

.woocommerce-page .faida-prices small {
    font-size: 9px;
}

/* Grid-specific styles */
.faida-prices-grid {
    display: flex;
    gap: 6px;
    align-items: center;
    margin: 5px 0;
    flex-wrap: nowrap;
}

.faida-prices-grid .public-price,
.faida-prices-grid .member-price {
    display: inline-block;
    padding: 2px 5px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
}

.faida-prices-grid .public-price {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #6c757d;
    text-decoration: line-through;
}

.faida-prices-grid .member-price {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.faida-prices-grid .member-price.register-prompt {
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    animation: purpleBlink 2s infinite;
}

@keyframes purpleBlink {
    0%, 100% {
        background-color: #fff3cd;
        border-color: #ffeaa7;
        color: #856404;
        box-shadow: 0 0 0 0 rgba(128, 0, 128, 0.7);
    }
    25% {
        background-color: #e8d4f1;
        border-color: #9b59b6;
        color: #6c3483;
        box-shadow: 0 0 10px 2px rgba(128, 0, 128, 0.7);
    }
    50% {
        background-color: #d4a5f5;
        border-color: #8e44ad;
        color: #ffffff;
        box-shadow: 0 0 15px 4px rgba(128, 0, 128, 0.8);
    }
    75% {
        background-color: #c39bd3;
        border-color: #7d3c98;
        color: #ffffff;
        box-shadow: 0 0 10px 2px rgba(128, 0, 128, 0.7);
    }
}

.faida-prices-grid .member-price.register-prompt:hover {
    background-color: #d4a5f5 !important;
    border-color: #8e44ad !important;
    color: #ffffff !important;
    animation-play-state: paused;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(128, 0, 128, 0.6);
}

.faida-prices-grid .member-price:hover {
    background-color: #c3e6cb;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.faida-prices-grid .member-price:active {
    transform: translateY(0);
}

.faida-prices-grid .member-price.loading {
    opacity: 0.7;
    cursor: not-allowed;
}

.faida-prices-grid .member-price.added {
    background-color: #28a745;
    color: white;
}

.faida-prices-grid small {
    font-size: 8px;
    font-weight: 400;
    text-transform: lowercase;
    opacity: 0.8;
    margin-left: 1px;
}

/* Shop loop item specific */
.woocommerce-loop-product .price .faida-prices-grid {
    margin: 0;
    gap: 4px;
}

.woocommerce-loop-product .price .faida-prices-grid .public-price,
.woocommerce-loop-product .price .faida-prices-grid .member-price {
    font-size: 11px;
    padding: 2px 4px;
}

.woocommerce-loop-product .price .faida-prices .wholesale-price {
    font-size: 11px;
    padding: 2px 4px;
}

.faida-whatsapp-btn {
    background-color: #25D366 !important;
    border-color: #1ebe57 !important;
    color: #ffffff !important;
    display: inline-flex;
    align-items: center;
    margin-left: 8px;
}
.faida-whatsapp-btn:hover {
    background-color: #1ebe57 !important;
    border-color: #159c45 !important;
    color: #ffffff !important;
}

/* Related products and upsells */
.related.products .faida-prices-grid,
.upsells.products .faida-prices-grid {
    margin: 3px 0;
}

.related.products .faida-prices-grid .public-price,
.related.products .faida-prices-grid .member-price,
.upsells.products .faida-prices-grid .public-price,
.upsells.products .faida-prices-grid .member-price {
    font-size: 11px;
    padding: 2px 4px;
}

/* Variable product styles */
.variable-price-wrapper .faida-prices {
    margin: 10px 0;
}

/* Admin styles */
.wp-admin .faida-price-settings {
    max-width: 600px;
}

.faida-price-settings .form-table th {
    width: 200px;
}

/* Notification styles */
.faida-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 4px;
    color: white;
    font-weight: 600;
    z-index: 9999;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    max-width: 300px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.faida-notification.show {
    transform: translateX(0);
}

.faida-notification-success {
    background-color: #28a745;
}

.faida-notification-error {
    background-color: #dc3545;
}

.faida-notification-info {
    background-color: #17a2b8;
}

/* Mobile responsive notifications */
@media (max-width: 768px) {
    .faida-notification {
        right: 10px;
        left: 10px;
        max-width: none;
        top: 10px;
    }
}

/* Simplified Checkout Styles */
.woocommerce-checkout .woocommerce-billing-fields__field-wrapper,
.woocommerce-checkout .woocommerce-shipping-fields__field-wrapper {
    display: grid;
    gap: 15px;
}

.woocommerce-checkout .form-row-wide {
    width: 100%;
    margin-bottom: 15px;
}

.woocommerce-checkout .form-row {
    margin-bottom: 15px;
}

/* Simplified checkout header */
.woocommerce-checkout .woocommerce-billing-fields h3,
.woocommerce-checkout .woocommerce-shipping-fields h3 {
    font-size: 18px;
    margin-bottom: 20px;
    color: #333;
    border-bottom: 2px solid #28a745;
    padding-bottom: 10px;
}

/* Checkout form improvements */
.woocommerce-checkout input[type="text"],
.woocommerce-checkout input[type="email"],
.woocommerce-checkout input[type="tel"],
.woocommerce-checkout select {
    padding: 12px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.woocommerce-checkout input[type="text"]:focus,
.woocommerce-checkout input[type="email"]:focus,
.woocommerce-checkout input[type="tel"]:focus,
.woocommerce-checkout select:focus {
    border-color: #28a745;
    outline: none;
}

/* Place order button */
.woocommerce-checkout #place_order {
    background-color: #28a745;
    color: white;
    padding: 15px 30px;
    font-size: 18px;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.woocommerce-checkout #place_order:hover {
    background-color: #218838;
}

/* Checkout summary improvements */
.woocommerce-checkout-review-order {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

/* Mobile checkout */
@media (max-width: 768px) {
    .woocommerce-checkout .col2-set,
    .woocommerce-checkout .col-1,
    .woocommerce-checkout .col-2 {
        width: 100%;
        float: none;
    }
    
    .woocommerce-checkout .woocommerce-billing-fields,
    .woocommerce-checkout .woocommerce-shipping-fields {
        margin-bottom: 30px;
    }
}
