/* Danner child theme base 閳?global typography, header, footer, buttons, shop cards */
@font-face {
  font-family: 'DIN Danner';
  src: url('../fonts/din-400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'DIN Danner';
  src: url('../fonts/din-700.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'DIN Danner';
  src: url('../fonts/din-900.woff2') format('woff2');
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --dn-ink: #2b2a27;
  --dn-green: #19322f;
  --dn-snow: #f5f5f3;
  --dn-line: #e6e3dd;
  --dn-white: #ffffff;
  --dn-container: 1440px;
  --dn-radius: 10px;
}

body,
body.woocommerce,
body.woocommerce-page {
  font-family: 'DIN Danner', sans-serif;
  color: var(--dn-ink);
  font-size: 16px;
  line-height: 24px;
}

h1, h2, h3, h4, h5, h6,
.heading-font,
.woocommerce ul.products li.product .name,
.woocommerce div.product .product_title {
  font-family: 'DIN Danner', sans-serif;
  font-weight: 900;
  color: var(--dn-ink);
}

p, li, td, th, label, input, textarea, select, button {
  font-family: 'DIN Danner', sans-serif;
}

a { color: var(--dn-green); }

.dn-container {
  width: 100%;
  max-width: var(--dn-container);
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
  box-sizing: border-box;
}

.dn-module { position: relative; }

.dn-btn,
.dn-btn:visited {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 15px 30px;
  border-radius: 24px;
  background: var(--dn-green);
  color: #fff;
  font-size: 15px;
  font-weight: 900;
  line-height: 18px;
  letter-spacing: .5px;
  text-transform: uppercase;
  text-decoration: none;
  border: 0;
  cursor: pointer;
  transition: background-color .2s ease, color .2s ease, transform .2s ease;
}
.dn-btn:hover { background: #244a45; color: #fff; }
.dn-btn--light,
.dn-btn--light:visited { background: #fff; color: var(--dn-green); }
.dn-btn--light:hover { background: #f0efec; color: var(--dn-green); }
.dn-btn--outline,
.dn-btn--outline:visited { background: transparent; color: #fff; border: 2px solid #fff; }
.dn-btn--outline:hover { background: #fff; color: var(--dn-green); }

.dn-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 24px;
  margin-bottom: 32px;
}
.dn-section-head h2 {
  margin: 0;
  font-size: 36px;
  line-height: 44px;
  font-weight: 900;
}
.dn-text-link {
  white-space: nowrap;
  color: var(--dn-ink);
  font-size: 15px;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.dn-text-link:hover { color: var(--dn-green); }

/* Header: one row, white, logo left, nav centred, utilities right */
.header-top,
#top-bar {
  background: #f4f4f2 !important;
  color: var(--dn-ink);
  min-height: 56px;
}
#top-bar .html p,
#top-bar .nav > li > a,
#top-bar .nav > li > a:hover {
  color: var(--dn-ink) !important;
  font-size: 13px;
  line-height: 20px;
  font-weight: 400;
  letter-spacing: .2px;
}
#top-bar .flex-row { min-height: 56px; }

#masthead,
.header-main {
  background: #fff !important;
  color: var(--dn-ink);
  box-shadow: none;
}
.header-main .header-inner {
  min-height: 68px;
  max-width: 1440px;
  padding-left: 24px;
  padding-right: 24px;
}
.header-main .hide-for-medium.flex-left {
  display: flex;
  align-items: center;
  justify-content: center;
}
#logo img { max-height: 46px; width: auto; }
#logo a { color: var(--dn-ink); }
.header-main .header-nav > li > a,
.header-main .nav > li > a {
  color: var(--dn-ink);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .2px;
  text-transform: none;
}
.header-main .header-nav > li > a:hover,
.header-main .nav > li > a:hover { color: var(--dn-green); }
.header-main .nav-uppercase > li > a { text-transform: none; }
.header-main .header-nav-main { gap: 32px; }
.header-main .hide-for-medium.flex-left > ul { justify-content: center; }
.header-main .header-nav-main > li { margin: 0; }
.header-main .flex-right .header-nav-main { gap: 18px; }
.header-main .header-search a,
.header-main .account-item > a,
.header-main .cart-item > a { color: var(--dn-ink); }

/* Native menu dropdown typography */
.header-main .nav-dropdown { border-radius: 6px; border: 1px solid var(--dn-line); }
.header-main .nav-dropdown > li > a { font-size: 14px; }

/* Footer (Site Module Importer Footer 2) */
.footer-2,
.footer-secondary { font-family: 'DIN Danner', sans-serif; }
.footer-2 .widget p,
.footer-secondary .widget p,
.footer-2 .widget a,
.footer-secondary .widget a { font-size: 14px; line-height: 22px; }
.footer-2 .widget h3,
.footer-secondary .widget h3 { font-size: 15px; font-weight: 700; }

/* Uniform product cards on shop/category archives */
.woocommerce ul.products {
  display: grid !important;
  grid-template-columns: repeat(var(--dn-cols, 3), minmax(0, 1fr));
  gap: 24px;
  margin: 0 0 32px !important;
  padding: 0;
  list-style: none;
}
.woocommerce ul.products::before,
.woocommerce ul.products::after { display: none !important; }
.woocommerce ul.products li.product {
  width: auto !important;
  float: none !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex;
}
.woocommerce ul.products li.product .product-small.box {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  margin: 0;
  background: #fff;
  border: 1px solid var(--dn-line);
  border-radius: 8px;
  overflow: hidden;
  transition: box-shadow .2s ease, transform .2s ease;
}
.woocommerce ul.products li.product .product-small.box:hover {
  box-shadow: 0 10px 28px rgba(43,42,39,.10);
  transform: translateY(-2px);
}
.woocommerce ul.products li.product .box-image {
  width: 100% !important;
  height: auto !important;
  aspect-ratio: 1 / 1;
  padding-top: 0 !important;
  background: #f7f6f3;
  overflow: hidden;
}
.woocommerce ul.products li.product .box-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  margin: 0;
  padding: 14px;
  box-sizing: border-box;
}
.woocommerce ul.products li.product .box-text {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 14px 16px 16px;
  text-align: left;
}
.woocommerce ul.products li.product .name,
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  min-height: 44px;
  margin: 0 0 6px;
  font-size: 16px;
  line-height: 22px;
  font-weight: 700;
}
.woocommerce ul.products li.product .price {
  margin-top: auto;
  font-size: 15px;
  line-height: 22px;
  font-weight: 700;
  color: var(--dn-ink);
}
.woocommerce ul.products li.product .price del { color: #8b8984; font-weight: 400; }
.woocommerce ul.products li.product .price ins { text-decoration: none; color: var(--dn-ink); }

/* Flatsome sale badge */
.woocommerce ul.products li.product .badge-container .badge,
.woocommerce .badge-container .badge {
  background: var(--dn-ink);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  border-radius: 4px;
}

/* SMI shop archive grid: uniform cards */
.smi-shop-archive-products .products {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 0 !important;
}
.smi-shop-archive-products .products > .product-small {
  width: auto !important;
  max-width: none !important;
  flex: none !important;
  padding: 0 !important;
  margin: 0 !important;
  display: flex;
}
.smi-shop-archive-products .products > .product-small > .col-inner {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
}
.smi-shop-archive-products .product-small.box {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
  background: #fff;
  border: 1px solid var(--dn-line);
  border-radius: 8px;
  overflow: hidden;
}
.smi-shop-archive-products .box-image {
  position: relative;
  width: 100% !important;
  height: auto !important;
  aspect-ratio: 1 / 1;
  padding-top: 0 !important;
  background: #f7f6f3;
  overflow: hidden;
}
.smi-shop-archive-products .box-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 14px;
  box-sizing: border-box;
}
.smi-shop-archive-products .box-text {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  padding: 14px 16px 16px;
  text-align: left;
}
.smi-shop-archive-products .name {
  min-height: 44px;
  margin: 0 0 6px;
  font-size: 16px;
  line-height: 22px;
  font-weight: 700;
}
.smi-shop-archive-products .price {
  margin-top: auto;
  font-size: 15px;
  font-weight: 700;
}

/* Related products slider: same uniform card box as the shop grid */
.related-products-wrapper .product-small.col { display: flex; }
.related-products-wrapper .product-small > .col-inner { display: flex; flex-direction: column; width: 100%; height: 100%; }
.related-products-wrapper .product-small.box {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  background: #fff;
  border: 1px solid var(--dn-line);
  border-radius: 8px;
  overflow: hidden;
}
.related-products-wrapper .box-image {
  position: relative;
  width: 100% !important;
  height: auto !important;
  aspect-ratio: 1 / 1;
  padding-top: 0 !important;
  background: #f7f6f3;
  overflow: hidden;
}
.related-products-wrapper .box-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 14px;
  box-sizing: border-box;
}
.related-products-wrapper .box-text {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  padding: 14px 16px 16px;
  text-align: left;
}
.related-products-wrapper .name { min-height: 44px; margin: 0 0 6px; font-size: 16px; line-height: 22px; font-weight: 700; }
.related-products-wrapper .price { margin-top: auto; font-size: 15px; font-weight: 700; }

/* Category archive uses the same div-based product grid as the Shop page */
.shop-container .products {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 0 !important;
}
.shop-container .products > .product-small {
  width: auto !important;
  max-width: none !important;
  flex: none !important;
  padding: 0 !important;
  margin: 0 !important;
  display: flex;
}
.shop-container .products > .product-small > .col-inner {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
}
.shop-container .product-small.box {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
  background: #fff;
  border: 1px solid var(--dn-line);
  border-radius: 8px;
  overflow: hidden;
}
.shop-container .box-image {
  position: relative;
  width: 100% !important;
  height: auto !important;
  aspect-ratio: 1 / 1;
  padding-top: 0 !important;
  background: #f7f6f3;
  overflow: hidden;
}
.shop-container .box-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 14px;
  box-sizing: border-box;
}
.shop-container .box-text {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  padding: 14px 16px 16px;
  text-align: left;
}
.shop-container .name {
  min-height: 44px;
  margin: 0 0 6px;
  font-size: 16px;
  line-height: 22px;
  font-weight: 700;
}
.shop-container .price {
  margin-top: auto;
  font-size: 15px;
  font-weight: 700;
}

@media (max-width: 849px) {
  .smi-shop-archive-products .image-tools,
  .shop-container .image-tools,
  .related-products-wrapper .image-tools,
  .woocommerce ul.products .image-tools,
  .smi-shop-archive-products .box-image .image-tools,
  .shop-container .box-image .image-tools,
  .related-products-wrapper .box-image .image-tools,
  .woocommerce ul.products .box-image .image-tools { display: none !important; }
}

/* Product detail gallery: one fixed stage so front/sole photos cannot grow */
body.single-product .product-gallery-slider .flickity-viewport {
  height: 480px !important;
  max-height: 480px !important;
}
body.single-product .product-gallery-slider .flickity-slider,
body.single-product .product-gallery-slider .slide {
  height: 100% !important;
}
body.single-product .product-gallery-slider .slide {
  display: flex;
  align-items: center;
  justify-content: center;
}
body.single-product .product-gallery-slider .slide > a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}
body.single-product .product-gallery-slider .slide img {
  width: 100% !important;
  height: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  object-position: center;
}
@media (max-width: 849px) {
  body.single-product .product-gallery-slider .flickity-viewport {
    height: 340px !important;
    max-height: 340px !important;
  }
}

