/* KDJ Cabinet Design, homepage concept
   Language: Heritage Craft (#12) for type/spacing/composition/motion ONLY.
   Palette: prospect-derived. Near-black espresso from their logo's black +
   warm walnut/tan from their logo's light brown and their project photography.
   Parchment lights keep the monochrome-with-wood character of their brand. */

:root {
  --bg-dark: #211a12;
  --bg-dark-2: #2b2117;
  --bg-light: #f2ebdf;
  --bg-white: #faf6ee;

  --accent: #b98a52;
  --accent-deep: #7a5327;
  --accent-on-dark: #d3a76c;
  --accent-muted: rgba(185, 138, 82, 0.22);

  --text-dark: #241c12;
  --text-body: #57493a;
  --text-muted: #6f6151;
  --text-light: #f6f1e7;
  --text-light-muted: rgba(246, 241, 231, 0.66);

  --font-display: 'EB Garamond', Georgia, serif;
  --font-body: 'Karla', 'Helvetica Neue', sans-serif;

  --wrap: min(90%, 1100px);
  --wrap-narrow: min(85%, 900px);
  --gutter: clamp(1.5rem, 4vw, 3rem);
  --nav-height: 80px;

  --ease-out: cubic-bezier(0.4, 0, 0.2, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  font-weight: 300;
  color: var(--text-body);
  background: var(--bg-white);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

.wrap { width: var(--wrap); margin-inline: auto; }

.eyebrow {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin-bottom: 1.1rem;
}
.section-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 4.4vw, 3.2rem);
  line-height: 1.12;
  color: var(--text-dark);
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
}
.section-title--light { color: var(--text-light); }

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 60;
  transition: background 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}
.nav__inner {
  width: var(--wrap);
  margin-inline: auto;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.nav__brand { display: flex; align-items: center; gap: 0.7rem; }
.nav__logo { width: auto; height: 40px; max-width: 120px; object-fit: contain; }
.nav__name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--text-light);
  letter-spacing: 0.02em;
  transition: color 0.35s var(--ease-out);
}
.nav__name em { font-style: italic; color: #f0e2c8; transition: color 0.35s var(--ease-out); }
.nav__links { display: flex; align-items: center; gap: clamp(1.2rem, 2.4vw, 2.2rem); }
.nav__link {
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: rgba(246, 241, 231, 0.85);
  transition: color 0.25s var(--ease-out);
}
.nav__link:hover { color: var(--accent-on-dark); }
.nav__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem 0.6rem 0.55rem 1.2rem;
  border-radius: 999px;
  background: var(--accent-deep);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  transition: background 0.25s var(--ease-out);
}
.nav__cta:hover { background: var(--accent); }
.nav__cta-icon {
  width: 26px; height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  display: grid; place-items: center;
}
.nav__cta-icon svg { width: 13px; height: 13px; }
.nav.scrolled { background: rgba(250, 246, 238, 0.96); box-shadow: 0 1px 0 rgba(36, 28, 18, 0.08); backdrop-filter: blur(8px); }
.nav.scrolled .nav__name { color: var(--text-dark); }
.nav.scrolled .nav__name em { color: var(--accent-deep); }
.nav.scrolled .nav__link { color: var(--text-body); }
.nav.scrolled .nav__link:hover { color: var(--accent-deep); }

.nav__burger {
  display: none;
  width: 44px; height: 44px;
  background: none; border: 0; cursor: pointer;
  position: relative;
  z-index: 70;
}
.nav__burger span {
  position: absolute;
  left: 10px; right: 10px;
  height: 2px;
  background: var(--text-light);
  transition: transform 0.3s var(--ease-out), top 0.3s var(--ease-out), background 0.3s var(--ease-out);
}
.nav__burger span:nth-child(1) { top: 18px; }
.nav__burger span:nth-child(2) { top: 26px; }
.nav.scrolled .nav__burger span { background: var(--text-dark); }
.nav__burger.open span { background: var(--text-light); }
.nav__burger.open span:nth-child(1) { top: 22px; transform: rotate(45deg); }
.nav__burger.open span:nth-child(2) { top: 22px; transform: rotate(-45deg); }

