/*
Theme Name: Modave Child
Theme URI: https://modave.presslayouts.com/landing
Author: PressLayouts Team
Description: Child theme for Modave with Mateossian customizations
Version: 1.3.30
Author URI: https://www.presslayouts.com/
Template: modave
Text Domain: modave-child
*/


/* Ενιαίο κάδρο 3:4 στις κάρτες προϊόντων */
.pls-product-image {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
}


/* Λεκτικό μάρκας πάνω από τον τίτλο στο archive */
.mateossian-loop-brand {
    margin-bottom: 4px;
    color: #777;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.mateossian-loop-brand a {
    color: inherit;
}

.mateossian-loop-brand a:hover {
    color: #111;
}


/* Λογότυπο μάρκας στη σελίδα προϊόντος */
.mateossian-single-brand-name {
    margin-bottom: 7px;
    color: var(--pls-secondary-color2, #888);
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: .02em;
    text-transform: uppercase;
}

.mateossian-single-brand-name a {
    color: inherit;
}

.mateossian-single-brand-name a:hover {
    color: var(--pls-secondary-color, #111);
}

.mateossian-single-brand-logo {
    display: flex;
    align-items: center;
    min-height: 0;
    margin: 10px 0 0;
}

.mateossian-single-brand-logo a {
    display: inline-flex;
    align-items: center;
}

.mateossian-single-brand-logo__image {
    display: block;
    width: auto;
    max-width: 120px;
    height: auto;
    max-height: 70px;
    object-fit: contain;
    object-position: left center;
}

.mateossian-single-brand-logo__fallback {
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}

/* Το logo αντικαθιστά την επάνω γραμμή κατηγοριών πριν από τον τίτλο. */
.woocommerce div.summary .pls-product-cat {
    display: none;
}

/* Το logo παίρνει τη θέση της αμέσως προηγούμενης γραμμής «Μάρκα» στο product meta. */
.single-product .product_meta > *:has(+ .mateossian-single-brand-logo),
.single-product .product_meta > *:not(.mateossian-single-brand-logo):has(a[href*="/brand/"]),
.single-product .product_meta > *:not(.mateossian-single-brand-logo):has(a[href*="product_brand"]) {
    display: none !important;
}

/* Πιο καθαρή οπτική ιεραρχία: μάρκα πρώτα, ελαφρώς μικρότερος τίτλος. */
.woocommerce div.product div.summary .product_title {
    font-size: 30px;
    line-height: 1.15;
}

/* Το description εμφανίζεται χαμηλά αυτούσιο, χωρίς σταθερή ετικέτα. */
.woocommerce div.product div.summary .woocommerce-product-details__short-description {
    margin: 18px 0 0;
}

.woocommerce div.product div.summary .woocommerce-product-details__short-description > :last-child {
    margin-bottom: 0;
}

/* Το «Καθαρισμός» των επιλογών να αναγνωρίζεται καθαρά ως σύνδεσμος. */
.woocommerce div.product form.variations_form .reset_variations {
    text-decoration-line: underline !important;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    cursor: pointer;
}

/* Η επιλεγμένη τιμή φαίνεται ήδη στο ενεργό swatch· δεν χρειάζεται να επαναλαμβάνεται δίπλα στην ετικέτα. */
form.variations_form .pls-swatches-selected-label {
    display: none !important;
}

/* Εξαντλημένα μεγέθη: ορατά και clickable, αλλά σαφώς διακριτά. */
form.variations_form .swatch-term.mateossian-out-of-stock {
    position: relative;
    overflow: hidden;
    background: #f5f5f5 !important;
    border-color: #d7d7d7 !important;
    color: #8a8a8a !important;
    opacity: 1 !important;
    cursor: pointer !important;
}

form.variations_form .swatch-term.mateossian-out-of-stock::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 12%;
    width: 76%;
    height: 1px;
    background: currentColor;
    transform: rotate(-38deg);
    transform-origin: center;
    pointer-events: none;
}

/* Επιλεγμένο εξαντλημένο μέγεθος. */
form.variations_form .swatch-term.mateossian-out-of-stock.swatch-selected {
    background: #fff1f0 !important;
    border-color: #d92d20 !important;
    color: #b42318 !important;
}

/* Το μήνυμα διαθεσιμότητας να ξεχωρίζει χωρίς βαρύ μαύρο badge. */
.woocommerce div.product div.summary p.stock.out-of-stock {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    margin: 8px 0 18px;
    padding: 7px 12px;
    background: #fff1f0 !important;
    border: 1px solid #f0b7b2;
    border-radius: 999px;
    color: #b42318 !important;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: .035em;
    text-transform: uppercase;
}

.products .product .product-title,
.products .product .woocommerce-loop-product__title {
    font-size: 16px;
    line-height: 1.35;
}

.pls-product-image > .woocommerce-LoopProduct-link {
    display: block;
    width: 100%;
    height: 100%;
}

.pls-product-image img.attachment-woocommerce_thumbnail {
    display: block;
    width: 100%;
    height: 100% !important;
    object-fit: cover;
    object-position: center top;
}


/* Εποχικό badge κατηγορίας στις κάρτες προϊόντων */
.products .product {
    position: relative;
}

.mateossian-collection-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 12;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 22px;
    padding: 4px 10px;
    background: #fff;
    color: #111;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: .02em;
    text-transform: uppercase;
    pointer-events: none;
}

