/* =============================================================
   NOVIQUE ESSENTIALS — COUPON & DISCOUNT BANNER SYSTEM
   Production-ready styles for all offer UI components
   ============================================================= */

/* ----------------------------------------------------------
   1. TOP ANNOUNCEMENT STRIP (Homepage / Sitewide)
   ---------------------------------------------------------- */
#nv-offer-strip {
    position: relative;
    width: 100%;
    background: linear-gradient(90deg, #f43f5e 0%, #e11d48 40%, #fb923c 100%);
    background-size: 200% 100%;
    animation: nv-strip-slide 6s ease infinite;
    color: #fff;
    padding: 0;
    z-index: 9999;
    overflow: hidden;
}

@keyframes nv-strip-slide {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.nv-offer-strip-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 10px 20px;
    max-width: 1400px;
    margin: 0 auto;
    flex-wrap: wrap;
}

.nv-strip-text {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-align: center;
    flex: 1;
    min-width: 0;
}

.nv-strip-code {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.18);
    border: 1.5px dashed rgba(255,255,255,0.5);
    border-radius: 6px;
    padding: 4px 12px;
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 0.12em;
    cursor: pointer;
    transition: background 0.2s ease;
    white-space: nowrap;
}

.nv-strip-code:hover {
    background: rgba(255,255,255,0.3);
}

.nv-strip-copy-icon {
    width: 14px;
    height: 14px;
    opacity: 0.85;
    flex-shrink: 0;
}

.nv-strip-copied-toast {
    display: inline-block;
    background: rgba(255,255,255,0.25);
    border-radius: 4px;
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 700;
    opacity: 0;
    transform: translateY(4px);
    transition: all 0.3s ease;
    pointer-events: none;
}

.nv-strip-copied-toast.show {
    opacity: 1;
    transform: translateY(0);
}

.nv-strip-close {
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.75);
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: color 0.2s ease;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.nv-strip-close:hover {
    color: #fff;
}

/* ----------------------------------------------------------
   2. PRODUCT PAGE NOTICE
   ---------------------------------------------------------- */
.nv-product-coupon-notice {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: linear-gradient(135deg, #fff5f7 0%, #fff 100%);
    border: 1.5px solid #fecdd3;
    border-left: 4px solid #f43f5e;
    border-radius: 12px;
    padding: 14px 18px;
    margin: 16px 0;
}

.nv-pcn-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #f43f5e, #e11d48);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #fff;
}

.nv-pcn-body {
    flex: 1;
    min-width: 0;
}

.nv-pcn-title {
    font-size: 13px;
    font-weight: 800;
    color: #0d0d0d;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 4px 0;
}

.nv-pcn-desc {
    font-size: 13px;
    color: #475569;
    margin: 0 0 8px 0;
    line-height: 1.5;
}

.nv-pcn-code-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.nv-pcn-code-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    border: 1.5px dashed #f43f5e;
    border-radius: 6px;
    padding: 4px 12px;
    font-size: 13px;
    font-weight: 900;
    color: #f43f5e;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: background 0.2s;
}

.nv-pcn-code-chip:hover {
    background: #fff5f7;
}

/* ----------------------------------------------------------
   3. CART & CHECKOUT — AVAILABLE OFFERS PANEL
   ---------------------------------------------------------- */
.nv-offers-panel {
    background: #fff;
    border: 1px solid #f1f5f9;
    border-radius: 18px;
    overflow: hidden;
    margin-bottom: 24px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.nv-offers-panel-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 20px;
    background: linear-gradient(135deg, #fff5f7 0%, #fff 100%);
    border-bottom: 1px solid #fecdd3;
    cursor: pointer;
    user-select: none;
}

.nv-offers-panel-icon {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #f43f5e, #e11d48);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
}

.nv-offers-panel-title {
    flex: 1;
    font-size: 14px;
    font-weight: 800;
    color: #0d0d0d;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0;
}

.nv-offers-panel-count {
    background: #f43f5e;
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 50px;
}

.nv-offers-chevron {
    transition: transform 0.3s ease;
    color: #94a3b8;
}

.nv-offers-panel.open .nv-offers-chevron {
    transform: rotate(180deg);
}

.nv-offers-body {
    display: none;
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Individual Coupon Card */
.nv-coupon-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: #fafafa;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px 16px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    position: relative;
    overflow: hidden;
}

.nv-coupon-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, #f43f5e, #fb923c);
}

