/* Caggiati WooCommerce — catalog / product cards like caggiatiby.by */

body.woocommerce,
body.woocommerce-page {
  background: #fff;
  color: #212121;
}

/* Hide default Woo archive title (we render our own) */
body.post-type-archive-product .woocommerce-products-header,
body.tax-product_cat .woocommerce-products-header,
body.tax-product_cat .woocommerce-products-header__title,
body.post-type-archive-product .woocommerce-products-header__title {
  display: none !important;
}

/* Breadcrumbs — same as Elementor WooCommerce breadcrumb (Главная / …) */
body.woocommerce .cag-woo-breadcrumbs,
body.woocommerce-page .cag-woo-breadcrumbs {
  text-align: center;
  padding: 40px 15px !important;
  background: transparent;
}
body.woocommerce .cag-woo-breadcrumbs .woocommerce-breadcrumb,
body.woocommerce-page .cag-woo-breadcrumbs .woocommerce-breadcrumb {
  font-size: 12px;
  line-height: 1.5;
  color: #666;
  text-align: center;
  margin: 0 0 1rem;
  padding: 0;
  background: transparent;
  font-family: Montserrat, Raleway, "Open Sans", Arial, sans-serif;
}
body.woocommerce .cag-woo-breadcrumbs .woocommerce-breadcrumb a,
body.woocommerce-page .cag-woo-breadcrumbs .woocommerce-breadcrumb a {
  color: #f15c22;
  text-decoration: none;
  font-family: Montserrat, Raleway, "Open Sans", Arial, sans-serif;

}
body.woocommerce .cag-woo-breadcrumbs .woocommerce-breadcrumb a:hover,
body.woocommerce-page .cag-woo-breadcrumbs .woocommerce-breadcrumb a:hover {
  color: #d3450d;
}
body.woocommerce .cag-woo-title {
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif !important;
  font-weight: 700 !important;
  font-size: 1.75rem !important;
  text-transform: uppercase;
  text-align: center;
  margin: 0;
  color: #212121;
}

/* Layout: sidebar + products */
body.woocommerce .cag-woo-layout {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  max-width: 1140px;
  margin: 0 auto 100px;
  padding: 0 15px;
  align-items: flex-start;
}
body.woocommerce .cag-woo-sidebar {
  width: 100%;
  max-width: 260px;
  flex: 0 0 260px;
}
body.woocommerce .cag-woo-sidebar-title {
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  text-transform: uppercase;
  margin: 0 0 1rem;
  color: #212121;
}
body.woocommerce .cag-woo-cat-nav {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  text-align: left;
}
body.woocommerce .cag-woo-cat-nav .nav-item {
  border-bottom: 1px solid #ececec;
  color: #909090;
}
body.woocommerce .cag-woo-cat-nav .nav-item a {
  display: block;
  padding: 12px 2px;
  font-family: Raleway, "Open Sans", sans-serif;
  font-size: 1.15rem;
  font-weight: 400;
  text-transform: none;
  text-decoration: none;
  color: #909090;
}
body.woocommerce .cag-woo-cat-nav .nav-item.active a,
body.woocommerce .cag-woo-cat-nav .nav-item a:hover {
  color: #212121 !important;
}
body.woocommerce .cag-woo-products {
  flex: 1 1 0;
  min-width: 0;
}

