/* ==========================================================================
   Current Promotions
   Templates: page-templates/current-promotions.php  (promotions page)
              page-templates/promotion-product.php   (product page design)
   Uses the brand variables defined in css/st-custom.css (:root).
   ========================================================================== */


/* ==================== START: Page variables ==================== */
/* Both templates wrap their content in .cp-page */
.cp-page {
    --cp-navy: #11162B;
    --cp-navy-deep: #0B1022;
    --cp-blue: var(--st-blue-dark, #004AB3);
    --cp-cyan: var(--st-blue-light, #1AC6FF);
    --cp-text: var(--st-text-black, #212529);
    --cp-muted: var(--st-form-text, #4B5563);
    --cp-border: #E5EAF0;
    --cp-soft-bg: #F4F8FC;
    --cp-tint-bg: #EEF6FF;
    --cp-radius: 20px;
    --cp-pill: 30px;
}

.cp-page {
    font-family: 'Hind Madurai', sans-serif;
    color: var(--cp-text);
    background: #fff;
}

.cp-page *,
.cp-page *::before,
.cp-page *::after {
    box-sizing: border-box;
}
/* ==================== END: Page variables ==================== */


/* ==================== START: Shared – buttons ==================== */
.cp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 12px 26px;
    border-radius: var(--cp-pill);
    border: 1.5px solid transparent;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
}

.cp-btn:hover,
.cp-btn:focus {
    text-decoration: none;
}

.cp-btn:focus-visible,
.cp-chip:focus-visible,
.cp-clear-filters:focus-visible,
.cp-sort-select:focus-visible,
.cp-flyer-thumb:focus-visible {
    outline: 3px solid var(--cp-cyan);
    outline-offset: 2px;
}

/* Filled blue */
.cp-btn-primary {
    background: var(--cp-blue);
    border-color: var(--cp-blue);
    color: #fff;
}

.cp-btn-primary:hover {
    background: var(--cp-navy);
    border-color: var(--cp-navy);
    color: #fff;
}

/* Blue outline */
.cp-btn-outline {
    background: #fff;
    border-color: var(--cp-blue);
    color: var(--cp-blue);
}

.cp-btn-outline:hover {
    background: var(--cp-blue);
    color: #fff;
}

/* Light-blue filled (on dark hero) */
.cp-btn-light {
    background: var(--cp-cyan);
    border-color: var(--cp-cyan);
    color: var(--cp-navy);
}

.cp-btn-light:hover {
    background: #fff;
    border-color: #fff;
    color: var(--cp-navy);
}

/* Transparent with border (on dark hero) */
.cp-btn-ghost {
    background: transparent;
    border-color: #5A6782;
    color: #fff;
    font-weight: 600;
}

.cp-btn-ghost:hover {
    border-color: #fff;
    color: #fff;
}
/* ==================== END: Shared – buttons ==================== */


/* ==================== START: Shared – section title ==================== */
.cp-section-title {
    margin: 0;
    font-family: 'Heebo', sans-serif;
    font-size: 34px;
    line-height: 1.2;
    font-weight: 700;
    color: var(--cp-navy);
}
/* ==================== END: Shared – section title ==================== */


/* ==================== START: Hero ==================== */
.cp-hero {
    position: relative;
    overflow: hidden;
    color: #fff;
    background-color: var(--cp-navy-deep);
    background-image:
        radial-gradient(ellipse 70% 90% at 88% 30%, rgba(0, 74, 179, 0.55) 0%, rgba(0, 74, 179, 0) 60%),
        radial-gradient(ellipse 45% 60% at 70% 110%, rgba(26, 198, 255, 0.22) 0%, rgba(26, 198, 255, 0) 65%),
        radial-gradient(ellipse 60% 80% at 0% 0%, rgba(40, 52, 96, 0.9) 0%, rgba(11, 16, 34, 0) 70%),
        linear-gradient(180deg, var(--cp-navy) 0%, var(--cp-navy-deep) 100%);
    border-bottom: 1px solid rgba(26, 198, 255, 0.25);
}

/* Dotted texture */
.cp-hero-dots {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.09) 1px, transparent 1px);
    background-size: 22px 22px;
    pointer-events: none;
}

/* Decorative rings on the right */
.cp-hero-rings {
    position: absolute;
    right: -120px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
}

.cp-hero .st-container {
    position: relative;
}

.cp-hero-content {
    max-width: 760px;
    padding: 72px 0 80px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.cp-breadcrumb {
    font-size: 14px;
    color: #B9C5D8;
}

.cp-breadcrumb a {
    color: #B9C5D8;
    text-decoration: underline;
}

.cp-breadcrumb a:hover {
    color: #fff;
}

.cp-breadcrumb span[aria-hidden] {
    margin: 0 4px;
}

.cp-eyebrow {
    align-self: flex-start;
    padding: 6px 14px;
    border: 1px solid var(--cp-cyan);
    border-radius: var(--cp-pill);
    color: var(--cp-cyan);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.cp-hero-title {
    margin: 0;
    font-family: 'Heebo', sans-serif;
    font-size: clamp(36px, 6vw, 56px);
    line-height: 1.08;
    font-weight: 800;
    letter-spacing: -0.01em;
    color: #fff;
}

.cp-hero-text {
    margin: 0;
    max-width: 560px;
    font-size: 19px;
    line-height: 1.5;
    color: #D5DEEA;
}

.cp-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 8px;
}
/* ==================== END: Hero ==================== */


/* ==================== START: Offers – header & sort ==================== */
.cp-offers {
    padding: 56px 0 32px;
}

.cp-offers-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 28px;
}

.cp-count {
    margin: 4px 0 0;
    color: var(--cp-muted);
}

.cp-sort {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cp-sort label {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--cp-muted);
}

.cp-sort-select {
    height: 44px;
    padding: 0 14px;
    border: 1px solid var(--st-form-border, #DCDCDC);
    border-radius: 10px;
    background: var(--st-field-bg, #F9F9F9);
    font-family: inherit;
    font-size: 15px;
    color: var(--cp-text);
    cursor: pointer;
}
/* ==================== END: Offers – header & sort ==================== */


/* ==================== START: Offers – filter chips ==================== */
.cp-filters {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 20px 24px;
    margin-bottom: 28px;
    background: var(--cp-soft-bg);
    border: 1px solid var(--cp-border);
    border-radius: var(--cp-radius);
}

.cp-filter-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cp-filter-label {
    flex: 0 0 84px;
    font-size: 14px;
    font-weight: 700;
    color: var(--cp-navy);
}

.cp-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.cp-chip {
    min-height: 40px;
    padding: 8px 16px;
    border: 1px solid #CBD5E1;
    border-radius: var(--cp-pill);
    background: #fff;
    color: var(--cp-text);
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.cp-chip:hover {
    border-color: var(--cp-blue);
    color: var(--cp-blue);
}

.cp-chip.is-active {
    background: var(--cp-blue);
    border-color: var(--cp-blue);
    color: #fff;
}
/* ==================== END: Offers – filter chips ==================== */


/* ==================== START: Offers – product grid & cards ==================== */
.cp-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
}

.cp-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--cp-border);
    border-radius: var(--cp-radius);
    box-shadow: var(--st-box-shadow, 0 0 4px rgba(0, 0, 0, 0.15));
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.cp-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(17, 22, 43, 0.12);
}

/* Hidden by the filters (set from JS) */
.cp-card.is-hidden {
    display: none;
}

.cp-card-media {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 230px;
    padding: 24px;
    background: var(--cp-soft-bg);
}

.cp-card-media img {
    max-width: 100%;
    max-height: 182px;
    object-fit: contain;
}

.cp-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    padding: 6px 12px;
    border-radius: var(--cp-pill);
    background: var(--cp-blue);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
}

