/* ===== RESET & BASE ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --c-bg: #ffffff;
  --c-surface: #f7f7f5;
  --c-dark: #111110;
  --c-dark-2: #1a1a18;
  --c-accent: #2d6a4f;
  --c-accent-light: #40916c;
  --c-accent-pale: #d8f3dc;
  --c-muted: #6b6b68;
  --c-border: #e4e4e0;
  --c-white: #ffffff;

  --ff-sans: "DM Sans", system-ui, -apple-system, sans-serif;
  --ff-display: "Teko", var(--ff-sans);

  --fs-xs: 0.75rem;
  --fs-sm: 0.875rem;
  --fs-base: 1rem;
  --fs-md: 1.125rem;
  --fs-lg: 1.375rem;
  --fs-xl: 1.75rem;
  --fs-2xl: 2.25rem;
  --fs-3xl: 3rem;
  --fs-4xl: 3.75rem;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 20px;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.07), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow: 0 4px 16px rgba(0, 0, 0, 0.08), 0 1px 4px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.12), 0 4px 12px rgba(0, 0, 0, 0.06);

  --topbar-h: 64px;
  --max-w: 1200px;
  --max-w-text: 720px;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--ff-sans);
  font-size: var(--fs-base);
  line-height: 1.6;
  color: var(--c-dark);
  background: var(--c-bg);
  overflow-x: hidden;
}

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

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

/* ===== AMBIENT TEXTURE ===== */
.ambient-noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.018;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

/* ===== SCROLL PROGRESS ===== */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: var(--c-accent);
  z-index: 9999;
  transition: width 0.1s linear;
}

/* ===== TYPOGRAPHY ===== */
h1,
h2,
h3,
h4 {
  font-family: var(--ff-display);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(var(--fs-3xl), 6vw, var(--fs-4xl));
}

h2 {
  font-size: clamp(var(--fs-xl), 3.5vw, var(--fs-3xl));
}

h3 {
  font-size: clamp(var(--fs-lg), 2.5vw, var(--fs-xl));
}

.eyebrow {
  font-family: var(--ff-sans);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-accent);
  margin-bottom: var(--space-2);
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-sm);
  font-family: var(--ff-sans);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition:
    background 0.18s,
    color 0.18s,
    border-color 0.18s,
    box-shadow 0.18s,
    transform 0.12s;
  white-space: nowrap;
  text-decoration: none;
}

.btn:active {
  transform: translateY(1px);
}

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

.btn-primary:hover {
  background: var(--c-accent-light);
  border-color: var(--c-accent-light);
  box-shadow: 0 4px 14px rgba(45, 106, 79, 0.3);
}

.btn-ghost {
  background: transparent;
  color: var(--c-white);
  border-color: rgba(255, 255, 255, 0.4);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.7);
}

.btn-dark {
  background: var(--c-dark);
  color: var(--c-white);
  border-color: var(--c-dark);
}

.btn-dark:hover {
  background: var(--c-dark-2);
}

.btn-ghost-dark {
  background: transparent;
  color: var(--c-dark);
  border-color: var(--c-border);
}

.btn-ghost-dark:hover {
  background: var(--c-surface);
}

