/* =====================================================================
   Southgate Contracting — site theme
   Sits on top of base.css (the shared Southgate / Corewell design system,
   copied unchanged). Everything specific to this site lives here.
   Brand: amber #B4530A + #F5A623 and brown-black #2B1D10, from the logo.
   ===================================================================== */

:root {
  --amber: #F5A623;          /* logo light amber: accents, and fills behind dark text */
  --amber-deep: #B4530A;     /* logo dark amber: buttons and icons (white text passes AA) */
  --amber-ink: #9A4407;      /* amber dark enough for links and small text on light grounds */
  --amber-soft: #FBEBD3;
  --amber-on-dark: #F7B54A;

  /* base.css reads the names below. Here they carry the Contracting palette. */
  --navy: #2B1D10;
  --navy-700: #40301F;
  --navy-900: #1D130A;
  --sky: var(--amber);
  --sky-ink: var(--amber-ink);
  --sky-soft: var(--amber-soft);
  --sky-on-dark: var(--amber-on-dark);

  --bg: #FFFFFF;
  --surface: #FAF6EF;
  --surface-2: #F2EADC;
  --card: #FFFFFF;
  --ink: #2B1D10;
  --text: #3B3128;
  --muted: #6B5F53;
  --line: rgba(43, 29, 16, .13);
  --line-strong: rgba(43, 29, 16, .28);

  --on-dark: #F7F1E8;
  --on-dark-muted: #CDBFAC;
  --shadow: 0 1px 2px rgba(43, 29, 16, .06), 0 18px 40px -24px rgba(43, 29, 16, .4);
}

::selection { background: var(--amber); color: var(--navy-900); }

/* Amber on white is too faint for a focus ring, icons or numerals: use the deep amber on light grounds */
:focus-visible { outline-color: var(--amber-deep); }
.section--dark :focus-visible, .cta-band :focus-visible, .site-footer :focus-visible { outline-color: var(--amber); }
.checklist svg, .trust svg { color: var(--amber-deep); }
.section--dark .checklist svg { color: var(--amber); }
.section--dark .checklist b, .section--dark .h4 { color: #fff; }
.section--dark .section-head > p { color: var(--on-dark-muted); }
.steps > li::before { color: var(--amber-deep); }
.accordion summary::after { border-color: var(--amber-deep); }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--amber-deep); box-shadow: 0 0 0 3px rgba(180, 83, 10, .22); }
.field label .optional { font-weight: 400; color: var(--muted); }
.media { border-radius: var(--radius-lg); }
.panel > p + p { margin-top: 10px; }
section[id], div[id], h2[id] { scroll-margin-top: 104px; }
/* Photo-and-text sections alternate sides on wide screens; on phones the photo always comes first */
@media (min-width: 1000px) { .split--flip > :first-child { order: 2; } }
.split > .stack > p:not(.lead):not(.eyebrow):not(.small) { max-width: 38em; }

