:root {
  --bg: #f8f7f2;
  --paper: #f8f7f2;
  --ink: #151515;
  --muted: #6b6a64;
  --line: rgba(21, 21, 21, 0.14);
  --accent: #b1202a;
  --forest: #284235;
  --steel: #63798a;
  --shadow: 0 22px 70px rgba(21, 21, 21, 0.13);
  --hero-title-min: 32px;
  --hero-title-fluid: 5.4vw;
  --hero-title-max: 50px;
  --section-title-min: 28px;
  --section-title-fluid: 3.2vw;
  --section-title-max: 46px;
  --body-text-size: 19px;
  --service-title-size: 24px;
  --project-title-size: 30px;
  --hero-content-left: 32px;
  --hero-content-top: 118px;
  --hero-content-width: 920px;
  --hero-tablet-top: 104px;
  --hero-mobile-left: 14px;
  --hero-mobile-top: 92px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, Arial, Helvetica, sans-serif;
  letter-spacing: 0;
}

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

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

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 20;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 28px;
  padding: 18px clamp(18px, 4vw, 56px);
  color: white;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
}

.site-header.is-scrolled {
  background: rgba(248, 247, 242, 0.94);
  color: var(--ink);
  border-bottom-color: var(--line);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  position: relative;
}

.brand-mark {
  width: 132px;
  height: auto;
  max-height: 62px;
  object-fit: contain;
  padding: 0;
  background: transparent;
}

.brand-mark-light {
  display: block;
}

.brand-mark-dark {
  display: none;
}

.site-header.is-scrolled .brand-mark-light {
  display: none;
}

.site-header.is-scrolled .brand-mark-dark {
  display: block;
}

.nav {
  display: flex;
  gap: 24px;
  font-size: 18px;
  justify-self: start;
}

.header-contacts {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 18px;
}

.header-contacts a {
  white-space: nowrap;
}

.hero {
  position: relative;
  height: clamp(620px, 76vh, 760px);
  display: grid;
  align-items: start;
  overflow: hidden;
}

.hero-image,
.hero-slideshow,
.hero-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-image {
  opacity: 0;
  object-fit: cover;
  transition: opacity 1.1s ease;
}

.hero-image.is-active {
  opacity: 1;
}

.hero-overlay {
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.22) 54%, rgba(0, 0, 0, 0.12));
}

.hero-content {
  position: absolute;
  z-index: 1;
  top: var(--hero-content-top);
  left: var(--hero-content-left);
  width: min(var(--hero-content-width), calc(100% - 36px));
  margin: 0;
  padding: 0;
  color: white;
}

.eyebrow,
.section-label {
  margin: 0 0 22px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.hero .eyebrow {
  color: #ffffff;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 820px;
  margin-bottom: 24px;
  font-size: clamp(var(--hero-title-min), var(--hero-title-fluid), var(--hero-title-max));
  line-height: 1;
  font-weight: 760;
}

h2 {
  font-size: clamp(var(--section-title-min), var(--section-title-fluid), var(--section-title-max));
  line-height: 1.06;
  font-weight: 740;
}

.hero-lede {
  max-width: 780px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(16px, 1.5vw, 20px);
  line-height: 1.45;
  white-space: pre-line;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border: 1px solid var(--ink);
  cursor: pointer;
  font: inherit;
}

.button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}

.button.secondary {
  border-color: rgba(255, 255, 255, 0.78);
  color: white;
}

.hero-stats {
  position: absolute;
  z-index: 2;
  right: clamp(18px, 4vw, 56px);
  bottom: 28px;
  display: grid;
  grid-template-columns: repeat(3, minmax(130px, 1fr));
  width: min(620px, calc(100% - 36px));
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(12px);
}

.hero-stats div {
  padding: 18px;
  border-right: 1px solid rgba(255, 255, 255, 0.22);
}

.hero-stats div:last-child {
  border-right: 0;
}

.hero-stats strong {
  display: block;
  font-size: 26px;
  line-height: 1;
}