/* ===== TOPBAR ===== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  gap: var(--space-6);
  height: var(--topbar-h);
  padding: 0 var(--space-8);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--c-border);
  transition: box-shadow 0.2s;
}

.topbar.scrolled {
  box-shadow: var(--shadow);
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
  flex-shrink: 0;
}

.brand-logo {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.brand-text {
  font-family: var(--ff-display);
  font-size: var(--fs-lg);
  font-weight: 600;
  color: var(--c-dark);
  letter-spacing: -0.01em;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: var(--space-6);
  margin-left: auto;
}

.main-nav a {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--c-muted);
  transition: color 0.15s;
}

.main-nav a:hover {
  color: var(--c-dark);
}

.call-pill {
  display: flex;
  align-items: center;
  padding: var(--space-2) var(--space-5);
  background: var(--c-accent);
  color: var(--c-white);
  border-radius: 999px;
  font-size: var(--fs-sm);
  font-weight: 600;
  white-space: nowrap;
  transition:
    background 0.15s,
    box-shadow 0.15s;
}

.call-pill:hover {
  background: var(--c-accent-light);
  box-shadow: 0 4px 14px rgba(45, 106, 79, 0.3);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  border: none;
  background: none;
  cursor: pointer;
  margin-left: auto;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--c-dark);
  border-radius: 2px;
  transition:
    transform 0.22s,
    opacity 0.22s;
  transform-origin: center;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: calc(90vh - var(--topbar-h));
  display: grid;
  grid-template-columns: 1fr 380px;
  align-items: end;
  gap: var(--space-8);
  padding: var(--space-20) var(--space-8) var(--space-16);
  max-width: var(--max-w);
  margin: 0 auto;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.2) 100%);
  z-index: -1;
}

.hero-content {
  color: var(--c-white);
  max-width: 640px;
}

.hero-content .eyebrow {
  color: var(--c-accent-pale);
}

.hero-content h1 {
  margin-top: var(--space-3);
  margin-bottom: var(--space-5);
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.4);
}

.hero-copy {
  font-size: var(--fs-md);
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: var(--space-8);
  max-width: 520px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-bottom: var(--space-8);
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
}

.hero-meta span {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

.hero-meta span::before {
  content: "✓ ";
  color: var(--c-accent-pale);
}

.hero-panel {
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  align-self: center;
  box-shadow: var(--shadow-lg);
}

.hero-panel h2 {
  font-size: var(--fs-xl);
  margin-bottom: var(--space-3);
}

.hero-panel p {
  font-size: var(--fs-sm);
  color: var(--c-muted);
  margin-bottom: var(--space-5);
}

.hero-panel ul {
  list-style: none;
  margin-bottom: var(--space-6);
}

.hero-panel ul li {
  font-size: var(--fs-sm);
  color: var(--c-dark);
  padding: var(--space-2) 0;
  border-bottom: 1px solid var(--c-border);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.hero-panel ul li::before {
  content: "→";
  color: var(--c-accent);
  flex-shrink: 0;
}

/* ===== TRUST STRIP ===== */
.trust-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: var(--c-dark);
}

.metric {
  padding: var(--space-10) var(--space-8);
  text-align: center;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.metric:last-child {
  border-right: none;
}

.metric h2 {
  font-family: var(--ff-display);
  font-size: var(--fs-4xl);
  color: var(--c-white);
  margin-bottom: var(--space-1);
}

.metric p {
  font-size: var(--fs-sm);
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 500;
}

/* ===== SECTIONS ===== */
.section {
  padding: var(--space-24) var(--space-8);
  max-width: var(--max-w);
  margin: 0 auto;
}

.section-dark {
  background: var(--c-surface);
  max-width: 100%;
  padding: var(--space-24) var(--space-8);
}

.section-dark > * {
  max-width: var(--max-w);
  margin-left: auto;
  margin-right: auto;
}

.section-accent {
  background: var(--c-accent-pale);
  max-width: 100%;
  padding: var(--space-24) var(--space-8);
}

.section-accent > * {
  max-width: var(--max-w);
  margin-left: auto;
  margin-right: auto;
}

.section-heading {
  margin-bottom: var(--space-12);
  max-width: var(--max-w-text);
}

.section-heading p {
  margin-top: var(--space-4);
  color: var(--c-muted);
  font-size: var(--fs-md);
}

/* ===== SERVICES GRID ===== */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-5);
}

.service-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: var(--space-8);
  transition:
    transform 0.18s,
    box-shadow 0.18s;
}

.service-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.service-card h3 {
  font-size: var(--fs-lg);
  margin-bottom: var(--space-3);
}

.service-card p {
  font-size: var(--fs-sm);
  color: var(--c-muted);
  line-height: 1.65;
}

/* ===== PROJECTS GRID ===== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--space-6);
  max-width: var(--max-w);
  margin: 0 auto;
}

.project-card {
  background: var(--c-bg);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition:
    transform 0.2s,
    box-shadow 0.2s;
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.project-card > img {
  width: 100%;
  height: 240px;
  object-fit: cover;
}

.project-content {
  padding: var(--space-6);
}

.project-content h3 {
  font-size: var(--fs-lg);
  margin-bottom: var(--space-1);
}

.project-date {
  font-size: var(--fs-xs);
  color: var(--c-accent);
  font-weight: 600;
  margin-bottom: var(--space-3);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.project-content p:not(.project-date) {
  font-size: var(--fs-sm);
  color: var(--c-muted);
  line-height: 1.65;
  margin-bottom: var(--space-5);
}

.project-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: var(--space-2);
}

.project-thumbs img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

/* ===== CTA STRIP ===== */
.cta-strip {
  background: var(--c-dark);
  color: var(--c-white);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-8);
  padding: var(--space-16) var(--space-8);
  flex-wrap: wrap;
}

.cta-strip .eyebrow {
  color: var(--c-accent-pale);
}

