/* =========================================================
   CATEGORY NAVIGATION — CLEAN FINAL
   Home / Collections / Product / Footer
========================================================= */

/* =========================================================
   VARIABLES / SCOPES
========================================================= */

.category_navigation_scope,
.product_categories_mobile_scope,
.home_categories_scope,
.footer_categories_scope,
.section_categories_mobile,
.section_categories {
  --cat-nav-row-height: 2rem;
  --cat-nav-line-gap: 0.35rem;
  --cat-nav-item-gap: 2.4rem;

  position: relative;
  width: 100%;
}

/* =========================================================
   TECHNICAL DATA HIDDEN
========================================================= */

.slug_category_tab_mobile,
.slug_category_panel_mobile,
.product-category-slug-current,
.product-univers-slug-current,
.product-subcat-slug-current,
.category-slug-current,
.category-univers-slug-current,
.category-subcat-slug-current,
.subcat-maincat-slug,
.univers-maincat-slug,
.category-univers-source {
  display: none !important;
}

/* =========================================================
   MAINCAT TABS — STANDARD NAV
========================================================= */

.category_navigation_scope .list_categories_tabs_mobile,
.product_categories_mobile_scope .list_categories_tabs_mobile,
.home_categories_scope .list_categories_tabs_mobile,
.footer_categories_scope .list_categories_tabs_mobile {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  align-items: center !important;
  gap: 0 !important;
  width: 100% !important;
}

.category_navigation_scope .item_category_tab_mobile,
.product_categories_mobile_scope .item_category_tab_mobile,
.home_categories_scope .item_category_tab_mobile,
.footer_categories_scope .item_category_tab_mobile {
  position: relative;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;

  width: 100% !important;
  min-width: 0 !important;
  min-height: var(--cat-nav-row-height) !important;

  padding-bottom: 0.65rem;
}

.category_navigation_scope .link_category_tab_mobile,
.product_categories_mobile_scope .link_category_tab_mobile,
.home_categories_scope .link_category_tab_mobile,
.footer_categories_scope .link_category_tab_mobile {
  position: relative;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;

  width: auto !important;
  max-width: max-content !important;

  color: inherit;
  text-decoration: none !important;
  opacity: 1 !important;
  overflow: visible;
}

.category_navigation_scope .text_category_tab_mobile,
.product_categories_mobile_scope .text_category_tab_mobile,
.home_categories_scope .text_category_tab_mobile,
.footer_categories_scope .text_category_tab_mobile {
  position: relative;
  display: inline-block;
  color: inherit;
  line-height: 1;
  white-space: nowrap;
}

/* Neutralise anciens soulignements internes */
.category_navigation_scope .link_category_tab_mobile::after,
.product_categories_mobile_scope .link_category_tab_mobile::after,
.home_categories_scope .link_category_tab_mobile::after,
.footer_categories_scope .link_category_tab_mobile::after,
.category_navigation_scope .text_category_tab_mobile::after,
.product_categories_mobile_scope .text_category_tab_mobile::after,
.home_categories_scope .text_category_tab_mobile::after,
.footer_categories_scope .text_category_tab_mobile::after {
  display: none !important;
  content: none !important;
}

/* Soulignement pleine largeur de colonne */
.category_navigation_scope .item_category_tab_mobile::after,
.product_categories_mobile_scope .item_category_tab_mobile::after,
.home_categories_scope .item_category_tab_mobile::after,
.footer_categories_scope .item_category_tab_mobile::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;

  width: 100%;
  height: 1px;

  background: currentColor;

  opacity: 0;
  transform: scaleX(0.92);
  transform-origin: center center;

  transition:
    opacity 220ms ease,
    transform 280ms ease;

  pointer-events: none;
}

