/* ============================================================================
   listing-v8.css  —  Modern luxury overlay for gyalia-hliou.asp + variants
   Scoped under `body.listing-v8` to avoid affecting other pages.
   Relies on home-v8.css for CSS variables (--v8-display, --v8-ui, --v8-accent...).
   ============================================================================ */

body.listing-v8 {
    font-family: var(--v8-ui);
    color: var(--v8-text);
    background: #FFFFFF;
}

/* ─────────── Page header / hero (topcategorydiv) ─────────── */
body.listing-v8 .topcategorydiv {
    background: #FAFAFA;
    border-bottom: 1px solid var(--v8-line);
    padding: 24px 0 28px;
    margin-bottom: 30px;
}
body.listing-v8 .moduleItemIntrotext {
    text-align: center;
}
body.listing-v8 h1.myfontsize20,
body.listing-v8 h1.mybottomzero {
    font-family: var(--v8-display) !important;
    font-weight: 400 !important;
    font-size: clamp(24px, 3vw, 36px) !important;
    line-height: 1.15 !important;
    letter-spacing: -0.3px !important;
    color: var(--v8-text) !important;
    margin: 8px 0 12px !important;
    text-transform: none !important;
    display: block !important;
}
body.listing-v8 h1 small,
body.listing-v8 h1 .small {
    font-family: var(--v8-ui);
    font-weight: 300;
    font-size: 0.55em;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--v8-muted);
    display: block;
    margin-top: 6px;
}

/* ─────────── Breadcrumb ─────────── */
body.listing-v8 .breadcrumb {
    background: transparent !important;
    padding: 0 0 10px !important;
    margin: 0 0 14px !important;
    font-family: var(--v8-ui);
    font-size: 12px;
    letter-spacing: 0.3px;
    color: var(--v8-muted);
    border-radius: 0;
}
body.listing-v8 .breadcrumb > li + li::before {
    content: "›";
    padding: 0 8px;
    color: var(--v8-line);
}
body.listing-v8 .breadcrumb a,
body.listing-v8 .breadcrumb a u {
    color: var(--v8-muted) !important;
    text-decoration: none !important;
    transition: color 0.2s;
}
body.listing-v8 .breadcrumb a:hover,
body.listing-v8 .breadcrumb a:hover u {
    color: var(--v8-accent) !important;
}

/* ─────────── Intro paragraph ─────────── */
body.listing-v8 .intro p,
body.listing-v8 .moduleItemIntrotext .intro {
    font-family: var(--v8-ui);
    font-size: 13.5px;
    line-height: 1.65;
    color: var(--v8-muted);
    font-weight: 300;
    max-width: 880px;
    margin: 0 auto;
    text-align: left;
}
body.listing-v8 .intro p b,
body.listing-v8 .intro p strong {
    color: var(--v8-text);
    font-weight: 500;
}

