/*
 * Luxury Wedding Vendor Deals - Frontend Styles
 * Version: 1.0.0
 */

/* =============================================
   CSS Custom Properties (Theme Variables)
   ============================================= */
:root {
    --lwd-ivory:      #FFFFF0;
    --lwd-gold:       #D4AF37;
    --lwd-gold-dark:  #b5932d;
    --lwd-gold-light: #f0d97a;
    --lwd-charcoal:   #333333;
    --lwd-charcoal-soft: #555555;
    --lwd-white:      #ffffff;
    --lwd-border:     #e8e0cc;
    --lwd-shadow:     rgba(212, 175, 55, 0.15);
    --lwd-shadow-hover: rgba(212, 175, 55, 0.35);
    --lwd-radius:     12px;
    --lwd-font-heading: 'Playfair Display', Georgia, serif;
    --lwd-font-body:    'Montserrat', 'Helvetica Neue', Arial, sans-serif;
    --lwd-transition:   0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* =============================================
   Wrapper & Layout
   ============================================= */
.lwd-deals-wrapper {
    font-family: var(--lwd-font-body);
    color: var(--lwd-charcoal);
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
    box-sizing: border-box;
}

.lwd-deals-controls {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-bottom: 28px;
    flex-wrap: wrap;
    gap: 12px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--lwd-border);
}

.lwd-sort-links {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    color: var(--lwd-charcoal-soft);
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.lwd-sort-link {
    color: var(--lwd-charcoal-soft);
    text-decoration: none;
    padding: 5px 14px;
    border-radius: 20px;
    border: 1px solid var(--lwd-border);
    transition: all var(--lwd-transition);
}

.lwd-sort-link:hover,
.lwd-sort-link.lwd-active {
    background: var(--lwd-gold);
    border-color: var(--lwd-gold);
    color: var(--lwd-white);
}

/* Grid Layout */
.lwd-layout-grid .lwd-deals-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 28px;
}

/* List Layout */
.lwd-layout-list .lwd-deals-grid {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.lwd-layout-list .lwd-deal-card {
    display: grid;
    grid-template-columns: 280px 1fr;
    align-items: start;
}

.lwd-layout-list .lwd-card-image-wrap {
    height: 220px;
    border-radius: var(--lwd-radius) 0 0 var(--lwd-radius);
}

.lwd-layout-list .lwd-card-body {
    border-radius: 0 var(--lwd-radius) var(--lwd-radius) 0;
}

/* No Deals */
.lwd-no-deals {
    text-align: center;
    padding: 48px;
    font-family: var(--lwd-font-body);
    color: var(--lwd-charcoal-soft);
    font-style: italic;
}

/* =============================================
   Deal Card
   ============================================= */
.lwd-deal-card {
    position: relative;
    background: var(--lwd-white);
    border-radius: var(--lwd-radius);
    border: 1px solid var(--lwd-border);
    box-shadow: 0 4px 16px var(--lwd-shadow);
    overflow: hidden;
    transition: transform var(--lwd-transition), box-shadow var(--lwd-transition);
    display: flex;
    flex-direction: column;
}

.lwd-deal-card:hover {
    transform: translateY(-6px) scale(1.01);
    box-shadow: 0 12px 32px var(--lwd-shadow-hover);
}

.lwd-deal-card.lwd-deal-featured {
    border-color: var(--lwd-gold);
    box-shadow: 0 4px 20px var(--lwd-shadow-hover);
}

.lwd-deal-card.lwd-deal-expired {
    opacity: 0.7;
    filter: grayscale(30%);
}

/* =============================================
   Badges
   ============================================= */
.lwd-badge {
    position: absolute;
    top: 14px;
    z-index: 10;
    font-family: var(--lwd-font-body);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 5px 12px;
    border-radius: 4px;
    line-height: 1;
}

.lwd-badge-discount {
    right: 14px;
    background: var(--lwd-gold);
    color: var(--lwd-white);
}

.lwd-badge-featured {
    left: 14px;
    background: var(--lwd-charcoal);
    color: var(--lwd-gold);
}

/* Both badges present */
.lwd-deal-card:has(.lwd-badge-featured) .lwd-badge-discount {
    top: 14px;
}

/* =============================================
   Card Image
   ============================================= */
.lwd-card-image-wrap {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: var(--lwd-ivory);
}

.lwd-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform var(--lwd-transition);
}

