/* ==========================================================================
   Todd Construction — base styles
   Font: Helvetica (system stack fallback to Arial for platforms without it)
   ========================================================================== */

:root {
  --navy: #07002B;
  --navy-soft: #100a3d;
  --cream: #F7F5F0;
  --white: #FFFFFF;
  --muted: #8C8C93;
  --muted-light: rgba(255,255,255,0.65);
  --ink: #1A1A1A;
  --grey: #6B6B70;
  --line: rgba(7, 0, 43, 0.1);
  --max-width: 1200px;
  --gap: clamp(1.5rem, 4vw, 3rem);
  font-size: 16px;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a { color: inherit; text-decoration: none; }

h1, h2, h3 {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-weight: 700;
  margin: 0;
  letter-spacing: -0.01em;
}

p { line-height: 1.7; margin: 0 0 1.1em; color: var(--grey); }

.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 clamp(1.25rem, 4vw, 3rem);
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--muted);
  margin: 0 0 0.9em;
}
.eyebrow-light { color: var(--muted-light); }

.btn {
  display: inline-block;
  padding: 0.95em 2em;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: 2px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: all 0.25s ease;
}
.btn-light {
  background: var(--white);
  color: var(--navy);
}
.btn-light:hover { background: var(--cream); }
.btn-outline {
  background: transparent;
  border-color: rgba(255,255,255,0.7);
  color: var(--white);
}
.btn-outline:hover { background: rgba(255,255,255,0.12); }
.btn-dark {
  background: var(--navy);
  color: var(--white);
}
.btn-dark:hover { background: var(--navy-soft); }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  padding: 0 clamp(1.25rem, 4vw, 3rem);
  height: 84px;
  transition: background 0.35s ease, height 0.35s ease, box-shadow 0.35s ease;
}
.site-header.scrolled {
  background: rgba(7, 0, 43, 0.96);
  height: 68px;
  box-shadow: 0 2px 20px rgba(0,0,0,0.15);
}
.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  color: var(--white);
  font-weight: 700;
  font-size: 1.2rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.main-nav {
  display: flex;
  gap: clamp(1.25rem, 3vw, 2.5rem);
  margin-left: auto;
  margin-right: 2.5rem;
}
.main-nav a {
  color: rgba(255,255,255,0.88);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
  position: relative;
  padding-bottom: 4px;
}
.main-nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0; height: 1px;
  background: var(--white);
  transition: width 0.25s ease;
}
.main-nav a:hover::after { width: 100%; }
.main-nav a.header-cta::after { display: none; }

.header-cta {
  border: 1.5px solid rgba(255,255,255,0.6);
  color: var(--white);
  padding: 0.6em 1.4em;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  white-space: nowrap;
  transition: background 0.25s ease;
}
.header-cta:hover { background: rgba(255,255,255,0.12); }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px; height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  margin-left: 1rem;
}
.nav-toggle span {
  display: block;
  width: 24px; height: 2px;
  background: var(--white);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  height: 100svh;
  min-height: 560px;
  display: flex;
  align-items: center;
  overflow: hidden;
  color: var(--white);
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 55%;
  background-attachment: fixed;
}
@supports not (background-attachment: fixed) {
  .hero-bg { background-attachment: scroll; }
}
/* iOS Safari ignores background-attachment: fixed; fall back to a static cover image */
@supports (-webkit-touch-callout: none) {
  .hero-bg { background-attachment: scroll; }
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7,0,43,0.55) 0%, rgba(7,0,43,0.35) 45%, rgba(7,0,43,0.85) 100%);
}
.hero-content {
  position: relative;
  z-index: 2;
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  padding: 0 clamp(1.25rem, 4vw, 3rem);
}
.hero-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.25em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--muted-light);
  margin-bottom: 1.2em;
}
.hero h1 {
  font-size: clamp(2.6rem, 7vw, 5.5rem);
  line-height: 1.02;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 0.4em;
}
.hero-sub {
  color: rgba(255,255,255,0.85);
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  max-width: 40em;
  margin-bottom: 1.8em;
}
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ---------- About ---------- */
.about { padding: clamp(4rem, 10vw, 8rem) 0; background: var(--cream); }
.about-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: var(--gap);
  align-items: start;
}
.about-media { position: sticky; top: 110px; }
.about-photo-frame {
  aspect-ratio: 4 / 5;
  background: var(--white);
  border: 1px solid var(--line);
  overflow: hidden;
}
.about-photo-frame img { width: 100%; height: 100%; object-fit: cover; }
.about-media-caption {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  font-size: 0.85rem;
}
.about-media-caption strong { color: var(--navy); }
.about-media-caption span { color: var(--grey); }

.about-copy h2 {
  font-size: clamp(2rem, 4vw, 2.8rem);
  color: var(--navy);
  margin-bottom: 0.7em;
}
.about-copy p { max-width: 60em; }
.about-close { font-weight: 500; color: var(--ink); font-size: 1.05rem; }

.values {
  display: grid;
  gap: 1.75rem;
  margin: 2.5rem 0 2.5rem;
}
.value {
  border-top: 1px solid var(--line);
  padding-top: 1.5rem;
  position: relative;
}
.value-index {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 0.5em;
}
.value h3 {
  color: var(--navy);
  font-size: 1.3rem;
  margin-bottom: 0.5em;
}
.value p { margin-bottom: 0; }

.section-lead { max-width: 42em; font-size: 1.05rem; }
.section-lead-light { color: rgba(255,255,255,0.75); }

/* ---------- Contact ---------- */
.contact { background: var(--navy-soft); color: var(--white); padding: clamp(4rem, 10vw, 8rem) 0; }
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap);
}
.contact h2 { color: var(--white); font-size: clamp(2rem, 4vw, 2.8rem); margin-bottom: 0.5em; }
.contact-details { margin-top: 2.5rem; display: grid; gap: 1.4rem; }
.contact-details dt {
  text-transform: uppercase;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--muted-light);
  margin-bottom: 0.3em;
}
.contact-details dd { margin: 0; font-size: 1.15rem; }
.contact-details a:hover { color: rgba(255,255,255,0.7); }

.contact-form {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.12);
  padding: clamp(1.5rem, 3vw, 2.5rem);
  border-radius: 4px;
}
.form-row { margin-bottom: 1.25rem; display: flex; flex-direction: column; gap: 0.5rem; }
.form-row label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; color: rgba(255,255,255,0.7); }
.form-row input, .form-row textarea {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.2);
  color: var(--white);
  font-family: inherit;
  font-size: 1rem;
  padding: 0.8em 1em;
  border-radius: 2px;
  resize: vertical;
}
.form-row input:focus, .form-row textarea:focus {
  outline: none;
  border-color: rgba(255,255,255,0.6);
  background: rgba(255,255,255,0.09);
}
.hidden-field { position: absolute; left: -9999px; }
.form-status { margin: 1rem 0 0; font-size: 0.9rem; color: rgba(255,255,255,0.8); min-height: 1.2em; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: rgba(255,255,255,0.6); padding: 1.75rem 0; }
.footer-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.8rem;
  letter-spacing: 0.02em;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .about-media { position: static; margin-bottom: 2rem; max-width: 360px; }
}

@media (max-width: 760px) {
  .main-nav { display: none; }
  .nav-toggle { display: flex; }

  .main-nav.open {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: fixed;
    top: 68px; left: 0; right: 0;
    background: rgba(7,0,43,0.98);
    padding: 1.5rem clamp(1.25rem, 4vw, 3rem) 2rem;
    gap: 1.25rem;
    margin: 0;
  }
  .main-nav.open a.header-cta {
    margin-top: 0.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
