/* Arkkitehtitoimisto Haljala Oy. Sivuston tyylit, versio 1 (lokakuu 2026). */

@font-face {
  font-family: "Source Serif 4";
  src: url("fonts/source-serif-4-latin.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Public Sans";
  src: url("fonts/public-sans-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #f3f0e9;
  --stone: #e7e2d8;
  --line: #d5cec1;
  --ink: #1e1c18;
  --ink-2: #5e584e;
  --edge: #8a8273;
  --terva: #2e2620;
  --terva-2: #b9afa0;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Public Sans", "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
  --m: clamp(20px, 3.9vw, 56px);
  --gap: 24px;
  --sec: clamp(72px, 9vw, 136px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-optical-sizing: auto;
  font-size: 19px;
  line-height: 1.58;
  font-weight: 400;
  font-kerning: normal;
  font-variant-numeric: lining-nums proportional-nums;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg, picture { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration-line: underline; text-decoration-thickness: 1px; text-underline-offset: 0.22em; text-decoration-color: color-mix(in srgb, currentColor 45%, transparent); transition: text-decoration-color .4s var(--ease), text-decoration-thickness .4s var(--ease); }
a:hover { text-decoration-color: currentColor; text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--terva); outline-offset: 3px; }
.foot :focus-visible { outline-color: var(--paper); }
h1, h2, h3, h4 { margin: 0; font-weight: 400; }
p { margin: 0 0 0.9em; }
p:last-child { margin-bottom: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
dl, dd { margin: 0; }
button { font: inherit; color: inherit; }
::selection { background: var(--terva); color: var(--paper); }

.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; background: var(--terva); color: var(--paper); padding: 10px 14px; font: 500 15px/1.2 var(--sans); text-decoration: none; transition: top .2s; }
.skip:focus { top: 12px; }

.sans { font-family: var(--sans); }
.label { font: 500 14px/1.4 var(--sans); letter-spacing: 0.005em; color: var(--ink-2); }
.meta { font: 400 15px/1.5 var(--sans); color: var(--ink-2); }
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); padding-inline: var(--m); }
.wrap { padding-inline: var(--m); }
.tnum { font-variant-numeric: tabular-nums lining-nums; }

/* ------------------------------------------------------------------ header */
.head { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 22px var(--m); position: relative; z-index: 20; }
.brand { display: inline-block; white-space: nowrap; line-height: 1; text-decoration: none; color: var(--ink); }
/* Inline layout so the wordmark sits on the text baseline: the j's descender (9.25 % of the width) hangs below it. */
.brand__wm { display: inline-block; vertical-align: baseline; width: 100px; height: auto; fill: currentColor; margin-bottom: -9.25px; }
.brand__desc { margin-left: 12px; font: 500 13px/1 var(--sans); letter-spacing: 0.01em; color: var(--ink-2); }
.nav ul { display: flex; gap: 30px; }
.nav a { font: 500 15px/1.3 var(--sans); text-decoration: none; padding-block: 6px; background-image: linear-gradient(currentColor, currentColor); background-size: 0 1px; background-position: 0 100%; background-repeat: no-repeat; transition: background-size .5s var(--ease); }
.nav a:hover, .nav a[aria-current="page"] { background-size: 100% 1px; }
.menu-btn { display: none; }

/* ------------------------------------------------------------------ frames, images, reveal */
.frame { position: relative; overflow: hidden; background: var(--stone); }
.frame img, .frame picture { width: 100%; height: 100%; }
.frame img { object-fit: cover; }
.cap { display: flex; justify-content: space-between; gap: 16px; margin-top: 10px; font: 400 13px/1.45 var(--sans); letter-spacing: 0.005em; color: var(--ink-2); }
.cap a { color: var(--ink); }

/* Kuva avautuu alhaalta ylös: paperinvärinen peite kutistuu ylöspäin, kun kuva on ladattu. */
.js [data-reveal].frame::after { content: ""; position: absolute; inset: 0; z-index: 1; background: var(--paper); transform-origin: 50% 0; transition: transform 1.1s var(--ease); pointer-events: none; }
.js [data-reveal].frame.is-in::after { transform: scaleY(0); }
.js [data-reveal].frame img { transform: scale(1.05); transition: transform 1.6s var(--ease); }
.js [data-reveal].frame.is-in img { transform: none; }
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.9s var(--ease), transform 1.1s var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .reveal.d1 { transition-delay: .08s; } .js .reveal.d2 { transition-delay: .16s; } .js .reveal.d3 { transition-delay: .24s; }

/* ------------------------------------------------------------------ home */
.intro { padding-top: clamp(28px, 4.2vw, 64px); padding-bottom: clamp(28px, 3.4vw, 48px); align-items: end; }
.intro__title { grid-column: 1 / 9; font-size: clamp(27px, 2.7vw, 40px); line-height: 1.17; letter-spacing: -0.012em; font-weight: 360; text-wrap: pretty; max-width: 22em; }
.intro__aside { grid-column: 10 / 13; font: 400 14.5px/1.55 var(--sans); color: var(--ink-2); }
.intro__aside p { margin: 0 0 6px; }
.intro__aside strong { font-weight: 500; color: var(--ink); }

.hero { margin: 0; }
.hero .frame { height: min(78vh, 60vw); min-height: 360px; }
.hero .cap { padding-inline: var(--m); }

.sec { padding-top: var(--sec); }
.sec-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding-inline: var(--m); padding-bottom: 28px; }
.sec-head h2 { font: 500 14px/1.4 var(--sans); color: var(--ink-2); letter-spacing: 0.005em; }
.sec-head a { font: 500 14px/1.4 var(--sans); }

