/* ============================================================
   MANTOUVERT — COMPONENTS
   Source of truth: rools.md (Version 1.0)
   ============================================================ */

/* --------------------------------------------
   Buttons — simple, large, flat. No gradients.
   -------------------------------------------- */
.btn {
  display: inline-block;
  padding: 20px 44px;
  font-family: var(--font-body);
  font-size: var(--type-small);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border-radius: var(--radius-btn); /* 4px */
  border: 1px solid transparent;
  transition:
    background-color var(--duration-fast) var(--ease),
    color var(--duration-fast) var(--ease),
    border-color var(--duration-fast) var(--ease);
}

/* Primary — matte black base, burnt orange hover */
.btn--primary {
  background-color: var(--color-black);
  color: var(--color-white);
  border-color: var(--color-black);
}

.btn--primary:hover {
  background-color: var(--color-orange); /* Burnt Orange hover */
  border-color: var(--color-orange);
  color: var(--color-white);
}

/* Ghost — outline style for dark heroes */
.btn--ghost {
  background-color: transparent;
  color: var(--color-white);
  border-color: rgba(245, 242, 237, 0.5);
}

.btn--ghost:hover {
  background-color: var(--color-orange);
  border-color: var(--color-orange);
  color: var(--color-white);
}

/* Inverted — white button on dark backgrounds */
.btn--light {
  background-color: var(--color-white);
  color: var(--color-black);
  border-color: var(--color-white);
}

.btn--light:hover {
  background-color: var(--color-orange);
  border-color: var(--color-orange);
  color: var(--color-white);
}

/* --------------------------------------------
   Navigation — hamburger centered, logo below.
   Transparent initially, turns black on scroll.
   -------------------------------------------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding-block: 24px;
  transition:
    background-color var(--duration-base) var(--ease),
    padding-block var(--duration-base) var(--ease);
}

.site-header.is-scrolled {
  padding-block: 16px;
}

.nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-align: center;
}

/* Hamburger button */
.nav__toggle {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px;
  cursor: pointer;
  background: none;
  border: none;
}

.hamburger-line {
  display: block;
  width: 36px;
  height: 3px;
  background-color: var(--color-white);
  border-radius: 2px;
  transition:
    transform var(--duration-fast) var(--ease),
    opacity var(--duration-fast) var(--ease);
}

/* Hamburger open state (X animation) */
.nav__toggle.is-active .hamburger-line:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}

.nav__toggle.is-active .hamburger-line:nth-child(2) {
  opacity: 0;
}

.nav__toggle.is-active .hamburger-line:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

/* Logo */
.nav__logo {
  font-family: var(--font-display); /* Monic DEMO Regular */
  font-size: 20px;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--color-white);
  transition: color var(--duration-fast) var(--ease);
  text-transform: uppercase;
}

/* On light backgrounds — icon and logo turn orange, black on hover */
.site-header.is-on-light .nav__logo {
  color: var(--color-orange);
}

.site-header.is-on-light .hamburger-line {
  background-color: var(--color-orange);
}

.site-header.is-on-light .nav__toggle:hover .hamburger-line {
  background-color: var(--color-black);
}

.site-header.is-on-light .nav__logo:hover {
  color: var(--color-black);
}

/* Full-screen menu overlay */
.nav__menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.nav__menu.is-open {
  display: flex;
}

/* Transparent black overlay — sits on top of the video */
.nav__menu::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background-color: rgba(17, 17, 17, 0.85);
  pointer-events: none;
}

/* Nav menu video background — high quality, covers full screen */
.nav__menu__video {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  pointer-events: none;
}

.nav__links {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 40px;
  text-align: center;
}

.nav__link {
  font-family: var(--font-secondary);
  font-size: var(--type-heading);
  letter-spacing: 0.02em;
  color: var(--color-white);
  opacity: 0.85;
  transition:
    opacity var(--duration-fast) var(--ease),
    color var(--duration-fast) var(--ease);
}

.nav__link:hover,
.nav__link.is-active {
  opacity: 1;
  color: var(--color-orange);
}

