/* ===========================================================================
 * Meridian Blocks — "Celestial cartography"
 * Dark, editorial, high-contrast serif + mono coordinates.
 * ======================================================================== */
:root {
  --bg: #0c0a08;
  --bg-2: #141110;
  --panel: #17130f;
  --bone: #ece6d9;
  --bone-dim: #b9b2a4;
  --muted: #8a847a;
  --line: rgba(236, 230, 217, .12);
  --line-2: rgba(236, 230, 217, .07);
  --amber: #e2b25f;
  --amber-soft: #d9b978;
  --amber-deep: #a9803a;
  --maxw: 1180px;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --mono: "Space Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--bone);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; font-weight: 400; }
::selection { background: rgba(226, 178, 95, .28); color: #fff; }

/* Film grain overlay for tactile depth */
.grain {
  position: fixed; inset: 0; z-index: 100; pointer-events: none; opacity: .5; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.4'/%3E%3C/svg%3E");
}

/* Coordinate label — the recurring cartographic device */
.coord { font-family: var(--mono); font-size: 11px; font-weight: 400; letter-spacing: .16em; color: var(--amber); margin: 0 0 20px; }
.coord.light { color: var(--amber-soft); }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 10px; font-family: var(--sans); font-weight: 600; font-size: 14px; letter-spacing: .01em;
  border-radius: 2px; padding: 13px 20px; border: 1px solid var(--line); transition: border-color .25s, background .25s, color .25s, transform .25s; }
.btn .arr { transition: transform .25s; }
.btn:hover .arr { transform: translateX(4px); }
.btn-solid { background: var(--amber); color: #17120a; border-color: var(--amber); font-weight: 700; }
.btn-solid:hover { background: var(--amber-soft); }
.btn-line { background: transparent; color: var(--bone); }
.btn-line:hover { border-color: var(--bone-dim); }
.btn.big { padding: 16px 26px; font-size: 15px; }
.btn:focus-visible, a:focus-visible, button:focus-visible { outline: 1px solid var(--amber); outline-offset: 4px; }

/* Brand */
.brand { display: inline-flex; align-items: center; gap: 12px; font-weight: 600; font-size: 16px; letter-spacing: .01em; color: var(--bone); }
.mark { width: 26px; height: 26px; color: var(--amber); }

/* Nav */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 40; display: flex; align-items: center; gap: 26px;
  padding: 22px max(24px, calc((100vw - var(--maxw)) / 2)); transition: background .3s, backdrop-filter .3s, border-color .3s; border-bottom: 1px solid transparent; }
.nav.scrolled { background: rgba(12, 10, 8, .72); backdrop-filter: blur(14px) saturate(1.2); border-bottom-color: var(--line-2); padding-top: 15px; padding-bottom: 15px; }
.nav-links { display: flex; gap: 30px; margin-left: auto; }
.nav-links a { font-size: 13.5px; font-weight: 500; color: var(--bone-dim); letter-spacing: .01em; transition: color .2s; }
.nav-links a:hover { color: var(--amber); }
.nav-cta { padding: 9px 16px; }
.menu-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; margin-left: auto; padding: 6px; }
.menu-toggle span { width: 22px; height: 1.5px; background: var(--bone); display: block; }

/* Hero */
.hero { position: relative; min-height: 100vh; display: flex; align-items: center; overflow: hidden; padding: 120px max(24px, calc((100vw - var(--maxw)) / 2)) 80px; }
.globe { position: absolute; right: -6%; top: 50%; transform: translateY(-50%); width: min(760px, 66vw); height: min(760px, 66vw); z-index: 0; opacity: .95; }
.hero-inner { position: relative; z-index: 2; max-width: 680px; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(120% 90% at 20% 40%, rgba(12,10,8,.72) 0%, rgba(12,10,8,.35) 45%, transparent 75%); }
.hero h1 { font-family: var(--serif); font-weight: 300; font-size: clamp(46px, 8vw, 104px); line-height: .98; letter-spacing: -.03em; margin: 0 0 28px; }
.hero h1 em { font-style: italic; font-weight: 400; color: var(--amber); }
.lede { font-size: clamp(16px, 1.9vw, 19px); line-height: 1.6; color: var(--bone-dim); max-width: 560px; margin: 0; font-weight: 400; }
.hero-cta { display: flex; gap: 14px; margin-top: 40px; flex-wrap: wrap; }
.scroll-cue { position: absolute; left: max(24px, calc((100vw - var(--maxw)) / 2)); bottom: 34px; z-index: 2; display: flex; align-items: center; gap: 12px;
  font-family: var(--mono); font-size: 10px; letter-spacing: .2em; color: var(--muted); }