/* ---------------------------------------------------------------- buttons */
.btn--primary { background: var(--amber-deep); color: #fff; }
.btn--primary:hover { background: #963F06; color: #fff; }
.btn--dark { background: var(--navy); color: #fff; }
.btn--dark:hover { background: var(--navy-700); color: #fff; }
.btn--sky:hover { background: #FFBC4F; }
.btn--ghost:hover { border-color: var(--ink); color: var(--ink); }

/* ---------------------------------------------------------------- header */
.nav__actions .btn[aria-current="page"] { box-shadow: 0 0 0 3px var(--amber-soft), 0 0 0 4px var(--amber-deep); }
/* Five links and a button: tighten up just above the point where the menu collapses */
@media (min-width: 1061px) and (max-width: 1220px) {
  .brand-link img { height: 38px; }
  .nav { gap: 14px; }
  .nav__list { gap: 0; }
  .nav__list a { padding: 0 10px; }
}

/* ---------------------------------------------------------------- home hero */
.hero { position: relative; overflow: hidden; }
.hero__mark { position: absolute; right: -5%; top: -6%; width: min(700px, 70vw); opacity: .07; pointer-events: none; }
.hero__top { position: relative; display: grid; gap: 28px; }
.hero__top h1 { max-width: 16ch; }
.hero__aside { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 24px 56px; }
.hero__aside .lead { max-width: 34em; }

/* The window: three photos set in a white frame, with a mullion, a transom and a sill */
.panes { position: relative; margin-top: clamp(44px, 5.5vw, 76px); display: grid; gap: 10px; grid-template-columns: 1.85fr 1fr; grid-template-rows: 1fr 1fr; height: clamp(380px, 40vw, 540px); padding: 10px; border-radius: 20px; background: #fff; border: 1px solid var(--line-strong); box-shadow: var(--shadow); }
.panes::after { content: ""; position: absolute; left: -12px; right: -12px; bottom: -14px; height: 13px; border-radius: 3px 3px 7px 7px; background: #fff; border: 1px solid var(--line-strong); box-shadow: 0 12px 18px -12px rgba(43, 29, 16, .45); }
.pane { position: relative; display: block; overflow: hidden; border-radius: 11px; background: var(--surface-2); }
.pane--main { grid-row: 1 / -1; }
.pane img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s; }
.pane:hover img { transform: scale(1.03); }
.pane__label { position: absolute; left: 14px; bottom: 14px; display: inline-flex; align-items: center; gap: 10px; max-width: calc(100% - 28px); padding: 10px 16px; border-radius: 999px; background: rgba(255, 255, 255, .95); color: var(--ink); font-size: 14px; font-weight: 500; line-height: 1.3; }
.pane__label b { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--amber-ink); font-weight: 700; }
@media (max-width: 760px) {
  .panes { grid-template-columns: 1fr 1fr; grid-template-rows: auto auto; height: auto; gap: 8px; padding: 8px; border-radius: 16px; }
  .panes::after { left: -8px; right: -8px; }
  .pane--main { grid-row: auto; grid-column: 1 / -1; aspect-ratio: 4 / 3; }
  .pane:not(.pane--main) { aspect-ratio: 1 / 1; }
  .pane:not(.pane--main) .pane__label { left: 8px; bottom: 8px; padding: 7px 12px; font-size: 0; gap: 0; }
  .pane:not(.pane--main) .pane__label b { font-size: 10px; }
}

/* Proof strip under the hero */
.proof { list-style: none; margin-top: clamp(40px, 5vw, 60px); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); border-top: 1px solid var(--line-strong); }
.proof li { display: grid; gap: 4px; padding: 22px 24px 4px 0; }
.proof li + li { padding-left: 24px; border-left: 1px solid var(--line); }
.proof b { font-size: clamp(24px, 2.4vw, 32px); font-weight: 500; line-height: 1.1; letter-spacing: -0.03em; color: var(--ink); }
.proof span { font-size: 14px; line-height: 1.5; color: var(--muted); max-width: 24ch; }
@media (max-width: 900px) { .proof { grid-template-columns: 1fr 1fr; column-gap: 20px; } .proof li, .proof li + li { border-left: 0; padding: 18px 0; border-bottom: 1px solid var(--line); } .proof b { font-size: 22px; } }

/* ---------------------------------------------------------------- numbered principles */
.principles { display: grid; gap: 40px 32px; grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr)); }
.principle { display: flex; flex-direction: column; gap: 12px; padding-top: 26px; border-top: 2px solid var(--ink); }
.principle__n { font-size: clamp(40px, 4vw, 56px); font-weight: 500; line-height: 1; letter-spacing: -0.04em; color: var(--amber-deep); }
.principle h3 { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; }
.principle .link-arrow { margin-top: auto; }
.section--dark .principle { border-top-color: rgba(255, 255, 255, .22); }
.section--dark .principle__n { color: var(--amber); }
.section--dark .principle h3 { color: #fff; }

/* ---------------------------------------------------------------- sector rows (home) */
.rows { list-style: none; border-top: 1px solid var(--line-strong); }
.rows a { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr) 28px; gap: 8px 48px; align-items: center; padding: 28px 10px 28px 0; border-bottom: 1px solid var(--line-strong); color: var(--text); text-decoration: none; transition: background .25s, padding .25s; }
.rows a:hover { background: var(--surface); padding-left: 18px; color: var(--text); }
.rows h3 { font-size: clamp(24px, 2.7vw, 36px); letter-spacing: -0.025em; transition: color .2s; }
.rows a:hover h3 { color: var(--amber-ink); }
.rows p { color: var(--muted); max-width: 36em; }
.rows svg { width: 24px; height: 24px; color: var(--ink); justify-self: end; transition: transform .25s; }
.rows a:hover svg { transform: translateX(4px); }
@media (max-width: 760px) {
  .rows a { grid-template-columns: minmax(0, 1fr) 24px; padding: 22px 4px 22px 0; }
  .rows a:hover { padding-left: 0; background: transparent; }
  .rows p { grid-column: 1 / -1; grid-row: 2; }
}

/* ---------------------------------------------------------------- the programme: six stages drawn as a bar chart */
.programme { --bar: var(--amber-deep); --rule: var(--line); --rule-strong: var(--line-strong); display: grid; }
.section--dark .programme { --bar: var(--amber); --rule: rgba(255, 255, 255, .1); --rule-strong: rgba(255, 255, 255, .24); }
.programme__phases, .programme__rows > li { display: grid; grid-template-columns: minmax(240px, 340px) minmax(0, 1fr); gap: 12px 32px; align-items: center; }
.programme__scale, .programme__track { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); }
.programme__scale span { padding: 0 0 12px 10px; border-left: 1px solid var(--rule-strong); font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.section--dark .programme__scale span { color: var(--on-dark-muted); }
.programme__rows { list-style: none; display: grid; }
.programme__rows > li { padding: 16px 0; border-top: 1px solid var(--rule-strong); }
.programme__rows > li:last-child { border-bottom: 1px solid var(--rule-strong); }
.programme__label { display: grid; gap: 2px; }
.programme__label b { font-size: 17px; font-weight: 500; color: var(--ink); letter-spacing: -0.01em; }
.section--dark .programme__label b { color: #fff; }
.programme__label b i { font-style: normal; font-weight: 700; font-size: 13px; color: var(--bar); margin-right: 10px; letter-spacing: 0; }
.programme__label span { font-size: 14px; line-height: 1.5; color: var(--muted); }
.section--dark .programme__label span { color: var(--on-dark-muted); }
.programme__track { height: 30px; background: repeating-linear-gradient(to right, var(--rule) 0 1px, transparent 1px 12.5%); }
.programme__bar { grid-column: var(--start) / span var(--span); margin-block: 5px; border-radius: 999px; background: var(--bar); }
.programme__bar--open { border-radius: 999px 0 0 999px; background: linear-gradient(to right, var(--bar) 55%, transparent); }
@media (max-width: 860px) {
  .programme__phases, .programme__rows > li { grid-template-columns: minmax(0, 1fr); }
  .programme__phases > span:first-child { display: none; }
  .programme__track { height: 18px; }
  .programme__bar { margin-block: 4px; }
}
@media (prefers-reduced-motion: no-preference) {
  .js .programme.reveal .programme__bar { transform: scaleX(0); transform-origin: left center; transition: transform .9s cubic-bezier(.2, .7, .2, 1); }
  .js .programme.reveal.is-visible .programme__bar { transform: none; }
  .js .programme.reveal li:nth-child(2) .programme__bar { transition-delay: .12s; }
  .js .programme.reveal li:nth-child(3) .programme__bar { transition-delay: .24s; }
  .js .programme.reveal li:nth-child(4) .programme__bar { transition-delay: .36s; }
  .js .programme.reveal li:nth-child(5) .programme__bar { transition-delay: .48s; }
  .js .programme.reveal li:nth-child(6) .programme__bar { transition-delay: .6s; }
}

/* ---------------------------------------------------------------- tiles */
.tiles { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); }
.tile { display: flex; flex-direction: column; gap: 12px; padding: 28px 26px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--card); color: var(--text); text-decoration: none; transition: border-color .2s, box-shadow .2s, transform .2s; }
a.tile:hover { border-color: var(--line-strong); box-shadow: var(--shadow); transform: translateY(-2px); color: var(--text); }
.tile h3 { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; }
.tile p { font-size: 15px; color: var(--muted); }
.tile .link-arrow { margin-top: auto; }

/* ---------------------------------------------------------------- the S mark as a quiet signature */
.page-hero { position: relative; overflow: hidden; }
.page-hero > .container { position: relative; z-index: 1; }
.page-hero::after { content: ""; position: absolute; right: -4%; top: 50%; transform: translateY(-46%); width: min(620px, 62vw); aspect-ratio: 443 / 308; background: url("../brand/contracting-icon.svg") no-repeat center / contain; opacity: .07; pointer-events: none; }
.dark-mark { position: relative; overflow: hidden; }
.dark-mark::after { content: ""; position: absolute; top: 0; bottom: 0; right: 0; max-width: 85%; aspect-ratio: 443 / 308; background: url("../brand/contracting-icon-reversed.svg") no-repeat right center / contain; opacity: .06; pointer-events: none; }
.section.dark-mark > *, .cta-band > * { position: relative; z-index: 1; }
/* On a tall dark section the mark sits in the bottom corner at a fixed size, so it never runs behind the text */
.section.dark-mark::after { top: auto; bottom: -70px; right: -60px; width: min(620px, 70%); max-width: none; opacity: .05; }

/* ---------------------------------------------------------------- quick routes in page headers */
.routes { list-style: none; display: grid; gap: 12px; margin-top: 8px; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); }
.routes a { position: relative; display: grid; gap: 2px; height: 100%; padding: 16px 44px 16px 18px; border: 1px solid var(--line-strong); border-radius: var(--radius-lg); background: var(--card); color: var(--ink); text-decoration: none; transition: border-color .2s, box-shadow .2s; }
.routes a:hover { border-color: var(--ink); box-shadow: var(--shadow); color: var(--ink); }
.routes b { font-size: 15px; font-weight: 700; }
.routes span { font-size: 14px; color: var(--muted); }
.routes svg { position: absolute; right: 16px; top: 50%; width: 18px; height: 18px; margin-top: -9px; transition: transform .2s; }
.routes a:hover svg { transform: translateX(3px); }
.page-hero__inner:has(.routes) { max-width: 1040px; }
.page-hero__inner:has(.routes) > .lead, .page-hero__inner:has(.routes) > h1 { max-width: 820px; }