.nav__link--cta {
  padding: 16px 40px;
  border: 1px solid var(--color-white);
  border-radius: var(--radius-btn);
  opacity: 1;
  font-size: var(--type-small);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.nav__link--cta:hover {
  background-color: var(--color-orange);
  border-color: var(--color-orange);
  color: var(--color-white);
}

/* --------------------------------------------
   Editorial Intro Section
   -------------------------------------------- */
.intro__eyebrow {
  font-size: var(--type-small);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 48px;
}

.intro__title {
  font-family: var(--font-secondary);
  font-size: var(--type-section);
  line-height: 1.1;
  max-width: 20ch;
}

/* --------------------------------------------
   Project Cards — minimal, image + small title
   -------------------------------------------- */
.project-card__media {
  display: block;
  overflow: hidden;
  margin-bottom: 24px;
}

.project-card__media img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: var(--radius-none); /* 0px */
  transition: transform var(--duration-slow) var(--ease);
}

.project-card__media:hover img {
  transform: scale(1.03); /* Smooth scale — allowed */
}

.project-card__title {
  font-family: var(--font-secondary);
  font-size: var(--type-heading); /* 42–56px but controlled */
  line-height: 1.2;
  margin-bottom: 8px;
}

.project-card__meta {
  font-size: var(--type-small);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-muted);
}

/* --------------------------------------------
   Services List — thin line icons, minimal
   -------------------------------------------- */
.services__item {
  border-top: 1px solid var(--color-sand);
  padding-block: 32px;
}

.services__item:last-child {
  border-bottom: 1px solid var(--color-sand);
}

.services__item a {
  display: flex;
  align-items: center;
  gap: 32px;
  transition: color var(--duration-fast) var(--ease);
}

.services__item a:hover {
  color: var(--color-orange);
}

.services__icon {
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  color: var(--color-stone);
}

.services__name {
  font-family: var(--font-secondary);
  font-size: var(--type-heading);
  line-height: 1.2;
}

/* --------------------------------------------
   Craftsmanship Section
   -------------------------------------------- */
.craftsmanship__media img {
  width: 100%;
  border-radius: var(--radius-none);
  object-fit: cover;
}

.craftsmanship__title {
  font-family: var(--font-secondary);
  font-size: var(--type-section);
  line-height: 1.1;
  margin-bottom: 32px;
}

.craftsmanship__text {
  color: var(--color-charcoal);
  margin-bottom: 40px;
}

/* --------------------------------------------
   Stats — elegant numbering
   -------------------------------------------- */
.stat {
  padding-top: 32px;
  border-top: 1px solid var(--color-sand);
}

.stat__number {
  display: block;
  font-family: var(--font-secondary);
  font-size: var(--type-section);
  color: var(--color-accent);
  margin-bottom: 16px;
}

.stat__label {
  font-size: var(--type-small);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-muted);
}

/* --------------------------------------------
   Gallery — large editorial photography
   -------------------------------------------- */
.gallery__item img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: var(--radius-none);
}

.gallery__item:first-child img {
  aspect-ratio: 16 / 10;
}

.gallery__caption {
  margin-top: 16px;
  font-size: var(--type-small);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-muted);
}

/* --------------------------------------------
   Testimonials
   -------------------------------------------- */
.testimonial {
  max-width: 900px;
  margin-inline: auto;
  text-align: center;
  padding-block: 40px;
}

.testimonial__quote {
  font-family: var(--font-secondary);
  font-size: var(--type-heading);
  line-height: 1.3;
  margin-bottom: 40px;
}

.testimonial__author {
  font-style: normal;
  font-size: var(--type-small);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-muted);
}

/* --------------------------------------------
   CTA Section — large typography, dark
   -------------------------------------------- */
.cta {
  background-color: var(--color-black);
  color: var(--color-white);
  text-align: center;
}

.cta__title {
  font-family: var(--font-display);
  font-size: var(--type-hero);
  text-transform: uppercase;
  margin-bottom: 64px;
}

/* --------------------------------------------
   Footer — minimal, dark, large typography
   -------------------------------------------- */
