@import url("https://fonts.googleapis.com/css2?family=Righteous&display=swap");

:root {
  --light-mystified: #D6E4D6;
  --candidate: #C6BE8D;
  --scots-pine: #636536;
  --black-mesa: #242510;
  --portfolio-text: var(--black-mesa);
  --portfolio-muted: var(--scots-pine);
  --portfolio-line: rgba(36, 37, 16, .18);
  --portfolio-card: rgba(255, 255, 255, .18);
}

.portfolio-nav,
.portfolio-footer,
.portfolio-nav *,
.portfolio-footer * {
  box-sizing: border-box;
}

.portfolio-nav {
  position: sticky;
  top: 18px;
  z-index: 20;
  width: min(1240px, calc(100% - 48px));
  margin: 22px auto 0;
  padding: 10px 12px 10px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border: 1px solid var(--portfolio-line);
  border-radius: 999px;
  background: rgba(255, 255, 255, .3);
  box-shadow: 0 18px 44px rgba(36, 37, 16, .08);
  backdrop-filter: blur(18px) saturate(1.2);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  color: var(--portfolio-text);
  font-family: Inter, system-ui, sans-serif;
  font-size: 14px;
  font-weight: 600;
}

.portfolio-nav .brand {
  font-family: Righteous, Inter, system-ui, sans-serif;
  font-size: 18px;
  line-height: 1;
  letter-spacing: .03em;
  text-transform: uppercase;
}

.portfolio-nav .links {
  display: flex;
  align-items: center;
  gap: 44px;
}

.portfolio-nav .pill,
.portfolio-footer .pill {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  border-radius: 999px;
  background: #fff;
  color: var(--black-mesa);
  font-weight: 600;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, .54);
  color: var(--black-mesa);
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: pointer;
}

.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  content: "";
}

.nav-toggle span { position: relative; }
.nav-toggle span::before,
.nav-toggle span::after {
  position: absolute;
  left: 0;
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }
.portfolio-nav.open .nav-toggle span { background: transparent; }
.portfolio-nav.open .nav-toggle span::before { top: 0; transform: rotate(45deg); }
.portfolio-nav.open .nav-toggle span::after { top: 0; transform: rotate(-45deg); }

.portfolio-footer {
  width: 100%;
  margin: 0;
  border-radius: 0;
  background: #151515;
  color: #fff2e9;
  padding: 32px 0 36px;
  font-family: Inter, system-ui, sans-serif;
}

.portfolio-footer .footer-grid {
  width: min(1180px, calc(100% - 36px));
  margin-inline: auto;
  display: grid;
  grid-template-columns: 1.1fr .9fr .9fr .9fr;
  gap: 34px;
}

.portfolio-footer b {
  display: block;
  margin-bottom: 14px;
  color: #fff2e9;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
}

.portfolio-footer p,
.portfolio-footer a {
  display: block;
  margin: 0 0 7px;
  color: rgba(255, 242, 233, .78);
  font-size: 14px;
  line-height: 1.35;
  text-decoration: none;
}

.portfolio-footer .footer-logo {
  width: min(1180px, calc(100% - 36px));
  margin: 44px auto 0;
  color: #fff2e9;
  font-size: clamp(52px, 9vw, 132px);
  line-height: .8;
  letter-spacing: -.08em;
  font-weight: 600;
}

