.cookie-banner {
  position: fixed;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  max-width: 920px;
  margin: 0 auto;
  padding: 16px 18px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 16px;
  background: rgba(10, 20, 31, .96);
  color: #fff;
  box-shadow: 0 18px 60px rgba(0,0,0,.30);
  backdrop-filter: blur(14px);
}

.cookie-banner__text {
  font-size: 14px;
  line-height: 1.45;
}

.cookie-banner__text a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cookie-banner__accept {
  flex: 0 0 auto;
  border: 0;
  border-radius: 999px;
  padding: 11px 18px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

[data-form-status] {
  min-height: 1.4em;
}

[data-form-status][data-state="success"] {
  font-weight: 600;
}

[data-form-status][data-state="error"] {
  font-weight: 600;
}

.form-honeypot {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  white-space: nowrap !important;
}

@media (max-width: 640px) {
  .cookie-banner {
    align-items: stretch;
    flex-direction: column;
  }

  .cookie-banner__accept {
    width: 100%;
  }
}

.formst-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 2px 0 8px;
  font-size: 12px;
  line-height: 1.45;
}
.formst-consent input { flex: 0 0 auto; margin-top: 3px; }
.formst-consent a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.contact-messengers {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
}
.contact-messengers a {
  font-size: 14px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Contact form checkbox: override the generic full-width input/label rules. */
.contact-form .formst-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 2px 0 18px;
  color: #c6c9ca;
  font-size: 11px;
  line-height: 1.45;
  letter-spacing: .05em;
  text-transform: uppercase;
  cursor: pointer;
}

.contact-form .formst-consent input[type="checkbox"] {
  appearance: auto;
  flex: 0 0 18px;
  display: block;
  width: 18px;
  height: 18px;
  min-width: 18px;
  margin: 0;
  padding: 0;
  border: 0;
  accent-color: #f26722;
}

.contact-form .formst-consent span {
  flex: 1 1 auto;
  min-width: 0;
}

.contact-form .formst-consent a {
  color: #f4f1eb;
}

/* Keep Chromium/Yandex browser autofill consistent with the dark contact form. */
.contact-form input:-webkit-autofill,
.contact-form input:-webkit-autofill:hover,
.contact-form input:-webkit-autofill:focus,
.contact-form textarea:-webkit-autofill,
.contact-form textarea:-webkit-autofill:hover,
.contact-form textarea:-webkit-autofill:focus {
  -webkit-text-fill-color: #f4f1eb;
  -webkit-box-shadow: 0 0 0 1000px #090d0f inset;
  caret-color: #f4f1eb;
  transition: background-color 9999s ease-out 0s;
}

.nav .nav-login {
  border: 1px solid rgba(255,255,255,.34);
  border-radius: 999px;
  padding: 8px 14px;
  margin-left: 6px;
  text-decoration: none;
}
.nav .nav-login::after { content: none; }
.nav .nav-login:hover {
  border-color: #f26722;
  color: #fff;
}

/* Approved logo: reserve space for the contact phone on narrow headers. */
@media (max-width: 900px) {
  .head > nav { display: none; }
}
@media (max-width: 600px) {
  .head { gap: 12px; }
  .head > .brand { flex: 0 1 160px; min-width: 0; }
  .head > .brand > img[src*="formst-logo-"] { width: 160px !important; max-width: 100%; height: auto; }
  .head > .phone { flex-shrink: 0; white-space: nowrap; }
  .site-header .brand > img[src*="formst-logo-"] { width: min(225px, 46vw) !important; height: auto; }
}