.site-footer {
  background-color: var(--color-black);
  color: var(--color-white);
  padding-block: 120px 48px;
}

.site-footer__logo {
  font-family: var(--font-secondary);
  font-size: clamp(48px, 6vw, 90px);
  line-height: 1;
  color: var(--color-white);
}

.site-footer__nav ul {
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: right;
}

.site-footer__nav a {
  font-size: var(--type-small);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-white);
  opacity: 0.7;
  transition:
    opacity var(--duration-fast) var(--ease),
    color var(--duration-fast) var(--ease);
}

.site-footer__nav a:hover {
  opacity: 1;
  color: var(--color-orange);
}

.site-footer__meta {
  font-size: var(--type-small);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-stone);
  opacity: 0.7;
}

/* --------------------------------------------
    Hero Cards — 8-card grid (4 up, 4 down)
    -------------------------------------------- */
.hero--cards {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 0;
  overflow: hidden;
}

/* Shared background — 3 images side by side */
.hero-cards__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: flex;
}

.hero-cards__bg img {
  flex: 1 1 0;
  min-width: 0;
  height: 100%;
  object-fit: cover;
}

.hero-cards__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.7) 0%,
    rgba(0, 0, 0, 0.35) 50%,
    rgba(0, 0, 0, 0.15) 100%
  );
}

.hero-cards {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(2, 1fr);
  width: 100%;
  height: 100vh;
}

/* Transparent cards — white borders show the shared bg grid */
.hero-card {
  position: relative;
  background-color: transparent;
  border-right: 2px solid rgb(255, 255, 255);
  border-bottom: 2px solid rgb(255, 255, 255);
  cursor: pointer;
  transition: background-color var(--duration-base) var(--ease);
}

.hero-card:nth-child(4n) {
  border-right: none;
}

.hero-card:nth-child(n + 5) {
  border-bottom: none;
}

.hero-card:hover {
  background-color: rgba(0, 0, 0, 0.35);
}

/* Orange triangle in top-right corner — bottom row cards 6, 7, 8 only */
.hero-card:nth-child(6)::after,
.hero-card:nth-child(7)::after,
.hero-card:nth-child(8)::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 0;
  height: 0;
  border-top: 28px solid var(--color-orange);
  border-left: 28px solid transparent;
  z-index: 2;
}

/* Header text on bottom cards 6, 7, 8 */
.hero-card__header {
  position: absolute;
  top: 16px;
  left: 20px;
  z-index: 3;
  font-family: var(--font-display); /* Monic Sans Serif Ligature */
  font-size: clamp(18px, 1.6vw, 26px);
  line-height: 1.2;
  color: var(--color-white);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0;
}

/* Bottom hero text — full-width headline, paragraph bottom-right */
.hero-cards__footer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 2;
  padding: 0 60px 80px;
  pointer-events: none;
}

.hero-cards__headline {
  font-family: var(--font-display);
  font-size: clamp(80px, 9vw, 110px);
  line-height: 1;
  color: var(--color-white);
  text-transform: uppercase;
  letter-spacing: -0.01em;
  white-space: nowrap;
  width: 100%;
  margin: 0;
}

.hero-cards__paragraph {
  position: absolute;
  bottom: 80px;
  right: 60px;
  max-width: 350px;
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
}

/* --------------------------------------------
    Page Hero — full viewport so the section
    always fills the visible display cleanly.
    -------------------------------------------- */
.hero--page {
  min-height: 100vh;
  align-items: flex-end;
}

/* --------------------------------------------
   Project Grid — portfolio listing
   -------------------------------------------- */
.project-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--gutter);
}

/* --------------------------------------------
   Project Detail Facts
   -------------------------------------------- */
.project-detail__facts {
  margin-bottom: 48px;
}

.project-detail__facts li {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding-block: 16px;
  border-bottom: 1px solid var(--color-sand);
  font-size: var(--type-body);
}

.project-detail__facts .meta {
  flex: 0 0 auto;
}

/* --------------------------------------------
   Next Project — editorial navigation
   -------------------------------------------- */