/* ─────────── Filter sidebar (aside.cart-sidebar) ─────────── */
body.listing-v8 .cart-sidebar-header {
    background: var(--v8-text) !important;
    color: #fff !important;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
body.listing-v8 .cart-sidebar-header h3 {
    font-family: var(--v8-ui);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #fff;
    margin: 0;
}
body.listing-v8 .icr {
    font-family: var(--v8-ui);
    font-size: 13px;
    color: var(--v8-text);
}

/* ─────────── Sort / View options bar ─────────── */
body.listing-v8 .change-view-flat,
body.listing-v8 .sortby {
    font-family: var(--v8-ui);
    font-size: 12px;
    color: var(--v8-muted);
}

/* ─────────── PRODUCT CARDS — the heart of the listing ─────────── */
/* Use flexbox on the product row so all sibling cards in a row stay equal-height
   regardless of description / price content length. */
body.listing-v8 #productslist.row,
body.listing-v8 .row.categoryProduct {
    display: flex;
    flex-wrap: wrap;
}
body.listing-v8 .item.myitem {
    padding: 6px !important;
    margin-bottom: 8px;
    display: flex;
}
body.listing-v8 .product {
    background: #FFFFFF;
    border: 1px solid var(--v8-line);
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    width: 100%;
}
body.listing-v8 .product:hover {
    border-color: var(--v8-accent);
    box-shadow: 0 8px 28px rgba(80, 137, 176, 0.12);
    transform: translateY(-2px);
}

/* Image area */
body.listing-v8 .product .image {
    background: #F7F8FA;
    padding: 14px 14px 4px;
    position: relative;
    max-height: none !important;     /* override base style2016 max-height:240px */
    overflow: visible;
}
body.listing-v8 .product .container1 {
    padding-top: 60.66% !important;  /* keep stable aspect ratio (matches gyalia-hliou.css) */
    position: relative !important;
    overflow: hidden;
}
/* CRITICAL: make the anchor itself fill .container1 so the click target exists
   even before lazy-load swaps the placeholder SVG into <img src>. */
body.listing-v8 .product .container1 a {
    position: absolute !important;
    top: 0; right: 0; bottom: 0; left: 0;
    display: block !important;
    z-index: 2;
    overflow: hidden;
}
body.listing-v8 .product .container1 a img {
    position: absolute !important;
    top: 0; right: 0; bottom: 0; left: 0;
    margin: auto !important;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    transition: transform 0.5s ease;
}
body.listing-v8 .product:hover .container1 a img {
    transform: scale(1.04);
}
/* Description gets the remaining height so cards in a row stay equal */
body.listing-v8 .product .description {
    flex: 1 1 auto;
}

/* Hide clutter (productid badge — not customer-facing) */
body.listing-v8 .product .promotion2 {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 2;
    opacity: 0.5;
    font-size: 10px !important;
}
body.listing-v8 .product .promotion2 .productid {
    font-size: 10px !important;
    color: var(--v8-muted) !important;
    background: rgba(255,255,255,0.85);
    padding: 2px 6px;
}

/* Promotion badges (NEW / discount) */
body.listing-v8 .product .promotion {
    position: absolute;
    top: 8px; right: 8px; left: auto;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    z-index: 3;
}
body.listing-v8 .product .promotion .new-product {
    font-family: var(--v8-ui) !important;
    background: #FFFFFF !important;
    color: var(--v8-accent) !important;
    border: 1px solid var(--v8-accent) !important;
    font-size: 10px !important;
    font-weight: 600 !important;
    letter-spacing: 1.8px !important;
    padding: 3px 8px !important;
    text-transform: uppercase !important;
    border-radius: 0 !important;
    height: auto !important;
    line-height: 1.4 !important;
    float: none !important;
    display: inline-block !important;
}
body.listing-v8 .product .promotion .discount {
    font-family: var(--v8-ui) !important;
    background: var(--v8-text) !important;
    color: #FFFFFF !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    letter-spacing: 0.3px !important;
    padding: 4px 8px !important;
    border-radius: 0 !important;
    height: auto !important;
    line-height: 1.4 !important;
    float: none !important;
    display: inline-block !important;
    position: static !important;
    bottom: auto !important;
    left: auto !important;
}

/* Polarized / Black Friday badges (corner) */
body.listing-v8 .product .blackfr,
body.listing-v8 .product .mypolar {
    opacity: 0.92;
}

/* Description area */
body.listing-v8 .product .description {
    padding: 12px 12px 14px !important;
    text-align: center;
}
body.listing-v8 .product .description h4 {
    margin: 0 0 4px;
    font-family: var(--v8-display);
    font-weight: 400;
    font-size: 17px;
    letter-spacing: -0.2px;
    text-transform: capitalize;
}
body.listing-v8 .product .description h4 a {
    color: var(--v8-text) !important;
    text-decoration: none !important;
}
body.listing-v8 .product .description h4 a:hover {
    color: var(--v8-accent) !important;
}
body.listing-v8 .product .description .grid-description {
    margin: 0 0 6px;
}
body.listing-v8 .product .description .lineOverflow {
    font-family: var(--v8-ui);
    font-size: 11px;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: var(--v8-muted);
    font-weight: 500;
}
body.listing-v8 .product .description .century14grey {
    font-family: var(--v8-ui) !important;
    font-size: 11px !important;
    color: var(--v8-muted) !important;
    font-weight: 500 !important;
    letter-spacing: 0.5px;
}

/* Hide long list-description ul on hover-card; keep schema in DOM */
body.listing-v8 .product .list-description {
    display: none !important;
}

/* Price */
body.listing-v8 .product .price {
    font-family: var(--v8-ui);
    font-size: 14px;
    padding: 4px 12px 12px !important;
    text-align: center;
    color: var(--v8-text);
}
body.listing-v8 .product .price .from {
    color: var(--v8-muted) !important;
    text-decoration: line-through !important;
    font-size: 12px !important;
    margin-right: 6px;
}
body.listing-v8 .product .price > span:not(.from) {
    font-weight: 600;
    color: var(--v8-text);
}

/* Quick view / Color view / Detail buttons */
body.listing-v8 .product .colorview,
body.listing-v8 .product .quickview,
body.listing-v8 .product .normalview {
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;          /* let clicks pass through to image <a> */
}
body.listing-v8 .product:hover .colorview,
body.listing-v8 .product:hover .quickview,
body.listing-v8 .product:hover .normalview {
    opacity: 1;
}
/* Buttons inside overlay divs still need to receive clicks */
body.listing-v8 .product .colorview > *,
body.listing-v8 .product .quickview > *,
body.listing-v8 .product .normalview > * {
    pointer-events: auto;
}
body.listing-v8 .product .btn-quickview,
body.listing-v8 .product .btn-normalview {
    font-family: var(--v8-ui) !important;
    font-size: 10px !important;
    letter-spacing: 1.5px !important;
    text-transform: uppercase;
    background: #fff !important;
    color: var(--v8-text) !important;
    border: 1px solid var(--v8-text) !important;
    padding: 5px 10px !important;
    border-radius: 0 !important;
    font-weight: 500 !important;
    transition: all 0.2s;
}
body.listing-v8 .product .btn-quickview:hover,
body.listing-v8 .product .btn-normalview:hover {
    background: var(--v8-accent) !important;
    color: #fff !important;
    border-color: var(--v8-accent) !important;
}

/* Stock indicator (color-in / cartorange) */
body.listing-v8 .product .color-in { color: #2A9D5A !important; }
body.listing-v8 .product .cartorange { color: #C8762A !important; }

/* Add-to-cart / Add-to-wishlist */
body.listing-v8 .product .add-fav {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 4;
    color: var(--v8-muted) !important;
    background: rgba(255,255,255,0.9);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
body.listing-v8 .product .add-fav:hover {
    color: #C8762A !important;
    background: #fff;
}

/* ─────────── Pagination ─────────── */
body.listing-v8 .pagination {
    margin: 32px 0;
    font-family: var(--v8-ui);
}
body.listing-v8 .pagination > li > a,
body.listing-v8 .pagination > li > span {
    color: var(--v8-muted) !important;
    border: 1px solid var(--v8-line) !important;
    background: #FFFFFF !important;
    font-size: 13px;
    letter-spacing: 0.5px;
    padding: 8px 14px !important;
    margin: 0 2px;
    transition: all 0.2s;
    border-radius: 0 !important;
}
body.listing-v8 .pagination > li > a:hover {
    background: var(--v8-text) !important;
    color: #FFFFFF !important;
    border-color: var(--v8-text) !important;
}
body.listing-v8 .pagination > .active > a,
body.listing-v8 .pagination > .active > a:hover,
body.listing-v8 .pagination > .active > span {
    background: var(--v8-accent) !important;
    color: #FFFFFF !important;
    border-color: var(--v8-accent) !important;
}

/* ─────────── Bottom SEO/content sections ─────────── */
body.listing-v8 .innerPage {
    max-width: 980px;
    margin: 40px auto !important;
    padding: 0 24px;
}
body.listing-v8 .innerPage h2,
body.listing-v8 .innerPage h3 {
    font-family: var(--v8-display);
    font-weight: 400;
    color: var(--v8-text);
    letter-spacing: -0.2px;
}
body.listing-v8 .innerPage h2 { font-size: clamp(22px, 2.4vw, 28px); margin: 1.4em 0 0.5em; }
body.listing-v8 .innerPage h3 { font-size: 20px; margin: 1.2em 0 0.5em; }
body.listing-v8 .innerPage p,
body.listing-v8 .innerPage li {
    font-family: var(--v8-ui);
    font-size: 14px;
    line-height: 1.7;
    color: var(--v8-text);
    font-weight: 300;
}
body.listing-v8 .innerPage strong {
    font-weight: 500;
    color: var(--v8-text);
}
body.listing-v8 .innerPage a {
    color: var(--v8-accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* ─────────── Generic buttons restyle ─────────── */
body.listing-v8 .btn.btn-thin {
    font-family: var(--v8-ui) !important;
    font-size: 11px !important;
    letter-spacing: 2px !important;
    text-transform: uppercase;
    background: transparent !important;
    color: var(--v8-accent) !important;
    border: 1px solid var(--v8-accent) !important;
    padding: 8px 18px !important;
    border-radius: 0 !important;
    transition: all 0.2s;
}
body.listing-v8 .btn.btn-thin:hover {
    background: var(--v8-accent) !important;
    color: #fff !important;
}

/* ─────────── Mobile adjustments ─────────── */
@media (max-width: 767px) {
    body.listing-v8 .topcategorydiv {
        padding: 16px 0 18px;
        margin-bottom: 18px;
    }
    body.listing-v8 h1.myfontsize20,
    body.listing-v8 h1.mybottomzero {
        font-size: 20px !important;
    }
    body.listing-v8 .item.myitem {
        padding: 4px !important;
    }
    body.listing-v8 .product .description h4 { font-size: 14px; }
    body.listing-v8 .product .description .century14grey { font-size: 10px !important; }
    body.listing-v8 .product .price { font-size: 13px; }
    body.listing-v8 .product .colorview,
    body.listing-v8 .product .quickview,
    body.listing-v8 .product .normalview { opacity: 1; }  /* always visible on touch */
}