.cp-card-body {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    gap: 8px;
    padding: 18px 20px 20px;
}

.cp-card-meta {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--cp-muted);
}

.cp-card-title {
    margin: 0;
    font-family: 'Heebo', sans-serif;
    font-size: 19px;
    line-height: 1.3;
    font-weight: 600;
    color: var(--cp-navy);
}

.cp-card-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.cp-scope {
    padding: 3px 10px;
    border-radius: 6px;
    background: #EEF4FB;
    color: var(--cp-blue);
    font-size: 13px;
    font-weight: 600;
}

.cp-ends {
    font-size: 13px;
    color: var(--cp-muted);
}

.cp-card-btn {
    margin-top: auto;
    width: 100%;
    min-height: 44px;
    padding: 10px 16px;
}
/* ==================== END: Offers – product grid & cards ==================== */


/* ==================== START: Offers – empty state ==================== */
.cp-empty {
    padding: 48px 24px;
    text-align: center;
    border: 1px dashed #CBD5E1;
    border-radius: var(--cp-radius);
    color: var(--cp-muted);
}

.cp-empty[hidden] {
    display: none;
}

.cp-empty p {
    margin: 0 0 8px;
}

.cp-clear-filters {
    border: none;
    background: none;
    padding: 4px;
    color: var(--cp-blue);
    font-family: inherit;
    font-size: 16px;
    font-weight: 700;
    text-decoration: underline;
    cursor: pointer;
}
/* ==================== END: Offers – empty state ==================== */