.next-project {
  border-top: 1px solid var(--color-sand);
}

.next-project__link {
  display: block;
}

.next-project__title {
  font-family: var(--font-secondary);
  font-size: var(--type-section);
  line-height: 1.1;
  transition: color var(--duration-fast) var(--ease);
}

.next-project__link:hover .next-project__title {
  color: var(--color-accent);
}

/* --------------------------------------------
   Contact Form — minimal, editorial
   -------------------------------------------- */
.contact-form__field {
  margin-bottom: 32px;
}

.contact-form__field label {
  display: block;
  margin-bottom: 12px;
}

.contact-form__field input,
.contact-form__field select,
.contact-form__field textarea {
  width: 100%;
  padding: 16px 0;
  font-family: var(--font-body);
  font-size: var(--type-body);
  color: var(--color-text);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--color-sand);
  border-radius: 0;
  transition: border-color var(--duration-fast) var(--ease);
}

.contact-form__field input:focus,
.contact-form__field select:focus,
.contact-form__field textarea:focus {
  outline: none;
  border-bottom-color: var(--color-accent);
}

.contact-form__field textarea {
  resize: vertical;
}

.contact-details {
  padding: 48px;
  background-color: var(--color-black);
  color: var(--color-white);
}

.contact-details .craftsmanship__title {
  color: var(--color-white);
  margin-bottom: 40px;
}

.contact-details .project-detail__facts li {
  border-bottom-color: rgba(245, 242, 237, 0.15);
}

.contact-details .project-detail__facts .meta {
  color: var(--color-stone);
}

/* --------------------------------------------
   Scroll Reveal Transition — global curtain
   that slides down covering the viewport,
   then slides away revealing the next section.
   Scroll acts as a trigger; page locks while
   the transition plays.
   Two layers: black curtain first, then the
   orange curtain falls on top of it.
   -------------------------------------------- */
.scroll-reveal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background-color: var(--color-black);
  z-index: 50;
  transform: translateY(-100%);
  pointer-events: none;
  will-change: transform;
  transition: transform var(--duration-slow) var(--ease);
}

.scroll-reveal--orange {
  background-color: var(--color-orange);
  z-index: 51;
}

/* Lock scrolling while the reveal transition plays */
body.is-locked {
  overflow: hidden;
}

/* Small devices — no scroll transition curtain */
@media (max-width: 768px) {
  .scroll-reveal,
  .scroll-reveal--orange {
    display: none;
  }

  body.is-locked {
    overflow: auto;
  }
}

/* --------------------------------------------
   Atherton Pavilions — Editorial Magazine Spread
   Split-screen 2-column "book" layout.
   -------------------------------------------- */
.editorial-spread {
  background-color: #E5E5E5;
  min-height: 100vh;
  display: flex;
  align-items: stretch;
  padding: 0;
}

.editorial-spread__book {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

/* Left panel — deep forest green */
.editorial-spread__page--green {
  background-color: #3A4B40;
  padding: 60px 80px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Left panel — deep ocean blue */
.editorial-spread__page--blue {
  background-color: #1B3A57;
  padding: 60px 80px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Left panel — dark espresso brown */
.editorial-spread__page--brown {
  background-color: #3E2C1F;
  padding: 60px 80px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Top section — page number + intro columns */
.editorial-spread__top {
  display: flex;
  justify-content: space-between;
  gap: 40px;
}

.editorial-spread__page-num {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.8);
  letter-spacing: 0.08em;
  font-family: var(--font-body);
  flex: 0 0 auto;
}

.editorial-spread__intro-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  max-width: 420px;
}

.editorial-spread__intro-cols p {
  font-size: 10px;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.7);
  max-width: none;
  font-family: var(--font-body);
}

/* Middle — main title */
.editorial-spread__title {
  font-family: var(--font-secondary);
  font-size: clamp(48px, 5vw, 80px);
  line-height: 1.05;
  color: #000000;
  margin: 0;
  letter-spacing: -0.01em;
}

/* Bottom — description */
.editorial-spread__desc {
  font-size: 15px;
  line-height: 1.5;
  color: #000000;
  max-width: 80%;
  font-family: var(--font-body);
}

/* Explore all projects link */
.editorial-spread__explore {
  display: inline-block;
  margin-top: 24px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #000000;
  border-bottom: 1px solid rgba(0, 0, 0, 0.4);
  padding-bottom: 4px;
  transition:
    border-color var(--duration-fast) var(--ease),
    color var(--duration-fast) var(--ease);
}

.editorial-spread__explore:hover {
  border-color: var(--color-orange);
  color: var(--color-orange);
}

/* Gallery overlay — expands smoothly from the card */
.gallery-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background-color: rgba(0, 0, 0, 0.95);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity var(--duration-slow) var(--ease),
    visibility var(--duration-slow) var(--ease);
}

