/* The enquiry follows the ruled layout of the workshop drawing.
   Action buttons are hand-torn masking-tape strips with struck typewriter ink. */
.site-header nav .contact-link,
.hero-enquiry,
.enquiry-submit,
.enquiry-reset,
.copy-reference {
  --tape-tilt: -1.1deg;
  --tape-font: 'Courier New', 'American Typewriter', Courier, var(--type-drawing);
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border-style: solid;
  border-color: transparent;
  border-width: 8px 28px 9px 28px;
  border-image-source: url('./tape-strip-a.svg');
  border-image-slice: 8 28 9 28 fill;
  border-image-width: 8px 28px 9px 28px;
  border-image-repeat: stretch;
  border-radius: 0;
  color: #1c1a16;
  font-family: var(--tape-font);
  font-weight: 700;
  font-synthesis: weight;
  letter-spacing: .045em;
  text-shadow: .4px 0 0 #1c1a1655, -.3px .35px 0 #1c1a162a;
  transform: rotate(var(--tape-tilt));
  transition: transform .18s ease, filter .18s ease, color .18s ease, opacity .18s ease;
}

.site-header nav .contact-link:hover,
.hero-enquiry:hover,
.enquiry-submit:hover:not(:disabled),
.enquiry-reset:hover:not(:disabled),
.copy-reference:hover:not(:disabled) {
  background: transparent;
  color: #100f0d;
  filter: brightness(1.04) drop-shadow(0 2px 3px #04132440);
  transform: rotate(calc(var(--tape-tilt) * .35)) translateY(-1px);
}

.site-header nav .contact-link:active,
.hero-enquiry:active,
.enquiry-submit:active:not(:disabled),
.enquiry-reset:active:not(:disabled),
.copy-reference:active:not(:disabled) {
  filter: brightness(.98);
  transform: rotate(var(--tape-tilt)) translateY(.5px);
}

.site-header nav .contact-link {
  --tape-tilt: 1.15deg;
  border-width: 8px 26px 9px 26px;
  border-image-source: url('./tape-strip-b.svg');
  border-image-slice: 8 26 9 26 fill;
  border-image-width: 8px 26px 9px 26px;
  padding: 2px 2px 3px;
  font-size: .875rem;
  line-height: 1.35;
}

.header-location a {
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color .2s ease;
}

.header-location a:hover {
  color: var(--accent);
}

.hero-enquiry {
  --tape-tilt: -1.35deg;
  justify-content: space-between;
  gap: 14px;
  width: fit-content;
  padding: 4px 2px 5px;
  font-size: .9375rem;
  line-height: 1.4;
  margin-top: 26px;
  margin-left: -10px;
}

.hero-enquiry span {
  transition: transform .2s ease;
}

.hero-enquiry:hover span {
  transform: translateX(3px);
}

.hero .scroll-cue {
  display: flex;
  width: fit-content;
  margin-top: 15px;
}

.service-list .service-enquiry,
.service-list .service-guide {
  margin: 14px 0 0;
}

.enquiry {
  scroll-margin-top: 36px;
}

.enquiry .contact-main {
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.2fr);
  grid-template-areas: "intro sheet" "contact sheet";
  grid-template-rows: auto 1fr;
  gap: 36px 10%;
  margin: 0;
}

.enquiry-intro {
  grid-area: intro;
}

.enquiry h2 {
  max-width: none;
  margin: 18px 0 24px;
}

.enquiry-intro > p:not(.eyebrow):not(.enquiry-note) {
  max-width: 36ch;
  color: #d5e3ef;
}

.enquiry-note {
  font-family: var(--type-note);
  font-size: 1.75rem;
  line-height: 1.2;
  transform: rotate(-3deg);
  transform-origin: left center;
  margin: 25px 0 0;
}

.enquiry .contact-info {
  grid-area: contact;
  border-top: 1px solid #91b2cb77;
  padding-top: 20px;
  align-self: start;
}

.enquiry .contact-info > p {
  font-size: 1rem;
  margin-top: 0;
}

.workshop-hours {
  margin: 18px 0 22px;
  padding: 14px 0;
  border-top: 1px solid #91b2cb55;
  border-bottom: 1px solid #91b2cb55;
  display: grid;
  gap: 7px;
  font-size: .9375rem;
  line-height: 1.5;
}

.workshop-hours > div {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr);
  gap: 12px;
  align-items: baseline;
}

.workshop-hours dt {
  color: #c0d3e3;
}

.workshop-hours dd {
  margin: 0;
  color: var(--fg);
}

.workshop-hours dd.mono {
  font-size: .875rem;
}

.enquiry-sheet {
  grid-area: sheet;
  border-top: 1px solid #c0d3e3;
  min-width: 0;
}

.sheet-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 15px 0;
  border-bottom: 1px solid #91b2cb77;
}

