*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --accent: #f08c41;
  --dark: #0d131a;
  --dark2: rgb(4, 36, 61);
  --dark3: #1e2835;
  --light: #f5f0eb;
  --muted: #b8c0cc;
  --white: #ffffff;
  --font-display: "Inter", sans-serif;
  --font-body: "Roboto", sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--dark2);
  color: var(--white);
  overflow-x: hidden;
}

/* ── NAV ── */
nav {
  position: fixed;
  border-bottom: var(--light);
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 120px;
  background: var(--dark2);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: padding 0.3s;
}
nav.scrolled {
  padding: 14px 70px;
}

.nav-logo {
  width: 145px;
}

.nav-links {
  display: flex;
  gap: 36px;
  list-style: none;
}
.nav-links a {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover {
  color: var(--accent);
}

.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
}
.burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  transition: all 0.3s;
}
.burger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.burger.open span:nth-child(2) {
  opacity: 0;
}
.burger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99;
  background: rgba(13, 19, 26, 0.97);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
}
.mobile-menu.open {
  display: flex;
}
.mobile-menu a {
  font-size: 1.3rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}
.mobile-menu a:hover {
  color: var(--accent);
}

/* ── HERO ── */
#main {
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 0 120px 80px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url("/assets/img/bg.png");
  background-size: 100%;
  background-position: center;
  /* filter: brightness(0.45); */
}
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  /* background: linear-gradient(to top, rgba(13, 19, 26, 0.9) 0%, transparent 60%); */
}

.hero-content {
  position: relative;
  max-width: 700px;
}
.hero-eyebrow {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4.1rem);
  font-weight: 600;
  line-height: 1.1;
  color: var(--white);
  margin-bottom: 24px;
}
.hero-sub {
  font-size: 1rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.75);
  max-width: 520px;
  margin-bottom: 40px;
}
.hero-sub .highlight {
  color: var(--accent);
  font-weight: 600;
}

.btn {
  display: inline-block;
  padding: 14px 32px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  transition: all 0.25s;
  cursor: pointer;
  border: none;
}
.btn-primary {
  background: var(--accent);
  color: var(--white);
}
.btn-primary:hover {
  background: #d9762e;
  transform: translateY(-1px);
}
.btn-outline {
  background: transparent;
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.3);
}
.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ── STATS BAR ── */
.stats-bar {
  background: var(--dark2);
  padding: 36px 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.stat-item {
  text-align: left;
}
.stat-num {
  font-family: var(--font-display);
  font-size: 2.8rem;
  font-weight: 600;
  color: var(--accent);
  line-height: 1;
}
.stat-label {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 6px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ── SECTIONS ── */
section {
  padding: 66px 120px;
}
.section-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  font-weight: 300;
  line-height: 1.15;
  margin-bottom: 24px;
}
.section-body {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--muted);
}

/* ── ABOUT ── */
#about {
  background: var(--dark2);
}
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 64px;
  align-items: center;
}
.about-img {
  width: 100%;
  aspect-ratio: 4/4;
  border-radius: 40px;
}

/* ── PROJECTS / GALLERY ── */
#gallereya {
  background: var(--dark2);
}
.gallery-header {
  margin-bottom: 50px;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr) 1.5fr; /* Дві малі колонки зліва, одна велика справа */
  grid-template-rows: auto auto;
  gap: 16px;
}
.gallery-grid img {
  width: 100%;
  height: 100%; /* Важливо для заповнення комірок */
  object-fit: cover;
  border-radius: 2px;
  transition:
    transform 0.4s,
    filter 0.4s;
  filter: brightness(0.85);
}
.gallery-grid img:hover {
  transform: scale(1.02);
  filter: brightness(1);
}
.gallery-grid img:first-child {
  grid-row: span 2;
  aspect-ratio: auto;
}

/* Перше фото (ліворуч зверху) */
.gallery-grid img:nth-child(1) {
  grid-column: span 2;
  grid-row: 1;
  aspect-ratio: 16 / 10;
}

/* Високе фото справа (займає 2 ряди) */
.gallery-grid img:nth-child(2) {
  grid-column: 3;
  grid-row: span 2;
}

/* Маленькі фото знизу */
.gallery-grid img:nth-child(3),
.gallery-grid img:nth-child(4) {
  grid-row: 2;
  grid-column: span 1;
  aspect-ratio: 1 / 1; /* Квадратні або 4/3 */
}

/* ── TECH DETAILS ── */
#technichnidetali {
  background: var(--dark2);
}
.tech-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
  max-width: 1200px;
}

.tech-features {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-top: 40px;
}
.feature-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 2px;
  padding: 20px;
  display: flex;
  gap: 14px;
  align-items: center;
}
.feature-icon {
  width: 47px;
  height: 47px;
  margin-bottom: 12px;
  color: var(--accent);
}
.feature-title {
  font-size: 1.13rem;
  font-weight: 500;
  color: var(--white);
  line-height: 1.4;
}
.download-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--accent);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  border-bottom: 1px solid rgba(240, 140, 65, 0.4);
  padding-bottom: 2px;
  transition:
    border-color 0.2s,
    color 0.2s;
}
.download-link:hover {
  border-color: var(--accent);
}