/* Quick View: one stable gallery height, images contained instead of overflowing */
.mfp-content .product-lightbox,
.mfp-content .product-quick-view-container { max-height: 88vh; }
.mfp-content .product-quick-view-container .product-gallery-slider .flickity-viewport {
  height: 440px !important;
  max-height: 52vh !important;
}
.mfp-content .product-quick-view-container .product-gallery-slider .flickity-slider,
.mfp-content .product-quick-view-container .product-gallery-slider .slide {
  height: 100% !important;
}
.mfp-content .product-quick-view-container .product-gallery-slider .slide {
  display: flex;
  align-items: center;
  justify-content: center;
}
.mfp-content .product-quick-view-container .product-gallery-slider img {
  width: 100% !important;
  height: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  object-position: center;
}
@media (max-width: 849px) {
  .mfp-content .product-quick-view-container .product-gallery-slider .flickity-viewport {
    height: 280px !important;
    max-height: 42vh !important;
  }
}

/* Product actions use the Danner green, never the old blue target colour */
.single_add_to_cart_button.button,
button.single_add_to_cart_button,
body.single-product .single_add_to_cart_button.button,
html body.single-product button.single_add_to_cart_button,
html body.single-product .single_add_to_cart_button.button,
html body.single-product .product-buy-now-button,
html body.single-product .button.buy-now,
.product-buy-now-button,
.button#place_order,
.checkout-button,
.woocommerce-checkout .button,
.woocommerce-cart .button {
  background-color: #19322f !important;
  border-color: #19322f !important;
  color: #fff !important;
}
.single_add_to_cart_button.button:hover,
.product-buy-now-button:hover,
.button#place_order:hover {
  background-color: #244a45 !important;
  border-color: #244a45 !important;
}

