/* ==========================================================================
   BIM Performance - site stylesheet
   --------------------------------------------------------------------------
   Shape system (locked, do not mix):
     cards, images, panels .... 14px
     buttons, inputs .......... 10px
     small tags ............... full pill
   Accent: ember red (orange in dark). Logo bands appear only as .stripe.
   Theme: light base, dark via prefers-color-scheme or the header switch.
   ========================================================================== */

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body, h1, h2, h3, h4, p, figure, blockquote, dl, dd, ul, ol { margin: 0; padding: 0; }
ul[class], ol[class] { list-style: none; }
img, svg, video { display: block; max-width: 100%; height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ---------- tokens ----------
   "Ember and charcoal", taken from the logo: charcoal #1e2024, ember red
   #d2412a, orange #ec7a33, saffron #f4b13f, paper #f8f7f2. Red carries the
   light theme, orange the dark one; the three bands together are the
   signature stripe (.stripe). The visitor can override the system theme
   with the header switch, stored as data-theme on <html>. */
:root {
  --bg:          #f7f5f0;
  --surface:     #fffefb;
  --surface-2:   #efebe3;
  --text:        #1e2024;
  --muted:       #5b5e65;
  --border:      #e2ddd2;
  --border-firm: #cac3b5;
  --accent:      #c63c22;
  --accent-soft: #f8e5dc;
  --accent-ink:  #ffffff;
  --ember:       #d2412a;
  --orange:      #ec7a33;
  --saffron:     #f4b13f;
  --charcoal:    #1e2024;
  --shadow:      0 1px 2px rgba(30, 32, 36, .05), 0 12px 32px -12px rgba(30, 32, 36, .14);
  --shadow-lift: 0 2px 4px rgba(30, 32, 36, .06), 0 22px 48px -16px rgba(30, 32, 36, .20);
  color-scheme: light;

  --r-panel: 14px;
  --r-ctrl:  10px;

  --wrap: 1200px;
  --gut: 20px;

  --f-display: "Outfit", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-body: "Inter Tight", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;

  --ease: cubic-bezier(.16, 1, .3, 1);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
      --bg:          #141517;
      --surface:     #1c1e22;
      --surface-2:   #24272c;
      --text:        #f3f1ec;
      --muted:       #a7a9ae;
      --border:      #2e3137;
      --border-firm: #40444b;
      --accent:      #ec7a33;
      --accent-soft: #2b1e16;
      --accent-ink:  #1a0f08;
      --shadow:      0 1px 2px rgba(0, 0, 0, .4), 0 14px 36px -14px rgba(0, 0, 0, .6);
      --shadow-lift: 0 2px 6px rgba(0, 0, 0, .45), 0 26px 54px -18px rgba(0, 0, 0, .7);
      color-scheme: dark;
  }
}
:root[data-theme="dark"] {
    --bg:          #141517;
    --surface:     #1c1e22;
    --surface-2:   #24272c;
    --text:        #f3f1ec;
    --muted:       #a7a9ae;
    --border:      #2e3137;
    --border-firm: #40444b;
    --accent:      #ec7a33;
    --accent-soft: #2b1e16;
    --accent-ink:  #1a0f08;
    --shadow:      0 1px 2px rgba(0, 0, 0, .4), 0 14px 36px -14px rgba(0, 0, 0, .6);
    --shadow-lift: 0 2px 6px rgba(0, 0, 0, .45), 0 26px 54px -18px rgba(0, 0, 0, .7);
    color-scheme: dark;
}

/* ---------- base ---------- */
body {
  font-family: var(--f-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 1rem;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--f-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.08;
  text-wrap: balance;
}

h1 { font-size: clamp(2.25rem, 1.35rem + 3.6vw, 3.9rem); }
h2 { font-size: clamp(1.75rem, 1.2rem + 2.1vw, 2.65rem); }
h3 { font-size: clamp(1.15rem, 1.02rem + 0.5vw, 1.4rem); letter-spacing: -0.015em; }
h4 { font-size: 1.05rem; letter-spacing: -0.01em; }

p { text-wrap: pretty; }
.lede { font-size: clamp(1.06rem, 1rem + 0.35vw, 1.25rem); color: var(--muted); max-width: 60ch; }
.body-max { max-width: 65ch; }
.muted { color: var(--muted); }

a.inline {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a.inline:hover { text-decoration-thickness: 2px; }

:where(a, button, summary, input, textarea, select):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--surface); color: var(--text);
  padding: 12px 18px; z-index: 100; border-radius: 0 0 var(--r-ctrl) 0;
}
.skip:focus { left: 0; }

