*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --black:   #0e0e0e;
  --white:   #f5f3ef;
  --mid:     #1c1c1c;
  --subtle:  #2e2e2e;
  --accent:  #c8a96e;   /* warm gold: professional, warm, distinctive */
  --muted:   #888880;
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body:    'DM Sans', sans-serif;
}

html { scroll-behavior: smooth; }

body {
  background: var(--black);
  color: var(--white);
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.6;
  overflow-x: hidden;
}

/* ── NOISE OVERLAY ── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  opacity: 0.035;
  pointer-events: none;
  z-index: 999;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(14, 14, 14, 0.8);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  transition: padding 0.3s ease;
}

@media (min-width: 640px) {
  nav { padding: 1.25rem 3rem; }
}

.nav-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--white);
  text-decoration: none;
}

.nav-links {
  display: none;
  gap: 2rem;
}

.nav-links a {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
  font-weight: 500;
}

.nav-links a:hover { color: var(--accent); }

@media (min-width: 850px) {
  .nav-links { display: flex; }
}

.nav-cta {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  text-decoration: none;
  border: 1px solid var(--accent);
  padding: 0.45rem 1rem;
  transition: background 0.2s, color 0.2s;
}

.nav-cta:hover {
  background: var(--accent);
  color: var(--black);
}

/* ── HERO ── */
.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 5rem 2rem 3rem; /* Tightened for mobile focus */
  position: relative;
  overflow: hidden;
}

.hero-socials-top {
  display: flex;
  gap: 1.25rem;
  margin-bottom: 2rem;
  opacity: 0;
  animation: fadeUp 0.7s ease forwards 0.1s;
}

.hero-socials-top a {
  color: var(--muted);
  transition: color 0.2s, transform 0.2s;
}

.hero-socials-top a:hover {
  color: var(--accent);
  transform: translateY(-2px);
}

.hero-socials-top svg {
  width: 18px;
  height: 18px;
}

@media (max-width: 480px) {
  .hero {
    padding-top: 4rem; /* Even tighter for QR scans */
  }
  .hero-headline {
    font-size: clamp(2.8rem, 15vw, 4rem); /* Ensure buttons are visible on small screens */
  }
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -80px; right: -80px;
  width: 420px; height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(200,169,110,0.12) 0%, transparent 70%);
  pointer-events: none;
}

.hero-eyebrow {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeUp 0.7s ease forwards 0.2s;
}

.hero-headline {
  font-family: var(--font-display);
  font-size: clamp(3rem, 12vw, 6.5rem);
  font-weight: 700;
  line-height: 1.0;
  letter-spacing: -0.01em;
  color: var(--white);
  margin-bottom: 0.5rem;
  opacity: 0;
  animation: fadeUp 0.7s ease forwards 0.35s;
}

.hero-headline em {
  font-style: italic;
  color: var(--accent);
}

.hero-sub {
  font-size: clamp(0.9rem, 3.5vw, 1.1rem); /* Slightly larger for readability */
  color: #ccc; /* Higher contrast than var(--muted) for quick reading */
  max-width: 420px; /* Allow more text per line for better flow */
  margin-bottom: 2.5rem;
  margin-top: 1rem;
  opacity: 0;
  animation: fadeUp 0.7s ease forwards 0.5s;
}

.hero-buttons {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeUp 0.7s ease forwards 0.65s;
}

.btn-primary {
  background: var(--accent);
  color: var(--black);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.85rem 1.75rem;
  text-decoration: none;
  transition: opacity 0.2s, transform 0.2s;
  display: inline-block;
}

.btn-primary:hover { opacity: 0.85; transform: translateY(-1px); }

.btn-secondary {
  background: transparent;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.85rem 1.75rem;
  text-decoration: none;
  border: 1px solid var(--subtle);
  transition: border-color 0.2s, transform 0.2s;
  display: inline-block;
}

.btn-secondary:hover { border-color: var(--muted); transform: translateY(-1px); }

.hero-trust {
  margin-top: 2.5rem;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0;
  animation: fadeUp 0.7s ease forwards 0.8s;
}

.hero-trust span { color: var(--accent); margin-right: 0.4rem; }

