/* Checkout: cart, cart confirm, payment — new design */

.page.nd-checkout {
  max-width: var(--max);
  margin: 0 auto;
  padding: 28px 18px 110px;
  overflow-x: hidden;
}

.page.nd-checkout:has(.nd-cart-empty) {
  padding-bottom: 48px;
}

/* Empty cart state */
.nd-cart-empty {
  width: 100%;
}

.nd-cart-empty__crumbs {
  margin-bottom: 18px;
}

.nd-cart-empty__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  padding: 48px 28px 52px;
  background:
    radial-gradient(circle at 78% 18%, rgba(255, 199, 44, 0.18), transparent 28%),
    linear-gradient(145deg, #f8fbff 0%, #eef5ff 55%, #e4effc 100%);
  border: 1px solid #d0dff2;
  border-radius: var(--radius-lg, 16px);
  box-shadow: 0 12px 28px rgba(7, 29, 58, 0.06);
}

.nd-cart-empty__eyebrow {
  margin: 0;
  color: var(--blue-800, #0f3b78);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nd-cart-empty__icon {
  display: grid;
  place-items: center;
  margin: 8px 0 4px;
}

.nd-cart-empty__title {
  margin: 0;
  color: var(--blue-950, #071d3a);
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 900;
  line-height: 1.2;
}

.nd-cart-empty__hint {
  margin: 0;
  max-width: 420px;
  color: #4a607c;
  font-size: 16px;
  line-height: 1.55;
}

.nd-cart-empty__actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-top: 12px;
}

.nd-cart-empty__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 28px;
  border-radius: 999px;
  background: var(--yellow, #f5b400);
  color: var(--blue-950, #071d3a);
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 8px 18px rgba(245, 180, 0, 0.28);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.nd-cart-empty__cta:hover,
.nd-cart-empty__cta:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(245, 180, 0, 0.34);
  color: var(--blue-950, #071d3a);
  text-decoration: none;
}

.nd-cart-empty__link {
  color: var(--blue-800, #0f3b78);
  font-weight: 800;
  font-size: 14px;
  text-decoration: none;
}

.nd-cart-empty__link:hover,
.nd-cart-empty__link:focus-visible {
  text-decoration: underline;
}

@media (max-width: 650px) {
  .nd-cart-empty__card {
    padding: 36px 18px 40px;
  }

  .nd-cart-empty__hint {
    font-size: 15px;
  }

  .nd-cart-empty__cta {
    width: 100%;
  }
}

/* Legacy cart view embeds its own search; header already provides search in ND */
.nd-checkout .ct-videoSection,
.nd-checkout .home-quick-search-wrap,
.nd-checkout .common-search,
.nd-checkout .home-mobile-search-wrap {
  display: none !important;
}

.nd-checkout-loading {
  position: fixed !important;
  inset: 0 !important;
  left: 0 !important;
  top: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100% !important;
  height: 100% !important;
  z-index: 12000 !important;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(7, 29, 58, 0.45) !important;
  opacity: 1 !important;
}

.nd-checkout-loading.is-visible,
#loading.nd-checkout-loading.is-visible {
  display: flex !important;
}

.nd-checkout-loading__panel {
  position: relative;
  top: auto;
  left: auto;
  transform: none;
  background: var(--white, #fff);
  border-radius: var(--radius, 12px);
  padding: 28px 32px;
  text-align: center;
  width: auto;
  max-width: 90vw;
  box-shadow: 0 18px 40px rgba(7, 29, 58, 0.18);
}

.nd-checkout-loading__panel img {
  width: 48px;
  height: 48px;
  margin-bottom: 12px;
}

.nd-checkout-loading__panel p,
#loading.nd-checkout-loading p {
  color: #071d3a !important;
  font-size: 16px !important;
  margin: 0;
}

.nd-checkout .mainContent,
.nd-checkout .varify-submit-page {
  width: 100%;
  max-width: none;
  padding: 0 !important;
  float: none !important;
}

.nd-checkout .car-lists,
.nd-checkout .productlisting,
.nd-checkout .form-fill-cart,
.nd-checkout .cart-form-grid {
  float: none !important;
  width: 100%;
  max-width: 100%;
}

.nd-checkout .car-lists.productlisting,
.nd-checkout .car-lists.productbaselisting {
  background: var(--white);
  border: 1px solid var(--border, #e5e7eb);
  border-radius: var(--radius, 12px);
  padding: 20px;
  margin: 0 0 20px !important;
  box-shadow: 0 8px 24px rgba(7, 29, 58, 0.04);
}

.nd-checkout .cart-user-form,
.nd-checkout h4.orderHistory {
  color: var(--blue-950);
  font-weight: 900;
}

.nd-checkout .form-control {
  min-height: 44px;
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 10px;
  font: inherit;
}

.nd-checkout .control-label,
.nd-checkout label {
  color: var(--blue-800);
  font-weight: 700;
}

.nd-checkout .actn-btn,
.nd-checkout .btn.actn-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.nd-checkout .actn-btn:hover,
.nd-checkout .btn.actn-btn:hover {
  filter: brightness(0.96);
}

.nd-checkout .sticky_bottom.productBtnsFixedBottom {
  display: block !important;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 120;
  background: var(--white);
  border-top: 1px solid var(--line, #e5e7eb);
  box-shadow: 0 -10px 28px rgba(7, 29, 58, 0.1);
}

.nd-checkout .sticky_bottom .btn2,
.nd-checkout .sticky_bottom .actn-btn2 {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  min-width: 120px;
  padding: 10px 20px;
  border: 0;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  color: #fff !important;
}

.nd-checkout .nav-prex-next {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 20px;
}

.nd-checkout .nav-prex-next .btn.actn-btn,
.nd-checkout .nav-prex-next .btn2.actn-btn2 {
  margin: 0;
}

/* Fallback cart action colors if dynamic_colors is unavailable */
.nd-checkout .cart_back_btn_color {
  background-color: #5b6777 !important;
  color: #fff !important;
}

.nd-checkout .cart_save_btn_color {
  background-color: var(--orange, #f97316) !important;
  color: #fff !important;
}

.nd-checkout .cart_submit_btn_color {
  background-color: var(--blue-900, #0f3b78) !important;
  color: #fff !important;
}

.nd-checkout .displaynon {
  display: none !important;
}

.nd-checkout .my-table,
.nd-checkout table.table {
  font-size: 14px;
}

.nd-checkout .my-table th,
.nd-checkout table.table th {
  background: rgba(15, 59, 120, 0.06);
  color: var(--blue-950);
  font-weight: 800;
}

.nd-checkout--confirm .varify-submit-page {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
}

/* Review timer — plain row like legacy confirm */
.nd-checkout--confirm .nd-confirm-timer {
  gap: 16px;
  padding: 0 0 12px !important;
  margin-bottom: 12px;
  background: transparent;
  border: 0;
  border-radius: 0;
}

.nd-checkout--confirm .nd-confirm-timer .block-message {
  flex: 1 1 220px;
  margin: 0;
  background: transparent;
  border: 0;
  padding: 0;
}

.nd-checkout--confirm .nd-confirm-timer .block-message h5 {
  margin: 0;
  font-size: 15px !important;
  line-height: 1.45;
  color: #000 !important;
  font-weight: 600 !important;
}

.nd-checkout--confirm .counter_msg_wrap_counter {
  flex: 0 0 auto;
}

.nd-checkout--confirm .counter_msg_wrap_counter .flip-clock-wrapper {
  margin: 0;
  transform: scale(0.82);
  transform-origin: right center;
}

/* Quotation document — single flat layout, no extra outer boxes */
.nd-checkout--confirm #sales_preview_order {
  margin-top: 0;
}

.nd-checkout--confirm #sales_preview_order .brandDetailInfo {
  display: table !important;
  width: 100% !important;
  border: 1px solid #000 !important;
  border-radius: 0 !important;
  padding: 10px !important;
  margin-bottom: 10px !important;
  background: transparent !important;
  gap: 0;
}

.nd-checkout--confirm #sales_preview_order .brandDetails {
  display: table-cell !important;
  vertical-align: top !important;
  padding: 10px !important;
  width: auto !important;
}

.nd-checkout--confirm #sales_preview_order .brandDetails img {
  max-width: 140px;
  height: auto;
}

.nd-checkout--confirm #sales_preview_order .invoiceDetails p {
  border-color: #000 !important;
  border-radius: 0;
}

.nd-checkout--confirm #sales_preview_order .table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-bottom: 10px;
  padding-top: 10px;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.nd-checkout--confirm #sales_preview_order table {
  width: 100% !important;
  border-color: #000 !important;
  border-collapse: collapse;
  font-size: 12px;
  margin: 0;
}

.nd-checkout--confirm #sales_preview_order table td,
.nd-checkout--confirm #sales_preview_order table th {
  border-color: #000 !important;
  padding: 8px 10px !important;
  vertical-align: top;
}

