/* ThoreauPro site styles. Mobile first; wider layouts are added at 44rem and 64rem. */

@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-variable.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}

:root {
  --fir: #1e3a32;        /* evergreen: hero, buttons, headings */
  --fir-deep: #14271f;
  --tape: #f2c230;       /* tape-measure yellow: the one accent */
  --paper: #f6f7f4;
  --white: #ffffff;
  --ink: #1d2327;
  --steel: #56636a;      /* secondary text */
  --line: #d3d9d4;

  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --wrap: 68rem;
  --gutter: 1.125rem;
  --radius: 4px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img { max-width: 100%; height: auto; }

a { color: var(--fir); text-underline-offset: 0.18em; }
a:hover { color: var(--fir-deep); }

:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 2px; }

h1, h2, h3 {
  font-stretch: 112%;
  font-weight: 750;
  line-height: 1.08;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

h2 { font-size: clamp(1.6rem, 1.2rem + 1.8vw, 2.25rem); color: var(--fir); }
h3 { font-size: 1.125rem; letter-spacing: -0.005em; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -4rem;
  z-index: 10;
  padding: 0.6rem 0.9rem;
  background: var(--tape);
  color: var(--ink);
  font-weight: 650;
  border-radius: var(--radius);
}
.skip-link:focus { top: 0.5rem; }

/* ---- Header ------------------------------------------------------------ */

.site-header { background: var(--paper); }

.site-header__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.25rem 1.5rem;
  padding-block: 0.9rem;
}

.brand {
  font-stretch: 122%;
  font-weight: 850;
  font-size: 1.3rem;
  letter-spacing: -0.02em;
  color: var(--fir);
  text-decoration: none;
}

.site-nav { display: flex; flex-wrap: wrap; gap: 0.15rem 1.25rem; }

.site-nav a {
  padding-block: 0.35rem;
  font-size: 0.95rem;
  font-weight: 550;
  color: var(--ink);
  text-decoration: none;
}
.site-nav a:hover { text-decoration: underline; text-decoration-thickness: 2px; }

/* ---- Buttons ----------------------------------------------------------- */

.button {
  display: inline-block;
  padding: 0.85rem 1.35rem;
  background: var(--fir);
  color: var(--white);
  font-family: inherit;
  font-size: 1.0625rem;
  font-weight: 650;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  border: 0;
  border-radius: var(--radius);
}
.button:hover { background: var(--fir-deep); color: var(--white); }