/* ---------- layout ---------- */
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gut); }
@media (max-width: 480px) { :root { --gut: 16px; } }

section { padding-block: clamp(3.5rem, 2rem + 6vw, 7rem); }
.section-head { max-width: 44ch; margin-bottom: clamp(2rem, 1.2rem + 2.4vw, 3.25rem); }
.section-head p { margin-top: 1rem; color: var(--muted); }

.rule { border: 0; border-top: 1px solid var(--border); margin: 0; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  white-space: nowrap;
  font-family: var(--f-display);
  font-weight: 500; font-size: .975rem; letter-spacing: -0.01em;
  padding: .78rem 1.3rem;
  border-radius: var(--r-ctrl);
  border: 1px solid transparent;
  cursor: pointer; text-decoration: none;
  transition: background-color .22s var(--ease), border-color .22s var(--ease),
              color .22s var(--ease), transform .12s var(--ease), box-shadow .22s var(--ease);
}
.btn:active { transform: translateY(1px); }

.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: var(--shadow); }
.btn-primary:hover { background: color-mix(in srgb, var(--accent) 86%, #000); box-shadow: var(--shadow-lift); }

.btn-outline { background: transparent; color: var(--text); border-color: var(--border-firm); }
.btn-outline:hover { background: var(--surface); border-color: var(--text); }

.btn-onaccent { background: var(--surface); color: var(--text); }
.btn-onaccent:hover { background: color-mix(in srgb, var(--surface) 90%, #000); }

.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; }

.tag {
  display: inline-flex; align-items: center; gap: .4rem;
  font-family: var(--f-display); font-size: .78rem; font-weight: 500;
  padding: .3rem .7rem; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent);
}

/* ---------- header ---------- */
.site-head {
  position: sticky; top: 0; z-index: 50;
  height: 72px;
  display: flex; align-items: center;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--border);
}
@media (prefers-reduced-transparency: reduce) {
  .site-head { background: var(--bg); backdrop-filter: none; -webkit-backdrop-filter: none; }
}
.head-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }

.brand {
  display: inline-flex; align-items: center; gap: .6rem;
  font-family: var(--f-display); font-weight: 700; font-size: 1.25rem;
  letter-spacing: -0.035em; text-decoration: none; color: var(--text);
}
.brand-mark { height: 2.1em; width: auto; flex: none; }
.brand .b2 { font-weight: 400; color: var(--muted); }

