/* Phone and tablet readability. Desktop artwork and the approved industry framing stay intact. */
@media (max-width: 1200px) {
  html { -webkit-text-size-adjust: 100%; scroll-padding-top: 100px; }
  body { font-size: 16px; }
  .container { width: calc(100% - 48px); }
  .site-header .header-inner { height: 80px; gap: 16px; }
  .site-header .brand { width: 190px; height: 62px; }
  .site-header .header-phone { display: flex; margin-left: auto; min-width: 44px; min-height: 44px; justify-content: center; }
  .site-header .header-phone span { display: none; }
  .site-header .header-quote { min-height: 44px; font-size: 14px; padding: 12px 16px; }
  .site-header .menu-toggle { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px; flex-shrink: 0; width: 44px; height: 44px; padding: 10px; border: 1px solid #dce3eb; border-radius: 5px; background: #fff; }
  .menu-toggle span { display: block; width: 23px; height: 2px; background: var(--navy); }
  .site-header nav { display: none; position: absolute; inset: 100% 0 auto; margin: 0; padding: 12px 24px 20px; background: #fff; border-bottom: 1px solid #dce3eb; box-shadow: 0 14px 25px #10203316; max-height: calc(100vh - 105px); max-height: calc(100dvh - 105px); overflow-y: auto; overscroll-behavior: contain; }
  .site-header nav.open { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 4px 20px; }
  .site-header nav a { display: flex; align-items: center; min-height: 48px; padding: 10px 8px; font-size: 16px; line-height: 1.4; border-bottom: 1px solid #edf0f4; }
  #main p:not(.eyebrow) { font-size: 16px; line-height: 1.65; }
  #main .eyebrow { font-size: 11px; line-height: 1.5; letter-spacing: .1em; }
  #main .btn { min-height: 48px; max-width: 100%; font-size: 15px; line-height: 1.45; white-space: normal; padding: 14px 18px; }
  #main .btn .icon, .gas-card button .icon, .nitrogen-service>.icon { flex-shrink: 0; }
  #main .field-help, #main .advice-help, #main .step-subtitle, #main .privacy-note p,
  #main .aside-note, #main .reference-library-content>p, #main .refrigerant-finder>p,
  #main .welding-player>p, #main .welding-detail { font-size: 14px !important; line-height: 1.6; }
  #main .field>label, #main .need-fieldset legend, .refrigerant-search-field label { font-size: 15px; line-height: 1.5; }
  .field, .form-row, .form-step, .quote-main, .quote-aside { min-width: 0; }
  .field input, .field select, .field textarea, .refrigerant-search-field input { font-size: 16px; min-height: 48px; max-width: 100%; }
  .field textarea { min-height: 120px; }
  .need-options label>span { font-size: 14px; line-height: 1.5; min-height: 60px; }
  .form-actions { gap: 16px; flex-wrap: wrap; }
  .form-actions>span, .back-button { font-size: 14px; }
  .back-button { min-height: 44px; }
  .quote-steps { gap: 12px; }
  .quote-steps>span { font-size: 13px; line-height: 1.45; }
  .quote-steps b { flex-shrink: 0; width: 28px; height: 28px; font-size: 13px; }
  .quote-summary { font-size: 15px; line-height: 1.7; max-width: 100%; }
  .quote-aside dt { font-size: 13px; }
  .quote-aside dd { font-size: 15px; overflow-wrap: anywhere; }
  .catalog-filter button { min-height: 48px; font-size: 14px; line-height: 1.4; }
  .catalog-filter button span { font-size: 13px; }
  .gas-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .gas-card-content { padding: 24px; }
  .gas-card-content h3 { font-size: 24px; line-height: 1.25; overflow-wrap: break-word; }
  .gas-card button, .product-card button, .gpl-choice>button, .nitrogen-app-copy>button,
  .refrigerant-format-choice { min-height: 48px; font-size: 14px; line-height: 1.5; }
  .video-family-link, .sector-video-link, .gpl-contact, .nitrogen-phone { display: flex; align-items: center; min-height: 44px; font-size: 14px; line-height: 1.5; }
  .sector-layout { grid-template-columns: 1fr; gap: 24px; }
  .sector-tabs { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); padding: 12px; gap: 8px; }
  .sector-tab { min-width: 0; min-height: 60px; padding: 14px; font-size: 15px; line-height: 1.4; }
  .sector-tab>span:last-child { display: none; }
  .sector-detail { grid-template-columns: minmax(0,.95fr) minmax(0,1.05fr); }
  .sector-copy { padding: 30px; }
  .sector-copy h3 { font-size: 30px; }
  .sector-copy .sector-tags>span { font-size: 12px; line-height: 1.5; }
  .section-heading>p { max-width: 420px; }
  .section-heading>p br { display: none; }
  .refrigerant-references { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .refrigerant-references small, .laboratory-results small { font-size: 12px; line-height: 1.5; }
  .refrigerant-card h4 { font-size: 15px; }
  .refrigerant-other { font-size: 15px; min-height: 44px; }
  .laboratory-results span { font-size: 14px; }
  .laboratory-results { max-height: 580px; overscroll-behavior: contain; }
  .laboratory-specifications { min-inline-size: 0; }
  .laboratory-specifications legend { max-width: 100%; font-size: 16px; }
  .reference-library>summary { font-size: 16px; min-height: 54px; }
  .reference-summary-hint { font-size: 12px; white-space: normal; }
  .product-card h3, .reference-card h3 { font-size: 17px; line-height: 1.4; }
  .nitrogen-photo-button>span, .refrigerant-photo-button>span, .industrial-photo-button>span,
  .gpl-gallery-photo>span, .gpl-photo-button>span, .reference-photo-button>span,
  .delivery-photo-button>span { font-size: 12px; }
  .departments>span { font-size: 14px; min-width: 0; }
  .departments b { font-size: 12px; flex-shrink: 0; }
  .offer-breakdown strong, .offer-breakdown span, .check-list { font-size: 15px; line-height: 1.6; }
  .faq-list summary { min-height: 56px; font-size: 16px; line-height: 1.5; gap: 16px; }
  .faq-list summary>span { flex-shrink: 0; }
  .footer-top p, .footer-top>a:last-child { font-size: 14px; }
  .footer-bottom { flex-wrap: wrap; font-size: 12px; line-height: 1.6; }
  .footer-bottom a, .footer-bottom button { min-height: 44px; display: inline-flex; align-items: center; font-size: 13px; }
  dialog { max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow-y: auto; padding: 32px 22px 24px; }
  .dialog-close { width: 44px; height: 44px; top: 4px; right: 4px; }
  .product-dialog>img { max-width: 100%; height: min(58vh,650px); height: min(58dvh,650px); }
  .product-dialog>p, .nitrogen-dialog .nitrogen-photo-credit, .nitrogen-photo-credit>span:last-child { font-size: 13px !important; }
  dialog p:not(.eyebrow) { font-size: 15px; }
  a, button, input, select, textarea { touch-action: manipulation; }
}

@media (max-width: 960px) {
  .gas-grid, .refrigerant-gallery, .laboratory-results { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .gpl-intro, .nitrogen-intro, .food-map-layout { gap: 28px; }
  .welding-feature, .purchase-layout, .delivery-layout { grid-template-columns: 1fr; gap: 28px; }
  .welding-player { padding: 24px 24px 0; }
  .welding-copy { padding: 0 24px 28px; }
  .quote-layout { grid-template-columns: minmax(0,1fr); }
  .gpl-choices { grid-template-columns: 1fr; }
  .gpl-choice-number { margin-bottom: 16px; }
  .gpl-choice>p { margin-bottom: 16px; }
  .refrigerant-contact { flex-wrap: wrap; }
  .hero { min-height: 0; }
  .hero-content { padding-block: 56px 28px; }
  .hero h1 { font-size: clamp(36px,5.8vw,56px); }
  .hero-location { position: relative; inset: auto; width: fit-content; max-width: calc(100% - 48px); min-width: 0; margin: 0 24px 26px; }
  .hero-bottom { margin-top: 0; flex-wrap: wrap; gap: 16px 28px; font-size: 14px; }
  .hero-location div>span, .hero-location small, .hero-assurance { font-size: 13px; line-height: 1.5; }
  .hero-assurance .icon { width: 20px; height: 20px; flex-shrink: 0; }
  .hero-link { font-size: 15px; min-height: 44px; }
  .nitrogen-other { flex-wrap: wrap; }
}

@media (max-width: 740px) {
  .sector-detail, .nitrogen-intro, .gpl-intro, .food-map-layout, .faq-layout { grid-template-columns: minmax(0,1fr); }
  .sector-photo { height: 320px; min-height: 0; }
  .sector-photo.contained-photo { height: 320px; padding: 8px; }
  .industry-photo-frame { height: 320px; min-height: 0; }
  .sector-copy { padding: 26px; }
  .section-heading { display: block; }
  .section-heading>p { margin-top: 22px; max-width: none; }
  .nitrogen-app-heading, .industrial-photo-heading, .refrigerant-gallery-heading { display: block; }
  .nitrogen-app-heading>p, .industrial-photo-heading>p, .refrigerant-gallery-heading>p { margin-top: 18px; }
  .nitrogen-supplied-gallery { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .nitrogen-supplied-gallery button, .nitrogen-supplied-gallery button:nth-child(n+4) { grid-column: auto; }
  .nitrogen-supplied-gallery button:nth-child(n+4) img { height: 280px; }
  .nitrogen-supplied-gallery button:last-child { grid-column: 1 / -1; }
}

@media (max-width: 650px) {
  html { scroll-padding-top: 84px; }
  .container { width: calc(100% - 32px); }
  .section { padding-block: 52px; }
  .site-header .header-inner { height: 72px; gap: 8px; }
  .site-header .brand { width: clamp(140px,43vw,180px); height: 54px; }
  .site-header .header-phone { margin-left: auto; }
  .site-header .header-quote { display: none; }
  .site-header nav.open { grid-template-columns: 1fr; gap: 0; padding: 8px 16px 16px; }
  .site-header nav { max-height: calc(100vh - 110px); max-height: calc(100dvh - 110px); }
  .topbar>.container { gap: 8px; flex-wrap: wrap; padding-block: 8px; }
  .topbar { font-size: 11px; line-height: 1.45; }
  .hero-content { padding-top: 36px; }
  .hero h1 { font-size: clamp(32px,7.8vw,46px); line-height: 1.14; }
  .hero h1 em { font-size: .76em; }
  .hero-intro { max-width: 100%; }
  .hero-actions { align-items: stretch; gap: 12px; }
  .hero-actions .btn { width: 100%; justify-content: space-between; }
  .hero-link { padding: 8px 0; }
  .hero-location { margin-inline: 16px; max-width: calc(100% - 32px); padding: 16px; }
  .hero-bottom { justify-content: flex-start; padding-block: 20px; gap: 14px 20px; }
  .hero-bottom>span { font-size: 13px; }
  .hero-bottom strong { font-size: 24px; }
  h2 { font-size: clamp(30px,8vw,38px); }
  .sector-tabs { grid-template-columns: repeat(2,minmax(0,1fr)); padding: 8px; }
  .sector-tab { padding: 12px 10px; font-size: 14px; gap: 8px; }
  .sector-tab>.icon { flex-shrink: 0; }
  .sector-copy h3 { font-size: 28px; }
  .catalog-filter { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
  .catalog-filter button { text-align: left; font-size: 13px; padding: 12px; }
  .gas-grid { grid-template-columns: minmax(0,1fr); gap: 18px; }
  .gas-family-photo, .gas-family-placeholder { height: 220px; }
  .gas-card-content, .gas-card.help-card { padding: 24px; }
  .card-number { font-size: 12px; }
  .refrigerant-finder { padding: 20px 16px; }
  .refrigerant-references { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .refrigerant-references>button { font-size: 16px; padding: 14px 12px; }
  .refrigerant-photo-button>img { height: 220px; }
  .refrigerant-contact { padding: 22px 18px; }
  .refrigerant-contact a { font-size: clamp(19px,5.5vw,25px); }
  .laboratory-results { grid-template-columns: minmax(0,1fr); max-height: 520px; }
  .laboratory-services { gap: 16px; }
  .nitrogen-applications { grid-template-columns: minmax(0,1fr); }
  .nitrogen-app-copy, .laboratory-services article { padding: 22px; }
  .nitrogen-other { padding: 22px; }
  .nitrogen-photo-button>img { height: 260px; }
  .form-step { padding: 24px 18px; }
  .form-row, .form-row.three { grid-template-columns: minmax(0,1fr); gap: 18px; }
  .form-row.three>.field:last-child { grid-column: auto; }
  .need-options { grid-template-columns: minmax(0,1fr); }
  .need-options label>span { padding: 14px; font-size: 15px; min-height: 52px; }
  .quote-steps { padding: 18px 12px; gap: 8px; }
  .quote-steps>span { flex: 1; flex-direction: column; align-items: center; text-align: center; font-size: 12px; }
  .form-actions .btn, .summary-actions .btn { width: 100%; justify-content: center; }
  .summary-actions { flex-direction: column; }
  .quote-summary { padding: 18px 14px; font-size: 14px; }
  .quote-aside { display: block; padding: 24px; }
  .quote-aside dl { display: block; }
  .quote-aside .aside-contact { border-left: 0; border-top: 1px solid #d7dcd7; padding: 22px 0 0; margin: 22px 0 0; }
  .quote-aside .aside-note { margin: 18px 0 0; }
  .reference-library>summary { flex-wrap: wrap; gap: 8px; padding: 18px; }
  .reference-summary-hint { flex-shrink: 1; }
  .closing .container { align-items: flex-start; flex-direction: column; gap: 24px; }
  .closing h2 { font-size: 32px; }
  .closing .btn { width: 100%; justify-content: center; }
  footer { padding-bottom: calc(160px + env(safe-area-inset-bottom,0px)); }
  .mobile-bottom { padding: 8px 12px calc(8px + env(safe-area-inset-bottom,0px)); gap: 8px; }
  .mobile-bottom a { min-height: 48px; font-size: 13px; padding: 10px 8px; gap: 7px; line-height: 1.4; }
  dialog { width: calc(100% - 24px); padding: 48px 18px 20px; }
  .product-dialog { width: calc(100% - 24px); padding: 48px 18px 20px; }
  .product-dialog h3 { font-size: 23px; padding-right: 0; }
}

@media (max-width: 430px) {
  .products-grid, .reference-grid, .reference-library .reference-grid, .refrigerant-gallery,
  .industrial-photos, .gpl-gallery, .nitrogen-supplied-gallery { grid-template-columns: minmax(0,1fr); }
  .reference-photo-button>img, .refrigerant-photo-button>img { height: 250px; }
  .refrigerant-references { grid-template-columns: minmax(0,1fr); }
  .refrigerant-references>button { min-height: 60px; }
  .sector-tabs { grid-template-columns: minmax(0,1fr); }
  .sector-tab { min-height: 52px; }
  .departments { grid-template-columns: 1fr; }
}

/* Keep the assistant reachable above the phone actions, including with a soft keyboard. */
@media (max-width: 1200px) {
  .rg-chat-message p { font-size: 15px; }
  .rg-chat-choice { font-size: 14px !important; min-height: 44px; }
  .rg-chat-header p, .rg-chat-scope, .rg-chat-input-label, .rg-chat-input-help,
  .rg-chat-footer, .rg-chat-availability, .rg-chat-author, .rg-chat-feedback { font-size: 12px; }
  .rg-chat-live-button, .rg-chat-send, .rg-chat-end-live { font-size: 13px !important; min-height: 44px; }
  .rg-chat-close { width: 44px; height: 44px; }
}
@media (max-width: 650px) {
  .rg-chat { --rg-chat-bottom: calc(76px + env(safe-area-inset-bottom,0px)); }
  .rg-chat-launcher { width: 52px; height: 52px; min-height: 52px; padding: 8px; justify-content: center; }
  .rg-chat-launcher-copy { display: none; }
  .rg-chat-panel { position: fixed; inset: auto 12px calc(76px + env(safe-area-inset-bottom,0px)); width: auto; height: min(680px,calc(100vh - 96px - env(safe-area-inset-bottom,0px))); height: min(680px,calc(100dvh - 96px - env(safe-area-inset-bottom,0px))); }
  .rg-chat:has(.rg-chat-panel:not([hidden])) .rg-chat-launcher { visibility: hidden; }
  .rg-chat-header { padding: 14px; }
  .rg-chat-header h2 { font-size: 22px; }
  .rg-chat-scope { padding: 10px 14px; }
  .rg-chat-live-bar { gap: 10px; flex-wrap: wrap; }
  .rg-chat-availability { max-width: none; flex: 1; min-width: 90px; }
  .rg-chat-live-button { max-width: 170px; }
  .rg-chat-input-row { flex-wrap: wrap; }
  .rg-chat-input { flex-basis: 160px; }
  .rg-chat-send { max-width: none; }
}
@media (max-height: 560px) and (max-width: 1200px) {
  .rg-chat-panel { position: fixed; top: 8px; bottom: auto; right: 12px; height: calc(100vh - 16px); height: calc(100dvh - 16px); max-width: calc(100vw - 24px); overflow-y: auto; }
  .rg-chat-panel>* { flex-shrink: 0; }
  .rg-chat-scroll { min-height: 120px; }
  .rg-chat:has(.rg-chat-panel:not([hidden])) .rg-chat-launcher { visibility: hidden; }
}
