/* HAWOSE — components (ported from the design system bundle.css, hw- prefix) */

/* ---------- Utility type ---------- */
.hw-label {
  font-family: var(--font-label); font-size: 13px; line-height: 16px; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase;
}
.hw-spec {
  font-family: var(--font-mono); font-size: 14px; line-height: 22px; font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.hw-display-xl {
  font-family: var(--font-display); font-size: var(--fs-display-xl); line-height: var(--lh-display-xl);
  font-weight: 800; text-transform: uppercase; text-wrap: balance; margin: 0;
}
.hw-display-l {
  font-family: var(--font-display); font-size: var(--fs-display-l); line-height: var(--lh-display-l);
  font-weight: 700; text-transform: uppercase; text-wrap: balance; margin: 0;
}
.hw-heading {
  font-family: var(--font-display); font-size: var(--fs-heading); line-height: var(--lh-heading);
  font-weight: 700; text-transform: uppercase; margin: 0;
}
.hw-title {
  font-family: var(--font-display); font-size: var(--fs-title); line-height: var(--lh-title);
  font-weight: 700; letter-spacing: .01em; text-transform: uppercase; margin: 0;
}
.hw-lead { font-size: var(--fs-lead); line-height: var(--lh-lead); color: var(--ink-muted); margin: 0; max-width: 60ch; }

/* ---------- Layout ---------- */
.hw-wrap { width: 100%; max-width: calc(var(--content-max) + 2 * var(--gutter)); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.hw-section { padding-top: var(--section-y); padding-bottom: var(--section-y); }
.hw-section--sunken { background: var(--surface-sunken); }
.hw-section--dark { background: var(--charcoal); color: var(--on-charcoal); }
.hw-section--tight-top { padding-top: 0; }
.hw-stack > * + * { margin-top: var(--space-4); }

/* ---------- Button ---------- */
.hw-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  min-height: 48px; padding: var(--space-3) var(--space-6);
  font-family: var(--font-label); font-size: 16px; line-height: 20px; font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase;
  border: var(--rule) solid transparent; border-radius: var(--radius-sm);
  text-decoration: none; cursor: pointer; white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
  transition: background-color var(--dur-fast) ease-out, color var(--dur-fast) ease-out,
              border-color var(--dur-fast) ease-out, transform var(--dur-fast) ease-out;
}
.hw-btn i { font-size: .95em; transition: transform var(--dur) ease-out; }
.hw-btn:hover .fa-arrow-right { transform: translateX(4px); }
.hw-btn:active { transform: translateY(1px); }
.hw-btn--primary { background: var(--madder); color: var(--on-madder); }
.hw-btn--primary:hover { background: var(--madder-hover); color: var(--on-madder); }
.hw-btn--dark { background: var(--charcoal); color: var(--on-charcoal); }
.hw-btn--dark:hover { background: var(--ink); color: var(--on-charcoal); }
.hw-btn--light { background: var(--surface); color: var(--madder); }
.hw-btn--light:hover { background: var(--surface-raised); color: var(--madder-hover); }
.hw-btn--outline { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.hw-btn--outline:hover { border-color: var(--ink); color: var(--ink); }
.hw-btn--on-dark { background: transparent; color: var(--on-charcoal); border-color: var(--on-charcoal-muted); }
.hw-btn--on-dark:hover { border-color: var(--on-charcoal); color: var(--on-charcoal); background: rgba(252, 247, 248, .06); }
.hw-btn--phone { font-family: var(--font-mono); letter-spacing: 0; text-transform: none; font-weight: 500; }
.hw-btn--sm { min-height: 40px; padding: var(--space-2) var(--space-4); font-size: 14px; }
.hw-btn--block { width: 100%; }
.hw-actions { display: flex; flex-wrap: wrap; gap: var(--space-3); }
@media (max-width: 575.98px) {
  .hw-actions--stack { flex-direction: column; align-items: stretch; }
  .hw-actions--stack .hw-btn { width: 100%; }
}

/* Text link with arrow */
.hw-link {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-family: var(--font-label); font-size: 15px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--madder); text-decoration: none; min-height: 44px;
}
.hw-link i { transition: transform var(--dur) ease-out; }
.hw-link:hover { color: var(--madder-hover); }
.hw-link:hover i { transform: translateX(4px); }

/* ---------- SectionHeader ---------- */
.hw-section-head { display: grid; gap: var(--space-3); max-width: 760px; margin-bottom: var(--space-8); }
.hw-section-head::before {
  content: ""; width: 56px; height: var(--rule-heavy); background: var(--madder);
  margin-bottom: var(--space-2); transform-origin: left center;
}
.hw-section-head__eyebrow { color: var(--madder); display: flex; align-items: center; gap: var(--space-3); }
.hw-section-head__eyebrow .hw-spec { color: var(--ink-muted); font-size: 13px; }
.hw-section-head__title { margin: 0; font-family: var(--font-display); font-size: var(--fs-display-l); line-height: var(--lh-display-l); font-weight: 700; text-transform: uppercase; text-wrap: balance; color: var(--ink); }
.hw-section-head__lead { margin: 0; font-size: var(--fs-lead); line-height: var(--lh-lead); color: var(--ink-muted); max-width: 60ch; }
.hw-section--dark .hw-section-head__title { color: var(--on-charcoal); }
.hw-section--dark .hw-section-head__lead { color: var(--on-charcoal-muted); }
.hw-section--dark .hw-section-head__eyebrow { color: var(--on-charcoal); }
@media (min-width: 1024px) { .hw-section-head { margin-bottom: var(--space-12); } }

/* ---------- Icon tile ---------- */
.hw-tile {
  flex: none; width: 56px; height: 56px; display: grid; place-items: center;
  background: var(--madder); color: var(--on-madder); font-size: 24px; border-radius: var(--radius-0);
}
.hw-tile--dark { background: var(--charcoal); color: var(--on-charcoal); }
.hw-tile--sm { width: 44px; height: 44px; font-size: 19px; }

/* ---------- ServiceCard ---------- */
.hw-service {
  position: relative; display: flex; flex-direction: column; height: 100%;
  background: var(--surface-raised); border: var(--rule-hairline) solid var(--line); border-radius: var(--radius-md);
  overflow: hidden; color: inherit; text-decoration: none;
  transition: box-shadow var(--dur) ease-out, transform var(--dur) ease-out, border-color var(--dur) ease-out;
}
.hw-service::before {
  content: ""; position: absolute; inset: 0 0 auto; height: var(--rule-accent); background: var(--madder);
  transform: scaleX(0); transform-origin: left; transition: transform var(--dur) ease-out; z-index: 2;
}
.hw-service:hover { box-shadow: var(--shadow-lift); transform: translateY(-4px); color: inherit; }
.hw-service:hover::before { transform: scaleX(1); }
.hw-service__media { position: relative; aspect-ratio: 4 / 3; background: var(--surface-sunken); overflow: hidden; }
.hw-service__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hw-service__media--contain img { object-fit: contain; padding: var(--space-4); }
.hw-service__index { position: absolute; top: var(--space-3); right: var(--space-3); padding: 2px var(--space-2); background: var(--charcoal); color: var(--on-charcoal); }
.hw-service__tile { position: relative; z-index: 1; margin: -28px 0 0 var(--space-6); }
.hw-service__body { display: flex; flex-direction: column; gap: var(--space-3); flex: 1; padding: var(--space-4) var(--space-6) var(--space-6); }
.hw-service__title { margin: 0; font-family: var(--font-display); font-size: var(--fs-title); line-height: var(--lh-title); font-weight: 700; letter-spacing: .01em; text-transform: uppercase; }
.hw-service__text { margin: 0; color: var(--ink-muted); }
.hw-service__more { margin-top: auto; padding-top: var(--space-3); display: inline-flex; gap: var(--space-2); align-items: center; color: var(--madder); }
.hw-service__more i { transition: transform var(--dur) ease-out; }
.hw-service:hover .hw-service__more i { transform: translateX(4px); }

/* ---------- SpecCard ---------- */
.hw-specard {
  position: relative; background: var(--surface-raised); border: var(--rule-hairline) solid var(--line); border-radius: var(--radius-md);
  overflow: hidden; display: flex; flex-direction: column; height: 100%;
  transition: box-shadow var(--dur) ease-out, transform var(--dur) ease-out;
}
.hw-specard::before {
  content: ""; position: absolute; inset: 0 0 auto; height: var(--rule-accent); background: var(--madder);
  transform: scaleX(0); transform-origin: left; transition: transform var(--dur) ease-out; z-index: 2;
}
.hw-specard:hover { box-shadow: var(--shadow-lift); transform: translateY(-4px); }
.hw-specard:hover::before { transform: scaleX(1); }
.hw-specard__media { position: relative; aspect-ratio: 1 / 1; background: var(--surface-sunken); }
.hw-specard__media--wide { aspect-ratio: 4 / 3; }
.hw-specard__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hw-specard__badge { position: absolute; top: var(--space-3); left: var(--space-3); padding: var(--space-1) var(--space-2); background: var(--charcoal); color: var(--on-charcoal); border-radius: var(--radius-sm); }
.hw-specard__badge--madder { background: var(--madder); color: var(--on-madder); }
.hw-specard__body { padding: var(--space-4) var(--space-4) var(--space-6); display: grid; gap: var(--space-2); align-content: start; }
.hw-specard__title { margin: 0; font-family: var(--font-display); font-size: 20px; line-height: 24px; font-weight: 700; text-transform: uppercase; }
.hw-specard__text { margin: 0; font-size: 15px; line-height: 22px; color: var(--ink-muted); }
.hw-specard__rows { margin: var(--space-2) 0 0; display: grid; grid-template-columns: auto 1fr; border-top: var(--rule-hairline) solid var(--line); }
.hw-specard__rows dt, .hw-specard__rows dd { margin: 0; padding: var(--space-2) 0; border-bottom: var(--rule-hairline) solid var(--line); }
.hw-specard__rows dt { color: var(--ink-muted); padding-right: var(--space-4); font-weight: 500; }
.hw-specard__rows dd { text-align: right; }
@media (min-width: 768px) {
  .hw-specard__body { padding: var(--space-4) var(--space-6) var(--space-6); }
  .hw-specard__title { font-size: 22px; line-height: 26px; }
}

/* ---------- FactStrip ---------- */
.hw-facts { background: var(--charcoal); color: var(--on-charcoal); position: relative; }
.hw-facts::before {
  content: ""; position: absolute; inset: 0 0 auto; height: var(--rule-accent);
  background: repeating-linear-gradient(-45deg, var(--madder) 0 10px, var(--charcoal) 10px 20px);
}
.hw-facts__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.hw-facts__item { padding: var(--space-8) var(--space-4); border-left: var(--rule-hairline) solid var(--on-charcoal-line); border-top: var(--rule-hairline) solid var(--on-charcoal-line); display: grid; gap: var(--space-2); grid-template-rows: 1fr auto; align-content: stretch; }
.hw-facts__item:nth-child(odd) { border-left: 0; }
.hw-facts__item:nth-child(-n+2) { border-top: 0; }
.hw-facts__figure { align-self: end; font-family: var(--font-display); font-size: var(--fs-figure); line-height: var(--lh-figure); font-weight: 800; font-variant-numeric: tabular-nums; }
.hw-facts__figure small { font-size: 1em; font-weight: 700; margin-left: var(--space-1); }
.hw-facts__caption { color: var(--on-charcoal-muted); }
@media (min-width: 768px) {
  .hw-facts__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .hw-facts__item { padding: var(--space-12) var(--space-6); border-top: 0; }
  .hw-facts__item:nth-child(odd) { border-left: var(--rule-hairline) solid var(--on-charcoal-line); }
  .hw-facts__item:first-child { border-left: 0; }
}
/* Five facts: 2 columns (last one full width) until desktop, then one row */
.hw-facts__grid--5 > .hw-facts__item:last-child:nth-child(odd) { grid-column: 1 / -1; }
@media (min-width: 768px) and (max-width: 1023.98px) {
  .hw-facts__grid--5 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hw-facts__grid--5 .hw-facts__item { border-top: var(--rule-hairline) solid var(--on-charcoal-line); }
  .hw-facts__grid--5 .hw-facts__item:nth-child(-n+2) { border-top: 0; }
  .hw-facts__grid--5 .hw-facts__item:nth-child(odd) { border-left: 0; }
}
@media (min-width: 1024px) {
  .hw-facts__grid--5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .hw-facts__grid--5 > .hw-facts__item:last-child:nth-child(odd) { grid-column: auto; }
}

/* ---------- CtaBand ---------- */
.hw-cta { position: relative; overflow: hidden; background: var(--madder); color: var(--on-madder); }
.hw-cta::after {
  content: ""; position: absolute; top: 0; bottom: 0; right: 0; width: 34%;
  background: repeating-linear-gradient(-45deg, var(--madder-hover) 0 16px, transparent 16px 32px);
  pointer-events: none;
}
.hw-cta__inner { position: relative; z-index: 1; display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-6) var(--space-12); padding-top: var(--space-12); padding-bottom: var(--space-12); }
.hw-cta__copy { flex: 1 1 360px; min-width: 0; display: grid; gap: var(--space-2); }
.hw-cta__title { margin: 0; font-family: var(--font-display); font-size: 32px; line-height: 34px; font-weight: 800; text-transform: uppercase; text-wrap: balance; }
.hw-cta__text { margin: 0; font-size: 18px; line-height: 28px; max-width: 52ch; }
.hw-cta__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); }
.hw-cta .hw-btn--on-dark { color: var(--on-madder); border-color: var(--on-madder); }
.hw-cta .hw-btn--on-dark:hover { background: var(--madder-hover); }
@media (max-width: 575.98px) {
  .hw-cta::after { width: 22%; opacity: .7; }
  .hw-cta__actions { width: 100%; flex-direction: column; }
  .hw-cta__actions .hw-btn { width: 100%; }
}
@media (min-width: 1024px) {
  .hw-cta__inner { padding-top: var(--space-16); padding-bottom: var(--space-16); }
  .hw-cta__title { font-size: 40px; line-height: 42px; }
}