.gallery-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.gallery-overlay__close {
  position: absolute;
  top: 30px;
  right: 40px;
  z-index: 10;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-white);
  cursor: pointer;
  transition: color var(--duration-fast) var(--ease);
}

.gallery-overlay__close:hover {
  color: var(--color-orange);
}

.gallery-overlay__main {
  width: 80%;
  max-width: 1200px;
  margin-bottom: 40px;
  overflow: hidden;
  transform: scale(0.92);
  transition: transform var(--duration-slow) var(--ease);
}

.gallery-overlay.is-open .gallery-overlay__main {
  transform: scale(1);
}

.gallery-overlay__main img {
  width: 100%;
  height: 60vh;
  object-fit: cover;
}

.gallery-overlay__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  width: 80%;
  max-width: 1200px;
}

.gallery-overlay__grid img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  cursor: pointer;
  opacity: 0.7;
  transition:
    opacity var(--duration-fast) var(--ease),
    transform var(--duration-fast) var(--ease);
}

.gallery-overlay__grid img:hover {
  opacity: 1;
  transform: scale(1.02);
}

/* Infinite Drag Gallery — flat "museum in space" canvas */
.infinite-gallery {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  overflow: hidden;
  cursor: grab;
  background-color: #E5E5E5;
  background-image:
    radial-gradient(rgba(0, 0, 0, 0.04) 1px, transparent 1px);
  background-size: 24px 24px;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

.infinite-gallery.is-dragging {
  cursor: grabbing;
}

.infinite-gallery__canvas {
  position: absolute;
  top: 0;
  left: 0;
  will-change: transform;
}

.infinite-gallery__title {
  position: absolute;
  top: 90px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  font-family: var(--font-secondary);
  font-size: clamp(24px, 3vw, 40px);
  color: var(--color-black);
  letter-spacing: 0.02em;
  text-align: center;
  pointer-events: none;
}

/* Masonry card in the infinite canvas */
.infinite-gallery__card {
  position: absolute;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  cursor: pointer;
}

.infinite-gallery__card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}

/* Banner overlay — title + short description on every card */
.infinite-gallery__banner {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 2;
  padding: 48px 20px 16px;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.75) 0%,
    rgba(0, 0, 0, 0.45) 55%,
    transparent 100%
  );
  color: var(--color-white);
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}

.infinite-gallery__banner h4 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1.1;
  margin: 0 0 4px;
}

.infinite-gallery__banner p {
  font-family: var(--font-body);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
}

/* Collection tag — small pill label above the title */
.infinite-gallery__collection {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-orange);
  background-color: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  padding: 3px 10px;
  margin-bottom: 8px;
}



/* Right panel — full-bleed image */
.editorial-spread__page--image {
  position: relative;
  min-height: 700px;
  overflow: hidden;
}

.editorial-spread__page--image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Image page overlays */
.editorial-spread__img-num {
  position: absolute;
  top: 40px;
  right: 40px;
  font-size: 12px;
  color: #FFFFFF;
  z-index: 2;
  font-family: var(--font-body);
  letter-spacing: 0.08em;
}

.editorial-spread__caption {
  position: absolute;
  bottom: 40px;
  left: 40px;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.8);
  z-index: 2;
  font-family: var(--font-body);
  letter-spacing: 0.06em;
  max-width: 280px;
}