/* Product grid cards — .product-wrap look */
body.woocommerce ul.products {
  display: flex !important;
  flex-wrap: wrap;
  margin: 0 -10px !important;
  padding: 0 !important;
  list-style: none;
  clear: both;
}
body.woocommerce ul.products::before,
body.woocommerce ul.products::after {
  display: none !important;
}
body.woocommerce ul.products li.product {
  width: 33.333% !important;
  max-width: 33.333% !important;
  float: none !important;
  margin: 0 0 30px !important;
  padding: 0 10px !important;
  clear: none !important;
  position: relative;
}
body.woocommerce ul.products li.product .woocommerce-loop-product__link,
body.woocommerce ul.products li.product > a:first-child {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 50px 17px 15px;
  background: #fff;
  border: 1px solid transparent;
  text-decoration: none;
  text-align: center;
  box-sizing: border-box;
  transition: border-color 0.2s ease;
}
/* Card shell when button is sibling */
body.woocommerce ul.products li.product {
  display: flex;
  flex-direction: column;
}
body.woocommerce ul.products li.product .cag-product-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 50px 17px 15px;
  background: #fff;
  border: 1px solid transparent;
  text-align: center;
  box-sizing: border-box;
  transition: border-color 0.2s ease;
}
body.woocommerce ul.products li.product:hover .woocommerce-loop-product__link,
body.woocommerce ul.products li.product:hover {
  /* hover on whole li border via inner */
}
body.woocommerce ul.products.columns-3 li.product:hover > .woocommerce-loop-product__link,
body.woocommerce ul.products li.product:hover > a.woocommerce-loop-product__link {
  border-color: #f15c22;
}

/* Rebuild card as one bordered block including button */
body.woocommerce ul.products li.product {
  background: #fff;
  border: 1px solid transparent;
  padding: 50px 17px 15px !important;
  margin: 0 0 30px !important;
  width: calc(33.333% - 20px) !important;
  max-width: calc(33.333% - 20px) !important;
  margin-left: 10px !important;
  margin-right: 10px !important;
  box-sizing: border-box;
  transition: border-color 0.2s ease;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}
body.woocommerce ul.products li.product:hover {
  border-color: #f15c22;
}
body.woocommerce ul.products li.product .woocommerce-loop-product__link {
  display: block;
  width: 100%;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  text-decoration: none;
  color: inherit;
}
body.woocommerce ul.products li.product img {
  margin: 0 auto 40px;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 220px;
  object-fit: contain;
}
body.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif !important;
  font-size: 1.15rem !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  margin: auto 0 30px !important;
  padding: 0 !important;
  color: #212121 !important;
  text-align: center;
}
body.woocommerce ul.products li.product .star-rating,
body.woocommerce ul.products li.product .onsale {
  display: none !important;
}

/* Request button — btn-outline-primary */
body.woocommerce ul.products li.product .button,
body.woocommerce ul.products li.product .cag-product-request,
body.woocommerce ul.products li.product a.button {
  display: inline-block !important;
  margin-top: auto !important;
  margin-bottom: 0 !important;
  padding: 12px 22px !important;
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif !important;
  font-size: 1.3rem !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  color: #f15c22 !important;
  background: transparent !important;
  background-image: none !important;
  border: 1px solid #f15c22 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  width: auto !important;
}
body.woocommerce ul.products li.product .button:hover,
body.woocommerce ul.products li.product .cag-product-request:hover {
  color: #fff !important;
  background: #f15c22 !important;
  border-color: #f15c22 !important;
}

/* Pagination */
body.woocommerce nav.woocommerce-pagination ul {
  border: 0 !important;
}
body.woocommerce nav.woocommerce-pagination ul li {
  border: 0 !important;
}
body.woocommerce nav.woocommerce-pagination ul li a,
body.woocommerce nav.woocommerce-pagination ul li span {
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif;
  min-width: 42px;
  padding: 10px 14px !important;
  border: 1px solid #ececec !important;
  color: #212121 !important;
  background: #fff !important;
}
body.woocommerce nav.woocommerce-pagination ul li a:hover,
body.woocommerce nav.woocommerce-pagination ul li span.current {
  border-color: #f15c22 !important;
  color: #f15c22 !important;
  background: #fff !important;
}

/* ========== Single product ========== */
body.single-product {
  background: #fafafa;
}

body.single-product .site-main,
body.single-product #content {
  background: transparent;
}

body.single-product .cag-woo-breadcrumbs {
  margin-bottom: 0;
  padding: 40px 15px !important;
}

body.single-product div.product {
  max-width: 1140px;
  margin: 0 auto 80px;
  padding: 0 15px 40px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas:
    "gallery summary"
    "tabs tabs"
    "related related";
  gap: 48px 56px;
  align-items: start;
}