.category_navigation_scope .item_category_tab_mobile:hover::after,
.category_navigation_scope .item_category_tab_mobile.is-active::after,
.category_navigation_scope .item_category_tab_mobile.is-preview::after,
.product_categories_mobile_scope .item_category_tab_mobile:hover::after,
.product_categories_mobile_scope .item_category_tab_mobile.is-active::after,
.product_categories_mobile_scope .item_category_tab_mobile.is-preview::after,
.home_categories_scope .item_category_tab_mobile:hover::after,
.home_categories_scope .item_category_tab_mobile.is-active::after,
.home_categories_scope .item_category_tab_mobile.is-preview::after,
.footer_categories_scope .item_category_tab_mobile:hover::after,
.footer_categories_scope .item_category_tab_mobile.is-active::after,
.footer_categories_scope .item_category_tab_mobile.is-preview::after {
  opacity: 1;
  transform: scaleX(1);
}

/* =========================================================
   COLLECTIONS MAINCATS — FINSWEET FORM STRUCTURE
========================================================= */

.main-categories .w-dyn-items,
.main-categories .list_categories_tabs_mobile {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  width: 100% !important;
  gap: 0 !important;
}

.main-categories .w-dyn-item,
.main-categories .item_category_tab_mobile {
  position: relative;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;

  width: 100% !important;
  min-width: 0 !important;
  min-height: var(--cat-nav-row-height) !important;

  padding-bottom: 0 !important;
}

.main-categories .item_category_tab_mobile::after,
.main-categories .w-dyn-item::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;

  width: 100%;
  height: 1px;

  background: currentColor;

  opacity: 0;
  transform: scaleX(0.92);
  transform-origin: center center;

  transition:
    opacity 220ms ease,
    transform 280ms ease;

  pointer-events: none;
}

.main-categories .item_category_tab_mobile:hover::after,
.main-categories .item_category_tab_mobile.is-active::after,
.main-categories .item_category_tab_mobile.is-list-active::after,
.main-categories .item_category_tab_mobile:has(.filter_radio-item.is-active)::after,
.main-categories .item_category_tab_mobile:has(.filter_radio-item.is-list-active)::after,
.main-categories .item_category_tab_mobile:has(input:checked)::after,
.main-categories .item_category_tab_mobile:has(.w--redirected-checked)::after,
.main-categories .w-dyn-item:hover::after,
.main-categories .w-dyn-item.is-active::after,
.main-categories .w-dyn-item.is-list-active::after {
  opacity: 1 !important;
  transform: scaleX(1) !important;
}

/* Neutralise soulignement court sur maincat */
.main-categories .maincat-label::after,
.main-categories .univers-label::after,
.main-categories .radiobutton_label::after,
.main-categories .text_category_tab_mobile::after {
  display: none !important;
  content: none !important;
}

/* =========================================================
   PANELS — DEFAULT
========================================================= */

.category_navigation_scope .content_categories_mobile,
.product_categories_mobile_scope .content_categories_mobile,
.home_categories_scope .content_categories_mobile,
.footer_categories_scope .content_categories_mobile {
  width: 100%;
  margin-top: var(--cat-nav-line-gap);
}

.category_navigation_scope .list_categories_panels_mobile,
.product_categories_mobile_scope .list_categories_panels_mobile,
.home_categories_scope .list_categories_panels_mobile,
.footer_categories_scope .list_categories_panels_mobile {
  width: 100%;
}

.category_navigation_scope .item_category_panel_mobile,
.product_categories_mobile_scope .item_category_panel_mobile,
.home_categories_scope .item_category_panel_mobile,
.footer_categories_scope .item_category_panel_mobile {
  display: none !important;
  width: 100%;

  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
  pointer-events: auto !important;
}

.category_navigation_scope .item_category_panel_mobile.is-active,
.category_navigation_scope .item_category_panel_mobile.is-visible,
.product_categories_mobile_scope .item_category_panel_mobile.is-active,
.product_categories_mobile_scope .item_category_panel_mobile.is-visible,
.home_categories_scope .item_category_panel_mobile.is-active,
.home_categories_scope .item_category_panel_mobile.is-visible,
.footer_categories_scope .item_category_panel_mobile.is-active,
.footer_categories_scope .item_category_panel_mobile.is-visible {
  display: block !important;
}

