/* ============================================================
   Blank Space Design — Website v2
   A bolder editorial take on the studio system: oversized
   Cormorant display, layered imagery, hairline structure,
   split-center navigation, espresso bands for rhythm.
   ============================================================ */

/* Fonts are loaded by a <link> in each page's <head> (faster than @import) */

:root {
  --espresso:      #584F46;
  --espresso-deep: #3F3833;
  --espresso-warm: #6E6356;
  --sage:          #918D75;
  --taupe:         #B4957E;

  --paper:      #F3EFE8;
  --paper-2:    #FBF9F5;
  --paper-cool: #ECEBE6;
  --ink-bg:     #2E2A25;

  --line:         rgba(88, 79, 70, 0.16);
  --line-strong:  rgba(88, 79, 70, 0.30);
  --line-on-dark: rgba(243, 239, 232, 0.18);

  --accent: var(--sage);

  --fg-1: var(--espresso);
  --fg-2: var(--espresso-deep);
  --fg-3: rgba(63, 56, 51, 0.60);

  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans:  "Jost", "Helvetica Neue", Arial, sans-serif;

  --pad-x: clamp(24px, 6vw, 110px);
  --section-y: clamp(84px, 12vw, 184px);
  --maxw: 1400px;

  --tracking-eyebrow: 0.28em;
  --tracking-label: 0.16em;

  --radius-img: 2px;
  --shadow-float: 0 40px 80px -44px rgba(46, 42, 37, 0.55);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --nav-h: 92px;
}

html[data-accent="sage"]     { --accent: var(--sage); }
html[data-accent="taupe"]    { --accent: var(--taupe); }
html[data-accent="espresso"] { --accent: var(--espresso-warm); }

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: clip; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--fg-2);
  font-family: var(--sans);
  font-weight: 300;
  font-size: 17.5px;
  line-height: 1.64;
  letter-spacing: 0.005em;
  overflow-x: clip;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
::selection { background: var(--accent); color: var(--paper-2); }

/* ---------- Type ---------- */
.eyebrow {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 0.8em;
}
.eyebrow::before { content: ""; width: 30px; height: 1px; background: currentColor; opacity: 0.7; }
.eyebrow.no-rule::before { display: none; }
.eyebrow .sep { opacity: 0.55; }

.display {
  font-family: var(--serif);
  font-weight: 300;
  line-height: 0.97;
  letter-spacing: 0.002em;
  color: var(--fg-1);
  margin: 0;
  font-size: clamp(48px, 8.8vw, 150px);
  text-wrap: balance;
}
.display em, .title em, .subtitle em { font-style: italic; color: var(--accent); }

.title {
  font-family: var(--serif);
  font-weight: 300;
  line-height: 1.02;
  color: var(--fg-1);
  margin: 0;
  font-size: clamp(36px, 5.4vw, 76px);
  text-wrap: balance;
}

.subtitle {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(26px, 3.2vw, 40px);
  line-height: 1.14;
  color: var(--fg-1);
  margin: 0;
}

.lead {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(21px, 2.4vw, 30px);
  line-height: 1.42;
  color: var(--accent);
  margin: 0;
  text-wrap: balance;
}

.body-lg { font-size: clamp(17.5px, 1.4vw, 20px); line-height: 1.7; color: var(--fg-2); }
.muted { color: var(--fg-3); }
p { margin: 0 0 1.15em; max-width: 60ch; }
p:last-child { margin-bottom: 0; }

.label {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 11.5px;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--accent);
}

.vcap {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--sans);
  font-weight: 400;
  font-size: 10.5px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--fg-3);
}

/* ---------- Layout ---------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--pad-x); }
.section { padding-block: var(--section-y); }
.hr { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ---------- Buttons & links ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.9em;
  font-family: var(--sans);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  padding: 18px 32px;
  border: 1px solid var(--espresso);
  color: var(--espresso);
  background: transparent;
  cursor: pointer;
  transition: background 0.5s var(--ease), color 0.5s var(--ease), border-color 0.5s var(--ease);
}
.btn .arrow { transition: transform 0.5s var(--ease); }
.btn:hover { background: var(--espresso); color: var(--paper); }
.btn:hover .arrow { transform: translateX(5px); }
.btn--solid { background: var(--espresso); color: var(--paper); }
.btn--solid:hover { background: var(--espresso-deep); }
.btn--light { border-color: rgba(243,239,232,0.5); color: var(--paper-2); }
.btn--light:hover { background: var(--paper-2); color: var(--espresso); border-color: var(--paper-2); }

.link-underline {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-family: var(--sans);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--fg-1);
  padding-bottom: 5px;
  position: relative;
}
.link-underline::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: var(--accent);
}
.link-underline .arrow { transition: transform 0.5s var(--ease); }
.link-underline:hover .arrow { transform: translateX(5px); }

/* ---------- Frames ---------- */
.frame { position: relative; overflow: hidden; border-radius: var(--radius-img); background: var(--paper-cool); }
.frame img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.frame.zoom:hover img { transform: scale(1.045); }

