:root {
  --green: #006b3f;
  --green-dark: #003a27;
  --green-deep: #061b13;
  --green-glow: rgba(0, 107, 63, 0.28);
  --lime: #8cc63f;
  --lime-glow: rgba(140, 198, 63, 0.28);
  --ink: #13201a;
  --muted: #5c6d63;
  --line: rgba(255, 255, 255, 0.22);
  --white: #ffffff;
  --soft: rgba(255, 255, 255, 0.66);
  --glass: rgba(255, 255, 255, 0.18);
  --glass-strong: rgba(255, 255, 255, 0.76);
  --shadow: 0 18px 54px rgba(0, 42, 27, 0.14);
  --radius-lg: 34px;
  --radius-md: 24px;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font-family: "Inter", Arial, sans-serif;
  color: var(--ink);
  line-height: 1.6;
  background:
    radial-gradient(
      circle at 12% 8%,
      rgba(140, 198, 63, 0.18),
      transparent 30%
    ),
    radial-gradient(circle at 80% 4%, rgba(0, 107, 63, 0.13), transparent 30%),
    linear-gradient(135deg, #f7fbf8 0%, #edf5ef 42%, #ffffff 100%);
  overflow-x: hidden;
}
body.menu-open {
  overflow: hidden;
}
img {
  max-width: 100%;
  display: block;
}
a {
  color: inherit;
  text-decoration: none;
}
button,
input,
textarea {
  font: inherit;
}
.container {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
}

.cursor-glow {
  position: fixed;
  width: 320px;
  height: 320px;
  left: 0;
  top: 0;
  pointer-events: none;
  transform: translate(-50%, -50%);
  background: radial-gradient(
    circle,
    rgba(140, 198, 63, 0.18),
    transparent 68%
  );
  z-index: 0;
  opacity: 0.75;
  transition: opacity 0.3s ease;
}
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  width: 0%;
  z-index: 100;
  background: linear-gradient(90deg, var(--lime), var(--green));
  box-shadow: 0 0 20px rgba(140, 198, 63, 0.65);
}
.section-with-bg {
  position: relative;
}
.section-with-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(0, 107, 63, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 107, 63, 0.04) 1px, transparent 1px);
  background-size: 70px 70px;
  mask-image: linear-gradient(
    to bottom,
    transparent,
    #000 20%,
    #000 80%,
    transparent
  );
}

