/* ------------------------------------------------------------------
   Custom Trade Workflows
   Palette and type ported from the GoDaddy build: Playfair Display over
   Open Sans, near-black on white, muted mauve accent.
   ------------------------------------------------------------------ */

:root {
  --ink:        #151515;
  --ink-2:      #474747;
  --ink-3:      #898989;
  --rule:       #e2e2e2;
  --wash:       #f3f3f3;
  --paper:      #ffffff;
  --accent:     #8f6e6e;
  --accent-dk:  #6f5454;
  --accent-wash:#f4eeee;

  --serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --sans:  'Open Sans', -apple-system, 'Segoe UI', Helvetica, Arial, sans-serif;

  --shell: 71.25rem;
  --gap:   1.5rem;
}

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

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

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

img { max-width: 100%; height: auto; display: block; }

a { color: var(--accent); text-underline-offset: 2px; }
a:hover { color: var(--accent-dk); }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--ink); color: #fff; padding: 0.75rem 1.25rem;
}
.skip:focus { left: 0; }

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

/* ---------------------------------------------------------- typography */
h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 500;
  line-height: 1.18;
  margin: 0;
  text-wrap: balance;
  letter-spacing: -0.005em;
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 3.2vw, 2.25rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.4rem); }

p { margin: 0; }

.lede { font-size: 1.125rem; color: var(--ink-2); }

.eyebrow {
  font-family: var(--sans);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--accent);
}

/* ------------------------------------------------------------ banner */
.promo {
  display: block;
  background: var(--ink);
  color: #fff;
  text-align: center;
  padding: 0.65rem var(--gap);
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.01em;
}
.promo:hover { background: var(--accent-dk); color: #fff; }

/* ------------------------------------------------------------ header */
.site-header {
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
  position: sticky;
  top: 0;
  z-index: 20;
}

.site-header .shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--gap);
  min-height: 5.5rem;
  flex-wrap: wrap;
}

.brand { display: block; flex: none; }
.brand img { width: clamp(190px, 26vw, 300px); height: auto; }

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 2rem;
}

.site-nav a {
  color: var(--ink);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding-block: 0.4rem;
  border-bottom: 2px solid transparent;
  display: block;
}
.site-nav a:hover { color: var(--accent); }
.site-nav a[aria-current="page"] { border-bottom-color: var(--accent); color: var(--accent); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--rule);
  border-radius: 3px;
  width: 2.75rem;
  height: 2.5rem;
  cursor: pointer;
  position: relative;
}
.nav-toggle-bar,
.nav-toggle-bar::before,
.nav-toggle-bar::after {
  content: '';
  position: absolute;
  left: 50%;
  width: 1.25rem;
  height: 2px;
  background: var(--ink);
  transform: translateX(-50%);
}
.nav-toggle-bar { top: 50%; margin-top: -1px; }
.nav-toggle-bar::before { top: -6px; left: 0; transform: none; }
.nav-toggle-bar::after  { top:  6px; left: 0; transform: none; }

@media (max-width: 52rem) {
  .nav-toggle { display: block; }
  .site-nav { flex-basis: 100%; display: none; }
  .site-nav.is-open { display: block; padding-bottom: 1rem; }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav a { padding: 0.7rem 0; border-bottom: 1px solid var(--rule); }
}

/* ---------------------------------------------------------- sections */
.section { padding-block: clamp(3rem, 7vw, 5.5rem); }
.section + .section { border-top: 1px solid var(--rule); }
.section--wash { background: var(--wash); }
.section--tight { padding-block: clamp(2rem, 4vw, 3rem); }

.section > .shell { display: flex; flex-direction: column; gap: 2rem; }

.section-head { display: flex; flex-direction: column; gap: 0.75rem; max-width: 46rem; }
.section-head.is-centered { margin-inline: auto; text-align: center; }