.work { margin-bottom: clamp(80px, 8vw, 128px); align-items: end; row-gap: 22px; }
.work:last-child { margin-bottom: 0; }
.work__img { grid-column: 1 / 9; }
.work__img .frame { aspect-ratio: 3 / 2; }
.work__txt { grid-column: 10 / 13; padding-bottom: 4px; }
.work--r .work__img { grid-column: 5 / 13; grid-row: 1; }
.work--r .work__txt { grid-column: 1 / 4; grid-row: 1; }
.work--pair .work__img { grid-column: 1 / 8; }
.work--pair .work__img2 { grid-column: 9 / 13; align-self: start; }
.work--pair .work__img2 .frame { aspect-ratio: 4 / 5; }
.work--pair .work__txt { grid-column: 9 / 13; grid-row: 2; }
.work--mid .work__img { grid-column: 3 / 11; }
.work--mid .work__txt { grid-column: 3 / 9; }
.work__name { font-size: clamp(25px, 2.1vw, 31px); line-height: 1.15; letter-spacing: -0.01em; font-weight: 400; margin-bottom: 8px; }
.work__name a { text-decoration: none; }
.work__name a:hover { text-decoration: underline; text-decoration-thickness: 1px; }
.work__meta { font: 400 14px/1.5 var(--sans); color: var(--ink-2); margin-bottom: 12px; }
.work__desc { font-size: 18px; line-height: 1.5; margin-bottom: 14px; }
.more { font: 500 14px/1.4 var(--sans); }

.now__list { border-top: 1px solid var(--line); }
.now__row { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); padding: 15px 0 14px; border-bottom: 1px solid var(--line); align-items: baseline; }
.now__name { grid-column: 1 / 5; font-size: 20px; line-height: 1.3; }
.now__place { grid-column: 5 / 7; font: 400 15px/1.45 var(--sans); color: var(--ink-2); }
.now__state { grid-column: 7 / 13; font: 400 15px/1.45 var(--sans); }
.now__note { margin-top: 28px; max-width: 38em; font-size: 19px; }
.now-wrap { padding-inline: var(--m); }

.office { align-items: center; row-gap: 28px; }
.office__img { grid-column: 1 / 6; }
.office__img .frame { aspect-ratio: 4 / 3; }
.office__txt { grid-column: 7 / 12; }
.lede { font-size: clamp(22px, 1.95vw, 28px); line-height: 1.32; letter-spacing: -0.006em; font-weight: 380; text-wrap: pretty; }