.glass-card {
  background: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.66),
    rgba(255, 255, 255, 0.22)
  );
  border: 1px solid rgba(255, 255, 255, 0.48);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 80;
  background: rgba(255, 255, 255, 0.34);
  border-bottom: 1px solid rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition:
    background 0.3s ease,
    box-shadow 0.3s ease,
    transform 0.3s ease;
}
.site-header.scrolled {
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 18px 60px rgba(0, 42, 27, 0.1);
}
.navbar {
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  letter-spacing: 0.06em;
  color: var(--green);
}
.brand-logo-wrap {
  width: 62px;
  height: 62px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.48);
  box-shadow: 0 12px 36px rgba(0, 80, 48, 0.12);
}
.brand img {
  width: 78px;
  height: auto;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.14));
}
.brand-text {
  font-size: 1.02rem;
}
.nav-menu {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  font-size: 0.94rem;
}
.nav-menu a {
  position: relative;
  padding: 10px 14px;
  border-radius: 999px;
  color: rgba(19, 32, 26, 0.86);
  transition:
    color 0.2s ease,
    background 0.2s ease,
    transform 0.2s ease;
}
.nav-menu a:hover,
.nav-menu a.active {
  color: var(--green);
  background: rgba(0, 107, 63, 0.08);
  transform: translateY(-1px);
}
.nav-toggle {
  display: none;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 14px;
  background: var(--green);
  color: #fff;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
}
.nav-toggle span {
  width: 20px;
  height: 2px;
  border-radius: 4px;
  background: #fff;
  transition:
    transform 0.25s ease,
    opacity 0.25s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.hero {
  min-height: 820px;
  padding: 160px 0 90px;
  overflow: hidden;
  color: var(--white);
  background:
    linear-gradient(
      115deg,
      rgba(4, 29, 20, 0.97),
      rgba(0, 78, 50, 0.82) 52%,
      rgba(0, 107, 63, 0.58)
    ),
    url("assets/engineering-team.jpg") center/cover no-repeat;
}
.hero::after {
  content: "";
  position: absolute;
  inset: auto -10% -30% -10%;
  height: 360px;
  background: radial-gradient(
    ellipse at center,
    rgba(255, 255, 255, 0.24),
    transparent 62%
  );
  transform: rotate(-4deg);
}
.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.grid-lines {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.055) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: linear-gradient(90deg, #000, transparent 70%);
}
.orb {
  position: absolute;
  border-radius: 999px;
  filter: blur(2px);
  animation: floatOrb 9s var(--ease) infinite alternate;
}
.orb-one {
  width: 320px;
  height: 320px;
  left: -110px;
  top: 130px;
  background: rgba(140, 198, 63, 0.24);
}
.orb-two {
  width: 470px;
  height: 470px;
  right: -180px;
  top: 70px;
  background: rgba(255, 255, 255, 0.1);
  animation-delay: -3s;
}
.orb-three {
  width: 210px;
  height: 210px;
  left: 48%;
  bottom: 80px;
  background: rgba(140, 198, 63, 0.18);
  animation-delay: -5s;
}
@keyframes floatOrb {
  from {
    transform: translate3d(0, 0, 0) scale(1);
  }
  to {
    transform: translate3d(28px, -32px, 0) scale(1.08);
  }
}
.hero-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 64px;
  align-items: center;
}
.eyebrow {
  margin: 0 0 14px;
  color: var(--lime);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.hero h1 {
  margin: 0;
  max-width: 790px;
  font-size: clamp(3.05rem, 6.7vw, 6.8rem);
  line-height: 0.92;
  letter-spacing: -0.075em;
}
.tagline {
  min-height: 2.75rem;
  margin: 30px 0 0;
  font-size: clamp(1.28rem, 2.4vw, 2.15rem);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.03em;
}
.tagline span::after {
  content: "";
  display: inline-block;
  width: 3px;
  height: 1em;
  margin-left: 6px;
  transform: translateY(3px);
  background: var(--lime);
  animation: blink 0.7s steps(2, start) infinite;
}
@keyframes blink {
  50% {
    opacity: 0;
  }
}
.hero-text {
  max-width: 620px;
  margin: 22px 0 0;
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.84);
}
.hero-actions {
  display: flex;
  gap: 16px;
  margin-top: 38px;
  flex-wrap: wrap;
}
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 0 26px;
  border-radius: 999px;
  border: 0;
  font-weight: 900;
  cursor: pointer;
  overflow: hidden;
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease,
    background 0.22s ease;
}
.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.42),
    transparent
  );
  transition: transform 0.55s ease;
}
.btn:hover::before {
  transform: translateX(100%);
}
.btn:hover {
  transform: translateY(-3px);
}
.btn-primary {
  color: #10210f;
  background: var(--lime);
  box-shadow: 0 20px 54px rgba(140, 198, 63, 0.28);
}
.btn-secondary {
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.28);
}
.hero-visual {
  position: relative;
  min-height: 548px;
}
.hero-card {
  position: relative;
  border-radius: 40px;
  padding: 16px;
  transform-style: preserve-3d;
}
.hero-card img {
  height: 510px;
  width: 100%;
  object-fit: cover;
  border-radius: 30px;
}
.floating-badge {
  position: absolute;
  left: 34px;
  bottom: 34px;
  padding: 12px 16px;
  border-radius: 999px;
  font-weight: 900;
  color: #10301f;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.62);
  backdrop-filter: blur(8px);
}
.mini-card {
  position: absolute;
  right: -22px;
  top: 70px;
  max-width: 230px;
  padding: 18px 20px;
  border-radius: 22px;
  color: #10301f;
  animation: floatCard 4.6s ease-in-out infinite;
}
.mini-card strong {
  display: block;
  font-size: 1rem;
}
.mini-card span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.92rem;
}
@keyframes floatCard {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-14px);
  }
}

