/* Maison Drabiec Coiffure - responsive overrides. Loaded after the compiled theme. */
:root {
  --md-fluid-body: clamp(0.95rem, 0.9rem + 0.25vw, 1.08rem);
  --md-fluid-small: clamp(0.82rem, 0.78rem + 0.2vw, 0.95rem);
  --md-fluid-h1: clamp(1.45rem, 1.05rem + 1.7vw, 2.45rem);
  --md-fluid-h2: clamp(1.2rem, 1rem + 0.85vw, 1.75rem);
  --md-fluid-h3: clamp(1.05rem, 0.95rem + 0.5vw, 1.35rem);
  --md-touch: 44px;
}

html { font-size: 100%; }
body { font-size: var(--md-fluid-body); overflow-x: hidden; }
img, picture, svg, video { max-width: 100%; height: auto; }
.container, .container-md, .container-fluid { max-width: min(100% - 1.5rem, 1320px); }

h1, .h1, .product__name { font-size: var(--md-fluid-h1); line-height: 1.15; overflow-wrap: anywhere; }
h2, .h2, .accordion-button { font-size: var(--md-fluid-h2); line-height: 1.2; }
h3, .h3 { font-size: var(--md-fluid-h3); line-height: 1.25; }
.rich-text, .product__description, .product__description-short { font-size: var(--md-fluid-body); line-height: 1.62; }
.rich-text h2, .product__description h2 { font-size: var(--md-fluid-h2); }

.header-bottom__row { row-gap: 0.75rem; }
.header-bottom__logo img, .logo img { width: clamp(150px, 22vw, 280px); max-height: clamp(46px, 8vw, 82px); object-fit: contain; }
.header-block__action-btn, .btn, button, input, select, textarea { min-height: var(--md-touch); }

#search_widget, .search-widget, .ps_searchbar, .header-bottom .search-widget { width: min(100%, 32rem); }
#search_widget form, .search-widget form, .ps_searchbar form { width: 100%; }
#search_widget input, .search-widget input, .ps_searchbar input { width: 100%; font-size: var(--md-fluid-body); }

.header-nav-full-width, .header-bottom { overflow-x: clip; }
.header-nav-full-width .container, .header-nav-full-width .container-md { max-width: 100%; }
.top-menu, .menu, .navbar-nav { flex-wrap: wrap; gap: 0.25rem 0.75rem; }
.top-menu a, .menu a, .navbar-nav a { font-size: clamp(0.92rem, 0.84rem + 0.25vw, 1.08rem); line-height: 1.25; }

.products {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr));
  gap: clamp(0.75rem, 1.6vw, 1.5rem);
  align-items: stretch;
}
.product-miniature, .product-miniature__inner { min-width: 0; height: 100%; }
.product-miniature__inner { display: flex; flex-direction: column; }
.product-miniature__top { aspect-ratio: 1 / 1; display: grid; place-items: center; overflow: hidden; }
.product-miniature__top img, .product-miniature img { width: 100%; height: 100%; object-fit: contain; }
.product-miniature__bottom { display: flex; flex-direction: column; flex: 1; gap: 0.6rem; }
.product-miniature__title {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: calc(1.25em * 3);
  font-size: clamp(0.92rem, 0.84rem + 0.24vw, 1.05rem);
  line-height: 1.25;
  overflow-wrap: anywhere;
}
.product-miniature__price { font-size: clamp(1rem, 0.92rem + 0.35vw, 1.2rem); }
.product-miniature__actions { margin-top: auto; }
.product-miniature__form { display: flex; gap: 0.5rem; align-items: center; flex-wrap: wrap; }
.product-miniature__add, .product-miniature__details { flex: 1 1 10rem; white-space: normal; }
.product-miniature__add-text { display: inline; }

.product__container {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(20rem, 0.95fr);
  gap: clamp(1rem, 3vw, 3rem);
  align-items: start;
}
.product__left, .product__right, .product__bottom-left, .product__bottom-right { min-width: 0; }
.product__images, .product__carousel, .product__no-image { max-width: min(100%, 44rem); margin-inline: auto; }
.product__carousel .carousel-inner, .product__no-image { aspect-ratio: 1 / 1; }
.product__carousel .carousel-item, .product__carousel picture { height: 100%; }
.product__carousel img, .product__no-image img { width: 100%; height: 100%; object-fit: contain; }
.product__thumbnails-list { display: flex; gap: 0.5rem; overflow-x: auto; padding: 0.5rem 0; scroll-snap-type: x proximity; }
.product__thumbnail { flex: 0 0 clamp(54px, 10vw, 82px); scroll-snap-align: start; }
.product__bottom { display: grid; grid-template-columns: minmax(0, 1fr) minmax(16rem, 22rem); gap: clamp(1rem, 3vw, 2.5rem); }
.product__actions .btn, #add-to-cart-or-refresh .btn { white-space: normal; }