.products .product.has-mateossian-collection-badge .pls-product-labels {
    top: 42px;
}


/* ==================================================
   ΦΙΛΤΡΑ ΚΑΤΑΣΤΗΜΑΤΟΣ
   ================================================== */

/*
 * Το parent theme εφαρμόζει ανεξάρτητο scroll σε κάθε ul του sidebar.
 * Στις ιεραρχικές κατηγορίες αυτό δημιουργεί δύο διπλανές μπάρες
 * (μία στην κύρια λίστα και μία στην εσωτερική λίστα). Η εσωτερική
 * λίστα ακολουθεί πλέον το scroll της κύριας.
 */
.pls-widget-area .widget ul ul,
.pls-shop-top-filter-widgets .widget ul ul {
    max-height: none !important;
    overflow: visible !important;
}

/* Καθαρή ιεραρχία ανάμεσα στον τίτλο κάθε φίλτρου και στις επιλογές του. */
.pls-widget-area .widget > .widget-title,
.pls-widget-area .widget > h2,
.pls-widget-area .widget .wp-block-group__inner-container > h2,
.pls-shop-top-filter-widgets .widget > .widget-title,
.pls-shop-top-filter-widgets .widget > h2,
.pls-shop-top-filter-widgets .widget .wp-block-group__inner-container > h2 {
    color: var(--pls-heading-color, #111);
    font-size: 22px;
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: -0.015em;
}

/*
 * Το Modave αποδίδει τις τιμές με μηδενικά προϊόντα ως σκέτο span,
 * χωρίς σύνδεσμο. Δεν έχουν καμία λειτουργία, οπότε δεν εμφανίζονται.
 * Ισχύει για μέγεθος, χρώμα και κάθε αντίστοιχο attribute filter.
 */
.pls-attributes-filter .pls-attributes-inline > li:not(:has(> a[href])) {
    display: none !important;
}


/* ==================================================
   ΚΑΡΤΕΣ ΚΑΤΗΓΟΡΙΩΝ ΑΡΧΙΚΗΣ
   ================================================== */

/* Ίδιο μέγεθος και στις τρεις κάρτες. */
.mateossian-category-card .pls-banners-slider .swiper-wrapper {
    align-items: flex-start !important;
}

/*
 * Το πραγματικό HTML του Product Categories widget δεν περιέχει την custom
 * κλάση του Banners Slider. Στην αρχική στοχεύουμε απευθείας τις κανονικές
 * κλάσεις του Modave και δίνουμε σε όλες τις κατηγορίες ενιαίο κάδρο 3:4.
 */
.home .pls-slider-wrapper .products.swiper-wrapper {
    align-items: stretch !important;
}

.home .pls-slider-wrapper .products.swiper-wrapper > .product-category {
    height: auto !important;
}

.home .pls-slider-wrapper .product-category .pls-category-inner {
    position: relative !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    aspect-ratio: 3 / 4 !important;
    overflow: hidden !important;
    background: #f5f5f5;
    border-radius: 12px;
}

.home .pls-slider-wrapper .product-category .pls-category-image,
.home .pls-slider-wrapper .product-category .pls-category-image > a {
    position: absolute !important;
    inset: 0 !important;
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
}

.home .pls-slider-wrapper .product-category .pls-category-image img {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    object-fit: cover !important;
    object-position: center top !important;
}

/* Όλοι οι τίτλοι παραμένουν στην ίδια θέση, ανεξάρτητα από την εικόνα. */
.home .pls-slider-wrapper .product-category .pls-category-content {
    position: absolute !important;
    z-index: 2 !important;
    right: 12px !important;
    bottom: 16px !important;
    left: 12px !important;
    width: auto !important;
    margin: 0 !important;
    transform: none !important;
}

/* Διακριτό περίγραμμα ακριβώς επάνω στο λευκό button του τίτλου. */
.home .mateossian-categories-men .product-category .pls-category-content > a,
.home .mateossian-categories-women .product-category .pls-category-content > a {
    box-sizing: border-box !important;
    border: 1px solid rgba(17, 17, 17, 0.14) !important;
    border-radius: 999px !important;
}

/*
 * Ασύμμετρη διάταξη των δύο σειρών της αρχικής:
 * τα Αντρικά ανοίγουν δεξιά όπως πριν, ενώ το slider των Γυναικείων
 * ανοίγει προς το αριστερό άκρο της οθόνης. Οι επικεφαλίδες μένουν
 * ευθυγραμμισμένες μέσα στο βασικό container.
 */
@media (min-width: 1025px) {
    .home .mateossian-categories-women .pls-slider-wrapper {
        width: calc(100% + ((100vw - 100%) / 2)) !important;
        max-width: none !important;
        margin-right: 0 !important;
        margin-left: calc((100vw - 100%) / -2) !important;
        overflow: hidden !important;
    }

    /* Καθρέφτης της επάνω γραμμής των Αντρικών. */
    .home .mateossian-categories-women .section-heading {
        display: flex !important;
        flex-direction: row-reverse !important;
        align-items: center !important;
        justify-content: space-between !important;
    }

    .home .mateossian-categories-women .section-heading > h2 {
        margin-right: 0 !important;
        margin-left: 0 !important;
        text-align: right;
    }

    .home .mateossian-categories-women .section-heading > .view-all-btn {
        margin-right: 0 !important;
        margin-left: 0 !important;
        text-align: left;
    }

}


/* ==================================================
   ΛΟΓΟΤΥΠΑ BRANDS ΑΡΧΙΚΗΣ
   ================================================== */

/*
 * Τα αρχεία των brands έχουν διαφορετικές αναλογίες. Κάθε λογότυπο
 * τοποθετείται σε ίδιο πλαίσιο ώστε να έχει κοινή στοίχιση και οπτικό βάρος,
 * χωρίς τέντωμα ή αλλοίωση των αναλογιών του.
 */
.home .pls-product-brands .products.swiper-wrapper {
    align-items: stretch !important;
}

.home .pls-product-brands .product-brand {
    height: auto !important;
}

.home .pls-product-brands .product-brand > a {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-height: 118px !important;
}

.home .pls-product-brands .brand-image {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 220px !important;
    max-width: 82% !important;
    height: 76px !important;
    margin: 0 auto !important;
}

.home .pls-product-brands .brand-image img {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    margin: 0 !important;
    object-fit: contain !important;
    object-position: center !important;
}

.mateossian-category-card .pls-banner {
    height: auto !important;
    min-height: 0 !important;
}

.mateossian-category-card .banner-wrapper {
    position: relative !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    aspect-ratio: 410 / 546 !important;
    overflow: hidden !important;
    border-radius: 20px;
}

/* Η εικόνα δεν επηρεάζει το ύψος της κάρτας. */
.mateossian-category-card .banner-image-wrap,
.mateossian-category-card .banner-image {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    overflow: hidden !important;
}

.mateossian-category-card .banner-image img {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    object-fit: cover !important;
    object-position: center top !important;
}

/* Διακριτική σκίαση χαμηλά για να διαβάζεται το link. */
.mateossian-category-card .banner-wrapper::after {
    content: "";
    position: absolute;
    z-index: 1;
    right: 0;
    bottom: 0;
    left: 0;
    height: 32%;
    pointer-events: none;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.28), transparent);
}