/* ==================== START: Promotion flyer ==================== */
/* Sits directly under the hero; the products section below adds its own top spacing */
.cp-flyer {
    padding: 56px 0 0;
}

.cp-flyer-box {
    display: flex;
    align-items: center;
    gap: 36px;
    padding: 32px;
    background: var(--cp-soft-bg);
    border: 1px solid var(--cp-border);
    border-radius: var(--cp-radius);
}

.cp-flyer-thumb {
    flex: 0 0 210px;
    display: flex;
    flex-direction: column;
    height: 272px;
    overflow: hidden;
    background: #fff;
    border: 1px solid #DCE3EC;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(17, 22, 43, 0.12);
    text-decoration: none;
    transition: transform 0.3s ease;
}

.cp-flyer-thumb:hover {
    transform: translateY(-4px);
    text-decoration: none;
}

/* Use .cp-flyer-thumb img when the real flyer image is added */
.cp-flyer-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cp-flyer-thumb-head {
    padding: 18px 16px;
    background: var(--cp-navy);
    color: #fff;
    font-family: 'Heebo', sans-serif;
    font-size: 17px;
    line-height: 1.15;
    font-weight: 800;
}

.cp-flyer-thumb-body {
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    text-align: center;
    color: var(--cp-muted);
    font-size: 13px;
    line-height: 1.4;
}

.cp-flyer-content {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cp-flyer-content .cp-section-title {
    font-size: 30px;
}

.cp-flyer-content p {
    margin: 0;
    max-width: 560px;
    font-size: 17px;
    color: var(--cp-muted);
}

.cp-tag {
    align-self: flex-start;
    padding: 4px 12px;
    border-radius: var(--cp-pill);
    background: #E8F3FF;
    color: var(--cp-blue);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.cp-flyer-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 6px;
}

.cp-file-info {
    font-size: 14px;
    color: var(--cp-muted);
}
/* ==================== END: Promotion flyer ==================== */


/* ==================== START: Help band ==================== */
.cp-help {
    padding: 32px 0 72px;
}

.cp-help-box {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 40px;
    background: var(--cp-tint-bg);
    border-radius: var(--cp-radius);
}

.cp-help-text {
    flex: 1 1 420px;
}

.cp-help-text .cp-section-title {
    font-size: 28px;
}

.cp-help-text p {
    margin: 6px 0 0;
    font-size: 17px;
    color: var(--cp-muted);
}

.cp-help-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}
/* ==================== END: Help band ==================== */


/* ==========================================================================
   Product page with promotion (Phase 2 design)
   Template: page-templates/promotion-product.php
   ========================================================================== */


/* ==================== START: Product page – layout ==================== */
.cp-pd {
    padding: 32px 0 72px;
}