.nav { display: flex; align-items: center; gap: 1.6rem; }
.nav a {
  font-size: .94rem; text-decoration: none; color: var(--muted);
  transition: color .18s var(--ease);
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.nav .btn { font-size: .9rem; padding: .6rem 1.05rem; }
.nav .btn-primary, .nav .btn-primary:hover { color: var(--accent-ink); }

.burger {
  display: none;
  background: transparent; border: 1px solid var(--border-firm);
  border-radius: var(--r-ctrl); padding: .5rem .7rem; cursor: pointer;
  font-family: var(--f-display); font-size: .9rem;
}

@media (max-width: 1100px) {
  .burger { display: inline-flex; align-items: center; gap: .5rem; }
  .nav {
    position: fixed; inset: 72px 0 auto 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: .5rem var(--gut) 1.25rem;
    box-shadow: var(--shadow-lift);
    display: none;
  }
  .nav[data-open="true"] { display: flex; }
  .nav a { padding: .85rem 0; border-bottom: 1px solid var(--border); font-size: 1.02rem; color: var(--text); }
  .nav .btn { margin-top: 1rem; border-bottom: 0; justify-content: center; font-size: 1rem; padding: .8rem 1.2rem; }
}

/* ---------- hero (asymmetric split) ---------- */
.hero { padding-top: clamp(2.5rem, 1.5rem + 3vw, 4.5rem); padding-bottom: clamp(3rem, 2rem + 4vw, 5.5rem); }
.hero-grid { display: grid; gap: clamp(2rem, 1rem + 4vw, 3.5rem); align-items: center; }
@media (min-width: 900px) { .hero-grid { grid-template-columns: 1.05fr .95fr; } }
.hero h1 { margin-bottom: 1.15rem; }
.hero .lede { margin-bottom: 1.9rem; }

.hero-figure {
  position: relative;
  border-radius: var(--r-panel);
  overflow: hidden;
  background: var(--surface-2);
  box-shadow: var(--shadow-lift);
  aspect-ratio: 16 / 10;
}
.hero-figure img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- credibility strip ---------- */
.strip { padding-block: clamp(1.75rem, 1.2rem + 1.6vw, 2.5rem); border-top: 1px solid var(--border); }
.strip-inner { display: flex; flex-wrap: wrap; gap: 1rem 2.75rem; align-items: center; }
.strip-item { display: flex; align-items: center; gap: .6rem; font-size: .93rem; color: var(--muted); }
.strip-item i { font-size: 1.15rem; color: var(--accent); }

/* ---------- services grid (4 items, 2 x 2) ---------- */
.bento { display: grid; gap: 1rem; }
@media (min-width: 880px) {
  .bento { grid-template-columns: 1fr 1fr; gap: 1.25rem; }
}
.svc {
  display: flex; flex-direction: column;
  border-radius: var(--r-panel);
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
  text-decoration: none;
  transition: transform .26s var(--ease), box-shadow .26s var(--ease), border-color .26s var(--ease);
}
.svc:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); border-color: var(--border-firm); }
.svc-media { background: var(--surface-2); aspect-ratio: 16 / 10; overflow: hidden; }
.svc-media img { width: 100%; height: 100%; object-fit: cover; }
.svc-body { padding: clamp(1.25rem, 1rem + 1vw, 1.9rem); display: flex; flex-direction: column; gap: .7rem; flex: 1; }
.svc-body i { font-size: 1.5rem; color: var(--accent); }
.svc-body p { color: var(--muted); font-size: .97rem; }
.svc-more {
  margin-top: auto; padding-top: .4rem;
  font-family: var(--f-display); font-weight: 500; font-size: .93rem; color: var(--accent);
}
.svc-more::after {
  content: "\2192"; display: inline-block;
  margin-left: .4rem;
  transition: transform .2s var(--ease);
}
.svc:hover .svc-more::after { transform: translateX(3px); }


/* ---------- process (sticky rail + list) ---------- */
.rail { display: grid; gap: clamp(2rem, 1rem + 3vw, 3.5rem); }
@media (min-width: 940px) {
  .rail { grid-template-columns: .85fr 1.15fr; align-items: start; }
  .rail-head { position: sticky; top: 112px; }
}
.rail-head p { color: var(--muted); margin-top: 1rem; max-width: 34ch; }

.steps { display: grid; gap: 0; }
.step { display: grid; gap: .5rem; padding-block: clamp(1.4rem, 1rem + 1vw, 2rem); }
.step + .step { border-top: 1px solid var(--border); }
.step-k {
  font-family: var(--f-display); font-weight: 500; font-size: .85rem;
  color: var(--accent);
}
.step p { color: var(--muted); max-width: 54ch; }

/* ---------- projects: portfolio grid ----------
   Uniform tall tiles, square corners, quiet captions. The pictures carry it. */
.work-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2.25rem 1rem; }
@media (min-width: 820px) {
  .work-grid { grid-template-columns: repeat(3, 1fr); gap: 3.25rem 2.5rem; }
}
.work { margin: 0; }
.work-media { aspect-ratio: 2 / 3; overflow: hidden; background: var(--surface-2); }
.work-media img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .8s var(--ease);
}
.work:hover .work-media img { transform: scale(1.025); }
.work figcaption { padding-top: .8rem; font-size: .88rem; line-height: 1.45; }
.work figcaption strong { display: block; font-weight: 500; color: var(--text); }
.work figcaption span { color: var(--muted); }

/* ---------- deliverables (grouped, sparse dividers) ---------- */
.groups { display: grid; gap: 1rem; }
@media (min-width: 760px) { .groups { grid-template-columns: repeat(3, 1fr); } }
.group {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-panel); padding: clamp(1.25rem, 1rem + 1vw, 1.75rem);
}
.group h4 { margin-bottom: .9rem; }
.group ul { display: grid; gap: .6rem; list-style: none; }
.group li { display: grid; grid-template-columns: 18px 1fr; gap: .6rem; font-size: .94rem; color: var(--muted); }
.group li i { color: var(--accent); font-size: 1rem; line-height: 1.5; }

