@font-face {
  font-family: "PSS Sans";
  src: url("../assets/fonts/DejaVuSans.woff") format("woff");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "PSS Sans";
  src: url("../assets/fonts/DejaVuSans-Bold.woff") format("woff");
  font-style: normal;
  font-weight: 600 700;
  font-display: swap;
}

/* =========================================================
   1. Design tokens
   ========================================================= */

:root {
  --color-bg: #171819;
  --color-bg-deep: #0f1011;
  --color-surface: #1f2021;
  --color-surface-raised: #252627;
  --color-text: #f4f4f2;
  --color-text-muted: #a7a7a1;
  --color-text-dim: #777873;
  --color-line: rgba(255, 255, 255, 0.14);
  --color-line-strong: rgba(255, 255, 255, 0.28);
  --color-accent: #d7cbbf;
  --color-danger: #d66767;

  --font-sans: "PSS Sans", Arial, sans-serif;
  --container: 1240px;
  --section-space: 120px;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --shadow-card: 0 24px 60px rgba(0, 0, 0, 0.24);
}

/* =========================================================
   2. Reset and base typography
   ========================================================= */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
  background: var(--color-bg-deep);
}

body {
  margin: 0;
  background:
    linear-gradient(135deg, transparent 0 48%, rgba(255, 255, 255, 0.018) 48% 49%, transparent 49% 100%),
    var(--color-bg);
  background-size: 620px 620px;
  color: var(--color-text);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
}

body.modal-open {
  overflow: hidden;
}

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

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

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

h1,
h2 {
  letter-spacing: -0.04em;
}

.heading-stack span {
  display: block;
}

.heading-nowrap {
  max-width: none;
  white-space: nowrap;
  font-size: clamp(18px, 4.4vw, 64px);
}

h2 {
  margin-bottom: 0;
  font-size: clamp(38px, 4.4vw, 64px);
  font-weight: 500;
  line-height: 1.04;
}

h3 {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.25;
}

p {
  line-height: 1.65;
}

/* =========================================================
   3. Shared layout and components
   ========================================================= */

.container {
  width: min(var(--container), calc(100% - 48px));
  margin-inline: auto;
}

.section {
  padding-block: var(--section-space);
  border-top: 1px solid var(--color-line);
}

.section-title {
  display: grid;
  grid-template-columns: 56px minmax(0, 850px);
  gap: 24px;
  align-items: start;
  margin-bottom: 64px;
}

.section-index {
  padding-top: 8px;
  color: var(--color-text-dim);
  font-size: 12px;
  letter-spacing: 0.12em;
}