/* ---------- Page header (subpages) ---------- */
.hw-pagehead {
  /* The photo is set inline on each page: style="background-image: var(--pagehead-overlay), url('…')".
     A url() inside a custom property would resolve against this stylesheet, not the page. */
  --pagehead-overlay: linear-gradient(90deg, rgba(31, 31, 31, .96) 0%, rgba(31, 31, 31, .86) 55%, rgba(31, 31, 31, .6) 100%);
  position: relative; color: var(--on-charcoal); background-color: var(--charcoal);
  background-image: var(--pagehead-overlay);
  background-size: cover; background-position: center;
  padding-top: calc(var(--nav-h) + var(--space-12));
  padding-bottom: var(--space-12);
  overflow: hidden;
}
.hw-pagehead::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: var(--rule-heavy);
  background: repeating-linear-gradient(-45deg, var(--madder) 0 12px, var(--charcoal-deep) 12px 24px);
}
.hw-pagehead__inner { position: relative; display: grid; gap: var(--space-4); max-width: 760px; }
.hw-pagehead__crumb { color: var(--on-charcoal-muted); display: flex; gap: var(--space-2); align-items: center; }
.hw-pagehead__crumb a { color: var(--on-charcoal-muted); text-decoration: none; }
.hw-pagehead__crumb a:hover { color: var(--on-charcoal); }
.hw-pagehead__crumb [aria-current] { color: var(--on-charcoal); }
.hw-pagehead__title { margin: 0; }
.hw-pagehead__title::after { content: ""; display: block; width: 56px; height: var(--rule-heavy); background: var(--madder); margin-top: var(--space-4); transform-origin: left; }
.hw-pagehead__lead { margin: 0; font-size: var(--fs-lead); line-height: var(--lh-lead); color: var(--on-charcoal-muted); max-width: 56ch; }
@media (min-width: 1024px) {
  .hw-pagehead { padding-top: calc(var(--nav-h) + var(--space-16)); padding-bottom: var(--space-16); }
}

/* ---------- Media frame (industrial corner marks) ---------- */
.hw-frame { position: relative; margin: 0; }
.hw-frame img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: var(--radius-0); }
.hw-frame::before, .hw-frame::after {
  content: ""; position: absolute; width: 32px; height: 32px; pointer-events: none; z-index: 1;
}
.hw-frame::before { top: -8px; left: -8px; border-top: var(--rule-accent) solid var(--madder); border-left: var(--rule-accent) solid var(--madder); }
.hw-frame::after { bottom: -8px; right: -8px; border-bottom: var(--rule-accent) solid var(--charcoal); border-right: var(--rule-accent) solid var(--charcoal); }
.hw-frame__caption { position: absolute; left: 0; bottom: 0; padding: var(--space-2) var(--space-3); background: var(--charcoal); color: var(--on-charcoal); }

/* ---------- Focus ---------- */
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; box-shadow: 0 0 0 2px var(--surface); }
.hw-cta :focus-visible, .hw-section--dark :focus-visible, .hw-nav :focus-visible, .site-footer :focus-visible { outline-color: var(--on-charcoal); box-shadow: none; }