.lwd-deal-card:hover .lwd-card-img {
    transform: scale(1.05);
}

.lwd-no-image {
    background: linear-gradient(135deg, var(--lwd-ivory) 0%, #f0e8c0 100%);
}

/* Video Play Button Overlay */
.lwd-video-play-btn {
    position: absolute;
    bottom: 12px;
    right: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
    transition: transform var(--lwd-transition), opacity var(--lwd-transition);
    opacity: 0.85;
}

.lwd-video-play-btn:hover {
    transform: scale(1.1);
    opacity: 1;
}

/* =============================================
   Card Body
   ============================================= */
.lwd-card-body {
    padding: 20px 22px 22px;
    display: flex;
    flex-direction: column;
    flex: 1;
    background: var(--lwd-white);
    gap: 8px;
}

.lwd-card-category {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--lwd-gold);
}

.lwd-card-title {
    font-family: var(--lwd-font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0;
    line-height: 1.3;
}

.lwd-card-title a {
    color: var(--lwd-charcoal);
    text-decoration: none;
    transition: color var(--lwd-transition);
}

.lwd-card-title a:hover {
    color: var(--lwd-gold);
}

.lwd-card-excerpt {
    font-size: 13.5px;
    color: var(--lwd-charcoal-soft);
    line-height: 1.6;
    flex: 1;
}

/* =============================================
   Pricing
   ============================================= */
.lwd-pricing {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-top: 4px;
}

.lwd-sale-price {
    font-family: var(--lwd-font-heading);
    font-size: 1.45rem;
    font-weight: 700;
    color: var(--lwd-gold-dark);
    letter-spacing: -0.01em;
}

.lwd-original-price {
    font-size: 0.95rem;
    color: #999;
    font-weight: 400;
}

.lwd-original-price s {
    text-decoration: line-through;
}

/* =============================================
   Expiry & Social Proof
   ============================================= */
.lwd-expiry {
    font-size: 12px;
    color: var(--lwd-charcoal-soft);
    display: flex;
    align-items: center;
    gap: 5px;
}

.lwd-expiry svg {
    flex-shrink: 0;
    opacity: 0.7;
}

.lwd-expired-label {
    color: #c53030;
    font-weight: 600;
}

.lwd-social-proof {
    font-size: 12px;
    color: var(--lwd-charcoal-soft);
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 500;
}

.lwd-social-proof svg {
    flex-shrink: 0;
    color: var(--lwd-gold);
}

/* =============================================
   WhatsApp Button
   ============================================= */
.lwd-whatsapp-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    margin-top: 8px;
    padding: 14px 20px;
    background: #25D366;
    color: var(--lwd-white);
    border: none;
    border-radius: 8px;
    font-family: var(--lwd-font-body);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background var(--lwd-transition), transform var(--lwd-transition), box-shadow var(--lwd-transition);
    min-height: 52px; /* Mobile thumb-friendly */
    -webkit-tap-highlight-color: transparent;
    position: relative;
    overflow: hidden;
}

.lwd-whatsapp-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255,255,255,0.1);
    opacity: 0;
    transition: opacity var(--lwd-transition);
}

