/* Workshop, contact and utility pages */
body:has(main > :is(.custom-hero, .contact-page))::after { opacity: .025; }

.configurator-section,
.super-custom-panel,
.custom-process {
  --service-gutter: calc((100% - var(--page)) / 2);
}

.not-found.photo-fade-hero {
  --photo-hero-focus: 60% 38%;
  min-height: clamp(430px, 69svh, 660px);
  justify-content: stretch;
  padding-inline: 0;
}

.custom-hero-copy,
.not-found-copy {
  display: grid;
  justify-items: start;
  gap: 20px;
  min-width: 0;
}

.custom-hero { --photo-hero-focus: 56% 41%; }

.custom-hero-copy {
  gap: clamp(14px, 1.7vw, 24px);
}

.custom-hero h1,
.contact-main h1,
.not-found h1 {
  max-width: 13ch;
  margin: 0;
  font-size: clamp(2.75rem, 5.9vw, 5.5rem);
  line-height: .99;
  letter-spacing: -.035em;
}

.custom-hero h1 {
  max-width: none;
  font-size: clamp(2.75rem, 4.65vw, 5.5rem);
  text-wrap: pretty;
}

.custom-hero-copy > p,
.not-found-copy > p {
  max-width: 44ch;
  color: var(--muted);
  font-size: 1.06rem;
  line-height: 1.55;
}

.custom-hero-copy > p:not(.custom-price-basis) { color: var(--ink-soft); }

.custom-hero-copy .custom-price-basis,
.not-found-copy .not-found-status {
  color: var(--rust-deep);
  font-size: .85rem;
  font-variant-numeric: tabular-nums;
}

.custom-hero-copy .button-link,
.not-found-copy .button-link,
.contact-main .button-link,
.config-price-card .config-continue {
  justify-content: space-between;
  background: var(--ink);
  color: var(--paper-light);
  border-color: var(--ink);
  text-transform: none;
  letter-spacing: 0;
  font-size: .9rem;
}

.custom-hero-copy .button-link:hover,
.not-found-copy .button-link:hover,
.contact-main .button-link:hover,
.config-price-card .config-continue:hover {
  background: var(--rust-deep);
  color: var(--paper-light);
  border-color: var(--rust-deep);
}

.super-custom-panel .super-custom-visual {
  margin-inline: 0 -40px;
}

.custom-hero-photo img {
  filter: saturate(.79) contrast(.94) brightness(1.045);
}

.not-found-photo img { filter: saturate(.64) contrast(.87) brightness(1.12); }

.configurator-section {
  padding-block: clamp(34px, 5vw, 72px) clamp(58px, 8vw, 116px);
  padding-inline: var(--service-gutter);
  background: transparent;
}

.configurator-heading {
  grid-template-columns: minmax(0, 1fr) minmax(290px, .54fr);
  align-items: end;
  gap: clamp(20px, 5vw, 72px);
  padding-bottom: clamp(24px, 3vw, 44px);
  border-color: var(--line);
}

.configurator-heading h2,
.super-custom-panel h2,
.form-intro h2,
.custom-form-section ~ .faq-section h2 {
  max-width: 19ch;
  margin: 0;
  font-size: var(--heading-section);
  line-height: 1.04;
  letter-spacing: -.035em;
  text-wrap: balance;
}

.super-custom-panel h2,
.form-intro h2,
.custom-form-section ~ .faq-section h2 { font-size: var(--heading-narrative); }

.configurator-shell {
  grid-template-columns: minmax(0, 1fr) minmax(304px, .54fr);
  align-items: start;
  gap: clamp(30px, 6.3vw, 90px);
  padding-top: clamp(34px, 4.5vw, 60px);
}

.config-estimate-strip { display: none; }

.configurator-form,
.config-step,
.config-option-field,
.custom-form fieldset,
.custom-form .field {
  min-width: 0;
}

.configurator-form {
  display: grid;
  gap: clamp(26px, 4vw, 56px);
}

.config-step { padding: 0 0 clamp(28px, 3.8vw, 56px); }
.config-step:last-child { padding-bottom: 0; border-bottom: 0; }
.config-step legend,
.custom-form legend {
  margin: 0 0 18px;
  padding: 2px 0 4px;
  font-size: clamp(1.45rem, 2.4vw, 2.1rem);
  font-family: var(--font-headline);
  font-weight: 400;
  line-height: 1.08;
}
.config-step legend span,
.custom-form legend span {
  display: inline-block;
  margin-right: .75rem;
  color: var(--forest);
  letter-spacing: 0;
  vertical-align: .1em;
}