.scroll-cue i { width: 44px; height: 1px; background: linear-gradient(90deg, var(--amber), transparent); position: relative; overflow: hidden; }
.scroll-cue i::after { content: ""; position: absolute; top: 0; left: -14px; width: 14px; height: 1px; background: var(--amber); animation: cue 2.4s ease-in-out infinite; }
@keyframes cue { 0% { left: -14px; } 60%,100% { left: 44px; } }

/* Sections */
.section { width: min(var(--maxw), calc(100% - 48px)); margin: 0 auto; padding: 118px 0; border-top: 1px solid var(--line-2); }
.sec-head { margin-bottom: 60px; }
.sec-title { font-family: var(--serif); font-weight: 300; font-size: clamp(30px, 4.4vw, 52px); line-height: 1.02; letter-spacing: -.02em; }
.sec-title, .manifesto h2 em, .contact h2 em { text-wrap: balance; }

/* Manifesto */
.manifesto { text-align: left; }
.manifesto h2 { font-family: var(--serif); font-weight: 300; font-size: clamp(26px, 3.9vw, 46px); line-height: 1.18; letter-spacing: -.01em; max-width: 15ch; }
.manifesto h2 em { font-style: italic; color: var(--amber); }

/* Capabilities */
.cap-list { list-style: none; margin: 0; padding: 0; }
.cap { display: grid; grid-template-columns: 60px 1fr auto; gap: 32px; align-items: baseline; padding: 34px 0; border-top: 1px solid var(--line); transition: background .3s; }
.cap:last-child { border-bottom: 1px solid var(--line); }
.cap:hover { background: linear-gradient(90deg, rgba(226,178,95,.05), transparent 60%); }
.cap-idx { font-family: var(--mono); font-size: 13px; color: var(--amber); padding-top: 6px; }
.cap-body h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(22px, 2.6vw, 30px); letter-spacing: -.01em; margin: 0 0 10px; }
.cap-body p { color: var(--bone-dim); font-size: 15px; max-width: 60ch; margin: 0; }
.cap-tag { font-family: var(--mono); font-size: 11px; letter-spacing: .06em; color: var(--muted); white-space: nowrap; padding-top: 8px; }