/* ---------- faq ---------- */
.faq { max-width: 820px; }
.faq details { border-top: 1px solid var(--border); }
.faq details:last-of-type { border-bottom: 1px solid var(--border); }
.faq summary {
  cursor: pointer; list-style: none;
  display: flex; align-items: flex-start; justify-content: space-between; gap: 1.5rem;
  padding: 1.15rem 0;
  font-family: var(--f-display); font-weight: 500; font-size: 1.05rem; letter-spacing: -0.01em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; flex: none;
  font-size: 1.4rem; line-height: 1; color: var(--accent);
  transition: transform .25s var(--ease);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .answer { padding: 0 0 1.35rem; color: var(--muted); max-width: 65ch; }
.faq .answer p + p { margin-top: .75rem; }

/* ---------- accent call to action band ---------- */
.band { background: var(--accent); color: var(--accent-ink); }
.band-inner { display: grid; gap: 1.75rem; align-items: center; }
@media (min-width: 860px) { .band-inner { grid-template-columns: 1.4fr auto; } }
.band h2 { color: var(--accent-ink); }
.band p { margin-top: .85rem; max-width: 52ch; opacity: .92; }

/* ---------- forms ---------- */
.form-grid { display: grid; gap: clamp(2rem, 1rem + 3vw, 3.5rem); align-items: start; }
@media (min-width: 940px) { .form-grid { grid-template-columns: 1.1fr .9fr; } }

.field { display: grid; gap: .45rem; margin-bottom: 1.1rem; }
.field label { font-family: var(--f-display); font-weight: 500; font-size: .92rem; }
.field .hint { font-size: .85rem; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border-firm);
  border-radius: var(--r-ctrl);
  padding: .72rem .85rem;
  font-size: 1rem;
  transition: border-color .18s var(--ease), box-shadow .18s var(--ease);
}
.field textarea { min-height: 140px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: var(--muted); opacity: 1; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
}
.field-err { font-size: .87rem; color: var(--accent); font-weight: 500; display: none; }
.field[data-invalid="true"] input,
.field[data-invalid="true"] textarea,
.field[data-invalid="true"] select { border-color: var(--accent); }
.field[data-invalid="true"] .field-err { display: block; }
.two-up { display: grid; gap: 1.1rem; }
@media (min-width: 620px) { .two-up { grid-template-columns: 1fr 1fr; } }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.notice {
  border-radius: var(--r-panel); padding: 1rem 1.15rem;
  border: 1px solid var(--border-firm); background: var(--surface);
  font-size: .95rem; margin-bottom: 1.5rem;
}
.notice-ok { border-color: var(--accent); background: var(--accent-soft); color: var(--text); }

.aside-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-panel); padding: clamp(1.25rem, 1rem + 1vw, 1.9rem);
}
.aside-card h3 { margin-bottom: 1rem; }
.contact-list { display: grid; gap: .9rem; list-style: none; }
.contact-list li { display: grid; grid-template-columns: 20px 1fr; gap: .75rem; font-size: .96rem; }
.contact-list i { color: var(--accent); font-size: 1.15rem; }
.contact-list a { text-decoration: none; }
.contact-list a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- footer ---------- */
.site-foot { border-top: 1px solid var(--border); padding-block: clamp(2.5rem, 2rem + 2vw, 4rem) 2rem; }
.foot-grid { display: grid; gap: 2rem; }
@media (min-width: 760px) { .foot-grid { grid-template-columns: 1.4fr 1fr 1fr; } }
.foot-grid h4 { font-size: .95rem; margin-bottom: .9rem; }
.foot-links { display: grid; gap: .55rem; list-style: none; }
.foot-links a { font-size: .94rem; color: var(--muted); text-decoration: none; }
.foot-links a:hover { color: var(--text); }
.foot-blurb { color: var(--muted); font-size: .94rem; max-width: 38ch; margin-top: .9rem; }
.foot-base {
  margin-top: clamp(2rem, 1.5rem + 2vw, 3rem); padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; justify-content: space-between;
  font-size: .87rem; color: var(--muted);
}

/* ---------- scroll reveal ---------- */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(18px); }
  .reveal.is-in {
    opacity: 1; transform: none;
    transition: opacity .7s var(--ease), transform .7s var(--ease);
    transition-delay: var(--d, 0ms);
  }
}

/* ---------- inner page header ---------- */
.page-head { padding-block: clamp(2.75rem, 2rem + 3vw, 4.5rem) clamp(1.5rem, 1rem + 2vw, 2.5rem); }
.page-head h1 { max-width: 24ch; margin-bottom: 1.1rem; }
.crumb { font-size: .88rem; color: var(--muted); margin-bottom: 1.1rem; }
.crumb a { text-decoration: none; }
.crumb a:hover { text-decoration: underline; text-underline-offset: 3px; }