.config-details { min-width: 0; }
.config-details > summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 1.2rem;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  padding-block: 9px;
  list-style: none;
  cursor: pointer;
  color: var(--ink);
}
.config-details > summary::-webkit-details-marker { display: none; }
.config-details > summary svg { width: 1.2rem; height: 1.2rem; }
.config-details[open] > summary svg { transform: rotate(180deg); }
.config-details > summary:hover { color: var(--rust-deep); }
.config-details > summary:focus-visible { outline-offset: 3px; }

@media (prefers-reduced-motion: no-preference) {
  .config-details > summary svg { transition: transform 180ms var(--motion-out); }
}

.config-finish-step summary {
  grid-template-columns: auto minmax(0, 1fr) 1.2rem;
  padding-block: 16px;
  font: 400 clamp(1.35rem, 2.2vw, 1.95rem)/1.1 var(--font-headline);
}
.config-detail-index { font-size: .65em; color: var(--forest); }
.config-finish-step summary small {
  display: block;
  margin-block-start: 5px;
  color: var(--muted);
  font: 400 .88rem/1.35 var(--font-body);
}
.config-finish-step .config-option-grid { margin-block-start: 12px; }

.config-model-grid {
  gap: 0 20px;
  border: 0;
}

.config-model-card {
  min-height: 64px;
  grid-template-columns: 18px minmax(0, 1fr);
  align-content: start;
  gap: 8px;
  padding: 11px 8px;
  border: 0;
  border-bottom: 1px solid var(--line);
}

.config-model-card input {
  width: 16px;
  height: 16px;
  margin: 2px 0 0;
  accent-color: var(--forest);
}

.config-model-card:hover { background: var(--paper); }
.config-model-card:has(input:checked) {
  background: var(--paper-2);
  color: var(--ink);
  border-color: var(--rust-deep);
}
.config-model-card:has(input:focus-visible) {
  outline: 2px solid var(--forest);
  outline-offset: 2px;
}
.config-model-card strong {
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.35vw, 1.15rem);
  font-weight: 600;
  line-height: 1.15;
  overflow-wrap: anywhere;
}
.config-model-card small {
  margin-top: 5px;
  color: var(--muted);
  font: inherit;
  font-size: .8rem;
  letter-spacing: 0;
  line-height: 1.22;
  text-transform: none;
}

.config-help,
.config-length-guidance {
  margin-top: 15px;
  padding: 0;
  border: 0;
  color: var(--muted);
  font-size: .93rem;
}

.config-length-control {
  grid-template-columns: 46px minmax(0, 1fr) 46px;
  gap: 14px;
  padding: 12px 0;
  border-block: 1px solid var(--line);
}
.config-length-control > div {
  min-width: 0;
  grid-template-columns: 1fr;
  justify-items: center;
  gap: 0;
  text-align: center;
}
.config-length-control output {
  color: var(--ink);
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}
.config-length-control input[type="range"] {
  grid-column: 1;
  width: min(100%, 340px);
  min-height: 34px;
  margin: 0;
  accent-color: var(--forest);
}
.config-length-control p {
  font-size: .76rem;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}
.config-length-control button {
  width: 46px;
  height: 46px;
  color: var(--ink);
  border-color: var(--line);
}
.config-length-control button:is(:hover, :focus-visible) {
  background: var(--ink);
  color: var(--paper-light);
}

.config-option-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.config-option-field,
.custom-form .field { gap: 6px; }
.config-option-field label,
.custom-form .field label {
  min-width: 0;
  align-items: baseline;
  gap: 6px;
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  font-size: .91rem;
  line-height: 1.35;
  letter-spacing: 0;
  text-transform: none;
}
.config-option-field label small {
  color: var(--forest);
  white-space: nowrap;
}
.config-option-field select,
.custom-form .field :is(input, select, textarea) {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  padding: 11px 10px;
  border: 1px solid color-mix(in srgb, var(--ink) 55%, var(--paper));
  border-radius: 0;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  line-height: 1.4;
  caret-color: var(--forest);
}
.config-option-field select { text-overflow: ellipsis; }
.config-option-field select:focus-visible,
.config-length-control input[type="range"]:focus-visible,
.custom-form .field :is(input, select, textarea):focus-visible {
  border-color: var(--forest);
  outline: 2px solid var(--forest);
  outline-offset: 2px;
}
.custom-form .field :is(input, textarea)::placeholder {
  color: var(--muted);
}