.nd-checkout--confirm #sales_preview_order thead th {
  background: transparent !important;
  color: inherit;
  position: static;
}

.nd-checkout--confirm #sales_preview_order thead p,
.nd-checkout--confirm #sales_preview_order tbody p {
  margin: 4px 0;
  line-height: 1.35;
  font-size: 12px;
}

/* Captcha — single horizontal row */
.nd-checkout--confirm .nd-confirm-captcha {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  margin: 20px 0 24px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.nd-checkout--confirm .nd-confirm-captcha__label {
  flex: 0 0 auto;
  margin: 0;
  font-weight: 700;
  white-space: nowrap;
}

.nd-checkout--confirm .nd-confirm-captcha__image {
  flex: 0 0 auto;
  line-height: 0;
}

.nd-checkout--confirm .nd-confirm-captcha__image img {
  display: block;
  max-height: 50px;
  width: auto;
}

.nd-checkout--confirm .nd-confirm-captcha__input {
  flex: 1 1 180px;
  width: auto;
  max-width: 260px;
  min-width: 160px;
  min-height: 44px;
  margin: 0;
}

.nd-checkout--confirm .nd-confirm-captcha .trynewcaptcha {
  flex: 0 0 auto;
  margin: 0 !important;
  min-height: 44px;
  padding: 0 20px;
  white-space: nowrap;
}

/* Action buttons — left aligned */
.nd-checkout--confirm .nd-confirm-actions {
  margin-top: 4px;
  margin-bottom: 8px;
}

.nd-checkout--confirm .nd-confirm-actions__bar {
  text-align: left;
}

.nd-checkout--confirm .nd-confirm-actions__buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
}

.nd-checkout--confirm .nd-confirm-actions .nav-prex-next {
  justify-content: flex-start;
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.nd-checkout--confirm .nd-confirm-btn {
  width: auto !important;
  max-width: 100%;
  min-width: 110px;
  min-height: 44px;
  padding: 0 20px;
  margin: 0 !important;
  border-radius: 8px !important;
}

.nd-checkout--confirm .nd-confirm-btn--primary,
.nd-checkout--confirm .nd-confirm-btn--print,
.nd-checkout--confirm .nd-confirm-btn--secondary,
.nd-checkout--confirm .nd-confirm-btn--outline,
.nd-checkout--confirm .nd-confirm-captcha .nd-confirm-btn {
  background: var(--orange, #f97316) !important;
  color: var(--white) !important;
  border: 0 !important;
}

.nd-checkout--confirm .nd-confirm-btn--outline:hover,
.nd-checkout--confirm .nd-confirm-captcha .nd-confirm-btn:hover {
  filter: brightness(0.96);
  background: var(--orange, #f97316) !important;
}

/* Override legacy cart-confirm.css forcing all buttons red */
.nd-checkout--confirm .car-lists .btn.actn-btn,
.nd-checkout--confirm .col-md-12 .btn.actn-btn,
.nd-checkout--confirm .nav-prex-next .btn.actn-btn {
  background-color: var(--orange, #f97316) !important;
  color: #fff !important;
}

.nd-checkout--confirm .block-message.warning h5 {
  color: var(--blue-950) !important;
  font-weight: 700 !important;
}

.nd-checkout--payment .mainContent,
.nd-checkout--payment .payment-page-wrap {
  background: var(--white);
  border: 1px solid var(--border, #e5e7eb);
  border-radius: var(--radius, 12px);
  padding: 24px;
}

.nd-checkout--payment #payment-panels.paymentPanel {
  max-width: 100%;
  margin: 2rem 0 !important;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.16), 0 2px 10px rgba(0, 0, 0, 0.12);
  overflow: hidden;
}

.nd-checkout--payment #payment-panels .nd-payment-panel__heading {
  padding: 20px;
  background-color: #f5f5f5;
  border-bottom: 1px solid #ddd;
}

.nd-checkout--payment #payment-panels .nd-payment-panel__title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  color: #333;
}

.nd-checkout--payment #payment-panels .nd-payment-panel__amount {
  float: none;
  font-size: 14px;
  font-weight: 400;
  color: #000;
  white-space: nowrap;
}

.nd-checkout--payment .nd-payment-credit-term {
  margin-bottom: 1rem;
}

.nd-checkout--payment .nd-payment-credit-term__limit {
  margin: 0 0 1rem;
  font-weight: 600;
  color: #333;
}

.nd-checkout--payment .nd-payment-credit-term__question {
  display: block;
  margin-bottom: 0.75rem;
  font-weight: 600;
  color: #333;
}

.nd-checkout--payment .nd-payment-credit-term__radios {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: center;
}