.news-list { border-top: 1px solid var(--line); }
.news-list li { border-bottom: 1px solid var(--line); }
.news-list a { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); padding: 16px 0 15px; text-decoration: none; align-items: baseline; }
.news-list time { grid-column: 1 / 3; font: 400 15px/1.4 var(--sans); color: var(--ink-2); }
.news-list span { grid-column: 3 / 11; font-size: 20px; line-height: 1.35; }
.news-list a:hover span { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }

.band { margin-top: var(--sec); background: var(--stone); padding-block: clamp(56px, 6.5vw, 96px); }
.band__txt { grid-column: 1 / 8; }
.band__aside { grid-column: 9 / 13; font: 400 15px/1.6 var(--sans); align-self: end; }
.band__aside p { margin-bottom: 4px; }

/* ------------------------------------------------------------------ page heads */
.page-head { padding-top: clamp(36px, 5vw, 80px); padding-bottom: clamp(32px, 4vw, 56px); row-gap: 18px; }
.crumb { grid-column: 1 / -1; font: 500 14px/1.4 var(--sans); color: var(--ink-2); }
.crumb a { color: var(--ink-2); }
.page-title { grid-column: 1 / 11; font-size: clamp(40px, 4.6vw, 68px); line-height: 1.03; letter-spacing: -0.022em; font-weight: 340; }
.page-lede { grid-column: 1 / 9; font-size: clamp(21px, 1.8vw, 26px); line-height: 1.34; font-weight: 380; letter-spacing: -0.004em; text-wrap: pretty; }
.page-meta { grid-column: 1 / -1; font: 400 15px/1.5 var(--sans); color: var(--ink-2); }

/* ------------------------------------------------------------------ project page */
.case-hero { margin: 0; }
.case-hero .frame { height: min(86vh, 64vw); min-height: 340px; }
.case-hero .cap { padding-inline: var(--m); }
.case-intro { padding-top: clamp(48px, 6vw, 96px); row-gap: 40px; align-items: start; }
.facts { grid-column: 1 / 5; border-top: 1px solid var(--line); font: 400 15px/1.5 var(--sans); }
.facts div { display: grid; grid-template-columns: 7.6em 1fr; gap: 12px; padding: 10px 0 9px; border-bottom: 1px solid var(--line); }
.facts dt { color: var(--ink-2); }
.case-text { grid-column: 6 / 12; }
.case-text .lede { margin-bottom: 1.1em; }
.chapter { padding-top: clamp(56px, 6vw, 96px); align-items: start; }
.chapter h2 { grid-column: 1 / 5; font-size: clamp(23px, 1.9vw, 28px); line-height: 1.2; letter-spacing: -0.008em; padding-top: 2px; }
.chapter .txt { grid-column: 6 / 12; max-width: 36em; }
.fig { margin: 0; padding-top: clamp(48px, 5vw, 80px); }
.fig--full .frame { height: min(90vh, 62vw); }
.fig--full .cap { padding-inline: var(--m); }
.pair { padding-top: clamp(48px, 5vw, 80px); align-items: end; row-gap: 40px; }
.pair figure { margin: 0; }
.pair__a { grid-column: 1 / 8; }
.pair__a .frame { aspect-ratio: 3 / 2; }
.pair__b { grid-column: 9 / 13; }
.pair__b .frame { aspect-ratio: 4 / 5; }
.pair--flip .pair__a { grid-column: 6 / 13; }
.pair--flip .pair__b { grid-column: 1 / 5; grid-row: 1; }
.pair--even .pair__a { grid-column: 1 / 7; }
.pair--even .pair__b { grid-column: 7 / 13; }
.pair--even .pair__b .frame { aspect-ratio: 3 / 2; }
.single { padding-top: clamp(48px, 5vw, 80px); }
.single figure { margin: 0; grid-column: 3 / 11; }
.single .frame { aspect-ratio: 3 / 2; }
.single--tall figure { grid-column: 4 / 10; }
.single--tall .frame { aspect-ratio: 4 / 5; }

