/* TOWFAST MOBILE + DEVICE POLISH V2
   Loaded after the main stylesheet. Desktop above 980px is left alone. */

@media (max-width: 980px) {
  html,
  body {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
  }

  body {
    -webkit-text-size-adjust: 100% !important;
    text-size-adjust: 100% !important;
  }

  *,
  *::before,
  *::after {
    box-sizing: border-box !important;
  }

  img,
  video,
  iframe,
  canvas,
  svg {
    max-width: 100% !important;
  }

  .wrap,
  html body .wrap,
  html body .reviews-section .wrap {
    width: calc(100% - 28px) !important;
    max-width: var(--max) !important;
    margin-left: auto !important;
    margin-right: auto !important;
    min-width: 0 !important;
  }

  main,
  section,
  header,
  footer,
  .home-hero-bg-wrap {
    max-width: 100% !important;
    overflow-x: clip !important;
  }

  section {
    padding-top: 46px !important;
    padding-bottom: 46px !important;
  }

  .site-header {
    top: 8px !important;
    padding-bottom: 8px !important;
  }

  .site-header .nav-wrap {
    width: calc(100% - 20px) !important;
    min-height: 66px !important;
    height: 66px !important;
    padding: 0 10px !important;
    gap: 8px !important;
    border-radius: 20px !important;
    overflow: visible !important;
  }

  .site-header .brand {
    width: 132px !important;
    max-width: 132px !important;
    height: 52px !important;
    min-width: 0 !important;
  }

  .site-header .brand img {
    width: 118px !important;
    max-width: 118px !important;
    max-height: 42px !important;
  }

  .site-header .menu-toggle {
    height: 44px !important;
    min-width: 78px !important;
    padding: 0 13px !important;
    border-radius: 14px !important;
    font-size: 14px !important;
    line-height: 1 !important;
  }

  .site-header .site-nav.open {
    top: 82px !important;
    left: 10px !important;
    right: 10px !important;
    width: auto !important;
    max-width: none !important;
    max-height: calc(100dvh - 104px) !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    padding: 8px !important;
    border-radius: 20px !important;
  }

  .site-header .site-nav.open a,
  .site-header .site-nav.open .nav-link {
    min-height: 48px !important;
    padding: 0 13px !important;
    font-size: 14.5px !important;
    white-space: normal !important;
  }

  main > section:first-child,
  main > div:first-child {
    margin-top: -82px !important;
    padding-top: 82px !important;
  }

  html body .hero::before,
  html body .page-hero::before {
    inset: -82px 0 0 0 !important;
  }

  .home-hero-bg-wrap,
  .home-hero-bg-wrap .hero,
  .home-hero-bg-wrap .hero-inner,
  .page-hero,
  .page-hero .wrap,
  .page-hero-grid,
  .blog-hero-grid,
  .areas-hero .page-hero-grid,
  .services-hero .wrap {
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .home-hero-bg-wrap .hero-inner,
  main > section.hero:first-child .hero-inner {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 16px !important;
    min-height: 0 !important;
    padding: 24px 0 22px !important;
    align-items: start !important;
    overflow: hidden !important;
  }

  .home-hero-bg-wrap .hero-inner > *,
  main > section.hero:first-child .hero-inner > *,
  .page-hero .wrap > *,
  .page-hero-grid > *,
  .blog-hero-grid > *,
  .content-grid > *,
  .split > *,
  .cta-grid > *,
  .card-grid > *,
  .proof-grid > *,
  .footer-grid > * {
    min-width: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
  }

  .home-hero-bg-wrap .hero-inner > div:first-child {
    display: block !important;
  }

  .hero h1,
  .page-hero h1,
  h1 {
    max-width: 100% !important;
    width: 100% !important;
    font-size: clamp(32px, 9vw, 42px) !important;
    line-height: 1.03 !important;
    letter-spacing: -0.045em !important;
    margin-bottom: 12px !important;
    overflow-wrap: anywhere !important;
    text-wrap: balance !important;
  }

  .section-intro h2,
  .body-copy h2,
  .cta-grid h2,
  .reviews-head h2,
  .reviews-intro h2,
  h2 {
    max-width: 100% !important;
    font-size: clamp(26px, 7vw, 34px) !important;
    line-height: 1.08 !important;
    letter-spacing: -0.035em !important;
    overflow-wrap: anywhere !important;
  }

  h3 {
    max-width: 100% !important;
    overflow-wrap: anywhere !important;
  }

  .eyebrow,
  .breadcrumbs,
  .hero p.lead,
  .page-hero p,
  .section-intro p,
  .body-copy p,
  .body-copy li,
  .legal-card p,
  .legal-card li,
  .service-card p,
  .area-card p,
  .blog-card p,
  .info-card p {
    max-width: 100% !important;
    min-width: 0 !important;
    overflow-wrap: anywhere !important;
  }

  .eyebrow {
    font-size: 11.5px !important;
    line-height: 1.35 !important;
    letter-spacing: .075em !important;
    margin-bottom: 8px !important;
  }

  .hero p.lead,
  .page-hero p,
  .section-intro p,
  .body-copy p,
  .body-copy li {
    font-size: 15.5px !important;
    line-height: 1.52 !important;
  }

  .breadcrumbs {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 6px !important;
    width: 100% !important;
    font-size: 12.5px !important;
    line-height: 1.35 !important;
    margin-bottom: 10px !important;
  }

  .hero-actions,
  .cta-actions,
  .reviews-actions,
  .cash-actions-v18,
  .form-actions {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 9px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .btn,
  .call-pill,
  button,
  input[type="submit"] {
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .hero-actions .btn,
  .cta-actions .btn,
  .reviews-actions .btn,
  .cash-actions-v18 .btn,
  .btn {
    width: 100% !important;
    min-height: 43px !important;
    padding: 10px 12px !important;
    border-radius: 13px !important;
    font-size: 13.5px !important;
    line-height: 1.12 !important;
    text-align: center !important;
  }

  .trust-row {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 7px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin-top: 12px !important;
    overflow: visible !important;
  }

  .trust-row span {
    min-width: 0 !important;
    width: 100% !important;
    padding: 7px 8px !important;
    border-radius: 12px !important;
    font-size: 11.5px !important;
    line-height: 1.2 !important;
    white-space: normal !important;
    text-align: center !important;
  }

  .hero-card,
  .hero-info-card,
  .areas-hero-card,
  .blog-hero-card,
  .service-card,
  .info-card,
  .area-card,
  .blog-card,
  .quote-panel,
  .legal-card,
  .highlight-box,
  .proof,
  .review-card,
  .contact-map-copy,
  .contact-map-box,
  .cash-strip-v18 {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding: 17px !important;
    border-radius: 18px !important;
  }

  .hero-card h2,
  .hero-info-card h2,
  .areas-hero-card h2,
  .blog-hero-card h2 {
    font-size: 22px !important;
    line-height: 1.12 !important;
    margin-bottom: 8px !important;
  }

  .quick-list,
  .hero-info-links,
  .blog-hero-links,
  .area-quick-links,
  .compact-list {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 8px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow: visible !important;
    margin-top: 10px !important;
  }

  .quick-list a,
  .hero-info-links a,
  .blog-hero-links a,
  .area-quick-links a,
  .compact-list a {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 39px !important;
    padding: 9px 11px !important;
    border-radius: 12px !important;
    font-size: 13px !important;
    line-height: 1.15 !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
  }

  .page-hero,
  main > section.page-hero:first-child {
    padding-top: 86px !important;
    padding-bottom: 28px !important;
  }

  main > section.page-hero:first-child .wrap,
  main > section.page-hero.hero-split:first-child .wrap,
  main > section.page-hero.blog-hero:first-child .wrap,
  main > section.page-hero.areas-hero:first-child .wrap,
  .blog-hero-grid,
  .page-hero-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 15px !important;
    align-items: start !important;
    width: calc(100% - 28px) !important;
    max-width: var(--max) !important;
    margin-left: auto !important;
    margin-right: auto !important;
    overflow: hidden !important;
  }

  .card-grid,
  .proof-grid,
  .footer-grid,
  .content-grid,
  .split,
  .cta-grid,
  .review-grid,
  .reviews-grid,
  .trust-strip,
  .blog-hub-grid,
  .blog-hub-featured-grid,
  .notfound-grid,
  .contact-map-grid,
  .form-grid,
  .form-grid.two,
  .form-grid.three,
  .quote-form-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 14px !important;
  }

  .service-card img,
  .blog-card img,
  .blog-hub-card img,
  .image-panel,
  .image-panel img {
    width: 100% !important;
    max-width: 100% !important;
  }

  .service-card img,
  .blog-card img,
  .blog-hub-card img {
    height: auto !important;
    aspect-ratio: 16 / 10 !important;
    object-fit: cover !important;
    border-radius: 14px !important;
    margin-bottom: 12px !important;
  }

  .image-panel {
    aspect-ratio: 4 / 3 !important;
    max-height: 380px !important;
    overflow: hidden !important;
  }

  .proof-grid .proof strong,
  .proof strong {
    font-size: 25px !important;
    line-height: 1.1 !important;
  }

  .quote-form,
  form,
  label,
  input,
  select,
  textarea {
    max-width: 100% !important;
    min-width: 0 !important;
  }

  input,
  select,
  textarea,
  .quote-form input,
  .quote-form select,
  .quote-form textarea {
    min-height: 48px !important;
    padding: 11px 12px !important;
    border-radius: 12px !important;
    font-size: 16px !important;
  }

  textarea,
  .quote-form textarea {
    min-height: 108px !important;
  }

  .contact-map-box iframe {
    min-height: 300px !important;
  }

  .site-footer {
    padding-top: 38px !important;
    padding-bottom: 96px !important;
  }
}

@media (max-width: 768px) {
  body {
    padding-bottom: 82px !important;
  }

  #tf-desktop-actions {
    display: none !important;
  }

  #tf-mobile-action-bar {
    position: fixed !important;
    left: 8px !important;
    right: 8px !important;
    bottom: 8px !important;
    z-index: 9800 !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px !important;
    width: auto !important;
    max-width: calc(100% - 16px) !important;
    min-width: 0 !important;
    padding: 6px !important;
    border-radius: 16px !important;
    overflow: hidden !important;
    background: rgba(5, 6, 7, 0.94) !important;
    border: 1px solid rgba(255, 255, 255, 0.14) !important;
    box-shadow: 0 14px 40px rgba(0,0,0,0.35) !important;
    backdrop-filter: blur(14px) !important;
    -webkit-backdrop-filter: blur(14px) !important;
  }

  #tf-mobile-action-bar .tf-mobile-action-row {
    display: contents !important;
  }

  #tf-mobile-action-bar .tf-mobile-action-chat,
  #tf-mobile-action-bar .tf-mobile-action-quote,
  #tf-mobile-action-bar .tf-mobile-action-call {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 42px !important;
    padding: 8px 4px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 12px !important;
    font-size: 11.5px !important;
    font-weight: 950 !important;
    line-height: 1.05 !important;
    white-space: nowrap !important;
    text-align: center !important;
    text-decoration: none !important;
    overflow: hidden !important;
  }

  #tf-mobile-action-bar .tf-mobile-action-chat {
    grid-column: 1 !important;
    background: #111417 !important;
    color: #ffffff !important;
    border: 1px solid rgba(255,255,255,0.14) !important;
  }

  #tf-mobile-action-bar .tf-mobile-action-quote {
    grid-column: 2 !important;
    background: #bcff14 !important;
    color: #050607 !important;
    border: 1px solid #bcff14 !important;
  }

  #tf-mobile-action-bar .tf-mobile-action-call {
    grid-column: 3 !important;
    background: #506ffd !important;
    color: #ffffff !important;
    border: 1px solid #506ffd !important;
  }
}

