/* =========================================================
   DIVAYRA SMART OFFER SLIDER - FRONTEND UI v1.0.3
   Premium offer carousel + category-based benefit row
   Position: Offer Slider -> Benefit Badges -> Cart Buttons
   ========================================================= */
:root{
    --dv-offer-bg:#FCFBF7;
    --dv-offer-card:#FFFDF9;
    --dv-offer-card-2:#FAF2E9;
    --dv-offer-border:#E7D8CC;
    --dv-offer-border-strong:#D8B989;
    --dv-offer-text:#2B1A14;
    --dv-offer-muted:#6B564A;
    --dv-offer-gold:#C8A96A;
    --dv-offer-gold-dark:#A87938;
    --dv-offer-soft:#FFF8EF;
    --dv-offer-shadow:0 10px 26px rgba(43,26,20,.055);
}

.dv-offer-slider-wrap,
.dv-benefit-badges-wrap{
    position:relative;
    width:100%;
    color:var(--dv-offer-text);
    font-family:inherit;
    box-sizing:border-box;
}
.dv-offer-slider-wrap *,
.dv-benefit-badges-wrap *{box-sizing:border-box;}

/* ===============================
   Offer slider header
   =============================== */
.dv-offer-slider-wrap{
    margin:16px 0 8px;
    padding:0;
}
.dv-offer-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
    margin-bottom:10px;
}
.dv-offer-header::after{
    content:"";
    height:1px;
    background:rgba(231,216,204,.9);
    flex:1 1 auto;
    order:2;
    margin-left:10px;
}
.dv-offer-header-icon{
    color:var(--dv-offer-gold);
    display:inline-flex;
    align-items:center;
    justify-content:center;
    flex:0 0 auto;
    order:0;
}
.dv-offer-header-icon svg{width:18px;height:18px;}
.dv-offer-header h3{
    order:1;
    margin:0 !important;
    font-family:"Cormorant Garamond", Georgia, serif !important;
    color:var(--dv-offer-text) !important;
    font-size:22px !important;
    line-height:1.1 !important;
    font-weight:500 !important;
    letter-spacing:.01em;
    white-space:nowrap;
}

/* ===============================
   Offer carousel
   =============================== */