.lwd-whatsapp-btn:hover {
    background: #1da851;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

.lwd-whatsapp-btn:hover::before {
    opacity: 1;
}

.lwd-whatsapp-btn:active {
    transform: translateY(0);
}

.lwd-whatsapp-btn.lwd-btn-loading {
    opacity: 0.75;
    cursor: wait;
}

/* =============================================
   Single Deal Page
   ============================================= */
.lwd-single-deal {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 20px;
    font-family: var(--lwd-font-body);
}

.lwd-single-deal-header {
    margin-bottom: 28px;
}

.lwd-single-deal-category {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--lwd-gold);
    margin-bottom: 8px;
}

.lwd-single-deal-title {
    font-family: var(--lwd-font-heading);
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--lwd-charcoal);
    margin: 0 0 16px;
    line-height: 1.2;
}

.lwd-single-image-wrap {
    position: relative;
    border-radius: var(--lwd-radius);
    overflow: hidden;
    margin-bottom: 24px;
    max-height: 520px;
}

.lwd-single-image-wrap img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.lwd-single-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
    margin-bottom: 28px;
}

.lwd-single-gallery img {
    border-radius: 8px;
    width: 100%;
    height: 120px;
    object-fit: cover;
    cursor: pointer;
    transition: transform var(--lwd-transition);
}

.lwd-single-gallery img:hover {
    transform: scale(1.03);
}

.lwd-single-pricing-box {
    background: var(--lwd-ivory);
    border: 1px solid var(--lwd-border);
    border-radius: var(--lwd-radius);
    padding: 24px;
    margin-bottom: 24px;
}

.lwd-single-pricing-box .lwd-pricing {
    margin-bottom: 12px;
}

.lwd-single-pricing-box .lwd-sale-price {
    font-size: 2rem;
}

.lwd-single-video {
    margin-bottom: 28px;
}

.lwd-single-video iframe,
.lwd-single-video video {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: var(--lwd-radius);
    border: none;
}

.lwd-single-content {
    font-size: 16px;
    line-height: 1.75;
    color: var(--lwd-charcoal-soft);
    margin-bottom: 32px;
}

.lwd-single-whatsapp-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 18px 28px;
    background: #25D366;
    color: var(--lwd-white);
    border: none;
    border-radius: 10px;
    font-family: var(--lwd-font-body);
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    cursor: pointer;
    width: 100%;
    max-width: 400px;
    margin: 0 auto 32px;
    min-height: 60px;
    transition: all var(--lwd-transition);
}

.lwd-single-whatsapp-btn:hover {
    background: #1da851;
    box-shadow: 0 8px 24px rgba(37, 211, 102, 0.4);
    transform: translateY(-2px);
}

/* =============================================
   Decorative Gold Divider
   ============================================= */
.lwd-gold-divider {
    border: none;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--lwd-gold), transparent);
    margin: 40px 0;
    opacity: 0.5;
}

/* =============================================
   Responsive / Mobile-First
   ============================================= */
@media (max-width: 768px) {
    .lwd-layout-grid .lwd-deals-grid {
        grid-template-columns: 1fr;
    }

    .lwd-layout-list .lwd-deal-card {
        grid-template-columns: 1fr;
    }

    .lwd-layout-list .lwd-card-image-wrap {
        height: 200px;
        border-radius: var(--lwd-radius) var(--lwd-radius) 0 0;
    }

    .lwd-layout-list .lwd-card-body {
        border-radius: 0 0 var(--lwd-radius) var(--lwd-radius);
    }

    .lwd-single-deal-title {
        font-size: 1.8rem;
    }

    .lwd-whatsapp-btn {
        font-size: 15px;
        min-height: 56px;
    }
}

@media (max-width: 480px) {
    .lwd-deals-controls {
        justify-content: center;
    }

    .lwd-card-body {
        padding: 16px;
    }

    .lwd-sale-price {
        font-size: 1.3rem;
    }
}

/* =============================================
   Loading State Animation
   ============================================= */
@keyframes lwd-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.lwd-btn-loading {
    animation: lwd-pulse 1.4s ease-in-out infinite;
}
