/**
 * Coupon Widget Front CSS
 */

.coupon-widget {
    margin-bottom: 5px;
}

.coupon-widget-title {
    margin: 0 0 20px 0;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.2;
    display:none;
}
.js-product-miniature-wrapper .ddbuilder-widget-coupon-widget-ProductCoupon{
    position: absolute;
    margin-top: -50px;
    width:100%;
    background: #ffffffde
}
/* List Mode */
.coupons-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Grid Mode */
.coupons-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

/* Carousel Mode (requires additional JS) */
.coupons-carousel {
    position: relative;
    overflow: hidden;
}

.coupons-carousel .carousel-inner {
    display: flex;
    transition: transform 0.3s ease;
}

.coupon-card {
    position: relative;
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    padding: 20px;
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* Coupon Styles */
.coupon-card.default {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
}

.coupon-card.bordered {
    border: 2px dashed #007bff;
    background: #fff;
}

.coupon-card.shadow {
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    border: none;
}

.coupon-card.highlight {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border: none;
}

.highlight .discount-badge {
    background: rgba(255,255,255,0.2);
    color: #fff;
}

.highlight .coupon-code {
    background: rgba(0,0,0,0.2);
    color: #fff;
}

/* Discount Badge */
.discount-badge {
    display: inline-block;
    background: #007bff;
    color: #fff;
    padding: 8px 15px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 18px;
    margin-bottom: 15px;
    align-self: flex-start;
}

.free-shipping-badge {
    background: #28a745;
}

.gift-badge {
    background: #17a2b8;
}

/* Coupon Info */
.coupon-info {
    flex: 1;
    margin-bottom: 15px;
}

.coupon-name {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 10px 0;
}

.coupon-description {
    font-size: 14px;
    opacity: 0.9;
    margin: 0;
}

/* Coupon Details */
.coupon-details {
    margin: 15px 0;
    font-size: 14px;
}

.coupon-detail-item {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.coupon-detail-item i {
    font-size: 16px;
    color: #6c757d;
    width: 20px;
}

.highlight .coupon-detail-item i {
    color: rgba(255,255,255,0.8);
}

.minimal-purchase {
    color: #6c757d;
    font-size: 13px;
}

.expiry-date {
    color: #dc3545;
    font-size: 13px;
}

.highlight .minimal-purchase,
.highlight .expiry-date {
    color: rgba(255,255,255,0.8);
}

/* Coupon Code */
.coupon-code-wrapper {
    display: flex;
    align-items: center;
    margin-top: 15px;
}

.coupon-code {
    flex: 1;
    background: #f1f3f4;
    padding: 10px 15px;
    border-radius: 4px 0 0 4px;
    font-family: monospace;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 1px;
    border: 1px solid #dee2e6;
    border-right: none;
}

.copy-code-btn {
    background: #e9ecef;
    border: 1px solid #dee2e6;
    border-left: none;
    padding: 10px 15px;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.copy-code-btn:hover {
    background: #dee2e6;
}

.copy-code-btn i {
    font-size: 18px;
    color: #495057;
}

.copy-code-btn.copied {
    background: #28a745;
    border-color: #28a745;
}

.copy-code-btn.copied i {
    color: #fff;
}

/* No code display */
.coupon-code.simple {
    border-radius: 4px;
    border-right: 1px solid #dee2e6;
    text-align: center;
}

/* Expired/Used indicators */
.coupon-card.expired {
    opacity: 0.6;
    filter: grayscale(0.5);
}

.coupon-card.used {
    opacity: 0.4;
    filter: grayscale(1);
}

/* Responsive */
@media (max-width: 992px) {
    .coupons-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .coupons-grid {
        grid-template-columns: 1fr;
    }
    
    .coupon-card {
        padding: 15px;
    }
    
    .discount-badge {
        font-size: 16px;
        padding: 6px 12px;
    }
}

/* Animations */
@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

.coupon-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(0,0,0,0.15);
}

.highlight.coupon-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(102, 126, 234, 0.4);
}

.coupon-card.highlight .copy-code-btn:hover {
    background: rgba(0,0,0,0.3);
}

/* Loading state */
.coupons-loading {
    text-align: center;
    padding: 40px;
}

.coupons-loading .spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 15px;
}

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

/* Empty state */
.coupons-empty {
    text-align: center;
    padding: 40px;
    background: #f8f9fa;
    border-radius: 8px;
    color: #6c757d;
}

.coupons-empty i {
    font-size: 48px;
    margin-bottom: 15px;
    color: #adb5bd;
}

.product__flash p{
    margin:0;
}
