/* KF preservation pass: existing design; variance 4, motion 1, density 4.
   Every layout override is mobile-only and limited to native store content. */
@media (max-width: 767px) {
  body.kf-mc26-native {
    --kf-mc26-gutter: 20px;
    /* The existing KF stylesheet also uses this token for native archives. */
    --kf-fc-gutter: var(--kf-mc26-gutter);
  }

  /* One outer gutter. Do not target the Elementor header/footer or home/shop. */
  body.kf-mc26-native #main > :is(.ct-container, .ct-container-full),
  body.kf-mc26-native #main > .fct-genric-template-wrapper {
    width: calc(100% - var(--kf-mc26-gutter) * 2);
    max-width: none;
    margin-inline: auto;
    padding-inline: 0;
  }
  body.kf-mc26-native #main > .hero-section > .entry-header {
    width: calc(100% - var(--kf-mc26-gutter) * 2);
    margin-inline: auto;
    padding-inline: 0;
  }

  body.kf-mc26-native .entry-content > :is(.fct-single-product-page, .fluent-cart-checkout-page, .fct-cart-page) {
    width: 100%;
    max-width: 100%;
    margin-inline: 0;
    padding-inline: 0;
    box-sizing: border-box;
  }
  body.kf-mc26-native .fct-single-product-page {
    padding-inline: 0;
  }
  /* Related/similar product titles must not reserve three empty text lines. */
  body.single-fluent-products .fct-product-list-container .fct-product-card-title {
    min-height: 0;
    height: auto;
    margin-bottom: 8px;
  }
  body.kf-mc26-native .fluent-cart-checkout-page {
    padding-inline: 0;
    --fct-container-padding-x: 16px;
    --fct-container-padding-y: 16px;
  }
  body.kf-mc26-native .fluent-cart-checkout-page :is(.fct_checkout_inner, .fct_checkout_form, .fct_checkout_summary) {
    min-width: 0;
    max-width: 100%;
    margin-inline: 0;
  }
  body.kf-mc26-native .fluent-cart-checkout-page .fct_checkout_form_items {
    padding-inline: 16px;
  }
  body.kf-mc26-native .fluent-cart-checkout-page .fct_summary_box {
    padding-inline: 16px;
  }
  /* KF's outer summary card already supplies its border and padding. */
  body.kf-mc26-native .fluent-cart-checkout-page .fct_summary_box > .fct_checkout_form_section {
    border: 0;
    background: transparent;
    margin-bottom: 0;
  }
  body.kf-mc26-native .fluent-cart-checkout-page .fct_summary_box .fct_form_section_header {
    padding: 0 0 16px;
  }
  body.kf-mc26-native .fluent-cart-checkout-page .fct_summary_box .fct_form_section_body {
    padding-inline: 0;
    padding-bottom: 0;
  }
  body.kf-mc26-native .fluent-cart-checkout-page .fct_line_item_info {
    flex: 1 1 0%;
    min-width: 0;
  }
  body.kf-mc26-native .fluent-cart-checkout-page .fct_line_item_price {
    flex: 0 0 auto;
    white-space: nowrap;
  }
  body.kf-mc26-native .fluent-cart-checkout-page :is(.fct_input_wrapper, .fct_checkout_input_group) {
    min-width: 0;
  }
  body.kf-mc26-native .fluent-cart-checkout-page :is(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]), select, textarea) {
    max-width: 100%;
    font-size: 16px;
  }
  body.kf-mc26-native .fluent-cart-checkout-page :is(.fct_summary, .fct_address_wrapper) {
    overflow-wrap: anywhere;
  }

  /* Cart page only: the slide-out cart retains its own spacing. */
  body.kf-mc26-native .fct-cart-page { min-width: 0; }
  body.kf-mc26-native .fct-cart-page :is(.fct-cart-total-wrapper, .fluent-cart-cart-cart-button-wrap) {
    padding-inline: 16px;
  }
  body.kf-mc26-native .fct-cart-page .fct-cart-item-info { min-width: 0; gap: 12px; }
  body.kf-mc26-native .fct-cart-page .fct-cart-item-details { min-width: 0; overflow-wrap: anywhere; }
}
@media (max-width: 359px) {
  body.kf-mc26-native { --kf-mc26-gutter: 16px; }
}
/* Tablet and phone landscape: match the site's existing 32px tablet gutter. */
@media (min-width: 768px) and (max-width: 1023px) {
  body.kf-mc26-native { --kf-fc-gutter: 32px; }
  body.kf-mc26-native #main > :is(.ct-container, .ct-container-full),
  body.kf-mc26-native #main > .fct-genric-template-wrapper {
    width: calc(100% - 64px);
    max-width: none;
    margin-inline: auto;
    padding-inline: 0;
  }
  body.kf-mc26-native .entry-content > :is(.fct-single-product-page, .fluent-cart-checkout-page, .fct-cart-page) {
    width: 100%;
    max-width: 100%;
    margin-inline: 0;
    padding-inline: 0;
  }
}