.nd-checkout--payment .nd-payment-credit-term__radio {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nd-checkout--payment .nd-payment-credit-term input[type="radio"] {
  accent-color: var(--orange, #f97316);
  width: 18px;
  height: 18px;
  margin: 0;
  flex-shrink: 0;
}

.nd-checkout--payment .nd-payment-credit-term__radio label {
  font-weight: 400;
  margin-bottom: 0;
  cursor: pointer;
}

.nd-checkout--payment .nd-payment-credit-term .cart_asterisk {
  color: #dc2626;
}

.nd-checkout--payment #payment-panels .panel-body {
  float: none !important;
  width: 100%;
  padding: 20px;
}

.nd-checkout--payment #payment-panels .form-group.row {
  align-items: flex-start;
  margin-bottom: 1rem;
}

.nd-checkout--payment #payment-panels .form-control {
  padding: 10px 12px !important;
  margin-bottom: 8px;
  min-height: 44px;
  border: 1px solid var(--border, #e5e7eb) !important;
  border-radius: 10px;
  box-shadow: none !important;
}

.nd-checkout--payment #payment-panels .nd-payment-actions__buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
}

.nd-checkout--payment #payment-panels .nd-payment-actions__buttons .btn,
.nd-checkout--payment #payment-panels .nd-payment-actions__buttons .actn-btn {
  position: static !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 120px;
  min-height: 44px;
  margin: 0 !important;
  padding: 0 28px !important;
  border-radius: 999px !important;
  font-weight: 800;
  text-decoration: none !important;
  white-space: nowrap;
  z-index: auto !important;
}

.nd-checkout--payment #payment-panels .btn-cancel,
.nd-checkout--payment #payment-panels .btn-pay {
  margin-top: 0 !important;
}

.nd-checkout--payment #payment-panels .nd-payment-accept {
  margin-top: 20px;
}

.nd-checkout--payment #payment-panels .trynewcaptcha {
  display: inline-block;
  margin-top: 8px;
  cursor: pointer;
}

.nd-checkout .width50px {
  width: 50px !important;
  min-width: 50px;
  max-width: 50px;
  box-sizing: border-box;
}

.nd-checkout .help-block.blink_error {
  color: #dc2626;
  font-size: 13px;
  display: block;
  font-weight: 600;
}

.nd-checkout .incoterms_block.has-error {
  border: 2px solid #dc2626;
  border-radius: 10px;
  padding: 12px;
  background: rgba(220, 38, 38, 0.04);
}

.nd-checkout .incoterms_block.has-error .control-label {
  color: #dc2626;
}

/* Transit/shipping note sits on its own full-width row below INCOTERMS + carrier. */
.nd-checkout--cart .shipping_note_wrap {
  float: none !important;
  clear: both;
  width: 100% !important;
  max-width: 100%;
  margin: 4px 0 16px;
}

.nd-checkout--cart .shipping_note_wrap .shipping_note {
  display: block;
  width: 100%;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid var(--line, #e5e7eb);
  border-radius: var(--radius-md, 10px);
  background: var(--surface, #f7f9fc);
  color: var(--blue-800, #1e3a5f);
  font-size: 14px;
  line-height: 1.45;
}

/* Legacy cart.css forces p { color: #000 } — restore new-design footer text */
.nd-layout .footer .nd-footer-follow,
.nd-layout .nd-footer .nd-footer-follow {
  color: var(--yellow) !important;
}

.nd-layout .footer p:not(.nd-footer-follow),
.nd-layout .nd-footer p:not(.nd-footer-follow),
.nd-layout .nd-footer li,
.nd-layout .nd-footer .nd-footer-links a {
  color: rgba(255, 255, 255, 0.92);
}

.nd-layout .nd-footer .nd-footer-heading {
  color: var(--yellow) !important;
}

/* Cart line item header: keep remove (X) and collapse controls visible */
.nd-checkout .prod-detail .prod-header {
  flex-wrap: nowrap;
  gap: 10px;
}

.nd-checkout .prod-detail .prod-header > .d-flex.w-100 {
  flex: 1 1 auto;
  width: auto !important;
  min-width: 0;
}

.nd-checkout .prod-detail .prod-header .childparent-arrow,
.nd-checkout .prod-detail .prod-header a.black1,
.nd-checkout .prod-detail .prod-header input.minimize_block {
  flex: 0 0 auto;
}

.nd-checkout .prod-detail .prod-header a.black1 {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Comments field: full-width stacked layout (legacy cart.css behavior) */
.nd-checkout .prod-descp p:has(.user_comment) > span {
  display: block;
  width: 100%;
  max-width: 100%;
}

.nd-checkout .prod-descp .user_comment {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  display: block;
  float: none;
  min-height: 96px;
  margin-top: 6px;
}

.nd-checkout .prod-descp p:has(.user_comment) small {
  display: block;
  float: none;
  margin-top: 6px;
}

@media (max-width: 767px) {
  .page.nd-checkout {
    padding: 20px 14px 36px;
  }

  .nd-checkout .car-lists.productlisting {
    padding: 14px !important;
  }

  .nd-checkout--confirm .nd-confirm-timer {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }

  .nd-checkout--confirm .counter_msg_wrap_counter .flip-clock-wrapper {
    transform: scale(0.75);
    transform-origin: center center;
    margin: 0 auto;
  }

  .nd-checkout--confirm .nd-confirm-captcha {
    gap: 10px 12px;
  }

  .nd-checkout--confirm .nd-confirm-captcha__label {
    width: 100%;
  }

  .nd-checkout--confirm .nd-confirm-captcha__input {
    flex: 1 1 100%;
    max-width: none;
  }

  .nd-checkout--confirm .nd-confirm-actions__buttons {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .nd-checkout--confirm .nd-confirm-btn {
    width: auto !important;
  }

  .nd-checkout--payment #payment-panels .col-md-8.offset-md-4 {
    margin-left: 0;
    width: 100%;
    max-width: 100%;
    flex: 0 0 100%;
  }

  .nd-checkout--payment #payment-panels .nd-payment-actions__buttons {
    justify-content: flex-start;
  }

  /* Cart sticky action bar — stack full-width buttons on mobile */
  .nd-checkout .sticky_bottom .nav-prex-next,
  .nd-checkout .sticky_bottom .sticky_button_next {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    width: 100%;
  }

  .nd-checkout .sticky_bottom .productActionBtns {
    display: flex !important;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start !important;
    gap: 10px;
    width: 100%;
  }

  .nd-checkout .sticky_bottom .btn2,
  .nd-checkout .sticky_bottom .actn-btn2,
  .nd-checkout #cart_buttons .btn.actn-btn,
  .nd-checkout #cart_buttons .btn2.actn-btn2 {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    white-space: normal;
    line-height: 1.35;
    padding: 12px 16px !important;
    text-align: center;
  }

  .nd-checkout .cart_back_btn_color,
  .nd-checkout .cart_save_btn_color,
  .nd-checkout .cart_submit_btn_color {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  .nd-checkout .nav-prex-next.removebuttons#cart_buttons,
  .nd-checkout #cart_buttons.nav-prex-next {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .nd-checkout .sticky_bottom.productBtnsFixedBottom {
    padding: 12px 14px calc(12px + env(safe-area-inset-bottom, 0px)) !important;
  }

  .page.nd-checkout {
    padding-bottom: calc(220px + env(safe-area-inset-bottom, 0px));
  }

  .nd-checkout--payment #payment-panels .nd-payment-actions__buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .nd-checkout--payment #payment-panels .nd-payment-actions__buttons .btn,
  .nd-checkout--payment #payment-panels .nd-payment-actions__buttons .actn-btn {
    width: 100% !important;
    max-width: 100% !important;
    white-space: normal;
    line-height: 1.35;
  }
}

/* —— Redesigned cart (items + pickup + shipping + summary) —— */
.nd-checkout--cart .nd-cart-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  align-items: start;
}

