/* NAD — independent website concept
   Palette and type are provisional tokens: adjust in :root.
   Jost is an open-licence stand-in; NAD's own fonts were not verified. */

@font-face {
  font-family: "Jost";
  src: url("../fonts/jost-latin-wght-normal.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #f4f1eb;          /* plaster */
  --surface: #fbfaf7;     /* panel / paper */
  --ink: #1e1c19;         /* text */
  --muted: #5e5850;       /* secondary text, 6.4:1 on --bg */
  --line: #d9d2c6;        /* hairlines */
  --stone: #e8e3da;       /* image well */
  --accent: #7a5a3a;      /* bronze, 5.9:1 on --bg */
  --dark: #1c1b19;        /* header: the original logo is light grey on transparent */
  --on-dark: #ece8e1;
  --focus: #1e1c19;

  --font: "Jost", "Helvetica Neue", Arial, sans-serif;
  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: clamp(1.5rem, 1.2rem + 1.2vw, 2rem);
  --step-3: clamp(2rem, 1.4rem + 2.6vw, 3.5rem);

  --gutter: clamp(1.25rem, 0.6rem + 2.6vw, 3rem);
  --max: 1440px;
  --space: clamp(4rem, 2.5rem + 6vw, 8.5rem);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.6;
  font-weight: 400;
  overflow-x: hidden;
}
body.is-locked { overflow: hidden; }
img { display: block; max-width: 100%; }
h1, h2, h3 { font-weight: 400; line-height: 1.15; margin: 0; letter-spacing: -0.01em; }
p { margin: 0; }
a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
[hidden] { display: none !important; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

section[id] { scroll-margin-top: 5rem; }
.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }

.skip {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--ink); color: var(--surface); padding: .75rem 1rem; text-decoration: none;
}
.skip:focus { top: 1rem; }

/* Concept bar */
.concept-bar {
  background: var(--stone); color: var(--ink); border-bottom: 1px solid var(--line);
  font-size: var(--step--1); text-align: center; padding: .5rem var(--gutter);
}

/* Header (dark, so the original light-grey logo reads as designed) */
.site-header { position: sticky; top: 0; z-index: 20; background: var(--dark); color: var(--on-dark); }
.site-header :focus-visible { outline-color: var(--on-dark); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4.5rem; }
.logo { display: inline-flex; align-items: center; text-decoration: none; min-height: 44px; }
.logo__img { height: 30px; width: auto; }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: clamp(1rem, 2vw, 2.25rem); align-items: center; }
.site-nav a { text-decoration: none; display: inline-block; padding: .6rem 0; }
.site-nav a:hover { text-decoration: underline; }
.site-nav__cta { border: 1px solid var(--on-dark); padding: .6rem 1rem !important; }
.site-nav__cta:hover { background: var(--on-dark); color: var(--dark); text-decoration: none !important; }
.nav-toggle { display: none; }