@media (max-width: 430px) {
  .wrap,
  html body .wrap,
  html body .reviews-section .wrap,
  main > section.page-hero:first-child .wrap,
  main > section.page-hero.hero-split:first-child .wrap,
  main > section.page-hero.blog-hero:first-child .wrap,
  main > section.page-hero.areas-hero:first-child .wrap,
  .blog-hero-grid,
  .page-hero-grid {
    width: calc(100% - 24px) !important;
  }

  .site-header .nav-wrap {
    width: calc(100% - 16px) !important;
  }

  .site-header .brand {
    width: 124px !important;
    max-width: 124px !important;
  }

  .site-header .brand img {
    width: 110px !important;
    max-width: 110px !important;
  }

  .site-header .menu-toggle {
    min-width: 72px !important;
    padding: 0 11px !important;
  }

  .hero h1,
  .page-hero h1,
  h1 {
    font-size: clamp(30px, 8.7vw, 38px) !important;
  }

  .hero-card,
  .hero-info-card,
  .areas-hero-card,
  .blog-hero-card,
  .service-card,
  .info-card,
  .area-card,
  .blog-card,
  .quote-panel,
  .legal-card,
  .highlight-box,
  .proof,
  .review-card,
  .cash-strip-v18 {
    padding: 15px !important;
    border-radius: 16px !important;
  }
}