body.single-product div.product .woocommerce-product-gallery {
  grid-area: gallery;
  float: none !important;
  width: auto !important;
  margin: 0;
  background: #f0f0f0;
  padding: 28px 24px;
  min-height: 460px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

body.single-product div.product .woocommerce-product-gallery__wrapper,
body.single-product div.product .woocommerce-product-gallery__image {
  width: 100%;
  text-align: center;
}

body.single-product div.product .woocommerce-product-gallery img {
  width: auto !important;
  max-width: 100%;
  max-height: 420px;
  margin: 0 auto;
  border: 0;
  box-shadow: none;
  object-fit: contain;
}

body.single-product div.product .woocommerce-product-gallery__trigger {
  top: 16px;
  right: 16px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #fff !important;
  border: 1px solid #e5e5e5;
  color: #666 !important;
  text-indent: -9999px;
  overflow: hidden;
}

body.single-product div.product .summary.entry-summary {
  grid-area: summary;
  float: none !important;
  width: auto !important;
  margin: 0;
  padding: 8px 0 0;
}

body.single-product div.product .product_title {
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif !important;
  font-weight: 700 !important;
  font-size: 2.25rem !important;
  line-height: 1.15 !important;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin: 0 0 1rem;
  color: #212121;
}

body.single-product div.product .price {
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif;
  color: #f15c22 !important;
  font-size: 1.75rem;
  font-weight: 700;
  margin: 0 0 0.75rem;
  line-height: 1.2;
}

body.single-product div.product .woocommerce-product-details__short-description {
  font-family: Raleway, "Open Sans", sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  color: #555;
  margin-bottom: 1.5rem;
}

body.single-product div.product table.variations {
  width: 100%;
  margin: 0 0 1.5rem;
  border: 0;
  border-collapse: separate;
  border-spacing: 0;
  background: #fff;
  border: 1px solid #ececec;
}

body.single-product div.product table.variations tr + tr th,
body.single-product div.product table.variations tr + tr td {
  border-top: 1px solid #ececec;
}

body.single-product div.product table.variations th,
body.single-product div.product table.variations td {
  padding: 14px 18px;
  vertical-align: middle;
}

body.single-product div.product table.variations th.label {
  width: 38%;
  font-family: Raleway, "Open Sans", sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  color: #212121;
  text-align: left;
}

body.single-product div.product table.variations td.value {
  text-align: left;
}

body.single-product div.product table.variations select {
  width: 100%;
  max-width: 100%;
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid #ddd;
  border-radius: 0;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23666' d='M1.41 0 6 4.58 10.59 0 12 1.41l-6 6-6-6z'/%3E%3C/svg%3E") no-repeat right 14px center;
  padding: 11px 40px 11px 14px;
  font-family: Raleway, "Open Sans", sans-serif;
  font-size: 0.95rem;
  color: #212121;
  line-height: 1.4;
}

body.single-product div.product table.variations .reset_variations {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.85rem;
  color: #909090 !important;
  text-decoration: underline;
}

/* Simple products only — flex on variations_form breaks attribute selects. */
body.single-product div.product form.cart:not(.variations_form) {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 0;
  margin: 0 0 1.5rem;
  padding-top: 0.25rem;
}

body.single-product div.product form.variations_form {
  display: block;
  margin: 0 0 1.5rem;
}

body.single-product div.product .woocommerce-variation-add-to-cart {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  margin-top: 1rem;
}

body.single-product div.product form.cart .quantity {
  display: none !important;
}

body.single-product div.product .cart .button,
body.single-product div.product .single_add_to_cart_button {
  flex: 1 1 auto;
  width: 100%;
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif !important;
  font-size: 1.25rem !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.04em;
  color: #f15c22 !important;
  background: transparent !important;
  border: 1px solid #f15c22 !important;
  border-radius: 0 !important;
  padding: 16px 32px !important;
  box-shadow: none !important;
  transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

body.single-product div.product .cart .button:hover,
body.single-product div.product .single_add_to_cart_button:hover {
  color: #fff !important;
  background: #f15c22 !important;
  border-color: #f15c22 !important;
}

body.single-product div.product .cag-product-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin: 0 0 1.5rem;
  padding: 0;
  border: 0;
  font-family: Raleway, "Open Sans", sans-serif;
  font-size: 0.9rem;
  color: #666;
}

body.single-product div.product .cag-product-meta__label {
  color: #909090;
}

body.single-product div.product .cag-product-meta a {
  color: #f15c22;
  text-decoration: none;
}

body.single-product div.product .cag-product-meta a:hover {
  text-decoration: underline;
}

/* Inscription calculator on letter products */
body.single-product div.product .caggiati-calc-anchor {
  width: 100%;
  margin: 0 0 2rem;
}

body.single-product div.product .caggiati-calc--product {
  margin-top: 0.5rem;
}

body.single-product div.product .caggiati-calc__product-letter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  align-items: baseline;
  margin: 0 0 1rem;
  font-family: Raleway, "Open Sans", sans-serif;
  font-size: 0.95rem;
  color: #666;
}