.button--tape { background: var(--tape); color: var(--ink); }
.button--tape:hover { background: #ffd24a; color: var(--ink); }

.button--block { display: block; width: 100%; }

/* ---- Tape edge: the tick-marked strip under the green header blocks ---- */

.tape-edge {
  height: 1.6rem;
  background-color: var(--tape);
  background-image:
    repeating-linear-gradient(90deg, var(--ink) 0 2px, transparent 2px 5rem),
    repeating-linear-gradient(90deg, var(--ink) 0 1px, transparent 1px 1rem);
  background-size: 100% 62%, 100% 32%;
  background-repeat: no-repeat;
  background-position: var(--gutter) 0, var(--gutter) 0;
}

/* ---- Hero -------------------------------------------------------------- */

.hero { background: var(--fir); color: var(--white); }

.hero__inner { padding-block: 2.75rem 3rem; }

.hero__title {
  max-width: 15ch;
  font-size: clamp(2.35rem, 1.3rem + 5.6vw, 4.6rem);
  font-stretch: 118%;
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.03em;
}

.hero__lede {
  max-width: 34rem;
  margin-top: 1.4rem;
  font-size: 1.2rem;
  line-height: 1.45;
  color: rgb(255 255 255 / 0.92);
}

.hero__actions { margin-top: 1.75rem; }

.hero__proof {
  max-width: 34rem;
  margin-top: 1.75rem;
  padding-top: 1.1rem;
  border-top: 1px solid rgb(255 255 255 / 0.28);
  font-size: 0.975rem;
  color: rgb(255 255 255 / 0.85);
}

.hero :focus-visible,
.service-head :focus-visible { outline-color: var(--white); }

/* ---- Sections ---------------------------------------------------------- */

.section { padding-block: 3rem; }
.section--tint { background: #eaeee9; }

.section__intro { max-width: 40rem; margin-top: 0.7rem; color: var(--steel); }

.empty { margin-top: 1.5rem; }

/* ---- Rate sheet -------------------------------------------------------- */

.rates { margin-top: 1.75rem; border-top: 2px solid var(--ink); }

.rates__row { border-bottom: 1px solid var(--line); }

.rates__link {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "what rate"
    "deposit deposit";
  gap: 0.35rem 1rem;
  padding: 1.05rem 0.25rem 1.05rem 0.75rem;
  border-left: 5px solid transparent;
  color: var(--ink);
  text-decoration: none;
}
.rates__link:hover,
.rates__link:focus-visible {
  background: var(--white);
  border-left-color: var(--tape);
  color: var(--ink);
}
.rates__link:hover .rates__name { text-decoration: underline; text-decoration-thickness: 2px; }

.rates__what { grid-area: what; min-width: 0; }

.rates__name {
  display: block;
  font-stretch: 110%;
  font-weight: 720;
  font-size: 1.2rem;
  line-height: 1.2;
  color: var(--fir);
}

.rates__tagline { display: block; margin-top: 0.25rem; font-size: 0.975rem; color: var(--steel); }

.rates__rate { grid-area: rate; text-align: right; white-space: nowrap; }

.rates__amount {
  display: block;
  font-stretch: 112%;
  font-weight: 800;
  font-size: 1.6rem;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.rates__unit { display: block; margin-top: 0.2rem; font-size: 0.85rem; color: var(--steel); }

.rates__deposit {
  grid-area: deposit;
  font-size: 0.925rem;
  font-weight: 550;
  font-variant-numeric: tabular-nums;
}

.rates__minimum {
  display: inline-block;
  margin-left: 0.4rem;
  padding: 0.05rem 0.45rem;
  background: var(--tape);
  border-radius: 2px;
  font-size: 0.85rem;
  font-weight: 650;
}

/* ---- Steps ------------------------------------------------------------- */

.steps {
  display: grid;
  gap: 1.5rem;
  margin-top: 1.75rem;
  counter-reset: step;
}

.steps li {
  position: relative;
  padding-left: 3.1rem;
  counter-increment: step;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: -0.2rem;
  width: 2.2rem;
  font-stretch: 118%;
  font-weight: 850;
  font-size: 2.3rem;
  line-height: 1;
  color: var(--fir);
}

.steps p { margin-top: 0.35rem; color: var(--steel); }

/* ---- Terms ------------------------------------------------------------- */

.terms { display: grid; gap: 1.4rem 2.5rem; margin-top: 1.75rem; }
.terms dt { font-stretch: 110%; font-weight: 720; font-size: 1.125rem; }
.terms dd { margin-top: 0.3rem; max-width: 34rem; color: var(--steel); }

/* ---- About ------------------------------------------------------------- */

.about p { max-width: 40rem; margin-top: 0.9rem; font-size: 1.2rem; line-height: 1.5; }

/* ---- Service page ------------------------------------------------------ */

.service-head { background: var(--fir); color: var(--white); }
.service-head .wrap { padding-block: 1.5rem 2.25rem; }

.crumb { font-size: 0.95rem; }
.crumb a { color: rgb(255 255 255 / 0.88); }
.crumb a::before { content: "\2039\00a0"; }

.service-head h1 {
  max-width: 18ch;
  margin-top: 1.1rem;
  font-size: clamp(2.1rem, 1.3rem + 4.2vw, 3.6rem);
  font-stretch: 118%;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
}

.service-head__tagline {
  max-width: 34rem;
  margin-top: 0.9rem;
  font-size: 1.15rem;
  color: rgb(255 255 255 / 0.9);
}

.service { display: grid; gap: 2.5rem; align-items: start; }

.service__about h2 { font-size: 1.45rem; }
.service__about h2:not(:first-child) { margin-top: 2rem; }

.service__blurb { max-width: 38rem; margin-top: 0.7rem; }

.jobs { margin-top: 0.8rem; max-width: 38rem; border-top: 1px solid var(--line); }
.jobs li { padding: 0.6rem 0; border-bottom: 1px solid var(--line); }

.note { max-width: 38rem; margin-top: 1rem; font-size: 0.95rem; color: var(--steel); }

/* The rate ticket */

.ticket {
  padding: 1.4rem 1.25rem 1.5rem;
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: 6px 6px 0 var(--fir);
}

.ticket__heading { font-size: 1.05rem; color: var(--steel); font-weight: 600; letter-spacing: 0; }

.ticket__rate { display: flex; align-items: baseline; gap: 0.5rem; margin-top: 0.5rem; }

.ticket__amount {
  font-stretch: 118%;
  font-weight: 850;
  font-size: 3.4rem;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--fir);
  font-variant-numeric: tabular-nums;
}

.ticket__unit { font-weight: 600; color: var(--steel); }

/* Tape meter: one cell per hour, the deposit hours filled yellow */

.meter {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  margin-top: 1.4rem;
  padding-bottom: 1.5rem;
  border-left: 2px solid var(--ink);
}

.meter__hour {
  position: relative;
  height: 2.5rem;
  border-block: 2px solid var(--ink);
  border-right: 2px solid var(--ink);
  background-color: var(--paper);
  background-image: repeating-linear-gradient(90deg, transparent 0 calc(25% - 1px), var(--ink) calc(25% - 1px) 25%);
  background-size: 100% 38%;
  background-repeat: no-repeat;
}

.meter__hour--deposit { background-color: var(--tape); }

.meter__mark {
  position: absolute;
  right: 0;
  top: calc(100% + 0.4rem);
  transform: translateX(50%);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--steel);
  white-space: nowrap;
}
.meter__hour:last-child .meter__mark { transform: none; }

.ticket__lines { margin-top: 0.9rem; border-top: 1px solid var(--line); }

.ticket__lines > div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--line);
}
.ticket__lines dt { color: var(--steel); }
.ticket__lines dd { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }

.ticket__fine { margin-top: 0.9rem; font-size: 0.9rem; color: var(--steel); }

.ticket .button { margin-top: 1.2rem; }

/* Other services */

.others { display: grid; gap: 0 2.5rem; margin-top: 1.25rem; border-top: 1px solid #c3cbc5; }

.others a {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 0.75rem 0.25rem;
  border-bottom: 1px solid #c3cbc5;
  color: var(--ink);
  text-decoration: none;
}
.others a:hover .others__name { text-decoration: underline; text-decoration-thickness: 2px; }

.others__name { font-weight: 650; color: var(--fir); }
.others__rate { font-size: 0.95rem; color: var(--steel); white-space: nowrap; font-variant-numeric: tabular-nums; }

/* ---- Booking form ------------------------------------------------------- */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.service-head--compact h1 { margin-top: 0.3rem; font-size: clamp(1.8rem, 1.2rem + 3vw, 2.75rem); max-width: 22ch; }

.book-step { margin-top: 1.1rem; font-size: 0.95rem; font-weight: 600; color: var(--tape); }

.form-wrap { max-width: 44rem; }

.form-intro { max-width: 38rem; }

.fieldset { margin: 0 0 2.25rem; padding: 0; border: 0; min-width: 0; }

.fieldset > legend {
  padding: 0;
  margin-bottom: 0.9rem;
  font-stretch: 112%;
  font-weight: 750;
  font-size: 1.45rem;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--fir);
}

.fieldset__hint { margin: -0.4rem 0 1rem; color: var(--steel); }

.field { margin-bottom: 1.2rem; }
.field--short { max-width: 22rem; }

.field label,
.field__static { display: block; font-weight: 650; }

.field__static { margin-top: -0.2rem; font-weight: 500; color: var(--steel); font-size: 0.95rem; }

.field__hint { margin-top: 0.15rem; font-size: 0.925rem; color: var(--steel); }

.optional { font-weight: 400; color: var(--steel); }

