/* v896 — Mobile polish for form/status/FAQ pages
   Desktop untouched: all rules are scoped to tablet/mobile breakpoints. */

@media (max-width: 1080px) {
  /* Status/contact/order/FAQ shells */
  body :where(
    .tracking-layout-v858,
    .tracking-page-v881,
    .check-status-layout-v881,
    .contact-layout,
    .contact-grid,
    .order-shell,
    .order-layout,
    .quote-flow-shell,
    .payment-summary-shell,
    .thank-you-shell,
    .faq-xxx-grid-v847
  ){
    grid-template-columns:1fr !important;
    max-width:100% !important;
    min-width:0 !important;
    gap:18px !important;
  }

  body :where(
    .tracking-sidebar,
    .check-status-sidebar,
    .contact-sidebar,
    .order-sidebar,
    .payment-summary-sidebar,
    .faq-xxx-sidebar-wrap-v847
  ){
    position:static !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
  }

  body :where(.faq-xxx-sidebar-wrap-v847 .emergency-side-box-v787FR:nth-of-type(n+4)){
    display:none !important;
  }

  body :where(form, fieldset, .form-grid, .input-grid, .order-grid, .applicant-grid, .upload-grid, .payment-grid){
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }

  body :where(.form-grid, .input-grid, .order-grid, .applicant-grid, .upload-grid, .payment-grid, .grid.two, .grid.three, .grid.four){
    grid-template-columns:1fr !important;
  }
}

@media (max-width: 768px) {
  body :where(
    .tracking-page,
    .check-status-page,
    .contact-page,
    .order-page,
    .fees-page,
    .quote-flow-page,
    .payment-page,
    .thank-you-page,
    .vge-compact-faq-v861
  ){
    overflow-x:hidden !important;
    padding-bottom:96px !important;
  }

  body :where(.container, .quote-flow-shell, .order-shell, .tracking-shell, .contact-shell, .payment-summary-shell, .thank-you-shell){
    width:100% !important;
    max-width:100% !important;
    padding-left:14px !important;
    padding-right:14px !important;
    box-sizing:border-box !important;
  }

  /* Forms: safe touch targets */
  body :where(input, select, textarea, button){
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }
  body :where(input, select, textarea){
    width:100% !important;
    font-size:16px !important; /* avoid iOS zoom */
  }
  body :where(input, select, button){
    min-height:44px !important;
  }
  body :where(textarea){
    min-height:112px !important;
  }

  body :where(label){
    font-size:14px !important;
    line-height:1.45 !important;
  }

  body :where(.btn, button, input[type="submit"], .faq-xxx-help-btn-v847){
    min-height:44px !important;
    border-radius:0 !important;
  }

  body :where(.hero-actions, .form-actions, .order-actions, .payment-actions, .tracking-actions, .contact-actions){
    display:flex !important;
    flex-direction:column !important;
    align-items:stretch !important;
    gap:10px !important;
  }

  body :where(.hero-actions .btn, .form-actions .btn, .order-actions .btn, .payment-actions .btn, .tracking-actions .btn, .contact-actions .btn, .faq-xxx-help-btn-v847){
    width:100% !important;
    justify-content:center !important;
    text-align:center !important;
  }

  /* Cards/panels become flatter on mobile */
  body :where(
    .card,
    .panel,
    .box,
    .tracking-card,
    .check-status-card,
    .contact-card,
    .order-card,
    .payment-card,
    .thank-you-card,
    .faq-xxx-topic-card-v847,
    .faq-xxx-intro-card-v847,
    .faq-xxx-help-card-v847,
    .faq-xxx-trust-item-v847
  ){
    border-radius:0 !important;
    box-shadow:none !important;
    max-width:100% !important;
    min-width:0 !important;
  }

  /* Tracking/check status */
  body :where(.tracking-hero, .check-status-hero, .contact-hero, .order-hero, .payment-hero, .thank-you-hero){
    padding-top:22px !important;
    padding-bottom:22px !important;
  }

  body :where(h1){
    font-size:clamp(29px,9vw,40px) !important;
    line-height:1.12 !important;
    letter-spacing:-0.035em !important;
  }
  body :where(h2){
    font-size:clamp(23px,6.5vw,31px) !important;
    line-height:1.18 !important;
  }
  body :where(p, li){
    font-size:14.5px !important;
    line-height:1.62 !important;
  }

  /* FAQ mobile refinements */
  body.vge-compact-faq-v861 .faq-xxx-grid-v847{
    grid-template-columns:1fr !important;
    gap:18px !important;
  }
  body.vge-compact-faq-v861 .faq-xxx-chip-row-v847{
    display:flex !important;
    overflow-x:auto !important;
    flex-wrap:nowrap !important;
    -webkit-overflow-scrolling:touch !important;
    padding-bottom:6px !important;
    margin-bottom:16px !important;
  }
  body.vge-compact-faq-v861 .faq-xxx-chip-v847{
    white-space:nowrap !important;
    flex:0 0 auto !important;
  }
  body.vge-compact-faq-v861 .faq-xxx-topic-stack-v847{
    gap:10px !important;
  }
  body.vge-compact-faq-v861 .faq-xxx-topic-summary-v847{
    grid-template-columns:38px minmax(0,1fr) 30px !important;
    gap:10px !important;
    padding:14px 12px !important;
  }
  body.vge-compact-faq-v861 .faq-xxx-topic-count-v847{
    width:30px !important;
    height:30px !important;
    min-width:30px !important;
    font-size:12px !important;
  }
  body.vge-compact-faq-v861 .faq-xxx-topic-chevron-v847{
    display:none !important;
  }
  body.vge-compact-faq-v861 .faq-xxx-question-list-v847 .vge-tv-faq-item-v787GY summary{
    padding:12px !important;
    gap:10px !important;
  }
  body.vge-compact-faq-v861 .faq-xxx-question-list-v847 .vge-tv-faq-answer-v787GY{
    padding:0 12px 12px 12px !important;
  }

  /* Tables/status summaries */
  body :where(table){
    min-width:560px !important;
    max-width:none !important;
    width:max-content !important;
  }
  body :where(.table-wrap, .table-responsive, [class*="table-wrap"], [class*="table-responsive"]){
    width:100% !important;
    max-width:100% !important;
    overflow-x:auto !important;
    -webkit-overflow-scrolling:touch !important;
    border:1px solid #d7e2f0 !important;
  }

  /* File upload blocks */
  body :where(.upload-area, .upload-box, .dropzone, [class*="upload"]){
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }

  /* Floating chat/quick contact should not hide final buttons */
  body :where(main){
    padding-bottom:24px !important;
  }
}

@media (max-width: 480px) {
  body :where(.container, .quote-flow-shell, .order-shell, .tracking-shell, .contact-shell, .payment-summary-shell, .thank-you-shell){
    padding-left:12px !important;
    padding-right:12px !important;
  }

  body :where(h1){
    font-size:clamp(27px,10vw,36px) !important;
  }

  body.vge-compact-faq-v861 .faq-xxx-title-v847{
    font-size:28px !important;
  }

  body.vge-compact-faq-v861 .faq-xxx-topic-summary-v847{
    grid-template-columns:32px minmax(0,1fr) 28px !important;
    gap:8px !important;
  }

  body.vge-compact-faq-v861 .faq-xxx-topic-icon-v847,
  body.vge-compact-faq-v861 .faq-xxx-help-icon-v847{
    font-size:29px !important;
  }

  body :where(table){
    min-width:520px !important;
  }

  body :where(.btn, button, input[type="submit"]){
    font-size:14px !important;
  }
}