.nv-coupon-card:hover {
    border-color: #fecdd3;
    box-shadow: 0 4px 16px rgba(244,63,94,0.1);
}

.nv-coupon-card.applied {
    border-color: #10b981;
    background: #f0fdf4;
}

.nv-coupon-card.applied::before {
    background: #10b981;
}

.nv-coupon-discount-badge {
    min-width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #f43f5e, #e11d48);
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
    text-align: center;
}

.nv-coupon-discount-badge.type-fixed {
    background: linear-gradient(135deg, #6366f1, #4f46e5);
}

.nv-coupon-discount-badge.type-freeship {
    background: linear-gradient(135deg, #10b981, #059669);
}

.nv-coupon-discount-num {
    font-size: 20px;
    font-weight: 900;
    line-height: 1;
}

.nv-coupon-discount-unit {
    font-size: 10px;
    font-weight: 700;
    opacity: 0.85;
    letter-spacing: 0.05em;
}

.nv-coupon-info {
    flex: 1;
    min-width: 0;
}

.nv-coupon-code {
    font-size: 15px;
    font-weight: 900;
    color: #0d0d0d;
    letter-spacing: 0.06em;
    margin: 0 0 3px 0;
}

.nv-coupon-desc {
    font-size: 12px;
    color: #64748b;
    margin: 0 0 6px 0;
    line-height: 1.4;
}

.nv-coupon-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.nv-coupon-tag {
    font-size: 10px;
    font-weight: 700;
    color: #64748b;
    background: #f1f5f9;
    padding: 2px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.nv-coupon-tag.expiry {
    color: #dc2626;
    background: #fef2f2;
}

.nv-coupon-apply-btn {
    background: linear-gradient(135deg, #f43f5e, #e11d48);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 10px 18px;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(244,63,94,0.25);
}

.nv-coupon-apply-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(244,63,94,0.35);
}

.nv-coupon-apply-btn:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.nv-coupon-applied-badge {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #10b981;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    flex-shrink: 0;
}

/* ----------------------------------------------------------
   4. FREE GIFT NOTICE (Cart/Checkout)
   ---------------------------------------------------------- */
.nv-freegift-notice {
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(135deg, #f0fdf4, #fff);
    border: 1.5px solid #bbf7d0;
    border-left: 4px solid #10b981;
    border-radius: 12px;
    padding: 14px 18px;
    margin-bottom: 20px;
}

.nv-freegift-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #10b981, #059669);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
    font-size: 18px;
}

.nv-freegift-body {
    flex: 1;
}

.nv-freegift-title {
    font-size: 13px;
    font-weight: 800;
    color: #0d0d0d;
    margin: 0 0 3px 0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.nv-freegift-desc {
    font-size: 12px;
    color: #475569;
    margin: 0;
    line-height: 1.5;
}

/* ----------------------------------------------------------
   5. COUPON FEEDBACK MESSAGES (AJAX Apply)
   ---------------------------------------------------------- */
.nv-coupon-msg {
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    margin-top: 12px;
    display: none;
}

.nv-coupon-msg.success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #065f46;
    display: block;
}

.nv-coupon-msg.error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
    display: block;
}

/* ----------------------------------------------------------
   6. RESPONSIVE OVERRIDES
   ---------------------------------------------------------- */
@media (max-width: 640px) {
    .nv-offer-strip-inner {
        padding: 8px 14px;
        gap: 10px;
    }

    .nv-strip-text {
        font-size: 12px;
    }

    .nv-strip-code {
        font-size: 13px;
        padding: 3px 10px;
    }

    .nv-coupon-card {
        flex-wrap: wrap;
    }

    .nv-coupon-apply-btn {
        width: 100%;
        text-align: center;
        justify-content: center;
    }

    .nv-coupon-discount-badge {
        min-width: 56px;
        height: 56px;
    }

    .nv-coupon-discount-num {
        font-size: 17px;
    }
}