.section {
  padding: 96px 0;
}
.intro-strip {
  margin-top: -1px;
  padding: 36px 0 28px;
  background: rgba(255, 255, 255, 0.32);
}
.strip-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.stat-card {
  min-height: 148px;
  border-radius: var(--radius-md);
  padding: 26px;
}
.stat-card strong {
  display: block;
  color: var(--green);
  font-size: 2.75rem;
  line-height: 1;
  letter-spacing: -0.05em;
}
.stat-card strong::after {
  content: "%";
  font-size: 1.2rem;
  margin-left: 2px;
  color: var(--lime);
}
.stat-card:nth-child(2) strong::after {
  content: "/7";
}
.stat-card:nth-child(3) strong::after {
  content: "+";
}
.stat-card span {
  display: block;
  color: var(--muted);
  font-weight: 700;
  margin-top: 10px;
}

.two-column {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 74px;
  align-items: center;
}
.two-column.reverse {
  grid-template-columns: 0.9fr 1fr;
}
.section-copy h2,
.section-heading h2,
.project-copy h2,
.portfolio h2,
.contact h2 {
  margin: 0 0 24px;
  font-size: clamp(2.05rem, 4vw, 3.9rem);
  line-height: 1.03;
  letter-spacing: -0.058em;
}
.section-copy p,
.project-copy p,
.portfolio p,
.contact p {
  color: var(--muted);
  font-size: 1.06rem;
}
.section-copy p + p {
  margin-top: 16px;
}
.image-stack {
  position: relative;
}
.image-frame {
  border-radius: var(--radius-lg);
  padding: 14px;
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  overflow: hidden;
}
.image-frame.large img {
  width: 100%;
  height: 510px;
  object-fit: cover;
  border-radius: 25px;
  transform: scale(1.01);
}
.image-frame.dark {
  background: linear-gradient(
    145deg,
    rgba(0, 58, 39, 0.92),
    rgba(0, 107, 63, 0.42)
  );
}
.overlap-card {
  position: absolute;
  left: -28px;
  bottom: 34px;
  width: min(300px, 88%);
  padding: 20px;
  border-radius: 22px;
  color: #10301f;
  font-weight: 800;
}

.services {
  background: rgba(255, 255, 255, 0.32);
}
.section-heading {
  position: relative;
  z-index: 1;
  max-width: 790px;
  margin-bottom: 40px;
}
.cards {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.service-card {
  position: relative;
  min-height: 276px;
  padding: 32px 28px;
  border-radius: 30px;
  overflow: hidden;
  transform-style: preserve-3d;
  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}
.service-card::after {
  content: "";
  position: absolute;
  width: 156px;
  height: 156px;
  right: -62px;
  bottom: -62px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(140, 198, 63, 0.38),
    transparent 68%
  );
  transition: transform 0.3s ease;
}
.service-card:hover {
  transform: translateY(-7px);
  border-color: rgba(140, 198, 63, 0.52);
  box-shadow: 0 24px 64px rgba(0, 64, 42, 0.14);
}
.service-card:hover::after {
  transform: scale(1.28);
}
.card-number {
  color: var(--lime);
  font-weight: 900;
  letter-spacing: 0.12em;
}
.service-card h3 {
  margin: 20px 0 12px;
  font-size: 1.32rem;
  line-height: 1.2;
  letter-spacing: -0.025em;
}
.service-card p {
  margin: 0;
  color: var(--muted);
}

