/* NAMMINI v3, dark only. Text in Kalkės on warm black, Mėlis for the services, Ąžuolas in small doses.
   Bodoni Moda for headings, DM Sans for text (the "bodoni" pair from the first prototype's picker). */
@font-face { font-family: 'Bodoni Moda'; src: url(fonts/bodoni-moda-latin.woff2) format('woff2'); font-weight: 400 900; font-display: swap; unicode-range: U+0000-00FF, U+2000-206F; }
@font-face { font-family: 'Bodoni Moda'; src: url(fonts/bodoni-moda-latin-ext.woff2) format('woff2'); font-weight: 400 900; font-display: swap; unicode-range: U+0100-02FF, U+1E00-1EFF; }
@font-face { font-family: 'DM Sans'; src: url(fonts/dm-sans-latin.woff2) format('woff2'); font-weight: 100 1000; font-display: swap; unicode-range: U+0000-00FF, U+2000-206F; }
@font-face { font-family: 'DM Sans'; src: url(fonts/dm-sans-latin-ext.woff2) format('woff2'); font-weight: 100 1000; font-display: swap; unicode-range: U+0100-02FF, U+1E00-1EFF; }

:root {
  --bg: #0E0D0B; --bg-2: #171512; --ink: #F5F1E8; --muted: #A69E91; --line: rgb(245 241 232 / .14);
  --melis: #17474B; --azuolas: #C49A70;
  --head: 'Bodoni Moda', Georgia, serif; --body: 'DM Sans', Arial, sans-serif;
  --gut: clamp(16px, 4vw, 64px);
  --lw: clamp(120px, 11vw, 160px); /* the header logo's width */
  --slow: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 clamp(15px, 1.05vw, 17px)/1.6 var(--body); overflow-x: clip; }
img { display: block; max-width: 100%; }
picture { display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--head); font-weight: 500; line-height: 1.04; margin: 0; letter-spacing: -0.02em; text-wrap: balance; }
p { margin: 0; }
figure { margin: 0; }
.label { font: 600 11.5px/1.3 var(--body); letter-spacing: .18em; text-transform: uppercase; color: var(--azuolas); }
.skip { position: absolute; left: -999px; top: 8px; z-index: 60; background: var(--ink); color: var(--bg); padding: 8px 12px; }
.skip:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--azuolas); outline-offset: 3px; }

/* ---------- header: over the pictures, with a dark backing once the page moves ---------- */
.top { position: fixed; inset: 0 0 auto; z-index: 30; display: flex; align-items: center; justify-content: space-between; padding: 18px var(--gut); pointer-events: none; }
.top > * { pointer-events: auto; }
.top::before { content: ''; position: absolute; inset: 0; z-index: -1; background: rgb(14 13 11 / .82); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line); opacity: 0; transition: opacity .35s; }
.solid .top::before { opacity: 1; }
.logo { display: block; width: var(--lw); }
.logo img { width: 100%; height: auto; }
.top nav { display: flex; align-items: center; gap: clamp(14px, 2.4vw, 34px); font: 600 11.5px/1 var(--body); letter-spacing: .18em; text-transform: uppercase; }
.top nav a { text-decoration: none; }
.top nav a:not(.cta):hover { text-decoration: underline; text-underline-offset: 5px; }
.cta { border: 1px solid currentColor; padding: 10px 16px; border-radius: 99px; transition: background .3s, color .3s; }
.cta:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); }
@media (max-width: 640px) { .top nav a:not(.cta) { display: none; } }
@media (max-width: 760px) { .top::before { backdrop-filter: none; -webkit-backdrop-filter: none; background: rgb(14 13 11 / .94); } }

/* ---------- opening: one screen that holds still while you scroll ----------
   The logo shows for a moment, then flies to its place top left, over four columns of his pictures.
   Scrolling does not move the page at first: the columns part from the middle (left two and the title
   to the left, right two to the right) and show the studio's words behind them; then the page goes on.
   Hovering a column widens it. Clicking one grows it to full screen, then its project opens. */
.opening { position: relative; height: 230vh; background: var(--bg); }
.shade { display: none; }
.stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.intro { position: absolute; inset: 0; z-index: 5; background: var(--bg); pointer-events: none;
  animation: intro-bg .55s ease .4s both, intro-off 0s linear .96s both; }
/* CSS only, so it ends on time however slowly the script arrives. The logo sits where the header's
   logo is (left var(--gut), top 18px, width --lw) and starts 1.6 times larger in the middle of the
   screen; a transform, so it moves nothing else on the page (no layout shift). */
.intro img { position: absolute; left: var(--gut); top: 18px; width: var(--lw); height: auto; transform-origin: 0 0;
  animation: intro-fly .56s cubic-bezier(.6, 0, .2, 1) .4s backwards; }
@keyframes intro-fly { from { transform: translate(calc(50vw - var(--gut) - var(--lw) * .8), calc(50svh - 18px - var(--lw) * .229)) scale(1.6); } }
@keyframes intro-bg { to { background-color: rgb(14 13 11 / 0); } }
@keyframes intro-off { to { visibility: hidden; } }
.home .top .logo { animation: logo-in 0s linear .96s both; }
@keyframes logo-in { from { opacity: 0; } }
.no-intro .intro { display: none; }
.no-intro .top .logo { animation: none; }
.behind { position: absolute; inset: 0; display: grid; align-content: center; justify-items: center; gap: 22px; padding: 0 var(--gut); text-align: center;
  opacity: 0; transform: scale(.94); }
