/* ==========================================================================
   Lumentis Global — design tokens + base styles
   ========================================================================== */

:root {
  --ink: #0E0E0F;
  --paper: #F5F2EC;
  --stone: #9A948A;
  --stone-line: #DAD5CB;
  --clay: #8C5A3C;
  --clay-hover: #6F4630;
  --white: #FFFFFF;

  --font-head: 'Space Grotesk', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Archivo', 'Helvetica Neue', Arial, sans-serif;

  --fs-h1: clamp(2.6rem, 5.4vw, 4.6rem);
  --fs-h2: clamp(1.9rem, 3.6vw, 3.1rem);
  --fs-h3: clamp(1.3rem, 2.2vw, 1.6rem);
  --fs-body: 1rem;
  --fs-small: 0.9rem;
  --fs-caption: 0.75rem;

  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 16px;
  --sp-4: 24px;
  --sp-5: 32px;
  --sp-6: 48px;
  --sp-7: 64px;
  --sp-8: 96px;
  --sp-9: 128px;

  --radius: 2px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --nav-h: 76px;
  --max-w: 1440px;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img, video { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--font-head); font-weight: 300; line-height: 1.1; margin: 0; }
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: inherit; }

/* Image protection — the photography is the commercial asset */
img { -webkit-user-drag: none; user-drag: none; user-select: none; -webkit-touch-callout: none; }

/* Focus visibility */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 3px;
}

/* Skip link */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--paper);
  padding: var(--sp-2) var(--sp-3);
  z-index: 1000;
}
.skip-link:focus { left: var(--sp-3); top: var(--sp-3); }

/* ---- Layout helpers ---- */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 var(--sp-5); }
@media (max-width: 600px) { .container { padding: 0 var(--sp-3); } }

section { padding: var(--sp-8) 0; }
.section-tight { padding: var(--sp-6) 0; }

.eyebrow {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--fs-caption);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--stone);
}

/* ---- Buttons / links ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 14px 28px;
  border: 1px solid var(--ink);
  border-radius: var(--radius);
  font-size: var(--fs-small);
  letter-spacing: 0.02em;
  transition: background var(--ease) 0.25s, color var(--ease) 0.25s, border-color var(--ease) 0.25s;
}
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: var(--clay); border-color: var(--clay); }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { border-color: var(--clay); color: var(--clay); }
.btn-on-dark { border-color: var(--paper); color: var(--paper); }
.btn-on-dark:hover { background: var(--clay); border-color: var(--clay); color: var(--paper); }

.text-link {
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
  transition: color var(--ease) 0.2s;
}
.text-link:hover { color: var(--clay); }

/* ---- Reveal on scroll ---- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ==========================================================================
   Nav
   ========================================================================== */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 500;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  background: rgba(245, 242, 236, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--stone-line);
}
.site-nav.nav-on-dark {
  background: transparent;
  border-bottom-color: transparent;
}
.site-nav.nav-on-dark.nav-scrolled {
  background: rgba(14, 14, 15, 0.92);
  border-bottom-color: rgba(245, 242, 236, 0.14);
}
.nav-inner {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--sp-5);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo-wordmark {
  font-family: var(--font-head);
  font-weight: 300;
  letter-spacing: 0.06em;
  font-size: 1.3rem;
  color: var(--ink);
}
.nav-on-dark .logo-wordmark { color: var(--paper); }

.nav-links { display: flex; gap: var(--sp-6); align-items: center; }
.nav-links a {
  font-size: var(--fs-small);
  letter-spacing: 0.02em;
  padding-bottom: 3px;
  border-bottom: 1px solid transparent;
  transition: border-color var(--ease) 0.2s, color var(--ease) 0.2s;
}
.nav-links a:hover, .nav-links a.active { border-color: currentColor; }
.nav-on-dark .nav-links a { color: var(--paper); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  width: 32px;
  height: 22px;
  position: relative;
}
.nav-toggle span {
  position: absolute;
  left: 0; right: 0;
  height: 1px;
  background: var(--ink);
  transition: transform var(--ease) 0.25s, opacity var(--ease) 0.25s, top var(--ease) 0.25s;
}
.nav-on-dark .nav-toggle span { background: var(--paper); }
.nav-toggle span:nth-child(1) { top: 0; }
.nav-toggle span:nth-child(2) { top: 10px; }
.nav-toggle span:nth-child(3) { top: 20px; }
.nav-open .nav-toggle span:nth-child(1) { top: 10px; transform: rotate(45deg); }
.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
.nav-open .nav-toggle span:nth-child(3) { top: 10px; transform: rotate(-45deg); }

