/* assets/css/offers.css — Special Offers / Clearance page */

.offers-page {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px 60px;
    font-family: 'Poppins', sans-serif;
    color: #1e293b;
}

/* Hero */
.offers-hero {
    background: linear-gradient(120deg, #1e3c72 0%, #2a5298 55%, #e94e92 130%);
    border-radius: 20px;
    color: #fff;
    text-align: center;
    padding: 48px 24px;
    margin: 24px 0 32px;
    box-shadow: 0 12px 30px rgba(30, 60, 114, 0.22);
}

.offers-hero__eyebrow {
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.8rem;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.18);
    padding: 5px 16px;
    border-radius: 20px;
    margin-bottom: 14px;
}

.offers-hero__title {
    font-family: 'Space Grotesk', 'Poppins', sans-serif;
    font-size: 2.4rem;
    font-weight: 700;
    margin: 0 0 8px;
}

.offers-hero__subtitle {
    font-size: 1.1rem;
    opacity: 0.95;
    margin: 0 0 22px;
}

.offers-hero__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #25d366;
    color: #fff;
    padding: 12px 26px;
    border-radius: 30px;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.offers-hero__cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.28);
    color: #fff;
}

/* Category filter */
.offers-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-bottom: 32px;
}

.offers-filter__btn {
    border: 1.5px solid #d7deea;
    background: #fff;
    color: #2a5298;
    padding: 8px 18px;
    border-radius: 24px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.offers-filter__btn:hover {
    border-color: #2a5298;
    background: #f4f7fa;
}

.offers-filter__btn.active {
    background: linear-gradient(135deg, #2a5298, #1e3c72);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 10px rgba(42, 82, 152, 0.3);
}

/* Grid — flexbox so every row (incl. a partial last row) is centered,
   never left-aligned */
.offers-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
    gap: 24px;
}

/* Card */
.offer-card {
    /* fixed-ish width so flexbox can wrap and center the cards */
    flex: 0 1 250px;
    max-width: 260px;
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    border: 1px solid #eef1f6;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.offer-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 26px rgba(30, 60, 114, 0.14);
}

.offer-card__image {
    position: relative;
    height: 200px;
    background: #f4f7fa;
    display: flex;
    align-items: center;
    justify-content: center;
}

.offer-card__image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 12px;
}

.offer-card__noimg {
    color: #c2ccda;
    font-size: 3rem;
}

.offer-card__badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: #e94e92;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1px;
    padding: 4px 12px;
    border-radius: 20px;
    z-index: 2;
    box-shadow: 0 2px 6px rgba(233, 78, 146, 0.4);
}