.mateossian-category-card .banner-content-wrap {
    position: absolute !important;
    inset: 0 !important;
    z-index: 2 !important;
}

/* Διακριτικό πλαίσιο μόνο στον επάνω υπότιτλο. */
.mateossian-category-card .banner-content-text {
    display: inline-block !important;
    width: fit-content !important;
    max-width: calc(100% - 40px) !important;
    padding: 7px 11px !important;
    background: rgba(255, 255, 255, 0.82) !important;
    color: #1a1a1a !important;
    border: 1px solid rgba(255, 255, 255, 0.45) !important;
    border-radius: 4px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 1.25 !important;
    letter-spacing: 0.035em !important;
    white-space: nowrap !important;
    box-shadow: 0 3px 14px rgba(0, 0, 0, 0.08) !important;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    text-shadow: none !important;
}

.mateossian-category-card .banner-content-text * {
    color: inherit !important;
}

/* Καθαρό link με κινούμενη γραμμή, χωρίς button πλαίσιο. */
.mateossian-category-card .banner-button .button {
    position: relative !important;
    display: inline-block !important;
    padding: 0 0 6px !important;
    background: transparent !important;
    color: #fff !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
    text-decoration: none !important;
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.45);
    backdrop-filter: none !important;
}

.mateossian-category-card .banner-button .button::before {
    display: none !important;
}

