/* Oak & Stone 6.7.1 — self-balancing card grids.
   Fewer (or more) service cards or towns: rows re-centre instead of leaving a gap. */

/* A town slot left empty in Customize → Business Details → Service areas hides its card. */
html body .elementor .e-con.area-card:has(.elementor-heading-title:empty){display:none!important}

/* Services grid + city cards: flexible rows; a short last row sits in the centre. */
html body main .elementor .e-con.atlas-grid,
html body .elementor .e-con.e-con.areas-grid{display:flex!important;flex-direction:row!important;flex-wrap:wrap!important;justify-content:center!important;align-content:flex-start!important;align-items:stretch!important}
html body main .elementor .e-con.atlas-grid{--per:4;--g:16px;gap:var(--g)!important}
html body .elementor .e-con.e-con.areas-grid{--per:3;--g:16px;gap:var(--g)!important}
html body main .elementor .e-con.atlas-grid>.e-con,
html body .elementor .e-con.e-con.areas-grid>.e-con{flex:0 0 calc((100% - (var(--per) - 1) * var(--g)) / var(--per))!important;max-width:calc((100% - (var(--per) - 1) * var(--g)) / var(--per))!important;width:auto!important;min-width:0!important}
html body main .elementor .e-con.atlas-grid>.e-con{height:clamp(250px,21vw,330px)!important}
html body .elementor .e-con.e-con.areas-grid>.e-con{height:clamp(220px,17vw,270px)!important}
/* Only one or two cards left: let them grow a little instead of looking lost. */
html body main .elementor .e-con.atlas-grid:not(:has(>.e-con:nth-child(3))),
html body .elementor .e-con.e-con.areas-grid:not(:has(>.e-con:nth-child(3))){--per:2}
html body main .elementor .e-con.atlas-grid:not(:has(>.e-con:nth-child(2))),
html body .elementor .e-con.e-con.areas-grid:not(:has(>.e-con:nth-child(2))){--per:1;max-width:560px!important;margin-inline:auto!important}

@media (max-width:1000px){
  html body main .elementor .e-con.atlas-grid{--per:2;--g:12px}
  html body main .elementor .e-con.atlas-grid>.e-con{height:clamp(190px,44vw,300px)!important}
}
@media (max-width:900px){ html body .elementor .e-con.e-con.areas-grid{--per:2} }
@media (max-width:767px){
  html body main .elementor .e-con.atlas-grid{--g:10px}
  html body main .elementor .e-con.atlas-grid>.e-con{height:clamp(190px,52vw,250px)!important}
  html body .elementor .e-con.e-con.areas-grid{--g:12px}
  html body .elementor .e-con.e-con.areas-grid>.e-con{height:clamp(150px,42vw,220px)!important}
}

/* Phones: the home headline and buttons come first, the photo follows (the offer is visible without scrolling). */
@media(max-width:767px){html body main .ed-home .ed-plate{order:3!important;margin:22px 0 6px!important}}

/* 6.7.2: service and project pages that still use the older split hero (.hero + .hero-img)
   get the same framed photo card as Kitchens/Bathrooms, instead of a photo that runs to the
   screen edge and grows with the monitor. CSS only: no page re-import needed. */
@media(min-width:801px){
html body main .hero:not(.hero-home){display:grid!important;grid-template-columns:minmax(0,.86fr) minmax(0,1.14fr)!important;align-items:center;gap:clamp(26px,4vw,72px);padding:clamp(32px,4vw,70px) var(--pad)!important;min-height:0!important;border-bottom:1px solid var(--rule)}
html body main .hero:not(.hero-home)>.hero-copy,html body main .hero:not(.hero-home)>.e-con-inner>.hero-copy{padding:0!important;width:auto!important;max-width:none!important}
html body main .hero:not(.hero-home) h1{font-size:clamp(43px,5.6vw,92px)}
html body main .hero:not(.hero-home) .hero-img{position:relative!important;width:100%!important;height:auto!important;min-height:0!important;aspect-ratio:1.4;align-self:center;overflow:hidden;border-radius:var(--r,14px);box-shadow:0 18px 44px rgba(29,33,37,.10)}
html body main .hero:not(.hero-home) .hero-img .elementor-widget-container,html body main .hero:not(.hero-home) .hero-img .elementor-image{position:absolute;inset:0;height:100%}
html body main .hero:not(.hero-home) .hero-img img{position:absolute!important;inset:0;width:100%!important;height:100%!important;object-fit:cover;border-radius:inherit}
}
@media(max-width:800px){
html body main .hero:not(.hero-home) .hero-img{width:auto!important;margin:0 clamp(18px,5vw,36px) 32px!important;height:clamp(210px,58vw,380px)!important;border-radius:var(--r,14px);overflow:hidden;box-shadow:0 14px 34px rgba(29,33,37,.10)}
}