.projects {
  overflow: hidden;
  color: #fff;
  background: linear-gradient(135deg, #061b13, #004d31 58%, #006b3f);
}
.projects.section-with-bg::before {
  opacity: 0.5;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
}
.project-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 0.88fr 1fr;
  gap: 64px;
  align-items: center;
}
.project-copy p {
  color: rgba(255, 255, 255, 0.78);
}
.text-link {
  display: inline-flex;
  margin-top: 20px;
  color: var(--lime);
  font-weight: 900;
}
.project-showcase {
  position: relative;
  min-height: 580px;
  display: grid;
  place-items: center;
}
.showcase-card {
  position: relative;
  z-index: 2;
  width: min(440px, 100%);
  border-radius: 38px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.26);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(10px);
  transform: rotate(2deg);
}
.showcase-card img {
  height: 560px;
  width: 100%;
  object-fit: cover;
  object-position: center;
  border-radius: 28px;
}
.showcase-ring {
  position: absolute;
  width: 520px;
  height: 520px;
  border-radius: 999px;
  border: 1px solid rgba(140, 198, 63, 0.32);
  box-shadow:
    inset 0 0 60px rgba(140, 198, 63, 0.1),
    0 0 100px rgba(140, 198, 63, 0.12);
  animation: slowSpin 18s linear infinite;
}
.showcase-ring::before,
.showcase-ring::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: var(--lime);
  box-shadow: 0 0 28px rgba(140, 198, 63, 0.7);
}
.showcase-ring::before {
  left: 70px;
  top: 56px;
}
.showcase-ring::after {
  right: 88px;
  bottom: 42px;
}
@keyframes slowSpin {
  to {
    transform: rotate(360deg);
  }
}

.portfolio {
  overflow: hidden;
  background:
    radial-gradient(circle at 8% 0%, rgba(140, 198, 63, 0.2), transparent 28%),
    radial-gradient(circle at 92% 12%, rgba(0, 107, 63, 0.12), transparent 30%),
    rgba(255, 255, 255, 0.38);
}
.portfolio-header {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 0.55fr);
  gap: 44px;
  align-items: end;
  margin-bottom: 40px;
}
.section-heading.compact {
  margin-bottom: 0;
}
.portfolio-intro {
  margin: 0 0 8px;
  padding: 22px 24px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.48);
  border: 1px solid rgba(255, 255, 255, 0.52);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 18px 60px rgba(0, 42, 27, 0.08);
}
.portfolio-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.portfolio-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100%;
  border-radius: 30px;
  overflow: hidden;
  transform-style: preserve-3d;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}
.portfolio-card:hover {
  transform: translateY(-8px);
  border-color: rgba(140, 198, 63, 0.56);
  box-shadow: 0 24px 64px rgba(0, 64, 42, 0.16);
}
.portfolio-image {
  position: relative;
  height: 246px;
  overflow: hidden;
  isolation: isolate;
}
.portfolio-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 32%, rgba(0, 47, 30, 0.34));
  z-index: 1;
}
.portfolio-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition:
    transform 0.55s var(--ease),
    filter 0.55s var(--ease);
}
.portfolio-card:hover .portfolio-image img {
  transform: scale(1.08);
  filter: saturate(1.06) contrast(1.04);
}
.portfolio-content {
  flex: 1;
  padding: 26px 24px 28px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.72),
    rgba(255, 255, 255, 0.4)
  );
}
.portfolio-tag {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  color: var(--green-dark);
  background: rgba(140, 198, 63, 0.2);
  border: 1px solid rgba(140, 198, 63, 0.35);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.portfolio-card h3 {
  margin: 18px 0 12px;
  font-size: 1.26rem;
  line-height: 1.18;
  letter-spacing: -0.03em;
  color: var(--ink);
}
.portfolio-card p {
  margin: 0;
  font-size: 0.98rem;
  color: var(--muted);
}
.portfolio-wide {
  grid-column: span 3;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
}
.portfolio-wide .portfolio-image {
  height: auto;
  min-height: 330px;
}
.portfolio-wide .portfolio-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 36px;
}
.portfolio-wide h3 {
  font-size: clamp(1.7rem, 3vw, 2.45rem);
}