.cp-pd-breadcrumb {
    margin-bottom: 24px;
    font-size: 14px;
    color: var(--cp-muted);
}

.cp-pd-breadcrumb a {
    color: var(--cp-blue);
}

.cp-pd-breadcrumb span[aria-hidden] {
    margin: 0 4px;
}

.cp-pd-main {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 48px;
    align-items: start;
}
/* ==================== END: Product page – layout ==================== */


/* ==================== START: Product page – gallery ==================== */
.cp-pd-gallery {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 520px;
    padding: 40px;
    background: var(--cp-soft-bg);
    border: 1px solid var(--cp-border);
    border-radius: var(--cp-radius);
}

.cp-pd-gallery img {
    width: 100%;
    max-height: 440px;
    object-fit: contain;
}
/* ==================== END: Product page – gallery ==================== */


/* ==================== START: Product page – image badge ==================== */
/* Low z-index so the badge scrolls under the sticky site header */
.cp-product-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: var(--cp-pill);
    background: var(--cp-blue);
    color: #fff;
    font-family: 'Hind Madurai', sans-serif;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    box-shadow: 0 4px 14px rgba(0, 74, 179, 0.28);
    pointer-events: none;
}
/* ==================== END: Product page – image badge ==================== */


/* ==================== START: Product page – promotion box ==================== */
.cp-product-promo {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin: 16px 0 20px;
    padding: 20px 22px;
    background: var(--cp-tint-bg);
    border: 1px solid #B7D7FF;
    border-radius: 16px;
    font-family: 'Hind Madurai', sans-serif;
}

.cp-product-promo-icon {
    flex: 0 0 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--cp-blue);
    color: #fff;
}

.cp-product-promo-body {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cp-product-promo-campaign {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--cp-blue);
}

.cp-product-promo-offer {
    font-family: 'Heebo', sans-serif;
    font-size: 26px;
    line-height: 1.2;
    font-weight: 800;
    color: var(--cp-navy);
}

.cp-product-promo-scope {
    font-size: 15px;
    line-height: 1.5;
    color: #374151;
}

/* Selected option status – set by JS for SKU-level promotions */
.cp-product-promo-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    align-self: flex-start;
    margin-top: 4px;
    padding: 4px 12px;
    border-radius: var(--cp-pill);
    font-size: 14px;
    font-weight: 700;
    line-height: 1.3;
}

.cp-product-promo-status[hidden] {
    display: none;
}

.cp-product-promo-status.is-included {
    background: var(--cp-blue);
    color: #fff;
}

.cp-product-promo-status.is-excluded {
    background: #fff;
    border: 1px solid #CBD5E1;
    color: var(--cp-muted);
}

.cp-product-promo-link {
    margin-top: 4px;
    font-size: 15px;
    font-weight: 700;
    color: var(--cp-blue);
    text-decoration: none;
}

.cp-product-promo-link:hover {
    color: var(--cp-navy);
    text-decoration: underline;
}

.cp-product-promo-link:focus-visible {
    outline: 3px solid var(--cp-cyan);
    outline-offset: 2px;
}
/* ==================== END: Product page – promotion box ==================== */


/* ==================== START: Product page – info column ==================== */
.cp-pd-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.cp-pd-title {
    margin: 0;
    font-family: 'Heebo', sans-serif;
    font-size: 40px;
    line-height: 1.15;
    font-weight: 700;
    color: var(--cp-navy);
}

.cp-pd-sku,
.cp-pd-desc {
    margin: 0;
    font-size: 15px;
}

.cp-pd-desc {
    color: var(--cp-muted);
}

.cp-pd-info .cp-product-promo {
    margin: 0;
}

.cp-pd-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 4px;
}
/* ==================== END: Product page – info column ==================== */


