:root {
  --bg: #f6f8fb;
  --surface: #ffffff;
  --text: #14202e;
  --muted: #536274;
  --accent: #1f7ae0;
  --accent-ink: #ffffff;
  --border: #dde4ec;
  --ink: #0a1524;
  --warm: #ffb454;
  --radius: 14px;
  --shadow: 0 18px 40px -24px rgba(10, 25, 45, .4);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b131d;
    --surface: #121d2a;
    --text: #e6edf5;
    --muted: #9aabbd;
    --accent: #4c9bf0;
    --accent-ink: #06121f;
    --border: #223243;
    --ink: #060d16;
    --shadow: 0 18px 40px -24px rgba(0, 0, 0, .8);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 78px; }
body { margin: 0; background: var(--bg); color: var(--text); line-height: 1.6; -webkit-text-size-adjust: 100%; }
a { color: var(--accent); }
img { max-width: 100%; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
::selection { background: color-mix(in srgb, var(--accent) 28%, transparent); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: blur(10px) saturate(1.2);
  border-bottom: 1px solid color-mix(in srgb, var(--border) 70%, transparent);
  transition: box-shadow .3s ease, background .3s ease;
}
.site-header.scrolled { box-shadow: 0 12px 28px -20px rgba(10, 25, 45, .6); background: color-mix(in srgb, var(--bg) 94%, transparent); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-size: 1.25rem; letter-spacing: -.01em; }
.brand strong { color: var(--accent); }
.brand img { border-radius: 7px; transition: transform .4s cubic-bezier(.2, .7, .2, 1); }
.brand:hover img { transform: rotate(-6deg) scale(1.05); }
nav { display: flex; align-items: center; gap: 22px; }
nav a { position: relative; text-decoration: none; color: var(--muted); font-weight: 500; font-size: .95rem; }
nav a:not(.btn)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px;
  background: var(--accent); border-radius: 2px; transform: scaleX(0); transform-origin: left;
  transition: transform .3s ease;
}
nav a:not(.btn):hover { color: var(--text); }
nav a:not(.btn):hover::after { transform: scaleX(1); }

.menu-toggle {
  display: none; align-items: center; justify-content: center;
  width: 42px; height: 42px; padding: 0; border: 0; border-radius: 11px;
  background: transparent; color: var(--text); cursor: pointer;
}
.menu-toggle:hover { background: color-mix(in srgb, var(--text) 8%, transparent); }
.menu-toggle svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.menu-toggle .i-close { display: none; }
.menu-toggle[aria-expanded="true"] .i-open { display: none; }
.menu-toggle[aria-expanded="true"] .i-close { display: block; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; background: var(--accent); color: var(--accent-ink);
  border: 0; border-radius: 999px; padding: 12px 22px; font-weight: 600; font-size: 1rem;
  text-decoration: none; cursor: pointer; transition: transform .2s ease, filter .2s ease, box-shadow .2s ease;
}
nav a.btn { color: var(--accent-ink); }
.btn:hover { filter: brightness(1.08); transform: translateY(-1px); box-shadow: 0 10px 22px -12px color-mix(in srgb, var(--accent) 80%, transparent); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: .6; cursor: wait; transform: none; }
.btn-small { padding: 8px 16px; font-size: .9rem; }
.btn-lg { padding: 14px 28px; }
.btn-ghost { background: rgba(255, 255, 255, .1); color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .55); }
.btn-ghost:hover { background: rgba(255, 255, 255, .18); }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; align-items: center;
  min-height: clamp(520px, 68vh, 700px);
  padding: 56px 0 112px;
  color: #fff; background: var(--ink);
}
.hero-media { position: absolute; inset: 0; z-index: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 55%; display: block; }
.hero-media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(to bottom, rgba(8, 18, 30, .5) 0%, rgba(8, 18, 30, .12) 30%, rgba(8, 18, 30, .45) 72%, var(--bg) 100%),
    linear-gradient(to right, rgba(8, 18, 30, .86) 0%, rgba(8, 18, 30, .5) 42%, rgba(8, 18, 30, .05) 76%, rgba(8, 18, 30, .22) 100%);
}
.hero-inner { position: relative; z-index: 2; width: 100%; }
.hero .eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  text-transform: uppercase; letter-spacing: .12em; font-size: .78rem; font-weight: 600;
  margin: 0 0 18px; padding: 8px 16px 8px 12px; border-radius: 999px;
  background: rgba(255, 255, 255, .09); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18);
  backdrop-filter: blur(6px); color: #eef4fb;
}
.pulse {
  width: 8px; height: 8px; border-radius: 50%; background: var(--warm);
  box-shadow: 0 0 0 0 rgba(255, 180, 84, .65); animation: pulse 2.6s ease-out infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(255, 180, 84, .6); }
  70%, 100% { box-shadow: 0 0 0 9px rgba(255, 180, 84, 0); }
}
.hero h1 {
  font-size: clamp(2.1rem, 5.4vw, 3.6rem); line-height: 1.06; letter-spacing: -.025em;
  margin: 0 0 20px; max-width: 20ch; text-wrap: balance;
  text-shadow: 0 2px 30px rgba(4, 12, 22, .45);
}
.hero .lede { font-size: clamp(1.05rem, 2vw, 1.22rem); max-width: 50ch; color: #dce6f2; margin: 0; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 32px; }

.scroll-cue {
  position: absolute; z-index: 2; left: 50%; bottom: 82px; transform: translateX(-50%);
  color: rgba(255, 255, 255, .7); line-height: 0; animation: bob 2.4s ease-in-out infinite;
}
.scroll-cue:hover { color: #fff; }
@keyframes bob { 0%, 100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 7px); } }