/* ---------- Mobile menu ---------- */
.menu {
  position: fixed;
  inset: 0;
  z-index: 55;
  background: var(--bg-dark);
  display: grid;
  place-items: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s var(--ease-out), visibility 0.35s;
}
.menu.open { opacity: 1; visibility: visible; }
.menu__inner { text-align: center; padding: 2rem; }
.menu__link {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2rem, 8vw, 2.8rem);
  color: var(--text-light);
  padding: 0.45rem 0;
  transition: color 0.25s var(--ease-out);
}
.menu__link:hover { color: var(--accent-on-dark); }
.menu__divider {
  width: 56px; height: 1px;
  background: var(--accent);
  margin: 1.4rem auto;
}
.menu__cta {
  display: inline-block;
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-on-dark);
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 0.9rem 2rem;
}
.menu__phone { margin-top: 1.2rem; color: var(--text-light-muted); font-size: 0.95rem; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}
.hero__media { position: absolute; inset: 0; }
.hero__img { width: 100%; height: 100%; object-fit: cover; object-position: center 62%; }
.hero__scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(to bottom, rgba(24, 17, 10, 0.72) 0%, rgba(24, 17, 10, 0.38) 12%, rgba(24, 17, 10, 0) 26%),
    linear-gradient(to top, rgba(24, 17, 10, 0.88) 0%, rgba(24, 17, 10, 0.45) 34%, rgba(24, 17, 10, 0.05) 62%, rgba(24, 17, 10, 0) 78%);
}
.hero__content {
  position: relative;
  z-index: 2;
  width: var(--wrap);
  margin-inline: auto;
  padding-bottom: clamp(4.5rem, 10vh, 7rem);
}
.hero__eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: #f0e2c8;
  background: rgba(24, 17, 10, 0.55);
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  margin-bottom: 1.2rem;
}
.hero__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.6rem, 6.4vw, 5rem);
  line-height: 1.05;
  color: var(--text-light);
  max-width: 13ch;
  margin-bottom: 1.3rem;
}
.hero__sub {
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  color: rgba(246, 241, 231, 0.88);
  max-width: 46ch;
  margin-bottom: 2rem;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.9rem; }
.hero__caption {
  position: absolute;
  z-index: 2;
  right: var(--gutter);
  bottom: 1.1rem;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: rgba(246, 241, 231, 0.6);
}

/* ---------- Buttons ---------- */
.btn-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.7rem 0.7rem 0.7rem 1.5rem;
  border-radius: 999px;
  background: var(--accent-deep);
  color: #fff;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  transition: background 0.25s var(--ease-out), transform 0.25s var(--ease-out);
}
.btn-pill:hover { background: var(--accent); }
.btn-pill__icon {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  display: grid; place-items: center;
  transition: transform 0.3s var(--ease-out);
}
.btn-pill:hover .btn-pill__icon { transform: rotate(360deg); }
.btn-pill__icon svg { width: 15px; height: 15px; }
.btn-pill--ghost {
  background: transparent;
  border: 1px solid rgba(246, 241, 231, 0.55);
  color: var(--text-light);
}
.btn-pill--ghost:hover { background: rgba(246, 241, 231, 0.12); }
.btn-pill--ghost .btn-pill__icon { background: rgba(246, 241, 231, 0.14); }
.btn-pill--dark { background: var(--bg-dark); }
.btn-pill--dark:hover { background: var(--bg-dark-2); }
.btn-pill--light { background: var(--bg-white); color: var(--text-dark); }
.btn-pill--light:hover { background: var(--bg-light); }
.btn-pill--light .btn-pill__icon { background: var(--accent-muted); color: var(--accent-deep); }
.btn-pill--ghostlight {
  background: transparent;
  border: 1px solid rgba(246, 241, 231, 0.5);
  color: var(--text-light);
}
.btn-pill--ghostlight:hover { background: rgba(246, 241, 231, 0.1); }
.btn-pill--ghostlight .btn-pill__icon { background: rgba(246, 241, 231, 0.14); }

