*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --color-bg: #f7f8f5;
  --color-text: #151814;
  --color-text-muted: #556057;
  --color-text-soft: #748075;
  --color-accent: #1f6b45;
  --color-accent-strong: #124a2f;
  --color-blue: #285b7a;
  --color-amber: #a5672b;
  --color-border: #dfe5dc;
  --color-surface: #ffffff;
  --color-surface-strong: #eef3ef;
  --shadow-soft: 0 24px 70px rgba(18, 39, 28, 0.13);
  --max-width: 1120px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--color-text);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(247, 248, 245, 1) 380px),
    var(--color-bg);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
  width: 100%;
}

a {
  color: var(--color-accent);
  text-decoration: none;
}

a:hover {
  color: var(--color-accent-strong);
}

.site-nav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(247, 248, 245, 0.86);
  border-bottom: 1px solid rgba(223, 229, 220, 0.82);
  backdrop-filter: blur(18px);
  padding: 0 1.5rem;
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 1.5rem;
}

.logo {
  color: var(--color-text);
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0;
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 1.35rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-links a {
  color: var(--color-text-muted);
  font-size: 0.92rem;
  font-weight: 650;
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--color-text);
}

.hero {
  min-height: 620px;
  display: flex;
  align-items: flex-end;
  background:
    linear-gradient(90deg, rgba(12, 20, 15, 0.82) 0%, rgba(12, 20, 15, 0.64) 45%, rgba(12, 20, 15, 0.24) 100%),
    linear-gradient(180deg, rgba(12, 20, 15, 0) 55%, rgba(12, 20, 15, 0.56) 100%),
    url("/img/engineering-planning.webp") center / cover no-repeat;
  color: #fff;
}

.hero-inner {
  width: min(var(--max-width), calc(100% - 3rem));
  margin: 0 auto;
  padding: 7rem 0 5.5rem;
}

.eyebrow {
  color: var(--color-accent);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 0.7rem;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #b9efc9;
}

.hero h1 {
  font-size: 4.5rem;
  font-weight: 850;
  line-height: 1;
  letter-spacing: 0;
  margin-bottom: 1rem;
}

.hero-sub {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.22rem;
  max-width: 660px;
  margin-bottom: 2rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-bottom: 2rem;
}

.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  max-width: 720px;
}

.hero-points span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0.35rem 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.88rem;
  font-weight: 650;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0.72rem 1.2rem;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 750;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, color 0.15s, transform 0.15s;
}

.btn:hover {
  transform: translateY(-1px);
  text-decoration: none;
}

.btn-primary {
  background: #f9fff9;
  color: #163c28;
  border: 1px solid rgba(255, 255, 255, 0.7);
}

.btn-primary:hover {
  background: #dff6e5;
  color: #163c28;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.32);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.58);
}

.section {
  padding: 5rem 1.5rem;
}

.section + .section {
  border-top: 1px solid rgba(223, 229, 220, 0.76);
}

.section-inner {
  width: min(var(--max-width), 100%);
  margin: 0 auto;
}

.intro-section {
  padding-top: 4rem;
  padding-bottom: 4rem;
  background: var(--color-surface);
}

.split-intro {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 4rem;
  align-items: start;
}

.split-intro h2,
.section-heading h2 {
  font-size: 2rem;
  line-height: 1.16;
  letter-spacing: 0;
}

.split-intro > p {
  color: var(--color-text-muted);
  font-size: 1.08rem;
  max-width: 620px;
}

.section-heading {
  max-width: 720px;
  margin-bottom: 2rem;
}

.highlights,
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.highlight,
.service,
.project,
.post-link {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  box-shadow: 0 12px 36px rgba(21, 24, 20, 0.04);
}

.highlight {
  min-height: 230px;
  padding: 1.4rem;
}

.highlight h3,
.highlight h2,
.service h2,
.project h2,
.post-link h3 {
  color: var(--color-text);
  font-size: 1.08rem;
  line-height: 1.25;
  margin-bottom: 0.7rem;
}

.highlight p,
.service p,
.project p,
.post-link p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
}

.highlight:nth-child(2) {
  border-top-color: rgba(40, 91, 122, 0.42);
}

.highlight:nth-child(3) {
  border-top-color: rgba(165, 103, 43, 0.42);
}

.writing-section {
  background: var(--color-surface-strong);
}

.writing-heading {
  max-width: none;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
}

.text-link {
  color: var(--color-accent-strong);
  font-size: 0.95rem;
  font-weight: 750;
  white-space: nowrap;
}

.text-link::after {
  content: " ->";
}

.writing-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.post-link {
  display: flex;
  flex-direction: column;
  min-height: 230px;
  padding: 1.35rem;
  color: inherit;
  text-decoration: none;
  transition: border-color 0.15s, transform 0.15s, box-shadow 0.15s;
}