.drawing { padding-top: clamp(56px, 6vw, 96px); }
.drawing figure { margin: 0; grid-column: 1 / -1; }
.drawing__f { background: color-mix(in srgb, var(--stone) 55%, var(--paper)); padding: clamp(18px, 3vw, 48px); }
.drawing__f .dw { width: 100%; height: auto; max-height: 78vh; margin-inline: auto; }
.drawing--narrow figure { grid-column: 2 / 12; }
.drawing .legend { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); column-gap: var(--gap); row-gap: 2px; margin-top: 14px; font: 400 14px/1.5 var(--sans); counter-reset: r; }
.drawing .legend li { counter-increment: r; display: flex; gap: 8px; }
.drawing .legend li::before { content: counter(r); min-width: 1.6em; font-weight: 500; }
.drawing .legend b { font-weight: 400; color: var(--ink-2); margin-left: auto; padding-right: 16px; }
.drawings-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); }

/* SVG-piirustukset */
.dw { color: var(--ink); overflow: visible; }
.dw .w { fill: currentColor; }
.dw .sb { fill: var(--paper); }
.dw .l { fill: none; stroke: currentColor; stroke-width: 1.1; vector-effect: non-scaling-stroke; }
.dw .t { fill: none; stroke: currentColor; stroke-width: .75; vector-effect: non-scaling-stroke; opacity: .78; }
.dw .g { fill: none; stroke: currentColor; stroke-width: .6; vector-effect: non-scaling-stroke; }
.dw .c { fill: none; stroke: currentColor; stroke-width: .6; vector-effect: non-scaling-stroke; opacity: .5; }
.dw .x { fill: none; stroke: currentColor; stroke-width: .8; vector-effect: non-scaling-stroke; stroke-dasharray: 5 4; }
.dw .h { fill: var(--ink-2); }
.dw .wa { fill: #e0dcd2; }
.dw .st { fill: #cfc7b8; }
.dw text { font-family: var(--sans); fill: currentColor; }
.dw .dn { font-size: calc(var(--u) * 15px); font-weight: 500; }
.dw .dl { font-size: calc(var(--u) * 12.5px); }
.dw .ds { font-size: calc(var(--u) * 12px); }

.next { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); padding: clamp(56px, 6vw, 96px) var(--m) 0; text-decoration: none; align-items: end; }
.next__label { grid-column: 1 / 4; font: 500 14px/1.4 var(--sans); color: var(--ink-2); align-self: start; }
.next__name { grid-column: 4 / 9; font-size: clamp(30px, 3vw, 44px); line-height: 1.08; letter-spacing: -0.018em; font-weight: 360; }
.next__img { grid-column: 10 / 13; }
.next__img .frame { aspect-ratio: 3 / 2; }
.next:hover .next__name { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.12em; }

/* ------------------------------------------------------------------ index */
.filters { display: flex; flex-wrap: wrap; gap: 8px 22px; padding-inline: var(--m); padding-bottom: 28px; font: 500 15px/1.4 var(--sans); }
.filters button { background: none; border: 0; padding: 6px 0; cursor: pointer; color: var(--ink-2); background-image: linear-gradient(var(--ink), var(--ink)); background-size: 0 1px; background-position: 0 100%; background-repeat: no-repeat; transition: background-size .5s var(--ease), color .3s; }
.filters button:hover { color: var(--ink); }
.filters button[aria-pressed="true"] { color: var(--ink); background-size: 100% 1px; }
.filters .count { color: var(--ink-2); font-weight: 400; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: var(--gap); row-gap: clamp(44px, 4.5vw, 72px); padding-inline: var(--m); }
.cards--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card[hidden] { display: none; }
.card .frame, .card .ph { aspect-ratio: 4 / 3; margin-bottom: 14px; }
.card .ph { background: var(--stone); display: flex; align-items: center; justify-content: center; font: 400 13px/1.4 var(--sans); color: var(--ink-2); padding: 20px; text-align: center; }
.card .ph--dw { background: color-mix(in srgb, var(--stone) 55%, var(--paper)); padding: 6%; }
.card .ph--dw svg { width: 100%; height: 100%; }
.card .frame img { transition: opacity .6s var(--ease), transform 1.6s var(--ease); }
.card:has(.card__page):hover .frame img { opacity: .9; }
.card__name { font-size: 21px; line-height: 1.25; margin-bottom: 4px; }
.card__name a { text-decoration: none; }
.card__name a:hover { text-decoration: underline; text-decoration-thickness: 1px; }
.card__meta { font: 400 14px/1.5 var(--sans); color: var(--ink-2); }
.card__page { font: 500 13px/1.4 var(--sans); margin-top: 6px; display: inline-block; }

.rows { border-top: 1px solid var(--line); }
.rows li { display: grid; grid-template-columns: 5.5em minmax(0, 1fr) 12em; column-gap: var(--gap); padding: 12px 0 11px; border-bottom: 1px solid var(--line); font: 400 15.5px/1.45 var(--sans); }
.rows li > :first-child { color: var(--ink-2); }
.rows li > :last-child { color: var(--ink-2); }
.listsec { grid-column: 1 / 11; }

/* ------------------------------------------------------------------ text pages */
.text-sec { padding-top: var(--sec); align-items: start; row-gap: 24px; }
.text-sec > h2 { grid-column: 1 / 4; font-size: clamp(23px, 1.9vw, 28px); line-height: 1.2; letter-spacing: -0.008em; }
.text-sec > .body { grid-column: 5 / 12; }
.text-sec > .body--wide { grid-column: 5 / 13; }
.body h3 { font-size: 21px; line-height: 1.3; margin: 1.4em 0 .35em; }
.body h3:first-child { margin-top: 0; }

.values li { display: grid; grid-template-columns: 2.2em 1fr; padding: 20px 0 22px; border-top: 1px solid var(--line); }
.values li:last-child { border-bottom: 1px solid var(--line); }
.values .n { font: 500 14px/1.9 var(--sans); color: var(--ink-2); }
.values h3 { font-size: 22px; line-height: 1.25; margin: 0 0 6px; }
.values p { font-size: 18px; line-height: 1.52; }

.people li { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 5fr) minmax(0, 3fr); column-gap: var(--gap); padding: 22px 0 24px; border-top: 1px solid var(--line); align-items: start; }
.people li:last-child { border-bottom: 1px solid var(--line); }
.people h3 { font-size: 23px; line-height: 1.2; margin-bottom: 4px; }
.people .role { font: 400 14.5px/1.45 var(--sans); color: var(--ink-2); }
.people .what { font-size: 17.5px; line-height: 1.5; }
.people .contact { font: 400 14.5px/1.6 var(--sans); }
.people .contact a { word-break: break-all; }

