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

:root {
  --bg: #faf9f7;
  --text: #2b2b28;
  --text-mid: #807d76;
  --text-light: #a09d96;
  --text-faint: #c5c2bb;
  --border: #e6e4df;
  --surface: #fff;
  --accent: #b5502e;
  --accent-hover: #954023;
  --on-accent: #fff;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: 'Playfair Display', Georgia, serif;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

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

/* ── NAV ── */

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 48px;
  border-bottom: 0.5px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg);
  z-index: 100;
}

.nav-logo {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 500;
  color: var(--text);
}

.nav-links {
  display: flex;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  font-size: 13px;
  color: var(--text-light);
  transition: color 0.2s;
  position: relative;
  padding-bottom: 4px;
}

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

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

.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1.5px;
  background: var(--accent);
}

.nav-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-hamburger span {
  display: block;
  width: 24px;
  height: 1.5px;
  background: var(--text);
  margin: 5px 0;
  transition: transform 0.3s, opacity 0.3s;
}

/* ── HERO ── */

.hero {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  min-height: 480px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
}

.hero-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-right: 48px;
}

.hero-text h1 {
  font-family: var(--font-heading);
  font-size: 48px;
  font-weight: 500;
  line-height: 1.15;
  margin-bottom: 16px;
  color: var(--text);
}

.hero-text p {
  font-size: 16px;
  color: var(--text-mid);
  line-height: 1.7;
  margin-bottom: 28px;
  max-width: 380px;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--on-accent);
  font-weight: 500;
  background: var(--accent);
  border-radius: 6px;
  padding: 12px 22px;
  width: fit-content;
  transition: background 0.2s;
}

.hero-cta:hover {
  background: var(--accent-hover);
}

.hero-cta svg {
  width: 16px;
  height: 16px;
}

.hero-image {
  overflow: hidden;
  border-radius: 0 0 0 24px;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ── STATS ── */

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  max-width: 1200px;
  margin: 0 auto;
}

.stat {
  background: var(--bg);
  padding: 28px 48px;
  text-align: center;
}

.stat-number {
  font-size: 36px;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 2px;
}

.stat-label {
  font-size: 11px;
  color: var(--text-light);
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* ── SECTIONS ── */

.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 64px 48px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 32px;
}

.section-header h2 {
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 500;
}

.section-header a {
  font-size: 13px;
  color: var(--text-mid);
  transition: color 0.2s;
}

.section-header a:hover {
  color: var(--text);
}

/* ── PROJECT ROWS ── */

.project-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
  cursor: pointer;
  transition: opacity 0.2s;
}

.project-row:hover {
  opacity: 0.85;
}

.project-row.reverse {
  grid-template-columns: 1fr 1.4fr;
}

.project-row.reverse .project-image {
  order: 2;
}

.project-row.reverse .project-info {
  order: 1;
}

.project-image {
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 3/2;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}

.project-row:hover .project-image img {
  transform: scale(1.03);
}

.project-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 8px 0;
}

.project-info h3 {
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 6px;
  color: var(--text);
}

.project-info p {
  font-size: 14px;
  color: var(--text-mid);
  line-height: 1.6;
}