/* --------------------------------------------
   Mega Footer — boxed container with a thick
   white border frame. Sits on a light gray
   background, centered with max-width.
   Injected globally on every page via JS.
   -------------------------------------------- */

/* Outer wrapper — light gray page background with video */
.mega-footer {
  position: relative;
  background-color: #F3F4F6;
  padding: 120px 40px 80px;
  overflow: hidden;
}

/* Footer body background video */
.mega-footer__bg-body {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.mega-footer__bg-body video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mega-footer__overlay-body {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(0, 0, 0, 0.25);
}

/* Brown spacer band between the last section and the footer */
.mega-footer__spacer {
  background-color: #3E2C1F; /* deep espresso brown */
  height: 120px;
}

/* The white framed box */
.mega-footer__box {
  position: relative;
  z-index: 2;
  max-width: 1600px;
  margin-inline: auto;
  background-color: #FFFFFF;
  padding: 12px 20px;
  border-radius: 0;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
}

/* Inner content wrapper — holds image & text */
.mega-footer__inner {
  position: relative;
  border-radius: 0;
  overflow: hidden;
  height: 800px;
  color: var(--color-white);
}

.mega-footer__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.mega-footer__bg img,
.mega-footer__bg video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mega-footer__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.5) 0%,
    rgba(0, 0, 0, 0.1) 50%,
    rgba(0, 0, 0, 0.2) 100%
  );
}

/* Top row — logo, nav links, CTA */
.mega-footer__top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 40px;
  background-color: var(--color-orange);
}

.mega-footer__logo {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-black);
  transition: color var(--duration-fast) var(--ease);
}

.mega-footer__logo:hover {
  color: var(--color-brick);
}

/* Contact — desktop top-right on the orange bar,
   mobile bottom-right on the same line as the title */
.mega-footer__contact {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 11;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 20px 40px; /* matches .mega-footer__top padding */
}

.mega-footer__contact a {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--color-black);
  transition:
    opacity var(--duration-fast) var(--ease),
    color var(--duration-fast) var(--ease);
}

.mega-footer__contact a:hover {
  opacity: 0.8;
  color: var(--color-brick);
}

/* Center — brand statement */
.mega-footer__center {
  position: absolute;
  top: 38%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 80%;
  max-width: 900px;
}

/* Title — bottom-left of the card */
.mega-footer__title {
  position: absolute;
  bottom: 60px;
  left: 60px;
  z-index: 10;
  font-family: var(--font-display);
  font-size: clamp(48px, 6vw, 90px);
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  line-height: 1;
  color: var(--color-white);
  margin: 0;
}

.mega-footer__title sup {
  font-size: 24px;
  font-weight: 700;
  vertical-align: super;
}

.mega-footer__subtitle {
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
  max-width: 600px;
  margin-top: 24px;
}

/* Bottom — social links */
.mega-footer__socials {
  display: flex;
  gap: 24px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 40px;
}

.mega-footer__socials a {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-white);
  border-bottom: 1px solid rgba(255, 255, 255, 0.4);
  padding-bottom: 4px;
  transition:
    border-color var(--duration-fast) var(--ease),
    color var(--duration-fast) var(--ease);
}

.mega-footer__socials a:hover {
  border-color: var(--color-orange);
  color: var(--color-orange);
}

/* Bottom bar — copyright */
.mega-footer__bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10;
  background-color: rgba(15, 23, 42, 0.9);
  min-height: 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 8px 40px;
}