body.single-product div.product .caggiati-calc__product-letter-label {
  color: #909090;
}

body.single-product div.product .caggiati-calc__product-letter-value {
  font-weight: 600;
  color: #333;
}

body.single-product.cag-has-letter-calc div.product form.cart {
  display: none !important;
}

body.single-product.cag-has-letter-calc div.product .woocommerce-tabs,
body.single-product.cag-has-letter-calc .wp-block-woocommerce-product-details {
  display: none !important;
}

body.single-product div.product .woocommerce-tabs {
  grid-area: tabs;
  float: none !important;
  width: 100% !important;
  margin: 0;
  padding: 32px 36px;
  background: #fff;
  border: 1px solid #ececec;
  box-sizing: border-box;
}

body.single-product .woocommerce-tabs ul.tabs {
  padding: 0 !important;
  margin: 0 0 24px !important;
  border-bottom: 1px solid #ececec !important;
  display: flex;
  flex-wrap: wrap;
  gap: 0 28px;
}

body.single-product .woocommerce-tabs ul.tabs::before {
  display: none !important;
}

body.single-product .woocommerce-tabs ul.tabs li {
  border: 0 !important;
  background: transparent !important;
  border-radius: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  position: relative;
}

body.single-product .woocommerce-tabs ul.tabs li::before,
body.single-product .woocommerce-tabs ul.tabs li::after {
  display: none !important;
}

body.single-product .woocommerce-tabs ul.tabs li a {
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif;
  text-transform: uppercase;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.04em;
  color: #909090 !important;
  padding: 0 0 14px !important;
  display: inline-block;
  position: relative;
}

body.single-product .woocommerce-tabs ul.tabs li.active a {
  color: #f15c22 !important;
}

body.single-product .woocommerce-tabs ul.tabs li.active a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: #f15c22;
}

body.single-product .woocommerce-tabs .panel {
  margin: 0;
  padding: 0;
  font-family: Raleway, "Open Sans", sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  color: #444;
}

body.single-product .woocommerce-tabs .panel h2 {
  display: none;
}

body.single-product .woocommerce-tabs table.shop_attributes {
  width: 100%;
  border: 0;
  border-collapse: collapse;
  margin: 0;
}

body.single-product .woocommerce-tabs table.shop_attributes th,
body.single-product .woocommerce-tabs table.shop_attributes td {
  border: 1px solid #ececec;
  padding: 14px 18px;
  font-style: normal;
  background: #fafafa;
}

body.single-product .woocommerce-tabs table.shop_attributes th {
  width: 34%;
  font-weight: 600;
  color: #212121;
}

body.single-product .woocommerce-tabs table.shop_attributes td {
  background: #fff;
}

body.single-product div.product .related.products {
  grid-area: related;
  float: none !important;
  width: 100% !important;
  margin: 0;
  padding-top: 8px;
}

body.single-product div.product .related.products > h2 {
  font-family: "OpenSansCondensed", "Open Sans Condensed", sans-serif !important;
  font-size: 1.75rem !important;
  font-weight: 700 !important;
  text-transform: uppercase;
  text-align: center;
  margin: 0 0 2rem;
  color: #212121;
}

body.single-product div.product .related.products ul.products {
  margin: 0 -10px !important;
  display: flex !important;
  flex-wrap: wrap !important;
}

