/* ============================================================
   Thermal Care — Responsive layer
   Overrides INLINE desktop layout styles at the agreed breakpoints.
   NOTE: selectors match the browser-serialized style attribute
   (colon+space, "repeat(3, 1fr)", rgb() colors) because pages
   render styles via the DC runtime. Raw-string fallbacks included
   where cheap.
   Breakpoints: 375 base · 640 sm · 768 md · 1024 lg · 1280 xl · 1536 2xl
   ============================================================ */

img,svg,video,iframe{max-width:100%}

/* ---------- Below lg (1023px): tablet + mobile ---------- */
@media (max-width:1023.98px){
  [style*="min-width: 1000px"],[style*="min-width:1000px"],[style*="min-width: 1100px"],[style*="min-width:1100px"]{min-width:0!important}
  /* horizontal gutters: every "… 64px" inline padding slims down */
  [style*="px 64px"]{padding-left:32px!important;padding-right:32px!important}
  [style*="0px 64px"]{padding-left:32px!important;padding-right:32px!important}
  /* fluid type (design sizes return at lg+) */
  h1{font-size:clamp(30px,7vw,44px)!important}
  h2[style*="font-size: 3"],h2[style*="font-size:3"]{font-size:clamp(25px,5.5vw,33px)!important}
  b[style*="font-size: 80px"]{font-size:clamp(44px,10vw,64px)!important;letter-spacing:-1px!important}
  b[style*="font-size: 58px"]{font-size:clamp(36px,7vw,48px)!important}
  /* CTA rows may wrap */
  div[style*="display: flex"][style*="gap: 14px"],div[style*="display: flex"][style*="gap: 12px"]{flex-wrap:wrap}
  /* decorative connector lines hide when their grids stack */
  i[style*="position: absolute"][style*="height: 2px"]{display:none!important}
  /* sticky side panels release */
  [style*="position: sticky"][style*="top: 120px"],[style*="position: sticky"][style*="top: 24px"],[style*="position: sticky"][style*="top: 32px"]{position:static!important}
}

/* ---------- md only (768–1023px): 2-column grids ---------- */
@media (min-width:768px) and (max-width:1023.98px){
  [style*="repeat(3, 1fr)"],[style*="repeat(4, 1fr)"],[style*="1.4fr 1fr 1fr 1fr"]{grid-template-columns:repeat(2,1fr)!important}
  [style*="repeat(2, 1fr)"]{gap:24px!important}
}

/* ---------- Below md (767px): single column ---------- */
@media (max-width:767.98px){
  /* all layout grids stack (numbered timeline rows keep their rail) */
  [style*="grid-template-columns"]:not([style*="60px 1fr"]){grid-template-columns:1fr!important}
  [style*="gap: 72px"]{gap:36px!important}
  [style*="gap: 64px"],[style*="gap: 56px"],[style*="gap: 48px"]{gap:32px!important}
  /* stats dividers become stacked rows */
  [style*="border-left: 1px solid rgb(230, 226, 218)"]{border-left:none!important;padding-left:0!important;padding-right:0!important;padding-top:20px!important}
  /* section vertical rhythm */
  [style*="padding: 96px"],[style*="padding: 88px"]{padding-top:64px!important}
  [style*="padding: 80px"],[style*="padding: 76px"],[style*="padding: 72px"]{padding-top:56px!important}
  /* offset hero frame echo tucks in */
  [style*="right: -22px"]{right:-10px!important;bottom:-10px!important}
  [style*="right: -20px"]{right:-10px!important;bottom:-10px!important}
  /* items pinned to a grid column release when the grid stacks */
  [style*="grid-column: 2"]{grid-column:auto!important}
  image-slot{max-width:100%!important;min-width:0!important}
}

/* ---------- Base / sm (below 640px): phones ---------- */
@media (max-width:639.98px){
  [style*="px 64px"],[style*="0px 64px"]{padding-left:20px!important;padding-right:20px!important}
  [style*="padding: 96px"],[style*="padding: 88px"],[style*="padding: 80px"]{padding-top:48px!important}
  /* primary CTAs go full width */
  a[style*="padding: 18px 34px"],a[style*="padding: 17px 32px"],a[style*="padding: 16px 30px"],a[style*="padding: 15px 28px"],a[style*="padding: 15px 26px"],a[style*="padding: 14px 28px"]{display:block!important;width:100%;text-align:center;box-sizing:border-box;align-self:stretch!important}
  /* ledger price rows stack: icon hidden, price under label */
  [style*="44px 1fr auto"]{grid-template-columns:1fr!important;gap:6px!important}
  [style*="44px 1fr auto"]>svg{display:none!important}
  /* dense panels breathe */
  [style*="padding: 44px 40px"]{padding:28px 24px!important}
  [style*="padding: 34px 32px"],[style*="padding: 34px"],[style*="padding: 32px"]{padding:24px 20px!important}
  /* nowrap emphasis figures may wrap on phones */
  b[style*="white-space: nowrap"],span[style*="white-space: nowrap"]{white-space:normal!important}
  /* accreditation / logo strips wrap */
  div[style*="display: flex"][style*="gap: 10px"],span[style*="display: flex"][style*="gap: 10px"],div[style*="display: flex"][style*="gap: 22px"]{flex-wrap:wrap}
  /* timeline rail slims */
  [style*="grid-template-columns: 60px 1fr"]{grid-template-columns:44px 1fr!important;gap:16px!important}
  [style*="width: 60px"][style*="height: 60px"]{width:44px!important;height:44px!important;font-size:15px!important}
  [style*="left: 29px"]{left:21px!important}
  /* forms: full-width inputs, 16px to prevent iOS zoom */
  input,select,textarea{font-size:16px!important;width:100%;box-sizing:border-box}
  /* footer legal rows stack */
  [style*="justify-content: space-between"][style*="flex-wrap: wrap"]{flex-direction:column;align-items:flex-start;gap:10px}
  /* area pills wrap tighter */
  [style*="font-size: 20px"][style*="border-radius: 99px"]{font-size:16px!important;padding:11px 20px!important}
  /* stats big-number blocks */
  [style*="padding-right: 36px"]{padding-right:0!important}
  [style*="padding-left: 36px"]{padding-left:0!important}
}