/* ---------- Trust strip ---------- */
.strip { position: relative; z-index: 3; margin-top: -46px; }
.strip-inner {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 18px;
  padding: 16px 12px; box-shadow: var(--shadow);
}
.strip-item { display: flex; align-items: center; gap: 10px; padding: 4px 12px; font-size: .9rem; color: var(--muted); }
.strip-item + .strip-item { border-left: 1px solid var(--border); }
.strip-item svg { width: 22px; height: 22px; flex: none; fill: none; stroke: var(--accent); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.strip-item strong { display: block; color: var(--text); font-weight: 600; font-size: .92rem; }

/* ---------- Sections ---------- */
.section { padding: 84px 0; }
.section-alt { background: var(--surface); border-block: 1px solid var(--border); }
.section-head { max-width: 62ch; margin-bottom: 34px; }
.kicker {
  display: inline-flex; align-items: center; gap: 9px;
  text-transform: uppercase; letter-spacing: .14em; font-size: .74rem; font-weight: 700;
  color: var(--accent); margin: 0 0 10px;
}
.kicker::before { content: ""; width: 22px; height: 2px; border-radius: 2px; background: currentColor; opacity: .55; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.3rem); line-height: 1.15; letter-spacing: -.02em; margin: 0 0 18px; }
.section-head .sub, .about p, .contact p { color: var(--muted); margin-top: 0; }

/* ---------- Recent work ---------- */
.work-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.work-item { margin: 0; }
.work-item.wide { grid-column: 1 / -1; }
.work-open {
  display: block; position: relative; width: 100%; padding: 0; border: 0;
  background: var(--border); border-radius: var(--radius); overflow: hidden;
  cursor: zoom-in; aspect-ratio: 3 / 2; -webkit-tap-highlight-color: transparent;
}
.work-item.wide .work-open { aspect-ratio: 2 / 1; }
.work-open img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .7s cubic-bezier(.2, .7, .2, 1), filter .4s ease;
}
.work-open::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(6, 14, 24, .5), rgba(6, 14, 24, 0) 55%);
  opacity: 0; transition: opacity .4s ease;
}
.work-open:hover img, .work-open:focus-visible img { transform: scale(1.045); }
.work-open:hover::after, .work-open:focus-visible::after { opacity: 1; }
.work-item figcaption { padding: 12px 2px 0; font-weight: 600; font-size: .96rem; line-height: 1.4; }
.work-item figcaption span { display: block; font-weight: 400; font-size: .82rem; color: var(--muted); }

/* ---------- Lightbox ---------- */
.lightbox {
  position: relative; padding: 0; margin: auto; border: 0; max-width: min(1120px, 94vw); max-height: 92vh;
  background: #07111c; color: #dce6f2; border-radius: var(--radius); overflow: hidden;
}
.lightbox img { display: block; width: 100%; max-height: 80vh; object-fit: contain; background: #07111c; }
.lightbox p { margin: 0; padding: 12px 18px 14px; font-size: .86rem; opacity: .8; }
.lightbox::backdrop { background: rgba(5, 11, 19, .82); backdrop-filter: blur(4px); }
.lightbox form { position: absolute; top: 10px; right: 10px; margin: 0; }
.lightbox-close {
  width: 38px; height: 38px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(9, 20, 33, .7); color: #fff; font-size: 1rem; line-height: 1;
  backdrop-filter: blur(6px); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2);
}
.lightbox-close:hover { background: rgba(9, 20, 33, .9); }

/* ---------- Service cards ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; }
.card {
  position: relative; background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px 24px 24px; overflow: hidden;
  transition: transform .35s cubic-bezier(.2, .7, .2, 1), box-shadow .35s ease, border-color .35s ease;
}
.card::before {
  content: ""; position: absolute; inset: 0 0 auto; height: 3px;
  background: linear-gradient(90deg, var(--accent), color-mix(in srgb, var(--warm) 80%, var(--accent)));
  transform: scaleX(0); transform-origin: left; transition: transform .4s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--accent) 30%, var(--border)); }
.card:hover::before { transform: scaleX(1); }
.card h3 { margin: 0 0 8px; font-size: 1.08rem; letter-spacing: -.01em; }
.card p { margin: 0; color: var(--muted); }
.card p.note { margin-top: 10px; font-size: .85rem; font-style: italic; opacity: .9; }
.icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; margin-bottom: 16px; border-radius: 12px;
  background: color-mix(in srgb, var(--accent) 12%, transparent); color: var(--accent);
}
.icon svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- About ---------- */
.about { display: grid; grid-template-columns: 1.35fr 1fr; gap: 48px; align-items: start; }
.about p { margin-bottom: 12px; }
.about-side { display: grid; gap: 12px; align-content: start; }
.veteran {
  display: flex; align-items: center; gap: 16px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 14px 18px;
  transition: border-color .3s ease, transform .3s ease;
}
.veteran:hover { border-color: color-mix(in srgb, var(--accent) 35%, var(--border)); transform: translateX(3px); }
.veteran img { flex: none; width: 92px; height: auto; }
.veteran strong { font-size: 1rem; line-height: 1.35; }
.facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.facts li {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px 18px; transition: border-color .3s ease, transform .3s ease;
}
.facts li:hover { border-color: color-mix(in srgb, var(--accent) 35%, var(--border)); transform: translateX(3px); }
.facts span { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: 3px; }

