﻿:root {
  --forgegrid-cta-bg: #ffffff;
  --forgegrid-cta-text: #17320b;
  --forgegrid-cta-border: rgba(15, 14, 13, 0.12);
}

html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

nav {
  gap: 1rem;
}

.nav-links {
  margin-left: auto;
}

.nav-cta-secondary {
  background: var(--forgegrid-cta-bg);
  color: var(--forgegrid-cta-text);
  border: 1px solid var(--forgegrid-cta-border);
}

.nav-cta-secondary:hover {
  background: var(--accent-light);
}

img,
.service-card-img,
.project-card-img {
  max-width: 100%;
}

@media (max-width: 900px) {
  nav {
    padding: 0.85rem 1rem;
    height: auto;
    flex-wrap: wrap;
    align-items: center;
  }

  .nav-logo {
    flex: 1 1 auto;
    min-width: 180px;
  }

  .nav-links {
    order: 3;
    width: 100%;
    gap: 0.85rem 1rem;
    flex-wrap: wrap;
    margin-left: 0;
  }

  .nav-cta,
  .nav-cta-secondary {
    padding-inline: 1rem;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .hero {
    min-height: auto;
    padding: 5rem 1rem 3rem;
  }

  .hero-overlay {
    background: linear-gradient(
      to bottom,
      rgba(245,243,238,0.92) 0%,
      rgba(245,243,238,0.72) 44%,
      rgba(245,243,238,0.28) 100%
    );
  }

  .hero-title {
    max-width: 640px;
    font-size: clamp(2.7rem, 11vw, 4.7rem);
  }

  .hero-sub {
    max-width: 32rem;
    margin-bottom: 2rem;
  }

  .hero-actions {
    flex-wrap: wrap;
  }

  .hero-actions a {
    min-height: 44px;
  }

  .hero-stat-row {
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
    text-align: left;
    gap: 1rem;
    margin-top: 2rem;
  }

  section {
    padding: 5rem 1rem;
  }

  .services-grid,
  .projects-grid,
  .about-inner,
  .contact-inner {
    grid-template-columns: 1fr;
  }

  .service-card,
  .project-card,
  .value-item {
    border-right: none;
  }

  .service-card {
    border-bottom: 1px solid var(--border);
  }

  .service-card:last-child {
    border-bottom: none;
  }

  .about-inner,
  .contact-inner {
    gap: 2.5rem;
  }

  .about-values,
  .form-row {
    grid-template-columns: 1fr;
  }

  footer {
    padding: 1.5rem 1rem;
    flex-wrap: wrap;
    gap: 0.75rem;
  }
}

@media (max-width: 700px) {
  .nav-links a {
    font-size: 0.8rem;
  }

  .nav-cta,
  .nav-cta-secondary {
    font-size: 0.74rem;
  }

  .hero-title {
    font-size: clamp(2.4rem, 12vw, 3.5rem);
    line-height: 0.98;
    margin-bottom: 1.6rem;
  }

  .hero-sub {
    font-size: 0.95rem;
    line-height: 1.65;
  }

  .btn-primary,
  .btn-ghost,
  .submit-btn {
    width: 100%;
    justify-content: center;
  }

  .project-card,
  .service-card,
  .about-visual,
  .contact-form {
    min-width: 0;
  }
}

@media (max-width: 480px) {
  nav {
    padding-inline: 0.8rem;
  }

  .nav-logo {
    font-size: 0.95rem;
  }

  .nav-links {
    gap: 0.65rem 0.9rem;
  }

  .hero {
    padding: 4.5rem 0.8rem 2.6rem;
  }

  section {
    padding: 4rem 0.8rem;
  }

  .hero-stat-num {
    font-size: 1.4rem;
  }

  .section-title {
    margin-bottom: 2.5rem;
  }
}