/* ---------------------------------------------------------------- residents */
.journey { list-style: none; display: grid; gap: 32px; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); }
.journey__step { position: relative; display: grid; gap: 12px; align-content: start; padding-top: 26px; border-top: 2px solid var(--ink); }
.journey__step::after { content: ""; position: absolute; top: -7px; left: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 4px var(--bg); }
.section--alt .journey__step::after { box-shadow: 0 0 0 4px var(--surface); }
.journey__when { font-size: 12px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--amber-ink); }
.journey__step h3 { font-size: 21px; font-weight: 700; letter-spacing: -0.01em; }
.callout { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 32px; padding: 20px 24px; border-radius: var(--radius-lg); background: var(--amber-soft); border: 1px solid rgba(180, 83, 10, .22); color: var(--ink); }
.callout p { max-width: 46em; }
.callout b { font-weight: 700; }
.tips { list-style: none; display: grid; gap: 0; border-top: 1px solid var(--line-strong); }
.tips li { display: grid; gap: 4px; padding: 18px 0; border-bottom: 1px solid var(--line-strong); }
.tips b { color: var(--ink); font-weight: 700; }
.tips span { color: var(--muted); font-size: 15px; }

/* ---------------------------------------------------------------- tables */
.data-table { width: 100%; min-width: 660px; border-collapse: collapse; font-size: 15px; line-height: 1.55; }
.data-table th, .data-table td { text-align: left; vertical-align: top; padding: 16px 24px 16px 0; border-bottom: 1px solid var(--line); }
.data-table thead th { font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); border-bottom: 1px solid var(--line-strong); }
.data-table tbody th { font-weight: 700; color: var(--ink); width: 24%; }
.data-table td:last-child { white-space: nowrap; font-weight: 500; color: var(--ink); padding-right: 0; }
.spec th { color: var(--muted); }
.spec td { color: var(--ink); }
.prose:has(.data-table) { max-width: 60em; }