.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}
.pill-list span {
  padding: 11px 15px;
  border-radius: 999px;
  background: rgba(0, 107, 63, 0.08);
  color: var(--green-dark);
  border: 1px solid rgba(0, 107, 63, 0.12);
  font-weight: 800;
}

.contact {
  background: rgba(255, 255, 255, 0.34);
}
.contact-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 0.95fr 1fr;
  gap: 58px;
  align-items: start;
}
.contact-list {
  display: grid;
  gap: 12px;
  margin-top: 30px;
}
.contact-list a,
.contact-list span {
  padding: 16px 18px;
  border-radius: 18px;
  color: var(--ink);
  font-weight: 800;
  transition:
    transform 0.2s ease,
    border-color 0.2s ease;
}
.contact-list a:hover {
  transform: translateX(6px);
  border-color: rgba(0, 107, 63, 0.35);
  color: var(--green);
}
.contact-form {
  padding: 32px;
  border-radius: 30px;
  display: grid;
  gap: 18px;
}
.contact-form label {
  display: grid;
  gap: 8px;
  font-weight: 900;
  color: var(--green-dark);
}
input,
textarea {
  width: 100%;
  border: 1px solid rgba(0, 107, 63, 0.14);
  border-radius: 16px;
  padding: 15px 16px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.62);
  outline: none;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}
input:focus,
textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 5px rgba(0, 107, 63, 0.1);
  background: rgba(255, 255, 255, 0.86);
}
textarea {
  resize: vertical;
}

.footer {
  padding: 34px 0;
  background: #06130f;
  color: rgba(255, 255, 255, 0.74);
}
.footer::before {
  opacity: 0.25;
}
.footer-grid {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.footer img {
  height: 32px;
  width: 72px;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.25));
}
.footer p {
  margin: 0;
}
.back-to-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.46);
  background: rgba(0, 107, 63, 0.84);
  color: #fff;
  z-index: 75;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  box-shadow: 0 18px 44px rgba(0, 56, 34, 0.25);
  transition:
    opacity 0.25s ease,
    transform 0.25s ease;
}
.back-to-top.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.reveal {
  opacity: 0;
  transform: translateY(34px);
  transition:
    opacity 0.8s var(--ease),
    transform 0.8s var(--ease);
  transition-delay: var(--delay, 0ms);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.tilt-card {
  will-change: transform;
  transition: transform 0.16s ease;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
  .cursor-glow {
    display: none;
  }
}

@media (max-width: 980px) {
  .nav-toggle {
    display: inline-flex;
  }
  .nav-menu {
    position: fixed;
    top: 94px;
    left: 20px;
    right: 20px;
    display: grid;
    gap: 6px;
    padding: 14px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.55);
    box-shadow: var(--shadow);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transform: translateY(-20px);
    opacity: 0;
    pointer-events: none;
    transition:
      opacity 0.25s ease,
      transform 0.25s ease;
  }
  .nav-menu.open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }
  .nav-menu a {
    padding: 14px 16px;
  }
  .hero {
    min-height: auto;
    padding: 130px 0 76px;
  }
  .hero-grid,
  .two-column,
  .two-column.reverse,
  .project-grid,
  .portfolio-header,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 44px;
  }
  .hero-visual {
    min-height: auto;
  }
  .hero-card img,
  .image-frame.large img {
    height: 390px;
  }
  .project-showcase {
    min-height: 520px;
  }
  .showcase-card img {
    height: 500px;
  }
  .strip-grid,
  .cards,
  .portfolio-grid {
    grid-template-columns: 1fr;
  }
  .portfolio-wide {
    grid-column: auto;
    grid-template-columns: 1fr;
  }
  .portfolio-wide .portfolio-image {
    height: 246px;
    min-height: 0;
  }
  .section {
    padding: 70px 0;
  }
  .mini-card {
    right: 14px;
    top: 32px;
  }
}