@media (max-width: 880px) {
  .nav-toggle { display: block; z-index: 600; }
  .nav-links {
    position: fixed;
    top: 0; right: 0;
    height: 100vh;
    width: min(340px, 100%);
    background: var(--ink);
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: var(--sp-5);
    padding: var(--sp-6);
    transform: translateX(100%);
    transition: transform 0.35s var(--ease);
  }
  .nav-open .nav-links { transform: translateX(0); }
  .nav-links a { color: var(--paper); font-size: 1.4rem; }
  .site-nav.nav-on-dark:not(.nav-scrolled) .nav-toggle span { background: var(--paper); }
}

/* ==========================================================================
   Hero — no imagery; the wordmark itself is the reveal
   ========================================================================== */
.hero {
  position: relative;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--paper);
  background: var(--ink);
  overflow: hidden;
}
.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 0 var(--sp-5);
  max-width: 900px;
  margin: 0 auto;
}
.hero-tagline { font-size: var(--fs-h3); font-weight: 400; color: var(--paper); opacity: 0.92; max-width: 34ch; margin: 0 auto var(--sp-5); }
.hero-actions { display: flex; gap: var(--sp-3); flex-wrap: wrap; justify-content: center; }
.hero-actions .btn { min-width: 170px; padding: 14px 20px; justify-content: center; }
.hero .eyebrow { color: var(--stone); margin-bottom: var(--sp-4); display: block; letter-spacing: normal; }

.hero-wordmark {
  font-family: var(--font-head);
  font-weight: 300;
  color: var(--paper);
  font-size: clamp(4rem, 14vw, 11rem);
  line-height: 1;
  margin: 0 0 var(--sp-5);
  opacity: 0;
  animation: heroWordmarkReveal 1.5s cubic-bezier(0.16, 1, 0.3, 1) 0.2s forwards;
}

@keyframes heroWordmarkReveal {
  0% { opacity: 0; letter-spacing: 0.4em; transform: translateY(12px); }
  100% { opacity: 1; letter-spacing: 0.06em; transform: translateY(0); }
}

.hero-reveal { opacity: 0; animation: heroFadeUp 0.9s var(--ease) forwards; }
.hero-reveal.d1 { animation-delay: 0.9s; }
.hero-reveal.d2 { animation-delay: 1.15s; }
.hero-reveal.d3 { animation-delay: 1.4s; }

@keyframes heroFadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-wordmark, .hero-reveal {
    animation: none;
    opacity: 1;
    letter-spacing: 0.06em;
    transform: none;
  }
}

/* Interior page hero (shorter, for Work/Services/About/Contact) */
.page-hero {
  padding: calc(var(--nav-h) + var(--sp-8)) 0 var(--sp-6);
  border-bottom: 1px solid var(--stone-line);
}
.page-hero h1 { max-width: 18ch; }
.page-hero .lede { font-size: var(--fs-h3); font-weight: 400; color: var(--stone); max-width: 46ch; margin-top: var(--sp-4); }

/* ==========================================================================
   Service highlights (home)
   ========================================================================== */
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-5);
}
.service-card {
  display: block;
  border-top: 1px solid var(--ink);
  padding-top: var(--sp-4);
}
.service-card .eyebrow { margin-bottom: var(--sp-3); }
.service-card h3 { margin-bottom: var(--sp-2); transition: color var(--ease) 0.2s; }
.service-card p { color: var(--stone); }
.service-card:hover h3 { color: var(--clay); }
@media (max-width: 880px) { .service-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .service-grid { grid-template-columns: 1fr; gap: var(--sp-6); } }

/* ==========================================================================
   Section heads (home teasers, What We Do intro)
   ========================================================================== */
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: var(--sp-4);
  margin-bottom: var(--sp-6);
}
.section-head h2 { max-width: 20ch; }
.section-head h2 a { transition: color var(--ease) 0.2s; }
.section-head h2 a:hover { color: var(--clay); }

/* ==========================================================================
   Carousel (What We Do — one per service). Auto-scrolls, pauses on
   hover/focus, and can be dragged left/right by hand (mouse click-and-hold
   or touch) — all driven from one JS position in initCarouselDrag().
   ========================================================================== */