.hero-stats span {
  display: block;
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.section {
  padding: clamp(72px, 9vw, 132px) clamp(18px, 4vw, 56px);
}

.services {
  padding-top: 44px;
  padding-bottom: 0;
}

.services .section-head {
  margin-bottom: 28px;
}

.intro {
  display: grid;
  grid-template-columns: minmax(160px, 0.34fr) minmax(0, 1fr);
  gap: clamp(28px, 7vw, 100px);
  padding-top: 28px;
  padding-bottom: 28px;
  background: var(--paper);
}

.intro-copy {
  max-width: 980px;
}

.intro-copy p {
  max-width: 760px;
  color: var(--muted);
  font-size: var(--body-text-size);
  line-height: 1.65;
  text-align: justify;
  text-wrap: pretty;
}

.about-detail {
  background: var(--paper);
  padding: 0 clamp(18px, 4vw, 56px) clamp(72px, 9vw, 132px);
}

.about-detail-row {
  display: grid;
  grid-template-columns: minmax(160px, 0.34fr) minmax(0, 1fr);
  gap: clamp(28px, 7vw, 100px);
  padding: 0 0 36px;
  background: var(--paper);
}

.about-detail-row:last-child {
  padding-bottom: 0;
}

.about-detail-row .side-title {
  font-size: clamp(24px, 2.15vw, 34px);
  line-height: 1.08;
}

.about-detail-copy {
  max-width: 980px;
}

.about-detail-copy p {
  max-width: 860px;
  color: var(--muted);
  font-size: var(--body-text-size);
  line-height: 1.65;
  text-align: justify;
}

.about-detail-copy ul {
  display: grid;
  gap: 12px;
  margin: 18px 0 0;
  padding-left: 20px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.62;
}

.about-detail-copy > ul:first-child {
  margin-top: 0;
}

.about-detail-copy li {
  text-align: justify;
}

.about-detail-copy strong {
  color: var(--ink);
  font-weight: 760;
}

.section-head {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(28px, 7vw, 100px);
  margin-bottom: 44px;
}

.section-head h2 {
  max-width: 920px;
}

.services .section-head h2 {
  margin-inline: auto;
  text-align: center;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  width: 100%;
  max-width: 1180px;
  margin-inline: auto;
}

.service-card {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 22px;
  min-height: 230px;
  padding: 28px;
  border: 1px solid rgba(21, 21, 21, 0.08);
  border-radius: 28px;
  background: rgba(255, 253, 247, 0.62);
  box-shadow: 0 16px 46px rgba(21, 21, 21, 0.06);
}

.service-card h3 {
  margin: 0;
  font-size: var(--service-title-size);
  line-height: 1.08;
  white-space: pre-line;
}

.service-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  text-align: justify;
  text-wrap: pretty;
}

.projects {
  background: var(--paper);
  overflow: hidden;
  padding-top: 44px;
}

.projects .section-head {
  margin-bottom: 28px;
}

.projects .section-head h2 {
  margin-inline: auto;
  text-align: center;
}

.project-grid {
  display: grid;
  gap: 14px;
  position: relative;
  left: 50%;
  width: min(100vw, 1440px);
  transform: translateX(-50%);
}

.project-card {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  min-height: 0;
  margin-inline: auto;
  overflow: hidden;
  background: var(--paper);
  color: white;
}

.project-slides,
.project-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.project-slide {
  object-fit: contain;
  opacity: 0;
  transition: opacity 0.45s ease, transform 0.65s ease;
}

.project-slide.is-active {
  opacity: 1;
}

.project-card:hover .project-slide.is-active {
  transform: scale(1.035);
}

.project-card-content {
  position: absolute;
  inset: auto 0 0;
  z-index: 2;
  padding: clamp(24px, 4vw, 42px) clamp(24px, 4vw, 42px) clamp(58px, 5vw, 76px);
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.82));
}