.sheet-heading .mono {
  font-size: .75rem;
  letter-spacing: .04em;
}

.enquiry-sheet-note {
  font-family: var(--type-note);
  font-size: 1.375rem;
  line-height: 1.2;
  transform: rotate(-3deg);
}

.enquiry-demo {
  font-size: .875rem;
  line-height: 1.6;
  color: #c0d3e3;
  margin: 18px 0 28px;
  max-width: 55ch;
}

.enquiry [hidden] {
  display: none !important;
}

.service-choice {
  border: 0;
  padding: 0;
  margin: 0 0 26px;
  min-width: 0;
}

.service-choice legend {
  padding: 0;
  margin-bottom: 10px;
  font-size: 1rem;
}

.service-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 22px;
}

.service-options label {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 48px;
  padding: 0 8px;
  border-bottom: 1px solid #91b2cb77;
  cursor: pointer;
  transition: border-color .2s ease, background-color .2s ease, color .2s ease;
}

.service-options label:hover {
  border-bottom-color: #c9dfef;
  background: #f3f7fb0d;
}

.service-options input {
  width: 18px;
  height: 18px;
  accent-color: #fff;
  margin: 0;
  flex-shrink: 0;
}

.service-options label:has(input:checked) {
  border-bottom-color: #fff;
  background: #f3f7fb14;
  color: #fff;
}

.enquiry-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px 20px;
}

.enquiry-field {
  min-width: 0;
}

.field-wide {
  grid-column: 1 / -1;
}

.enquiry-field label {
  display: block;
  margin: 0 0 7px;
  font-size: .9375rem;
}

.enquiry-field label > span {
  color: var(--muted);
  font-size: .8125rem;
}

.enquiry-field input,
.enquiry-field textarea {
  display: block;
  width: 100%;
  max-width: 100%;
  min-height: 46px;
  border: 1px solid #91b2cbaa;
  border-radius: 0;
  background: #10365b;
  color: var(--fg);
  padding: 10px 12px;
  font: inherit;
  font-size: 1rem;
  line-height: 1.5;
  box-shadow: none;
  transition: border-color .2s ease, background-color .2s ease;
}

.enquiry-field input:hover,
.enquiry-field textarea:hover {
  border-color: #c0d3e3;
}

.enquiry-field input:focus,
.enquiry-field textarea:focus {
  border-color: #fff;
  background: #0e3051;
}

.enquiry-field textarea {
  resize: vertical;
  min-height: 98px;
}

#registration {
  text-transform: uppercase;
  font-family: var(--type-drawing);
  letter-spacing: .06em;
}

.enquiry-field input[type="date"] {
  min-width: 0;
  appearance: none;
}

.enquiry-field input[type="date"]::-webkit-date-and-time-value {
  text-align: left;
}

.enquiry :is(input, textarea, button):focus-visible {
  outline: 2px solid #fff;
  outline-offset: 4px;
}

.enquiry :is(input, textarea)[aria-invalid="true"] {
  border-color: #ffd1b6;
}

.field-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-top: 6px;
}

.field-meta .field-help {
  margin: 0;
}

.field-counter {
  font-size: .75rem;
  color: #a9c4da;
  white-space: nowrap;
  flex-shrink: 0;
}

.field-counter.is-near-limit {
  color: #ffdcc5;
}

.field-help,
.field-error {
  font-size: .8125rem;
  line-height: 1.5;
  margin: 6px 0 0;
}

.field-help {
  color: #c0d3e3;
}

.field-error {
  color: #ffdcc5;
}

.enquiry-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  margin: 28px 0 0;
}

.enquiry-submit {
  --tape-tilt: -.95deg;
  justify-content: space-between;
  gap: 22px;
  padding: 4px 2px 5px;
  min-height: 48px;
  cursor: pointer;
  font-size: .9375rem;
  margin-left: -10px;
}

.enquiry-submit span {
  transition: transform .2s ease;
}

.enquiry-submit:hover:not(:disabled) span {
  transform: translateX(3px);
}

.manual-note {
  font-size: .8125rem;
  line-height: 1.5;
  color: #c0d3e3;
}

.enquiry-reset {
  --tape-tilt: 1.05deg;
  border-width: 8px 24px 9px 24px;
  border-image-source: url('./tape-drafting.svg');
  border-image-slice: 8 24 9 24 fill;
  border-image-width: 8px 24px 9px 24px;
  min-height: 44px;
  padding: 2px 2px 3px;
  cursor: pointer;
  font-size: .875rem;
  color: #16283a;
}

.enquiry-reset + .enquiry-reset {
  --tape-tilt: -.85deg;
}

#enquiry-preview-title,
#enquiry-receipt-title {
  font-weight: 400;
  font-size: 1.625rem;
  line-height: 1.3;
  margin: 24px 0 14px;
  letter-spacing: -.015em;
}

#enquiry-preview-title:focus,
#enquiry-receipt-title:focus {
  outline: none;
}