.section-label {
  margin-bottom: 18px;
  color: var(--color-accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.section-intro {
  max-width: 760px;
  margin: 24px 0 0;
  color: var(--color-text-muted);
  font-size: 17px;
}

.panel {
  padding: 30px;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  background: rgba(31, 32, 33, 0.86);
  box-shadow: var(--shadow-card);
}

.panel h3 {
  margin-bottom: 20px;
}

.panel p {
  margin-bottom: 16px;
  color: var(--color-text-muted);
}

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

.panel--large {
  padding: 40px;
}

.panel__result {
  padding-top: 20px;
  border-top: 1px solid var(--color-line);
  color: var(--color-text) !important;
  font-weight: 600;
}

.clean-list {
  display: grid;
  gap: 12px;
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}

.clean-list li {
  position: relative;
  padding-left: 22px;
  color: var(--color-text-muted);
  line-height: 1.5;
}

.clean-list li::before {
  content: "";
  position: absolute;
  top: 0.64em;
  left: 0;
  width: 7px;
  height: 7px;
  border: 1px solid var(--color-accent);
  transform: rotate(45deg);
}

.two-column {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.button {
  min-height: 50px;
  padding: 0 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border: 1px solid var(--color-line-strong);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 700;
  transition: transform 160ms ease, background 160ms ease, color 160ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button--light {
  border-color: #ffffff;
  background: #ffffff;
  color: #151617;
}

.button--ghost {
  background: rgba(0, 0, 0, 0.18);
  color: #ffffff;
  backdrop-filter: blur(12px);
}

.brand-logo {
  display: block;
  width: 220px;
}

.brand-logo img {
  width: 100%;
  height: auto;
}

.brand-logo--header {
  width: 150px;
}

.brand-logo--hero {
  width: min(992px, 100%);
  margin-inline: auto;
  animation: hero-item-in 900ms 100ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.brand-logo--footer {
  width: 200px;
}

/* =========================================================
   4. Header and navigation
   ========================================================= */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: 74px;
  padding-inline: max(24px, calc((100vw - var(--container)) / 2));
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(16, 17, 18, 0.76);
  backdrop-filter: blur(18px);
  animation: site-header-in 720ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.site-nav {
  display: flex;
  gap: 28px;
}

.site-nav a {
  color: var(--color-text-muted);
  font-size: 13px;
}

.site-nav a:hover {
  color: #ffffff;
}

.header-contact {
  justify-self: end;
  display: inline-flex;
  gap: 10px;
  align-items: center;
  font-size: 13px;
  font-weight: 700;
}

/* =========================================================
   5. Hero
   ========================================================= */

.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: center;
  overflow: hidden;
  background: #111213;
}

.hero__background,
.feature-hero > img,
.case-hero > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__background {
  opacity: 0.62;
  animation: hero-background-in 1200ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(10, 11, 12, 0.9), rgba(10, 11, 12, 0.35) 70%),
    linear-gradient(0deg, rgba(10, 11, 12, 0.82), transparent 50%);
}

.hero__content {
  position: relative;
  z-index: 2;
  padding-top: 110px;
}

.hero__kicker {
  max-width: 600px;
  margin: 34px 0 16px;
  color: #d6d6d1;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 860px;
  margin-bottom: 0;
  font-size: clamp(36px, 4.7vw, 70px);
  font-weight: 500;
  line-height: 1.06;
}

.hero .hero__title {
  max-width: 760px;
  margin: 36px auto 0;
  color: var(--color-accent);
  font-size: clamp(28px, 4vw, 52px);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-align: center;
  text-transform: uppercase;
  white-space: nowrap;
  animation: hero-item-in 900ms 220ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero__actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 44px;
  animation: hero-item-in 900ms 340ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero__stats {
  display: grid;
  grid-template-columns: 160px 220px minmax(260px, 1fr);
  max-width: 850px;
  margin: 80px auto 0;
  border-block: 1px solid rgba(255, 255, 255, 0.2);
  animation: hero-item-in 900ms 460ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero__stats > div {
  min-height: 105px;
  padding: 22px 24px 22px 0;
  border-right: 1px solid rgba(255, 255, 255, 0.2);
}

.hero__stats > div:not(:first-child) {
  padding-left: 24px;
}

.hero__stats > div:last-child {
  border-right: 0;
}

.hero__stats strong,
.hero__stats span {
  display: block;
}

.hero__stats strong {
  font-size: 24px;
  font-weight: 600;
}

.hero__stats span {
  margin-top: 7px;
  color: #b6b6b0;
  font-size: 12px;
}

/* =========================================================
   6. About and cooperation
   ========================================================= */

.section--about {
  border-top: 0;
}

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

.cooperation {
  margin-top: 18px;
  padding: 24px 30px;
  display: grid;
  grid-template-columns: 1.2fr repeat(3, 1fr);
  gap: 22px;
  align-items: center;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
}

.cooperation span {
  color: var(--color-text-muted);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.cooperation p {
  margin: 0;
  font-size: 14px;
  line-height: 1.4;
}

/* =========================================================
   7. Portfolio and project history
   ========================================================= */

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

.project-card {
  outline: none;
  overflow: hidden;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  box-shadow: var(--shadow-card);
  cursor: zoom-in;
  transition: border-color 180ms ease, transform 180ms ease;
}

.project-card:hover,
.project-card:focus-visible {
  border-color: var(--color-line-strong);
  transform: translateY(-3px);
}

.project-card:focus-visible {
  box-shadow: 0 0 0 3px rgba(215, 203, 191, 0.28), var(--shadow-card);
}

.project-card > img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  filter: saturate(0.62) contrast(1.08);
  transition: filter 180ms ease, transform 180ms ease;
}

.project-card:hover > img {
  filter: saturate(1) contrast(1.02);
  transform: scale(1.015);
}

.project-card__body {
  padding: 24px;
}

.project-card__body h3 {
  margin-bottom: 12px;
  font-size: 18px;
}

.project-card__body p {
  min-height: 48px;
  margin-bottom: 18px;
  color: var(--color-text-muted);
  font-size: 14px;
}

.project-card__body span {
  color: var(--color-text-dim);
  font-size: 12px;
}

.project-card[hidden] {
  display: none;
}

.portfolio-actions {
  display: flex;
  justify-content: center;
  margin-top: 36px;
}

.button--outline {
  min-width: 190px;
  background: transparent;
  color: var(--color-text);
  cursor: pointer;
}

.button--outline:hover {
  background: var(--color-text);
  color: var(--color-bg-deep);
}

.project-modal {
  width: min(1120px, calc(100% - 40px));
  max-height: calc(100svh - 40px);
  padding: 0;
  overflow: hidden auto;
  border: 1px solid var(--color-line-strong);
  border-radius: var(--radius-lg);
  background: var(--color-bg-deep);
  color: var(--color-text);
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.72);
}

.project-modal::backdrop {
  background: rgba(5, 6, 7, 0.88);
  backdrop-filter: blur(8px);
}

.project-modal[open] {
  animation: project-modal-in 280ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.project-modal[open]::backdrop {
  animation: project-backdrop-in 220ms ease-out both;
}


.project-modal__content {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.project-modal__content > img {
  width: 100%;
  max-height: 72svh;
  object-fit: contain;
  background: #0b0c0d;
}

.project-modal__copy {
  padding: 28px 32px 32px;
  border-top: 1px solid var(--color-line);
}

.project-modal__copy h2 {
  max-width: 900px;
  font-size: clamp(26px, 3.2vw, 44px);
}

.project-modal__copy p {
  margin: 16px 0 10px;
  color: var(--color-text-muted);
}

.project-modal__copy span {
  color: var(--color-accent);
  font-size: 13px;
}

.project-modal__close {
  position: fixed;
  z-index: 2;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background: rgba(10, 11, 12, 0.78);
  color: #ffffff;
  font: inherit;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.section--history {
  background: var(--color-bg-deep);
}

.history-heading {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  margin-bottom: 54px;
  border-block: 1px solid var(--color-line);
}

.history-heading > div {
  min-height: 150px;
  padding: 34px;
  border-right: 1px solid var(--color-line);
}

.history-heading > div:last-child {
  border-right: 0;
}

.history-heading strong,
.history-heading span {
  display: block;
}

.history-heading strong {
  font-size: clamp(50px, 7vw, 92px);
  font-weight: 500;
  line-height: 0.95;
}

.history-heading span {
  margin-top: 12px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 12px;
}

.project-table {
  border-top: 1px solid var(--color-line-strong);
}

.project-table__header,
.project-table__row {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(180px, 0.8fr) minmax(150px, 0.65fr);
  gap: 24px;
  align-items: center;
}

.project-table__header {
  padding: 14px 0;
  color: var(--color-text-dim);
  font-size: 11px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.project-table__row {
  padding: 19px 0;
  border-top: 1px solid var(--color-line);
}

.project-table__row strong {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45;
}

.project-table__row span {
  color: var(--color-text-muted);
  font-size: 13px;
  line-height: 1.4;
}

/* =========================================================
   8. Automation and virtual commissioning
   ========================================================= */

.feature-hero,
.case-hero {
  position: relative;
  min-height: 620px;
  display: grid;
  align-items: end;
  overflow: hidden;
  border-top: 1px solid var(--color-line);
}

.feature-hero > img,
.case-hero > img {
  filter: saturate(0.72);
}

.feature-hero__overlay,
.case-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(12, 13, 14, 0.96), rgba(12, 13, 14, 0.06) 72%);
}

.feature-hero__content,
.case-hero__content {
  position: relative;
  z-index: 2;
  padding-bottom: 70px;
}

.feature-hero h2,
.case-hero h2 {
  max-width: 850px;
}

.benefit-list,
.process-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.benefit-list li {
  padding: 20px 0;
  display: grid;
  gap: 7px;
  border-top: 1px solid var(--color-line);
}

.benefit-list strong {
  font-size: 16px;
}

.benefit-list span {
  color: var(--color-text-muted);
  font-size: 14px;
  line-height: 1.55;
}

.process-list li {
  padding: 20px 0;
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 16px;
  align-items: start;
  border-top: 1px solid var(--color-line);
}

.process-list span {
  color: var(--color-text-dim);
  font-size: 12px;
}

.process-list p {
  margin: 0;
  color: var(--color-text-muted);
  font-size: 14px;
}

.section--commissioning {
  background: var(--color-bg-deep);
}

.commissioning-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 64px;
  align-items: center;
}

.commissioning-image {
  overflow: hidden;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

.commissioning-image img {
  width: 100%;
  min-height: 680px;
  object-fit: cover;
}

.commissioning-grid h2 {
  margin-bottom: 42px;
}

.commissioning-copy {
  display: grid;
  gap: 24px;
}

.commissioning-copy > div {
  padding-top: 22px;
  border-top: 1px solid var(--color-line);
}

.commissioning-copy h3 {
  margin-bottom: 10px;
}

.commissioning-copy p {
  margin: 0;
  color: var(--color-text-muted);
}

.result-line {
  margin: 34px 0 0;
  padding: 20px 24px;
  border: 1px solid var(--color-line-strong);
  border-radius: var(--radius-sm);
}

/* =========================================================
   9. Pumping-station case
   ========================================================= */

.case-hero > img {
  opacity: 0.74;
}

.case-hero__overlay {
  background:
    linear-gradient(90deg, rgba(10, 11, 12, 0.82), rgba(10, 11, 12, 0.04)),
    linear-gradient(0deg, rgba(10, 11, 12, 0.94), transparent 72%);
}

.case-hero__content > p:last-child {
  margin: 20px 0 0;
  color: var(--color-text-muted);
  font-size: 18px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 36px;
  border-block: 1px solid var(--color-line-strong);
}

.metric-grid > div {
  min-height: 170px;
  padding: 30px;
  border-right: 1px solid var(--color-line);
}

.metric-grid > div:last-child {
  border-right: 0;
}

.metric-grid strong,
.metric-grid span {
  display: block;
}

.metric-grid strong {
  font-size: clamp(44px, 6vw, 76px);
  font-weight: 500;
  line-height: 1;
}

.metric-grid span {
  margin-top: 16px;
  color: var(--color-text-muted);
  font-size: 13px;
}

.hmi-frame {
  padding: 16px;
  overflow: hidden;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  background: var(--color-bg-deep);
}

.hmi-frame img {
  width: 100%;
  border-radius: var(--radius-sm);
}

.section--development {
  background: var(--color-bg-deep);
}

.development-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.big-percent {
  margin-bottom: 8px !important;
  color: var(--color-text) !important;
  font-size: clamp(56px, 8vw, 96px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.06em;
}

.data-list {
  margin: 30px 0;
}

.data-list > div {
  padding: 15px 0;
  display: flex;
  justify-content: space-between;
  gap: 30px;
  border-top: 1px solid var(--color-line);
}

.data-list dt {
  color: var(--color-text-muted);
}

.data-list dd {
  margin: 0;
  text-align: right;
}

.startup-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.startup-steps article {
  min-height: 240px;
  padding: 30px;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
}

.startup-steps span {
  display: block;
  margin-bottom: 70px;
  color: var(--color-text-dim);
  font-size: 13px;
}

.startup-steps p {
  margin: 0;
  font-size: 17px;
}

.startup-note {
  margin: 20px 0 0;
  padding: 24px 30px;
  border: 1px solid var(--color-line-strong);
  border-radius: var(--radius-sm);
  color: var(--color-text-muted);
}

.section--verification {
  background: var(--color-bg-deep);
}

.panel--error {
  border-color: rgba(214, 103, 103, 0.34);
}

.panel--error span {
  display: inline-block;
  margin-top: 16px;
  padding: 7px 10px;
  border: 1px solid rgba(214, 103, 103, 0.34);
  border-radius: 999px;
  color: #e0a0a0;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.conclusion-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

/* =========================================================
   10. Clients, contacts and footer
   ========================================================= */

.section--clients {
  background: var(--color-bg-deep);
}

.clients-board {
  max-width: 1040px;
  margin-inline: auto;
  padding: 26px;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  background: #1d1e1f;
}

.clients-board img {
  width: 100%;
  border-radius: var(--radius-sm);
}

.contacts {
  padding-block: 140px;
  border-top: 1px solid var(--color-line);
  background: #101112;
}

.contacts__grid {
  display: grid;
  grid-template-columns: 1fr 0.85fr;
  gap: 90px;
  align-items: end;
}

.contacts h2 {
  margin-bottom: 24px;
}

.contacts__grid > div:first-child > p:last-child {
  max-width: 620px;
  color: var(--color-text-muted);
}

.contacts__actions {
  border-top: 1px solid var(--color-line-strong);
}

.contacts__actions a {
  padding: 22px 0;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--color-line);
  font-size: 18px;
}

.site-footer {
  padding-block: 50px;
  border-top: 1px solid var(--color-line);
  background: #101112;
}

.site-footer__inner {
  display: grid;
  grid-template-columns: 1fr 1.3fr 1fr;
  gap: 40px;
  align-items: center;
}

.site-footer p,
.site-footer span {
  margin: 0;
  color: var(--color-text-dim);
  font-size: 11px;
  line-height: 1.5;
}

.site-footer__inner > div {
  display: grid;
  justify-items: end;
  gap: 6px;
}

/* =========================================================
   11. Motion
   ========================================================= */

@keyframes site-header-in {
  from {
    opacity: 0;
    transform: translateY(-14px);
    filter: blur(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

@keyframes hero-background-in {
  from {
    opacity: 0;
    transform: scale(1.035);
  }

  to {
    opacity: 0.62;
    transform: scale(1);
  }
}

@keyframes hero-item-in {
  from {
    opacity: 0;
    transform: translateY(20px);
    filter: blur(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}


@keyframes project-modal-in {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.965);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes project-backdrop-in {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-header,
  .hero__background,
  .brand-logo--hero,
  .hero__title,
  .hero__actions,
  .hero__stats,
  .project-modal[open],
  .project-modal[open]::backdrop {
    animation: none;
  }
}

/* =========================================================
   12. Responsive layout
   ========================================================= */

@media (max-width: 980px) {
  :root {
    --section-space: 96px;
  }

  .site-header {
    grid-template-columns: 1fr auto;
  }

  .site-nav {
    display: none;
  }

  .about-grid,
  .portfolio-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cooperation {
    grid-template-columns: repeat(2, 1fr);
  }

  .commissioning-grid,
  .contacts__grid {
    grid-template-columns: 1fr;
  }

  .commissioning-image img {
    min-height: 460px;
  }

  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .metric-grid > div:nth-child(2) {
    border-right: 0;
  }

  .metric-grid > div:nth-child(-n + 2) {
    border-bottom: 1px solid var(--color-line);
  }

  .project-table {
    overflow-x: auto;
  }

  .project-table__header,
  .project-table__row {
    min-width: 900px;
  }
}

@media (max-width: 680px) {
  :root {
    --section-space: 76px;
  }

  .container {
    width: min(var(--container), calc(100% - 32px));
  }

  h2 {
    font-size: 38px;
  }

  .site-header {
    height: 66px;
    padding-inline: 16px;
  }

  .brand-logo--header {
    width: 125px;
  }

  .header-contact {
    font-size: 12px;
  }

  .hero {
    min-height: 900px;
  }

  .hero__content {
    padding-top: 92px;
  }

  .hero h1 {
    font-size: 38px;
  }

  .hero .hero__title {
    margin-top: 29px;
    font-size: clamp(18px, 5.2vw, 30px);
    letter-spacing: 0.04em;
  }

  .hero__actions {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .hero__stats {
    grid-template-columns: 1fr;
    margin-top: 52px;
  }

  .hero__stats > div,
  .hero__stats > div:not(:first-child) {
    min-height: auto;
    padding: 18px 0;
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  }

  .hero__stats > div:last-child {
    border-bottom: 0;
  }

  .section-title {
    grid-template-columns: 1fr;
    gap: 14px;
    margin-bottom: 42px;
  }

  .section-index {
    padding-top: 0;
  }

  .about-grid,
  .portfolio-grid,
  .two-column,
  .cooperation,
  .development-grid,
  .startup-steps,
  .conclusion-grid {
    grid-template-columns: 1fr;
  }

  .panel,
  .panel--large {
    padding: 24px;
  }

  .project-card__body p {
    min-height: 0;
  }

  .project-modal {
    width: calc(100% - 20px);
    max-height: calc(100svh - 20px);
    border-radius: var(--radius-md);
  }

  .project-modal__copy {
    padding: 22px 20px 26px;
  }

  .project-modal__close {
    top: 10px;
    right: 10px;
    margin: 0;
  }

  .history-heading {
    grid-template-columns: 1fr;
  }

  .history-heading > div {
    min-height: 125px;
    padding-inline: 0;
    border-right: 0;
    border-bottom: 1px solid var(--color-line);
  }

  .history-heading > div:last-child {
    border-bottom: 0;
  }

  .feature-hero,
  .case-hero {
    min-height: 500px;
  }

  .feature-hero__content,
  .case-hero__content {
    padding-bottom: 44px;
  }

  .commissioning-grid {
    gap: 40px;
  }

  .commissioning-image img {
    min-height: 360px;
  }

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

  .metric-grid > div {
    min-height: 130px;
    padding-inline: 0;
    border-right: 0;
    border-bottom: 1px solid var(--color-line);
  }

  .metric-grid > div:last-child {
    border-bottom: 0;
  }

  .startup-steps article {
    min-height: 190px;
  }

  .startup-steps span {
    margin-bottom: 45px;
  }

  .contacts {
    padding-block: 90px;
  }

  .contacts__grid {
    gap: 48px;
  }

  .contacts__actions a {
    font-size: 15px;
  }

  .site-footer__inner {
    grid-template-columns: 1fr;
  }

  .site-footer__inner > div {
    justify-items: start;
  }
}