body.single-product div.product .related.products ul.products li.product {
  width: calc(25% - 20px) !important;
  max-width: calc(25% - 20px) !important;
}

@media (max-width: 991px) {
  body.single-product div.product {
    grid-template-columns: 1fr;
    grid-template-areas:
      "gallery"
      "summary"
      "tabs"
      "related";
    gap: 32px;
  }

  body.single-product div.product .woocommerce-product-gallery {
    min-height: 320px;
    padding: 32px 24px;
  }

  body.single-product div.product .product_title {
    font-size: 1.85rem !important;
  }

  body.single-product div.product .woocommerce-tabs {
    padding: 24px 20px;
  }

  body.single-product div.product .related.products ul.products li.product {
    width: calc(50% - 20px) !important;
    max-width: calc(50% - 20px) !important;
  }
}

@media (max-width: 575px) {
  body.single-product div.product .woocommerce-product-gallery {
    min-height: 260px;
    padding: 24px 16px;
  }

  body.single-product div.product .woocommerce-product-gallery img {
    max-height: 240px;
  }

  body.single-product div.product .product_title {
    font-size: 1.55rem !important;
  }

  body.single-product div.product .price {
    font-size: 1.45rem;
  }

  body.single-product div.product .related.products ul.products li.product {
    width: calc(100% - 20px) !important;
    max-width: calc(100% - 20px) !important;
  }
}

@media (max-width: 991px) {
  body.woocommerce .cag-woo-layout {
    flex-direction: column;
  }
  body.woocommerce .cag-woo-sidebar {
    max-width: 100%;
    flex: 1 1 auto;
  }
  body.woocommerce ul.products li.product {
    width: calc(50% - 20px) !important;
    max-width: calc(50% - 20px) !important;
  }
}
@media (max-width: 575px) {
  body.woocommerce ul.products li.product {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}

/* Avoid duplicate archive titles from theme/Woo wrappers */
body.tax-product_cat .page-header,
body.post-type-archive-product .page-header,
body.tax-product_cat h1.page-title,
body.post-type-archive-product h1.page-title {
  display: none !important;
}
body.woocommerce ul.products li.product .screen-reader-text {
  position: absolute !important;
  height: 1px; width: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px);
}

/* Checkout: request form only (name, phone, comment). */
body.woocommerce-checkout .woocommerce-additional-fields,
body.woocommerce-checkout .wc_payment_methods,
body.woocommerce-checkout .woocommerce-terms-and-conditions-wrapper,
body.woocommerce-checkout .woocommerce-shipping-fields,
body.woocommerce-checkout .woocommerce-shipping-totals,
body.woocommerce-checkout .shipping,
body.woocommerce-checkout #ship-to-different-address,
body.woocommerce-checkout .woocommerce-additional-fields > h3 {
  display: none !important;
}

body.woocommerce-checkout #payment {
  background: transparent;
  border: 0;
  padding: 0;
  margin-top: 1.5rem;
}

body.woocommerce-checkout #payment .place-order {
  margin: 0;
  padding: 0;
  float: none;
  width: 100%;
}

body.woocommerce-checkout form.checkout .col2-set {
  width: 100%;
  float: none;
}

body.woocommerce-checkout form.checkout #order_review_heading,
body.woocommerce-checkout form.checkout #order_review {
  width: 100%;
  float: none;
  margin-top: 1.5rem;
}

body.woocommerce-checkout .woocommerce-billing-fields h3 {
  font-family: "Open Sans Condensed", "Arial Narrow", sans-serif;
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

body.woocommerce-checkout .woocommerce form .form-row input.input-text,
body.woocommerce-checkout .woocommerce form .form-row textarea {
  border: 1px solid #ccc;
  border-radius: 0;
  padding: 0.65rem 0.75rem;
}

body.woocommerce-checkout #place_order {
  background: transparent !important;
  color: #333 !important;
  border: 1px solid #333 !important;
  border-radius: 0 !important;
  font-weight: 600;
  text-transform: none;
  padding: 0.75rem 2rem;
}

body.woocommerce-checkout #place_order:hover {
  background: #333 !important;
  color: #fff !important;
}