.timeline li { display: grid; grid-template-columns: 5em 1fr; column-gap: var(--gap); padding: 12px 0 12px; border-top: 1px solid var(--line); }
.timeline li:last-child { border-bottom: 1px solid var(--line); }
.timeline .y { font: 500 15px/1.6 var(--sans); }
.timeline p { font-size: 18px; line-height: 1.5; }

.steps li { display: grid; grid-template-columns: 2.2em minmax(0, 1fr) minmax(0, 9em); column-gap: var(--gap); padding: 18px 0 20px; border-top: 1px solid var(--line); align-items: baseline; }
.steps li:last-child { border-bottom: 1px solid var(--line); }
.steps .n { font: 500 14px/1.6 var(--sans); color: var(--ink-2); }
.steps h3 { font-size: 22px; line-height: 1.25; margin-bottom: 6px; }
.steps p { font-size: 18px; line-height: 1.5; }
.steps .dur { font: 400 14.5px/1.5 var(--sans); color: var(--ink-2); text-align: right; }

.prices { width: 100%; border-collapse: collapse; font-family: var(--sans); }
.prices caption { text-align: left; font: 400 14px/1.5 var(--sans); color: var(--ink-2); padding-bottom: 12px; caption-side: top; }
.prices th, .prices td { text-align: left; vertical-align: top; padding: 14px var(--gap) 13px 0; border-top: 1px solid var(--line); }
.prices tr:last-child th, .prices tr:last-child td { border-bottom: 1px solid var(--line); }
.prices thead th { font: 500 13px/1.4 var(--sans); color: var(--ink-2); border-top: 0; padding-bottom: 10px; }
.prices tbody th { font: 400 18px/1.35 var(--serif); width: 34%; }
.prices td { font-size: 15px; line-height: 1.5; color: var(--ink-2); }
.prices td.p { color: var(--ink); text-align: right; white-space: nowrap; padding-right: 0; font-variant-numeric: tabular-nums; width: 9.5em; }
.prices thead th:last-child { text-align: right; padding-right: 0; }
.rates { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); margin-top: 28px; font-family: var(--sans); }
.rates div { border-top: 1px solid var(--line); padding-top: 10px; }
.rates dt { font-size: 14px; color: var(--ink-2); }
.rates dd { font-size: 20px; font-variant-numeric: tabular-nums; }
.note { font: 400 14.5px/1.55 var(--sans); color: var(--ink-2); margin-top: 18px; max-width: 46em; }
.plain-list li { padding: 9px 0; border-top: 1px solid var(--line); font-size: 18px; line-height: 1.45; }
.plain-list li:last-child { border-bottom: 1px solid var(--line); }