.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field select,
.field textarea {
  display: block;
  width: 100%;
  margin-top: 0.4rem;
  padding: 0.7rem 0.8rem;
  background: var(--white);
  color: var(--ink);
  font: inherit;
  /* 16px minimum stops phones zooming the page when a field is focused */
  font-size: max(1rem, 16px);
  line-height: 1.35;
  border: 2px solid #7f8b85;
  border-radius: var(--radius);
}

.field textarea { resize: vertical; min-height: 6rem; }

.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible { outline: 3px solid var(--tape); outline-offset: 0; border-color: var(--ink); }

.field [aria-invalid="true"] { border-color: #a4261c; }

.field__error { margin-top: 0.4rem; font-size: 0.95rem; font-weight: 600; color: #a4261c; }

.field-row { display: grid; gap: 0 1rem; }

.choices { display: grid; gap: 0.5rem; margin-bottom: 1.3rem; }

.choice {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  padding: 0.75rem 0.85rem;
  background: var(--white);
  border: 2px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
}
.choice:has(input:checked) { border-color: var(--fir); box-shadow: inset 5px 0 0 var(--tape); }
.choice:has(input:focus-visible) { outline: 3px solid var(--ink); outline-offset: 2px; }
.choice input { flex: none; width: 1.25rem; height: 1.25rem; margin: 0.15rem 0 0; accent-color: var(--fir); }
.choice input:focus-visible { outline: none; }

.choice--check { margin-top: 0.9rem; font-weight: 600; }

.policy { max-width: 38rem; }

.form-alert {
  margin-bottom: 1.75rem;
  padding: 0.9rem 1rem;
  background: #fbeceb;
  border-left: 5px solid #a4261c;
  font-weight: 600;
}
.form-alert p { margin: 0; max-width: none; }
.form-alert--info { margin-top: 1.5rem; background: #fdf3cf; border-left-color: var(--tape); font-weight: 500; }

.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.5rem; margin-top: 0.5rem; }
.form-actions .button { cursor: pointer; }

.form-actions--sticky {
  position: sticky;
  bottom: 0;
  margin-inline: calc(var(--gutter) * -1);
  padding: 0.9rem var(--gutter);
  background: var(--paper);
  border-top: 2px solid var(--ink);
}

.form-back { font-size: 0.95rem; }
.form-note { max-width: 36rem; margin-top: 0.9rem; font-size: 0.925rem; color: var(--steel); }

/* Day and window picker */

.days { margin: 1.5rem 0 0; padding: 0; border: 0; border-top: 2px solid var(--ink); min-width: 0; }

.day {
  display: grid;
  gap: 0.6rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--line);
}

.day__weekday { display: block; font-stretch: 110%; font-weight: 720; font-size: 1.1rem; color: var(--fir); }
.day__monthday { display: block; font-size: 0.95rem; color: var(--steel); }
.day--full .day__weekday { color: var(--steel); }

.day__slots { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.6rem; }

.slot { position: relative; display: block; cursor: pointer; }
.slot input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }

.slot__body {
  display: block;
  height: 100%;
  padding: 0.65rem 0.8rem;
  background: var(--white);
  border: 2px solid #7f8b85;
  border-radius: var(--radius);
}
.slot__label { display: block; font-weight: 700; }
.slot__range { display: block; font-size: 0.9rem; color: var(--steel); }

.slot input:checked + .slot__body { background: var(--tape); border-color: var(--ink); }
.slot input:checked + .slot__body .slot__range { color: var(--ink); }
.slot input:focus-visible + .slot__body { outline: 3px solid var(--ink); outline-offset: 2px; }

.slot--off { cursor: default; }
.slot--off input { cursor: default; }
.slot--off .slot__body { background: transparent; border: 2px dashed var(--line); color: var(--steel); }
.slot--off .slot__label { font-weight: 500; text-decoration: line-through; }

/* Review step */

.review { display: grid; gap: 2.5rem; align-items: start; }
.review__main h2 { font-size: 1.45rem; }
.review__main form { margin-top: 2.25rem; }

.summary { margin-top: 0.9rem; border-top: 1px solid var(--line); max-width: 44rem; }
.summary > div { display: grid; gap: 0.1rem 1rem; padding: 0.75rem 0; border-bottom: 1px solid var(--line); }
.summary dt { font-size: 0.925rem; color: var(--steel); }
.summary dd { overflow-wrap: anywhere; }
.summary__change { margin-left: 0.5rem; font-size: 0.925rem; white-space: nowrap; }