/* ── DIVIDER ── */
.divider {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--subtle), transparent);
  margin: 0 2rem;
}

/* ── SECTION SHARED ── */
section { padding: 4rem 1.5rem; } /* Tightened for mobile momentum */

@media (min-width: 640px) {
  section { padding: 6rem 3rem; }
}

.section-label {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 7vw, 3.2rem);
  font-weight: 600;
  line-height: 1.1;
  color: var(--white);
  margin-bottom: 1rem;
}

/* ── SERVICES ── */
.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  margin-top: 2.5rem;
  border: 1px solid var(--subtle);
}

.service-card {
  padding: 1.75rem;
  background: var(--mid);
  transition: background 0.25s;
  position: relative;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 3px; height: 0;
  background: var(--accent);
  transition: height 0.3s ease;
}

.service-card:hover::before { height: 100%; }
.service-card:hover { background: #212121; }

.service-number {
  font-family: var(--font-display);
  font-size: 0.8rem;
  color: var(--accent);
  letter-spacing: 0.1em;
  margin-bottom: 0.6rem;
}

.service-name {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 0.4rem;
}

.service-desc {
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.55;
}

/* ── WORK ── */
.work-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-top: 2.5rem;
}

@media (min-width: 768px) {
  .work-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1200px) {
  .work-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.work-card {
  background: var(--mid);
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  transition: transform 0.3s ease, background 0.3s ease;
  height: 100%;
}

.work-card:hover {
  transform: translateY(-5px);
  background: #212121;
}

.work-thumb {
  width: 100%;
  aspect-ratio: 16/10;
  background: var(--subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.work-thumb-inner {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  padding: 2rem;
}

.work-thumb-inner img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* placeholder gradients for mock projects */
.thumb-1 { background: linear-gradient(135deg, #1a1a1a 0%, #0a0a0a 100%); }
.thumb-2 { background: linear-gradient(135deg, #1e2420 0%, #0d0f0e 100%); }
.thumb-3 { background: linear-gradient(135deg, #050505 0%, #1a1a2e 100%); }
.thumb-4 { background: linear-gradient(135deg, #fdfcf9 0%, #EFEAD8 100%); }
.thumb-5 { background: linear-gradient(135deg, #F9F7F2 0%, #E5E1D8 100%); } /* Solstice */
.thumb-6 { background: linear-gradient(135deg, #F4F7FA 0%, #D1D9E6 100%); } /* Vela */
.thumb-7 { background: linear-gradient(135deg, #1a1a1a 0%, #333 100%); background-image: url('https://images.unsplash.com/photo-1486406146926-c627a92ad1ab?q=80&w=1000'); background-size: cover; background-position: center; } /* Forma */
.thumb-8 { background: linear-gradient(135deg, #0F2B5B 0%, #051635 100%); } /* NexusAI */

.work-info {
  padding: 1.25rem;
  flex-grow: 1;
}

.work-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 0.25rem;
}

.work-type {
  font-size: 0.78rem;
  color: var(--muted);
}

/* ── MID-PAGE CTA ── */
.mid-cta {
  background: var(--mid);
  text-align: center;
  padding: 4rem 2rem;
}

.mid-cta-content {
  max-width: 500px;
  margin: 0 auto;
}

.mid-cta-title {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--white);
}

.mid-cta-sub {
  font-size: 1rem;
  color: var(--muted);
  margin-bottom: 2rem;
}

/* ── WHY ── */
.why-list {
  margin-top: 2rem;
  display: grid;
  gap: 1.5rem;
}

.why-item {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
}

/* ── PROCESS ── */
.process-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  margin-top: 3rem;
}

.process-step {
  position: relative;
}

.process-number {
  font-family: var(--font-display);
  font-size: 3rem;
  line-height: 1;
  color: var(--accent);
  opacity: 0.15;
  position: absolute;
  top: -0.5rem;
  left: -0.5rem;
  z-index: 0;
}

.process-content {
  position: relative;
  z-index: 1;
}

.process-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 0.5rem;
}

.process-desc {
  font-size: 0.9rem;
  color: var(--muted);
  max-width: 400px;
}

.why-icon {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border: 1px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.1rem;
}

.why-icon svg {
  width: 12px; height: 12px;
  stroke: var(--accent);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
}

.why-text strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--white);
  margin-bottom: 0.15rem;
}

.why-text span {
  font-size: 0.8rem;
  color: var(--muted);
}

/* ── ABOUT (Bold Two-Column) ── */
.about-section {
  background: var(--mid);
  border-top: 1px solid rgba(200, 169, 110, 0.15);
  border-bottom: 1px solid rgba(200, 169, 110, 0.15);
  padding: 5rem 2rem;
  position: relative;
  overflow: hidden;
}

.about-section::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(to bottom, transparent, var(--accent), transparent);
}

.about-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

@media (min-width: 900px) {
  .about-inner {
    grid-template-columns: 1fr 1.2fr;
    gap: 5rem;
    align-items: center;
  }
  .about-section { padding: 7rem 5rem; }
}

.about-left {
  position: relative;
}

.about-headline {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 700;
  line-height: 0.95;
  color: var(--white);
  letter-spacing: -0.02em;
}

.about-headline em {
  font-style: italic;
  color: var(--accent);
}

.about-right {
  border-left: none;
}

@media (min-width: 900px) {
  .about-right {
    border-left: 1px solid var(--subtle);
    padding-left: 4rem;
  }
}

.about-blurb {
  font-size: 1.05rem;
  color: #ccc;
  max-width: 500px;
  margin-bottom: 2.5rem;
  line-height: 1.65;
}

/* ── CONTACT ── */
.contact-section {
  background: var(--mid);
  text-align: center;
}

.contact-section .section-title {
  margin-bottom: 0.5rem;
}

.contact-sub {
  font-size: 0.88rem;
  color: var(--muted);
  margin-bottom: 2rem;
  max-width: 300px;
  margin-left: auto;
  margin-right: auto;
}

.contact-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  align-items: center;
}

.contact-buttons .btn-primary,
.contact-buttons .btn-secondary {
  width: 100%;
  max-width: 280px;
  text-align: center;
}

.contact-email {
  margin-top: 1.5rem;
  font-size: 0.78rem;
  color: var(--muted);
  letter-spacing: 0.05em;
}

.contact-email a {
  color: var(--accent);
  text-decoration: none;
}

/* ── ENGINEERING ── */
.engineering-section {
  padding-top: 0;
}

.engineering-card {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr;
  background: var(--mid);
  overflow: hidden;
}

@media (min-width: 900px) {
  .engineering-card {
    grid-template-columns: 1.2fr 0.8fr;
  }
}

.eng-slideshow {
  position: relative;
  height: 350px;
  overflow: hidden;
}

@media (min-width: 900px) {
  .eng-slideshow {
    height: 500px;
  }
}

.eng-slide {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}

.eng-slide.active {
  opacity: 1;
}

.eng-content {
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.eng-label {
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}

.eng-title {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--white);
}

.eng-desc {
  font-size: 0.95rem;
  color: var(--muted);
  line-height: 1.6;
}

/* ── FOOTER ── */
footer {
  padding: 2rem;
  text-align: center;
  border-top: 1px solid var(--subtle);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.footer-links a {
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--accent); }

.footer-copy {
  font-size: 0.7rem;
  color: #555;
  letter-spacing: 0.08em;
}

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* ── DESKTOP UPGRADES ── */
@media (min-width: 640px) {
  nav { padding: 1.5rem 3rem; }
  section { padding: 6rem 3rem; }
  .divider { margin: 0 3rem; }

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

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

  .process-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }

  .contact-buttons {
    flex-direction: row;
    justify-content: center;
  }

  .contact-buttons .btn-primary,
  .contact-buttons .btn-secondary {
    width: auto;
  }

  .hero { padding: 7rem 3rem 5rem; }
}

@media (min-width: 1024px) {
  nav { padding: 1.5rem 5rem; }
  section { padding: 7rem 5rem; }
  .divider { margin: 0 5rem; }
  .hero { padding: 8rem 5rem 6rem; }
  .hero-headline { max-width: 700px; }
  .services-grid { grid-template-columns: repeat(4, 1fr); }
  .work-grid { grid-template-columns: repeat(2, 1fr); }
}
