/* Contact page.
 *
 * External rather than an inline <style> on purpose: script-src and style-src on this site are
 * 'self' plus SHA-256 hashes with no 'unsafe-inline', so a new inline block would be dropped in
 * full until its hash was added to SecurityConfig. A stylesheet needs no hash and cannot drift
 * out of sync with one.
 *
 * The shared contact/location hub (phase6b-public.js) is injected just above the footer and
 * already carries the embedded map, the office address, the complaints and careers mailboxes and
 * the team cards. Everything here is deliberately the part the hub does not provide: the company
 * identity, the introduction, a machine-readable NAP present in the served HTML rather than only
 * after JavaScript runs, and the three calls to action.
 *
 * Colours come from the site tokens with the same fallbacks the hub uses, so this page tracks the
 * rest of the site if those tokens are ever retuned.
 */

.contact-main {
  display: block;
  background: var(--bg-primary, #0b0e13);
}

.contact-main .container {
  /* The site container, as /services.html uses it: 1280 wide, centred. An earlier 1180 put this
     page content 50px inside the header row, so the two did not share an edge. */
  width: min(var(--container-max, 1280px), calc(100% - 48px));
  margin-inline: auto;
}

/* ---------------------------------------------------------------- intro */

.contact-hero {
  padding: clamp(48px, 9vw, 96px) 0 clamp(28px, 5vw, 44px);
}

.contact-eyebrow {
  margin: 0 0 12px;
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent, #ff6547);
}

.contact-hero h1 {
  margin: 0 0 18px;
  font-size: clamp(2rem, 5vw, 3.1rem);
  line-height: 1.12;
}

.contact-intro {
  max-width: 62ch;
  margin: 0;
  font-size: clamp(1rem, 1.6vw, 1.12rem);
  line-height: 1.7;
  color: var(--text-secondary, #aab2bf);
}

/* ------------------------------------------------------------------ CTAs */

.contact-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

/* Every action is at least 44px tall because these are the page's primary targets and the two
   secondary ones are the ones a visitor reaches for on a phone. */
.contact-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid var(--accent, #ff6547);
  border-radius: 6px;
  font-weight: 650;
  text-decoration: none;
  line-height: 1.2;
  transition: background-color .18s ease, color .18s ease, border-color .18s ease;
}

.contact-cta-primary {
  background: var(--accent, #ff6547);
  color: #10060a;
}

.contact-cta-primary:hover,
.contact-cta-primary:focus-visible {
  background: transparent;
  color: var(--accent, #ff6547);
  outline: none;
}

.contact-cta-secondary {
  background: transparent;
  color: inherit;
  border-color: var(--border-subtle, rgba(255, 255, 255, .22));
}

.contact-cta-secondary:hover,
.contact-cta-secondary:focus-visible {
  border-color: var(--accent, #ff6547);
  color: var(--accent, #ff6547);
  outline: none;
}

/* --------------------------------------------------------------- details */

.contact-nap {
  padding: 0 0 clamp(40px, 7vw, 76px);
}

.contact-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.contact-card {
  min-width: 0;
  padding: 24px;
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, .12));
  border-radius: 8px;
  background: var(--bg-card, #11151b);
}

.contact-card h2 {
  margin: 0 0 14px;
  font-size: 1rem;
  letter-spacing: .02em;
}

.contact-card p {
  margin: 0;
  line-height: 1.75;
  color: var(--text-secondary, #aab2bf);
  /* Long addresses and mailboxes must wrap rather than widen the grid track, which is what would
     otherwise push the page into a horizontal scroll on a narrow phone. */
  overflow-wrap: anywhere;
}

.contact-card .contact-org {
  display: block;
  margin-bottom: 6px;
  font-weight: 650;
  color: inherit;
}

/* Inline links inside the cards keep a 44px target without becoming buttons. */
.contact-card a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, .22));
}

.contact-card a:hover,
.contact-card a:focus-visible {
  color: var(--accent, #ff6547);
  border-bottom-color: var(--accent, #ff6547);
  outline: none;
}

.contact-card .contact-person {
  display: block;
  margin-top: 10px;
}

.contact-card .contact-person-role {
  display: block;
  font-size: .86rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--accent, #ff6547);
}

@media (max-width: 900px) {
  .contact-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  .contact-main .container { width: min(calc(100% - 24px), 1180px); }
  .contact-card-grid { grid-template-columns: 1fr; }
  .contact-cta-row { flex-direction: column; align-items: stretch; }
  .contact-cta { justify-content: center; }
}