@media (max-width: 360px) {
  .site-header .brand {
    width: 112px !important;
    max-width: 112px !important;
  }

  .site-header .brand img {
    width: 98px !important;
    max-width: 98px !important;
  }

  .site-header .menu-toggle {
    min-width: 66px !important;
    font-size: 13px !important;
  }

  .trust-row {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  #tf-mobile-action-bar .tf-mobile-action-chat,
  #tf-mobile-action-bar .tf-mobile-action-quote,
  #tf-mobile-action-bar .tf-mobile-action-call {
    font-size: 11px !important;
  }
}

@media (min-width: 769px) and (max-width: 980px) {
  body {
    padding-bottom: 0 !important;
  }

  #tf-mobile-action-bar,
  #tf-desktop-actions {
    display: none !important;
  }
}

@media (min-width: 981px) and (max-width: 1120px) {
  html,
  body {
    max-width: 100% !important;
    overflow-x: hidden !important;
  }

  .site-header .nav-wrap {
    width: calc(100% - 28px) !important;
    padding-left: 12px !important;
    padding-right: 12px !important;
    gap: 10px !important;
  }

  .site-header .brand {
    width: 138px !important;
    max-width: 138px !important;
  }

  .site-header .brand img {
    width: 122px !important;
    max-width: 122px !important;
  }

  .site-header .site-nav {
    gap: 12px !important;
  }

  .site-header .site-nav a {
    font-size: 13px !important;
  }

  .site-header .call-pill {
    display: none !important;
  }
}