.behind .big { max-width: 30ch; }
.behind .more { text-decoration: none; margin-top: 14px; }
.cols { list-style: none; margin: 0; padding: 0; position: absolute; inset: 0; display: flex; gap: 2px; pointer-events: none; }
.col { position: relative; flex: 1 1 0; min-width: 0; overflow: hidden; pointer-events: auto;
  transition: flex-grow .8s cubic-bezier(.65, 0, .25, 1), opacity .5s; }
/* the columns, the title, the words behind and the phone's shade are moved by site.js (moveOpening),
   once per frame, with transforms only: nothing else on the page is restyled while you scroll */
.col, .opening h1 { will-change: transform; }
.still .cols:hover .col { flex-grow: .75; }
.still .cols .col:hover, .still .cols .col:focus-within { flex-grow: 2.4; }
/* a project opened: a copy of its picture grows to the whole screen (.grow), the title slides out to
   the left, labels and header fade; on the project page the title then zooms in (.arrive) */
.going .tag, .going .top { opacity: 0; transition: opacity .3s; }
.going .opening h1 { opacity: 0; transform: translateX(-28vw); transition: transform .65s cubic-bezier(.6, 0, .35, 1), opacity .5s ease .08s; }
.stage .grow { position: absolute; z-index: 2; }
.col a { position: absolute; inset: 0; display: block; color: #fff; text-decoration: none; }
.col picture, .col img { width: 100%; height: 100%; object-fit: cover; }
.col img { transition: filter .8s; }
.still .cols:hover .col:not(:hover) img { filter: brightness(.72); }
.col a::after { content: ''; position: absolute; inset: 0; background: linear-gradient(rgb(0 0 0 / .4), transparent 26%, transparent 52%, rgb(0 0 0 / .62)); pointer-events: none; }
.tag { position: absolute; z-index: 1; left: clamp(14px, 1.6vw, 24px); right: 12px; top: clamp(96px, 14vh, 130px); display: grid; gap: 4px; white-space: nowrap;
}
.tag .no { font: 600 11px/1 var(--body); letter-spacing: .18em; opacity: .75; }
.tag b { font: 500 clamp(1.2rem, 1.7vw, 1.7rem)/1.1 var(--head); letter-spacing: -0.02em; margin-top: 6px; overflow: hidden; text-overflow: ellipsis; }
.tag > span:not(.no):not(.go) { font-size: 14px; opacity: .85; }
.tag .go { margin-top: 10px; font: 600 11px/1 var(--body); letter-spacing: .18em; text-transform: uppercase; color: var(--azuolas);
  opacity: 0; transform: translateY(6px); transition: opacity .5s, transform .5s; }
.col:hover .go, .col:focus-within .go { opacity: 1; transform: none; }
.opening h1 { position: absolute; z-index: 3; left: var(--gut); bottom: clamp(48px, 10vh, 110px); color: #fff; font-size: clamp(2.6rem, 6.4vw, 6.8rem); max-width: 11ch;
  pointer-events: none; text-shadow: 0 2px 30px rgb(0 0 0 / .35); }
@media (max-width: 640px) {
  /* on a phone the pictures stack as bands, and part upwards and downwards */
  .opening { height: 190vh; }
  .cols { flex-direction: column; }
  .col a::after { background: linear-gradient(transparent 40%, rgb(0 0 0 / .35)); }
  .tag { display: none; }
  .shade { display: block; position: absolute; inset: 0; z-index: 2; pointer-events: none;
    background: linear-gradient(rgb(0 0 0 / .35), transparent 20%, transparent 55%, rgb(0 0 0 / .6)); }
  .opening h1 { bottom: 40px; font-size: clamp(2.2rem, 10vw, 2.8rem); }
}

/* ---------- sections ---------- */
section:not(.opening):not(.p-hero) { padding: clamp(80px, 15vh, 180px) var(--gut); }
.statement { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 3fr); gap: 24px; }
.statement .label { padding-top: .9em; }
.big { font: 400 clamp(1.7rem, 3.2vw, 3.2rem)/1.2 var(--head); letter-spacing: -0.015em; max-width: 28ch; text-wrap: pretty; }
@media (max-width: 760px) { .statement { grid-template-columns: 1fr; } }

/* projects: picks up from the studio's words. Pinned: the first project opens out of a thin line,
   then scrolling moves the projects sideways; the one in the middle comes forward, each picture
   drifts a little inside its frame. A click grows the picture to full screen and opens the project. */