/* 6.7.2: Home reviews (real Google review excerpts with project photos), before "Our story". */
html body main .e-con.home-reviews{display:flex!important;flex-direction:column;align-items:center;text-align:center;padding:clamp(56px,7vw,112px) var(--pad)!important;gap:0}
html body main .home-reviews>.elementor-widget-heading .elementor-heading-title{max-width:22ch;margin:6px auto 0;font-size:clamp(34px,4.2vw,62px);line-height:1.06}
html body main .home-reviews .hr-score{margin:clamp(18px,2.4vw,30px) 0 0}
html body main .home-reviews .hr-score p{margin:0}
html body main .home-reviews .hr-word{font:600 clamp(30px,3vw,44px)/1.1 var(--serif);color:var(--ink,#1d2125)}
html body main .home-reviews .hr-stars span,html body main .home-reviews .hr-stars-sm span{display:inline-block;letter-spacing:3px;line-height:1;color:transparent;-webkit-background-clip:text;background-clip:text}
html body main .home-reviews .hr-stars span{font-size:clamp(28px,2.6vw,36px);margin:6px 0 4px;background-image:linear-gradient(90deg,var(--gold,#c9a23a) calc(var(--r,5) / 5 * 100%),#d8d4cc 0)}
html body main .home-reviews .hr-count{font-size:16px;opacity:.78}
html body main .e-con.hr-grid{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr));gap:clamp(16px,2vw,30px);width:100%;max-width:1320px;margin:clamp(30px,4vw,54px) auto 0;text-align:left}
html body main .e-con.hr-card{display:flex!important;flex-direction:column;gap:0;padding:clamp(18px,2vw,30px)!important;border-radius:28px;background:color-mix(in srgb,var(--gold,#c9a23a) 8%,#fff)!important;border:0!important;box-shadow:none}
html body main .hr-card .hr-photo img{width:100%!important;max-width:100%!important;height:auto!important;aspect-ratio:1/1!important;object-fit:cover!important;border-radius:16px;display:block}
html body main .hr-card .hr-stars-sm{margin-top:18px}
html body main .hr-card .hr-stars-sm p{margin:0}
html body main .hr-card .hr-stars-sm span{font-size:21px;background-image:linear-gradient(90deg,var(--gold,#c9a23a),var(--gold,#c9a23a))}
html body main .hr-card .elementor-widget-heading{margin-top:12px}
html body main .hr-card .elementor-heading-title{font-size:clamp(21px,1.7vw,26px)!important;line-height:1.2}
html body main .hr-card .hr-meta p{margin:4px 0 0;font-size:13px;letter-spacing:.06em;text-transform:uppercase;opacity:.7}
html body main .hr-card .hr-quote p{margin:12px 0 0;font-size:17px;line-height:1.7}
html body main .home-reviews>.elementor-widget-button{margin-top:clamp(28px,3vw,44px)}
@media(max-width:1024px){html body main .e-con.hr-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:767px){html body main .e-con.hr-grid{grid-template-columns:minmax(0,1fr)}html body main .hr-card .hr-photo img{aspect-ratio:4/3!important}}

/* Social buttons with no link (no profile on that network) are hidden. */
html body .rn-footer .elementor-widget-button:has(a.elementor-button[href="#"]){display:none!important}

/* Long email addresses wrap inside the footer column. */
html body .rn-footer a[href^="mailto:"]{overflow-wrap:anywhere;word-break:break-word}