@media (max-width: 600px) {
  .container {
    width: min(100% - 28px, 1160px);
  }
  .navbar {
    min-height: 74px;
  }
  .brand-logo-wrap {
    width: 54px;
    height: 54px;
  }
  .brand img {
    width: 68px;
  }
  .brand-text {
    display: none;
  }
  .nav-menu {
    top: 82px;
    left: 14px;
    right: 14px;
  }
  .hero h1 {
    font-size: 2.78rem;
  }
  .tagline {
    font-size: 1.13rem;
    min-height: 2.1rem;
  }
  .hero-text {
    font-size: 1rem;
  }
  .hero-actions {
    flex-direction: column;
  }
  .btn {
    width: 100%;
  }
  .hero-card,
  .image-frame,
  .showcase-card {
    border-radius: 26px;
    padding: 10px;
  }
  .hero-card img,
  .image-frame.large img {
    height: 320px;
    border-radius: 20px;
  }
  .floating-badge {
    left: 20px;
    bottom: 20px;
    font-size: 0.82rem;
  }
  .mini-card {
    position: static;
    margin-top: 14px;
    max-width: 100%;
  }
  .overlap-card {
    position: static;
    margin-top: 14px;
    width: 100%;
  }
  .section-copy h2,
  .section-heading h2,
  .project-copy h2,
  .portfolio h2,
  .contact h2 {
    font-size: 2.1rem;
  }
  .service-card {
    min-height: auto;
  }
  .project-showcase {
    min-height: auto;
  }
  .showcase-card {
    width: 100%;
    transform: none;
  }
  .showcase-card img {
    height: 430px;
  }
  .showcase-ring {
    display: none;
  }
  .contact-form {
    padding: 22px;
  }
  .footer-grid {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 720px) {
  .portfolio-header {
    gap: 22px;
    margin-bottom: 28px;
  }
  .portfolio-intro {
    padding: 18px;
  }
  .portfolio-image {
    height: 220px;
  }
  .portfolio-content {
    padding: 22px 20px 24px;
  }
}

/* Full-width content sections: hero stays unchanged */
main > section:not(.hero) > .container {
  width: 100%;
  max-width: none;
  padding-left: clamp(20px, 4vw, 70px);
  padding-right: clamp(20px, 4vw, 70px);
}

/* Keep the hero exactly in its original centred layout */
.hero > .container {
  width: min(1160px, calc(100% - 40px));
  max-width: 1160px;
  padding-left: 0;
  padding-right: 0;
}

/* Let full-width card layouts breathe properly on large screens */
main > section:not(.hero) .cards,
main > section:not(.hero) .portfolio-grid,
main > section:not(.hero) .strip-grid {
  width: 100%;
}

@media (min-width: 1280px) {
  main > section:not(.hero) .cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  main > section:not(.hero) .portfolio-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 1500px) {
  main > section:not(.hero) > .container {
    padding-left: clamp(70px, 5vw, 110px);
    padding-right: clamp(70px, 5vw, 110px);
  }
}

@media (max-width: 600px) {
  main > section:not(.hero) > .container {
    width: 100%;
    padding-left: 16px;
    padding-right: 16px;
  }

  .hero > .container {
    width: min(100% - 28px, 1160px);
    padding-left: 0;
    padding-right: 0;
  }
}

/* Performance additions */
.portfolio-card,
.service-card,
.stat-card,
.image-frame,
.showcase-card {
  content-visibility: auto;
  contain-intrinsic-size: 420px;
}

@media (max-width: 980px) {
  .cursor-glow {
    display: none;
  }
}

.form-trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}
