/* ДИЗАЙН КОЛКО СПЕСТЯВА*/
.hit-saving-under-price {
    margin-top: 6px;
    font-size: 14px;
    line-height: 1.2;
}

.hit-saving-label {
    display: block;
    font-weight: 500;
    opacity: 0.9;
}

.hit-saving-amount {
    display: block;
    font-weight: 700;
    font-size: 16px;
    color: #000;
}

/* По желание – още по-стегнато за малки екрани */
@media (max-width: 480px) {
    .hit-saving-amount {
        font-size: 15px;
    }
}



/* Основна продукт карта */
.woocommerce ul.products li.product {
    border-radius: 18px;
    padding: 18px 16px 22px;
    transition: all 0.25s ease;
    background: #fff;
    text-align: center; /* центрираме всичко вътре */
}

/* Hover ефект */
.woocommerce ul.products li.product:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.08);
}

/* Снимка */
.woocommerce ul.products li.product img {
    margin-bottom: 12px;
    transition: transform 0.3s ease;
}

.woocommerce ul.products li.product:hover img {
    transform: scale(1.04);
}

/* Заглавие – 2 реда MAX  десктоп*/
.woocommerce ul.products li.product h2,
.woocommerce ul.products li.product h3 {
    font-size: 15px;
    font-weight: 500;
    line-height: 1.35;
    margin-bottom: 6px;

    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}


/* Цена – централно */
.woocommerce ul.products li.product .price {
    font-size: 15px;
    font-weight: 600;
    color: #222;
    margin-bottom: 10px;
    text-align: center;
}
@media (max-width: 480px) {
    .woocommerce ul.products li.product h2,
    .woocommerce ul.products li.product h3 {
        -webkit-line-clamp: 5;   /* повече място */
        font-size: 14px;         /* по-добра пропорция */
        line-height: 1.4;
    }
}

/* махаме underline от продукт линковете */
.woocommerce ul.products li.product a.ast-loop-product__link {
    text-decoration: none !important;
}

/* махаме underline от бутона */
.woocommerce ul.products li.product a.button {
    text-decoration: none !important;
}

/*ВСИЧКИ КАРТИ ЕДНАКВО ВИСОКИ*/

.woocommerce ul.products li.product {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* product link block */
.woocommerce ul.products li.product .ast-loop-product__link {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
/*ЗАГЛАВИЕТО ФИКСИРАНА ВИСОЧИНА*/
.woocommerce ul.products li.product .woocommerce-loop-product__title {
    min-height: 42px;
}
/*ЦЕНАТА ВИНАГИ Е НА ЕДНА ЛИНИЯ*/
.woocommerce ul.products li.product .price {
    margin-top: auto;
}
/*БУТОНА "ДОБАВИ.." ВИНАГИ НАЙ-ДОЛУ*/
.woocommerce ul.products li.product .button {
    margin-top: 10px;
}
/*HOVER*/
.woocommerce ul.products li.product {
    transition: all .25s ease;
}

.woocommerce ul.products li.product:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.08);
}

/*ДИЗАЙН НА ЕТИКЕТИ (HEMA FREE, TPO FREE...)*/
/* =========================
   PRODUCT BADGES
   ========================= */

.woocommerce ul.products li.product {
    position: relative;
}