/* Flatsome sale badge: always black with white text, no blue sale bubble */
.badge-inner.on-sale,
.badge-inner.secondary,
.badge-container .badge-inner.on-sale {
  background-color: #2b2a27 !important;
  color: #fff !important;
  border: 0 !important;
}
.badge-container .badge-inner .onsale,
.badge-container .onsale { color: #fff !important; }

/* Shop layout */
.dn-shop-row { align-items: flex-start; }
.dn-shop-sidebar-col { position: relative; }
@media (max-width: 849px) {
  .woocommerce ul.products { --dn-cols: 2 !important; gap: 14px; }
  .smi-shop-archive-products .products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .smi-shop-archive-products .box-text { padding: 10px 10px 12px; }
  .smi-shop-archive-products .name { min-height: 40px; font-size: 14px; line-height: 20px; }
  .smi-shop-archive-products .price { font-size: 14px; }
}

/* Mobile header: menu left, logo left, cart right */
@media (max-width: 849px) {
  #top-bar,
  #top-bar .flex-row { min-height: 42px; }
  #top-bar .html p { font-size: 12px; line-height: 18px; }
  .header-main .header-inner {
    min-height: 58px;
    justify-content: flex-start;
    padding-left: 16px;
    padding-right: 16px;
    position: relative;
    display: flex;
    align-items: center;
  }
  .header-main .header-inner.medium-logo-center #logo {
    position: absolute !important;
    left: 54px;
    top: 50%;
    transform: translateY(-50%) !important;
    order: 1;
    width: 92px;
    margin: 0 !important;
  }
  #logo img { max-height: 36px; max-width: 92px; }
  .header-main .show-for-medium.flex-left {
    order: 0;
    flex: 0 0 auto;
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
  }
  .header-main .show-for-medium.flex-right {
    order: 2;
    flex: 0 0 auto;
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
  }
  .header-main .flex-right .mobile-nav { display: flex; }
}