/* =========================================================
   PRODUCT PAGE PANELS — ALIGNÉS SOUS MAINCATS
========================================================= */

.product_categories_mobile_scope {
  min-height: 5rem;
}

.product_categories_mobile_scope .content_categories_mobile {
  margin-top: 0.3rem !important;
}

.product_categories_mobile_scope .list_categories_panels_mobile {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  align-items: start;
  gap: 0;
  width: 100%;
  height: 5rem;
}

.product_categories_mobile_scope .item_category_panel_mobile {
  grid-row: 1;
  width: 100%;
  text-align: center;
}

.product_categories_mobile_scope .item_category_panel_mobile:nth-child(1) {
  grid-column: 1;
}

.product_categories_mobile_scope .item_category_panel_mobile:nth-child(2) {
  grid-column: 2;
}

.product_categories_mobile_scope .item_category_panel_mobile:nth-child(3) {
  grid-column: 3;
}

/* =========================================================
   UNIVERS / SUBCATS — SHARED NAV LINKS
========================================================= */

.category_navigation_scope .product-univers,
.product_categories_mobile_scope .product-univers,
.home_categories_scope .product-univers,
.footer_categories_scope .product-univers,
.category_navigation_scope .product-subcategories,
.product_categories_mobile_scope .product-subcategories,
.home_categories_scope .product-subcategories,
.footer_categories_scope .product-subcategories {
  display: block;
  width: 100%;
  height: auto !important;
}

.category_navigation_scope .product-univers,
.product_categories_mobile_scope .product-univers {
  min-height: 1.35rem;
  margin-bottom: 0.12rem;
}

.category_navigation_scope .product-subcategories,
.product_categories_mobile_scope .product-subcategories {
  min-height: 1.25rem;
}

.category_navigation_scope .product-univers-list,
.product_categories_mobile_scope .product-univers-list,
.home_categories_scope .product-univers-list,
.footer_categories_scope .product-univers-list,
.category_navigation_scope .product-subcategories-list,
.product_categories_mobile_scope .product-subcategories-list,
.home_categories_scope .product-subcategories-list,
.footer_categories_scope .product-subcategories-list {
  display: flex !important;
  align-items: center;
  justify-content: center;
  align-content: center;
  flex-wrap: wrap;

  gap: 0.15rem var(--cat-nav-item-gap);
  width: 100%;
}

.product_categories_mobile_scope .product-univers-list,
.product_categories_mobile_scope .product-subcategories-list {
  margin-top: 0.5rem;
}

.category_navigation_scope .item_subcathome,
.product_categories_mobile_scope .item_subcathome,
.home_categories_scope .item_subcathome,
.footer_categories_scope .item_subcathome,
.category_navigation_scope .item_univershome,
.product_categories_mobile_scope .item_univershome,
.home_categories_scope .item_univershome,
.footer_categories_scope .item_univershome {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.category_navigation_scope .subcathome-link,
.product_categories_mobile_scope .subcathome-link,
.home_categories_scope .subcathome-link,
.footer_categories_scope .subcathome-link,
.category_navigation_scope .univershome-link,
.product_categories_mobile_scope .univershome-link,
.home_categories_scope .univershome-link,
.footer_categories_scope .univershome-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;

  color: inherit;
  text-decoration: none !important;
  white-space: nowrap;
  opacity: 1 !important;
}

.category_navigation_scope .subcathome-link::after,
.product_categories_mobile_scope .subcathome-link::after,
.home_categories_scope .subcathome-link::after,
.footer_categories_scope .subcathome-link::after,
.category_navigation_scope .univershome-link::after,
.product_categories_mobile_scope .univershome-link::after,
.home_categories_scope .univershome-link::after,
.footer_categories_scope .univershome-link::after {
  display: none !important;
  content: none !important;
}

