/* VF3-P109 | HOME ONLY | mobile width & nested cards
   Derived from VFc(1).zip (27-10-2026). Do NOT touch shared shop/listing
   layouts, PC/tablet, sticky vehicle tabs or P108 mobile contact/navigation.
   320-767px: outer 10px sides, section 12px, inner discovery 10px.
*/
@media screen and (max-width: 767px) {
  /* Base auto-universal.css defines 100% - 32px after an earlier 100% - 20px;
     this home-only override removes the extra blank gutter on BOTH sides. */
  body.auto-master.auto-home-universal #main-content .auto-u-page > main.auto-u-container.auto-u-stack {
    box-sizing: border-box !important;
    width: calc(100% - 20px) !important;
    max-width: 1280px !important;
    min-width: 0 !important;
    margin-inline: auto !important;
    padding-inline: 0 !important;
  }
  /* Keep one primary 12px horizontal inset instead of stacking 16px + 18px. */
  body.auto-master.auto-home-universal #main-content .auto-u-stack > section.auto-u-panel.auto-u-floor {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin-inline: 0 !important;
    padding-inline: 12px !important;
    border-radius: 14px;
  }
  body.auto-master.auto-home-universal #main-content .auto-u-stack > section.auto-u-panel.auto-u-floor > :is(div, header, article, form) {
    min-width: 0;
    max-width: 100%;
  }
  /* The overview section encloses another pair of boxed sections: category,
     stories and shop boxes. Minimize interior padding while retaining borders. */
  body.auto-home-universal #tong-quan .vf3-p10-categories {
    padding: 10px !important;
    margin-inline: 0 !important;
    gap: 9px !important;
  }
  body.auto-home-universal #tong-quan :is(.vf3-p10-feed, .vf3-p10-shopbox) {
    box-sizing: border-box;
    padding: 10px !important;
    min-width: 0;
    max-width: 100%;
  }
  body.auto-home-universal #tong-quan .vf3-p10-discovery {
    min-width: 0;
    max-width: 100%;
    gap: 11px;
  }
  body.auto-home-universal #tong-quan .vf3-p10-partners > a {
    min-width: 0;
    padding: 10px !important;
    gap: 10px;
  }
  body.auto-home-universal #tong-quan .vf3-p10-partners > a > span:nth-child(2) {
    min-width: 0;
    overflow-wrap: anywhere;
  }
  body.auto-home-universal #tong-quan .vf3-p10-post-grid {
    max-width: 100%;
    min-width: 0;
  }
  /* 34 province contact cards are already displayed in two columns. Keep that
     density on 375-767px, remove the intermediate frame's excess padding. */
  body.auto-home-universal #gia-lan-banh.auto-u-onroad .vf3-region-contact-directory {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin-inline: 0;
    padding: 11px !important;
  }
  body.auto-home-universal #gia-lan-banh .vf3-region-contact-grid {
    min-width: 0;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 8px;
  }
  body.auto-home-universal #gia-lan-banh .vf3-region-contact-card {
    min-width: 0;
    padding: 9px !important;
  }
  body.auto-home-universal #gia-lan-banh .vf3-region-contact-line a {
    max-width: 100%;
    overflow-wrap: anywhere;
  }
  /* Mobile table should scroll inside its own bounds, not widen the page. */
  body.auto-home-universal #gia-lan-banh :is(.vf3-regional-price, .vf3-region-table-scroll) {
    min-width: 0;
    max-width: 100%;
  }
  body.auto-home-universal #gia-lan-banh .vf3-region-table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  /* News and text blocks receive the same full available content width. */
  body.auto-home-universal #bai-viet .vf3-p16-news-grid,
  body.auto-home-universal #tong-quan .vf3-p10-post-grid,
  body.auto-home-universal #tong-quan .vf3-p10-partners {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
  }
}
/* Very narrow devices: contact information must not clip/overflow its card. */
@media screen and (max-width: 360px) {
  body.auto-home-universal #gia-lan-banh .vf3-region-contact-grid {
    grid-template-columns: minmax(0,1fr);
  }
  body.auto-home-universal #gia-lan-banh .vf3-region-contact-card {
    padding: 11px !important;
  }
}