/* Shared navigation on every public page. */
.back-to-top {
  position: fixed; left: max(22px, env(safe-area-inset-left)); right: auto;
  bottom: max(var(--back-top-bottom, 22px), env(safe-area-inset-bottom));
  z-index: 100; display: grid; place-items: center; box-sizing: border-box;
  width: 48px; height: 48px; padding: 0; border: 1px solid #d4e4ee45; border-radius: 16px;
  background: #14232cb8; color: #f0f6fa; cursor: pointer;
  backdrop-filter: blur(16px) saturate(130%); -webkit-backdrop-filter: blur(16px) saturate(130%);
  opacity: 0; visibility: hidden; transform: translateY(16px);
  box-shadow: 0 8px 24px #00000030, inset 0 1px 0 #ffffff14;
  transition: opacity .25s, transform .25s, visibility .25s, background .25s;
}
.back-to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top span { display: block; width: 20px; height: 20px; font-size: 0; background: currentColor; mask: url('/assets/icons/tabler/arrow-up.svg') center/contain no-repeat; -webkit-mask: url('/assets/icons/tabler/arrow-up.svg') center/contain no-repeat; }
.back-to-top:hover, .back-to-top:focus-visible { background: #233c49d9; border-color: #ff9b6780; }
.back-to-top:focus-visible { outline: 2px solid #ff9b67; outline-offset: 4px; }
body.case-lightbox-open .back-to-top { visibility: hidden; }
#projects .project-controls { align-items: center; }
.project-count { margin-right: 10px; color: #666a6c; font-size: 13px; white-space: nowrap; font-variant-numeric: tabular-nums; }
#projects .project-controls button:disabled { opacity: .35; cursor: default; }
#projects .project-controls button:disabled:hover, #projects .project-controls button:disabled:focus-visible { background: transparent; color: var(--ink); border-color: #aaa9a4; }
.project-rail:focus-visible { outline: 2px solid #f26722; outline-offset: 3px; }
@media (max-width: 640px) {
  .back-to-top { left: max(12px, env(safe-area-inset-left)); right: auto; width: 44px; height: 44px; border-radius: 14px; }
  #projects .project-controls button { width: 48px; height: 48px; }
}
@media (prefers-reduced-motion: reduce) { .back-to-top { transition: none; } }

/* A site-owned callback panel; native dialog handles focus and Escape. */
.formst-callback-launcher {
  box-sizing: border-box;
  position: fixed; left: max(28px, env(safe-area-inset-left)); bottom: max(28px, env(safe-area-inset-bottom));
  z-index: 110; display: flex; align-items: center; gap: 12px; padding: 10px 20px 10px 10px;
  max-width: calc(100% - 100px); min-height: 54px; border: 1px solid #ffffff36; border-radius: 6px;
  background: #101214; color: #fff; box-shadow: 0 10px 30px #0003;
  font: 600 14px/1.2 Arial, sans-serif; cursor: pointer;
}
.formst-callback-launcher[hidden] { display: none; }
.formst-callback-icon { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 3px; background: #f26722; color: #101214; font-size: 23px; }
.formst-callback-launcher:hover { background: #25292b; }
.formst-callback-launcher:focus-visible, .formst-callback-dialog :focus-visible { outline: 3px solid #f26722; outline-offset: 3px; }
body.case-lightbox-open .formst-callback-launcher, body.formst-media-open .formst-callback-launcher { visibility: hidden; }
body.formst-callback-open { overflow: hidden; }
.formst-callback-dialog {
  box-sizing: border-box;
  position: fixed; inset: auto auto 28px 28px; margin: 0; padding: 0; width: min(430px, calc(100% - 32px));
  max-height: calc(100dvh - 56px); overflow-y: auto; overscroll-behavior: contain;
  border: 1px solid #c7c6c0; border-radius: 8px; background: #f4f1eb; color: #101214;
  box-shadow: 0 24px 80px #0006; font: 15px/1.5 Arial, sans-serif;
}
.formst-callback-dialog::backdrop { background: #080c10a6; }
.formst-callback-dialog * { box-sizing: border-box; }
.formst-callback-head { position: sticky; top: 0; z-index: 1; padding: 26px 28px 0; background: #f4f1eb; }
.formst-callback-dialog .formst-callback-kicker { margin: 0 40px 14px 0; color: #c74b0c; font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.formst-callback-dialog h2 { margin: 0 24px 10px 0; font: 700 27px/1.15 Arial, sans-serif; letter-spacing: -.04em; text-transform: none; }
.formst-callback-dialog #formst-callback-description { margin: 0; color: #555d62; font: 14px/1.5 Arial, sans-serif; }
.formst-callback-close { position: absolute; top: 10px; right: 10px; width: 44px; height: 44px; border: 0; background: transparent; color: #101214; font-size: 28px; cursor: pointer; }
.formst-callback-form { display: grid; gap: 16px; padding: 22px 28px 26px; margin: 0; }
.formst-callback-form > label { display: block; margin: 0; color: #383f43; font: 600 12px/1.4 Arial, sans-serif; }
.formst-callback-form input:not([type=checkbox]), .formst-callback-form textarea {
  display: block; width: 100%; min-width: 0; margin: 7px 0 0; padding: 12px 13px; border: 1px solid #c7c6c0; border-radius: 3px;
  background: #fff; color: #101214; font: 16px/1.4 Arial, sans-serif; box-shadow: none;
}
.formst-callback-form textarea { min-height: 84px; resize: vertical; }
.formst-callback-optional { margin-left: 5px; color: #777d81; font-weight: 400; }
.formst-callback-form > .formst-callback-consent { display: flex; align-items: flex-start; gap: 9px; color: #5e6468; font-size: 11px; font-weight: 400; }
.formst-callback-consent input { flex: 0 0 18px; width: 18px; height: 18px; margin: 1px 0 0; accent-color: #f26722; }
.formst-callback-consent a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.formst-callback-submit { display: flex; align-items: center; justify-content: space-between; width: 100%; min-height: 48px; padding: 13px 16px; border: 0; border-radius: 3px; background: #101214; color: #fff; font: 600 14px/1.4 Arial, sans-serif; cursor: pointer; }
.formst-callback-submit span { color: #f26722; font-size: 20px; }
.formst-callback-submit:disabled { opacity: .6; cursor: wait; }
.formst-callback-dialog .formst-callback-phone { margin: 0; color: #63696d; text-align: center; font: 12px/1.4 Arial, sans-serif; }
.formst-callback-phone a { color: #101214; white-space: nowrap; text-decoration: none; font-weight: 700; }
.formst-callback-form [data-form-status] { margin: 0; font: 13px/1.5 Arial, sans-serif; }
.formst-callback-form [data-form-status]:empty { display: none; }
.formst-callback-form [data-state=error] { color: #a82318; }
.formst-callback-form [data-state=success] { color: #206243; }
@media (max-width: 640px) {
  .formst-callback-launcher { left: max(16px, env(safe-area-inset-left)); bottom: max(16px, env(safe-area-inset-bottom)); min-height: 48px; padding: 8px 14px 8px 8px; gap: 9px; font-size: 13px; }
  .formst-callback-dialog { inset: auto 0 0; width: 100%; max-width: none; max-height: calc(100dvh - 16px); border-radius: 14px 14px 0 0; border-bottom: 0; padding-bottom: env(safe-area-inset-bottom); }
  .formst-callback-head { padding: 24px 22px 0; }
  .formst-callback-form { padding: 20px 22px 24px; gap: 14px; }
}

/* Keep the house title inside its column and allow narrow grids to shrink. */
.house-page .hero-grid > *, .house-page .request-grid > * { min-width: 0; }
.house-page .hero-copy h1 { font-size: clamp(40px, 4.65vw, 72px); overflow-wrap: anywhere; }
.house-page .hero-footnote, .house-page .hero-lead { overflow-wrap: anywhere; }
@media (max-width: 880px) {
  .house-page .hero-copy h1 { font-size: clamp(40px, 8vw, 68px); }
}
@media (max-width: 570px) {
  .house-page .hero-copy h1 { font-size: clamp(34px, 10.2vw, 46px); }
}

/* The same optional private project field works in static and generated forms. */
form .formst-attachment { min-width: 0; max-width: 100%; margin: 0 0 12px; color: inherit; }
form .formst-attachment .formst-attachment-label { display: block; margin: 0 0 8px; color: inherit; font: 600 13px/1.45 Arial, sans-serif; text-transform: none; letter-spacing: 0; }
form .formst-attachment-label span { font-weight: 400; opacity: .75; }
form .formst-attachment input[type=file] {
  display: block; box-sizing: border-box; width: 100%; min-width: 0; max-width: 100%; min-height: 48px;
  margin: 0; padding: 10px; border: 1px solid #a7abad; border-radius: 3px; background: #fff; color: #171c20;
  font: 14px/1.5 Arial, sans-serif; text-transform: none; letter-spacing: 0;
}
form .formst-attachment input[type=file]::file-selector-button { margin-right: 10px; padding: 7px 10px; border: 0; border-radius: 2px; background: #171c20; color: #fff; font: 600 13px/1.3 Arial, sans-serif; cursor: pointer; }
form .formst-attachment input[type=file]:focus-visible { outline: 3px solid #f26722; outline-offset: 3px; }
form .formst-attachment .formst-attachment-hint { margin: 8px 0 0; color: inherit; opacity: .8; font: 12px/1.5 Arial, sans-serif; text-transform: none; letter-spacing: 0; overflow-wrap: anywhere; }
form .formst-attachment .formst-attachment-error { margin: 8px 0 0; color: #a82318; font: 600 13px/1.5 Arial, sans-serif; }
.contact-form .formst-attachment .formst-attachment-error { color: #ffb4a9; }
form .formst-attachment .formst-attachment-remove { width: auto; min-height: 36px; margin-top: 6px; padding: 4px 0; border: 0; background: transparent; color: inherit; font: 600 12px/1.5 Arial, sans-serif; text-decoration: underline; cursor: pointer; }
form .formst-attachment [hidden] { display: none; }

.formst-field-error{display:block;font-size:13px;line-height:1.45;color:#b33722;margin:6px 0 0;text-transform:none;letter-spacing:normal}[aria-invalid="true"]{border-color:#b33722!important;outline-color:#b33722}body .hero-actions .button.primary{background:#f26722!important;color:#101719!important;border:2px solid #ff985f!important;box-shadow:0 5px 20px #0003;font-weight:800}body .hero-actions .button.primary:focus-visible{outline:3px solid white;outline-offset:4px}

.cookie-banner{flex-wrap:wrap}.cookie-banner__accept,.cookie-banner__reject{min-height:44px;min-width:120px;padding:10px 16px;border:1px solid #aab5bd;border-radius:24px;background:#f5f1e9;color:#172a34;font:700 14px/1.4 Arial;cursor:pointer}.formst-cookie-settings{font:inherit;color:inherit;background:transparent;border:0;padding:8px;text-decoration:underline;cursor:pointer}.formst-coal-nav{font-weight:700;white-space:nowrap}@media(max-width:600px){.cookie-banner__accept,.cookie-banner__reject{flex:1}.cookie-banner__text{flex-basis:100%}}
@media(max-width:400px){.hero h1{font-size:clamp(27px,9vw,36px)!important;overflow-wrap:normal}.hero-actions .button{max-width:100%;white-space:normal}}