/* ==================== START: Product page – size options ==================== */
.cp-pd-options-wrap {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cp-pd-options-label {
    font-weight: 700;
    color: var(--cp-navy);
}

.cp-pd-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.cp-pd-option {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-width: 56px;
    min-height: 44px;
    padding: 8px 16px;
    justify-content: center;
    border: 1px solid #CBD5E1;
    border-radius: 10px;
    background: #fff;
    color: var(--cp-text);
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.cp-pd-option:hover {
    border-color: var(--cp-blue);
    color: var(--cp-blue);
}

/* Selected size – same gradient as the theme's attribute buttons */
.cp-pd-option.is-active {
    background: var(--st-btn-gradient, var(--cp-blue));
    border-color: transparent;
    color: #fff;
}

.cp-pd-option:focus-visible {
    outline: 3px solid var(--cp-cyan);
    outline-offset: 2px;
}

.cp-pd-option-tag {
    padding: 1px 6px;
    border-radius: var(--cp-pill);
    background: var(--cp-blue);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.04em;
    line-height: 1.4;
    text-transform: uppercase;
}

.cp-pd-option.is-active .cp-pd-option-tag {
    background: #fff;
    color: var(--cp-blue);
}
/* ==================== END: Product page – size options ==================== */


/* ==================== START: Product page – section heads (table, more promotions) ==================== */
.cp-pd-table-section,
.cp-pd-more {
    margin-top: 56px;
}

.cp-pd-section-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 16px;
}

.cp-pd-section-head .cp-section-title {
    font-size: 26px;
}

.cp-pd-section-note {
    font-size: 14px;
    color: var(--cp-muted);
}

.cp-pd-view-all {
    font-weight: 700;
    color: var(--cp-blue);
    text-decoration: none;
}

.cp-pd-view-all:hover {
    color: var(--cp-navy);
    text-decoration: underline;
}
/* ==================== END: Product page – section heads ==================== */


/* ==================== START: Product page – options table ==================== */
.cp-pd-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--cp-border);
    border-radius: 16px;
    -webkit-overflow-scrolling: touch;
}

.cp-pd-table {
    width: 100%;
    min-width: 480px;
    margin: 0;
    border-collapse: collapse;
    font-size: 15px;
}

.cp-pd-table th {
    padding: 14px 20px;
    background: var(--cp-soft-bg);
    color: var(--cp-navy);
    font-weight: 700;
    text-align: left;
}

.cp-pd-table td {
    padding: 14px 20px;
    border-top: 1px solid var(--cp-border);
    color: #374151;
    vertical-align: middle;
}