@media (max-width: 760px) {
  .nav-toggle {
    display: inline-flex; align-items: center; min-height: 44px; min-width: 44px;
    background: none; border: 1px solid var(--on-dark); padding: .5rem .9rem; color: var(--on-dark);
  }
  .site-nav { position: absolute; left: 0; right: 0; top: 100%; background: var(--dark); border-bottom: 1px solid #3a3733; }
  .js .site-nav:not(.is-open) { display: none; }
  .site-nav ul { flex-direction: column; align-items: stretch; gap: 0; padding: .5rem var(--gutter) 1.25rem; }
  .site-nav a { display: block; padding: .85rem 0; border-bottom: 1px solid #3a3733; }
  .site-nav__cta { margin-top: 1rem; text-align: center; border-bottom: 1px solid var(--on-dark) !important; }
}

/* Intro */
.intro {
  padding-block: clamp(2.5rem, 1.5rem + 4vw, 5.5rem) clamp(2.5rem, 2rem + 3vw, 4.5rem);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 1.5rem 2rem; align-items: end;
}
.intro h1 { font-size: var(--step-3); max-width: 18ch; grid-column: 1 / span 7; }
.intro__lede { grid-column: 9 / -1; max-width: 36ch; color: var(--muted); font-size: var(--step-1); line-height: 1.5; }
@media (max-width: 900px) {
  .intro { grid-template-columns: minmax(0, 1fr); }
  .intro h1, .intro__lede { grid-column: 1 / -1; }
}

.block { padding-bottom: var(--space); }
.kicker { font-size: var(--step--1); color: var(--muted); letter-spacing: .04em; }
.section-head {
  display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1rem 2rem;
  border-top: 1px solid var(--ink); padding-top: 1.25rem; margin-bottom: clamp(1.75rem, 1rem + 2.5vw, 3rem);
}
.section-head h2 { font-size: var(--step-2); margin-top: .25rem; }
.section-head__aside { color: var(--muted); max-width: 38ch; display: grid; gap: .75rem; justify-items: start; }
.section-head__note { color: var(--muted); margin-top: .5rem; max-width: 44ch; font-size: var(--step--1); }

/* Justified rows: each tile grows by its aspect ratio, so every row shares one height and no image is cropped. */
.rows { display: grid; gap: clamp(.75rem, .4rem + 1vw, 1.25rem); }
.row { display: flex; gap: clamp(.75rem, .4rem + 1vw, 1.25rem); align-items: flex-start; }
.tile { margin: 0; min-width: 0; flex-basis: 0; flex-shrink: 1; }
.tile__btn { display: block; width: 100%; padding: 0; border: 0; background: var(--stone); cursor: zoom-in; }
.tile img { width: 100%; height: auto; }
.tile figcaption { font-size: var(--step--1); color: var(--muted); padding-top: .5rem; }
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .tile__btn img { transition: opacity .3s var(--ease); }
  .tile__btn:hover img { opacity: .9; }
}
@media (max-width: 640px) { .row { flex-direction: column; } .tile { flex: none !important; width: 100%; } }

/* Filter */
.filter { display: flex; flex-wrap: wrap; gap: .5rem; }
.filter button { background: none; border: 1px solid var(--line); padding: .5rem .95rem; min-height: 44px; font-size: var(--step--1); }
.filter button:hover { border-color: var(--ink); }
.filter button[aria-pressed="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.filter-status { font-size: var(--step--1); color: var(--muted); margin: -1rem 0 1.25rem; min-height: 1.4em; }

.link-btn { display: inline-flex; align-items: center; gap: .6rem; min-height: 44px; background: none; border: 0; border-bottom: 1px solid var(--ink); padding: .25rem 0; color: var(--ink); text-align: left; }
.link-btn::after { content: "→"; transition: transform .3s var(--ease); }
.link-btn:hover::after { transform: translateX(3px); }

/* Services */
.service-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(2rem, 4vw, 5rem); }
.service { border-top: 1px solid var(--line); padding: 1.75rem 0 2.25rem; display: grid; grid-template-columns: 3rem 1fr; gap: .25rem 1rem; }
.service__num { color: var(--muted); font-size: var(--step--1); padding-top: .35rem; }
.service h3 { font-size: var(--step-1); }
.service p { color: var(--muted); grid-column: 2; max-width: 44ch; margin-top: .5rem; }
.service .link-btn { grid-column: 2; justify-self: start; margin-top: 1rem; font-size: var(--step--1); }
@media (max-width: 760px) { .service-list { grid-template-columns: minmax(0, 1fr); } }

/* Studio */
.studio__inner { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 2rem; border-top: 1px solid var(--ink); padding-top: 1.25rem; }
.studio h2 { grid-column: span 4; font-size: var(--step-2); }
.facts { margin: 0; display: grid; }
.studio .facts { grid-column: span 8; }
.facts div { display: grid; grid-template-columns: 10rem 1fr; gap: 1rem; padding: .9rem 0; border-bottom: 1px solid var(--line); }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; overflow-wrap: anywhere; }
@media (max-width: 760px) {
  .studio__inner { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  .studio h2, .studio .facts { grid-column: 1 / -1; }
  .facts div { grid-template-columns: minmax(0, 1fr); gap: .15rem; }
}

/* Enquiry */
.enquiry__inner { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 2rem clamp(2rem, 4vw, 4rem); border-top: 1px solid var(--ink); padding-top: 1.25rem; }
.enquiry__intro { grid-column: span 4; }
.enquiry__intro h2 { font-size: var(--step-2); }
.enquiry__intro p { margin-top: 1rem; color: var(--muted); max-width: 34ch; }
.enquiry__intro .draft-flag { color: var(--ink); border-left: 2px solid var(--accent); padding-left: 1rem; }
.brief { grid-column: span 8; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem 1.5rem; }
.field { display: grid; gap: .4rem; margin: 0; min-width: 0; }
.field--wide { grid-column: 1 / -1; }
fieldset.field { border: 0; padding: 0; }
legend { padding: 0; margin-bottom: .4rem; }
label, legend { font-size: var(--step--1); }
.opt { color: var(--muted); }
input, select, textarea { width: 100%; min-height: 48px; padding: .7rem .85rem; border: 1px solid #a99f91; border-radius: 0; background: var(--surface); }
textarea { resize: vertical; min-height: 8rem; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; border-color: var(--ink); }
.checks { display: flex; flex-wrap: wrap; gap: .5rem; }
.check { position: relative; }
.check input { position: absolute; opacity: 0; width: 1px; height: 1px; min-height: 0; }
.check label { display: inline-flex; align-items: center; gap: .55rem; min-height: 44px; padding: .5rem .95rem; border: 1px solid #a99f91; background: var(--surface); cursor: pointer; font-size: var(--step-0); }
.check label::before { content: ""; width: .9rem; height: .9rem; border: 1px solid var(--ink); flex: none; }
.check input:checked + label { border-color: var(--ink); }
.check input:checked + label::before { background: var(--ink); box-shadow: inset 0 0 0 2px var(--surface); }
.check input:focus-visible + label { outline: 2px solid var(--focus); outline-offset: 2px; }
.summary { margin-top: 1rem; border-top: 1px solid var(--line); padding-top: 1.5rem; }
.summary h3 { font-size: var(--step-1); }
.summary__text { margin: 1rem 0 0; padding: 1.25rem; background: var(--surface); border: 1px solid var(--line); font-family: inherit; font-size: var(--step--1); line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; }
.summary__actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1rem; }
.summary__status { margin-top: .75rem; font-size: var(--step--1); color: var(--muted); }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .7rem 1.4rem; background: var(--ink); color: var(--surface); border: 1px solid var(--ink); }
.btn:hover { background: #3a3631; }
.btn--quiet { background: none; color: var(--ink); }
.btn--quiet:hover { background: var(--stone); }
@media (max-width: 900px) { .enquiry__inner { grid-template-columns: minmax(0, 1fr); } .enquiry__intro, .brief { grid-column: 1 / -1; } }
@media (max-width: 560px) { .brief { grid-template-columns: minmax(0, 1fr); } }

/* Footer */
.site-footer { border-top: 1px solid var(--ink); padding-block: 2.5rem 3rem; font-size: var(--step--1); color: var(--muted); }
.site-footer__inner { display: grid; gap: .75rem; }
.site-footer p { max-width: 80ch; }
.site-footer strong { color: var(--ink); font-weight: 500; }

/* Detail panel */
.panel { position: fixed; inset: 0; z-index: 50; background: var(--surface); overflow-y: auto; overscroll-behavior: contain; }
@media (prefers-reduced-motion: no-preference) { .panel { animation: panel-in .25s var(--ease); } @keyframes panel-in { from { opacity: 0; } to { opacity: 1; } } }
.panel__inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter) 3rem; }
.panel__head { position: sticky; top: 0; z-index: 2; background: var(--surface); display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid var(--line); }
.panel__head h2 { font-size: var(--step-2); }
.panel__close { min-height: 44px; min-width: 44px; padding: .5rem 1rem; background: none; border: 1px solid var(--ink); flex: none; }
.panel__close:hover { background: var(--ink); color: var(--surface); }
.panel__body { display: grid; grid-template-columns: minmax(0, 1fr) 19rem; gap: 2rem 3rem; padding-top: 1.5rem; }
.viewer { margin: 0; min-width: 0; }
.viewer__stage { background: var(--stone); display: grid; place-items: center; min-height: 12rem; }
.viewer__stage img { max-width: 100%; max-height: calc(100vh - 13rem); width: auto; height: auto; }
.viewer__bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .75rem 0; }
.viewer__nav { min-width: 48px; min-height: 48px; background: none; border: 1px solid var(--line); font-size: 1.1rem; flex: none; }
.viewer__nav:hover { border-color: var(--ink); }
.viewer__caption { text-align: center; }
.viewer__count { color: var(--muted); font-size: var(--step--1); margin-left: .5rem; white-space: nowrap; }
.panel__info { align-self: start; position: sticky; top: 6rem; display: grid; gap: 1.5rem; }
.thumbs { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .4rem; }
.thumbs button { display: block; width: 100%; padding: 0; border: 2px solid transparent; background: var(--stone); }
.thumbs button[aria-current="true"] { border-color: var(--ink); }
.thumbs img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.facts--compact div { grid-template-columns: 6.5rem 1fr; padding: .6rem 0; }
.panel__services h3 { font-size: var(--step--1); color: var(--muted); font-weight: 400; margin-bottom: .4rem; }
.panel__services ul { margin: 0; padding: 0; list-style: none; }
.panel__services li { padding: .25rem 0; }
.panel__services .note { font-size: var(--step--1); color: var(--muted); margin-top: .5rem; }
.panel__original { font-size: var(--step--1); color: var(--muted); justify-self: start; min-height: 44px; display: inline-flex; align-items: center; }
@media (max-width: 900px) {
  .panel__body { grid-template-columns: minmax(0, 1fr); }
  .viewer__stage img { max-height: 70vh; }
  .panel__info { position: static; }
  .thumbs { grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
