/* Collection-page product imagery */
.collection-series-landscape { width: 260px; height: 125px; flex: 0 0 260px; overflow: hidden; border-radius: var(--radius-medium); background: #10253a; }
.collection-series-landscape > img { display: block; width: 125px !important; height: 260px !important; max-width: none; object-fit: cover !important; object-position: center; transform: rotate(90deg); transform-origin: center; }

.model-tile .model-accurate-image,
.type-strip .model-accurate-image,
.products-list .earbud-card .model-accurate-image {
    /* The source imagery is converted to an edge-clean cutout in model-images.js. */
    opacity: 1;
    background: transparent !important;
    filter: none;
    /* White studio surfaces merge into the same soft card background without
       modifying pixels in JavaScript, so pale handset finishes remain intact. */
    mix-blend-mode: multiply;
    -webkit-mask-image: none;
    mask-image: none;
}

/* This selector intentionally outranks the collection templates, which set a
   normal blend mode for every image. It merges the original white studio
   surface into the soft section background while preserving handset colour. */
.model-tile:not(.model-tile--feature) > img.model-accurate-image,
.type-strip article > img.model-accurate-image,
.products-list .earbud-card > img.model-accurate-image {
    mix-blend-mode: multiply !important;
}

.model-tile,
.type-strip article {
    isolation: isolate;
}

.collection-faq .split-layout { align-items: stretch; }
.collection-faq .faq-image { align-self: stretch; min-height: 100% !important; aspect-ratio: auto; }
.collection-faq .faq-image > img.collection-inventory-image { display: block; width: 100%; height: 100%; min-height: 100% !important; object-fit: cover !important; object-position: center 54%; }

@media (max-width: 600px) {
    .collection-series-landscape { width: 100%; height: 180px; flex-basis: 100%; }
    .collection-series-landscape > img { width: 180px !important; height: 100% !important; transform: rotate(90deg); }
    .collection-faq .faq-image { min-height: 300px !important; height: 300px; }
    .collection-faq .faq-image > img.collection-inventory-image { min-height: 300px !important; }
}

/* Keep every uploaded series lineup fully visible in the Product Comparison
   module. This applies to collection pages and their related detail pages. */
.collection-compare .compare-title > img.series-comparison-image,
.comparison-section .image-heading > img.series-comparison-image {
    padding: 0 !important;
    object-fit: contain !important;
    object-position: center !important;
    background: #ffffff !important;
}

/* Product Comparison artwork shares a white inset surface on both collection
   and detail pages, keeping the original background while adding breathing
   room and a subtle layered edge. */
.comparison-section .series-comparison-frame,
.collection-compare .series-comparison-frame {
    width: 100%;
    padding: 16px;
    overflow: hidden;
    border-radius: var(--radius-medium);
    background: #ffffff;
    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, .88),
        inset 0 -1px 0 rgba(213, 220, 229, .72),
        0 16px 28px rgba(0, 0, 0, .22);
}

.comparison-section .image-heading .series-comparison-frame {
    height: auto;
    aspect-ratio: 1672 / 941;
    padding: 12px;
    align-self: center;
}

.collection-compare .series-comparison-frame {
    height: 250px;
}

.comparison-section .series-comparison-frame > img.series-comparison-image,
.collection-compare .series-comparison-frame > img.series-comparison-image {
    display: block;
    width: 100%;
    height: 100%;
    padding: 0 !important;
    object-fit: contain !important;
    object-position: center !important;
    background: #ffffff !important;
    border-radius: calc(var(--radius-medium) - 5px);
    transform: none;
    transform-origin: center;
}

.comparison-section > .container > .series-comparison-frame {
    width: min(100%, 540px);
    margin: 22px 0 30px;
}

@media (max-width: 760px) {
    .comparison-section .image-heading .series-comparison-frame { height: auto; min-height: 0; padding: 12px; }
    .collection-compare .series-comparison-frame { height: min(72vw, 300px); padding: 14px; }
}

/* Comparison cards sit inside a dark section. Keep the model name and the
   short specification together in a compact dark card rather than letting
   the default white related-product card styles turn them into empty pills. */
.comparison-section .earbuds-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-top: 32px;
}

.comparison-section .earbuds-grid > a {
    display: block;
    min-width: 0;
    color: inherit;
}

.comparison-section .earbuds-grid .earbud-card {
    display: block;
    min-height: 132px;
    height: 100%;
    margin: 0;
    padding: 22px;
    border: 1px solid rgba(255,255,255,.22) !important;
    border-radius: 18px !important;
    color: #ffffff !important;
    background: rgba(255,255,255,.09) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.12) !important;
}

.comparison-section .earbuds-grid .earbud-card h3 {
    display: block !important;
    margin: 0 0 8px !important;
    color: #ffffff !important;
    font-size: 1.12rem;
    line-height: 1.25;
}

.comparison-section .earbuds-grid .earbud-card p {
    display: block !important;
    margin: 0 !important;
    color: rgba(255,255,255,.76) !important;
    font-size: .95rem;
    line-height: 1.55;
}

/* Keep the three iPhone 18 model columns equally legible. The browser's
   automatic table sizing used to shrink the Duo column around short headings. */
.comparison-section .table-wrap--dark .series-comparison-table {
    width: 100%;
    min-width: 1040px;
    table-layout: fixed;
}

.comparison-section .series-comparison-table :is(th, td):nth-child(1) { width: 19%; }
.comparison-section .series-comparison-table :is(th, td):nth-child(2),
.comparison-section .series-comparison-table :is(th, td):nth-child(3),
.comparison-section .series-comparison-table :is(th, td):nth-child(4) {
    width: 27%;
    overflow-wrap: break-word;
}

/* Related-model cards on every product-detail page.
   The product artwork is treated as part of the card surface rather than a
   separate white rectangle: multiply lets its light studio backdrop inherit
   the card colour while retaining the phone's original detail. */
.product-range .range-card,
.products-list .earbud-card {
    --related-card-surface: #f5f7f9;
    overflow: hidden;
    border: 1px solid #e1e7eb;
    background: var(--related-card-surface);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .95),
        inset 0 -1px 0 rgba(211, 220, 226, .62),
        0 14px 30px rgba(35, 74, 145, .09);
}

.product-range .range-card > img,
.products-list .earbud-card > img {
    width: 100%;
    margin: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    mix-blend-mode: multiply;
    object-fit: cover;
}

/* Preserve the supplied finish on light-coloured models instead of allowing
   their studio whites to wash out the handset in product-list and definition
   sections. Multiply removes the neutral backdrop while retaining the colour. */
.explain-section .model-accurate-image,
.products-list .earbud-card > img[data-model-image-slug="iphone-11"],
.products-list .earbud-card > img[data-model-image-slug="iphone-xr"] {
    mix-blend-mode: multiply;
}

.product-range .range-card > div,
.products-list .earbud-card > div {
    position: relative;
    z-index: 1;
    background: var(--related-card-surface);
}

.product-range .range-card:hover,
.products-list .earbud-card:hover {
    border-color: #d4dfe6;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .98),
        inset 0 -1px 0 rgba(211, 220, 226, .62),
        0 20px 38px rgba(35, 74, 145, .15);
}

@media (max-width: 600px) {
    .product-range .range-card > img,
    .products-list .earbud-card > img {
        width: 100%;
        margin: 0;
    }
}
