/* ============================================================
   Carl Wilhjelm - Freelance Technology Consultant
   Direction: Atlanta elevation. Night graphite / daylight concrete.
   ============================================================ */

/* --- 1. Tokens ------------------------------------------------ */
:root {
  --graphite:   #191C22;
  --graphite-2: #212530;
  --concrete:   #E7E8E4;
  --concrete-2: #F2F3F0;
  --ink:        #1A1D23;
  --steel:      #5D6470;
  --wire:       #8FA3B4;
  --gold:       #C89B3C;
  --gold-lite:  #E3BC68;
  --gold-ink:   #7A5712;
  --rule:       #C9CBC4;
  --rule-dark:  #333949;

  --display: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --body:    'Instrument Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --mono:    'IBM Plex Mono', ui-monospace, Menlo, Consolas, monospace;

  --max: 1200px;
  --gutter: 28px;
}

/* --- 2. Base -------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--concrete);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
p { margin: 0 0 1.1em; color: var(--steel); }
p:last-child { margin-bottom: 0; }

/* Focus ring follows the surface: ink on concrete, gold on graphite.
   A single gold ring would fall under 3:1 against the light background. */
:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 1px;
}
.site-header :focus-visible,
.site-footer :focus-visible,
.hero :focus-visible,
.page-hero :focus-visible,
.on-dark :focus-visible,
.cta-band :focus-visible,
.plate :focus-visible {
  outline-color: var(--gold);
}

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  background: var(--gold); color: var(--graphite);
  padding: 10px 18px; font-family: var(--mono); font-size: .75rem;
  letter-spacing: .12em; text-transform: uppercase; font-weight: 500;
  transition: top .18s ease;
}
.skip-link:focus { top: 12px; }

/* --- 3. Type -------------------------------------------------- */
h1, h2, h3, h4 {
  font-family: var(--display);
  font-stretch: 118%;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.02;
  letter-spacing: -0.005em;
  margin: 0 0 .5em;
  color: var(--ink);
  text-wrap: balance;
}

h1 { font-size: clamp(2.5rem, 6.6vw, 5.1rem); line-height: .95; letter-spacing: -0.02em; }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.9rem); line-height: .98; letter-spacing: -0.012em; }
h3 { font-size: 1.1rem; font-stretch: 108%; letter-spacing: .005em; }
h4 { font-size: .95rem; font-stretch: 108%; letter-spacing: .01em; }

.eyebrow, .code {
  font-family: var(--mono);
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  line-height: 1.4;
}

.eyebrow {
  display: block;
  color: var(--gold-ink);
  margin-bottom: 1.15rem;
}
.on-dark .eyebrow, .hero .eyebrow, .page-hero .eyebrow { color: var(--gold); }

.lede {
  font-size: clamp(1.05rem, 1.5vw, 1.2rem);
  line-height: 1.6;
  max-width: 56ch;
}

/* --- 4. Layout ------------------------------------------------ */
.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

.section { padding: clamp(64px, 9vw, 116px) 0; }

.section-head { max-width: 62ch; margin-bottom: clamp(38px, 5vw, 60px); }
.section-head p { font-size: 1.08rem; }

/* --- 5. Header ------------------------------------------------ */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--graphite);
  border-bottom: 1px solid var(--rule-dark);
}

.nav {
  display: flex; align-items: center; gap: 28px;
  min-height: 72px;
}

.brand { display: flex; align-items: center; gap: 12px; margin-right: auto; }
.brand-glyph { width: 26px; height: 26px; flex: none; }
.brand-glyph .g-tower { fill: var(--wire); }
.brand-glyph .g-spire { fill: var(--gold); }
.brand-name {
  font-family: var(--display);
  font-stretch: 112%; font-weight: 700;
  font-size: .98rem; letter-spacing: .045em;
  text-transform: uppercase; color: #fff;
  line-height: 1.1;
  display: block;
}
.brand-sub {
  display: block;
  font-family: var(--mono); font-size: .58rem; font-weight: 400;
  letter-spacing: .17em; color: var(--wire);
  text-transform: uppercase; margin-top: 3px;
}