.cart-grid, .checkout-grid, .cart-overview, .cart-summary { min-width: 0; }
.cart-items, .cart-item, .cart-summary-line, .product-line-grid { overflow-wrap: anywhere; }

@media (max-width: 991.98px) {
  .product__container, .product__bottom { grid-template-columns: 1fr; }
  .product__right { order: 2; }
  .product__left { order: 1; }
  .product__bottom-right { order: -1; }
  .product__images, .product__carousel, .product__no-image { max-width: min(100%, 34rem); }
}

@media (max-width: 767.98px) {
  :root { --md-touch: 48px; }
  .container, .container-md, .container-fluid { max-width: min(100% - 1rem, 100%); padding-left: 0.5rem; padding-right: 0.5rem; }
  .header-bottom__row { align-items: center !important; }
  .header-bottom__logo { flex: 1 1 100%; justify-content: center; margin: 0 !important; }
  .header-bottom__logo img, .logo img { width: min(72vw, 230px); max-height: 64px; }
  .header-bottom .search-widget, #search_widget, .ps_searchbar { order: 5; flex: 1 1 100%; width: 100%; margin-top: 0.5rem; }
  .header-top { display: none !important; }
  .header-nav-full-width { padding-block: 0.45rem; }
  .top-menu, .menu, .navbar-nav { display: flex; overflow-x: auto; flex-wrap: nowrap; gap: 0.75rem; padding: 0.25rem 0.75rem; scrollbar-width: thin; }
  .top-menu > li, .menu > li, .navbar-nav > li { flex: 0 0 auto; }
  .products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; }
  .product-miniature__top { aspect-ratio: 1 / 1.08; }
  .product-miniature__title { -webkit-line-clamp: 4; min-height: calc(1.22em * 4); }
  .product-miniature__form { display: block; }
  .quantity-button { margin-bottom: 0.5rem; }
  .product-miniature__add, .product-miniature__details { width: 100%; }
  .product__name { margin-top: 0.5rem; }
  .product__description-short { font-size: 0.98rem; }
  .product-add-to-cart, .product__actions form, .product-quantity { width: 100%; }
  .product__actions .btn, #add-to-cart-or-refresh .btn { width: 100%; }
  .accordion-button { padding-inline: 0.75rem; }
  .accordion-body { padding-inline: 0.75rem; }
}

@media (max-width: 399.98px) {
  .products { grid-template-columns: 1fr; }
  .product-miniature__top { max-height: 72vw; }
  .top-menu a, .menu a, .navbar-nav a { font-size: 0.95rem; }
}

/* Mobile breadcrumb: keep long product names inside the viewport. */
.breadcrumb__wrapper { overflow-x: hidden; }
.breadcrumb { min-width: 0; flex-wrap: wrap; row-gap: 0.25rem; }
.breadcrumb-item { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.breadcrumb-item.active, .breadcrumb-item:last-child { flex: 1 1 100%; }

.table-responsive, .product-features, .tabs, .accordion { max-width: 100%; }
.table-responsive { overflow-x: auto; }

@media (max-width: 767.98px) {
  .breadcrumb { font-size: clamp(0.82rem, 0.76rem + 0.35vw, 0.95rem); padding-inline: 0.25rem; }
  .breadcrumb-item.active, .breadcrumb-item:last-child { line-height: 1.35; }
  .btn, button, input, select, textarea { max-width: 100%; }
}

/* Strong wrap for long breadcrumb labels on product pages. */
.breadcrumb-item:last-child,
.breadcrumb-item:last-child span,
.breadcrumb-item:last-child a {
  min-width: 0;
  max-width: 100%;
  white-space: normal !important;
  overflow-wrap: anywhere;
  word-break: break-word;
}
@media (max-width: 767.98px) {
  .breadcrumb-item:last-child {
    display: block;
    width: 100%;
    flex: 0 1 100%;
  }
}