#enquiry-preview-title:focus-visible,
#enquiry-receipt-title:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 5px;
}

.reference-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 20px;
  margin: 8px 0 14px;
  padding: 12px 14px;
  border: 1px solid #91b2cb88;
  background: #10365b;
}

.enquiry-reference {
  margin: 0;
  font-size: .875rem;
  overflow-wrap: anywhere;
  color: #fff;
}

.copy-reference {
  --tape-tilt: 1.1deg;
  border-width: 7px 22px 8px 22px;
  border-image-source: url('./tape-drafting.svg');
  border-image-slice: 8 24 9 24 fill;
  border-image-width: 7px 22px 8px 22px;
  margin-left: auto;
  min-height: 36px;
  padding: 1px 2px 2px;
  cursor: pointer;
  font-size: .8125rem;
  color: #16283a;
}

.enquiry button:disabled {
  opacity: .55;
  cursor: not-allowed;
}

.preview-notice {
  font-size: 1rem;
  color: #d5e3ef;
}

.enquiry-summary {
  margin: 28px 0;
  border-top: 1px solid #91b2cb77;
}

.enquiry-summary > div {
  display: grid;
  grid-template-columns: 125px minmax(0, 1fr);
  gap: 20px;
  padding: 14px 0;
  border-bottom: 1px solid #91b2cb77;
}

.enquiry-summary dt {
  font-size: .875rem;
  color: #c0d3e3;
}

.enquiry-summary dd {
  margin: 0;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.preview-next {
  font-size: .9375rem;
  line-height: 1.65;
  color: #d5e3ef;
}

@media (max-width: 1100px) {
  .enquiry .contact-main {
    column-gap: 6%;
    grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  }

  .enquiry-actions {
    gap: 15px;
  }
}

@media (max-width: 760px) {
  .brand-mark {
    width: min(41vw, 158px);
  }

  .site-header nav .contact-link {
    border-width: 7px 21px 8px 21px;
    border-image-width: 7px 21px 8px 21px;
    padding: 1px 0 2px;
    font-size: .8125rem;
    white-space: nowrap;
  }

  .hero-enquiry {
    position: absolute;
    top: calc(100svh - 174px);
    left: calc(var(--pad) - 10px);
    margin: 0;
    border-width: 7px 24px 9px 24px;
    border-image-width: 7px 24px 9px 24px;
    padding: 2px 0 3px;
    min-height: 42px;
    font-size: .875rem;
  }

  .hero .scroll-cue {
    top: calc(100svh - 118px);
    margin: 0;
  }

  .enquiry {
    scroll-margin-top: 20px;
  }

  .enquiry .contact-main {
    grid-template-columns: 1fr;
    grid-template-areas: "intro" "sheet" "contact";
    grid-template-rows: auto;
    gap: 28px;
  }

  .enquiry h2 {
    margin: 16px 0 20px;
  }

  .enquiry-intro > p:not(.eyebrow):not(.enquiry-note) {
    margin: 0;
    max-width: 42ch;
  }

  .enquiry-note {
    display: none;
  }

  .enquiry .contact-info {
    margin-top: 12px;
  }

  .sheet-heading {
    gap: 12px;
  }

  .enquiry-demo {
    margin-bottom: 24px;
  }
}

@media (max-width: 760px) and (max-height: 700px) {
  .hero-enquiry {
    top: calc(100svh - 162px);
    padding: 1px 0 2px;
    min-height: 40px;
  }

  .hero .scroll-cue {
    top: calc(100svh - 112px);
  }
}

@media (max-width: 380px) {
  .enquiry-fields {
    grid-template-columns: 1fr;
  }

  .service-options {
    column-gap: 12px;
    font-size: .9375rem;
  }

  .sheet-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 9px;
  }

  .enquiry-summary > div {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .copy-reference {
    margin-left: 0;
  }
}

@media (max-width: 360px) {
  .chapter-nav {
    font-size: .75rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-header nav .contact-link:hover,
  .hero-enquiry:hover,
  .enquiry-submit:hover:not(:disabled),
  .enquiry-reset:hover:not(:disabled),
  .copy-reference:hover:not(:disabled) {
    transform: rotate(var(--tape-tilt));
  }
}

@media print {
  .hero-enquiry,
  .enquiry-actions,
  .enquiry-demo,
  .copy-reference,
  .field-counter {
    display: none !important;
  }

  .enquiry .contact-main {
    display: block;
  }

  .enquiry-sheet {
    break-inside: avoid;
    border-color: #8baac1;
  }

  .reference-row {
    background: #ffffff;
    border-color: #8baac1;
  }

  .enquiry-reference {
    color: #123c65;
  }

  .enquiry-field input,
  .enquiry-field textarea {
    background: #ffffff;
    color: #123c65;
    border-color: #8baac1;
  }
}