.mega-footer__bottom p {
  font-family: var(--font-body);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

/* --------------------------------------------
   Responsive Components
   -------------------------------------------- */
@media (max-width: 768px) {
  .mega-footer {
    padding-block: 40px;
  }

  .mega-footer__box {
    padding: 10px;
    border-radius: 20px;
  }

  .mega-footer__inner {
    height: 550px;
    border-radius: 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }

  .mega-footer__top {
    padding: 24px 20px;
  }

  /* Center — static, flows as: subtitle, socials, then contact below */
  .mega-footer__center {
    position: static;
    transform: none;
    width: 100%;
    order: 2;
  }

  /* Contact — centered, straight under the social links */
  .mega-footer__contact {
    position: static;
    order: 3;
    margin-top: 24px;
    padding: 0;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    text-align: center;
  }

  .mega-footer__contact a {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.95);
  }

  .mega-footer__contact a:hover {
    color: var(--color-orange);
    opacity: 1;
  }

  .mega-footer__title {
    font-size: clamp(28px, 8vw, 56px);
    bottom: 24px;
    left: 24px;
  }

  .mega-footer__title sup {
    font-size: 16px;
  }

  .mega-footer__subtitle {
    font-size: 15px;
    margin-top: 16px;
  }

  .mega-footer__socials {
    gap: 16px;
    margin-top: 32px;
  }

  .mega-footer__socials a {
    font-size: 12px;
  }

  /* Bottom bar — modestly reduced height on small devices */
  .mega-footer__bottom {
    min-height: 32px;
    padding: 6px 20px;
    justify-content: center;
    text-align: center;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px;
  }

  .mega-footer__bottom p {
    font-size: 10px;
    margin: 0;
  }

  .editorial-spread__book {
    grid-template-columns: 1fr;
  }

  .editorial-spread__page--green,
  .editorial-spread__page--blue,
  .editorial-spread__page--brown,
  .editorial-spread__page--image {
    min-height: 500px;
  }

  .editorial-spread__page--green,
  .editorial-spread__page--blue,
  .editorial-spread__page--brown {
    padding: 40px 32px;
  }

  .editorial-spread__intro-cols {
    grid-template-columns: 1fr;
    max-width: none;
  }

  .editorial-spread__desc {
    max-width: 100%;
  }

  .hero-cards {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(4, 1fr);
  }

  /* 2-column mobile borders */
  .hero-card {
    border-right: 2px solid rgb(255, 255, 255);
    border-bottom: 2px solid rgb(255, 255, 255);
  }

  .hero-card:nth-child(2n) {
    border-right: none;
  }

  .hero-card:nth-child(n + 7) {
    border-bottom: none;
  }

  .hero-cards__footer {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 0 20px 120px;
  }

  .hero-cards__headline {
    font-size: clamp(48px, 12vw, 72px);
  }

  .hero-cards__paragraph {
    font-size: 14px;
    margin: 0;
    bottom: 120px;
  }

  .project-grid {
    grid-template-columns: 1fr;
  }

  .next-project__title {
    font-size: var(--type-heading);
  }

  .contact-details {
    padding: 32px;
  }

  .intro__title {
    font-size: var(--type-heading);
  }

  .craftsmanship__title {
    font-size: var(--type-heading);
  }

  .stat__number {
    font-size: var(--type-heading);
  }

  .testimonial__quote {
    font-size: var(--type-heading);
  }

  .site-footer__nav ul {
    text-align: left;
  }

  /* Nav menu — smaller links on mobile */
  .nav__links {
    gap: 28px;
  }

  .nav__link {
    font-size: clamp(28px, 8vw, 40px);
  }

  .nav__link--cta {
    padding: 14px 32px;
    font-size: 13px;
  }

  /* Hero cards — smaller header text */
  .hero-card__header {
    font-size: clamp(14px, 3.5vw, 20px);
    top: 10px;
    left: 12px;
  }

  /* Editorial spread — smaller title */
  .editorial-spread__title {
    font-size: clamp(36px, 10vw, 56px);
  }

  /* Gallery overlay — stack grid */
  .gallery-overlay__grid {
    grid-template-columns: 1fr;
    width: 90%;
  }

  .gallery-overlay__main {
    width: 90%;
  }

  .gallery-overlay__main img {
    height: 40vh;
  }

  /* Infinite gallery — smaller cards */
  .infinite-gallery__title {
    font-size: clamp(20px, 5vw, 28px);
    top: 70px;
  }

  /* Buttons — full width on mobile */
  .btn {
    width: 100%;
    text-align: center;
  }

  .hero__actions .btn {
    width: auto;
  }

  /* CTA title — smaller */
  .cta__title {
    font-size: clamp(40px, 12vw, 64px);
  }

  /* Footer logo — smaller */
  .site-footer__logo {
    font-size: clamp(40px, 10vw, 60px);
  }
}