/* ---------- 2xl: never stretch past design cap ---------- */
@media (min-width:1536px){
  [style*="max-width: 1280px"]{max-width:1280px!important}
  [style*="max-width: 1152px"]{max-width:1152px!important}
}

@media (prefers-reduced-motion:reduce){
  *{animation:none!important;transition:none!important}
}

/* ============================================================
   Static-site layer (added at build): header nav, KB filters, forms
   ============================================================ */
#tc-page{min-width:0}
img{height:auto}
.tc-nav-btn{background:linear-gradient(#f0821e,#f0821e) left bottom / 0% 2px no-repeat;border:none;font:inherit;cursor:pointer;display:flex;align-items:center;gap:6px;padding:14px 0 12px;letter-spacing:0.05em;transition:background-size .25s ease}
.tc-nav-btn:hover,.tc-nav-btn[aria-expanded="true"],.tc-nav-link:hover{background-size:100% 2px}
.tc-nav-link{background:linear-gradient(#f0821e,#f0821e) left bottom / 0% 2px no-repeat;padding:14px 0 12px;transition:background-size .25s ease}
.tc-nav-cta{background:#f0821e;color:#fff;padding:13px 28px;border-radius:8px;font-weight:700;box-shadow:0 6px 16px rgba(240,130,30,.28);transition:transform .18s ease,box-shadow .18s ease,background .18s ease}
.tc-nav-cta:hover{background:#d96f0e;color:#fff;transform:translateY(-2px);box-shadow:0 10px 22px rgba(240,130,30,.36)}
.tc-dd[hidden]{display:none!important}
.tc-dd-link{color:#1e2430;font-size:14.5px;font-weight:600;padding:10px 14px;border-radius:8px;display:block;transition:background .15s ease,transform .15s ease}
.tc-dd-link:hover{background:#fbf3ea;color:#f0821e;transform:translateX(3px)}
.tc-m-head{margin:0;padding:14px 0 6px;font-size:11.5px;font-weight:800;letter-spacing:.12em;text-transform:uppercase;color:#7a8291}
.tc-m-link{display:block;color:#1e2430;font-size:16px;font-weight:600;padding:13px 4px;border-bottom:1px solid #efece5}
#tc-mobile-bar{display:none}
#tc-burger{display:none}
#tc-mobile-menu[hidden]{display:none!important}
@media(max-width:1023.98px){
  #tc-burger{display:inline-flex}
  #tc-desktop-nav{display:none!important}
  #tc-topbar-accred{display:none!important}
  #tc-topbar{padding-left:24px!important;padding-right:24px!important}
  #tc-header{padding:10px 24px!important}
  #tc-header img{height:40px!important}
  #tc-mobile-menu{display:block;max-height:calc(100vh - 100px);overflow-y:auto}
}
@media(max-width:639.98px){
  #tc-mobile-bar{display:flex}
  body{padding-bottom:70px}
  #tc-topbar,#tc-header{padding-left:20px!important;padding-right:20px!important}
  #tc-header{padding-top:8px!important;padding-bottom:8px!important}
  #tc-header img{height:36px!important}
}
.tc-kb-filter[aria-pressed="true"]{border-color:#f0821e!important;background:#fbf3ea!important;color:#c05e12!important}
.tc-kb-filter{border-color:#d7d3cb!important;background:#fff!important;color:#1e2430!important}
.tc-kb-card[hidden]{display:none!important}
#tc-contact-form input:focus,#tc-contact-form textarea:focus{border-color:#1f7bc0;outline:none}
#tc-contact-form.is-sent button{background:#1e2430}

/* GHL enquiry popup (service pages) */
@keyframes ghlFade{from{opacity:0}to{opacity:1}}
@keyframes ghlPop{from{opacity:0;transform:translateY(18px)}to{opacity:1;transform:none}}
#ghl-popup-overlay[hidden]{display:none!important}
#ghl-popup-close-btn:hover{background:#f0821e!important}