.split { display: grid; gap: clamp(2rem, 1rem + 3vw, 3.5rem); align-items: start; }
@media (min-width: 900px) { .split { grid-template-columns: 1.1fr .9fr; } }
.split-figure { border-radius: var(--r-panel); overflow: hidden; background: var(--surface-2); box-shadow: var(--shadow); }
.split-figure img { width: 100%; object-fit: cover; }

.prose > * + * { margin-top: 1.1rem; }
.prose h3 { margin-top: 2.25rem; }
.prose p { color: var(--muted); max-width: 65ch; }
.prose ul { display: grid; gap: .6rem; padding-left: 0; list-style: none; max-width: 65ch; }
.prose ul li { display: grid; grid-template-columns: 18px 1fr; gap: .6rem; color: var(--muted); }
.prose ul li i { color: var(--accent); font-size: 1rem; line-height: 1.55; }

/* ---------- label on AI-generated illustrations ---------- */
.svc-media, .split-figure { position: relative; }
.ill-tag {
  position: absolute; left: .75rem; bottom: .75rem;
  padding: .2rem .55rem; border-radius: 999px;
  background: rgb(18 19 22 / .62); color: #f4f2ec;
  font-size: .72rem; letter-spacing: .02em; line-height: 1.4;
  backdrop-filter: blur(4px); pointer-events: none;
}

/* ---------- theme switch ---------- */
.head-inner { justify-content: flex-start; }
.head-inner > .brand { margin-right: auto; }
.nav { order: 1; }
.theme-toggle { order: 2; }
.burger { order: 3; }
.theme-toggle {
  flex: none; width: 40px; height: 40px;
  display: inline-grid; place-items: center;
  background: transparent; color: var(--text);
  border: 1px solid var(--border-firm); border-radius: 999px;
  cursor: pointer; font-size: 1.1rem;
  transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
.theme-toggle:hover { border-color: var(--text); background: var(--surface); }

/* ---------- signature stripe: the three logo bands ---------- */
.stripe {
  display: block; width: 88px; height: 6px; border-radius: 3px;
  background: linear-gradient(90deg, var(--ember) 0 33.3%, var(--orange) 33.3% 66.6%, var(--saffron) 66.6%);
}
.page-head .stripe, .hero .stripe { margin-bottom: 1.4rem; }
.site-foot { position: relative; }
.site-foot::before {
  content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 3px;
  background: linear-gradient(90deg, var(--ember) 0 33.3%, var(--orange) 33.3% 66.6%, var(--saffron) 66.6%);
}

/* ---------- film: full width video with caption ---------- */
.film {
  position: relative; margin: 0; overflow: hidden;
  border-radius: var(--r-panel); background: var(--charcoal);
  aspect-ratio: 16 / 9; box-shadow: var(--shadow-lift);
}
.film video { width: 100%; height: 100%; object-fit: cover; }
.film figcaption {
  position: absolute; inset: auto 0 0 0;
  padding: clamp(1.25rem, 1rem + 2vw, 2.5rem);
  background: linear-gradient(0deg, rgb(20 21 23 / .78), transparent);
  color: #f7f5f0; display: grid; gap: .35rem;
}
.film-k { font-family: var(--f-display); font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--saffron); }
.film-t { font-family: var(--f-display); font-weight: 600; font-size: clamp(1.3rem, 1rem + 1.6vw, 2.2rem); letter-spacing: -.02em; line-height: 1.1; }
.film .ill-tag { left: auto; right: .75rem; bottom: auto; top: .75rem; }

