/**
 * Featured Products Styles
 *
 * Two-column hero cards with background media and text overlay.
 * Reference: 1512px width, 676×520 cards, 42px gap.
 *
 * @package Mesa
 * @since 1.5.0
 */

/* ============================================
   Section
   ============================================ */
.mesa-featured-products {
    width: 100%;
    background-color: #FFFFFF;
    padding-block: 0 clamp(2.5rem, 3.97vw, 3.75rem);
    direction: rtl;
    box-sizing: border-box;
}

/* ============================================
   Heading
   ============================================ */
.mesa-featured-products__heading {
    font-family: 'Open Sans', sans-serif !important;
    font-weight: 700 !important;
    font-style: italic !important;
    font-size: clamp(1.75rem, 3.44vw, 3.25rem);
    line-height: 100%;
    letter-spacing: 0;
    text-align: right;
    color: #000000;
    margin: 0;
}

/* ============================================
   Grid (2 columns)
   ============================================ */
.mesa-featured-products__grid {
    display: flex;
    gap: clamp(1rem, 2.78vw, 2.625rem);
    margin-top: clamp(1.5rem, 2.65vw, 2.5rem);
}

/* ============================================
   Card
   ============================================ */
.mesa-featured-products__card {
    flex: 1 1 0;
    aspect-ratio: 676 / 520;
    position: relative;
    overflow: hidden;
    border-radius: 0;
}

/* ============================================
   Media (Image / Video)
   ============================================ */
.mesa-featured-products__media {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ============================================
   Content Overlay
   ============================================ */
.mesa-featured-products__overlay {
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    padding: clamp(1rem, 2.65vw, 2.5rem);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    text-align: right;
    /* Gradient scrim for text readability */
    background: linear-gradient(to top, rgba(0, 0, 0, 0.65) 0%, rgba(0, 0, 0, 0.3) 60%, transparent 100%);
}

/* Brand */
.mesa-featured-products__brand {
    font-family: 'Open Sans', sans-serif;
    font-weight: 400;
    font-size: clamp(0.875rem, 1.32vw, 1.25rem);
    line-height: 140%;
    letter-spacing: 0;
    color: #FFFFFF;
}

/* Product Title */
.mesa-featured-products__title {
    font-family: 'Open Sans', sans-serif;
    font-weight: 600;
    font-size: clamp(1.25rem, 2.38vw, 2.25rem);
    line-height: 130%;
    letter-spacing: 0;
    color: #FFFFFF;
    margin: 0.25rem 0 0;
}

/* ============================================
   Price Row
   ============================================ */
.mesa-featured-products__price-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 0.5rem;
}

/* Price */
.mesa-featured-products__price {
    font-family: 'Open Sans', sans-serif;
    font-weight: 600;
    font-size: clamp(1.25rem, 2.38vw, 2.25rem);
    line-height: 140%;
    letter-spacing: 0;
    color: #CEFE65;
}

/* ============================================
   CTA Button (parallelogram — same as hero slider)
   ============================================ */
.mesa-featured-products__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: clamp(8.75rem, 11.9vw, 11.25rem);
    height: clamp(2.25rem, 2.91vw, 2.75rem);
    background-color: #CEFE65;
    color: #08050C;
    font-family: 'Open Sans', sans-serif;
    font-weight: 600;
    font-style: italic;
    font-size: clamp(0.875rem, 1.19vw, 1.125rem);
    line-height: 1;
    text-decoration: none;
    border: none;
    border-radius: 0;
    clip-path: polygon(15px 0, 100% 0, calc(100% - 15px) 100%, 0 100%);
    padding: 0 calc(15px + 20px);
    cursor: pointer;
    transition: opacity 0.2s ease;
    flex-shrink: 0;
}

.mesa-featured-products__btn:hover {
    opacity: 0.9;
}

/* ============================================
   Responsive: Mobile (<=768px)
   ============================================ */
@media screen and (max-width: 768px) {
    .mesa-featured-products__grid {
        flex-direction: column;
    }

    .mesa-featured-products__card {
        flex: none;
        width: 100%;
        aspect-ratio: 676 / 520;
    }

    .mesa-featured-products__btn {
        clip-path: polygon(12px 0, 100% 0, calc(100% - 12px) 100%, 0 100%);
        padding: 0 calc(12px + 16px);
    }
}

/* ============================================
   Reduced Motion
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    .mesa-featured-products__btn {
        transition: none;
    }
}