.config-price-card {
  position: static;
  top: 16px;
  margin: 0;
  padding: clamp(20px, 2.9vw, 40px);
  border-top: 1px solid var(--ink);
  border-radius: 0;
  background: var(--paper-2);
  color: var(--ink);
}
.config-price-card > .eyebrow,
.config-price-meta,
.config-summary dt,
.config-option-summary > p,
.config-super-custom span {
  color: var(--muted);
  font: inherit;
  font-size: .89rem;
  line-height: 1.4;
  letter-spacing: 0;
  text-transform: none;
}
.config-total {
  margin: 8px 0;
  font-size: clamp(3.4rem, 5.5vw, 5.15rem);
  line-height: 1;
  white-space: nowrap;
}
.config-total,
.config-summary dd,
.config-option-summary strong { font-variant-numeric: tabular-nums; }
.config-price-meta { padding-bottom: 16px; font-size: .8rem; border-color: var(--line); }
.config-summary > div { align-items: baseline; padding: 8px 0; border-color: var(--line); }
.config-selected-dimensions {
  margin-top: 12px;
  padding: 8px 0 0;
  border: 0;
  color: var(--ink);
  letter-spacing: 0;
  font-size: .8rem;
}
.config-option-summary { padding: 14px 0; }
.config-option-summary ul { margin: 8px 0 0; }
.config-option-summary li { gap: 12px; font-size: .92rem; }
.config-quote-note {
  padding: 12px;
  border-color: var(--rust-deep);
  color: var(--ink);
  font-size: .86rem;
}
.config-price-card .config-continue,
.config-price-card .config-super-custom {
  min-height: 48px;
  height: auto;
  padding: 12px;
  font-size: .95rem;
  line-height: 1.4;
}
.config-price-card .config-continue svg,
.config-price-card .config-super-custom svg { flex-shrink: 0; }
.config-price-card .config-super-custom {
  margin-top: 8px;
  padding-inline: 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-body);
  font-weight: 600;
}
.config-price-card .config-super-custom:is(:hover, :focus-visible) {
  color: var(--rust-deep);
  background: transparent;
}
.config-price-card .config-super-custom:focus-visible { outline-color: var(--rust-deep); }
.config-price-card .config-super-custom span { font-size: .81rem; font-weight: 400; }
.config-price-card .config-super-custom:hover span,
.config-price-card .config-super-custom:focus-visible span { color: var(--ink); }
.config-disclaimer {
  margin-top: 14px;
  color: var(--muted);
  font-size: .8rem;
}

.super-custom-panel {
  grid-template-columns: minmax(0, 1.18fr) minmax(0, .82fr);
  align-items: center;
  gap: clamp(24px, 8vw, 115px);
  min-height: 0;
  padding: 0 var(--service-gutter) 0 0;
  border: 0;
  background: var(--paper-grain, none) var(--paper-2);
  color: var(--ink);
}

.super-custom-panel::after { content: none; }
.super-custom-panel .super-custom-visual {
  position: static;
  z-index: auto;
  grid-area: 1 / 1;
  margin: 0;
}

.super-custom-panel > div {
  grid-column: 2;
  padding-block: 20px;
}

.super-custom-visual img {
  height: auto;
  aspect-ratio: 1.58 / 1;
  object-position: center 53%;
  filter: saturate(.86) contrast(.94) brightness(1.06);
}

.super-custom-panel h2 { max-width: 21ch; }
.super-custom-panel p { margin-top: 16px; color: var(--muted); }
.super-custom-panel .text-link { margin-top: 8px; text-transform: none; letter-spacing: 0; font-size: .9rem; }

.custom-process {
  padding: clamp(52px, 8vw, 115px) var(--service-gutter);
  background: transparent;
  color: var(--ink);
}

.custom-process > h2 {
  margin: 0 0 clamp(20px, 3.2vw, 44px);
  font-size: var(--heading-section);
}

.custom-process-layout {
  display: grid;
  grid-template-columns: minmax(0, .86fr) minmax(0, 1.14fr);
  align-items: center;
  gap: clamp(24px, 6.5vw, 92px);
}

.custom-process-layout > figure {
  grid-area: 1 / 2;
  aspect-ratio: 1.36;
  margin: 0;
  border-radius: 0;
}
.custom-process-layout > figure img {
  height: 100%;
  object-position: center 52%;
  filter: saturate(.75) contrast(.91) brightness(1.07);
}

@keyframes workshop-photo-passage {
  from { transform: translateY(2.4%) scale(1.07); }
  to { transform: translateY(0) scale(1); }
}

@supports (view-timeline-name: --custom-workshop) and (animation-range: entry 12% contain 60%) {
  @media screen and (prefers-reduced-motion: no-preference) {
    .custom-process-layout > figure {
      overflow: clip;
      view-timeline-name: --custom-workshop;
    }

    .custom-process-layout > figure img {
      animation: workshop-photo-passage linear both;
      animation-timeline: --custom-workshop;
      animation-range: entry 12% contain 60%;
    }
  }
}