.nd-checkout--cart .nd-cart-layout__main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  width: 100%;
}

@media (min-width: 992px) {
  /* If the legacy form closes __main too early, keep leaked blocks in the
   * left column so products never occupy the 320px summary slot. */
  .nd-checkout--cart .nd-cart-layout > *:not(.nd-cart-summary) {
    grid-column: 1;
  }

  .nd-checkout--cart .nd-cart-layout > .nd-cart-summary {
    grid-column: 2;
    grid-row: 1 / -1;
  }
}

.nd-checkout--cart .nd-cart-page-head {
  margin-bottom: 22px;
}

.nd-checkout--cart .nd-cart-page-head__crumbs {
  margin-bottom: 12px;
  font-size: 13px;
  color: var(--muted);
}

.nd-checkout--cart .nd-cart-page-head__row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
}

.nd-checkout--cart .nd-cart-page-head__eyebrow {
  margin: 0 0 4px;
  color: var(--blue-700);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nd-checkout--cart .nd-cart-page-head__title {
  margin: 0;
  color: var(--blue-950);
  font-size: clamp(26px, 3vw, 34px);
  font-weight: 900;
  line-height: 1.15;
}

.nd-checkout--cart .nd-cart-page-head__count {
  margin: 0;
  color: var(--muted);
  font-weight: 700;
  white-space: nowrap;
}

.nd-checkout--cart .nd-cart-lines {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-top: 28px;
  margin-bottom: 8px;
  clear: both;
  width: 100%;
  min-width: 0;
}

.nd-checkout--cart .nd-cart-line-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.nd-checkout--cart .nd-cart-line {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  box-shadow: 0 8px 24px rgba(7, 29, 58, 0.04);
}

.nd-checkout--cart .nd-cart-line__main {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: start;
}

.nd-checkout--cart .nd-cart-line__media img {
  width: 88px;
  height: 88px;
  object-fit: contain;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid var(--line);
}

.nd-checkout--cart .nd-cart-line__sku {
  color: var(--blue-700);
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 4px;
}

.nd-checkout--cart .nd-cart-line__name {
  margin: 0 0 6px;
  color: var(--blue-950);
  font-size: 18px;
  font-weight: 900;
  line-height: 1.25;
}

.nd-checkout--cart .nd-cart-line__unit {
  color: var(--muted);
  font-size: 14px;
}

.nd-checkout--cart .nd-cart-line__unit-was {
  text-decoration: line-through;
  margin-right: 6px;
  opacity: 0.7;
}

.nd-checkout--cart .nd-cart-line__discount-badge {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #eef5ff;
  color: var(--blue-900, #0b3d91);
  font-size: 12px;
  font-weight: 800;
}

.nd-checkout--cart .nd-cart-line__controls {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  min-width: 140px;
}

.nd-checkout--cart .nd-cart-line__qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.nd-checkout--cart .nd-cart-line__qty-btn {
  width: 36px;
  height: 36px;
  border: 0;
  background: #f3f6fa;
  font-size: 18px;
  font-weight: 700;
  color: var(--blue-900);
  cursor: pointer;
}

.nd-checkout--cart .nd-cart-line__qty-input {
  width: 48px;
  height: 36px;
  border: 0;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  text-align: center;
  font-weight: 800;
}

.nd-checkout--cart .nd-cart-line__total {
  color: var(--blue-950);
  font-weight: 900;
  font-size: 16px;
}

.nd-checkout--cart .nd-cart-line__remove {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: 4px;
}

.nd-checkout--cart .nd-cart-line__notes {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.nd-checkout--cart .nd-cart-line__notes-label {
  display: block;
  margin-bottom: 8px;
  color: var(--blue-800);
  font-size: 13px;
  font-weight: 700;
}

.nd-checkout--cart .nd-cart-line__notes-input {
  width: 100%;
  min-height: 84px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  resize: vertical;
  font: inherit;
}

.nd-checkout--cart .nd-cart-step__head {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.nd-checkout--cart .nd-cart-step__num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--blue-900);
  color: var(--white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  flex-shrink: 0;
}

.nd-checkout--cart .nd-cart-step__title {
  margin: 0 0 4px;
  color: var(--blue-950);
  font-size: 22px;
  font-weight: 900;
}

.nd-checkout--cart .nd-cart-step__hint {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.nd-checkout--cart .nd-cart-pickup {
  margin-bottom: 28px;
}

.nd-checkout--cart .nd-cart-pickup--nested {
  margin: 0;
  padding: 16px 18px 18px;
  background: #f8fbff;
  border: 1px solid #d7e4f4;
  border-radius: var(--radius-md);
}

.nd-checkout--cart .nd-cart-pickup--nested .nd-cart-step__head {
  margin-bottom: 12px;
}

.nd-checkout--cart .nd-cart-pickup--nested .nd-cart-step__title {
  font-size: 16px;
}

.nd-checkout--cart .nd-cart-pickup__for {
  margin: 6px 0 0;
  color: var(--blue-800);
  font-size: 13px;
  font-weight: 700;
}

.nd-checkout--cart .nd-cart-pickup__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.nd-checkout--cart .nd-cart-pickup__card {
  position: relative;
  margin: 0;
  cursor: pointer;
}

.nd-checkout--cart .nd-cart-pickup__radio {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.nd-checkout--cart .nd-cart-pickup__card-body {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  padding: 14px 16px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
  min-height: 78px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.nd-checkout--cart .nd-cart-pickup__card.is-selected .nd-cart-pickup__card-body {
  border-color: var(--blue-700);
  box-shadow: 0 0 0 1px var(--blue-700);
}

.nd-checkout--cart .nd-cart-pickup__card.is-disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.nd-checkout--cart .nd-cart-pickup__radio-ui {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  border-radius: 50%;
  border: 2px solid var(--line);
  background: var(--white);
}

.nd-checkout--cart .nd-cart-pickup__card.is-selected .nd-cart-pickup__radio-ui {
  border-color: var(--blue-700);
  box-shadow: inset 0 0 0 4px var(--blue-700);
}

.nd-checkout--cart .nd-cart-pickup__city {
  display: block;
  color: var(--blue-950);
  font-weight: 900;
  font-size: 16px;
}

.nd-checkout--cart .nd-cart-pickup__stock {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.nd-checkout--cart .nd-cart-pickup__distance {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.nd-checkout--cart .nd-cart-shipping {
  margin-top: 0;
  margin-bottom: 8px;
  overflow: auto;
  width: 100%;
}

.nd-checkout--cart .nd-cart-shipping .float-start {
  float: none;
}

.nd-checkout--cart .nd-cart-pickup--ddp-hidden {
  display: none !important;
}

.nd-checkout--cart .nd-cart-shipping__form .car-lists.productlisting {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: 0 8px 24px rgba(7, 29, 58, 0.04);
}

.nd-checkout--cart .nd-cart-shipping__form .brand_complete_info {
  display: none !important;
}

.nd-checkout--cart .nd-cart-summary {
  position: sticky;
  top: 88px;
  min-width: 0;
  width: 100%;
}

.nd-checkout--cart .nd-cart-summary__card {
  width: 100%;
  box-sizing: border-box;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: 0 8px 24px rgba(7, 29, 58, 0.06);
}

.nd-checkout--cart .nd-cart-summary__title {
  float: none !important;
  width: auto;
  margin: 0 0 16px;
  color: var(--blue-950);
  font-size: 20px;
  font-weight: 900;
}

.nd-checkout--cart .nd-cart-summary__row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 12px;
  width: 100%;
  clear: both;
  margin-bottom: 10px;
  font-size: 14px;
  color: var(--ink);
}

/* Label must never shrink/clip; the value wraps instead of overflowing. */
.nd-checkout--cart .nd-cart-summary__label {
  flex: 0 0 auto;
  white-space: nowrap;
  overflow: visible;
}

.nd-checkout--cart .nd-cart-summary__value {
  flex: 1 1 auto;
  min-width: 0;
  text-align: right;
  overflow-wrap: anywhere;
}

.nd-checkout--cart .nd-cart-summary__row--muted {
  color: var(--muted);
}

.nd-checkout--cart .nd-cart-summary__row--discount .nd-cart-summary__value {
  color: #0a7a3e;
  font-weight: 700;
}

.nd-checkout--cart .nd-cart-summary__divider {
  height: 1px;
  background: var(--line);
  margin: 12px 0;
}

.nd-checkout--cart .nd-cart-summary__row--total {
  font-weight: 900;
  color: var(--blue-950);
  font-size: 16px;
}

.nd-checkout--cart .nd-cart-summary__cta {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  margin-top: 16px;
  padding: 12px 18px;
  border: 0;
  border-radius: 999px !important;
  background: var(--yellow) !important;
  color: var(--blue-950) !important;
  font-weight: 900 !important;
  font-size: 15px;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: filter 0.15s ease, opacity 0.15s ease;
}

.nd-checkout--cart .nd-cart-summary__cta:hover,
.nd-checkout--cart .nd-cart-summary__cta:focus {
  filter: brightness(0.96);
  color: var(--blue-950) !important;
  text-decoration: none;
}

.nd-checkout--cart .nd-cart-pickup.has-error {
  border-color: #e11d48;
  box-shadow: 0 0 0 1px rgba(225, 29, 72, 0.25);
}

.nd-checkout--cart .nd-cart-pickup__error {
  display: none;
  margin: 10px 0 0;
  color: #be123c;
  font-size: 13px;
  font-weight: 700;
}

.nd-checkout--cart .nd-cart-pickup__error.blink_error {
  display: block;
}

.nd-checkout--cart .sticky_bottom.productBtnsFixedBottom {
  display: none !important;
}

@media (max-width: 991px) {
  .nd-checkout--cart .nd-cart-layout {
    grid-template-columns: 1fr;
  }

  .nd-checkout--cart .nd-cart-layout > *:not(.nd-cart-summary),
  .nd-checkout--cart .nd-cart-layout > .nd-cart-summary {
    grid-column: auto;
    grid-row: auto;
  }

  .nd-checkout--cart .nd-cart-summary {
    position: static;
    order: -1;
  }

  .nd-checkout--cart .nd-cart-pickup__grid {
    grid-template-columns: 1fr;
  }

  .nd-checkout--cart .nd-cart-line__main {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .nd-checkout--cart .nd-cart-line__controls {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    min-width: 0;
  }
}

/* -----------------------------------------------------------------------
 * Redesigned address flow (nd-cart-address.js)
 * --------------------------------------------------------------------- */

.nd-checkout--cart .nd-hidden-dup {
  display: none !important;
}

/* The primary Contact & shipping / billing container must stay visible.
 * Legacy carts-new.js hides #hide_billing_details after ~1s (progressive
 * disclosure from the old radio flow); this override neutralises that so the
 * redesigned always-visible form does not flash and disappear.
 * IMPORTANT: scope to .nd-cart-layout (only rendered for a NON-empty redesigned
 * cart). On an empty cart there is no .nd-cart-layout, so #hide_billing_details
 * keeps its inline display:none and stays hidden as expected. */
.nd-checkout--cart .nd-cart-layout #hide_billing_details,
.nd-checkout--cart .nd-cart-layout #show_shipping_details_div {
  display: block !important;
}

.nd-checkout--cart .nd-use-billing {
  margin: 6px 0 22px;
}

.nd-checkout--cart .nd-use-billing__label {
  display: inline-flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface, #f7f9fc);
  font-weight: 700;
  color: var(--blue-950);
  cursor: pointer;
  user-select: none;
}

/* Force a real, visible checkbox even when a global theme reset hides or
 * restyles native checkboxes/radios. */
.nd-checkout--cart .nd-use-billing__cb {
  -webkit-appearance: checkbox !important;
  -moz-appearance: checkbox !important;
  appearance: auto !important;
  width: 18px !important;
  height: 18px !important;
  min-width: 18px;
  margin: 1px 0 0 !important;
  padding: 0 !important;
  position: static !important;
  opacity: 1 !important;
  visibility: visible !important;
  clip: auto !important;
  pointer-events: auto !important;
  accent-color: var(--blue-900);
  cursor: pointer;
  flex: 0 0 auto;
}

.nd-checkout--cart .nd-billing-fields {
  margin-bottom: 12px;
}

.nd-checkout--cart .nd-billing-fields > h4 {
  margin-top: 0;
}

/* -----------------------------------------------------------------------
 * Business and Discount Information (collapsible)
 * --------------------------------------------------------------------- */

.nd-checkout--cart .nd-biz-disc {
  margin: 8px 0 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--white);
  overflow: hidden;
}

.nd-checkout--cart .nd-biz-disc__toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin: 0;
  padding: 16px 18px;
  border: 0;
  background: #f3f4f6;
  color: var(--blue-950);
  font-size: 16px;
  font-weight: 900;
  text-align: left;
  cursor: pointer;
}

.nd-checkout--cart .nd-biz-disc__chev {
  transition: transform 0.2s ease;
  color: var(--muted);
}

.nd-checkout--cart .nd-biz-disc.is-open .nd-biz-disc__chev {
  transform: rotate(180deg);
}

.nd-checkout--cart .nd-biz-disc__body {
  padding: 4px 18px 18px;
  border-top: 1px solid var(--line);
}

.nd-checkout--cart .nd-biz-disc__body > .form-group,
.nd-checkout--cart .nd-biz-disc__body > .formGrid {
  margin-bottom: 14px;
}

.nd-checkout--cart .nd-biz-disc__body h4 {
  margin: 6px 0 4px;
  font-size: 15px;
  font-weight: 800;
  color: var(--blue-950);
}

.nd-checkout--cart .nd-contact-ship {
  overflow: visible;
}

.nd-checkout--cart .nd-contact-ship:not(.is-open) {
  overflow: hidden;
}

/* M1 multi-destination checkout: per-line "Deliver to" + shared address form.
 * Hidden in Section 2 unless Charles multi-address mode (mode 5) needs it.
 * In mode 6 (Collection + Shipping) the selector stays hidden — Charles
 * docks the shared address form inside Section 3 and assigns destinations
 * programmatically. */
.nd-cart-dest{display:none;margin-top:8px}
body.nd-multi-ship .nd-cart-dest{display:block}
.nd-cart-dest__label{display:block;font-size:12px;color:#666;margin-bottom:4px}
.nd-cart-dest__select{max-width:100%;padding:6px 8px;border:1px solid #ccc;border-radius:8px;font-size:13px;background:#fff}
.nd-shipto-form{border:1px solid #d9d9d9;border-radius:10px;padding:14px;margin:14px 0;background:#fafafa;max-width:640px}
.nd-shipto-form__title{font-weight:600;margin-bottom:10px}
.nd-shipto-form__grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.nd-shipto-form__grid input{padding:8px 10px;border:1px solid #ccc;border-radius:8px;font-size:13px;width:100%}
.nd-shipto-form__actions{margin-top:12px;display:flex;gap:10px}
.nd-shipto-form__error{color:#b30000;font-size:13px;margin:8px 0 0}
.nd-shipto-form__for{font-size:12px;color:#555;margin:-4px 0 8px}

/* Per-item fulfillment toggle (mixed collect + deliver).
 * The theme global rule ([type="radio"] in main.css) turns every radio into an
 * invisible position:absolute overlay sized 100%x100% of its nearest positioned
 * ancestor. Scoped positioning on the option label confines that overlay to the
 * pill itself, so page clicks can no longer hit it.
 * Permanently hidden in Section 2: the customer-facing per-item Collect/
 * Deliver decision lives only in Charles (Section 3). The radios remain as
 * hidden form/state carriers that Charles drives programmatically via
 * apply.line_method. */
.nd-checkout--cart .nd-cart-fulfill{display:none}
.nd-checkout--cart .nd-cart-fulfill > .nd-cart-dest__label{flex:0 0 100%;margin-bottom:0}
.nd-checkout--cart .nd-cart-fulfill__opt{position:relative;display:inline-flex;align-items:center;margin:0;padding:7px 16px;border:1px solid var(--line,#d9d9d9);border-radius:8px;background:var(--white,#fff);color:var(--blue-950);font-size:13px;font-weight:600;cursor:pointer;user-select:none}
.nd-checkout--cart .nd-cart-fulfill__opt .nd-cart-line__fulfill-radio{position:absolute;top:0;left:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}
.nd-checkout--cart .nd-cart-fulfill__opt.is-selected{border-color:var(--blue-900);background:#eaf1fb;box-shadow:inset 0 0 0 1px var(--blue-900)}
.nd-checkout--cart .nd-cart-fulfill__opt.is-selected span{color:var(--blue-900)}

/* KGS-AMELECO-COMPACT-CHECKOUT-20261019-01
 * Presentation-only density pass: reduce card gaps and cap long embedded
 * checkout fragments so each guided step can fit on a standard viewport.
 */
.page.nd-checkout {
  padding: 20px 18px 56px;
}

.nd-checkout--cart .nd-cart-page-head {
  margin-bottom: 14px;
}

.nd-checkout--cart .nd-cart-page-head__crumbs {
  margin-bottom: 8px;
}

.nd-checkout--cart .nd-cart-page-head__title {
  font-size: clamp(24px, 2.5vw, 30px);
}

.nd-checkout--cart .nd-cart-lines {
  gap: 14px;
  margin-top: 16px;
  margin-bottom: 4px;
}

.nd-checkout--cart .nd-cart-line-group {
  gap: 8px;
}

.nd-checkout--cart .nd-cart-step__head {
  gap: 10px;
  margin-bottom: 10px;
}

.nd-checkout--cart .nd-step--locked > .nd-cart-step__head,
.nd-checkout--cart .nd-step--collapsed > .nd-cart-step__head {
  margin-bottom: 0;
}

.nd-checkout--cart .nd-cart-step__num {
  width: 28px;
  height: 28px;
  font-size: 13px;
}

.nd-checkout--cart .nd-cart-step__title {
  margin-bottom: 2px;
  font-size: 20px;
  line-height: 1.2;
}

.nd-checkout--cart .nd-cart-step__hint {
  font-size: 13px;
  line-height: 1.35;
}

.nd-checkout--cart .nd-step-foot {
  /* Legacy shared cart CSS floats .main-page left at 100% width inside the
   * step body — an uncleared flex foot collapses to zero width and pins its
   * Continue button at the section's top-right. Clear the float and pin the
   * foot to full width so Continue sits lower-right under the section. */
  clear: both;
  width: 100%;
  padding: 4px 0 10px;
}

.nd-checkout--cart .nd-step-next {
  min-height: 40px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.nd-checkout--cart .nd-cart-line {
  padding: 12px 14px;
  box-shadow: 0 4px 14px rgba(7, 29, 58, 0.04);
}

.nd-checkout--cart .nd-cart-line__main {
  grid-template-columns: 72px minmax(0, 1fr) auto;
  gap: 12px;
}

.nd-checkout--cart .nd-cart-line__media img {
  width: 72px;
  height: 72px;
}

.nd-checkout--cart .nd-cart-line__sku {
  margin-bottom: 2px;
}

.nd-checkout--cart .nd-cart-line__name {
  margin-bottom: 4px;
  font-size: 16px;
  line-height: 1.25;
}

.nd-checkout--cart .nd-cart-line__unit {
  font-size: 13px;
}

.nd-checkout--cart .nd-cart-line__controls {
  gap: 8px;
  min-width: 128px;
}

.nd-checkout--cart .nd-cart-line__notes {
  margin-top: 10px;
  padding-top: 8px;
}

.nd-checkout--cart .nd-cart-line__notes-label {
  margin-bottom: 6px;
}

.nd-checkout--cart .nd-cart-line__notes-input {
  min-height: 64px;
  padding: 8px 10px;
}

.nd-checkout .car-lists.productlisting,
.nd-checkout .car-lists.productbaselisting,
.nd-checkout--cart .nd-cart-shipping__form .car-lists.productlisting {
  padding: 14px;
  margin-bottom: 10px !important;
}

.nd-checkout .form-control {
  min-height: 40px;
  padding-top: 6px;
  padding-bottom: 6px;
}

.nd-checkout--cart .nd-cart-shipping__form .form-group,
.nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group {
  margin-bottom: 8px;
}

.nd-checkout--cart .nd-cart-shipping__form .formGrid {
  gap: 8px 10px;
}

.nd-checkout--cart .nd-cart-shipping__form .control-label,
.nd-checkout--cart .nd-cart-shipping__form label {
  font-size: 13px;
  line-height: 1.3;
  margin-bottom: 4px;
}

.nd-checkout--cart .nd-cart-shipping__form p.help-block:empty {
  display: none;
  margin: 0;
  min-height: 0;
}

.nd-checkout--cart .nd-cart-shipping__form h4 {
  margin: 8px 0 6px;
  padding-top: 0 !important;
  font-size: 15px;
}

.nd-checkout--cart .nd-use-billing {
  margin: 4px 0 12px;
}

.nd-checkout--cart .nd-use-billing__label {
  padding: 8px 10px;
}

.nd-checkout--cart .nd-biz-disc {
  margin: 6px 0 12px;
}

.nd-checkout--cart .nd-biz-disc__toggle {
  padding: 10px 12px;
  font-size: 15px;
}

.nd-checkout--cart .nd-biz-disc__body {
  padding: 4px 12px 10px;
}

.nd-checkout--cart .nd-biz-disc__body > .form-group,
.nd-checkout--cart .nd-biz-disc__body > .formGrid {
  margin-bottom: 8px;
}

.nd-checkout--cart .nd-biz-disc__body h4 {
  margin-top: 4px;
}

.nd-checkout--cart .nd-cart-pickup-zone {
  margin-top: 8px;
}

/* The contact card scrolls internally like the fragment panes — heading and
 * Continue stay on screen while the form remains fully usable. */
.nd-checkout--cart .nd-cart-shipping__form .car-lists.productlisting {
  max-height: calc(100vh - 200px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.nd-checkout--cart .nd-checkout-embed iframe {
  min-height: 480px;
}

/* Embedded checkout fragments own their own scroll so the surrounding guided
 * step, its heading, and Continue control remain in reach. */
.nd-checkout--cart .nd-step--checkout .nd-frag {
  max-height: calc(100vh - 190px);
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

.nd-checkout--cart .nd-step--checkout .nd-frag > .page.nd-checkout {
  padding: 0 !important;
  overflow: visible;
}

.nd-checkout--confirm .varify-submit-page {
  padding: 0;
}

.nd-checkout--confirm .nd-confirm-timer {
  gap: 10px;
  padding: 8px 10px !important;
  margin-bottom: 8px;
}

.nd-checkout--confirm .nd-confirm-timer .block-message h5 {
  font-size: 14px !important;
  line-height: 1.35;
}

.nd-checkout--confirm .counter_msg_wrap_counter .flip-clock-wrapper {
  transform: scale(0.72);
}

.nd-checkout--confirm #sales_preview_order .brandDetailInfo {
  padding: 6px !important;
  margin-bottom: 6px !important;
}

.nd-checkout--confirm #sales_preview_order .brandDetails {
  padding: 6px !important;
}

.nd-checkout--confirm #sales_preview_order .brandDetails img {
  max-width: 110px !important;
  height: auto !important;
}

.nd-checkout--confirm #sales_preview_order .invoiceDetails p {
  margin-bottom: 6px !important;
}

.nd-checkout--confirm #sales_preview_order .table-responsive {
  margin-bottom: 6px;
  padding-top: 6px;
}

.nd-checkout--confirm #sales_preview_order table {
  font-size: 11.5px;
}

.nd-checkout--confirm #sales_preview_order table td,
.nd-checkout--confirm #sales_preview_order table th {
  padding: 5px 6px !important;
}

.nd-checkout--confirm #sales_preview_order thead p,
.nd-checkout--confirm #sales_preview_order tbody p,
.nd-checkout--confirm #sales_preview_order td p {
  margin: 2px 0;
  line-height: 1.25;
  font-size: 11.5px;
}

.nd-checkout--confirm .nd-confirm-captcha {
  gap: 8px 12px;
  margin: 10px 0 14px;
}

.nd-checkout--confirm .nd-confirm-captcha__input,
.nd-checkout--confirm .nd-confirm-captcha .trynewcaptcha,
.nd-checkout--confirm .nd-confirm-btn {
  min-height: 40px;
}

.nd-checkout--confirm .nd-confirm-btn {
  padding: 0 16px;
}

.nd-checkout--confirm .nd-confirm-actions {
  margin-top: 0;
  margin-bottom: 4px;
}

.nd-checkout--payment .mainContent,
.nd-checkout--payment .payment-page-wrap {
  padding: 14px;
}

.nd-checkout--payment #payment-panels.paymentPanel {
  margin: 10px 0 !important;
}

.nd-checkout--payment #payment-panels .nd-payment-panel__heading {
  padding: 12px 14px;
}

.nd-checkout--payment #payment-panels .panel-body {
  padding: 14px;
}

.nd-checkout--payment #payment-panels .nd-payment-panel__title {
  font-size: 18px;
}

.nd-checkout--payment #payment-panels .form-group.row {
  margin-bottom: 8px;
}

.nd-checkout--payment #payment-panels .form-control {
  padding: 7px 10px !important;
  margin-bottom: 6px;
  min-height: 40px;
}

.nd-checkout--payment #payment-panels .nd-payment-actions__buttons {
  gap: 8px;
  margin-top: 4px;
}

@media (max-width: 991px) {
  .nd-checkout--cart .nd-cart-line__main {
    grid-template-columns: 64px minmax(0, 1fr);
  }

  .nd-checkout--cart .nd-cart-line__media img {
    width: 64px;
    height: 64px;
  }
}

@media (max-width: 767px) {
  .page.nd-checkout {
    padding: 14px 10px 32px;
  }

  .nd-checkout--cart .nd-cart-page-head {
    margin-bottom: 10px;
  }

  .nd-checkout--cart .nd-cart-page-head__row {
    align-items: flex-start;
    gap: 10px;
  }

  .nd-checkout--cart .nd-cart-page-head__title {
    font-size: 24px;
  }

  .nd-checkout--cart .nd-cart-lines {
    gap: 10px;
    margin-top: 10px;
  }

  .nd-checkout--cart .nd-cart-step__head {
    gap: 8px;
    margin-bottom: 8px;
  }

  .nd-checkout--cart .nd-cart-step__num {
    width: 26px;
    height: 26px;
    font-size: 12px;
  }

  .nd-checkout--cart .nd-cart-step__title {
    font-size: 18px;
  }

  .nd-checkout--cart .nd-cart-step__hint {
    font-size: 12px;
  }

  .nd-checkout--cart .nd-step-foot {
    padding: 2px 0 8px;
  }

  .nd-checkout--cart .nd-step-next {
    width: 100%;
    min-height: 42px;
  }

  .nd-checkout--cart .nd-cart-line {
    padding: 10px;
  }

  .nd-checkout--cart .nd-cart-line__main {
    grid-template-columns: 56px minmax(0, 1fr);
    gap: 10px;
  }

  .nd-checkout--cart .nd-cart-line__media img {
    width: 56px;
    height: 56px;
  }

  .nd-checkout--cart .nd-cart-line__notes-input {
    min-height: 56px;
  }

  .nd-checkout .car-lists.productlisting,
  .nd-checkout .car-lists.productbaselisting,
  .nd-checkout--cart .nd-cart-shipping__form .car-lists.productlisting {
    padding: 10px !important;
  }

  .nd-checkout .form-control {
    min-height: 40px;
  }

  .nd-checkout--cart .nd-cart-shipping__form .formGrid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    column-gap: 8px;
    row-gap: 8px;
  }

  .nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group {
    margin-bottom: 0;
  }

  .nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group:has(#cart_email),
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group:has(#cart_address_1),
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group:has(input[type="file"]),
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group:has(textarea),
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group:has(.customFileInput),
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group.billingShippingcheck,
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group.incoterms_block,
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > .form-group.shipping_preference_block,
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > #ship_with_freight_block,
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > #freight_display_block,
  .nd-checkout--cart .nd-cart-shipping__form .formGrid > #packedbox {
    grid-column: 1 / -1;
  }

  .nd-checkout--cart .nd-biz-disc__toggle {
    padding: 8px 10px;
  }

  .nd-checkout--cart .nd-biz-disc__body {
    padding: 4px 10px 8px;
  }

  .nd-checkout--cart .nd-cart-shipping__form .car-lists.productlisting {
    max-height: calc(100vh - 160px);
  }

  .nd-checkout--cart .nd-step--checkout .nd-frag {
    max-height: calc(100vh - 170px);
  }

  .nd-checkout--confirm .nd-confirm-timer {
    padding: 8px !important;
  }

  .nd-checkout--confirm #sales_preview_order table td,
  .nd-checkout--confirm #sales_preview_order table th {
    padding: 4px 5px !important;
  }

  .nd-checkout--payment .mainContent,
  .nd-checkout--payment .payment-page-wrap {
    padding: 10px;
  }

  .nd-checkout--payment #payment-panels .nd-payment-panel__heading,
  .nd-checkout--payment #payment-panels .panel-body {
    padding: 10px;
  }
}

/* KGS-AMELECO-COMPACT-CHECKOUT-20261019-01-FIX
 * TC27 follow-up: at handset widths the legacy quotation header block
 * (.brandDetailInfo is display:table with .brandDetails cells) cannot
 * reflow, so the Sold To / Ship To / invoice columns overflow the
 * compact pane horizontally. Stack the cells and pin a persistent
 * order-total bar to the bottom of the preview scroll area. The bar is
 * injected by charles_panel.php cloning the rendered total — no second
 * calculation.
 */
@media (max-width: 767px) {
  .nd-checkout--confirm #sales_preview_order .brandDetailInfo,
  #nd_frag_confirm #sales_preview_order .brandDetailInfo {
    display: block !important;
  }

  .nd-checkout--confirm #sales_preview_order .brandDetails,
  #nd_frag_confirm #sales_preview_order .brandDetails {
    display: block !important;
    width: 100% !important;
    box-sizing: border-box;
  }

  .nd-checkout--confirm #sales_preview_order .invoiceDetails p,
  #nd_frag_confirm #sales_preview_order .invoiceDetails p,
  .nd-checkout--confirm #sales_preview_order .brandDetails p,
  #nd_frag_confirm #sales_preview_order .brandDetails p,
  .nd-checkout--confirm #sales_preview_order .brandDetails strong,
  #nd_frag_confirm #sales_preview_order .brandDetails strong {
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  /* Sold To / Ship To party boxes: table-layout:auto inner tables grow
   * to the longest unbroken value (email/address) and overflow the
   * fixed 50% cell. Stack the two columns and wrap contents. */
  .nd-checkout--confirm #sales_preview_order .party-boxes,
  #nd_frag_confirm #sales_preview_order .party-boxes,
  .nd-checkout--confirm #sales_preview_order .party-boxes tbody,
  #nd_frag_confirm #sales_preview_order .party-boxes tbody,
  .nd-checkout--confirm #sales_preview_order .party-boxes tr,
  #nd_frag_confirm #sales_preview_order .party-boxes tr,
  .nd-checkout--confirm #sales_preview_order .party-boxes > tbody > tr > td,
  #nd_frag_confirm #sales_preview_order .party-boxes > tbody > tr > td {
    display: block !important;
    width: 100% !important;
    box-sizing: border-box;
  }

  .nd-checkout--confirm #sales_preview_order .party-inner,
  #nd_frag_confirm #sales_preview_order .party-inner {
    table-layout: fixed !important;
  }

  .nd-checkout--confirm #sales_preview_order .party-inner > tbody > tr > td,
  #nd_frag_confirm #sales_preview_order .party-inner > tbody > tr > td {
    display: block !important;
    width: 100% !important;
    box-sizing: border-box;
  }

  .nd-checkout--confirm #sales_preview_order .party-inner td,
  #nd_frag_confirm #sales_preview_order .party-inner td,
  .nd-checkout--confirm #sales_preview_order .party-boxes p,
  #nd_frag_confirm #sales_preview_order .party-boxes p {
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .nd-preview-summary {
    position: sticky;
    bottom: 0;
    z-index: 6;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 4px 8px;
    padding: 8px 10px;
    margin-top: 6px;
    background: var(--white, #fff);
    border-top: 1px solid var(--line, #d9d9d9);
    box-shadow: 0 -2px 8px rgba(0, 0, 0, .08);
    font-size: 13px;
    color: var(--blue-950, #102a56);
  }

  /* The total must never truncate — it wraps internally if needed; the
   * hint drops to its own row when both cannot fit side by side. */
  .nd-preview-summary__total {
    font-weight: 700;
    flex: 0 1 auto;
  }

  .nd-preview-summary__hint {
    flex: 1 1 auto;
    font-weight: 400;
    font-size: 11.5px;
    color: #666;
  }
}