.dv-offer-slider{
    position:relative;
    background:transparent;
    border:none;
    overflow:visible;
}
.dv-offer-viewport{
    overflow:hidden;
    width:100%;
}
.dv-offer-track{
    display:flex;
    gap:12px;
    transition:transform .42s cubic-bezier(.22,.61,.36,1);
    will-change:transform;
}
.dv-offer-card{
    flex:0 0 25%;
    min-width:0;
    box-sizing:border-box;
    padding:14px 12px 13px;
    border:1px solid rgba(231,216,204,.95);
    border-radius:8px;
    background:linear-gradient(135deg,var(--dv-offer-card) 0%,var(--dv-offer-card-2) 100%);
    box-shadow:0 8px 18px rgba(43,26,20,.035);
    text-align:center;
    min-height:126px;
    display:flex;
    align-items:center;
    justify-content:center;
    transition:border-color .22s ease, transform .22s ease, box-shadow .22s ease;
}
.dv-offer-card:hover{
    border-color:rgba(200,169,106,.75);
    box-shadow:var(--dv-offer-shadow);
    transform:translateY(-1px);
}
.dv-offer-card-content{min-width:0;width:100%;}
.dv-offer-label-row{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:6px;
    margin-bottom:7px;
    flex-wrap:wrap;
    min-height:17px;
}
.dv-offer-label,
.dv-offer-badge{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    max-width:100%;
    border-radius:999px;
    font-size:8.5px;
    line-height:1;
    padding:4.5px 7px;
    text-transform:uppercase;
    letter-spacing:.045em;
    font-weight:700;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
}
.dv-offer-label{
    background:#F0DDC5;
    color:#6F4B1E;
}
.dv-offer-badge{
    border:1px solid rgba(200,169,106,.38);
    background:#FFF8EF;
    color:#8A6634;
}
.dv-offer-card h4{
    margin:0 0 7px !important;
    font-family:inherit !important;
    font-size:14px !important;
    line-height:1.18 !important;
    font-weight:700 !important;
    color:var(--dv-offer-text) !important;
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
    overflow:hidden;
}
.dv-offer-card p{
    margin:0 !important;
    font-size:11px !important;
    line-height:1.42 !important;
    color:var(--dv-offer-muted) !important;
    display:-webkit-box;
    -webkit-line-clamp:3;
    -webkit-box-orient:vertical;
    overflow:hidden;
}
.dv-offer-card p::after{
    content:"";
    display:block;
    width:22px;
    height:3px;
    margin:8px auto 0;
    border-radius:99px;
    background:linear-gradient(90deg,var(--dv-offer-gold) 0%,#E8D3AF 100%);
}
.dv-offer-extra-row{
    display:flex;
    flex-wrap:wrap;
    justify-content:center;
    gap:6px;
    margin-top:8px;
}
.dv-offer-coupon,
.dv-offer-cta{
    display:inline-flex;
    align-items:center;
    border-radius:999px;
    font-size:10px;
    line-height:1;
    padding:5px 7px;
    border:1px solid rgba(200,169,106,.35);
}
.dv-offer-coupon{background:#fff;color:#7C572A;font-weight:700;}
.dv-offer-cta{background:#2B1A14;color:#FFF8EF;border-color:#2B1A14;}

/* Slider arrows / dots */
.dv-offer-nav{
    position:absolute;
    top:50%;
    transform:translateY(-50%);
    z-index:3;
    width:30px;
    height:30px;
    padding:0 !important;
    border-radius:50% !important;
    border:1px solid rgba(200,169,106,.45) !important;
    background:#FFFDF9 !important;
    color:#2B1A14 !important;
    box-shadow:0 6px 18px rgba(43,26,20,.08) !important;
    display:flex !important;
    align-items:center;
    justify-content:center;
    cursor:pointer;
}
.dv-offer-nav svg{width:18px;height:18px;}
.dv-offer-nav:hover{
    background:#2B1A14 !important;
    color:#FFF8EF !important;
    border-color:#C8A96A !important;
}
.dv-offer-prev{left:-14px;}
.dv-offer-next{right:-14px;}
.dv-offer-dots{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:7px;
    margin-top:10px;
}
.dv-offer-dot{
    width:6px !important;
    height:6px !important;
    min-height:0 !important;
    padding:0 !important;
    border-radius:50% !important;
    border:none !important;
    background:#D9C6B8 !important;
    cursor:pointer;
    box-shadow:none !important;
}
.dv-offer-dot.is-active{
    width:18px !important;
    border-radius:999px !important;
    background:#2B1A14 !important;
}

/* ===============================
   Flexible benefit badges row
   New visual: thin separated row below offer section,
   directly above quantity/cart buttons.
   =============================== */
.dv-benefit-badges-wrap{
    margin:10px 0 14px;
    padding:11px 0;
    border-top:1px solid rgba(231,216,204,.95);
    border-bottom:1px solid rgba(231,216,204,.95);
    background:transparent;
}
.dv-benefit-title{
    font-family:"Cormorant Garamond", Georgia, serif;
    font-size:18px;
    line-height:1.1;
    margin:0 0 8px;
    color:var(--dv-offer-text);
}
.dv-benefit-grid{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:10px 14px;
    align-items:center;
}
.dv-benefit-item{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:8px;
    min-width:0;
    padding:0;
    border:none;
    border-radius:0;
    background:transparent;
    box-shadow:none;
    text-align:left;
}
.dv-benefit-icon{
    color:#C07C2C;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    flex:0 0 auto;
}
.dv-benefit-icon svg{width:18px;height:18px;}
.dv-benefit-copy{
    min-width:0;
    display:flex;
    flex-direction:column;
    gap:2px;
}
.dv-benefit-copy strong{
    font-size:12px;
    line-height:1.15;
    font-weight:600;
    color:var(--dv-offer-text);
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
}
.dv-benefit-copy small{
    font-size:10.5px;
    line-height:1.2;
    color:var(--dv-offer-muted);
    display:-webkit-box;
    -webkit-line-clamp:1;
    -webkit-box-orient:vertical;
    overflow:hidden;
}

@media (max-width:1280px){
    .dv-offer-track{gap:10px;}
    .dv-offer-card{min-height:124px;padding:13px 10px;}
}
@media (max-width:1024px){
    .dv-offer-track{gap:10px;}
    .dv-offer-card{padding:12px 10px;min-height:120px;}
    .dv-offer-nav{display:none !important;}
    .dv-benefit-grid{gap:8px 10px;}
}
@media (max-width:767px){
    .dv-offer-slider-wrap{margin:12px 0 6px;}
    .dv-offer-header{margin-bottom:8px;gap:6px;}
    .dv-offer-header::after{margin-left:6px;}
    .dv-offer-header-icon svg{width:16px;height:16px;}
    .dv-offer-header h3{font-size:18px !important;}
    .dv-offer-track{gap:8px;}
    .dv-offer-card{
        min-height:102px;
        padding:9px 6px 8px;
        border-radius:7px;
    }
    .dv-offer-label-row{gap:4px;margin-bottom:5px;min-height:14px;}
    .dv-offer-label,
    .dv-offer-badge{font-size:6.8px;padding:3.5px 5px;max-width:100%;}
    .dv-offer-card h4{
        font-size:10.5px !important;
        line-height:1.16 !important;
        margin-bottom:5px !important;
    }
    .dv-offer-card p{
        font-size:8.5px !important;
        line-height:1.28 !important;
        -webkit-line-clamp:3;
    }
    .dv-offer-card p::after{width:18px;height:2px;margin-top:6px;}
    .dv-offer-extra-row{display:none;}
    .dv-offer-dots{margin-top:7px;gap:6px;}
    .dv-offer-dot{width:5px !important;height:5px !important;}
    .dv-offer-dot.is-active{width:15px !important;}

    .dv-benefit-badges-wrap{
        margin:9px 0 12px;
        padding:9px 0;
    }
    .dv-benefit-grid{
        grid-template-columns:repeat(4,minmax(0,1fr));
        gap:6px 4px;
    }
    .dv-benefit-item{
        flex-direction:column;
        justify-content:flex-start;
        text-align:center;
        gap:4px;
    }
    .dv-benefit-icon svg{width:16px;height:16px;}
    .dv-benefit-copy strong{
        font-size:8.7px;
        line-height:1.1;
        white-space:normal;
        display:-webkit-box;
        -webkit-line-clamp:2;
        -webkit-box-orient:vertical;
    }
    .dv-benefit-copy small{display:none;}
}
@media (max-width:380px){
    .dv-offer-track{gap:6px;}
    .dv-offer-card{padding:8px 5px;min-height:96px;}
    .dv-offer-card h4{font-size:9.8px !important;}
    .dv-offer-card p{font-size:8px !important;}
    .dv-benefit-grid{gap:5px 3px;}
    .dv-benefit-copy strong{font-size:8.1px;}
}

/* v1.0.4: smoother infinite loop autoplay support */
.dv-offer-track [data-dv-clone="yes"]{
    pointer-events:none;
}

/* =========================================================
   v1.0.5 Dynamic Discount Badge beside WooCommerce price
   Example: 49% OFF
   ========================================================= */
.single-product div.product .summary .price{
    display:flex;
    align-items:center;
    flex-wrap:wrap;
    gap:10px;
}
.single-product .summary .price .divayra-discount-badge,
.single-product .divayra-discount-badge{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-height:25px;
    padding:6px 10px;
    border-radius:6px;
    background:#F0DDC5;
    color:#7A5A3A;
    border:1px solid rgba(200,169,106,.28);
    font-size:12px;
    font-weight:700;
    line-height:1;
    letter-spacing:.035em;
    text-transform:uppercase;
    white-space:nowrap;
    vertical-align:middle;
    box-shadow:0 4px 12px rgba(43,26,20,.045);
}
@media (max-width:767px){
    .single-product div.product .summary .price{
        gap:8px;
    }
    .single-product .summary .price .divayra-discount-badge,
    .single-product .divayra-discount-badge{
        min-height:22px;
        padding:5px 8px;
        font-size:10px;
        border-radius:5px;
    }
}


/* =========================================================
   v1.0.6 Price + discount badge inline fix
   Keeps badge beside sale price on WoodMart single product page.
   ========================================================= */
.single-product div.product .summary .price,
.single-product .summary-inner .price,
.single-product p.price,
.single-product .product-image-summary .price{
    display:flex !important;
    align-items:baseline !important;
    flex-wrap:wrap !important;
    gap:10px !important;
}
.single-product .summary .price .divayra-price-inline-wrap,
.single-product p.price .divayra-price-inline-wrap,
.single-product .product-image-summary .price .divayra-price-inline-wrap{
    display:inline-flex !important;
    align-items:baseline !important;
    flex-wrap:nowrap !important;
    gap:10px !important;
    width:auto !important;
    max-width:100% !important;
    vertical-align:baseline !important;
    white-space:nowrap !important;
}
.single-product .summary .price .divayra-price-inline-wrap del,
.single-product .summary .price .divayra-price-inline-wrap ins,
.single-product p.price .divayra-price-inline-wrap del,
.single-product p.price .divayra-price-inline-wrap ins{
    display:inline-flex !important;
    align-items:baseline !important;
    width:auto !important;
    margin:0 !important;
    padding:0 !important;
    white-space:nowrap !important;
}
.single-product .summary .price .divayra-price-inline-wrap ins,
.single-product p.price .divayra-price-inline-wrap ins{
    text-decoration:none !important;
}
.single-product .summary .price .divayra-price-inline-wrap .divayra-discount-badge,
.single-product p.price .divayra-price-inline-wrap .divayra-discount-badge{
    flex:0 0 auto !important;
    align-self:center !important;
    margin-left:0 !important;
    position:relative !important;
    top:-1px !important;
}
@media (max-width:767px){
    .single-product .summary .price .divayra-price-inline-wrap,
    .single-product p.price .divayra-price-inline-wrap{
        gap:7px !important;
        white-space:nowrap !important;
    }
}
@media (max-width:360px){
    .single-product .summary .price .divayra-price-inline-wrap,
    .single-product p.price .divayra-price-inline-wrap{
        gap:6px !important;
    }
    .single-product .summary .price .divayra-price-inline-wrap .divayra-discount-badge,
    .single-product p.price .divayra-price-inline-wrap .divayra-discount-badge{
        padding:4px 6px !important;
        font-size:9px !important;
    }
}


/* =========================================================
   v1.0.7 Discount badge scope note
   PHP now outputs .divayra-discount-badge only for the main
   single product price, not related/loop/archive product prices.
   ========================================================= */