.custom-process ol { display: block; padding-left: 1.65rem; list-style: decimal; }
.custom-process li,
.custom-process li + li {
  display: list-item;
  min-height: 0;
  padding: 0 0 16px 8px;
  border: 0;
  border-bottom: 1px solid var(--line);
}
.custom-process li + li { padding-top: 16px; }
.custom-process li::marker { color: var(--rust-deep); font-weight: 700; font-variant-numeric: tabular-nums; }
.custom-process h3 { margin: 0 0 4px; font-size: clamp(1.35rem, 2vw, 2rem); line-height: 1.15; }
.custom-process p { color: var(--muted); font-size: .97rem; }

.custom-form-section {
  grid-template-columns: minmax(0, .72fr) minmax(0, 1fr);
  gap: clamp(26px, 7vw, 96px);
  padding-block: clamp(40px, 6.4vw, 96px);
  border-top: 1px solid var(--line);
}
.form-intro { top: 28px; }
.form-intro h2 { margin-bottom: 18px; }
.form-contact { margin-top: 22px; }
.form-contact a {
  text-decoration: underline;
  text-underline-offset: .2em;
  text-decoration-thickness: 1px;
}
.custom-form {
  gap: clamp(16px, 2.4vw, 30px);
  min-width: 0;
}
.custom-form fieldset {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 16px;
}
.custom-form legend { padding-bottom: 11px; }
.config-payment-note { color: var(--muted); font-size: .85rem; }
.brief-details { border-block: 1px solid var(--line); }
.brief-details > summary { font-weight: 650; }
.brief-details > fieldset { margin-block: 6px 20px; }
.custom-form .consent { gap: 8px; font-size: .92rem; }
.custom-form .consent input { accent-color: var(--forest); }
.custom-form .submit-button {
  min-height: 54px;
  gap: 12px;
  padding: 10px 16px;
  border-color: var(--forest);
  background: var(--ink);
  font: 700 .93rem/1.2 var(--font-body);
  letter-spacing: 0;
  text-transform: none;
}
.custom-form .submit-button:hover { background: var(--rust-deep); border-color: var(--rust-deep); }
.custom-form .submit-button svg { flex-shrink: 0; }
.custom-form .form-note { margin: -10px 0 0; font-size: .88rem; }
.custom-form .form-status:empty {
  min-height: 0;
  margin-top: calc(-1 * clamp(16px, 2.4vw, 30px));
}
.custom-form-section ~ .faq-section { padding-block: clamp(48px, 7vw, 100px); }
.custom-form-section ~ .faq-section summary {
  min-height: 58px;
  grid-template-columns: minmax(0, 1fr) 22px;
  padding-block: 12px;
  font-size: clamp(1.1rem, 1.55vw, 1.4rem);
  font-weight: 600;
  gap: 10px;
}
.custom-form-section ~ .faq-section details > div { padding: 0 30px 20px 0; }

.contact-page.photo-fade-hero {
  --photo-hero-focus: 55% 48%;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  min-height: clamp(460px, 73svh, 690px);
  padding-inline: 0;
  padding-bottom: clamp(66px, 11svh, 110px);
}

.contact-page.photo-fade-hero > figure { grid-column: auto; }

.contact-main h1 {
  max-width: 17ch;
  font-size: clamp(2.45rem, 1.58rem + 3.5vw, 4.8rem);
  text-wrap: balance;
}
.contact-main > p:not(.eyebrow) {
  max-width: 49ch;
  margin: 20px 0 24px;
  color: var(--ink-soft);
  font-family: var(--font-body);
  font-size: 1.06rem;
}

.contact-details {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 3vw, 44px);
  width: var(--page);
  margin-inline: auto;
  padding-bottom: clamp(42px, 6vw, 90px);
  border-top: 0;
}

.contact-details > div {
  min-width: 0;
  display: grid;
  align-content: start;
  justify-items: start;
  gap: 4px;
  padding: 18px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
}

.contact-details .eyebrow {
  color: var(--muted);
  font-size: .85rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
}

.contact-details a,
.contact-details address {
  margin: 0;
  font: 400 1.06rem/1.4 var(--font-body);
  overflow-wrap: anywhere;
}

.contact-details a {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: .17em;
}
.contact-details a:hover { color: var(--rust-deep); }
.contact-details a.icon-action { min-height: 44px; }
.contact-details p:last-child { margin: 0; font-size: .9rem; }
.contact-page.photo-fade-hero > figure img {
  object-position: var(--photo-hero-focus);
  filter: sepia(.12) contrast(.91) brightness(1.04);
}