/* ---------- Header (split-center) ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 60;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  transition: background 0.5s var(--ease), backdrop-filter 0.5s var(--ease), box-shadow 0.5s var(--ease), height 0.4s var(--ease);
}
.site-header .bar {
  width: 100%;
  padding-inline: var(--pad-x);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}
.nav-side { display: flex; align-items: center; gap: clamp(24px, 3.2vw, 52px); }
.nav-side.right { justify-content: flex-end; }
.nav-a {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 12.5px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--fg-1);
  opacity: 0.85;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 8px 0;
  transition: opacity 0.4s var(--ease);
}
.nav-a .dot { width: 4px; height: 4px; border-radius: 50%; background: var(--accent); opacity: 0; transform: scale(0.4); transition: opacity 0.4s var(--ease), transform 0.4s var(--ease); }
.nav-a:hover { opacity: 1; }
.nav-a:hover .dot, .nav-a.active .dot { opacity: 1; transform: none; }
.nav-a.active { opacity: 1; }
/* Client login: an outlined button at the end of the right-hand menu */
.nav-a.nav-client { border: 1px solid currentColor; padding: 9px 16px; opacity: 1; transition: background 0.4s var(--ease), color 0.4s var(--ease), border-color 0.4s var(--ease); }
.nav-a.nav-client:hover { background: var(--espresso); border-color: var(--espresso); color: var(--paper); }
.brand { justify-self: center; }
.brand img { height: 32px; width: auto; transition: filter 0.4s var(--ease); }

.site-header.scrolled {
  background: rgba(243, 239, 232, 0.88);
  backdrop-filter: blur(14px) saturate(1.05);
  box-shadow: 0 1px 0 var(--line);
  height: 70px;
}
.site-header.on-dark:not(.scrolled) .nav-a { color: var(--paper-2); }
.site-header.on-dark:not(.scrolled) .brand img { filter: brightness(0) invert(1); }
.site-header.on-dark:not(.scrolled) .nav-toggle span { background: var(--paper-2); }
.site-header.on-dark:not(.scrolled) .nav-a.nav-client:hover { background: var(--paper-2); border-color: var(--paper-2); color: var(--espresso); }
.site-header.on-dark:not(.scrolled) .nav-a .dot { background: var(--paper-2); }

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; justify-self: end; }
.nav-toggle span { display: block; width: 25px; height: 1.5px; background: var(--fg-1); transition: transform 0.4s var(--ease), opacity 0.3s var(--ease); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 55;
  background: var(--paper);
  display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
  gap: 4px; padding: 0 9vw;
  transform: translateY(-100%);
  visibility: hidden; /* keeps closed-menu links out of the tab order */
  transition: transform 0.6s var(--ease), visibility 0s linear 0.6s;
}
.mobile-menu.open { transform: translateY(0); visibility: visible; transition: transform 0.6s var(--ease); }
.mobile-menu a { font-family: var(--serif); font-size: clamp(36px, 9vw, 58px); font-weight: 300; color: var(--fg-1); padding: 9px 0; }
.mobile-menu a em { font-style: italic; color: var(--accent); }
.mobile-menu .mm-client { display: inline-flex; align-items: center; gap: 0.8em; margin-top: 22px; padding: 22px 0 0; border-top: 1px solid var(--line-strong); font-family: var(--sans); font-size: 13px; font-weight: 500; letter-spacing: 0.15em; text-transform: uppercase; color: var(--fg-1); }
.mobile-menu .mm-meta { margin-top: 36px; font-family: var(--sans); font-size: 13px; letter-spacing: 0.1em; color: var(--fg-3); }
body.menu-open { overflow: hidden; }
/* Open phone menu sits on a light background: show the logo and menu icon dark, also on pages with a photo header */
body.menu-open .site-header.on-dark .brand img { filter: none; }
body.menu-open .site-header.on-dark .nav-toggle span { background: var(--fg-1); }

/* ---------- Skip link ---------- */
.skip-link {
  position: fixed; top: 12px; left: 12px; z-index: 80;
  padding: 12px 20px;
  background: var(--espresso); color: var(--paper);
  font-family: var(--sans); font-weight: 500; font-size: 12px;
  letter-spacing: var(--tracking-label); text-transform: uppercase;
  transform: translateY(-160%);
  transition: transform 0.3s var(--ease);
}
.skip-link:focus { transform: none; }

