/**
 * Dash Horizon responsive rules — shared client + cart
 */

/* Product cards — equal height, price pinned, no fixed clip height */
#order-standard_cart .products .product {
  display: flex !important;
  flex-direction: column !important;
  height: 100%;
  min-height: 0;
  overflow: visible !important;
}

#order-standard_cart .products .product header {
  flex: 0 0 auto;
}

#order-standard_cart .products .product div.product-desc {
  flex: 1 1 auto;
  min-height: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

#order-standard_cart .products .product footer {
  margin-top: auto !important;
  flex: 0 0 auto;
  display: flex !important;
  flex-direction: column;
  align-items: stretch;
  gap: 12px;
}

#order-standard_cart .products .product .product-pricing {
  margin-bottom: 0;
}

#order-standard_cart .products .product .btn-order-now {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 12px 16px !important;
  min-height: 46px;
}

#order-standard_cart .products .product .btn-order-now i {
  margin: 0 !important;
  font-size: 1rem;
}

#order-standard_cart .products .product:focus-within {
  outline: none;
  box-shadow: var(--dh-focus), var(--dh-shadow-soft) !important;
}

/* Prevent horizontal overflow */
body.dh-theme,
body.dh-theme #main-body,
body.dh-theme .primary-content {
  max-width: 100%;
}

@media (max-width: 1199px) {
  .dhx-wrap {
    padding-left: 16px;
    padding-right: 16px;
  }
}

@media (max-width: 991px) {
  body.dh-theme .master-breadcrumb .breadcrumb {
    border-radius: 16px;
    white-space: normal;
  }

  #order-standard_cart .secondary-cart-body,
  #order-standard_cart .secondary-cart-sidebar {
    width: 100% !important;
    max-width: none !important;
    flex: 1 1 100% !important;
  }
}

@media (max-width: 767px) {
  #order-standard_cart .products .row > [class*="col-"],
  #order-standard_cart .products .row-eq-height > [class*="col-"] {
    flex: 0 0 100% !important;
    max-width: 100% !important;
    width: 100% !important;
  }

  body.dh-theme #main-body > .container {
    padding-left: 12px;
    padding-right: 12px;
  }

  body.dh-theme .dataTables_wrapper .dataTables_filter,
  body.dh-theme .dataTables_wrapper .dataTables_length,
  body.dh-theme .dataTables_wrapper .dataTables_info,
  body.dh-theme .dataTables_wrapper .dataTables_paginate {
    float: none !important;
    text-align: left !important;
    width: 100%;
    margin-bottom: 10px;
  }

  body.dh-theme .md-editor .btn-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
  }

  body.dh-theme input[type="file"] {
    font-size: 14px;
  }
}

@media (max-width: 430px) {
  .dhx-logo span:last-child {
    font-size: 15px;
  }

  .dhx-logo-mark {
    width: 36px;
    height: 36px;
    border-radius: 12px;
  }
}

@media (max-width: 320px) {
  .dhx-wrap {
    padding: 10px 12px;
  }
}