/* ---------- Intro ---------- */
.intro {
  background: var(--bg-dark);
  padding-block: clamp(4rem, 8vw, 6.5rem);
}
.intro__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}
.intro .eyebrow { color: var(--accent-on-dark); }
.intro__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 4.2vw, 3.1rem);
  line-height: 1.14;
  color: var(--text-light);
}
.intro__title em { font-style: italic; color: var(--accent-on-dark); }
.intro__right p { color: var(--text-light-muted); margin-bottom: 1.1rem; font-size: 1.02rem; }
.intro__license {
  font-size: 0.8rem !important;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-on-dark) !important;
  padding-top: 0.6rem;
  border-top: 1px solid rgba(211, 167, 108, 0.3);
}

/* ---------- Heritage strip ---------- */
.heritage {
  background: var(--bg-dark-2);
  padding-block: clamp(3rem, 6vw, 4.5rem);
  border-top: 1px solid rgba(211, 167, 108, 0.16);
}
.heritage__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.5rem, 4vw, 3rem);
}
.heritage__item { text-align: center; }
.heritage__num {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 5vw, 3.8rem);
  line-height: 1;
  color: var(--accent-on-dark);
  margin-bottom: 0.7rem;
}
.heritage__label {
  font-size: 0.9rem;
  color: var(--text-light-muted);
  max-width: 30ch;
  margin-inline: auto;
}

/* ---------- Services ---------- */
.services {
  background: var(--bg-light);
  padding-block: clamp(4.5rem, 8vw, 7rem) clamp(3rem, 6vw, 5rem);
}
.service {
  width: var(--wrap);
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(1.8rem, 4.5vw, 4rem);
  align-items: center;
  padding-block: clamp(2.2rem, 5vw, 3.6rem);
}
.service--flip .service__media { order: 2; }
.service--flip .service__body { order: 1; }
.service__media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 4px;
  box-shadow: 0 24px 60px -24px rgba(36, 28, 18, 0.45);
}
.service__num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--accent-deep);
  margin-bottom: 0.6rem;
}
.service__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  color: var(--text-dark);
  margin-bottom: 1rem;
}
.service__text { font-size: 1.02rem; max-width: 46ch; }

/* ---------- Full bleed ---------- */
.fullbleed { line-height: 0; }
.fullbleed__img {
  width: 100%;
  height: clamp(320px, 62vh, 560px);
  object-fit: cover;
}

/* ---------- Gallery rail ---------- */
.gallery {
  background: var(--bg-white);
  padding-block: clamp(4.5rem, 8vw, 7rem);
  overflow: hidden;
}
.gallery__hint {
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: -1.6rem;
  margin-bottom: 2.2rem;
}
.gallery__rail {
  display: flex;
  gap: clamp(1rem, 2.4vw, 1.8rem);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-inline: max(calc((100vw - min(90vw, 1100px)) / 2), var(--gutter));
  padding-bottom: 1rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  cursor: grab;
}
.gallery__rail::-webkit-scrollbar { display: none; }
.gallery__rail.dragging { cursor: grabbing; scroll-snap-type: none; }
.gallery__card {
  flex: 0 0 min(78vw, 460px);
  scroll-snap-align: start;
}
.gallery__card img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 4px;
  pointer-events: none;
}
.gallery__card figcaption {
  padding-top: 0.8rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}

/* ---------- Reviews ---------- */
.reviews {
  background: var(--bg-dark);
  padding-block: clamp(4.5rem, 8vw, 7rem);
}
.reviews .eyebrow { color: var(--accent-on-dark); }
.reviews__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.5rem, 3.5vw, 2.6rem);
}
.review {
  border-top: 1px solid rgba(211, 167, 108, 0.35);
  padding-top: 1.6rem;
}
.review__quote {
  font-family: var(--font-display);
  font-size: 1.12rem;
  line-height: 1.55;
  color: var(--text-light);
  margin-bottom: 1.3rem;
}
.review__by {
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-on-dark);
}
.review__by span { color: var(--text-light-muted); font-weight: 300; text-transform: none; letter-spacing: 0.02em; }