.carousel {
  overflow: hidden;
  margin-top: var(--sp-5);
  background: var(--stone-line);
  cursor: grab;
  touch-action: pan-y;
}
.carousel.dragging { cursor: grabbing; user-select: none; }
.carousel-track {
  display: flex;
  gap: var(--sp-3);
  width: max-content;
  will-change: transform;
}
.carousel-item { flex-shrink: 0; width: 280px; height: 350px; }
.carousel-item img, .carousel-item video { width: 100%; height: 100%; object-fit: cover; }
.carousel-item img { pointer-events: none; }

@media (prefers-reduced-motion: reduce) {
  .carousel { overflow-x: auto; cursor: auto; touch-action: auto; }
}
@media (max-width: 600px) {
  .carousel-item { width: 200px; height: 250px; }
}

/* ==========================================================================
   Instagram placeholder grid
   ========================================================================== */
.insta-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--sp-2);
}
.insta-grid a { aspect-ratio: 1 / 1; overflow: hidden; display: block; }
.insta-grid img { width: 100%; height: 100%; object-fit: cover; transition: opacity var(--ease) 0.2s; }
.insta-grid a:hover img { opacity: 0.8; }
@media (max-width: 600px) { .insta-grid { grid-template-columns: repeat(2, 1fr); } }

/* ==========================================================================
   CTA band
   ========================================================================== */
.cta-band { background: var(--ink); color: var(--paper); text-align: center; }
.cta-band h2 { max-width: 22ch; margin: 0 auto var(--sp-5); }

/* ==========================================================================
   What We Do — one block per service, each with a full-bleed carousel
   ========================================================================== */
.wwd-block {
  padding: var(--sp-9) 0;
  border-top: 1px solid var(--stone-line);
  scroll-margin-top: calc(var(--nav-h) + var(--sp-4));
}
.wwd-block h3 { margin-bottom: var(--sp-3); max-width: 26ch; }
.wwd-block p { color: var(--stone); max-width: 68ch; }

/* ==========================================================================
   Prose blocks (About page copy, "draft copy" flags on What We Do)
   ========================================================================== */
.bio-copy p { color: var(--stone); max-width: 62ch; margin-bottom: var(--sp-3); }
.bio-copy p:last-child { margin-bottom: 0; }
.bio-pending { display: inline-block; margin-top: var(--sp-3); font-size: var(--fs-caption); color: var(--clay); border: 1px dashed var(--clay); padding: 4px 10px; }

/* ==========================================================================
   Contact page — direct details, no form
   ========================================================================== */
.contact-details { max-width: 480px; margin: 0 auto; }
.contact-details .detail-item { margin-bottom: var(--sp-5); }
.contact-details .eyebrow { display: block; margin-bottom: var(--sp-1); }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--ink);
  color: var(--paper);
  padding: var(--sp-7) 0 var(--sp-5);
}
.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: var(--sp-6);
  padding-bottom: var(--sp-6);
  border-bottom: 1px solid rgba(245, 242, 236, 0.16);
}
.footer-top .logo-wordmark { color: var(--paper); font-size: 1.4rem; }
.footer-links { display: flex; gap: var(--sp-7); flex-wrap: wrap; }
.footer-col h4 { font-size: var(--fs-caption); text-transform: uppercase; letter-spacing: 0.12em; color: var(--stone); margin-bottom: var(--sp-3); }
.footer-col a, .footer-col span { display: block; font-size: var(--fs-small); margin-bottom: var(--sp-2); color: var(--paper); }
.footer-col a:hover { color: var(--clay); }
.footer-col a.footer-social { display: inline-flex; align-items: center; gap: 6px; }
.footer-social svg { flex-shrink: 0; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--sp-2);
  padding-top: var(--sp-5);
  font-size: var(--fs-caption);
  color: var(--stone);
}

/* ==========================================================================
   Watermark overlay (?wip=1)
   ========================================================================== */
.wm-wrap { position: relative; }
body.watermark-on .wm-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.16;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='420' height='140'%3E%3Ctext x='0' y='40' font-family='Arial' font-size='20' fill='%23F5F2EC' transform='rotate(-18 210 70)'%3ELUMENTIS GLOBAL: WORK IN PROGRESS%3C/text%3E%3C/svg%3E");
  background-repeat: repeat;
}