.category_navigation_scope .subcathome-text,
.product_categories_mobile_scope .subcathome-text,
.home_categories_scope .subcathome-text,
.footer_categories_scope .subcathome-text,
.category_navigation_scope .univershome-text,
.product_categories_mobile_scope .univershome-text,
.home_categories_scope .univershome-text,
.footer_categories_scope .univershome-text {
  position: relative;
  display: inline-block;

  color: inherit;

  line-height: 1;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.category_navigation_scope .subcathome-text::after,
.product_categories_mobile_scope .subcathome-text::after,
.home_categories_scope .subcathome-text::after,
.footer_categories_scope .subcathome-text::after,
.category_navigation_scope .univershome-text::after,
.product_categories_mobile_scope .univershome-text::after,
.home_categories_scope .univershome-text::after,
.footer_categories_scope .univershome-text::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.16em;

  width: 100%;
  height: 1px;

  background: currentColor;

  transform: scaleX(0);
  transform-origin: left center;

  transition: transform 260ms ease;
  pointer-events: none;
}

.category_navigation_scope .subcathome-link:hover .subcathome-text::after,
.category_navigation_scope .subcathome-link.is-active .subcathome-text::after,
.product_categories_mobile_scope .subcathome-link:hover .subcathome-text::after,
.product_categories_mobile_scope .subcathome-link.is-active .subcathome-text::after,
.home_categories_scope .subcathome-link:hover .subcathome-text::after,
.home_categories_scope .subcathome-link.is-active .subcathome-text::after,
.footer_categories_scope .subcathome-link:hover .subcathome-text::after,
.footer_categories_scope .subcathome-link.is-active .subcathome-text::after,
.category_navigation_scope .univershome-link:hover .univershome-text::after,
.category_navigation_scope .univershome-link.is-active .univershome-text::after,
.product_categories_mobile_scope .univershome-link:hover .univershome-text::after,
.product_categories_mobile_scope .univershome-link.is-active .univershome-text::after,
.home_categories_scope .univershome-link:hover .univershome-text::after,
.home_categories_scope .univershome-link.is-active .univershome-text::after,
.footer_categories_scope .univershome-link:hover .univershome-text::after,
.footer_categories_scope .univershome-link.is-active .univershome-text::after {
  transform: scaleX(1);
}

/* =========================================================
   MOBILE
========================================================= */

@media screen and (max-width: 767px) {
  .category_navigation_scope .content_categories_mobile,
  .product_categories_mobile_scope .content_categories_mobile,
  .home_categories_scope .content_categories_mobile,
  .footer_categories_scope .content_categories_mobile {
    margin-top: 1rem;
  }

  .category_navigation_scope .product-univers-list,
  .product_categories_mobile_scope .product-univers-list,
  .home_categories_scope .product-univers-list,
  .footer_categories_scope .product-univers-list,
  .category_navigation_scope .product-subcategories-list,
  .product_categories_mobile_scope .product-subcategories-list,
  .home_categories_scope .product-subcategories-list,
  .footer_categories_scope .product-subcategories-list {
    gap: 0.25rem 1.2rem;
  }
}

/* =========================================================
   CATEGORY NAV — MOBILE PANELS STACK FIX
========================================================= */

@media screen and (max-width: 767px) {
  .product_categories_mobile_scope .list_categories_panels_mobile,
  .collections_categories_scope .list_categories_panels_mobile {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;

    width: 100% !important;
    height: auto !important;

    gap: 0.35rem !important;
  }

  .product_categories_mobile_scope .item_category_panel_mobile,
.collections_categories_scope .item_category_panel_mobile {
  width: 100% !important;
  flex-direction: column !important;
  align-items: center !important;
}

/* On ne force le flex que sur le panel actif */
.product_categories_mobile_scope .item_category_panel_mobile.is-active,
.product_categories_mobile_scope .item_category_panel_mobile.is-visible,
.collections_categories_scope .item_category_panel_mobile.is-active,
.collections_categories_scope .item_category_panel_mobile.is-visible {
  display: flex !important;
}
}