/* ---------- sample drawings ---------- */
.dw {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-panel); padding: clamp(1rem, .6rem + 2vw, 2.25rem);
}
.dw-tabs { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.25rem; }
.dw-tabs button {
  font-family: var(--f-display); font-weight: 500; font-size: .92rem;
  padding: .5rem 1rem; border-radius: 999px; cursor: pointer;
  background: transparent; color: var(--muted); border: 1px solid var(--border-firm);
}
.dw-tabs button[aria-selected="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.dw-panel { display: grid; place-items: center; }
.dw-panel[hidden] { display: none; }
.dw-svg { width: 100%; max-width: 560px; height: auto; max-height: 78vh; color: var(--text); }
#dw-elev { max-width: 760px; }
.dw-svg .ln { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }
.dw-svg .thin { stroke-width: 1.1; }
.dw-svg .wall { fill: currentColor; fill-opacity: .82; stroke-width: 1.4; }
.dw-svg .wall.new, .dw-svg .new-ln { stroke: var(--accent); }
.dw-svg .wall.new { fill: var(--accent); fill-opacity: .9; }
.dw-svg .glass { fill: color-mix(in srgb, var(--surface) 90%, var(--text)); }
.dw-svg .fillink { fill: currentColor; }
.dw-svg .dim, .dw-svg .tick { stroke-width: .9; opacity: .7; }
.dw-svg .tick { stroke-width: 1.6; }
.dw-svg .ground { stroke-width: 4; }
.dw-svg .hid { fill: none; stroke: currentColor; stroke-width: 1.1; stroke-dasharray: 10 7; opacity: .55; }

.dw-svg text { fill: currentColor; font-family: var(--f-display); text-anchor: middle; }
.dw-svg .lbl { font-size: 24px; font-weight: 600; letter-spacing: .06em; }
.dw-svg .small { font-size: 18px; opacity: .75; }
.dw-svg .tiny { font-size: 15px; opacity: .6; font-style: italic; }
.dw-svg .dimt { font-size: 17px; opacity: .75; }
.dw-svg .title { font-size: 30px; font-weight: 600; letter-spacing: .1em; }
.dw-svg .new-t { fill: var(--accent); opacity: 1; }
.dw-svg .left { text-anchor: start; }
@media (prefers-reduced-motion: no-preference) {
  .dw.reveal .ln { stroke-dasharray: 1; stroke-dashoffset: 1; }
  .dw.reveal .wall, .dw.reveal .glass { fill-opacity: 0; }
  .dw.reveal text, .dw.reveal .hid { opacity: 0; }
  .dw.is-in .ln { stroke-dashoffset: 0; transition: stroke-dashoffset 2.2s cubic-bezier(.45, 0, .2, 1); }
  .dw.is-in .wall { fill-opacity: .82; transition: fill-opacity .8s ease 1.6s; }
  .dw.is-in .wall.new { fill-opacity: .9; }
  .dw.is-in .glass { fill-opacity: 1; transition: fill-opacity .8s ease 1.6s; }
  .dw.is-in text { opacity: .75; transition: opacity .8s ease 1.8s; }
  .dw.is-in .lbl, .dw.is-in .title, .dw.is-in .new-t { opacity: 1; }
  .dw.is-in .hid { opacity: .55; transition: opacity .8s ease 1.2s; }
}

/* ---------- tiles: icon cards in a 4 column grid ---------- */
.tiles { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.tile {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-panel);
  padding: clamp(1.25rem, 1rem + 1vw, 1.75rem); display: grid; gap: .6rem; align-content: start;
}
.tile i { font-size: 1.6rem; color: var(--accent); }
.tile h3 { font-size: 1.12rem; }
.tile p { color: var(--muted); font-size: .94rem; }

/* ---------- gallery: mixed size image grid ---------- */
.gallery { display: grid; gap: 1rem; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 900px) { .gallery { grid-template-columns: repeat(3, 1fr); gap: 1.25rem; } }
.gallery figure { margin: 0; position: relative; }
.gallery .g-media { position: relative; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--r-panel); background: var(--surface-2); }
.gallery .g-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.gallery figure:hover img { transform: scale(1.03); }
.gallery figcaption { padding-top: .75rem; font-size: .92rem; line-height: 1.45; }
.gallery figcaption strong { display: block; font-family: var(--f-display); font-weight: 600; font-size: 1.02rem; color: var(--text); }
.gallery figcaption span { color: var(--muted); }
@media (min-width: 900px) { .gallery .wide { grid-column: span 2; } .gallery .wide .g-media { aspect-ratio: auto; height: 100%; min-height: 100%; } }
.g-media .ill-tag, .work-media .ill-tag { z-index: 1; }
.work-media { position: relative; }
.dw-svg pattern path { fill: none; stroke: currentColor; stroke-width: .7; }
.dw-svg .brick { fill: url(#pat-brick); opacity: .3; }
.dw-svg .roofhatch { fill: url(#pat-tile); opacity: .3; }
@media (prefers-reduced-motion: no-preference) {
  .dw.reveal .brick, .dw.reveal .roofhatch { opacity: 0; }
  .dw.is-in .brick, .dw.is-in .roofhatch { opacity: .3; transition: opacity .8s ease 1.6s; }
}