.gallery { position: relative; height: calc((var(--n) * .62 + 1.4) * 100vh); }
.pin { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; display: flex; align-items: center; }
.g-head { position: absolute; left: var(--gut); top: 50%; translate: 0 -50%; width: min(32vw, 420px); display: grid; gap: 16px;
}
.g-head h2 { font-size: clamp(2.8rem, 5.6vw, 5.4rem); }
.g-intro { color: var(--muted); max-width: 34ch; }
.g-count { font: 600 11.5px/1 var(--body); letter-spacing: .18em; color: var(--muted); margin-top: 18px; }
.g-now { color: var(--ink); }
.track { list-style: none; margin: 0; padding: 0 0 0 max(40vw, 460px); display: flex; gap: 4vw; will-change: transform; }
.panel { flex: none; width: 62vw; height: 74vh; height: 74svh; transform: scale(.9); will-change: transform; }
.panel a { position: relative; display: block; height: 100%; color: #fff; text-decoration: none; }
.panel .frame { position: absolute; inset: 0; overflow: hidden; background: var(--bg-2);
}
.panel picture { position: absolute; inset: 0 -8%; }
.panel img { width: 100%; height: 100%; object-fit: cover; will-change: transform; }
/* the panels away from the middle are darker: an overlay's opacity, cheaper than a filter */
.panel .dim { position: absolute; inset: 0; z-index: 1; background: #000; opacity: .4; pointer-events: none; }
.panel .frame::after { content: ''; position: absolute; inset: 45% 0 0; z-index: 1; background: linear-gradient(transparent, rgb(0 0 0 / .6)); }
.p-meta { position: absolute; z-index: 1; left: clamp(18px, 2.4vw, 36px); bottom: clamp(18px, 3vh, 36px); right: 18px; display: grid; gap: 8px;
  opacity: 0; z-index: 2; }
.p-meta b { font: 500 clamp(2rem, 4vw, 4rem)/1 var(--head); letter-spacing: -0.02em; }
.p-meta .cap { color: rgb(255 255 255 / .8); }
.p-meta .go { font: 600 11px/1 var(--body); letter-spacing: .18em; text-transform: uppercase; color: var(--azuolas); margin-top: 6px; }
.panel a:hover .go { text-decoration: underline; text-underline-offset: 5px; }
.g-bar { position: absolute; left: var(--gut); right: var(--gut); bottom: 28px; height: 1px; background: var(--line); }
.g-bar i { position: absolute; inset: 0; background: var(--azuolas); transform: scaleX(0); transform-origin: left; }
@media (max-width: 760px) {
  .gallery { height: calc((var(--n) * .42 + 1.2) * 100vh); }
  .pin { align-items: flex-end; padding-bottom: 9vh; }
  .g-head { top: 92px; translate: none; width: auto; right: var(--gut); gap: 8px; }
  .g-head h2 { font-size: 2.6rem; }
  .g-intro { font-size: 14px; }
  .g-count { margin-top: 4px; }
  .track { padding-left: 8vw; gap: 5vw; }
  .panel { width: 84vw; height: 56vh; height: 56svh; }
}

/* the picture that grows to full screen when a project is opened */
.grow { position: fixed; z-index: 50; overflow: hidden; background: var(--bg-2); transition: inset .7s cubic-bezier(.65, 0, .25, 1); }
.arrive .p-title { animation: arrive 1.1s cubic-bezier(.2, .7, .2, 1) both; transform-origin: 0 100%; }
@keyframes arrive { from { opacity: 0; transform: scale(1.22); filter: blur(8px); } 60% { filter: blur(0); } }
.arrive .top { animation: fade-in .7s ease .25s both; }
@keyframes fade-in { from { opacity: 0; } }
.grow img { width: 100%; height: 100%; object-fit: cover; }

/* space and detail (brand book, page 4): one whole view, two close-ups of the same picture */
.detail { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(12px, 1.6vw, 24px); align-items: start; }
.whole img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.whole figcaption { margin-top: 12px; font-size: 14px; color: var(--muted); }
.crops { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(12px, 1.6vw, 24px); }
.crop { aspect-ratio: 4 / 5; overflow: hidden; }
.crop img { width: 100%; height: 100%; object-fit: cover; object-position: var(--x) var(--y); transform: scale(2.6); transform-origin: var(--x) var(--y); }
.crops .txt { grid-column: 1 / -1; display: grid; gap: 12px; max-width: 46ch; padding-top: 8px; color: var(--muted); }
.crops .txt h2 { color: var(--ink); font-size: clamp(2rem, 3.2vw, 3rem); }
@media (max-width: 900px) { .detail { grid-template-columns: 1fr; } }

/* services: each with a picture, alternating sides, then the steps of the work */
.services { background: var(--bg); color: var(--ink); position: relative; overflow-x: clip; border-top: 1px solid var(--line); }
.motif { position: absolute; right: var(--gut); top: clamp(56px, 9vh, 110px); width: clamp(120px, 15vw, 240px); color: var(--azuolas); opacity: .9; }
.s-head { display: grid; gap: 14px 64px; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: end; margin-bottom: clamp(56px, 10vh, 120px); position: relative; }
.s-head .label { grid-column: 1 / -1; }
.s-head h2 { font-size: clamp(2.6rem, 4.6vw, 4.8rem); }
.s-head .s-intro { max-width: 46ch; padding-bottom: .6em; }
@media (max-width: 860px) { .s-head { grid-template-columns: 1fr; } }
.s-head .h2b { display: block; color: var(--muted); }
.s-intro { opacity: .82; }
.s-list { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(64px, 12vh, 140px); position: relative; }
.svc { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 4fr); gap: clamp(28px, 6vw, 110px); align-items: center; }
.svc:nth-child(even) { grid-template-columns: minmax(0, 4fr) minmax(0, 5fr); }
.svc:nth-child(even) .s-pic { order: 2; }
.s-pic { aspect-ratio: 4 / 5; overflow: hidden; }
.s-pic img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.08); transition: transform 1.6s var(--slow); }
.s-pic.reveal { opacity: 1; transform: none; clip-path: inset(100% 0 0); transition: clip-path 1.3s cubic-bezier(.65, 0, .25, 1); }
.s-pic.reveal.in { clip-path: inset(0); }
.s-pic.in img { transform: none; }
.s-txt { display: grid; gap: 14px; max-width: 44ch; }
.s-txt h3 { font-size: clamp(2rem, 3.2vw, 3.2rem); }
.s-txt > p { opacity: .85; }
.s-txt ul { list-style: none; margin: 8px 0 0; padding: 0; border-top: 1px solid var(--line); }
.s-txt ul li { padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 15px; color: var(--muted); }
.s-tags { font: 500 12px/1.6 var(--body); letter-spacing: .16em; text-transform: uppercase; color: var(--azuolas); }
.s-result { font: 500 1.15rem/1.4 var(--head); color: var(--azuolas); }
/* technical drawings and supervision hold still while you scroll (site.js, "pinned services") */
.svc-plan, .svc-ba, .svc-concept { display: block; position: relative; }
.svc-plan { height: calc(var(--n) * 55vh + 100vh); }
.svc-concept { height: 180vh; }
.svc-ba { height: 180vh; }
/* the sliders (concept and supervision): --w is how far the line has moved, 0 to 1 */
.wipe { position: relative; margin: 0; aspect-ratio: 1; max-height: calc(100svh - 120px); width: 100%; justify-self: center; overflow: hidden; --w: 0; }
.wipe picture, .wipe img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.w-over { position: absolute; inset: 0; }
.w-grow .w-over { clip-path: inset(0 0 calc((1 - var(--w)) * 100%) 0); }
.w-shrink .w-over { clip-path: inset(calc(var(--w) * 100%) 0 0 0); }
/* the line moves from top to bottom: the bottom edge of a box as tall as the picture, moved with a transform.
   Only a line, no handle, so it does not look like something to drag */