/* Shared portfolio case-study layout. Mirrors the Lights & Palms template. */
body {
  color: var(--portfolio-text);
  font-family: Inter, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

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

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

body h1,
body h2,
body h3,
body p {
  margin: 0;
}

body h1,
body h2,
body h3 {
  font-family: Inter, system-ui, sans-serif;
  font-weight: 600;
}

.wrap {
  width: min(1180px, calc(100% - 40px));
  margin-inline: auto;
}

.hero {
  padding: 86px 0 52px !important;
  text-align: center;
}

.eyebrow {
  color: var(--portfolio-muted);
  font-size: 13px;
  letter-spacing: .04em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 18px;
}

body h1 {
  max-width: 1120px;
  margin: 0 auto;
  color: var(--portfolio-text);
  font-size: clamp(58px, 8vw, 128px);
  line-height: .88;
  letter-spacing: -.065em;
}

.hero p {
  max-width: 760px;
  margin: 28px auto 0;
  color: var(--portfolio-muted);
  font-size: clamp(19px, 1.6vw, 26px);
  line-height: 1.3;
}

.hero-image {
  width: min(980px, calc(100% - 24px)) !important;
  margin: 34px auto 0 !important;
  border-radius: 18px;
  overflow: hidden;
  background: rgba(255, 255, 255, .2);
}

.hero-image img {
  height: auto !important;
  object-fit: contain !important;
}

.details {
  padding: 56px 0 86px !important;
}

.detail-grid {
  display: grid;
  grid-template-columns: .72fr 1.28fr;
  gap: 58px;
  border-top: 1px solid var(--portfolio-line, var(--line, rgba(36, 37, 16, .18)));
  padding-top: 34px;
}

.facts {
  display: grid;
  gap: 22px;
  align-content: start;
}

.fact {
  border-top: 1px solid var(--portfolio-line, var(--line, rgba(36, 37, 16, .18)));
  padding-top: 14px;
}

.fact span {
  display: block;
  color: var(--portfolio-muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 600;
  margin-bottom: 8px;
}

.fact b {
  color: var(--portfolio-text);
  font-weight: 600;
  font-size: 18px;
}

.intro-copy {
  max-width: 790px;
  color: var(--portfolio-text);
  font-size: clamp(24px, 2.8vw, 42px);
  line-height: 1.08;
  letter-spacing: -.045em;
  font-weight: 600;
}

.checklist {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  margin-top: 36px;
}

.checklist div {
  border: 1px solid var(--portfolio-line, var(--line, rgba(36, 37, 16, .18)));
  border-radius: 14px;
  padding: 18px;
  color: var(--portfolio-text);
  font-weight: 600;
  line-height: 1.15;
  background: var(--portfolio-card);
}

.section {
  padding: 86px 0 !important;
  border-top: 1px solid var(--portfolio-line, var(--line, rgba(36, 37, 16, .18)));
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 44px;
  align-items: center;
}

.split.reverse .copy {
  order: 2;
}

.copy h2,
.carousel-head h2 {
  color: var(--portfolio-text);
  font-size: clamp(34px, 4vw, 68px);
  line-height: .96;
  letter-spacing: -.055em;
  margin-bottom: 18px;
}

.copy p {
  max-width: 590px;
  color: var(--portfolio-muted);
  font-size: 17px;
  line-height: 1.55;
}

.frame,
.project-slide {
  border-radius: 16px;
  overflow: hidden;
  background: var(--portfolio-card);
}

.frame img,
.project-slide img {
  height: auto !important;
  object-fit: contain !important;
}

.project-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 34px;
}

.project-gallery .frame {
  aspect-ratio: 1 / 1;
  height: auto;
  display: block;
}

.project-gallery img {
  width: 100%;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center;
}

.carousel-section {
  width: min(1180px, calc(100% - 40px)) !important;
}

.carousel-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 20px;
}

.project-carousel {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 18px) / 2);
  gap: 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.project-carousel::-webkit-scrollbar {
  display: none;
}

.project-carousel .project-slide {
  scroll-snap-align: start;
  margin: 0;
}

@media (max-width: 820px) {
  .portfolio-nav {
    width: calc(100% - 24px);
    top: 10px;
    font-size: 12px;
    gap: 12px;
  }

  .portfolio-nav .brand { font-size: 14px; }
  .nav-toggle { display: none; }
  .portfolio-nav .links,
  .portfolio-nav > .pill { display: none; }
  .portfolio-nav > .pill {
    min-height: 38px;
    display: inline-flex;
    padding: 0 16px;
    font-size: 12px;
  }
  .portfolio-nav.open { border-radius: 24px; }
  .portfolio-nav.open .links {
    position: absolute;
    left: 12px;
    right: 12px;
    top: calc(100% + 8px);
    display: grid;
    gap: 2px;
    padding: 12px;
    border: 1px solid rgba(36, 37, 16, .16);
    border-radius: 20px;
    background: rgba(214, 228, 214, .88);
    box-shadow: 0 18px 44px rgba(36, 37, 16, .12);
    backdrop-filter: blur(18px) saturate(1.2);
    -webkit-backdrop-filter: blur(18px) saturate(1.2);
  }

  .portfolio-nav.open .links a { padding: 12px 10px; }
  .portfolio-nav.open > .pill {
    position: absolute;
    right: 12px;
    top: calc(100% + 196px);
    display: inline-flex;
  }

  .portfolio-footer .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .portfolio-footer .footer-logo { font-size: 56px; }

  .hero {
    padding: 72px 0 42px !important;
  }

  body h1 {
    font-size: clamp(46px, 14vw, 72px);
  }

  .hero-image {
    width: min(100% - 20px, 640px) !important;
  }

  .detail-grid,
  .split,
  .checklist,
  .project-gallery {
    grid-template-columns: 1fr;
  }

  .split.reverse .copy {
    order: 0;
  }

  .carousel-head {
    display: grid;
    align-items: start;
  }

  .project-carousel {
    grid-auto-columns: 86%;
  }
}