/* ---------- Service area ---------- */
.areas { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; }
.areas > div { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px 24px 24px; }
.areas h3 { margin: 0 0 14px; font-size: 1rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 700; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.chips li {
  background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
  padding: 5px 12px; font-size: .875rem; color: var(--muted);
  transition: color .25s ease, border-color .25s ease, background .25s ease;
}
.chips li:hover { color: var(--text); border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.areas > div:hover .chips li { border-color: color-mix(in srgb, var(--accent) 22%, var(--border)); }

/* ---------- Contact ---------- */
.contact { display: grid; grid-template-columns: 1fr 1.15fr; gap: 48px; align-items: start; }
.email-line { font-weight: 600; }
.form {
  display: grid; gap: 16px; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow);
}
.form label { display: grid; gap: 6px; font-weight: 600; font-size: .9rem; }
.form input, .form textarea {
  font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--border);
  border-radius: 10px; padding: 11px 13px; transition: border-color .2s ease, box-shadow .2s ease;
}
.form textarea { resize: vertical; min-height: 120px; }
.form input:focus, .form textarea:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
}
.form .btn { justify-self: start; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { margin: 0; min-height: 1.5em; color: var(--muted); font-size: .92rem; }
.form-status.ok { color: #1a9a5a; }
.form-status.err { color: #d14343; }

/* ---------- Footer ---------- */
.site-footer { padding: 30px 0; color: var(--muted); font-size: .875rem; border-top: 1px solid var(--border); }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.footer-inner p { margin: 0; }
.to-top { color: var(--muted); text-decoration: none; white-space: nowrap; }
.to-top:hover { color: var(--accent); }

/* ---------- Motion ---------- */
.js .reveal {
  opacity: 0; transform: translateY(16px);
  transition: opacity .6s ease, transform .6s cubic-bezier(.2, .7, .2, 1);
  transition-delay: var(--d, 0s);
}
.js .reveal.in { opacity: 1; transform: none; }

@keyframes heroDrift { from { transform: scale(1.03); } to { transform: scale(1.16); } }
.hero-media img { animation: heroDrift 34s ease-in-out infinite alternate; transform-origin: 50% 40%; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .reveal, .js .reveal { opacity: 1; transform: none; }
  .hero-media img { animation: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .menu-toggle { display: inline-flex; }
  nav {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 6px 20px 18px; background: var(--surface);
    border-bottom: 1px solid var(--border); box-shadow: var(--shadow);
    opacity: 0; visibility: hidden; transform: translateY(-8px); pointer-events: none;
    transition: opacity .2s ease, transform .2s ease, visibility .2s;
  }
  nav.open { opacity: 1; visibility: visible; transform: none; pointer-events: auto; }
  nav a { padding: 13px 2px; font-size: 1rem; border-bottom: 1px solid color-mix(in srgb, var(--border) 65%, transparent); }
  nav a:not(.btn)::after { display: none; }
  nav a.btn { margin-top: 14px; border-bottom: 0; text-align: center; }
  .strip-inner { grid-template-columns: 1fr 1fr; }
  .strip-item + .strip-item { border-left: 0; }
  .strip-item:nth-child(even) { border-left: 1px solid var(--border); }
}
@media (max-width: 760px) {
  .about, .contact { grid-template-columns: 1fr; gap: 30px; }
  .section { padding: 58px 0; }
  .hero { min-height: 0; padding: 72px 0 92px; }
  /* Portrait crop: shift toward the sunset so the frame isn't just grey sky. */
  .hero-media img { object-position: 72% 58%; }
  .hero h1 { max-width: 100%; }
  .scroll-cue { display: none; }
  .work-grid { grid-template-columns: 1fr; }
  .work-item.wide .work-open { aspect-ratio: 4 / 3; }
  .strip { margin-top: -38px; }
  .strip-item { padding: 4px 8px; font-size: .84rem; }
  .cta-row .btn { flex: 1 1 auto; text-align: center; }
}
@media (max-width: 360px) {
  .strip-inner { grid-template-columns: 1fr; padding: 10px 12px; }
  .strip-item + .strip-item, .strip-item:nth-child(even) { border-left: 0; border-top: 1px solid var(--border); padding-top: 10px; }
  .strip-item { padding-bottom: 4px; }
}