.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a {
  font-family: var(--mono); font-size: .715rem; font-weight: 500;
  letter-spacing: .15em; text-transform: uppercase;
  color: var(--wire);
  padding: 6px 0;
  position: relative;
  transition: color .16s ease;
}
.nav-links a:hover { color: #fff; }
.nav-links a.active { color: #fff; }
.nav-links a.active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px;
  height: 2px; background: var(--gold);
}

.nav-cta { display: flex; align-items: center; gap: 14px; }

.nav-toggle {
  display: none;
  width: 40px; height: 34px;
  background: none; border: 1px solid var(--rule-dark);
  cursor: pointer; padding: 0;
  align-items: center; justify-content: center; flex-direction: column; gap: 4px;
}
.nav-toggle span { display: block; width: 16px; height: 1.5px; background: var(--wire); }

/* --- 6. Buttons ----------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--mono); font-size: .715rem; font-weight: 500;
  letter-spacing: .14em; text-transform: uppercase;
  padding: 14px 24px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .16s ease, color .16s ease, border-color .16s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--gold); color: var(--graphite); border-color: var(--gold); }
.btn-primary:hover { background: var(--gold-lite); border-color: var(--gold-lite); }

.btn-ghost { background: transparent; color: var(--wire); border-color: var(--rule-dark); }
.btn-ghost:hover { color: #fff; border-color: var(--wire); }

.btn-block { width: 100%; }

/* --- 7. Hero -------------------------------------------------- */
.hero {
  position: relative;
  background: var(--graphite);
  color: #fff;
  overflow: hidden;
  isolation: isolate;
}

.hero-copy {
  padding-top: clamp(36px, 4.4vw, 64px);
  padding-bottom: clamp(14px, 2vw, 26px);
  position: relative; z-index: 3;
}

.hero h1 {
  color: #fff;
  max-width: 13ch;
  font-size: clamp(2.5rem, 7.4vw, 6.5rem);
}
.hero .lede { color: var(--wire); margin: 0; max-width: 46ch; }

/* headline sits above a band of lede + actions, so the hero has no dead corner */
.hero-foot {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 30px 56px;
  align-items: end;
  margin-top: clamp(22px, 3vw, 38px);
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* skyline */
.skyline-wrap {
  position: relative; z-index: 1;
  width: 100%; max-width: 1720px; margin: -4vw auto 0;
  pointer-events: none;
}
.skyline { width: 100%; height: auto; }

.sky-far  { opacity: .28; }
.sky-mid  { opacity: .55; }

.tower-fill  { fill: #232837; }
.tower-floor { fill: url(#floorlines); }
.tower-line  { fill: none; stroke: var(--wire); stroke-width: 1.25; stroke-linejoin: miter; opacity: .75; }
.sky-mid .tower-fill { fill: #1D2029; }
.crown-line  { fill: none; stroke: var(--gold); stroke-width: 1.75; }
.spire-line  { stroke: var(--gold); stroke-width: 1.75; fill: none; }

.spire-glow { fill: url(#spireglow); }

/* draw-on-load
   The hidden start state is gated on .is-drawn — the same class that starts the
   animation — so the two always arrive together. If scripting stalls between
   adding .js-draw and .is-drawn (rAF is paused in background tabs), the artwork
   stays fully visible rather than blank. Animations outrank these declarations,
   and their implicit `from` picks up the hidden value, so the reveal is intact. */
.draw { stroke-dasharray: 1; stroke-dashoffset: 0; }
.js-draw.is-drawn .draw { stroke-dashoffset: 1; }
.js-draw.is-drawn .sky-far .draw  { animation: draw 1.5s cubic-bezier(.22,.61,.36,1) .05s forwards; }
.js-draw.is-drawn .sky-mid .draw  { animation: draw 1.6s cubic-bezier(.22,.61,.36,1) .18s forwards; }
.js-draw.is-drawn .sky-near .draw { animation: draw 1.8s cubic-bezier(.22,.61,.36,1) .30s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.js-draw.is-drawn .tower-fill,
.js-draw.is-drawn .tower-floor,
.js-draw.is-drawn .spire-glow { opacity: 0; }
.js-draw.is-drawn .tower-fill,
.js-draw.is-drawn .tower-floor { animation: fadein 1.2s ease .7s forwards; }
.js-draw.is-drawn .spire-glow  { animation: fadein 1.6s ease 1.5s forwards; }
@keyframes fadein { to { opacity: 1; } }

/* grade line + title block */
.grade {
  position: relative; z-index: 3;
  border-top: 1px solid var(--gold);
  background: var(--graphite);
}
.survey {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.survey-item {
  padding: 20px 22px 22px;
  border-left: 1px solid var(--rule-dark);
}
.survey-item:first-child { border-left: 0; padding-left: 0; }
.survey-k {
  font-family: var(--display); font-stretch: 118%; font-weight: 700;
  font-size: 1.5rem; color: #fff; line-height: 1; text-transform: uppercase;
  display: block; margin-bottom: 9px;
}
.survey-v {
  font-family: var(--mono); font-size: .655rem; letter-spacing: .13em;
  text-transform: uppercase; color: var(--wire); line-height: 1.55;
  display: block;
}

/* --- 8. Panels ------------------------------------------------ */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }

.panel {
  position: relative;
  background: var(--concrete-2);
  border: 1px solid var(--rule);
  padding: 30px 28px 32px;
  transition: border-color .2s ease;
}
/* registration mark, top-left */
.panel::before, .panel::after {
  content: ""; position: absolute; background: var(--gold);
  transition: width .22s ease, height .22s ease;
}
.panel::before { left: -1px; top: -1px; width: 18px; height: 2px; }
.panel::after  { left: -1px; top: -1px; width: 2px; height: 18px; }
.panel:hover { border-color: var(--steel); }
.panel:hover::before { width: 34px; }
.panel:hover::after  { height: 34px; }

.panel .code { color: var(--gold-ink); display: block; margin-bottom: 18px; }
.panel h3 { margin-bottom: .65em; }
.panel p { font-size: .97rem; }

.spec-list { margin-top: 20px; border-top: 1px solid var(--rule); }
.spec-list li {
  font-family: var(--mono); font-size: .705rem; letter-spacing: .07em;
  text-transform: uppercase; color: var(--steel);
  padding: 10px 0 10px 18px;
  border-bottom: 1px solid var(--rule);
  position: relative;
}
.spec-list li::before {
  content: ""; position: absolute; left: 0; top: 17px;
  width: 7px; height: 1px; background: var(--gold);
}

/* --- 9. Quotes (on dark) -------------------------------------- */
.on-dark { background: var(--graphite); color: #fff; }
.on-dark h1, .on-dark h2, .on-dark h3, .on-dark h4 { color: #fff; }
.on-dark p { color: var(--wire); }

.quote-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; border-top: 1px solid var(--rule-dark); }
.quote {
  padding: 30px 34px 32px 0;
  border-bottom: 1px solid var(--rule-dark);
  display: flex; gap: 20px; align-items: flex-start;
}
.quote:nth-child(even) { padding-left: 34px; border-left: 1px solid var(--rule-dark); padding-right: 0; }
.quote-mark {
  font-family: var(--mono); font-size: .68rem; letter-spacing: .1em;
  color: var(--gold); flex: none; padding-top: 5px;
}
.quote p { color: #D8DEE6; font-size: 1.06rem; margin: 0; }

/* --- 10. Process ---------------------------------------------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-top: 1px solid var(--rule); }
.step { padding: 26px 26px 30px 0; position: relative; }
.step + .step { border-left: 1px solid var(--rule); padding-left: 26px; }
.step::before {
  content: ""; position: absolute; left: 0; top: -1px; width: 12px; height: 3px; background: var(--gold);
}
.step + .step::before { left: -1px; }
.step-num {
  font-family: var(--mono); font-size: .68rem; letter-spacing: .16em;
  color: var(--gold-ink); display: block; margin-bottom: 26px;
}
.step h4 { margin-bottom: .7em; }
.step p { font-size: .95rem; }

/* --- 11. CTA band --------------------------------------------- */
.cta-band {
  background: var(--graphite);
  color: #fff;
  padding: clamp(52px, 7vw, 84px) 0;
  position: relative;
  overflow: hidden;
}
.cta-band h2 { color: #fff; max-width: 20ch; }
.cta-band p { color: var(--wire); max-width: 54ch; font-size: 1.08rem; }
.cta-inner { display: grid; grid-template-columns: 1.35fr auto; gap: 40px; align-items: end; }

/* --- 12. Page hero (inner) ------------------------------------ */
.page-hero {
  background: var(--graphite);
  color: #fff;
  padding: clamp(58px, 8vw, 96px) 0 0;
  position: relative;
  overflow: hidden;
}
.page-hero h1 { color: #fff; max-width: 18ch; font-size: clamp(2.1rem, 5vw, 3.9rem); }
.page-hero p { color: var(--wire); max-width: 58ch; font-size: 1.1rem; }
.page-hero-inner { padding-bottom: clamp(96px, 11vw, 150px); position: relative; z-index: 2; }

.band-skyline {
  position: absolute; right: 0; bottom: 0; left: 0;
  z-index: 1; opacity: .62; pointer-events: none;
}
.band-skyline svg { width: 100%; height: auto; }
.page-hero { border-bottom: 1px solid var(--gold); }

/* --- 13. About ------------------------------------------------ */
.about-grid { display: grid; grid-template-columns: 300px 1fr; gap: clamp(32px, 5vw, 68px); align-items: start; }

.plate {
  background: var(--graphite);
  color: #fff;
  padding: 26px 24px 24px;
  position: relative;
}
.plate-mark {
  font-family: var(--display); font-stretch: 122%; font-weight: 700;
  font-size: 2.4rem; letter-spacing: .02em; color: #fff;
  line-height: 1; margin-bottom: 6px;
}
.plate-role {
  font-family: var(--mono); font-size: .63rem; letter-spacing: .16em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 22px;
}
.plate dl { margin: 0; border-top: 1px solid var(--rule-dark); }
.plate .row {
  display: flex; justify-content: space-between; gap: 14px;
  padding: 11px 0; border-bottom: 1px solid var(--rule-dark);
  font-family: var(--mono); font-size: .655rem; letter-spacing: .1em;
  text-transform: uppercase;
}
.plate .row dt { color: var(--wire); margin: 0; }
.plate .row dd { color: #fff; margin: 0; text-align: right; }

.prose p { font-size: 1.06rem; }
.prose h2 { margin-bottom: .7em; }

.values { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; margin-top: 44px; border-top: 1px solid var(--rule); }
.value { padding: 24px 26px 26px 0; border-bottom: 1px solid var(--rule); }
.value:nth-child(even) { padding-left: 26px; padding-right: 0; border-left: 1px solid var(--rule); }
.value h4 { margin-bottom: .6em; }
.value p { font-size: .95rem; margin: 0; }

/* --- 14. Contact ---------------------------------------------- */
.contact-grid { display: grid; grid-template-columns: 320px 1fr; gap: clamp(28px, 4vw, 52px); align-items: start; }

.info-list { border-top: 1px solid var(--rule); }
.info-item { padding: 18px 0; border-bottom: 1px solid var(--rule); }
.info-item .k {
  font-family: var(--mono); font-size: .655rem; letter-spacing: .16em;
  text-transform: uppercase; color: var(--steel); display: block; margin-bottom: 7px;
}
.info-item .v {
  font-family: var(--display); font-stretch: 108%; font-weight: 600;
  font-size: 1.02rem; color: var(--ink); text-transform: uppercase; letter-spacing: .01em;
  display: inline-block;
}
a.v { border-bottom: 1px solid var(--gold); padding-bottom: 1px; }
a.v:hover { color: var(--gold-ink); }

.form-card { background: var(--concrete-2); border: 1px solid var(--rule); padding: clamp(24px, 3vw, 34px); }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-family: var(--mono); font-size: .655rem; letter-spacing: .14em;
  text-transform: uppercase; color: var(--steel); margin-bottom: 7px;
}
.field input, .field select, .field textarea {
  width: 100%;
  font-family: var(--body); font-size: .98rem; color: var(--ink);
  background: #fff;
  border: 1px solid var(--rule);
  border-radius: 0;
  padding: 11px 13px;
  transition: border-color .16s ease, box-shadow .16s ease;
}
.field textarea { min-height: 148px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--gold); outline: none;
  box-shadow: inset 0 0 0 1px var(--gold);
}
.form-note {
  font-family: var(--mono); font-size: .66rem; line-height: 1.75;
  letter-spacing: .05em; color: var(--steel);
  margin: 16px 0 0; text-transform: uppercase;
}

/* Honeypot: hidden from people and assistive tech, visible to bots. */
.hp { display: none; }

.form-status {
  margin: 0 0 20px;
  padding: 15px 17px;
  background: var(--concrete);
  border-left: 3px solid var(--gold);
  color: var(--ink);
  font-size: .99rem;
  line-height: 1.55;
}
.form-status--error { border-left-color: #A3341F; }

/* --- 15. Footer ----------------------------------------------- */
.site-footer {
  background: var(--graphite); color: #fff;
  padding: clamp(44px, 5vw, 64px) 0 0;
  border-top: 1px solid var(--rule-dark);
}
.footer-grid {
  display: flex; flex-wrap: wrap; gap: 28px;
  justify-content: space-between; align-items: flex-start;
  padding-bottom: 34px;
}
.footer-links { display: flex; flex-wrap: wrap; gap: 26px; }
.footer-links a {
  font-family: var(--mono); font-size: .69rem; letter-spacing: .15em;
  text-transform: uppercase; color: var(--wire);
}
.footer-links a:hover { color: var(--gold); }
.footer-bottom {
  border-top: 1px solid var(--rule-dark);
  padding: 20px 0 26px;
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between;
  font-family: var(--mono); font-size: .655rem; letter-spacing: .11em;
  text-transform: uppercase; color: var(--wire);
}
.footer-bottom a { color: #fff; border-bottom: 1px solid var(--rule-dark); padding-bottom: 1px; }
.footer-bottom a:hover { color: var(--gold); }

/* --- 16. Responsive ------------------------------------------- */
@media (max-width: 1120px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 1000px) {
  .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .step:nth-child(odd) { border-left: 0; padding-left: 0; }
  .step:nth-child(3), .step:nth-child(4) { border-top: 1px solid var(--rule); padding-top: 26px; }
  .cta-inner { grid-template-columns: 1fr; align-items: start; }
  .cta-band .btn { justify-self: start; }
}

@media (max-width: 860px) {
  :root { --gutter: 20px; }

  .site-header { position: relative; }
  .nav-links {
    display: none;
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--graphite);
    border-bottom: 1px solid var(--rule-dark);
    padding: 6px 20px 18px;
    z-index: 120;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 13px 0; border-bottom: 1px solid var(--rule-dark); }
  .nav-links a.active::after { display: none; }
  .nav-links a.active { color: var(--gold); }
  .nav-toggle { display: flex; }
  .nav-cta .btn-primary { display: none; }

  .survey { grid-template-columns: repeat(2, 1fr); }
  .survey-item { padding: 16px 16px 18px; border-top: 1px solid var(--rule-dark); }
  .survey-item:nth-child(odd) { border-left: 0; padding-left: 0; }
  .survey-item:nth-child(-n+2) { border-top: 0; }
  .survey-k { font-size: 1.3rem; }

  .hero-foot { grid-template-columns: 1fr; align-items: start; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .quote-grid { grid-template-columns: 1fr; }
  .quote, .quote:nth-child(even) { padding: 22px 0 24px; border-left: 0; }
  .values { grid-template-columns: 1fr; }
  .value, .value:nth-child(even) { padding: 20px 0 22px; border-left: 0; }
  .row-2 { grid-template-columns: 1fr; }
  .skyline-wrap { margin-top: 12px; }
}

@media (max-width: 560px) {
  .steps { grid-template-columns: 1fr; }
  .step, .step + .step { border-left: 0; padding-left: 0; padding-top: 22px; border-top: 1px solid var(--rule); }
  .step:first-child { border-top: 0; padding-top: 26px; }
  .brand-sub { display: none; }
  .hero-actions .btn { width: 100%; }
}

/* --- 17. Motion preferences ----------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  /* Must match the specificity of the gated start state above, or it loses. */
  .js-draw.is-drawn .draw { stroke-dashoffset: 0; }
  .js-draw.is-drawn .tower-fill,
  .js-draw.is-drawn .tower-floor,
  .js-draw.is-drawn .spire-glow { opacity: 1; }
  .js-draw.is-drawn .sky-far .draw,
  .js-draw.is-drawn .sky-mid .draw,
  .js-draw.is-drawn .sky-near .draw,
  .js-draw.is-drawn .tower-fill,
  .js-draw.is-drawn .tower-floor,
  .js-draw.is-drawn .spire-glow { animation: none; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* keep compound modifiers from breaking across lines in display type */
.nb { white-space: nowrap; }