.legal-page {
  width: 100%;
  padding: 0;
}
.legal-page > .legal-opening {
  --photo-hero-focus: center 42%;
  max-width: none;
  margin: 0;
  min-height: clamp(315px, 48svh, 510px);
  padding-bottom: clamp(54px, 9svh, 94px);
}
.legal-opening .photo-fade-copy,
.legal-page > .legal-content {
  width: min(var(--page), 920px);
  max-width: none;
  margin-inline: auto;
}
.legal-opening .photo-fade-copy { padding: 0; border: 0; }
.legal-content { padding-bottom: clamp(44px, 6vw, 88px); }
.legal-page h1 {
  max-width: 22ch;
  margin: 0 0 16px;
  overflow-wrap: anywhere;
  font-size: clamp(2rem, 1.37rem + 2.25vw, 3.65rem);
  line-height: 1.04;
  text-wrap: balance;
}
.legal-page header > p:last-child { font-size: .94rem; }
.legal-page section { max-width: 69ch; padding: clamp(20px, 3vw, 35px) 0; }
.legal-page h2 {
  margin-bottom: 10px;
  font-size: clamp(1.35rem, 1.1rem + .85vw, 1.95rem);
  line-height: 1.05;
}
.legal-page section p { overflow-wrap: anywhere; }

@media (min-width: 1060px) and (min-height: 870px) {
  .config-price-card { position: sticky; }
}

@media (max-width: 1050px) {
  .config-model-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .config-estimate-strip:not([hidden]) {
    position: sticky;
    z-index: 5;
    top: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0 12px;
    min-height: 48px;
    margin-inline: calc(-1 * var(--service-gutter));
    padding: 6px var(--service-gutter);
    border-bottom: 1px solid var(--line);
    background: var(--paper);
    color: var(--ink);
    font-size: .875rem;
  }

  .config-estimate-strip span { text-decoration: underline; text-underline-offset: 4px; }
  .config-estimate-strip strong {
    font-size: 1.075rem;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
  }
  .config-estimate-strip:focus-visible { outline-offset: -3px; }
  #config-estimation { scroll-margin-top: 48px; }

  .configurator-form :is(input, select, button) { scroll-margin-top: 48px; }

  .configurator-heading,
  .configurator-shell {
    grid-template-columns: minmax(0, 1fr);
  }
  .configurator-heading { gap: 12px; }
  .config-model-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 800px) {
  .super-custom-panel,
  .custom-process-layout,
  .custom-form-section {
    grid-template-columns: minmax(0, 1fr);
  }

  .custom-hero-copy,
  .not-found-copy { gap: 16px; }
  .custom-hero { --photo-hero-focus: 61% 44%; }

  .super-custom-panel .super-custom-visual,
  .custom-process-layout > figure { margin-inline: calc((var(--page) - 100%) / 2); }
  .custom-hero h1,
  .not-found h1 { font-size: clamp(2.65rem, 9vw, 4.85rem); }

  .super-custom-panel {
    padding: 36px var(--service-gutter) 0;
  }
  .super-custom-panel > div {
    grid-column: auto;
    padding: 0;
  }
  .super-custom-panel .super-custom-visual {
    grid-area: auto;
    margin-inline: calc(-1 * var(--service-gutter));
  }
  .custom-process-layout > figure {
    grid-area: auto;
    aspect-ratio: 16 / 10;
  }
  .contact-page.photo-fade-hero { --photo-hero-focus: 63% 52%; }
  .contact-details { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contact-details > div:last-child { grid-column: 1 / -1; }
  .contact-details a { min-height: 44px; }
}

@media (max-width: 550px) {
  .contact-page.photo-fade-hero {
    min-height: clamp(420px, 67svh, 590px);
    padding-block-end: clamp(34px, 6.5svh, 58px);
  }

  .contact-page.photo-fade-hero > figure::after {
    background:
      var(--photo-header-scrim),
      radial-gradient(ellipse 119% 50% at 18% 56%, #f8f6eff5 23%, #f8f6efbb 63%, transparent 100%);
  }

  .contact-details { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .contact-details > div { padding-block: 12px; }
  .legal-page > .legal-opening { min-height: 290px; padding-block: calc(var(--header) + 36px) 54px; }
  .config-model-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
  .config-model-card { min-height: 60px; }
  .config-option-grid,
  .custom-form fieldset { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 360px) {
  .custom-hero h1 { font-size: 2.35rem; }
}