.post-link:hover {
  border-color: rgba(31, 107, 69, 0.45);
  box-shadow: var(--shadow-soft);
  color: inherit;
  transform: translateY(-2px);
}

.post-meta {
  color: var(--color-blue);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 1.4rem;
  text-transform: uppercase;
}

.page-header,
.services-grid,
.approach-content,
.work-content,
.contact-content,
.legal-content {
  width: min(var(--max-width), calc(100% - 3rem));
  margin-left: auto;
  margin-right: auto;
}

.page-header {
  padding: 5rem 0 2.5rem;
  border-bottom: 1px solid var(--color-border);
  margin-bottom: 2.5rem;
}

.page-header h1 {
  font-size: 3rem;
  font-weight: 850;
  letter-spacing: 0;
  line-height: 1.06;
  margin-bottom: 0.75rem;
}

.page-header p {
  color: var(--color-text-muted);
  font-size: 1.15rem;
  max-width: 640px;
}

.services-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  padding-bottom: 5rem;
}

.service,
.project {
  padding: 1.4rem;
}

.approach-content,
.work-content {
  display: grid;
  gap: 1rem;
  padding-bottom: 5rem;
}

.principle {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 1.5rem;
}

.principle h2 {
  font-size: 1.18rem;
  margin-bottom: 0.5rem;
}

.principle p {
  color: var(--color-text-muted);
  font-size: 0.96rem;
  max-width: 720px;
}

.project p {
  margin-bottom: 0.9rem;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  background: #eef3ef;
  color: var(--color-text-muted);
  padding: 0.2rem 0.58rem;
  border: 1px solid rgba(85, 96, 87, 0.12);
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 650;
  margin-right: 0.35rem;
  margin-bottom: 0.35rem;
}

.work-note {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  font-style: italic;
}

.contact-content {
  max-width: 660px;
  padding-bottom: 5rem;
}

.contact-info {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 1.5rem;
}

.contact-info h2 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.contact-info p {
  color: var(--color-text-muted);
  font-size: 0.98rem;
  margin-bottom: 0.75rem;
}

.contact-info p:last-child {
  margin-bottom: 0;
}

.legal-content {
  color: var(--color-text-muted);
  max-width: 780px;
  margin-bottom: 5rem;
}

.legal-content h1,
.legal-content h2 {
  color: var(--color-text);
}

.legal-content h1 {
  font-size: 2.7rem;
  margin-bottom: 0.85rem;
}

.legal-content h2 {
  font-size: 1.35rem;
  margin: 1.8rem 0 0.55rem;
}

.legal-content p {
  font-size: 0.98rem;
  line-height: 1.72;
  margin-bottom: 0.8rem;
}

.site-footer {
  border-top: 1px solid var(--color-border);
  padding: 1.5rem;
  margin-top: auto;
  background: var(--color-surface);
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: nowrap;
}

.footer-links {
  margin-left: auto;
  display: flex;
  justify-content: flex-end;
  gap: 1.4rem;
  flex-wrap: nowrap;
}

.footer-links a {
  color: var(--color-text);
  font-size: 0.92rem;
  font-weight: 650;
  white-space: nowrap;
}

.footer-links a:hover {
  color: var(--color-text);
}

.site-footer p {
  color: var(--color-text-muted);
  font-size: 0.92rem;
  white-space: nowrap;
  margin: 0;
}

@media (max-width: 900px) {
  .hero {
    min-height: 560px;
  }

  .hero h1 {
    font-size: 3.25rem;
  }

  .split-intro,
  .highlights,
  .writing-grid,
  .services-grid {
    grid-template-columns: 1fr;
  }

  .split-intro {
    gap: 1.4rem;
  }

  .writing-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 1rem;
  }
}

@media (max-width: 640px) {
  .site-nav {
    padding: 0 1rem;
  }

  .nav-inner {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    min-height: auto;
    padding: 0.9rem 0;
  }

  .nav-links {
    gap: 0.7rem 1rem;
    justify-content: flex-start;
  }

  .hero {
    min-height: 560px;
    background-position: 58% center;
  }

  .hero-inner {
    width: min(100% - 2rem, var(--max-width));
    padding: 5rem 0 3.5rem;
  }

  .hero h1 {
    font-size: 2.45rem;
  }

  .hero-sub {
    font-size: 1rem;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    width: 100%;
  }

  .section {
    padding: 3.5rem 1rem;
  }

  .split-intro h2,
  .section-heading h2 {
    font-size: 1.65rem;
  }

  .page-header,
  .services-grid,
  .approach-content,
  .work-content,
  .contact-content {
    width: min(100% - 2rem, var(--max-width));
  }

  .page-header {
    padding-top: 3.5rem;
  }

  .page-header h1 {
    font-size: 2.2rem;
  }
}