/* ── INFRASTRUCTURE ── */
#infrastruktura {
  background: var(--white);
}
.infra-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}
.infra-points {
  margin-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.infra-point {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.infra-point-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  margin-top: 7px;
  flex-shrink: 0;
}

#infrastruktura .section-title {
  color: var(--dark);
}
.infra-point p {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--dark);
}
.map-container {
  width: 100%;
  aspect-ratio: 4/3;
  border-radius: 2px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.map-container iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* ── FAQ ── */
#faq {
  background: var(--white);
}
.faq-wrap {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  column-gap: 80px;
}
.faq-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
#faq .section-title {
  color: var(--dark);
}
.faq-q {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 0;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 500;
  color: var(--dark);
  gap: 16px;
  user-select: none;
}
.faq-q:hover {
  color: var(--accent);
}
.faq-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--accent);
  transition: transform 0.3s;
}
.faq-item.open .faq-icon {
  transform: rotate(45deg);
}
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition:
    max-height 0.35s ease,
    padding 0.35s;
  font-size: 0.92rem;
  line-height: 1.75;
  color: var(--dark);
}
.faq-item.open .faq-a {
  max-height: 300px;
  padding-bottom: 24px;
}

/* ── VASHI PROEKTI ── */
#vashiproekti {
  background: var(--light); /* або колір фону вашого сайту */
}

#vashiproekti .section-title {
  color: var(--dark);
}

.proekti-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  margin-bottom: 60px;
}

.proekti-title-box {
  flex: 1;
}

.proekti-text-box {
  flex: 1.2;
}

.proekti-text-box .section-body {
  font-size: 16px;
  line-height: 1.6;
  color: var(--dark);
  opacity: 0.9;
}

.proekti-row {
  display: flex;
  gap: 12px;
  overflow: hidden;
}

.proekti-row img {
  width: calc(100% / 8 - 12px);
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 2px;
  filter: brightness(0.8);
  transition:
    transform 0.3s ease,
    filter 0.3s ease;
}

.proekti-row img:hover {
  transform: scale(1.05);
  filter: brightness(1);
}

/* Адаптивність */
@media (max-width: 1024px) {
  .proekti-header {
    flex-direction: column;
    gap: 20px;
  }

  .proekti-row {
    flex-wrap: wrap;
    justify-content: center;
  }

  .proekti-row img {
    width: calc(100% / 4 - 12px);
  }
}

@media (max-width: 600px) {
  .proekti-row img {
    width: calc(100% / 2 - 12px);
  }
}

/* ── CONTACT ── */
#kontakty {
  background: var(--dark2);
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}
.contact-info {
  padding-top: 16px;
}
.contact-block {
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.contact-line {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.contact-line-label {
  font-size: 0.72rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
}
.contact-line-value {
  font-size: 1.05rem;
  color: var(--white);
  font-weight: 500;
}
.contact-line-value a {
  color: var(--white);
  text-decoration: none;
  transition: color 0.2s;
}
.contact-line-value a:hover {
  color: var(--accent);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 64px;
  margin-bottom: 16px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
input,
textarea {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  padding: 14px 16px;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.9rem;
  transition: border-color 0.2s;
  outline: none;
}
input::placeholder,
textarea::placeholder {
  color: rgba(255, 255, 255, 0.3);
}
input:focus,
textarea:focus {
  border-color: var(--accent);
}
textarea {
  resize: vertical;
  min-height: 120px;
}

/* ── FOOTER ── */
footer {
  background: var(--dark2);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 32px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
footer p {
  font-size: 0.8rem;
  color: var(--muted);
}

/* ── ANIMATIONS ── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  nav {
    padding: 18px 24px;
  }
  nav.scrolled {
    padding: 12px 24px;
  }
  .nav-links {
    display: none;
  }
  .burger {
    display: flex;
  }

  #main {
    padding: 0 24px 64px;
  }
  section {
    padding: 44px 24px;
  }

  .hero-bg {
    background: var(--dark2);
  }
  .stats-bar {
    margin-top: 30px;
    padding: 0;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
  }
  .stat-num {
    font-size: 2rem;
  }
  .stat-label {
    text-transform: none;
    line-height: 150%;
    margin-top: 10px;
  }

  .about-grid,
  .tech-grid,
  .infra-grid,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-img {
    aspect-ratio: 16/9;
  }

  .gallery-grid {
    grid-template-columns: 1fr 1fr;
  }
  .gallery-grid img:nth-child(2) {
    grid-column: span 2;
    grid-row: auto;
    aspect-ratio: 16 / 9;
  }

  .tech-features {
    grid-template-columns: 1fr;
  }

  .faq-wrap {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  footer {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
}

@media (max-width: 560px) {
  .stats-bar {
    grid-template-columns: repeat(2, 1fr);
  }
  .stat-item + .stat-item {
    border-left: none;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
  }
  .gallery-grid {
    grid-template-columns: 1fr 1fr;
  }
  .gallery-grid img:first-child {
    aspect-ratio: 4/3;
  }
}