:focus-visible { outline: 1px solid var(--accent); outline-offset: 4px; }

/* ---------- Next-page link ---------- */
.next-page { border-top: 1px solid var(--line); }
.next-page a {
  display: flex; justify-content: space-between; align-items: baseline; gap: 24px;
  padding: clamp(40px, 5vw, 64px) 0;
}
.next-page .k { font-size: 11.5px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--fg-3); }
.next-page .n { font-family: var(--serif); font-weight: 300; font-size: clamp(34px, 4.6vw, 64px); color: var(--fg-1); line-height: 1; transition: color 0.4s var(--ease); }
.next-page .n em { font-style: italic; color: var(--accent); }
.next-page a:hover .n { color: var(--accent); }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink-bg); color: var(--paper); }
.site-footer a { color: var(--paper); }
.footer-cta {
  padding-block: clamp(72px, 9vw, 130px) clamp(56px, 7vw, 96px);
  border-bottom: 1px solid var(--line-on-dark);
}
.footer-cta .eyebrow { color: var(--taupe); }
.footer-cta h2 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(40px, 6.4vw, 96px);
  line-height: 1.0;
  color: var(--paper-2);
  margin: 26px 0 0;
  max-width: 14ch;
  text-wrap: balance;
}
.footer-cta h2 em { font-style: italic; color: var(--taupe); }
.footer-cta .row { display: flex; justify-content: space-between; align-items: flex-end; gap: 36px; flex-wrap: wrap; margin-top: clamp(30px, 4vw, 48px); }
.footer-cta .row p { color: rgba(243,239,232,0.75); max-width: 40ch; font-size: 16px; }

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: clamp(40px, 6vw, 96px);
  padding-block: clamp(48px, 6vw, 72px);
}
.footer-brand img { height: 34px; filter: brightness(0) invert(1); opacity: 0.94; }
.footer-brand p { margin-top: 22px; font-size: 14.5px; color: rgba(243,239,232,0.6); max-width: 30ch; }
.footer-col h4 { font-family: var(--sans); font-weight: 500; font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--taupe); margin: 4px 0 24px; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 13px; }
.footer-col ul a, .footer-col ul span { font-size: 15px; letter-spacing: 0.03em; color: rgba(243,239,232,0.82); transition: color 0.4s var(--ease); }
.footer-col ul a:hover { color: var(--paper-2); }

.footer-bottom {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 18px;
  padding-block: 26px 34px;
  border-top: 1px solid var(--line-on-dark);
  font-size: 12px; letter-spacing: 0.08em;
  color: rgba(243,239,232,0.55);
}
.social-row { display: flex; gap: 12px; align-items: center; }
.social-row a { width: 38px; height: 38px; border: 1px solid var(--line-on-dark); border-radius: 50%; display: grid; place-items: center; transition: background 0.4s var(--ease), border-color 0.4s var(--ease); }
.social-row a:hover { background: rgba(243,239,232,0.1); border-color: rgba(243,239,232,0.4); }
.social-row img { width: 15px; height: 15px; filter: brightness(0) invert(1); opacity: 0.85; }
.to-top { background: none; border: 0; cursor: pointer; font-family: var(--sans); font-size: 11.5px; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(243,239,232,0.7); padding: 6px 0; transition: color 0.4s var(--ease); }
.to-top:hover { color: var(--paper-2); }

/* ---------- Reveals ----------
   Gated on html.js (set inline in each <head>) so content stays
   visible if scripts fail to load. */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 1.05s var(--ease), transform 1.05s var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}
.js [data-reveal].in { opacity: 1; transform: none; }
.js [data-reveal-img] { clip-path: inset(0 0 100% 0); transition: clip-path 1.25s var(--ease); transition-delay: var(--reveal-delay, 0ms); }
.js [data-reveal-img].in { clip-path: inset(0 0 0 0); }

html.no-motion [data-reveal],
html.no-motion [data-reveal-img] { opacity: 1 !important; transform: none !important; clip-path: none !important; transition: none !important; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  [data-reveal], [data-reveal-img] { opacity: 1 !important; transform: none !important; clip-path: none !important; transition: none !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
  .site-header .bar { display: flex; justify-content: space-between; }
  .nav-side { display: none; }
  .brand { justify-self: start; }
  .nav-toggle { display: flex; }
}
@media (max-width: 860px) {
  .footer-grid { grid-template-columns: 1fr; gap: 44px; }
}
