/**
 * Freebie Campaign Notices CSS
 */

/* Shop Page Notice */
.wccwp-freebie-notice {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 16px 20px;
    margin-bottom: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    position: relative;
    overflow: hidden;
    display: block;
    width: 100%;
    box-sizing: border-box;
}

.wccwp-freebie-notice::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
    0%, 100% { transform: translate(-50%, -50%) rotate(0deg); }
    50% { transform: translate(-30%, -30%) rotate(180deg); }
}

.wccwp-freebie-notice-content {
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
    z-index: 1;
}

.wccwp-freebie-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wccwp-freebie-icon svg {
    width: 24px;
    height: 24px;
}

.wccwp-freebie-message {
    flex-grow: 1;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.5;
}

.wccwp-freebie-dismiss {
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wccwp-freebie-dismiss:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

/* Cart Page Notice */
.wccwp-freebie-cart-notice {
    background: #f0fdf4;
    border-color: #10b981;
    color: #065f46;
    border-radius: 8px;
    padding: 15px 20px;
    margin-bottom: 20px;
    font-weight: 500;
}

.wccwp-freebie-cart-notice.wccwp-freebie-qualified {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border: 2px solid #10b981;
    font-size: 16px;
}

/* Progress Bar in Cart */
.wccwp-freebie-progress-row th {
    font-weight: 600;
    color: #374151;
}

.wccwp-freebie-progress-bar {
    background: #e5e7eb;
    border-radius: 8px;
    height: 24px;
    position: relative;
    overflow: hidden;
    margin-bottom: 8px;
}

.wccwp-freebie-progress-fill {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    height: 100%;
    transition: width 0.3s ease;
    position: relative;
}

.wccwp-freebie-progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    animation: progress-shine 2s ease-in-out infinite;
}

@keyframes progress-shine {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.wccwp-freebie-progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 12px;
    font-weight: 600;
    color: #1f2937;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.8);
}

.wccwp-freebie-progress-text .wccwp-qualified {
    color: #059669;
}

.wccwp-freebie-progress-hint {
    font-size: 13px;
    color: #6b7280;
    margin-top: 4px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .wccwp-freebie-notice {
        padding: 12px 16px;
        margin-bottom: 20px;
        position: relative !important;
        z-index: 9999 !important;
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    
    .wccwp-freebie-notice-content {
        gap: 12px;
    }
    
    .wccwp-freebie-icon {
        width: 40px;
        height: 40px;
    }
    
    .wccwp-freebie-message {
        font-size: 14px;
    }
    
    .wccwp-freebie-dismiss {
        width: 28px;
        height: 28px;
        font-size: 20px;
    }
}

/* Checkout Page Notice */
.wccwp-freebie-checkout-notice {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border: 2px solid #10b981;
    color: #065f46;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 30px;
    font-weight: 500;
}

.wccwp-freebie-checkout-content {
    display: flex;
    align-items: center;
    gap: 15px;
}

.wccwp-freebie-checkout-icon {
    font-size: 32px;
    flex-shrink: 0;
}

.wccwp-freebie-checkout-message {
    flex-grow: 1;
    font-size: 16px;
    line-height: 1.5;
}

.wccwp-freebie-checkout-notice small {
    display: block;
    margin-top: 5px;
    font-size: 14px;
    color: #047857;
    font-weight: 400;
}

/* Theme Compatibility */
.theme-astra .wccwp-freebie-notice,
.theme-storefront .wccwp-freebie-notice {
    margin-left: -20px;
    margin-right: -20px;
    border-radius: 0;
}

@media (min-width: 769px) {
    .theme-astra .wccwp-freebie-notice,
    .theme-storefront .wccwp-freebie-notice {
        margin-left: 0;
        margin-right: 0;
        border-radius: 8px;
    }
}