.cwqr-product-quote-block {
  margin-top: 12px;
}

.single-product form.cart .cwqr-product-quote-block,
.woocommerce div.product form.cart .cwqr-product-quote-block {
  display: inline-flex;
  flex-direction: column;
  vertical-align: top;
  margin-top: 0;
  margin-left: 12px;
  width: auto;
  max-width: 100%;
}

#section-cart-product-page .content-add-to-cart .cwqr-product-quote-block {
  float: left;
  width: calc(100% - 360px);
  margin-top: 0 !important;
  margin-left: 12px;
  display: block;
  position: relative;
}

#section-cart-product-page .content-add-to-cart .woocommerce-variation-add-to-cart .cwqr-add-to-quote-button,
.woocommerce #section-cart-product-page .cwqr-add-to-quote-button.button {
  background-color: #ffffff !important;
  color: var(--main-color) !important;
  font-size: 18px !important;
  text-align: center;
  font-weight: 500;
  padding: 0.3em 1em;
  line-height: 1.7em !important;
  width: 100%;
}

#section-cart-product-page .content-add-to-cart .cwqr-inline-message {
  width: 350px;
  max-width: 70%;
  line-height: 15px;
  padding-top: 5px;
  display: none;
}

.single-product form.cart .cwqr-button,
.woocommerce div.product form.cart .cwqr-button {
  white-space: nowrap;
}

.cwqr-button.is-disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.cwqr-inline-message {
  margin-top: 8px;
  font-size: 14px;
  line-height: 1.4;
}

.cwqr-inline-message.is-success {
  color: #1f6c40;
}

.cwqr-inline-message.is-error {
  color: #a51d1d;
}

.cwqr-toast-stack {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 999999999999999999 !important;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.cwqr-toast {
  min-width: 260px;
  max-width: 360px;
  padding: 14px 16px;
  border-radius: 14px;
  color: #fff;
  box-shadow: 0 12px 28px rgba(17, 24, 39, 0.18);
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 0.24s ease, transform 0.24s ease;
}

.cwqr-toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.cwqr-toast.is-success {
  background: #1f6c40;
}

.cwqr-toast.is-error {
  background: #a51d1d;
}

.swal2-container.cwqr-swal-container {
  z-index: 999999999999999999 !important;
}

.swal2-container.cwqr-swal-container.swal2-top-end,
.swal2-container.cwqr-swal-container.swal2-top-right {
  padding-top: 18px;
  padding-right: 18px;
}

.swal2-popup.cwqr-swal-popup.swal2-toast {
  box-shadow: 0 14px 32px rgba(17, 24, 39, 0.22) !important;
}

.swal2-styled.cwqr-swal-button {
  border-radius: 999px !important;
  background: #ffffff !important;
  color: var(--main-color, #111827) !important;
  border: 1px solid rgba(17, 24, 39, 0.12) !important;
  font-weight: 700 !important;
  box-shadow: none !important;
}

.cwqr-quote-request {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  margin-top: 25px;
}

.cwqr-empty-state {
  padding: 22px;
  border: 1px dashed #d7cdbd;
  border-radius: 14px;
  background: #fff;
  color: #63584d;
}

.cwqr-empty-message {
  margin-bottom: 14px;
}

.cwqr-empty-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  background: #1f1f1f;
  color: #fff;
  text-decoration: none;
}

.cwqr-empty-link:hover {
  color: #fff;
  opacity: 0.92;
}

.cwqr-table-wrap {
  overflow-x: auto;
  border: 1px solid #eee7dc;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(17, 24, 39, 0.05);
}

.cwqr-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 0 !important;
  margin: 0 !important;
}

.cwqr-table th,
.cwqr-table td {
  padding: 18px 15px!important;
  text-align: left;
  vertical-align: middle;
  border: 0 !important;
  box-shadow: none !important;
}