.cp-pd-table tbody tr {
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.cp-pd-table tbody tr:hover {
    background: #F8FBFF;
}

/* Row of the selected size */
.cp-pd-table tbody tr.is-active {
    background: var(--cp-tint-bg);
}

.cp-pd-table-sku {
    font-weight: 600;
    color: var(--cp-navy);
}

/* Static badge inside the table (reuses .cp-badge colours) */
.cp-pd-table .cp-pd-included {
    position: static;
    display: inline-block;
}

.cp-pd-not-included {
    font-size: 14px;
    color: var(--cp-muted);
}
/* ==================== END: Product page – options table ==================== */


/* ==================== START: Responsive – max 1280px ==================== */
@media (max-width: 1280px) {
    .cp-grid {
        gap: 20px;
    }
}
/* ==================== END: Responsive – max 1280px ==================== */


/* ==================== START: Responsive – max 1024px (tablet) ==================== */
@media (max-width: 1024px) {
    .cp-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .cp-hero-content {
        padding: 56px 0 64px;
    }

    .cp-hero-rings {
        right: -220px;
        opacity: 0.6;
    }

    .cp-section-title {
        font-size: 30px;
    }

    /* Product page */
    .cp-pd-main {
        gap: 32px;
    }

    .cp-pd-gallery {
        min-height: 420px;
        padding: 32px;
    }

    .cp-pd-title {
        font-size: 34px;
    }
}
/* ==================== END: Responsive – max 1024px ==================== */


/* ==================== START: Responsive – max 768px (small tablet / large phone) ==================== */
@media (max-width: 768px) {
    .cp-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    .cp-hero-content {
        padding: 44px 0 52px;
        gap: 14px;
    }

    .cp-hero-text {
        font-size: 17px;
    }

    .cp-hero-rings {
        display: none;
    }

    .cp-offers {
        padding: 40px 0 24px;
    }

    .cp-section-title {
        font-size: 26px;
    }

    /* Filter label above its chips; chips scroll sideways instead of wrapping */
    .cp-filters {
        padding: 16px;
    }

    .cp-filter-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .cp-filter-label {
        flex-basis: auto;
    }

    .cp-chips {
        width: 100%;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 4px;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: thin !important;
    }

    .cp-chip {
        flex: 0 0 auto;
        white-space: nowrap;
    }

    .cp-card-media {
        height: 190px;
        padding: 18px;
    }

    .cp-card-media img {
        max-height: 150px;
    }

    .cp-card-body {
        padding: 14px 16px 16px;
    }

    .cp-card-title {
        font-size: 17px;
    }

    .cp-flyer {
        padding: 40px 0 0;
    }

    .cp-flyer-box {
        flex-direction: column;
        align-items: flex-start;
        gap: 24px;
        padding: 24px;
    }

    .cp-flyer-thumb {
        flex-basis: auto;
        width: 180px;
        height: 233px;
    }

    .cp-flyer-content .cp-section-title {
        font-size: 24px;
    }

    .cp-help {
        padding: 24px 0 48px;
    }

    .cp-help-box {
        padding: 28px 24px;
    }

    .cp-help-text {
        flex-basis: 100%;
    }

    .cp-help-text .cp-section-title {
        font-size: 24px;
    }

    /* Product page – gallery above info */
    .cp-pd {
        padding: 24px 0 48px;
    }

    .cp-pd-main {
        grid-template-columns: minmax(0, 1fr);
        gap: 24px;
    }

    .cp-pd-gallery {
        min-height: 320px;
        padding: 24px;
    }

    .cp-pd-gallery img {
        max-height: 300px;
    }

    .cp-pd-title {
        font-size: 30px;
    }

    .cp-pd-table-section,
    .cp-pd-more {
        margin-top: 40px;
    }

    .cp-pd-section-head .cp-section-title {
        font-size: 22px;
    }
}
/* ==================== END: Responsive – max 768px ==================== */


/* ==================== START: Responsive – max 480px (phone) ==================== */
@media (max-width: 480px) {
    .cp-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .cp-hero-actions .cp-btn,
    .cp-flyer-actions .cp-btn,
    .cp-help-actions .cp-btn {
        width: 100%;
    }

    .cp-offers-head {
        align-items: flex-start;
    }

    .cp-sort {
        width: 100%;
    }

    .cp-sort-select {
        flex: 1 1 auto;
    }

    .cp-card-media {
        height: 220px;
    }

    .cp-card-media img {
        max-height: 176px;
    }

    .cp-flyer-thumb {
        align-self: center;
    }

    /* Product page */
    .cp-pd-actions .cp-btn {
        width: 100%;
    }

    .cp-pd-table th,
    .cp-pd-table td {
        padding: 12px 14px;
    }

    .cp-product-promo {
        gap: 12px;
        padding: 16px;
    }

    .cp-product-promo-icon {
        flex-basis: 36px;
        width: 36px;
        height: 36px;
    }

    .cp-product-promo-icon svg {
        width: 16px;
        height: 16px;
    }

    .cp-product-promo-offer {
        font-size: 22px;
    }

    .cp-product-badge {
        top: 10px;
        left: 10px;
        padding: 6px 12px;
        font-size: 13px;
    }
}
/* ==================== END: Responsive – max 480px ==================== */


/* ==================== START: Reduced motion ==================== */
@media (prefers-reduced-motion: reduce) {
    .cp-btn,
    .cp-chip,
    .cp-card,
    .cp-flyer-thumb,
    .cp-pd-option,
    .cp-pd-table tbody tr {
        transition: none;
    }

    .cp-card:hover,
    .cp-flyer-thumb:hover {
        transform: none;
    }
}
/* ==================== END: Reduced motion ==================== */