.w-edge { position: absolute; inset: 0; pointer-events: none; will-change: transform; opacity: clamp(0, min(var(--w), 1 - var(--w)) * 16, 1); }
.w-edge { transform: translate3d(0, calc((var(--w) - 1) * 100%), 0); }
.w-edge i { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: #fff; box-shadow: 0 0 20px rgb(0 0 0 / .5); }
.w-tag { position: absolute; z-index: 2; top: 16px; padding: 7px 12px; border-radius: 99px; background: rgb(14 13 11 / .6); font: 600 10.5px/1 var(--body); letter-spacing: .16em; text-transform: uppercase; }
.w-a { left: 16px; top: auto; bottom: 16px; opacity: calc(1 - var(--w) * 1.6); }
.w-b { left: 16px; opacity: calc(var(--w) * 1.6 - .2); }
.pin2 { position: sticky; top: 0; height: 100vh; height: 100svh; display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 6fr); gap: clamp(28px, 5vw, 90px); align-items: center; padding: 84px 0 24px; }
.svc-ba .pin2 { grid-template-columns: minmax(0, 6fr) minmax(0, 4fr); }
.svc-ba .s-txt { order: 2; }
.sheets { list-style: none; margin: 6px 0 0; padding: 0; border-top: 1px solid var(--line); }
.sheets li { display: grid; grid-template-columns: 2.2em 1fr; padding: 7px 0; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 14.5px; transition: color .4s; }
.sheets li::before { content: attr(data-n); font: 600 11px/2 var(--body); letter-spacing: .12em; }
.sheets b { font-weight: 500; }
.sheets span { grid-column: 2; max-height: 0; overflow: hidden; opacity: 0; transition: max-height .5s, opacity .5s; font-size: 13.5px; }
.sheets li[aria-current] { color: var(--ink); }
.sheets li[aria-current]::before { color: var(--azuolas); }
.sheets li[aria-current] span { max-height: 3em; opacity: .75; }
/* the drawing: ink on white paper, as on his sheets */
.paper { position: relative; margin: 0; background: #fbfaf6; border-radius: 2px; padding: 1.5%; box-shadow: 0 30px 60px -30px rgb(0 0 0 / .9); max-height: calc(100svh - 120px); aspect-ratio: 24900 / 19300; justify-self: center; width: 100%; }
.paper svg { display: block; width: 100%; height: 100%; }
.p-art { position: relative; width: 100%; height: 100%; }
/* the render of the house over the drawing, fading as you scroll into the sheets */
.p-render { position: absolute; inset: 0; opacity: var(--r, 1); pointer-events: none; }
.p-render picture, .p-render img { width: 100%; height: 100%; object-fit: fill; }
.sheet-name { position: absolute; right: 12px; bottom: 10px; font: 600 10.5px/1 var(--body); letter-spacing: .16em; text-transform: uppercase; color: #6b6f76; }
.plan { --ink2: #1c1c1e; --red: #d6331f; --blue: #1d3fd8; --magenta: #c013b4; --orange: #e8891a; --green: #1c9a3c; --violet: #4b46c8; }
.plan * { vector-effect: non-scaling-stroke; }
.plan defs * { vector-effect: none; }
.plan text { font-family: Arial, Helvetica, sans-serif; }
.plan .wall { stroke: var(--ink2); stroke-width: 1.3; }
.plan .room { fill: #fff; stroke: var(--ink2); stroke-width: 1.1; }
.plan .openedge { stroke: #fff; stroke-width: 4; }
.plan .gap { fill: #fff; }
.plan .glass { fill: #fff; stroke: var(--ink2); stroke-width: 1; }
.plan .thin { fill: none; stroke: var(--ink2); stroke-width: .8; }
.plan .leaf { fill: none; stroke: var(--ink2); stroke-width: 1.3; }
.plan .swing { fill: none; stroke: var(--ink2); stroke-width: .8; stroke-dasharray: 4 3; }
.plan .terrace { fill: none; stroke: #6b6f76; stroke-width: 1; stroke-dasharray: 7 5; }
.plan .newwall { fill: url(#h-new); stroke: var(--red); stroke-width: 1; }
.plan .wcframe { fill: url(#h-frame); stroke: var(--blue); stroke-width: 1; }
.plan .ceil { stroke: none; opacity: .75; }
.plan .floor { stroke: var(--ink2); stroke-width: 1.1; }
.plan .L-furn { fill: #fff; stroke: #2a2d33; stroke-width: .9; }
.plan .L-furnFaint { fill: none; stroke: #b4b6bb; stroke-width: .8; }
.plan .L-furn path, .plan .L-furnFaint path { fill: none; }
.plan .tagbox { fill: #fff; stroke: var(--ink2); stroke-width: 1; }
.plan .tagnum { font-size: 265px; font-weight: 700; fill: var(--ink2); }
.plan .dim path { fill: none; stroke: #2a2d33; stroke-width: .9; }
.plan .dim text { font-size: 260px; fill: #2a2d33; }
.plan .axis { fill: none; stroke: var(--red); stroke-width: .8; stroke-dasharray: 6 4; }
.plan .light { fill: none; stroke: var(--blue); stroke-width: 1.1; }
.plan .light text { font-size: 215px; fill: var(--magenta); stroke: none; }
.plan .L-lightsFaint .light { stroke: #a9abb1; }
.plan .L-lightsFaint .light text { fill: #8d9097; }
.plan .sens { fill: none; stroke: var(--red); stroke-width: 1.2; }
.plan .lines path { fill: none; stroke-width: 3; }
.plan .lines text { font-size: 215px; fill: var(--magenta); }
.plan .ln-track { stroke: var(--violet); } .plan .ln-surface { stroke: var(--orange); } .plan .ln-profile { stroke: var(--green); } .plan .ln-led { stroke: var(--orange); stroke-dasharray: 2 3; }
.plan .el { stroke: var(--blue); stroke-width: 1.1; fill: none; }
.plan .e-open { fill: #fff; } .plan .e-grey { fill: #a9adb5; } .plan .e-fill { fill: #cfd8fb; } .plan .e-wet { fill: #7f98f0; } .plan .e-lead { fill: #fff; } .plan .e-dot { fill: var(--blue); }
.plan .thermo { fill: #fff; stroke: var(--red); stroke-width: 1.2; }
.plan .outlet { fill: #f9c9c2; stroke: #a31a0b; stroke-width: 1.1; }
.plan .channel { stroke: var(--blue); stroke-width: 3.5; fill: none; }
.plan .trap { fill: #fff; stroke: var(--blue); stroke-width: 1.4; }
.plan .diff { fill: none; stroke-width: 1.2; } .plan .diff-s { stroke: var(--blue); } .plan .diff-e { stroke: var(--red); }
.plan .start path { stroke: var(--red); stroke-width: 1.4; fill: none; }
.plan .start text { font-size: 180px; font-style: italic; fill: var(--red); }
.plan .callout rect { fill: #fff; stroke: var(--red); stroke-width: 1; stroke-dasharray: 5 3; }
.plan .callout text { font-size: 290px; fill: var(--ink2); }
.plan .callout text.head { font-weight: 700; }
.plan .leader { stroke: var(--red); stroke-width: .9; fill: none; }
.plan .tip { fill: var(--red); }
/* each layer comes in piece by piece when its sheet is reached (which sheets: the <style> on the home page) */
.plan .L { opacity: 0; transition: opacity .35s; }
.plan .L > g { opacity: 0; transform: translateY(-60px); transition: opacity .35s, transform .45s cubic-bezier(.2, .7, .2, 1); transition-delay: calc(var(--i) * var(--step)); }
@media (max-width: 860px) {
  /* less scrolling per pinned block on a phone */
  .svc-plan { height: calc(var(--n) * 36vh + 100vh); }
  .svc-ba { height: 150vh; }
  .svc-concept { height: 150vh; }
  .pin2, .svc-ba .pin2 { grid-template-columns: 1fr; grid-template-rows: auto 1fr; align-content: start; gap: 16px; padding-top: 76px; }
  .svc-ba .s-txt { order: 0; }
  .pin2 .s-txt > p:not(.s-tags), .pin2 .s-txt ul, .pin2 .s-result { display: none; }
  .pin2 .s-txt h3 { font-size: 1.7rem; }
  .sheets li { display: none; }
  .sheets li[aria-current] { display: grid; }
  .paper, .wipe { align-self: start; max-height: none; }
  .sheet-name { display: none; }
}
.process { margin-top: clamp(80px, 14vh, 160px); position: relative; }
.process h3 { font-size: clamp(1.8rem, 2.6vw, 2.6rem); margin-bottom: 32px; }
.process ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 28px; }
.process li { border-top: 1px solid var(--line); padding-top: 18px; display: grid; gap: 8px; }
.process b { font: 500 1.3rem/1.2 var(--head); }
.process p { color: var(--muted); font-size: 15px; }
@media (max-width: 860px) { .svc, .svc:nth-child(even) { grid-template-columns: 1fr; } .svc:nth-child(even) .s-pic { order: 0; } .motif { opacity: .25; } }

/* about: his portrait and a few words */
/* the picture (and on wide screens the text) holds still until his portrait has come down over the hard-hat one:
   .a-hold is the picture plus one screen of scrolling; the change runs while it covers the screen */
.about { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 5fr); gap: clamp(28px, 6vw, 110px); align-items: start; border-top: 1px solid var(--line);
  --fh: min(650px, calc(100svh - 140px)); }
.a-hold { height: calc(var(--fh) + 100svh); }
.a-pic { position: sticky; top: calc(50svh - var(--fh) / 2 + 30px); height: var(--fh); aspect-ratio: 4 / 5; max-width: 100%; overflow: hidden; }
.a-txt { position: sticky; top: max(90px, calc(50svh - 300px)); }
.a-pic { --a: 0; }
.a-pic img { width: 100%; height: 100%; object-fit: cover; }
/* first in a hard hat, then his portrait comes down over it as you scroll past (--a 0 to 1; CSS timeline below where supported) */
.a-over { position: absolute; inset: 0; clip-path: inset(0 0 calc((1 - var(--a)) * 100%) 0); }
.a-over picture { display: block; height: 100%; }
.a-edge { position: absolute; inset: 0; pointer-events: none; transform: translate3d(0, calc((var(--a) - 1) * 100%), 0); opacity: clamp(0, min(var(--a), 1 - var(--a)) * 16, 1); }
.a-edge::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: #fff; box-shadow: 0 0 20px rgb(0 0 0 / .5); }
.a-pic.reveal { opacity: 1; transform: none; clip-path: inset(100% 0 0); transition: clip-path 1.3s cubic-bezier(.65, 0, .25, 1); }
.a-pic.reveal.in { clip-path: inset(0); }
.a-txt { display: grid; gap: 16px; max-width: 50ch; }
.a-txt h2 { font-size: clamp(2.4rem, 4.4vw, 4.2rem); }
.a-txt > p:not(.label):not(.a-name) { color: var(--muted); }
.a-name { display: grid; gap: 2px; margin-top: 6px; }
.a-name b { font: 500 1.6rem/1.2 var(--head); }
.a-name span { color: var(--azuolas); font-size: 14px; }
.a-facts { list-style: none; margin: 10px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 24px; }
.a-facts li { border-top: 1px solid var(--line); padding-top: 10px; font-size: 14px; }
@media (max-width: 860px) { .about { grid-template-columns: 1fr; --fh: min(calc((100vw - 2 * var(--gut)) * 1.25), calc(100svh - 120px)); } .a-pic { top: 84px; } .a-hold { height: calc(var(--fh) + 100svh); } .a-txt { position: static; } }

/* the contact: centred; each block's label sits above its line, the lines below it are plain
   (links show only by colour on hover), so the three columns read evenly */
.contact { text-align: center; }
.contact h2 { font-size: clamp(2.8rem, 7.4vw, 7.2rem); max-width: 12ch; margin: 18px auto 0; }
/* the two short paragraphs under the title: one asks, one invites */
.c-text { color: var(--muted); max-width: 40ch; margin: 30px auto 0; font-size: clamp(1.15rem, 1.5vw, 1.35rem); line-height: 1.5; text-wrap: balance; }
.c-text + .c-text { margin-top: 10px; color: var(--ink); }
.c-info { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 clamp(24px, 4vw, 64px); max-width: 1000px; margin: clamp(56px, 9vh, 96px) auto 0; }
.c-info > div { display: grid; gap: 8px; align-content: start; justify-items: center; }
.c-info dt { justify-self: stretch; padding-bottom: 14px; margin-bottom: 8px; border-bottom: 1px solid var(--line); }
.c-info dd { margin: 0; font-size: clamp(1.05rem, 1.4vw, 1.25rem); }
.c-info a { text-decoration: none; transition: color .3s; }
.c-info a:hover { color: var(--azuolas); }
/* on a phone: one centred column; the gold labels separate the blocks, no lines */
@media (max-width: 760px) {
  .c-info { grid-template-columns: 1fr; gap: 44px; margin-top: 56px; }
  .c-info > div { gap: 6px; }
  .c-info dt { justify-self: center; border-bottom: 0; padding-bottom: 0; margin-bottom: 6px; }
  .c-info dd { font-size: 1.15rem; }
}
.c-btn { display: inline-block; margin-top: 34px; padding: 16px 30px; border-radius: 99px; background: var(--azuolas); color: var(--bg); text-decoration: none; font: 600 12px/1 var(--body); letter-spacing: .18em; text-transform: uppercase; transition: background .3s; }
.c-btn:hover { background: var(--ink); }
.contact .links { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 12px 40px; justify-content: center; font-size: clamp(1rem, 1.4vw, 1.25rem); }
.contact .links a { text-decoration: none; border-bottom: 1px solid var(--azuolas); padding-bottom: 4px; }
.foot { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 32px; padding: 32px var(--gut) 48px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.foot img { width: 120px; height: auto; opacity: .9; }
.foot a { text-decoration: none; color: var(--ink); }
.foot .proto { margin-left: auto; font-size: 13px; }
/* every page ends with the contact section; the footer under it is centred */
.foot { flex-direction: column; gap: 8px; text-align: center; }

.foot .credit { font-size: 13px; display: grid; justify-items: center; gap: 10px; }
.foot .kz-sign { color: var(--ink); opacity: .85; transition: opacity .3s; }
.foot .kz-sign:hover { opacity: 1; }

/* ---------- project page (hilight): full hero, the rooms one after another ---------- */
.p-hero { position: relative; height: 100vh; height: 100svh; overflow: hidden; background: var(--bg-2); color: #fff; }
.p-hero picture, .p-hero img { width: 100%; height: 100%; object-fit: cover; }
.p-hero::after { content: ''; position: absolute; inset: 0; background: linear-gradient(rgb(0 0 0 / .35), transparent 22%, transparent 45%, rgb(0 0 0 / .6)); }
.p-title { position: absolute; z-index: 1; left: var(--gut); bottom: clamp(36px, 9vh, 110px); display: grid; gap: 14px; animation: rise 1.4s var(--slow) .4s both; }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }
.p-title h1 { font-size: clamp(3.2rem, 8.4vw, 8.4rem); }
.p-intro { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.p-intro dl { margin: 0; display: grid; gap: 18px; }
.p-intro dt { font: 600 11.5px/1.3 var(--body); letter-spacing: .18em; text-transform: uppercase; color: var(--azuolas); }
.p-intro dd { margin: 4px 0 0; color: var(--muted); }
@media (max-width: 860px) { .p-intro { grid-template-columns: 1fr; } }
.room { padding-top: 0 !important; }
.room-head { display: flex; align-items: baseline; gap: 18px; border-top: 1px solid var(--line); padding-top: 22px; margin-bottom: clamp(20px, 4vh, 40px); }
.room-head h2 { font-size: clamp(2.1rem, 3.8vw, 3.6rem); }
.pics { display: grid; gap: clamp(10px, 1.4vw, 20px); }
.pics figure { overflow: hidden; background: var(--bg-2); cursor: zoom-in; }
.pics img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.6s var(--slow); }
.pics figure:hover img { transform: scale(1.04); }
.room-1 .pics img { aspect-ratio: 16 / 9; }
.room-2 .pics { grid-template-columns: 1fr 1fr; }
.room-2 .pics img { aspect-ratio: 4 / 5; }
.room-3 .pics, .room-4 .pics { grid-template-columns: 2fr 1fr; grid-auto-rows: 1fr; }
.room-3 .pics figure:first-child, .room-4 .pics figure:first-child { grid-row: span 2; }
.room-4 .pics { grid-template-columns: 2fr 1fr 1fr; }
.room-4 .pics figure:first-child { grid-row: span 2; }
.room-4 .pics figure:nth-child(4) { grid-column: 2 / span 2; }
.room-many .pics { grid-template-columns: repeat(3, 1fr); grid-auto-rows: auto; }
.room-many .pics figure:first-child { grid-row: auto; grid-column: span 2; }
.room-many .pics img { aspect-ratio: 1; }
.room-many .pics figure:first-child img { aspect-ratio: auto; }
@media (max-width: 760px) {
  .pics, .room-2 .pics, .room-3 .pics, .room-4 .pics, .room-many .pics { grid-template-columns: 1fr; grid-auto-rows: auto; }
  .pics figure:first-child, .room-4 .pics figure:nth-child(4), .room-many .pics figure:first-child { grid-row: auto; grid-column: auto; }
  .pics img { aspect-ratio: 4 / 5 !important; }
}
.next { position: relative; display: block; height: 70vh; overflow: hidden; color: #fff; text-decoration: none; background: var(--bg-2); }
.next picture, .next img { width: 100%; height: 100%; object-fit: cover; }
.next img { transition: transform 1.8s var(--slow); opacity: .75; }
.next:hover img { transform: scale(1.05); }
.next > span { position: absolute; left: var(--gut); bottom: clamp(32px, 7vh, 80px); display: grid; gap: 12px; }
.next b { font: 500 clamp(2.6rem, 6.4vw, 6.4rem)/1 var(--head); letter-spacing: -0.02em; }

/* picture viewer */
.lightbox { padding: 0; border: 0; width: 100vw; height: 100vh; max-width: none; max-height: none; background: rgb(8 8 7 / .97); }
.lightbox::backdrop { background: rgb(0 0 0 / .7); }
.lightbox img { width: 100%; height: 100%; object-fit: contain; padding: 56px 16px; }
.lightbox button { position: absolute; border: 0; background: rgb(245 241 232 / .12); color: #fff; font: 22px/1 var(--body); width: 48px; height: 48px; border-radius: 99px; cursor: pointer; }
.lb-x { top: 16px; right: 16px; }
.lb-prev { left: 16px; top: 50%; }
.lb-next { right: 16px; top: 50%; }

/* ---------- scroll-linked movement in CSS, where the browser can (Safari 26, Chrome 115) ----------
   Tied to the scroll position itself, so it stays in step with the finger on an iPhone, where
   scrolling runs apart from the page's script. Elsewhere site.js does the same per frame.
   "contain" = while the pinned block fills the screen, the same range site.js measures. */
@supports (animation-timeline: view()) {
  .opening { view-timeline: --opening block; }
  .col:nth-child(-n+2), .opening h1 { animation: part-left linear both; animation-timeline: --opening; animation-range: contain 0% contain 70%; }
  .col:nth-child(n+3) { animation: part-right linear both; animation-timeline: --opening; animation-range: contain 0% contain 70%; }
  .behind { animation: behind-in linear both; animation-timeline: --opening; animation-range: contain 0% contain 70%; }
  @media (max-width: 640px) {
    .col:nth-child(-n+2) { animation-name: part-up; }
    .col:nth-child(n+3), .opening h1 { animation-name: part-down; }
    .shade { animation: shade-out linear both; animation-timeline: --opening; animation-range: contain 0% contain 23%; }
  }
  .gallery { view-timeline: --gallery block; }
  .track { animation: track linear both; animation-timeline: --gallery; animation-range: contain 20% contain 100%; }
  .g-head { animation: head-out linear both; animation-timeline: --gallery; animation-range: contain 20% contain 46.7%; }
  .g-bar i { animation: bar linear both; animation-timeline: --gallery; animation-range: contain 0% contain 100%; }
  .panel:first-child .frame { animation: first-open linear both; animation-timeline: --gallery; animation-range: contain 0% contain 16%; }
  .svc-concept, .svc-ba { view-timeline: --wipe block; }
  .a-hold { view-timeline: --about block; }
  .a-over, .a-edge { animation-timeline: --about; animation-range: contain 5% contain 85%; animation-fill-mode: both; animation-timing-function: linear; }
  .a-over { animation-name: a-over; }
  .a-edge { animation-name: a-edge; }
  /* always from worse to better: the picture arrives showing the sketch (or the works) whole; the line moves only while the block holds still */
  .wipe .w-over, .wipe .w-edge, .wipe .w-tag { animation-timeline: --wipe; animation-range: contain 5% contain 80%; animation-fill-mode: both; animation-timing-function: linear; }
  .w-grow .w-over { animation-name: w-grow-over; }
  .w-shrink .w-over { animation-name: w-shrink-over; }
  .wipe .w-edge { animation-name: w-edge; }
  .w-a { animation-name: w-out; }
  .w-b { animation-name: w-in; }
}
@keyframes a-over { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes a-edge { from { transform: translate3d(0, -100%, 0); opacity: 0; } 6%, 94% { opacity: 1; } to { transform: translate3d(0, 0, 0); opacity: 0; } }
@keyframes w-grow-over { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes w-shrink-over { from { clip-path: inset(0 0 0 0); } to { clip-path: inset(100% 0 0 0); } }
@keyframes w-edge { from { transform: translate3d(0, -100%, 0); opacity: 0; } 6%, 94% { opacity: 1; } to { transform: translate3d(0, 0, 0); opacity: 0; } }
@keyframes w-out { 60%, to { opacity: 0; } }
@keyframes w-in { from, 40% { opacity: 0; } to { opacity: 1; } }
@keyframes part-left { to { transform: translate3d(-56vw, 0, 0); } }
@keyframes part-right { to { transform: translate3d(56vw, 0, 0); } }
@keyframes part-up { to { transform: translate3d(0, -56vh, 0); } }
@keyframes part-down { to { transform: translate3d(0, 56vh, 0); } }
@keyframes behind-in { from { opacity: 0; transform: scale(.94); } 45% { opacity: 1; } to { opacity: 1; transform: none; } }
@keyframes shade-out { to { opacity: 0; } }
@keyframes track { to { transform: translate3d(calc(var(--shift, 0) * -1px), 0, 0); } }
@keyframes head-out { to { opacity: 0; transform: translate3d(-40px, 0, 0); } }
@keyframes bar { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes first-open { from { clip-path: inset(0 49.2% round 2px); } to { clip-path: inset(0 0 round 2px); } }

/* reveal */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 1.1s, transform 1.1s var(--slow); transition-delay: calc(var(--d, 0) * 90ms); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  .intro { display: none; }
}
/* raised minutes in opening hours (9⁰⁰ – 18⁰⁰); the line keeps its height */
.c-info sup, .foot sup { font-size: .62em; line-height: 0; vertical-align: .55em; margin-left: .06em; letter-spacing: .02em; }
/* Instagram: its mark and the word */
.ig-link { display: inline-flex; align-items: center; gap: .45em; vertical-align: middle; }
.ig-link .ig { display: block; flex: none; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