/* -------------------------------------------------------------- hero */
.hero {
  padding-block: clamp(4rem, 11vw, 8rem);
  background: var(--ink);
  color: #fff;
}
.hero .shell { display: flex; flex-direction: column; gap: 1.75rem; align-items: flex-start; }
.hero h1 { color: #fff; max-width: 22ch; }
.hero p { color: #d6d0d0; font-size: 1.15rem; max-width: 55ch; }
.hero .eyebrow { color: #c4a5a5; }

/* ------------------------------------------------------------- cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 1.75rem;
}

.card {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 1.75rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--accent);
}
.section--wash .card { background: var(--paper); }
.card p { color: var(--ink-2); }
.card ul { margin: 0; padding-left: 1.1rem; color: var(--ink-2); }
.card li { margin-block: 0.25rem; }

/* -------------------------------------------------- process diagram
   Replaces a Lucid embed. The connectors are drawn with borders on the
   pseudo-element so there is no image to load and nothing to go stale;
   they turn from horizontal to vertical when the steps stack. */
.flow {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2.5rem;
  counter-reset: flow;
}

.flow-step {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding: 1.5rem 1.25rem;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--accent);
}

/* the arrow into the next step */
.flow-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 50%;
  right: -2.5rem;
  width: 2.5rem;
  height: 1px;
  background: var(--rule);
}
.flow-step:not(:last-child)::before {
  content: '';
  position: absolute;
  top: 50%;
  right: -0.85rem;
  width: 8px;
  height: 8px;
  border-top: 1px solid var(--accent);
  border-right: 1px solid var(--accent);
  transform: translateY(-50%) rotate(45deg);
  z-index: 1;
}

.flow-num {
  font-family: var(--serif);
  font-size: 1.6rem;
  line-height: 1;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.flow-step h3 { font-size: 1.05rem; }
.flow-step p { color: var(--ink-2); font-size: 0.925rem; }

@media (max-width: 60rem) {
  .flow { grid-template-columns: repeat(2, 1fr); gap: 2rem 2.5rem; }
  .flow-step:nth-child(2n)::after,
  .flow-step:nth-child(2n)::before { display: none; }
}

@media (max-width: 34rem) {
  .flow { grid-template-columns: 1fr; gap: 2.25rem; }
  /* connectors rotate to point down the stack */
  .flow-step:not(:last-child)::after {
    top: auto; bottom: -2.25rem; right: auto; left: 50%;
    width: 1px; height: 2.25rem;
  }
  .flow-step:nth-child(2n)::after { display: block; }
  .flow-step:not(:last-child)::before {
    top: auto; bottom: -0.6rem; right: auto; left: 50%;
    transform: translateX(-50%) rotate(135deg);
  }
  .flow-step:nth-child(2n)::before { display: block; }
}

/* ------------------------------------------------------------ prose */
.prose { max-width: 44rem; display: flex; flex-direction: column; gap: 1.1rem; }
.prose ul, .prose ol { margin: 0; padding-left: 1.25rem; display: flex; flex-direction: column; gap: 0.5rem; }
.prose h2, .prose h3 { margin-top: 1rem; }

/* ---------------------------------------------------------- buttons */
.btn {
  display: inline-block;
  font-family: var(--sans);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.95rem 2rem;
  border: 2px solid var(--accent);
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.btn:hover { background: var(--accent-dk); border-color: var(--accent-dk); color: #fff; }
.btn--ghost { background: transparent; color: var(--accent); }
.btn--ghost:hover { background: var(--accent); color: #fff; }
.hero .btn--ghost { color: #fff; border-color: #fff; }
.hero .btn--ghost:hover { background: #fff; color: var(--ink); }

/* ------------------------------------------------------------ forms */
.form { display: flex; flex-direction: column; gap: 1.1rem; max-width: 34rem; }
.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field label { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-2); }
.field input, .field textarea, .field select {
  font: inherit;
  color: var(--ink);
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--rule);
  border-radius: 2px;
  background: var(--paper);
  width: 100%;
}
.field input:focus, .field textarea:focus, .field select:focus {
  border-color: var(--accent);
  outline: none;
  box-shadow: 0 0 0 3px var(--accent-wash);
}
.field textarea { min-height: 8rem; resize: vertical; }

/* Honeypot — hidden from people, visible to naive bots. */
.hp { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

.form-msg { font-size: 0.925rem; padding: 0.75rem 1rem; border-left: 3px solid var(--ink-3); background: var(--wash); }
.form-msg[data-state="ok"]    { border-color: #3f6f52; background: #eaf1ec; color: #2c5039; }
.form-msg[data-state="error"] { border-color: #94373a; background: #f8eaea; color: #7a2c2f; }
.form-msg[hidden] { display: none; }

/* -------------------------------------------------- questionnaire
   Replaces a Microsoft Forms embed. The data-source list is long by
   design, so it gets its own scroll box and a filter rather than
   pushing the rest of the form off the screen. */
.form--wide { max-width: 52rem; gap: 2.5rem; }

.q {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 0;
  padding: 1.75rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.q:first-of-type { border-top: 0; padding-top: 0; }

.q legend {
  font-family: var(--serif);
  font-size: 1.25rem;
  line-height: 1.3;
  padding: 0;
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
}

.q-num {
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #fff;
  background: var(--accent);
  border-radius: 50%;
  width: 1.5rem;
  height: 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  font-variant-numeric: tabular-nums;
}

.q-help { font-size: 0.925rem; color: var(--ink-2); }
.q-optional { font-weight: 400; text-transform: none; letter-spacing: 0; color: var(--ink-3); }

.q-note {
  font-size: 0.875rem;
  color: var(--ink-2);
  border-left: 3px solid var(--accent);
  background: var(--accent-wash);
  padding: 0.75rem 1rem;
}

.q-opts { display: flex; flex-direction: column; gap: 0.5rem; }
.q-opts--inline { flex-direction: row; flex-wrap: wrap; gap: 0.5rem 1.5rem; }

.q label,
.ds-group label {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.95rem;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
  cursor: pointer;
  line-height: 1.45;
}
.q input[type="checkbox"],
.q input[type="radio"],
.ds-group input[type="checkbox"] {
  margin: 0.25rem 0 0;
  accent-color: var(--accent);
  flex: none;
  width: auto;
}
.q textarea { width: 100%; }

/* the data-source list */
.ds-filter { display: flex; flex-direction: column; gap: 0.4rem; }
.ds-filter label {
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--ink-2);
}
.ds-filter input[type="search"] {
  font: inherit; padding: 0.65rem 0.9rem;
  border: 1px solid var(--rule); border-radius: 2px; background: var(--paper); width: 100%;
}
.ds-filter input[type="search"]:focus {
  border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px var(--accent-wash);
}
.ds-count { font-size: 0.8rem; color: var(--ink-3); font-variant-numeric: tabular-nums; }

.ds-groups {
  max-height: 26rem;
  overflow-y: auto;
  border: 1px solid var(--rule);
  background: var(--paper);
  /* no top padding: the sticky selection bar sits flush against the top edge,
     otherwise list rows scroll through the padding gap above it */
  padding: 0 1.25rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
/* restore the breathing room the removed top padding used to give */
.ds-groups > .ds-group:first-child { padding-top: 1.25rem; }

/* Checked options are moved here and this sticks to the top of the scroll
   box — a frozen row you cannot scroll away from. It needs an opaque
   background so the list passes underneath it, and a z-index so it wins. */
.ds-selected {
  position: sticky;
  top: 0;
  z-index: 2;
  /* full-bleed across the container's side padding, and flush to its top —
     .ds-groups carries no top padding so nothing shows through above this */
  margin: 0 -1.25rem;
  padding: 0.75rem 1.25rem;
  background: var(--accent-wash);
  border-bottom: 1px solid var(--accent);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  box-shadow: 0 6px 10px -8px rgba(0, 0, 0, 0.35);
}
.ds-selected[hidden] { display: none; }

.ds-selected-head {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--accent-dk);
  font-variant-numeric: tabular-nums;
}

/* Capped so a long selection cannot swallow the whole box. */
.ds-selected-items {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  max-height: 9rem;
  overflow-y: auto;
}

.ds-group { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.45rem; }
.ds-group legend {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 0 0 0.35rem;
}
.ds-group[hidden] { display: none; }
.ds-group label[hidden] { display: none; }

.ds-other { margin-top: 0.25rem; }

@media (max-width: 40rem) {
  .ds-groups { max-height: 20rem; padding: 1rem; }
  .q-opts--inline { flex-direction: column; gap: 0.5rem; }
}

/* ------------------------------------------------------------- video
   .video-frame holds the aspect ratio so an embed can be dropped in
   without touching CSS. .video-slot is the placeholder skin, removed
   with the placeholder. */
.video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--ink);
  overflow: hidden;
}
.video-frame > iframe,
.video-frame > video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.video-slot {
  display: grid;
  place-items: center;
  background: var(--wash);
  border: 1px dashed var(--rule);
}
.video-slot-inner { text-align: center; padding: 1.5rem; display: flex; flex-direction: column; gap: 0.5rem; }
.video-slot-label {
  font-family: var(--serif);
  font-size: clamp(1.1rem, 3vw, 1.5rem);
  color: var(--ink-2);
}
.video-slot-note { font-size: 0.85rem; color: var(--ink-3); }
.video-slot-note code { font-size: 0.95em; }

/* ------------------------------------------------------------ embeds */
.embed { width: 100%; border: 0; display: block; }
.embed-frame { border: 1px solid var(--rule); background: var(--wash); }

/* --------------------------------------------------------- contact */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
  gap: 2.5rem;
}
.contact-detail { display: flex; flex-direction: column; gap: 0.4rem; }
.contact-detail a { font-size: 1.15rem; font-weight: 600; text-decoration: none; }

/* ---------------------------------------------------------- footer */
.site-footer { padding-block: 2.5rem; font-size: 0.875rem; color: var(--ink-3); }
.site-footer .shell { display: flex; flex-direction: column; gap: 1rem; }
.site-footer hr { border: 0; border-top: 1px solid var(--rule); margin: 0 0 0.5rem; }
.site-footer a { color: var(--ink-2); text-decoration: none; }
.site-footer a:hover { color: var(--accent); }
.footer-links { display: flex; flex-wrap: wrap; gap: 0.6rem; }

/* ----------------------------------------------------------- states */
.empty-state {
  border: 1px dashed var(--rule);
  padding: 2.5rem;
  text-align: center;
  color: var(--ink-3);
  background: var(--wash);
}

/* ----------------------------------------------------------- ledger
   The cost-comparison block on /dig-out/. A table would be the obvious
   markup, but the site has no table styles and this is not really tabular
   data — it is a short list of costs that has to stay readable on a phone,
   where a four-column table would either scroll sideways or shrink to
   nothing. So: a list that lays out as rows when there is room and stacks
   when there is not.

   .ledger-sum is the last row — the one the whole block exists to deliver.
   It is the only place on the page where the accent colour appears in type.
   -------------------------------------------------------------------- */
.ledger { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }

.ledger > li {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.15rem 1.5rem;
  padding-block: 1rem;
  border-bottom: 1px solid var(--rule);
  align-items: baseline;
}

.ledger-item { font-weight: 600; }

.ledger-val {
  font-family: var(--serif);
  font-size: 1.35rem;
  line-height: 1.2;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.ledger-note {
  grid-column: 1 / -1;
  font-size: 0.85rem;
  color: var(--ink-3);
}

.ledger-sum { border-bottom: 0; }
.ledger-sum .ledger-item,
.ledger-sum .ledger-val { color: var(--accent-dk); }
.ledger-sum .ledger-val { font-size: 1.5rem; white-space: normal; }

/* At phone width the number wants to sit under its label, not squeezed
   beside it — several of these are long enough to wrap badly otherwise. */
@media (max-width: 34rem) {
  .ledger > li { grid-template-columns: 1fr; }
  .ledger-val { text-align: left; }
}

/* The line that keeps an external benchmark from reading as our own result.
   Small, grey, and directly under whatever it qualifies. */
.footnote {
  font-size: 0.85rem;
  color: var(--ink-3);
  max-width: 46rem;
}

/* ------------------------------------------------------- monthly offer band
   The Dig-Out runs one named offer per calendar month and this is where it
   sits. It needs to read as a notice rather than as another content section,
   so it takes the accent wash and a rule top and bottom — the only place on
   the site where a section is bracketed that way. It stays quiet otherwise:
   no badge, no countdown, no colour outside the existing palette. The urgency
   is a real month ending, and dressing it up would make it look invented.
   -------------------------------------------------------------------- */
.section--offer {
  background: var(--accent-wash);
  border-top: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  padding-block: clamp(2.25rem, 5vw, 3.5rem);
}
.section--offer .eyebrow { color: var(--accent-dk); }
.section--offer .section-head { max-width: 52rem; gap: 1rem; }
/* .section + .section paints a rule between neighbours; the band draws its
   own, so suppress the inherited one and avoid a doubled line. */
.section + .section--offer { border-top: 2px solid var(--accent); }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