.offer-card__body {
    padding: 16px 18px 18px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.offer-card__cat {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #2a5298;
    font-weight: 600;
    margin-bottom: 4px;
}

.offer-card__title {
    font-size: 1.02rem;
    font-weight: 600;
    margin: 0 0 6px;
    color: #1e293b;
    line-height: 1.3;
}

.offer-card__desc {
    list-style: none;
    padding: 0;
    margin: 0 0 14px;
    font-size: 0.82rem;
    color: #475569;
    line-height: 1.45;
}

.offer-card__desc li {
    position: relative;
    padding-left: 18px;
    margin-bottom: 5px;
}

.offer-card__desc li::before {
    content: "\f00c";                 /* Font Awesome check */
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    position: absolute;
    left: 0;
    top: 1px;
    font-size: 0.7rem;
    color: #25d366;
}

.offer-card__footer {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.offer-card__price {
    line-height: 1.15;
}

.offer-card__now {
    font-size: 1.15rem;
    font-weight: 700;
    color: #1e3c72;
}

/* original (pre-sale) price, struck through */
.offer-card__was {
    font-size: 0.85rem;
    font-weight: 500;
    color: #94a3b8;
    text-decoration: line-through;
    margin-left: 6px;
}

.offer-card__price small {
    display: block;
    font-size: 0.68rem;
    font-weight: 500;
    color: #94a3b8;
    margin-top: 2px;
}

.offer-card__order {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #25d366;
    color: #fff;
    padding: 8px 16px;
    border-radius: 22px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease, transform 0.2s ease;
}

.offer-card__order:hover {
    background: #1eb856;
    transform: scale(1.04);
    color: #fff;
}

/* "View details" affordance on the card */
.offer-card {
    cursor: pointer;
}

.offer-card__more {
    font-size: 0.76rem;
    font-weight: 600;
    color: #2a5298;
    margin: 2px 0 12px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.offer-card__more i {
    font-size: 0.62rem;
    transition: transform 0.2s ease;
}

.offer-card:hover .offer-card__more i {
    transform: translateX(3px);
}

/* ================= Offer details modal ================= */
.offer-modal {
    position: fixed;
    inset: 0;
    z-index: 1080;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.offer-modal.open {
    display: flex;
}

.offer-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(2px);
}

.offer-modal__dialog {
    position: relative;
    z-index: 1;
    background: #fff;
    border-radius: 18px;
    width: 100%;
    max-width: 760px;
    max-height: 90vh;
    overflow: auto;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.3);
    animation: offerModalIn 0.22s ease;
}

@keyframes offerModalIn {
    from { opacity: 0; transform: translateY(16px) scale(0.98); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.offer-modal__close {
    position: absolute;
    top: 12px;
    right: 14px;
    z-index: 2;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    color: #334155;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.offer-modal__close:hover {
    background: #fff;
    color: #e94e92;
}

.offer-modal__grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
}

.offer-modal__media {
    position: relative;
    background: #f4f7fa;
    display: grid;
    place-items: center;
    padding: 28px;
    min-height: 260px;
}

.offer-modal__media img {
    max-width: 100%;
    max-height: 320px;
    object-fit: contain;
}

.offer-modal__badge {
    position: absolute;
    top: 14px;
    left: 14px;
    background: #e94e92;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    padding: 5px 14px;
    border-radius: 20px;
}

.offer-modal__info {
    padding: 30px 28px;
}

.offer-modal__cat {
    font-size: 0.74rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #2a5298;
    font-weight: 600;
}

.offer-modal__title {
    font-family: 'Space Grotesk', 'Poppins', sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    margin: 4px 0 12px;
}

.offer-modal__price {
    margin-bottom: 4px;
}

.offer-modal__price .offer-card__now { font-size: 1.5rem; }
.offer-modal__price .offer-card__was { font-size: 1rem; }

.offer-modal__note {
    display: block;
    color: #94a3b8;
    font-size: 0.78rem;
    margin-bottom: 16px;
}

.offer-modal__desc {
    list-style: none;
    padding: 0;
    margin: 0 0 22px;
    font-size: 0.9rem;
    color: #475569;
    line-height: 1.5;
}

.offer-modal__desc li {
    position: relative;
    padding-left: 22px;
    margin-bottom: 9px;
}

.offer-modal__desc li::before {
    content: "\f00c";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    position: absolute;
    left: 0;
    top: 2px;
    color: #25d366;
    font-size: 0.8rem;
}

.offer-modal__order {
    font-size: 0.95rem;
    padding: 12px 26px;
}

@media (max-width: 640px) {
    .offer-modal__grid { grid-template-columns: 1fr; }
    .offer-modal__media { min-height: 200px; padding: 24px; }
    .offer-modal__media img { max-height: 220px; }
    .offer-modal__info { padding: 22px 20px; }
    .offer-modal__title { font-size: 1.2rem; }
}

/* Empty / no-results states */
.offers-empty {
    text-align: center;
    padding: 60px 20px;
    color: #64748b;
}

.offers-empty i {
    font-size: 3rem;
    color: #c2ccda;
    margin-bottom: 16px;
}

.offers-empty p {
    font-size: 1.1rem;
    margin-bottom: 20px;
}

.offers-noresults {
    text-align: center;
    color: #64748b;
    padding: 40px 20px;
    font-size: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
    .offers-page {
        padding: 0 12px 40px;
    }

    /* Compact hero so it doesn't fill the screen */
    .offers-hero {
        padding: 22px 16px;
        border-radius: 14px;
        margin: 14px 0 18px;
    }

    .offers-hero__eyebrow {
        font-size: 0.68rem;
        margin-bottom: 8px;
    }

    .offers-hero__title {
        font-size: 1.5rem;
    }

    .offers-hero__subtitle {
        font-size: 0.9rem;
        margin-bottom: 16px;
    }

    .offers-hero__cta {
        padding: 10px 20px;
        font-size: 0.9rem;
    }

    /* Filter: one horizontally-scrolling row instead of 4 stacked rows */
    .offers-filter {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        gap: 8px;
        margin-bottom: 20px;
        padding-bottom: 6px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .offers-filter::-webkit-scrollbar {
        display: none;
    }

    .offers-filter__btn {
        flex: 0 0 auto;
        white-space: nowrap;
        padding: 7px 14px;
        font-size: 0.82rem;
    }

    /* Two clean columns */
    .offers-grid {
        gap: 12px;
    }

    .offer-card {
        flex: 1 1 calc(50% - 6px);
        max-width: calc(50% - 6px);
    }

    .offer-card__image {
        height: 140px;
    }

    .offer-card__body {
        padding: 12px 12px 14px;
    }

    .offer-card__title {
        font-size: 0.92rem;
    }

    .offer-card__desc {
        font-size: 0.78rem;
        -webkit-line-clamp: 2;
        margin-bottom: 10px;
    }

    .offer-card__price {
        font-size: 1rem;
    }

    .offer-card__order {
        padding: 7px 12px;
        font-size: 0.78rem;
    }
}
