/* UX/UI layer. Colours, type, components and section order stay as built. Loads after the section styles. */

/* Header: only the main bar sticks, at one height */
@media (min-width: 768px) { .site-header { top: -41px; } }
@media (min-width: 1025px) {
	.mainbar.is-shrunk .mainbar__inner { padding-top: 10px; padding-bottom: 10px; }
	.mainbar.is-shrunk .site-logo img { width: 180px; }
	.mainbar.is-shrunk .mainnav__link { padding-top: 13px; padding-bottom: 13px; }
}
.topbar__item a { display: inline-flex; align-items: center; gap: inherit; color: inherit; text-decoration: none; }
.topbar__item a:hover .topbar__text { text-decoration: underline; }
.mega { max-height: calc(100vh - 110px); }

/* Keyboard focus is always visible */
:focus-visible { outline: 3px solid #f9a825; outline-offset: 3px; }

/* Hero */
.hero__video { background: #000 var(--hero-poster, none) center / cover no-repeat; }
@media (min-width: 768px) and (max-width: 1100px) { .hero__title span { font-size: clamp(3.2rem, 8.2vw, 5.1rem); line-height: 1.16; } }
.ux-trust { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 22px 0 0; font-family: var(--pc-font-body); font-size: 16px; line-height: 1.3; color: #fff; }
.ux-trust b { font-weight: 600; }
.ux-stars { display: inline-flex; gap: 2px; color: #f9a825; line-height: 0; }
@media (max-width: 767px) { .ux-trust { justify-content: center; margin-top: 14px; } }

/* Reviews: score row */
.ux-score { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; width: 100%; max-width: var(--pc-max); margin: 0 auto 34px; font-family: var(--pc-font-body); font-size: 18px; color: var(--pc-text); }
.ux-score__n { font-family: var(--pc-font-head); font-size: 44px; font-weight: 700; line-height: 1; color: var(--pc-ink); }
.ux-score .ux-stars svg { width: 24px; height: 24px; }
.ux-score__link { margin-left: auto; display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; color: #b8431f; text-decoration: underline; text-underline-offset: 4px; }
@media (max-width: 1340px) { .ux-score { padding: 0 20px; } }
@media (max-width: 767px) { .ux-score__link { margin-left: 0; width: 100%; } }
.reviews__track:focus-within .reviews__row { animation-play-state: paused; }

/* Readability: same greys, one step darker so body text passes 4.5:1 */
:root { --pc-muted: #666; }
.footer-bottom__text { color: #666; }
.why-item__text, .why__item p, .why__list p { font-size: 15px; line-height: 1.45; color: #555; }
.why-item__title, .why__item h3, .why__list h3 { font-size: 17px; line-height: 1.3; }
.space-card__list li, .space-card__list li a, .space-card__list span { color: var(--pc-text); }

/* Instagram tiles (shown when the Instagram feed plugin is not active) */
.ux-ig { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; }
.ux-ig__tile { display: block; aspect-ratio: 1 / 1; overflow: hidden; background: #eee; }
.ux-ig__tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.ux-ig__tile:hover img { transform: scale(1.04); }
@media (max-width: 1024px) { .ux-ig { grid-template-columns: repeat(3, 1fr); } .ux-ig__tile:nth-child(n+4) { display: none; } }
@media (max-width: 767px) { .ux-ig { grid-template-columns: repeat(2, 1fr); } .ux-ig__tile:nth-child(n+3) { display: block; } .ux-ig__tile:nth-child(5) { display: none; } }

/* Forms: visible labels, 16px fields, messages beside the field */
.pc-form__label { display: block; width: 100%; margin: 0 0 6px; font-family: var(--pc-font-body); font-size: 14px; font-weight: 600; line-height: 1.3; color: #111; text-align: left; }
.pc-form__opt { font-weight: 400; color: #666; }
.pc-form .pc-form__field { font-size: 16px; font-weight: 500; }
.pc-form__group { align-items: flex-start; align-content: flex-start; }
.pc-form__field[aria-invalid="true"] { border-color: #b3261e; box-shadow: 0 0 0 1px #b3261e; }
.pc-form__error { display: block; width: 100%; margin-top: 5px; font-family: var(--pc-font-body); font-size: 14px; font-weight: 600; line-height: 1.3; color: #b3261e; text-align: left; }

/* Fluent Forms: the same visible labels, 16px fields and focus ring as the theme's own forms */
.pc-ff .frm-fluent-form .ff-el-input--label { position: static; width: auto; height: auto; margin: 0 0 6px; padding: 0; overflow: visible; clip: auto; white-space: normal; }
.pc-ff .frm-fluent-form .ff-el-input--label label { display: block; margin: 0; font-family: var(--pc-font-body); font-size: 14px; font-weight: 600; line-height: 1.3; color: #111; text-align: left; }
.pc-ff .frm-fluent-form .ff-el-form-control { font-size: 16px; font-weight: 500; }
.pc-ff .frm-fluent-form input.ff-el-form-control::placeholder, .pc-ff .frm-fluent-form textarea.ff-el-form-control::placeholder { color: transparent; }
.pc-ff .frm-fluent-form .ff-el-form-control:focus-visible { outline: 3px solid #f9a825; outline-offset: 2px; }
.pc-ff .frm-fluent-form .ff-t-container { align-items: flex-end; }

/* Phone and tablet: Call and Quote within thumb reach */
.ux-bar { display: none; }
.ux-menu-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 16px 20px 120px; }
.ux-menu-actions .btn, .ux-bar .btn { display: block; width: 100%; padding-left: 10px; padding-right: 10px; font-size: 16px; text-align: center; }
@media (max-width: 1024px) {
	.ux-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 98; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 10px 12px calc(10px + env(safe-area-inset-bottom)); background: #000; box-shadow: 0 -8px 24px rgba(0, 0, 0, .28); transition: transform .25s ease; }
	.ux-bar.is-away { transform: translateY(110%); }
	body { padding-bottom: 76px; }
	html.has-modal .ux-bar, html.ux-menu-open .ux-bar { transform: translateY(110%); }
	html.ux-menu-open { overflow: hidden; }
	/* 44px touch targets, same look */
	.footer-menu a { min-height: 44px; }
	.footer-head__icon { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; }
	.footer-social__link { width: 44px; height: 44px; }
	.footer-bottom__text a { display: inline-flex; align-items: center; min-height: 44px; }
	.space-card__head { min-height: 44px; }
	.mobile-nav__arrow { padding: 14px; top: 7px; }
	.pc-carousel__arrow { padding: 13px; }
	.pc-carousel__dot { position: relative; }
	.pc-carousel__dot::after { content: ""; position: absolute; inset: -17px; }
	.btn { min-height: 44px; }
}

/* Motion: quiet for anyone who asks for less */
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	.reviews__row, .clients__track, [class*="marquee"] { animation: none !important; }
	.reviews__viewport { overflow-x: auto; }
	*, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* Gallery tabs: every photo cropped to the same square */
.gallery-card__img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }

/* Tablet: the hero copy never runs wider than the screen */
.hero__content { max-width: 100%; }

/* Why choose us: the corner shape that hangs past the photo no longer widens the page on phones */
.why { overflow-x: clip; }

@media (max-width: 1024px) {
	/* Top bar links and the phone icon: 44px hit area, same height bar */
	.topbar__item a, .hbox--phone .hbox__icon, .footer-head__title a { position: relative; }
	.topbar__item a::after, .footer-head__title a::after { content: ""; position: absolute; left: -6px; right: -6px; top: 50%; height: 44px; transform: translateY(-50%); }
	.hbox--phone .hbox__icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; transform: translate(-50%, -50%); }
}
@media (max-width: 767px) {
	.sec--blog .pc-carousel__arrow--prev, .pc-carousel--gallery .pc-carousel__arrow--prev { left: -14px; }
	.sec--blog .pc-carousel__arrow--next, .pc-carousel--gallery .pc-carousel__arrow--next { right: -14px; }
}