/* ---------- Story / process ---------- */
.story {
  background: var(--bg-light);
  padding-block: clamp(4.5rem, 8vw, 7rem);
}
.story__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
.story__media img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 4px;
  box-shadow: 0 24px 60px -24px rgba(36, 28, 18, 0.4);
}
.story__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.12;
  color: var(--text-dark);
  margin-bottom: 1.4rem;
}
.story__title em { font-style: italic; color: var(--accent-deep); }
.story__body p { margin-bottom: 1.1rem; font-size: 1.02rem; max-width: 52ch; }
.story__body .btn-pill { margin-top: 0.8rem; }

/* ---------- CTA ---------- */
.cta {
  background: var(--bg-dark-2);
  padding-block: clamp(4.5rem, 9vw, 7.5rem);
  text-align: center;
}
.cta .eyebrow { color: var(--accent-on-dark); }
.cta__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  color: var(--text-light);
  margin-bottom: 1.2rem;
}
.cta__sub {
  color: var(--text-light-muted);
  max-width: 52ch;
  margin: 0 auto 2.2rem;
  font-size: 1.05rem;
}
.cta__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.9rem;
  margin-bottom: 2rem;
}
.cta__addr {
  font-size: 0.85rem;
  color: var(--text-light-muted);
  letter-spacing: 0.03em;
}

/* ---------- Footer ---------- */
.footer {
  background: var(--bg-dark);
  padding-block: clamp(3rem, 6vw, 4.5rem) 2rem;
}
.footer__grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4rem);
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(246, 241, 231, 0.12);
}
.footer__logo { width: auto; height: 52px; max-width: 160px; object-fit: contain; margin-bottom: 1rem; }
.footer__name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--text-light);
  margin-bottom: 0.5rem;
}
.footer__tag { font-size: 0.9rem; color: var(--text-light-muted); max-width: 36ch; }
.footer__head {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-on-dark);
  margin-bottom: 0.9rem;
}
.footer__link {
  display: block;
  font-size: 0.92rem;
  color: var(--text-light-muted);
  padding-block: 0.3rem;
  transition: color 0.25s var(--ease-out);
}
.footer__link:hover { color: var(--accent-on-dark); }
.footer__text { font-size: 0.92rem; color: var(--text-light-muted); padding-top: 0.4rem; }
.footer__base { padding-top: 1.6rem; }
.footer__base p { font-size: 0.78rem; color: rgba(246, 241, 231, 0.6); }

/* ---------- Reveal animation base ---------- */
.reveal { opacity: 0; transform: translateY(28px); }
html.no-js .reveal, html.no-js .reveal-hero { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .nav__links { display: none; }
  .nav__burger { display: block; }
  .intro__grid,
  .story__grid { grid-template-columns: 1fr; }
  .service { grid-template-columns: 1fr; }
  .service--flip .service__media { order: 0; }
  .service--flip .service__body { order: 1; }
  .reviews__grid { grid-template-columns: 1fr; }
  .heritage__grid { grid-template-columns: 1fr; gap: 2rem; }
  .footer__grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .hero {
    height: auto;
    min-height: 100svh;
    padding-top: 6rem;
  }
  .hero__content { padding-bottom: 4rem; }
  .hero__caption { display: none; }
  .footer__link { padding-block: 0.65rem; }
}

@media (max-width: 480px) {
  .hero { padding-top: 5rem; }
  .hero__actions .btn-pill { width: 100%; justify-content: space-between; }
  .cta__actions .btn-pill { width: 100%; justify-content: space-between; }
  .gallery__card { flex-basis: 82vw; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal, .reveal-hero { opacity: 1 !important; transform: none !important; }
}