.woocommerce ul.products li.product .hnh-product-badges {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 5;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.woocommerce ul.products li.product .hnh-badge {
    transform: rotate(-8deg);
    font-size: 12px;
    padding: 5px 9px;
    margin-top: 5px;
    border-radius: 14px;
    box-shadow: 0 4px 10px rgba(0,0,0,.12);
}

/* =========================
   SINGLE PRODUCT
   ========================= */

.single-product .woocommerce-product-gallery__wrapper {
    position: relative;
}

.single-product .hnh-product-badges {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    pointer-events: none;
}

.single-product .hnh-badge {
    transform: rotate(-8deg);
    font-size: 13px;
    padding: 7px 12px;
    margin-top: 6px;
    border-radius: 20px;
    box-shadow: 0 6px 15px rgba(0,0,0,.15);
}

/* =========================
   MOBILE
   ========================= */

@media (max-width: 768px) {

    .woocommerce ul.products li.product .hnh-product-badges {
        top: -11px;
        right: 6px;
    }

    .woocommerce ul.products li.product .hnh-badge {
        font-size: 9px;
        padding: 4px 7px;
        margin-top: 4px;
        transform: rotate(16deg);
        border-radius: 12px;
    }

    .single-product .hnh-product-badges {
        top: 8px;
        right: 8px;
    }

    .single-product .hnh-badge {
        font-size: 11px;
        padding: 5px 9px;
        margin-top: 5px;
        transform: rotate(-6deg);
        border-radius: 14px;
    }

}

/* =========================
   BADGE COLORS
   ========================= */

.hnh-badge.hema-tpo-free {
    background: #fde6f0;
    color: #e91e63;
}

.hnh-badge.new {
    background: #fff3cd;
    color: #b8860b;
}

.hnh-badge.promo {
    background: #ffe5e5;
    color: #c62828;
}

/* Контейнер на табовете */
.woocommerce div.product .woocommerce-tabs ul.tabs {
    display: flex;
    gap: 10px;
    border-bottom: 1px solid #eee;
    padding-left: 0;
    margin-bottom: 30px;
}

/* Всеки таб */
.woocommerce div.product .woocommerce-tabs ul.tabs li {
    background: transparent;
    border: none;
    margin: 0;
    padding: 0;
}

/* Линкът в таба */
.woocommerce div.product .woocommerce-tabs ul.tabs li a {
    display: inline-block;
    padding: 10px 18px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 500;
    color: #555;
    background: #f7f7f7;
    transition: all 0.25s ease;
}
/* Активен таб в single product (отзиви,документи,описание) */
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a {
    background: #e91e63;
    color: #fff;
}
.woocommerce div.product .woocommerce-tabs ul.tabs li a:hover {
    background: #e91e63;
    color: #fff;
}
/* Съдържание под табовете */
.woocommerce div.product .woocommerce-tabs .panel {
    padding: 24px 0;
    line-height: 1.7;
    font-size: 15px;
    color: #333;
}
.woocommerce div.product .woocommerce-tabs .panel h2 {
    font-size: 20px;
    margin-bottom: 14px;
    font-weight: 600;
}

/* Скриване на всички Sale badge-и в Astra + Woo */
.woocommerce span.onsale,
.woocommerce .ast-onsale-badge,
.woocommerce .ast-on-card-button {
    display: none !important;
}



/* =========================
   PRODUCT NAVIGATION
   ========================= */

.product-nav-under-header {
    padding: 10px 20px;
}

/* Desktop breadcrumb */

.product-breadcrumb-desktop {
    display: block;
    font-size: 14px;
    color: #777;
}

.product-breadcrumb-desktop a {
    color: #777;
    text-decoration: none;
}

.product-breadcrumb-desktop a:hover {
    color: #111;
}

/* Back button СТРЕЛКА НАЗАД*/

.product-back-mobile {
    display: inline-block;
    font-size: 14px;
    font-weight: 500;
    margin-right: 16px;
}

.product-back-mobile a {
    text-decoration: none;
    color: #111;
}

.product-back-mobile a:hover {
    opacity: .7;
}

/* =========================
   RESPONSIVE
   ========================= */

@media (max-width: 768px) {

    .product-breadcrumb-desktop {
        display: none;
    }

    .product-back-mobile {
        display: block;
    }

    .woocommerce-breadcrumb {
        display: none !important;
    }

}

@media (min-width: 769px) {

    .single-product .summary .woocommerce-breadcrumb {
        display: none !important;
    }

}
/*СКРИВА КАТЕГОРИЯТА В ЗАГЛАВИЕТО SINGLE PRODUCKT*/
.single-product .single-product-category {
    display: none !important;
}
/* Махаме категорията от картите в shop / category */
.ast-woo-product-category {
    display: none !important;
}

/* Центриране на Add to Cart бутона в product cards (Astra fix) */
.woocommerce ul.products li.product .button {
    margin: 12px auto 0 auto !important; /* override Astra */
    display: flex !important;
    align-items: center;
    justify-content: center;

    border-radius: 999px;
    padding: 8px 18px;
    font-size: 13px;
    font-weight: 500;
    background: #fff;
    color: #EA559D;
    border: 1px solid #EA559D;
    transition: all 0.25s ease;
}

.woocommerce ul.products li.product .button:hover {
    background: #EA559D;
    color: #fff;
}

/* =========================================================
   ASTRA MEGA MENU – FULL WIDTH, SAFE, NON-FIXED
   Работи само на desktop (>= 922px)
   ========================================================= */

@media (min-width: 922px) {
  /* 1) Header като референтен контейнер */
  .ast-desktop .site-header {
    position: relative;
    z-index: 1000;
  }

  /* 2) Родителите да не режат dropdown-а */
  .ast-desktop .main-header-menu > li {
    position: static;
  }

  /* 3) Sub-menu скрито по подразбиране */
  .ast-desktop .main-header-menu .sub-menu {
    display: grid; /* държим grid, но го правим невидим */
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(6px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
  }

  /* 4) Показване при hover */
  .ast-desktop .main-header-menu > li.menu-item-has-children:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
  }

  /* 5) Mega dropdown */
  .ast-desktop .main-header-menu > li.menu-item-has-children > .sub-menu {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;

    width: 100%;
    max-width: 100%;

    grid-template-columns: repeat(4, minmax(180px, 1fr));
    gap: 24px 40px;

    padding: 32px 40px;
    background: #fff;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.12);
    border-radius: 0;
    overflow: hidden;
    z-index: 999;
  }

  /* 6) Колони */
  .ast-desktop .main-header-menu > li.menu-item-has-children > .sub-menu > li {
    transition: transform 0.25s ease;
  }

  .ast-desktop .main-header-menu > li.menu-item-has-children > .sub-menu > li:hover {
    transform: translateY(-2px);
  }

  .ast-desktop .main-header-menu > li.menu-item-has-children > .sub-menu > li:not(:last-child) {
    border-right: 1px solid rgba(0, 0, 0, 0.05);
  }

  /* 7) Линкове */
  .ast-desktop .sub-menu li a {
    position: relative;
    display: inline-block;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 14px;
    color: #333;
    background: transparent;
    transition: background-color 0.2s ease, color 0.2s ease;
  }

  .ast-desktop .sub-menu li a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -4px;
    width: 0;
    height: 1px;
    background: #ea559d;
    transition: width 0.25s ease;
  }

  .ast-desktop .sub-menu li a:hover {
    background-color: rgba(234, 85, 157, 0.08);
    color: #ea559d;
  }

  .ast-desktop .sub-menu li a:hover::after {
    width: 100%;
  }

  .ast-desktop .sub-menu li.current-menu-item > a,
  .ast-desktop .sub-menu li.current-menu-ancestor > a {
    color: #ea559d;
    font-weight: 600;
  }
}

/*УПРАВЛЯВА АНИМАЦИЯТА НА ХЕДЪРА ПРИ СКРОЛ*/
#masthead {
  transition: transform .25s ease, opacity .25s ease;
}
#masthead:not(.header-visible) {
  transform: translateY(-100%);
}