.project-card small {
  color: rgba(255, 255, 255, 0.72);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.project-card h3 {
  margin: 12px 0 10px;
  font-size: var(--project-title-size);
  line-height: 1.05;
}

.project-card p {
  max-width: 520px;
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.45;
  white-space: pre-line;
}

.project-controls {
  position: absolute;
  z-index: 3;
  right: clamp(18px, 3vw, 34px);
  bottom: clamp(22px, 4vw, 38px);
  display: flex;
  gap: 10px;
}

.project-controls button {
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  background: rgba(0, 0, 0, 0.24);
  color: white;
  cursor: pointer;
  font: inherit;
  font-size: 28px;
  line-height: 1;
}

.project-dots {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: clamp(22px, 3vw, 34px);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  width: min(420px, calc(100% - 220px));
  transform: translateX(-50%);
}

.project-dots button {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 999px;
  background: transparent;
  cursor: pointer;
}

.project-dots button.is-active {
  background: white;
}

.contact-section {
  display: grid;
  grid-template-columns: minmax(160px, 0.34fr) minmax(0, 1fr);
  gap: clamp(24px, 5vw, 70px);
  align-items: start;
  padding: 48px clamp(18px, 4vw, 56px) 18px;
  background: #141414;
  color: white;
}

.contact-heading {
  display: grid;
  justify-items: center;
  gap: 18px;
  width: max-content;
  max-width: 100%;
}

.side-title {
  margin: 0;
  font-size: clamp(28px, 3.2vw, 46px);
  line-height: 1.06;
  font-weight: 740;
}

.intro > .side-title {
  font-size: clamp(24px, 2.15vw, 34px);
  line-height: 1.08;
}

.contact-details {
  display: grid;
  gap: 10px;
  max-width: 860px;
}

.contact-details p {
  display: grid;
  gap: 4px;
  margin: 0;
}

.contact-details span {
  color: rgba(255, 255, 255, 0.62);
  font-size: 13px;
  font-weight: 700;
}

.contact-details strong,
.contact-details a {
  font-size: 15px;
  font-weight: 650;
  line-height: 1.22;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 8px clamp(18px, 4vw, 56px) 22px;
  background: #141414;
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
}

.footer p {
  margin: 0;
}

@media (max-width: 920px) {
  .site-header {
    grid-template-columns: auto 1fr;
  }

  .nav {
    display: none;
  }

  .header-contacts {
    font-size: 13px;
    gap: 12px;
  }

  .hero {
    height: 820px;
  }

  .hero-content {
    top: var(--hero-tablet-top);
    left: 18px;
    width: min(720px, calc(100% - 36px));
    margin: 0;
    padding: 0;
  }

  .hero-stats,
  .intro,
  .about-detail-row,
  .section-head,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .hero-stats {
    left: 18px;
    right: 18px;
    grid-template-columns: 1fr;
  }

  .hero-stats div {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.22);
  }

  .hero-stats div:last-child {
    border-bottom: 0;
  }

  .service-grid {
    grid-template-columns: 1fr;
  }

  .service-card {
    grid-template-rows: auto auto;
    gap: 18px;
  }

  .footer {
    display: grid;
  }
}

@media (max-width: 560px) {
  .site-header {
    padding: 12px 14px;
    gap: 12px;
  }

  .brand span {
    display: none;
  }

  .header-contacts {
    display: grid;
    gap: 4px;
    justify-items: end;
  }

  .hero {
    height: 760px;
  }

  .hero-content {
    top: var(--hero-mobile-top);
    left: var(--hero-mobile-left);
    width: calc(100% - 28px);
    margin: 0;
    padding: 0;
  }

  .button {
    width: 100%;
  }

  .service-card {
    min-height: auto;
  }

  .service-card p,
  .intro-copy p,
  .about-detail-copy p,
  .about-detail-copy li {
    text-align: justify;
    text-wrap: pretty;
  }

  .project-controls {
    top: 16px;
    right: 16px;
    bottom: auto;
  }

  .project-controls button {
    width: 42px;
    height: 42px;
  }

  .project-card-content {
    padding-bottom: 48px;
  }

  .project-dots {
    left: 50%;
    right: auto;
    bottom: 18px;
    width: calc(100% - 48px);
    max-width: none;
    transform: translateX(-50%);
  }

  .contact-details p {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}