.mateossian-category-card .banner-button .button::after {
    content: "" !important;
    position: absolute !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    display: block !important;
    width: 100% !important;
    height: 1px !important;
    background: currentColor !important;
    transform: scaleX(1);
    transform-origin: right center;
    transition: transform 0.35s ease !important;
}

.mateossian-category-card .banner-button .button:hover {
    background: transparent !important;
    color: #fff !important;
}

.mateossian-category-card .banner-button .button:hover::after {
    transform: scaleX(0);
    transform-origin: left center;
}


/* ==================================================
   ΕΠΙΛΟΓΕΣ ΑΠΟΣΤΟΛΗΣ ΣΤΟ ΚΑΛΑΘΙ / CHECKOUT
   ================================================== */

/*
 * Το script μετατρέπει το κελί των επιλογών σε colspan=2. Έτσι δεν
 * περιορίζεται πλέον στη μισή στήλη του πίνακα και γεμίζει πραγματικά
 * όλο το διαθέσιμο πλάτος.
 */
.woocommerce table.shop_table tr.mateossian-shipping-row-normalized > th {
    display: none !important;
}

.woocommerce table.shop_table tr.mateossian-shipping-row-normalized > td {
    display: table-cell !important;
    width: 100% !important;
    max-width: none !important;
    float: none !important;
    padding: 16px 0 !important;
    text-align: left !important;
}

.woocommerce table.shop_table tr.mateossian-shipping-row-normalized > td::before {
    display: none !important;
}

.mateossian-shipping-title {
    margin: 0 0 12px;
    color: var(--pls-heading-color, #111);
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
}

/* Κάθε μέθοδος αποστολής γίνεται καθαρή, ενιαία επιλογή. */
.woocommerce ul#shipping_method {
    display: grid !important;
    gap: 9px;
    width: 100%;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.woocommerce ul#shipping_method li {
    position: relative;
    width: 100%;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
    text-indent: 0 !important;
}

.woocommerce ul#shipping_method li input.shipping_method {
    position: absolute;
    z-index: 2;
    top: 18px;
    left: 16px;
    width: 18px;
    height: 18px;
    margin: 0 !important;
    accent-color: #161616;
    cursor: pointer;
}

.woocommerce ul#shipping_method li label {
    display: flex !important;
    align-items: center;
    gap: 14px;
    width: 100%;
    max-width: none !important;
    box-sizing: border-box;
    min-height: 54px;
    margin: 0 !important;
    padding: 12px 16px 12px 48px;
    background: #fff;
    border: 1px solid #e4e4e4;
    border-radius: 10px;
    color: #222;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.35;
    text-align: left !important;
    cursor: pointer;
    transition: border-color .2s ease, background-color .2s ease, box-shadow .2s ease;
}

.woocommerce ul#shipping_method li label:hover {
    border-color: #aaa;
}

.woocommerce ul#shipping_method li input.shipping_method:checked + label {
    background: #f7f7f7;
    border-color: #1b1b1b;
    box-shadow: inset 0 0 0 1px #1b1b1b;
}

/* Η τιμή μένει δεξιά και δεν πέφτει μόνη της σε δεύτερη γραμμή. */
.woocommerce ul#shipping_method li label .amount {
    flex: 0 0 auto;
    margin-left: auto;
    font-weight: 700;
    white-space: nowrap;
}

.woocommerce ul#shipping_method li label .mateossian-free-shipping-label {
    flex: 0 0 auto;
    margin-left: auto;
    padding-left: 14px;
    font-weight: 700;
    white-space: nowrap;
}

/* Η χρέωση αντικαταβολής ακολουθεί τη στοίχιση των υπόλοιπων συνόλων. */
.woocommerce table.shop_table tr.fee > td {
    text-align: right !important;
}