.cwqr-table thead th {
  background: var(--main-color, #111111) !important;
  color: #ffffff !important;
  font-weight: 700;
  border: 0 !important;
  padding: 15px 16px;
}

.cwqr-table thead th:first-child {
  width: 58px;
  padding-left: 12px;
}

.cwqr-table thead th:nth-child(2) {
  width: 110px;
}

.cwqr-table thead th:last-child {
  width: 130px;
  text-align: center;
}

.cwqr-table tbody td {
  border-bottom: 1px solid #f0ebe3 !important;
}

.cwqr-table tbody tr:last-child td {
  border-bottom: 0 !important;
}

.cwqr-col-remove,
.cwqr-col-image {
  text-align: center !important;
}

.cwqr-col-remove {
  width: 58px;
  padding-left: 12px !important;
  padding-right: 8px !important;
}

.cwqr-col-image {
  width: 110px;
  padding-left: 8px !important;
  padding-right: 8px !important;
}

.cwqr-col-product {
  min-width: 260px;
  font-weight: 600;
  background: transparent !important;
  padding-left: 8px !important;
}

.cwqr-item-visual {
  width: 95px;
  margin: 0 auto;
}

.cwqr-item-image {
  display: block;
  width: 95px;
  height: 95px;
  object-fit: contain;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
}

.cwqr-item-content {
  min-width: 0;
  flex: 1 1 auto;
}

.cwqr-item-name {
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--main-color, #111111);
  font-size: 18px;
  line-height: 1.35;
}

.cwqr-item-name a {
  color: var(--main-color, #111111);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.cwqr-item-name a:hover {
  opacity: 0.85;
}

.cwqr-item-meta {
  margin-top: 6px;
  font-size: 14px;
  color: #6b6256;
  line-height: 1.45;
}

.cwqr-item-meta strong {
  color: #3a3229;
}

.cwqr-item-discount-badge {
  display: inline-flex;
  align-items: center;
  margin-top: 10px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #efe4c7;
  color: var(--main-color, #111111);
  font-size: 12px;
  line-height: 1.2;
  font-weight: 600;
}

.cwqr-price-stack {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
}

.cwqr-price-old {
  color: #8d8274;
  font-size: 13px;
  line-height: 1.2;
  text-decoration: line-through;
}

.cwqr-price-current {
  color: var(--main-color, #111111);
  font-weight: 700;
  line-height: 1.25;
}

.cwqr-table tbody tr:nth-child(odd) {
  background: #ffffff;
}

.cwqr-table tbody tr:nth-child(even) {
  background: #fffdf9;
}

.cwqr-qty-input {
  width: 44px!important;
  min-height: 30px!important;;
  height: 30px!important;;
  padding: 4px 6px!important;;
  border: 1px solid #d7d7d7;
  border-radius: 8px;
  background: #f3f3f3;
  text-align: center;
  font-weight: 600;
  color: var(--main-color, #111111);
  box-shadow: none;
}

.cwqr-qty-input::-webkit-outer-spin-button,
.cwqr-qty-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.cwqr-qty-input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

.cwqr-qty-control {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.cwqr-qty-button {
  width: 30px;
  height: 30px;
  min-width: 30px;
  padding: 0;
  border: 1px solid #e5e0d8;
  border-radius: 50%;
  background: #ffffff;
  color: var(--main-color, #111111);
  font-size: 18px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.cwqr-qty-button:hover {
  background: #f5f5f5;
}

.cwqr-remove-line,
.cwqr-clear-quote,
.cwqr-continue-shopping,
.cwqr-scroll-form,
.cwqr-action-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 999px;
  padding: 0 18px;
  border: 1px solid #d9d9d9;
  background: #fff;
  color: #1f1f1f;
  cursor: pointer;
  text-decoration: none;
}

.cwqr-remove-line {
  width: 34px;
  min-width: 34px;
  min-height: 34px;
  height: 34px;
  padding: 0;
  border-radius: 50%;
  border-color: #ff0000;
  background: #ff0000;
  color: #ffffff;
  font-size: 0;
  line-height: 1;
}

.cwqr-remove-line::before {
  content: "\00d7";
  font-family: inherit;
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
}

.cwqr-clear-quote {
  background: #1f1f1f;
  color: #fff;
  border-color: #1f1f1f;
}

.cwqr-action-link {
  gap: 8px;
}

.cwqr-scroll-form::after,
.cwqr-continue-shopping::after {
  content: "\42";
  font-family: "ETmodules", sans-serif;
  font-size: 18px;
  line-height: 1;
}

.cwqr-quote-actions {
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  gap: 12px;
  margin-top: 20px;
  overflow-x: auto;
  padding-bottom: 2px;
  -webkit-overflow-scrolling: touch;
}

.cwqr-quote-form {
  margin-top: 28px;
}

.cwqr-table tfoot th,
.cwqr-table tfoot td {
  border: 0 !important;
  padding: 16px;
}

.cwqr-table tfoot th {
  background: #525252 !important;
  color: #ffffff !important;
  font-weight: 700;
  border-top: 1px solid rgba(255, 255, 255, 0.18) !important;
}

body .cwqr-table tfoot td {
  background: #ffffff;
  font-weight: 700;
  color: var(--main-color, #111111);
  border-top: 1px solid rgba(0, 0, 0, 0.18) !important;
}

.cwqr-table tfoot tr:last-child td {
  font-size: 24px;
  line-height: 24px;
}

.cwqr-quote-form[hidden],
.cwqr-quote-form.is-disabled {
  display: none !important;
}

.cwqr-form-note {
  margin-top: 24px;
  padding: 16px 18px;
  border-radius: 12px;
  background: #fff7e7;
  color: #6b4c14;
}

@media (max-width: 980px) {
  #section-cart-product-page .content-add-to-cart .cwqr-product-quote-block {
    position: fixed !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 50% !important;
    height: 50px;
    background-color: #f5f5f5 !important;
    display: flex !important;
    flex-direction: column;
    justify-content: center;
    z-index: 99999 !important;
    margin: 0 !important;
    max-width: none;
  }

  .woocommerce #section-cart-product-page .content-add-to-cart .cwqr-add-to-quote-button.button,
  #section-cart-product-page .content-add-to-cart .woocommerce-variation-add-to-cart .cwqr-add-to-quote-button {
    border-radius: 0 !important;
    margin: 0 !important;
    background: none !important;
    border: 0 !important;
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 50px;
    line-height: 36px !important;
    padding: 0 12px !important;
  }

  #section-cart-product-page .content-add-to-cart .cwqr-inline-message {
    display: none!important;
  }

  body.single-product .woocommerce-variation-add-to-cart-disabled .cwqr-product-quote-block {
    display: none !important;
  }
}

@media (max-width: 980px) {
  .cwqr-quote-request {
    padding: 18px 14px;
  }

  .cwqr-toast-stack {
    top: 16px;
    right: 16px;
    left: 16px;
  }

  .cwqr-toast {
    min-width: 0;
    max-width: none;
  }

  .swal2-container.cwqr-swal-container.swal2-top-end,
  .swal2-container.cwqr-swal-container.swal2-top-right {
    padding-top: 12px;
    padding-right: 12px;
  }

  .cwqr-table-wrap {
    overflow: visible;
  }

  .cwqr-table,
  .cwqr-table thead,
  .cwqr-table tbody,
  .cwqr-table tfoot,
  .cwqr-table tr,
  .cwqr-table th,
  .cwqr-table td {
    display: block;
    width: 100%;
  }

  .cwqr-table thead {
    display: none;
  }

  .cwqr-table tbody tr {
    margin-bottom: 14px;
    padding: 12px;
    border: 1px solid #eee7dc !important;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 6px 18px rgba(17, 24, 39, 0.04);
  }

  .cwqr-table tbody tr:nth-child(odd) {
    background: #ffffff;
  }

  .cwqr-table tbody tr:nth-child(even) {
    background: #fffdf9;
  }

  .cwqr-table tbody td {
    display: block;
    min-width: 0;
    padding: 8px 0;
    border: 0 !important;
    text-align: center;
  }

  .cwqr-table tbody td:last-child {
    padding-bottom: 0;
  }

  .cwqr-table tbody td::before {
    content: attr(data-label);
    display: block;
    width: 100%;
    padding: 8px 10px;
    margin-bottom: 8px;
    border-radius: 8px;
    background: var(--main-color, #111111);
    color: #ffffff;
    font-weight: 700;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    font-size: 12px;
    box-sizing: border-box;
  }

  .cwqr-table tbody td.cwqr-col-product {
    display: block;
    min-width: 0;
    padding: 4px 4px 10px;
    padding-top: 0;
    margin-bottom: 8px;
    background: transparent !important;
    text-align: center;
  }

  .cwqr-table tbody td.cwqr-col-remove,
  .cwqr-table tbody td.cwqr-col-image {
    padding-top: 0;
  }

  .cwqr-table tbody td.cwqr-col-remove::before,
  .cwqr-table tbody td.cwqr-col-image::before {
    display: none;
  }

  .cwqr-table tbody td.cwqr-col-product::before {
    display: none;
  }

  .cwqr-col-product {
    min-width: 0;
    font-weight: 700;
  }

  .cwqr-item-visual {
    width: 86px;
  }

  .cwqr-item-image {
    width: 86px;
    height: 86px;
    margin: 0 auto;
  }

  .cwqr-item-name {
    font-size: 17px;
    line-height: 1.3;
    margin-bottom: 8px;
  }

  .cwqr-item-meta {
    font-size: 13px;
    line-height: 1.45;
  }

  .cwqr-price-stack {
    align-items: center;
  }

  .cwqr-item-discount-badge {
    justify-content: center;
  }

  .cwqr-qty-input {
    width: 42px;
    min-height: 30px;
    height: 30px;
    margin: 0;
  }

  .cwqr-qty-control {
    width: 100%;
  }

  .cwqr-remove-line {
    margin: 0 auto;
  }

  .cwqr-table tfoot {
    margin-top: 10px;
    padding: 0;
    border-radius: 12px;
    background: transparent;
  }

  .cwqr-table tfoot tr {
    display: block;
    padding: 0;
    border: 0 !important;
    margin-bottom: 12px;
    overflow: hidden;
    border-radius: 10px;
  }

  .cwqr-table tfoot tr:last-child {
    margin-bottom: 0;
  }

  .cwqr-table tfoot th,
  .cwqr-table tfoot td {
    width: 100%;
    padding: 10px 12px;
    border: 0 !important;
    text-align: center;
  }

  .cwqr-quote-actions {
    flex-wrap: nowrap;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
  }

  body.et-db #page-container .et_pb_section .bt-link-general.cwqr-action-link {
    flex: 1 1 0;
    min-width: 0!important;
    min-height: 38px!important;
    padding: 0 10px!important;
    font-size: 12px!important;
    line-height: 1.2!important;
    white-space: nowrap!important;
  }

  .cwqr-action-link::after {
    font-size: 15px;
  }
}

@media (max-width: 787px) {
  .cwqr-quote-actions {
    flex-wrap: wrap;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
  }

  body.et-db #page-container .et_pb_section .bt-link-general.cwqr-action-link {
    flex-basis: 100%;
    min-width: 0!important;
    min-height: 38px!important;
    padding: 0 10px!important;
    font-size: 12px!important;
    line-height: 1.2!important;
    white-space: nowrap!important;
  }

  .cwqr-quote-request {
    padding: 0px;
  }
}