.project-tag {
  font-size: 11px;
  color: var(--text-light);
  margin-top: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

/* ── PORTFOLIO PAGE ── */

.portfolio-nav {
  display: flex;
  gap: 12px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.portfolio-nav a {
  font-size: 13px;
  padding: 8px 18px;
  border-radius: 24px;
  border: 0.5px solid var(--border);
  color: var(--text-mid);
  transition: all 0.2s;
}

.portfolio-nav a:hover {
  border-color: var(--text-light);
  color: var(--text);
}

.portfolio-nav a.active {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

/* ── CAROUSEL ── */

.carousel {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 16/10;
  margin-bottom: 8px;
  cursor: pointer;
}

.carousel-track {
  width: 100%;
  height: 100%;
}

.carousel-track img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}

.carousel-track img.active {
  display: block;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border: 0.5px solid rgba(43, 43, 40, 0.2);
  background: rgba(250, 249, 247, 0.92);
  color: var(--text);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  z-index: 2;
  transition: all 0.2s;
  backdrop-filter: blur(8px);
}

.carousel-btn:hover {
  background: var(--bg);
  border-color: rgba(43, 43, 40, 0.4);
}

.carousel-btn.prev {
  left: 16px;
}

.carousel-btn.next {
  right: 16px;
}

.carousel-counter {
  text-align: center;
  font-size: 13px;
  color: var(--text-light);
  margin-top: 12px;
  letter-spacing: 1px;
}

.carousel-thumbs {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}

.carousel-thumbs button {
  width: 72px;
  height: 48px;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  opacity: 0.4;
  transition: opacity 0.2s;
  border: 2px solid transparent;
  padding: 0;
  background: none;
}

.carousel-thumbs button.active {
  opacity: 1;
  border-color: var(--text);
}

.carousel-thumbs button:hover {
  opacity: 0.7;
}

.carousel-thumbs button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-detail {
  margin-top: 32px;
}

.project-detail h2 {
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 500;
  margin-bottom: 10px;
}

.project-detail p {
  font-size: 15px;
  color: var(--text-mid);
  line-height: 1.7;
  max-width: 600px;
}

.project-specs {
  display: flex;
  gap: 36px;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 0.5px solid var(--border);
}

.project-specs .spec strong {
  display: block;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 2px;
}

.project-specs .spec span {
  font-size: 12px;
  color: var(--text-light);
}

/* ── LIGHTBOX ── */

.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(250, 249, 247, 0.97);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.lightbox.open {
  display: flex;
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: var(--text);
  transition: background 0.2s;
}

.lightbox-close:hover {
  background: var(--border);
}

.lightbox img {
  max-width: 85vw;
  max-height: 75vh;
  object-fit: contain;
  border-radius: 8px;
}

.lightbox-caption {
  color: var(--text-mid);
  font-size: 14px;
  margin-top: 16px;
}

.lightbox-nav {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.lightbox-nav button {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 0.5px solid var(--border);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: border-color 0.2s;
}

.lightbox-nav button:hover {
  border-color: var(--text-light);
}

/* ── ABOUT ── */

.about-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.about-photo {
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 4/3;
}

.about-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-text h2 {
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 500;
  margin-bottom: 16px;
}

.about-text p {
  font-size: 15px;
  color: var(--text-mid);
  line-height: 1.7;
  margin-bottom: 12px;
}

.values {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 48px;
}

.value {
  border-top: 0.5px solid var(--border);
  padding-top: 16px;
}

.value h4 {
  font-size: 15px;
  font-weight: 500;
  margin-bottom: 6px;
  color: var(--text);
}

.value p {
  font-size: 14px;
  color: var(--text-light);
  line-height: 1.6;
}

.team {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.team-member {
  text-align: center;
}

.team-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--border);
  margin: 0 auto 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 500;
  color: var(--text-mid);
  overflow: hidden;
}

.team-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.team-member h4 {
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
}

.team-member p {
  font-size: 13px;
  color: var(--text-light);
}

/* ── CONTACT ── */

.contact-wrap {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 48px;
}

.contact-wrap h2 {
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 500;
  margin-bottom: 28px;
  grid-column: span 2;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 12px;
  color: var(--text-light);
  margin-bottom: 6px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  font-size: 15px;
  padding: 12px 14px;
  border: 0.5px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  outline: none;
  font-family: var(--font-body);
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--text-light);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-faint);
}

.form-group textarea {
  height: 120px;
  resize: vertical;
}

.submit-btn {
  padding: 14px 32px;
  font-size: 14px;
  font-weight: 500;
  background: var(--accent);
  color: var(--on-accent);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s;
  margin-top: 4px;
}

.submit-btn:hover {
  background: var(--accent-hover);
}

.contact-details .detail {
  margin-bottom: 24px;
}

.contact-details .detail h4 {
  font-size: 12px;
  color: var(--text-light);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.contact-details .detail p {
  font-size: 15px;
  color: var(--text);
  line-height: 1.7;
}

/* ── FOOTER ── */

.footer {
  border-top: 0.5px solid var(--border);
  padding: 24px 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-left {
  font-size: 13px;
  color: var(--text-light);
}

.footer-social {
  display: flex;
  gap: 20px;
}

.footer-social a {
  color: var(--text-light);
  transition: color 0.2s;
}

.footer-social a:hover {
  color: var(--text);
}

.footer-social svg {
  width: 20px;
  height: 20px;
}

/* ── RESPONSIVE ── */

@media (max-width: 768px) {
  .nav {
    padding: 16px 24px;
  }

  .nav-hamburger {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg);
    padding: 24px;
    gap: 20px;
    border-bottom: 0.5px solid var(--border);
  }

  .nav-links.open {
    display: flex;
  }

  .hero {
    grid-template-columns: 1fr;
    padding: 0 24px;
    min-height: auto;
  }

  .hero-text {
    padding: 40px 0 24px;
  }

  .hero-text h1 {
    font-size: 32px;
  }

  .hero-image {
    border-radius: 8px;
    aspect-ratio: 16/10;
    margin-bottom: 24px;
  }

  .section {
    padding: 40px 24px;
  }

  .stats {
    grid-template-columns: repeat(3, 1fr);
  }

  .stat {
    padding: 20px 16px;
  }

  .stat-number {
    font-size: 28px;
  }

  .project-row,
  .project-row.reverse {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .project-row.reverse .project-image,
  .project-row.reverse .project-info {
    order: unset;
  }

  .about-hero {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .values {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .team {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }

  .contact-wrap {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .contact-wrap h2 {
    grid-column: span 1;
  }

  .project-specs {
    flex-wrap: wrap;
    gap: 20px;
  }

  .footer {
    padding: 20px 24px;
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .section-header h2 {
    font-size: 22px;
  }

  .portfolio-nav {
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
  }

  .carousel-thumbs {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}