.woocommerce table.shop_table tr.fee > td .amount {
    display: inline-block;
    margin-left: auto;
    font-weight: 700;
    white-space: nowrap;
}

/* Συμπαγής παρουσίαση του επιλογέα και των στοιχείων BOX NOW. */
.woocommerce ul#shipping_method li input.shipping_method[value*="box_now_delivery"]:not(:checked) ~ #box_now_delivery_button,
.woocommerce ul#shipping_method li input.shipping_method[value*="box_now_delivery"]:not(:checked) ~ #box_now_selected_locker_details {
    display: none !important;
}

.woocommerce ul#shipping_method #box_now_delivery_button {
    display: block !important;
    width: auto !important;
    min-width: 180px;
    min-height: 44px;
    margin: 10px 0 0 auto !important;
    padding: 10px 18px !important;
    border: 0 !important;
    border-radius: 8px !important;
    box-shadow: none !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
}

.woocommerce ul#shipping_method #box_now_selected_locker_details {
    width: 100% !important;
    max-width: none !important;
    margin: 10px 0 0 !important;
    padding: 12px 16px !important;
    box-sizing: border-box;
    background: #f4fbf1 !important;
    border: 1px solid #b9ddb0 !important;
    border-radius: 8px !important;
    color: #303830;
    text-align: left !important;
}

.woocommerce ul#shipping_method #locker-info {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 4px 10px;
}

.woocommerce ul#shipping_method #locker-info p {
    width: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    font-size: 13px;
    line-height: 1.4;
    text-align: left !important;
}

.woocommerce ul#shipping_method #locker-info .locker-title {
    flex: 0 0 auto;
    color: #202620;
}

.woocommerce ul#shipping_method #locker-info .locker-title::after {
    content: ":";
}

.woocommerce ul#shipping_method #locker-info .locker-detail {
    color: #555d55;
}

.woocommerce ul#shipping_method #locker-info .locker-detail + .locker-detail::before {
    content: "•";
    margin-right: 10px;
    color: #7a8578;
}

@media (max-width: 767px) {
    .woocommerce table.shop_table tr.mateossian-shipping-row-normalized > td {
        display: block !important;
        padding: 14px 0 16px !important;
    }

    .woocommerce ul#shipping_method li label {
        min-height: 52px;
        padding: 11px 13px 11px 44px;
        font-size: 14px;
    }

    .woocommerce ul#shipping_method li input.shipping_method {
        top: 17px;
        left: 14px;
    }

    .woocommerce ul#shipping_method #box_now_delivery_button {
        width: 100% !important;
        min-width: 0;
        min-height: 42px;
        margin-top: 8px !important;
    }

    .woocommerce ul#shipping_method #box_now_selected_locker_details {
        margin-top: 8px !important;
        padding: 11px 13px !important;
    }

    .woocommerce ul#shipping_method #locker-info {
        display: block;
    }

    .woocommerce ul#shipping_method #locker-info p {
        margin-top: 2px !important;
    }

    .woocommerce ul#shipping_method #locker-info .locker-detail + .locker-detail::before {
        content: none;
    }

    .home .pls-product-brands .product-brand > a {
        min-height: 96px !important;
    }

    .home .pls-product-brands .brand-image {
        width: 170px !important;
        height: 58px !important;
    }

    .pls-widget-area .widget > .widget-title,
    .pls-widget-area .widget > h2,
    .pls-widget-area .widget .wp-block-group__inner-container > h2,
    .pls-shop-top-filter-widgets .widget > .widget-title,
    .pls-shop-top-filter-widgets .widget > h2,
    .pls-shop-top-filter-widgets .widget .wp-block-group__inner-container > h2 {
        font-size: 18px;
    }

    .mateossian-collection-badge {
        top: 8px;
        left: 8px;
        min-height: 20px;
        padding: 4px 9px;
        font-size: 10px;
    }

    .products .product.has-mateossian-collection-badge .pls-product-labels {
        top: 38px;
    }

    .mateossian-single-brand-logo__image {
        max-width: 110px;
        max-height: 60px;
    }

    .mateossian-single-brand-name,
    .mateossian-loop-brand {
        font-size: 16px;
    }

    .woocommerce div.product div.summary .product_title {
        font-size: 22px;
    }

    .products .product .product-title,
    .products .product .woocommerce-loop-product__title {
        font-size: 15px;
    }
}