.news-items { padding-top: 8px; }
.news-item { padding-top: clamp(40px, 4.5vw, 64px); padding-bottom: 6px; align-items: start; row-gap: 14px; }
.news-item + .news-item { border-top: 1px solid var(--line); margin-inline: var(--m); padding-inline: 0; }
.news-item time { grid-column: 1 / 4; font: 400 15px/1.6 var(--sans); color: var(--ink-2); }
.news-item .body { grid-column: 4 / 11; }
.news-item h2 { font-size: clamp(24px, 2.1vw, 31px); line-height: 1.18; letter-spacing: -0.01em; margin-bottom: 14px; }
.news-item .frame { aspect-ratio: 3 / 2; margin: 22px 0 8px; }

.contact-top { padding-top: 8px; row-gap: 36px; align-items: start; }
.contact-top > div { grid-column: span 4; font: 400 15.5px/1.6 var(--sans); }
.contact-top h2 { font: 500 14px/1.4 var(--sans); color: var(--ink-2); margin-bottom: 8px; }
.contact-top .big { font: 400 22px/1.35 var(--serif); margin-bottom: 8px; }

.form { grid-column: 5 / 12; display: grid; grid-template-columns: 1fr 1fr; column-gap: var(--gap); row-gap: 20px; font-family: var(--sans); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field--full { grid-column: 1 / -1; }
.field label { font: 500 14px/1.4 var(--sans); }
.field .opt { font-weight: 400; color: var(--ink-2); }
.field input, .field select, .field textarea { font: 400 16px/1.4 var(--sans); color: var(--ink); background: #faf8f3; border: 1px solid var(--edge); border-radius: 0; padding: 11px 12px; width: 100%; appearance: none; }
.field select { background-image: linear-gradient(45deg, transparent 50%, var(--ink) 50%), linear-gradient(135deg, var(--ink) 50%, transparent 50%); background-position: calc(100% - 18px) 52%, calc(100% - 13px) 52%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--terva); outline-offset: 1px; }
.field [aria-invalid="true"] { border-color: #8f2f1f; }
.err { font: 400 13.5px/1.4 var(--sans); color: #8f2f1f; min-height: 0; }
.form__foot { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; }
.btn { font: 500 15px/1 var(--sans); background: var(--terva); color: var(--paper); border: 0; padding: 15px 22px; cursor: pointer; transition: background .3s var(--ease); }
.btn:hover { background: var(--ink); }
.form__note { font: 400 14px/1.5 var(--sans); color: var(--ink-2); }
.form__status { grid-column: 1 / -1; font: 400 15.5px/1.5 var(--sans); padding: 14px 16px; background: var(--stone); border-left: 2px solid var(--terva); }
.form__status:empty { display: none; }

.map { grid-column: 1 / -1; }
.map__f { background: color-mix(in srgb, var(--stone) 55%, var(--paper)); padding: clamp(16px, 2.5vw, 36px); }
.map__f svg { width: 100%; height: auto; }
.map text { font-family: var(--sans); }

.credits { width: 100%; border-collapse: collapse; font: 400 14.5px/1.5 var(--sans); }
.credits th, .credits td { text-align: left; vertical-align: top; padding: 11px 18px 10px 0; border-top: 1px solid var(--line); }
.credits thead th { font-weight: 500; color: var(--ink-2); border-top: 0; }
.credits td:first-child { font-family: var(--serif); font-size: 17px; }
.credits a { word-break: break-word; }
.table-wrap { overflow-x: auto; }

.notfound { padding-top: clamp(60px, 10vw, 160px); padding-bottom: 40px; }
.notfound p { grid-column: 1 / 9; }

/* ------------------------------------------------------------------ footer */
.foot { margin-top: var(--sec); background: var(--terva); color: var(--paper); padding: clamp(56px, 6vw, 88px) var(--m) 28px; }
.foot a { color: var(--paper); }
.foot__wm { width: 132px; fill: var(--paper); margin-bottom: clamp(36px, 4vw, 56px); }
.foot__cols { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); row-gap: 32px; font: 400 15px/1.6 var(--sans); }
.foot__cols > div { grid-column: span 3; }
.foot__h { font: 500 13px/1.4 var(--sans); color: var(--terva-2); margin-bottom: 10px; }
.foot__cols li { margin-bottom: 2px; }
.foot__cols ul a { text-decoration: none; }
.foot__cols ul a:hover { text-decoration: underline; }
.foot__base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; margin-top: clamp(48px, 5vw, 72px); padding-top: 18px; border-top: 1px solid rgba(243, 240, 233, .18); font: 400 13px/1.5 var(--sans); color: var(--terva-2); }
.foot__base p { margin: 0; }
.foot__base a { color: var(--paper); }

/* ------------------------------------------------------------------ tablet */
@media (max-width: 1100px) {
  .nav ul { gap: 22px; }
  .intro__title { grid-column: 1 / 10; }
  .intro__aside { grid-column: 10 / 13; }
  .work__img { grid-column: 1 / 9; }
  .work__txt { grid-column: 9 / 13; }
  .work--r .work__img { grid-column: 5 / 13; }
  .work--r .work__txt { grid-column: 1 / 5; }
  .cards, .cards--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .people li { grid-template-columns: 1fr 1fr; row-gap: 10px; }
  .people .contact { grid-column: 2; }
  .facts { grid-column: 1 / 6; }
  .case-text { grid-column: 7 / 13; }
}

/* ------------------------------------------------------------------ phone */
@media (max-width: 860px) {
  body { font-size: 17.5px; line-height: 1.56; }
  :root { --gap: 16px; }
  .head { padding-block: 16px; }
  .brand__wm { width: 92px; margin-bottom: -8.5px; }
  .brand__desc { margin-left: 10px; }
  .brand__desc { font-size: 12px; }
  .menu-btn { display: inline-block; background: none; border: 0; padding: 10px 0 10px 12px; font: 500 15px/1 var(--sans); cursor: pointer; position: relative; z-index: 31; }
  .js .nav { position: fixed; inset: 0; z-index: 30; background: var(--paper); padding: 96px var(--m) 40px; visibility: hidden; opacity: 0; transition: opacity .45s var(--ease), visibility 0s linear .45s; overflow-y: auto; }
  .js .nav.is-open { visibility: visible; opacity: 1; transition: opacity .45s var(--ease); }
  .js .nav ul { flex-direction: column; gap: 4px; }
  .js .nav a { font: 380 32px/1.3 var(--serif); letter-spacing: -0.01em; display: inline-block; padding-block: 4px; }
  html:not(.js) .nav ul { flex-wrap: wrap; gap: 6px 18px; }
  html:not(.js) .head { flex-wrap: wrap; }
  html:not(.js) .menu-btn { display: none; }
  .js .head.is-open .brand { position: relative; z-index: 31; }

  .grid > * { grid-column: 1 / -1 !important; }
  .grid { row-gap: 18px; }
  .intro { padding-top: 18px; padding-bottom: 26px; }
  .intro__title { font-size: 26px; line-height: 1.22; }
  .intro__aside { font-size: 14px; }
  .hero .frame { height: auto; aspect-ratio: 4 / 5; min-height: 0; }
  .hero .cap, .case-hero .cap, .fig--full .cap { flex-direction: column; gap: 2px; }
  .work { row-gap: 16px; margin-bottom: 72px; }
  .work--r .work__img, .work--r .work__txt, .work--pair .work__txt { grid-row: auto; }
  .work--pair .work__img2 { display: none; }
  .work__name { font-size: 25px; }
  .now__row { grid-template-columns: 1fr; row-gap: 2px; padding: 14px 0; }
  .now__name, .now__place, .now__state { grid-column: 1 / -1; }
  .news-list a { grid-template-columns: 1fr; row-gap: 2px; }
  .news-list time, .news-list span { grid-column: 1 / -1; }
  .news-list span { font-size: 19px; }
  .band__aside { margin-top: 10px; }
  .page-title { font-size: 38px; }
  .page-lede { font-size: 21px; }
  .case-hero .frame { height: auto; aspect-ratio: 4 / 5; min-height: 0; }
  .fig--full .frame { height: auto; aspect-ratio: 3 / 2; }
  .facts div { grid-template-columns: 7.2em 1fr; }
  .chapter { row-gap: 12px; }
  .pair { row-gap: 28px; }
  .pair__b { width: 72%; }
  .pair--flip .pair__b { margin-left: auto; }
  .pair--even .pair__b { width: 100%; }
  .drawing__f { padding: 12px; }
  .dw .dn { font-size: calc(var(--um) * 12.5px); }
  .dw .dl { font-size: calc(var(--um) * 11px); }
  .dw .ds { font-size: calc(var(--um) * 10.5px); }
  .drawings-2 { grid-template-columns: 1fr; }
  .next { grid-template-columns: 1fr; row-gap: 10px; }
  .next__label, .next__name, .next__img { grid-column: 1 / -1; }
  .next__img { width: 64%; }
  .cards, .cards--4 { grid-template-columns: 1fr; row-gap: 44px; }
  .rows li { grid-template-columns: 4.2em minmax(0, 1fr); row-gap: 2px; }
  .rows li > :last-child { grid-column: 2; }
  .people li { grid-template-columns: 1fr; }
  .people .contact { grid-column: 1; }
  .steps li { grid-template-columns: 2em minmax(0, 1fr); }
  .steps .dur { grid-column: 2; text-align: left; margin-top: 6px; }
  .prices thead { display: none; }
  .prices, .prices tbody, .prices tr, .prices th, .prices td { display: block; width: 100%; }
  .prices tr { border-top: 1px solid var(--line); padding: 12px 0; }
  .prices tr:last-child { border-bottom: 1px solid var(--line); }
  .prices th, .prices td, .prices tr:last-child th, .prices tr:last-child td { border: 0; padding: 2px 0; }
  .prices td.p { text-align: left; width: auto; font-size: 17px; margin-top: 4px; }
  .rates { grid-template-columns: 1fr 1fr; }
  .form { grid-template-columns: 1fr; }
  .contact-top > div { grid-column: 1 / -1; }
  .foot__cols > div { grid-column: span 6; }
  .news-item + .news-item { margin-inline: var(--m); }
  .credits thead { display: none; }
  .credits, .credits tbody, .credits tr, .credits td { display: block; width: 100%; }
  .credits tr { border-top: 1px solid var(--line); padding: 10px 0; }
  .credits td { border: 0; padding: 1px 0; }
}
@media (max-width: 420px) {
  .brand__wm { width: 88px; margin-bottom: -8.1px; }
  .brand__desc { font-size: 11.5px; }
  .foot__cols > div { grid-column: 1 / -1; }
  .rates { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-reveal].frame::after { display: none; }
  .js [data-reveal].frame img, .js .reveal { transform: none; opacity: 1; transition: none; }
  .js .nav { transition: none !important; }
}

@media print {
  .head nav, .menu-btn, .skip, .filters, .form { display: none !important; }
  .foot { background: none; color: var(--ink); }
  .foot a, .foot__base a { color: var(--ink); }
  .foot__wm { fill: var(--ink); }
}