/* ---------------------------------------------------------------- contact */
.contact-grid { display: grid; gap: 1px; background: rgba(255, 255, 255, .18); border: 1px solid rgba(255, 255, 255, .18); border-radius: var(--radius-lg); overflow: hidden; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); }
.contact-grid > div { background: var(--navy); padding: 28px; display: grid; gap: 8px; align-content: start; }
.contact-grid h3 { font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--on-dark-muted) !important; }
.map-card { position: relative; border-radius: var(--radius-lg); overflow: hidden; min-height: 360px; display: grid; align-items: end; }
.map-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.map-card .panel { position: relative; margin: 20px; max-width: 360px; }
#enquiry { scroll-margin-top: 110px; }
.contact-grid__wide { grid-column: 1 / -1; }
.phone-big { align-self: flex-start; font-size: clamp(38px, 5.4vw, 64px); font-weight: 500; line-height: 1.05; letter-spacing: -0.035em; color: var(--ink); text-decoration: none; white-space: nowrap; }
.phone-big:hover { color: var(--amber-ink); }
.callout .btn { white-space: nowrap; }

/* ---------------------------------------------------------------- footer */
.site-footer { position: relative; overflow: hidden; }
.site-footer > .container { position: relative; z-index: 1; }
.site-footer::after { content: ""; position: absolute; bottom: -70px; right: -60px; width: min(620px, 70%); aspect-ratio: 443 / 308; background: url("../brand/contracting-icon-reversed.svg") no-repeat right center / contain; opacity: .05; pointer-events: none; }
/* A dark section sitting directly on the footer keeps its mark; the footer drops its own so two never stack */
main:has(> .dark-mark:last-child) + .site-footer::after { display: none; }
.footer__promise { padding-block: clamp(56px, 7vw, 88px) clamp(36px, 4vw, 48px); font-size: clamp(30px, 4.2vw, 56px); font-weight: 500; line-height: 1.08; letter-spacing: -0.03em; color: #fff; max-width: 20ch; text-wrap: balance; }
.footer__promise span { color: var(--amber); }
.footer__top { padding-top: 48px; border-top: 1px solid rgba(255, 255, 255, .1); }
.footer__group { font-size: 14px; }