/* Approach traverse */
.traverse { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.leg { background: var(--bg); padding: 34px 26px; position: relative; transition: background .3s; }
.leg:hover { background: var(--bg-2); }
.leg-deg { font-family: var(--mono); font-size: 12px; color: var(--amber); display: inline-block; width: 30px; height: 30px; line-height: 28px; text-align: center; border: 1px solid var(--line); border-radius: 50%; margin-bottom: 22px; }
.leg h3 { font-family: var(--serif); font-weight: 400; font-size: 24px; margin: 0 0 10px; letter-spacing: -.01em; }
.leg p { color: var(--bone-dim); font-size: 14px; margin: 0; }

/* Work */
.work { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.proj { display: flex; flex-direction: column; min-height: 300px; padding: 28px; border: 1px solid var(--line); border-radius: 3px; background: var(--bg-2); transition: border-color .3s, transform .3s, background .3s; }
.proj:hover { border-color: var(--amber-deep); transform: translateY(-5px); }
.proj-live { background: linear-gradient(180deg, rgba(226,178,95,.07), var(--bg-2) 60%); border-color: rgba(226,178,95,.3); }
.proj-open { background: transparent; border-style: dashed; }
.proj-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: auto; }
.proj-kind { font-family: var(--mono); font-size: 10px; letter-spacing: .12em; color: var(--muted); }
.proj-live, .proj-tag { font-family: var(--mono); font-size: 11px; }
.proj-top .proj-live { color: var(--amber); }
.proj-top .proj-tag { color: var(--muted); }
.proj h3 { font-family: var(--serif); font-weight: 400; font-size: 34px; letter-spacing: -.02em; margin: 44px 0 12px; }
.proj p { color: var(--bone-dim); font-size: 14px; line-height: 1.6; margin: 0 0 22px; }
.proj-go { font-family: var(--mono); font-size: 12px; letter-spacing: .04em; color: var(--amber); display: inline-flex; align-items: center; gap: 8px; }
.proj-go.muted { color: var(--muted); }
.proj-go .arr { transition: transform .25s; }
.proj:hover .proj-go .arr { transform: translateX(4px); }

/* Studio */
.studio { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.studio-lead .lede { margin-top: 22px; }
.ethos { list-style: none; margin: 0; padding: 0; display: grid; }
.ethos li { display: flex; flex-direction: column; gap: 6px; padding: 26px 0; border-top: 1px solid var(--line); }
.ethos li:first-child { padding-top: 0; border-top: 0; }
.ethos strong { font-family: var(--serif); font-weight: 500; font-size: 20px; color: var(--bone); letter-spacing: -.01em; }
.ethos span { color: var(--muted); font-size: 14px; }

/* Contact */
.contact { text-align: center; padding: 130px 24px 120px; border-top: 1px solid var(--line-2); position: relative; overflow: hidden; }
.contact::before { content: ""; position: absolute; left: 50%; top: 0; transform: translateX(-50%); width: 700px; height: 700px; border-radius: 50%;
  background: radial-gradient(circle, rgba(226,178,95,.12), transparent 62%); pointer-events: none; }
.contact h2 { font-family: var(--serif); font-weight: 300; font-size: clamp(40px, 7vw, 88px); line-height: 1.0; letter-spacing: -.03em; margin: 0 auto 22px; position: relative; }
.contact h2 em { font-style: italic; color: var(--amber); }
.contact p { max-width: 500px; margin: 0 auto 34px; color: var(--bone-dim); font-size: 16px; position: relative; }

/* Footer */
.footer { width: min(var(--maxw), calc(100% - 48px)); margin: 0 auto; padding: 44px 0 40px; border-top: 1px solid var(--line); }
.foot-top { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding-bottom: 34px; }
.foot-nav { display: flex; gap: 26px; flex-wrap: wrap; }
.foot-nav a { font-size: 13px; color: var(--bone-dim); transition: color .2s; }
.foot-nav a:hover { color: var(--amber); }
.foot-base { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 24px; border-top: 1px solid var(--line-2); font-family: var(--mono); font-size: 11px; color: var(--muted); }

/* Reveal */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }

/* Responsive */
@media (max-width: 900px) {
  .globe { right: -30%; opacity: .55; }
  .studio { grid-template-columns: 1fr; gap: 34px; }
  .work { grid-template-columns: 1fr; }
  .traverse { grid-template-columns: repeat(2, 1fr); }
  .cap { grid-template-columns: 40px 1fr; }
  .cap-tag { display: none; }
}
@media (max-width: 620px) {
  .nav-links, .nav-cta { display: none; }
  .nav-links.open { display: flex; flex-direction: column; gap: 2px; position: absolute; top: 100%; left: 0; right: 0;
    background: rgba(12,10,8,.96); backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); padding: 12px 24px 20px; margin: 0; }
  .nav-links.open a { padding: 12px 0; }
  .menu-toggle { display: flex; }
  .traverse { grid-template-columns: 1fr; }
  .section { padding: 84px 0; }
  .globe { top: 12%; right: -40%; width: 520px; height: 520px; }
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .scroll-cue i::after { animation: none; }
  html { scroll-behavior: auto; }
}