.ref { font-variant-numeric: tabular-nums; letter-spacing: 0.04em; white-space: nowrap; }

/* ---- Payment and text pages --------------------------------------------- */

.head-help { margin-top: 0.8rem; font-size: 0.95rem; }
.head-help a { color: var(--white); }
.pay-merchant { max-width: 38rem; margin-top: 1.75rem; }
.pay-form { margin-top: 1.1rem; }
.pay-form .button { font-size: 1.15rem; padding: 1rem 1.6rem; cursor: pointer; }

.prose { max-width: 44rem; }
.prose h1 { font-size: clamp(2rem, 1.3rem + 3.2vw, 3rem); color: var(--fir); }
.prose h2 { margin-top: 2.25rem; font-size: 1.45rem; }
.prose p, .prose ul { margin-top: 0.9rem; }
.prose ul { padding-left: 1.25rem; list-style: disc; }
.prose li + li { margin-top: 0.4rem; }
.prose__meta { color: var(--steel); font-size: 0.95rem; }

/* ---- Notice pages (booking soon, 404, errors) --------------------------- */

.notice-page { padding-block: 2rem 3rem; }
.notice-page h1 { font-size: clamp(2rem, 1.3rem + 3.2vw, 3rem); color: var(--fir); }
.notice-page p { max-width: 36rem; margin-top: 1.1rem; }
.debug { margin-top: 1.1rem; padding: 0.8rem; background: var(--white); border: 1px solid var(--line); overflow-x: auto; font-size: 0.85rem; }

/* ---- Footer ------------------------------------------------------------ */

.site-footer { background: var(--fir-deep); color: rgb(255 255 255 / 0.86); font-size: 0.95rem; }
.site-footer__inner { display: grid; gap: 0.35rem; padding-block: 2rem; }
.site-footer__brand { font-stretch: 122%; font-weight: 850; font-size: 1.15rem; color: var(--white); }
.site-footer a { color: var(--white); }
.site-footer :focus-visible { outline-color: var(--white); }
.site-footer__fine { margin-top: 0.6rem; font-size: 0.85rem; color: rgb(255 255 255 / 0.65); }

/* ---- Tablet and up ----------------------------------------------------- */

@media (min-width: 44rem) {
  :root { --gutter: 2rem; }

  .hero__inner { padding-block: 4rem 4.25rem; }
  .section { padding-block: 4rem; }

  .rates__link {
    grid-template-columns: 1fr 7rem 13.5rem;
    grid-template-areas: "what rate deposit";
    align-items: center;
    gap: 1.5rem;
    padding-block: 1.15rem;
  }
  .rates__deposit { text-align: right; }
  .rates__minimum { display: block; width: fit-content; margin: 0.3rem 0 0 auto; }

  .steps { grid-template-columns: repeat(2, 1fr); gap: 2rem 2.5rem; }
  .terms { grid-template-columns: repeat(2, 1fr); }
  .others { grid-template-columns: repeat(2, 1fr); }

  .service-head .wrap { padding-block: 2rem 3rem; }

  .field-row { grid-template-columns: 1fr 1fr; }
  .field-row:has(.field--zip) { grid-template-columns: 1fr 10rem; }

  .day { grid-template-columns: 11rem 1fr; align-items: center; }
  .summary > div { grid-template-columns: 7rem 1fr; }

  .form-actions--sticky { margin-inline: 0; padding-inline: 0; }
}

/* ---- Desktop ----------------------------------------------------------- */

@media (min-width: 64rem) {
  .steps { grid-template-columns: repeat(4, 1fr); }

  .service { grid-template-columns: minmax(0, 1fr) 23rem; gap: 4rem; }
  .ticket { position: sticky; top: 1.5rem; }

  .review { grid-template-columns: minmax(0, 1fr) 23rem; gap: 4rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

@media print {
  .site-nav, .skip-link, .tape-edge { display: none; }
  .hero, .service-head, .site-footer { background: none; color: var(--ink); }
}