@media (max-width: 480px) {
  /* Nav menu — tighter */
  .nav__links {
    gap: 24px;
  }

  .nav__link {
    font-size: clamp(24px, 7vw, 32px);
  }

  /* Hero cards — single column on very small screens */
  .hero-cards {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(4, 1fr);
  }

  .hero-card__header {
    font-size: 13px;
  }

  .hero-cards__headline {
    font-size: clamp(36px, 11vw, 52px);
    white-space: normal;
  }

  .hero-cards__paragraph {
    position: static;
    max-width: 100%;
    margin-top: 16px;
    font-size: 13px;
  }

  .hero-cards__footer {
    padding: 0 16px 24px;
  }

  /* Editorial spread — tighter padding */
  .editorial-spread__page--green,
  .editorial-spread__page--blue,
  .editorial-spread__page--brown {
    padding: 32px 20px;
  }

  .editorial-spread__top {
    flex-direction: column;
    gap: 16px;
  }

  .editorial-spread__title {
    font-size: clamp(32px, 9vw, 44px);
  }

  .editorial-spread__desc {
    font-size: 14px;
  }

  .editorial-spread__img-num {
    top: 20px;
    right: 20px;
  }

  .editorial-spread__caption {
    bottom: 20px;
    left: 20px;
    font-size: 9px;
  }

  /* Mega footer — tighter */
  .mega-footer {
    padding: 24px 12px 40px;
  }

  .mega-footer__inner {
    height: 480px;
  }

  .mega-footer__top {
    padding: 16px 20px;
  }

  .mega-footer__contact {
    margin-top: 16px;
    gap: 4px;
  }

  .mega-footer__contact a {
    font-size: 11px;
  }

  .mega-footer__title {
    font-size: clamp(24px, 8.5vw, 40px);
    bottom: 16px;
    left: 16px;
  }

  .mega-footer__subtitle {
    font-size: 13px;
    margin-top: 12px;
  }

  .mega-footer__socials {
    gap: 12px;
    margin-top: 20px;
  }

  .mega-footer__socials a {
    font-size: 11px;
  }

  .mega-footer__bottom {
    padding: 4px 12px;
    gap: 6px;
  }

  .gallery-overlay__grid {
    gap: 8px;
  }

  /* Contact details — tighter */
  .contact-details {
    padding: 24px;
  }

  /* Stats — tighter */
  .stat {
    padding-top: 24px;
  }

  /* Services — tighter */
  .services__item {
    padding-block: 24px;
  }

  .services__item a {
    gap: 16px;
  }

  .services__name {
    font-size: clamp(24px, 6vw, 32px);
  }

  /* Project cards — tighter */
  .project-card__media {
    margin-bottom: 16px;
  }

  .project-card__title {
    font-size: clamp(24px, 6vw, 32px);
  }

  /* Buttons — smaller padding */
  .btn {
    padding: 16px 32px;
    font-size: 13px;
  }

  /* Hero — smaller padding */
  .hero {
    padding-bottom: 48px;
  }

  .hero__title {
    margin-bottom: 20px;
  }

  .hero__intro {
    margin-bottom: 32px;
    font-size: 16px;
  }

  /* Section head — tighter */
  .section-head__title {
    font-size: clamp(28px, 7vw, 40px);
  }

  /* Testimonials — tighter */
  .testimonial {
    padding-block: 24px;
  }

  .testimonial__quote {
    font-size: clamp(22px, 6vw, 30px);
    margin-bottom: 24px;
  }

  /* Next project — tighter */
  .next-project__title {
    font-size: clamp(28px, 7vw, 40px);
  }

  /* Footer meta — stack */
  .site-footer__meta {
    flex-direction: column;
    gap: 8px;
    margin-top: 60px;
    padding-top: 24px;
  }
}