.cta-strip h2 {
  margin-top: var(--space-2);
  margin-bottom: var(--space-3);
}

.cta-strip p {
  font-size: var(--fs-md);
  color: rgba(255, 255, 255, 0.7);
  max-width: 520px;
}

/* ===== REVIEWS ===== */
.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-5);
}

.review-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: var(--space-7);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.review-card p {
  font-size: var(--fs-sm);
  color: var(--c-dark);
  line-height: 1.7;
  flex: 1;
}

.review-card cite {
  font-style: normal;
  font-size: var(--fs-xs);
  font-weight: 700;
  color: var(--c-accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ===== ENQUIRY ===== */
.enquiry-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: var(--space-12);
  max-width: var(--max-w);
  margin: 0 auto;
}

.enquiry-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.enquiry-form label {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--c-dark);
}

.enquiry-form input,
.enquiry-form select,
.enquiry-form textarea {
  font-family: var(--ff-sans);
  font-size: var(--fs-base);
  color: var(--c-dark);
  background: var(--c-white);
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-sm);
  padding: var(--space-3) var(--space-4);
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
  width: 100%;
}

.enquiry-form input:focus,
.enquiry-form select:focus,
.enquiry-form textarea:focus {
  outline: none;
  border-color: var(--c-accent);
  box-shadow: 0 0 0 3px rgba(45, 106, 79, 0.12);
}

.enquiry-form textarea {
  resize: vertical;
}

.form-status {
  font-size: var(--fs-sm);
  color: var(--c-accent);
  min-height: 1.4em;
}

.contact-card {
  background: var(--c-dark);
  color: var(--c-white);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  height: fit-content;
  position: sticky;
  top: calc(var(--topbar-h) + var(--space-4));
}

.contact-card h3 {
  font-size: var(--fs-lg);
  line-height: 1.2;
}

.contact-card p {
  font-size: var(--fs-sm);
  color: rgba(255, 255, 255, 0.6);
}

.contact-card a {
  color: var(--c-accent-pale);
  font-size: var(--fs-sm);
  font-weight: 500;
  transition: color 0.15s;
}

.contact-card a:hover {
  color: var(--c-white);
}

.enquiry-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-top: var(--space-2);
}

/* ===== FOOTER ===== */
.footer {
  background: var(--c-dark-2);
  color: rgba(255, 255, 255, 0.4);
  text-align: center;
  padding: var(--space-10) var(--space-8);
  font-size: var(--fs-xs);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

/* ===== REVEAL ANIMATION ===== */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.55s ease,
    transform 0.55s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Hero should be visible immediately */
.hero.reveal {
  opacity: 1;
  transform: none;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1120px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding: var(--space-16) var(--space-6) var(--space-12);
  }

  .hero-panel {
    max-width: 480px;
  }

  .enquiry-layout {
    grid-template-columns: 1fr;
  }

  .contact-card {
    position: static;
  }
}

@media (max-width: 840px) {
  .nav-toggle {
    display: flex;
  }

  .main-nav {
    position: fixed;
    top: var(--topbar-h);
    left: 0;
    right: 0;
    background: var(--c-white);
    flex-direction: column;
    align-items: stretch;
    padding: var(--space-4) var(--space-6) var(--space-6);
    border-bottom: 1px solid var(--c-border);
    box-shadow: var(--shadow);
    transform: translateY(-110%);
    transition: transform 0.25s;
    z-index: 199;
    gap: 0;
    margin-left: 0;
  }

  .main-nav.open {
    transform: translateY(0);
  }

  .main-nav a {
    padding: var(--space-4) 0;
    border-bottom: 1px solid var(--c-border);
    font-size: var(--fs-base);
    color: var(--c-dark);
  }

  .main-nav a:last-child {
    border-bottom: none;
  }

  .call-pill {
    display: none;
  }

  .cta-strip {
    flex-direction: column;
    align-items: flex-start;
  }

  .trust-strip {
    grid-template-columns: 1fr;
  }

  .metric {
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .metric:last-child {
    border-bottom: none;
  }
}

@media (max-width: 560px) {
  :root {
    --topbar-h: 56px;
  }

  .topbar {
    padding: 0 var(--space-5);
    gap: var(--space-4);
  }

  .hero {
    padding: var(--space-12) var(--space-5) var(--space-10);
  }

  .section {
    padding: var(--space-16) var(--space-5);
  }

  .section-dark,
  .section-accent,
  .cta-strip {
    padding: var(--space-16) var(--space-5);
  }

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

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
