/* Fonts served from our own server (sito-src/fonts → /assets/fonts): no request to Google, so no visitor data leaves the site.
   Archivo is a variable font (one file per subset covers 400-800); Montserrat 800 holds only the glyphs of «DIPIETRA». */
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("fonts/archivo-latin-ext.woff2?v=1") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("fonts/archivo-latin.woff2?v=1") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Instrument Serif";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/instrument-serif-italic-latin-ext.woff2?v=1") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Instrument Serif";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/instrument-serif-italic-latin.woff2?v=1") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Instrument Serif";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/instrument-serif-latin-ext.woff2?v=1") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Instrument Serif";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/instrument-serif-latin.woff2?v=1") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Montserrat";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("fonts/montserrat-800-wordmark.woff2?v=1") format("woff2");
}

/* DIPIETRA demo — one stylesheet for every page. Warm lime-white, charcoal, one orange accent. */
:root {
  --bg: #f2eee7;
  --bg-2: #e7e1d6;
  --paper: #fbf9f5;
  --ink: #161412;
  --ink-2: #47413a;
  --muted: #6d665c;
  --line: rgba(22, 20, 18, 0.14);
  --dark: #12110f;
  --dark-2: #1c1a17;
  --stone: #ece6dc;
  --stone-2: #b5ac9f;
  --line-dark: rgba(236, 230, 220, 0.16);
  --accent: #e8572a;
  --accent-2: #c9441b;
  --radius: 14px;
  --gutter: clamp(20px, 4vw, 56px);
  --max: 1440px;
  --header-h: 72px;
  --f-sans: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-serif: "Instrument Serif", Georgia, "Times New Roman", serif;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); scrollbar-gutter: stable; }
html.menu-open { overflow: hidden; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.0625rem/1.6 var(--f-sans); -webkit-font-smoothing: antialiased; overflow-x: clip; }
img, video { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, p, figure, dl, dd, ol, ul { margin: 0; }
figure { position: relative; }
button { font: inherit; color: inherit; }
::selection { background: var(--accent); color: #fff; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: var(--bg); padding: 0.6rem 1rem; border-radius: 8px; }
.skip:focus { top: 12px; }
.placeholder { width: 100%; height: 100%; background: linear-gradient(135deg, var(--bg-2), #d9d1c4); }

/* ---------- type ---------- */
.eyebrow { display: flex; align-items: center; gap: 0.7rem; font-size: 0.76rem; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.eyebrow::before { content: ""; width: 26px; height: 1px; background: currentColor; flex: none; }
.eyebrow--light { color: var(--stone-2); }
.display { font-weight: 800; font-size: clamp(2.9rem, 7.4vw, 7.6rem); line-height: 0.94; letter-spacing: -0.04em; text-wrap: balance; }
.serif { font-family: var(--f-serif); font-style: italic; font-weight: 400; letter-spacing: -0.015em; color: var(--accent); }
.title { font-weight: 750; font-size: clamp(2rem, 4.2vw, 3.9rem); line-height: 1.02; letter-spacing: -0.032em; text-wrap: balance; }
.title--md { font-size: clamp(1.9rem, 3.4vw, 3.1rem); }
.title .serif { font-weight: 400; }
.lead { font-size: clamp(1.08rem, 1.35vw, 1.25rem); line-height: 1.6; color: var(--ink-2); max-width: 40ch; }
.lead--light { color: var(--stone-2); }
.link-arrow { display: inline-flex; align-items: center; gap: 0.5rem; font-weight: 600; text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px; white-space: nowrap; }
.link-arrow span { transition: transform 0.3s var(--ease); }
.link-arrow:hover span { transform: translateX(4px); }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem; padding: 0.8rem 1.25rem; border-radius: 999px; border: 1px solid transparent; font-weight: 600; font-size: 0.95rem; line-height: 1.2; text-decoration: none; cursor: pointer; transition: background 0.25s, color 0.25s, transform 0.25s var(--ease); white-space: nowrap; }
.btn:hover { transform: translateY(-1px); }
.btn--lg { padding: 1rem 1.5rem; font-size: 1rem; }
.btn--accent { background: var(--accent); color: #fff; }
.btn--accent:hover { background: var(--accent-2); }
.btn--dark { background: var(--ink); color: var(--bg); }
.btn--dark:hover { background: #2b2722; }
/* Halden-style hover: the fill wipes in from the bottom edge instead of fading */
.btn--ghost { border-color: currentColor; background: linear-gradient(var(--ink), var(--ink)) no-repeat 0 100% / 100% 0; transition: background-size 0.5s cubic-bezier(.16, 1, .3, 1), color 0.3s, border-color 0.3s, transform 0.25s var(--ease); }
.btn--ghost:hover { background-size: 100% 100%; color: var(--bg); border-color: var(--ink); }
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* ---------- header ---------- */
.preview-bar { background: var(--dark); color: var(--stone-2); font-size: 0.72rem; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; text-align: center; padding: 0.5rem 1rem; }
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(242, 238, 231, 0.9); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-bottom: 1px solid transparent; transition: border-color 0.3s; }
.site-header.is-scrolled { border-bottom-color: var(--line); }
.site-header.is-open { -webkit-backdrop-filter: none; backdrop-filter: none; }
.site-header__in { display: flex; align-items: center; justify-content: space-between; gap: 2rem; height: var(--header-h); }
.logo { display: inline-flex; align-items: center; text-decoration: none; flex: none; }
.logo img { height: 22px; width: auto; }
.logo__text { font-weight: 800; font-size: 1.35rem; letter-spacing: -0.02em; }
.nav-wrap { display: flex; align-items: center; gap: 2rem; }
.nav { display: flex; gap: 1.8rem; }
.nav a { position: relative; text-decoration: none; font-weight: 500; font-size: 0.95rem; padding: 0.3rem 0; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform 0.3s var(--ease); }
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.menu-toggle { display: none; position: relative; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%; background: transparent; cursor: pointer; }
.menu-toggle span:not(.sr) { position: absolute; left: 13px; right: 13px; height: 1.5px; background: var(--ink); transition: transform 0.3s var(--ease); }
.menu-toggle span:nth-child(1) { top: 18px; }
.menu-toggle span:nth-child(2) { top: 25px; }
.is-open .menu-toggle span:nth-child(1) { transform: translateY(3.5px) rotate(45deg); }
.is-open .menu-toggle span:nth-child(2) { transform: translateY(-3.5px) rotate(-45deg); }

/* ---------- sections ---------- */
.section { padding: clamp(72px, 9vw, 136px) 0; }
.section--tight { padding: clamp(40px, 5vw, 72px) 0; }
.section--top0 { padding-top: 0; }
.section--flush { padding-top: 0; padding-bottom: 0; }
.section--sand { background: var(--bg-2); }
.section--dark { background: var(--dark); color: var(--stone); }
.section--dark .lead { color: var(--stone-2); }
.head { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem 3rem; flex-wrap: wrap; margin-bottom: clamp(32px, 5vw, 64px); }
.head .title { margin-top: 1rem; max-width: 16ch; }
.head .lead { max-width: 44ch; }
.hint { color: var(--muted); font-size: 0.9rem; }

/* ---------- home hero ---------- */
.hero { padding: clamp(32px, 5vw, 72px) 0 clamp(56px, 7vw, 104px); }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: clamp(32px, 5vw, 80px); align-items: end; }
.hero__text .display { margin: 1.4rem 0 1.6rem; }
.hero__text .lead { margin-bottom: 2rem; }
.hero__media { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.58fr); gap: clamp(10px, 1.2vw, 16px); align-items: end; }
.hero__main, .hero__side { border-radius: var(--radius); overflow: hidden; background: var(--bg-2); }
.hero__main { aspect-ratio: 9 / 14; }
.hero__side { aspect-ratio: 3 / 4; margin-bottom: 18%; }
.hero__main > *, .hero__side > * { width: 100%; height: 100%; object-fit: cover; }

/* ---------- ticker ---------- */
.ticker { background: var(--ink); color: var(--bg); overflow: hidden; white-space: nowrap; padding: 1.05rem 0; }
.ticker__track { display: inline-flex; align-items: center; gap: 2.2rem; padding-left: 2.2rem; font-weight: 700; font-size: clamp(1.1rem, 1.8vw, 1.6rem); letter-spacing: -0.01em; animation: ticker 42s linear infinite; }
.ticker__track i { font-style: normal; color: var(--accent); font-size: 0.8em; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* ---------- manifesto ---------- */
.manifesto { display: grid; grid-template-columns: minmax(0, 0.3fr) minmax(0, 1fr); gap: 2rem var(--gutter); }
.manifesto__text { font-size: clamp(1.55rem, 2.9vw, 2.7rem); line-height: 1.2; font-weight: 600; letter-spacing: -0.022em; max-width: 30ch; text-wrap: pretty; }
.points { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem 2rem; margin-top: clamp(40px, 5vw, 64px); padding-top: 1.75rem; border-top: 1px solid var(--line); }
.point h3 { font-size: 1.12rem; font-weight: 700; margin-bottom: 0.35rem; }
.point p { color: var(--muted); }

/* ---------- project cards ---------- */
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(28px, 3vw, 40px) clamp(16px, 2vw, 28px); }
.cards--stagger .card:nth-child(3n + 2) { margin-top: clamp(0px, 5vw, 72px); }
.card { display: block; text-decoration: none; }
.card[hidden] { display: none; }
.card__media { position: relative; aspect-ratio: 3 / 4; border-radius: var(--radius); overflow: hidden; background: var(--bg-2); }
.card__media img, .card__media .placeholder { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.card:hover .card__media img { transform: scale(1.04); }
.card__tag { position: absolute; top: 12px; left: 12px; background: rgba(251, 249, 245, 0.92); color: var(--ink); font-size: 0.7rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; padding: 0.35rem 0.65rem; border-radius: 999px; }
.card__meta { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin-top: 1rem; }
.card__title { font-size: clamp(1.25rem, 1.6vw, 1.5rem); font-weight: 700; letter-spacing: -0.02em; }
.card__place { color: var(--muted); font-size: 0.88rem; white-space: nowrap; }
.card__text { color: var(--muted); margin-top: 0.35rem; font-size: 0.98rem; max-width: 38ch; }

/* ---------- home feature band (full-bleed loop) ---------- */
.feature { position: relative; background: var(--dark); color: var(--stone); overflow: hidden; }
.feature__media { position: relative; height: min(88vh, 56.25vw); min-height: 420px; margin: 0; }
.feature__media > * { width: 100%; height: 100%; object-fit: cover; }
.feature__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(12, 11, 9, 0.78) 0%, rgba(12, 11, 9, 0.28) 38%, rgba(12, 11, 9, 0) 62%); pointer-events: none; }
.feature__cap { position: absolute; left: 0; right: 0; bottom: clamp(28px, 5vw, 64px); display: grid; gap: 1rem; justify-items: start; }
.feature__title { color: #fff; max-width: 15ch; }
.feature__title .serif { color: #f3c9b6; }
.link-arrow--light { color: #fff; }
@media (max-width: 640px) { .feature__media { height: 78vh; min-height: 0; } }

/* ---------- services list ---------- */
.services { border-top: 1px solid var(--line); }
.service-row { display: grid; grid-template-columns: 64px minmax(0, 1fr) minmax(0, 1.1fr) 32px; gap: 1.5rem; align-items: baseline; padding: 1.55rem 0; border-bottom: 1px solid var(--line); text-decoration: none; transition: background 0.3s; }
.service-row__n { color: var(--accent); font-weight: 600; font-size: 0.95rem; }
.service-row__t { font-size: clamp(1.35rem, 2.3vw, 2.1rem); font-weight: 700; letter-spacing: -0.025em; line-height: 1.1; }
.service-row__d { color: var(--muted); }
.service-row__go { justify-self: end; transition: transform 0.3s var(--ease); }
.service-row:hover .service-row__go { transform: translateX(6px); }
.service-row:hover .service-row__t { color: var(--accent-2); }

/* ---------- process ---------- */
.process { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: clamp(40px, 6vw, 104px); align-items: start; }
.process__media { position: sticky; top: calc(var(--header-h) + 32px); aspect-ratio: 4 / 5; border-radius: var(--radius); overflow: hidden; background: var(--dark-2); }
.process__media > * { width: 100%; height: 100%; object-fit: cover; }
.process .title { margin: 1rem 0 clamp(28px, 4vw, 48px); max-width: 14ch; }
.steps { list-style: none; padding: 0; }
.step { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 1rem; padding: 1.75rem 0; border-top: 1px solid var(--line-dark); }
.step:last-child { border-bottom: 1px solid var(--line-dark); }
.step__n { font-family: var(--f-serif); font-style: italic; font-size: 2.3rem; line-height: 1; color: var(--accent); }
.step h3 { font-size: clamp(1.25rem, 1.7vw, 1.5rem); font-weight: 700; letter-spacing: -0.015em; margin-bottom: 0.4rem; }
.step p { color: var(--stone-2); max-width: 46ch; }
.steps--grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 2rem; }
.steps--grid .step { grid-template-columns: 1fr; border-bottom: 1px solid var(--line-dark); }

/* ---------- trust ---------- */
.trust { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr); gap: clamp(40px, 6vw, 104px); align-items: center; }
.trust__media { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 14px; align-items: end; }
.trust__media figure { border-radius: var(--radius); overflow: hidden; aspect-ratio: 3 / 4; background: var(--bg-2); }
.trust__media figure:last-child { aspect-ratio: 3 / 4.6; margin-bottom: 14%; }
.trust__media figure > * { width: 100%; height: 100%; object-fit: cover; }
.trust .title { margin: 1rem 0 1.25rem; max-width: 13ch; }
.trust .lead { margin-bottom: 1.75rem; }

/* ---------- CTA band ---------- */
.cta-band { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2rem 3rem; align-items: end; background: var(--accent); color: #fff; border-radius: calc(var(--radius) * 1.6); padding: clamp(36px, 6vw, 88px); }
.cta-band .eyebrow { color: rgba(255, 255, 255, 0.82); }
.cta-band .title { margin-top: 1rem; color: #fff; }
.cta-band .serif { color: var(--ink); }
.cta-band :focus-visible { outline-color: var(--ink); }

/* ---------- page hero (inner pages) ---------- */
.page-hero { padding: clamp(48px, 7vw, 112px) 0 clamp(40px, 6vw, 88px); }
.page-hero__grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr); gap: 2rem var(--gutter); align-items: end; }
.page-hero .display { font-size: clamp(2.7rem, 6.4vw, 6.4rem); margin-top: 1.3rem; }

/* ---------- services page ---------- */
.svc { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 104px); align-items: center; padding: clamp(48px, 7vw, 104px) 0; border-top: 1px solid var(--line); scroll-margin-top: calc(var(--header-h) + 8px); }
.svc:nth-child(even) .svc__media { order: 2; }
.svc__media { aspect-ratio: 4 / 5; border-radius: var(--radius); overflow: hidden; background: var(--bg-2); }
.svc__media > * { width: 100%; height: 100%; object-fit: cover; }
.svc__n { font-family: var(--f-serif); font-style: italic; font-size: 2rem; color: var(--accent); line-height: 1; margin-bottom: 1rem; }
.svc .lead { margin-top: 1.25rem; }
.uses { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.5rem 0 2rem; }
.uses li { border: 1px solid var(--line); border-radius: 999px; padding: 0.4rem 0.85rem; font-size: 0.88rem; }

/* ---------- works page ---------- */
.filters { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin-bottom: clamp(28px, 4vw, 48px); }
.filter { border: 1px solid var(--line); background: transparent; border-radius: 999px; padding: 0.6rem 1.1rem; font-weight: 600; font-size: 0.92rem; cursor: pointer; transition: background 0.25s, color 0.25s; }
.filter:hover { border-color: var(--ink); }
.filter[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.filters__status { margin-left: auto; color: var(--muted); font-size: 0.9rem; }
.gallery { columns: 3 260px; column-gap: 14px; }
.gallery a { display: block; margin-bottom: 14px; border-radius: 10px; overflow: hidden; break-inside: avoid; background: var(--bg-2); }
.gallery img { width: 100%; height: auto; transition: transform 0.8s var(--ease); }
.gallery a:hover img { transform: scale(1.03); }

/* ---------- project page ---------- */
.project-hero { padding: clamp(32px, 5vw, 72px) 0 clamp(56px, 7vw, 96px); }
.project-hero__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr); gap: clamp(32px, 6vw, 104px); align-items: end; }
.back { display: inline-flex; gap: 0.5rem; text-decoration: none; font-weight: 600; font-size: 0.92rem; color: var(--muted); margin-bottom: clamp(28px, 4vw, 56px); }
.back:hover { color: var(--ink); }
.display--project { font-size: clamp(2.8rem, 6.2vw, 6.2rem); margin: 1.2rem 0 1.4rem; }
.project-hero__media { aspect-ratio: 4 / 5; border-radius: var(--radius); overflow: hidden; background: var(--bg-2); }
.project-hero__media > * { width: 100%; height: 100%; object-fit: cover; }
/* full-screen project hero: the video fills the screen under the header, the title sits on it bottom-left */
.project-hero--full { position: relative; display: flex; align-items: flex-end; min-height: 560px; height: calc(100svh - var(--header-h)); padding: 0; overflow: hidden; background: var(--dark); color: #fff; }
.project-hero--full .project-hero__media { position: absolute; inset: 0; margin: 0; aspect-ratio: auto; border-radius: 0; background: #0b0a09; }
.project-hero--full .project-hero__media::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to top, rgba(12, 11, 9, 0.82) 0%, rgba(12, 11, 9, 0.4) 36%, rgba(12, 11, 9, 0) 64%), linear-gradient(to right, rgba(12, 11, 9, 0.5) 0%, rgba(12, 11, 9, 0) 58%); }
.project-hero--full .project-hero__media > * { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.project-hero__v--tall { display: none; }
.project-hero__v--only { display: block; }
.project-hero--full .project-hero__text { position: relative; z-index: 1; padding-bottom: clamp(40px, 7vh, 88px); }
.project-hero--full .project-hero__text > * { max-width: 46rem; }
.project-hero--full .back { color: rgba(236, 230, 220, 0.82); margin-bottom: clamp(20px, 4vh, 44px); }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 0.45rem; font-weight: 600; font-size: 0.92rem; color: var(--muted); margin-bottom: clamp(28px, 4vw, 56px); }
.crumbs a { color: inherit; text-decoration: none; }
.crumbs a:hover { color: var(--ink); }
.project-hero--full .crumbs { color: rgba(236, 230, 220, 0.82); margin-bottom: clamp(20px, 4vh, 44px); }
.project-hero--full .crumbs a:hover { color: #fff; }
.crumbs [aria-current] { color: inherit; opacity: 0.75; }
.project-hero--full .back:hover { color: #fff; }
.project-hero--full .display--project { color: #fff; }
.project-hero--full .lead { color: rgba(236, 230, 220, 0.88); }
.project-hero--full .facts { border-top-color: rgba(236, 230, 220, 0.24); }
.project-hero--full .facts dt { color: rgba(236, 230, 220, 0.7); }
.project-hero--full .facts dd { color: #fff; }
@media (max-width: 767px) {
  .project-hero__v--wide { display: none; }
  .project-hero__v--tall { display: block; }
  .project-hero--full .project-hero__media::after { background: linear-gradient(to top, rgba(12, 11, 9, 0.9) 0%, rgba(12, 11, 9, 0.55) 42%, rgba(12, 11, 9, 0) 72%); }
  .project-hero--full .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.75rem; font-size: 0.9rem; }
}
@media (min-width: 768px) and (max-height: 760px) { .project-hero--full .display--project { font-size: clamp(2.6rem, 5.2vw, 4.8rem); margin: 0.8rem 0 1rem; } .project-hero--full .facts { margin-top: 1.4rem; } }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin-top: 2.25rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
.facts dt { font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-bottom: 0.3rem; }
.facts dd { font-weight: 600; line-height: 1.35; }
.story { display: grid; grid-template-columns: minmax(0, 0.3fr) minmax(0, 1fr); gap: 2rem var(--gutter); }
.story__text p { font-size: clamp(1.25rem, 2vw, 1.75rem); line-height: 1.38; letter-spacing: -0.012em; max-width: 34ch; }
.story__text p + p { margin-top: 1.1em; }
.story__text .link-arrow { margin-top: 2rem; }
.craft { margin-top: clamp(48px, 7vw, 96px); display: grid; gap: 1.5rem; }
.loop > .loop__cap { position: absolute; left: 0; right: 0; bottom: 0; top: auto; height: auto; padding: 2.5rem 1rem 0.9rem; font-size: 0.86rem; line-height: 1.35; color: #fff; background: linear-gradient(to top, rgba(12, 11, 9, 0.75), rgba(12, 11, 9, 0)); }
.loops { display: grid; grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); gap: 14px; max-width: calc(var(--n, 3) * 420px); }
.loop { aspect-ratio: 9 / 16; border-radius: var(--radius); overflow: hidden; background: var(--dark-2); }
.loop > * { width: 100%; height: 100%; object-fit: cover; }
.next { display: grid; gap: 1rem; }
.next__link { display: inline-flex; align-items: baseline; gap: 1rem; text-decoration: none; font-weight: 800; font-size: clamp(2.2rem, 6vw, 5.6rem); letter-spacing: -0.04em; line-height: 1; }
.next__link > span:last-child { color: var(--accent); transition: transform 0.35s var(--ease); }
.next__link:hover > span:last-child { transform: translateX(10px); }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 104px); align-items: center; }
.about__media { border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 5; background: var(--bg-2); }
.about__media > img { width: 100%; height: 100%; object-fit: cover; }
.about__media figcaption { position: absolute; left: 14px; bottom: 14px; background: rgba(251, 249, 245, 0.92); padding: 0.4rem 0.75rem; border-radius: 999px; font-size: 0.82rem; font-weight: 500; }
.about__text .title { margin: 1rem 0 1.5rem; }
.about__text p:not(.eyebrow) { color: var(--ink-2); font-size: 1.12rem; max-width: 48ch; }
.about__text p + p { margin-top: 1rem; }
.values { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; }
.value { border-top: 1px solid var(--line); padding-top: 1.5rem; }
.value__n { font-family: var(--f-serif); font-style: italic; color: var(--accent); font-size: 2rem; line-height: 1; }
.value h3 { font-size: 1.35rem; font-weight: 700; letter-spacing: -0.015em; margin: 0.9rem 0 0.5rem; }
.value p { color: var(--muted); }
.academy { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 104px); align-items: center; }
.academy .title { margin: 1rem 0 1.25rem; }
.academy__media { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 14px; align-items: start; }
.academy__media figure { border-radius: var(--radius); overflow: hidden; aspect-ratio: 3 / 4; background: var(--dark-2); }
.academy__media figure:last-child { margin-top: 18%; }
.academy__media figure > * { width: 100%; height: 100%; object-fit: cover; }
.gallery--3 { columns: 3 240px; }

/* ---------- contact ---------- */
.contact { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr); gap: clamp(40px, 5vw, 88px); align-items: start; }
.contact__form { background: var(--paper); border: 1px solid var(--line); border-radius: calc(var(--radius) * 1.4); padding: clamp(24px, 4vw, 48px); }
.row-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1.25rem; }
.field { display: grid; align-content: start; gap: 0.5rem; margin: 0 0 1.4rem; border: 0; padding: 0; min-width: 0; }
.field label, .field legend { font-weight: 600; font-size: 0.95rem; padding: 0; }
.field legend { margin-bottom: 0.6rem; }
.opt { color: var(--muted); font-weight: 400; }
input:not([type="checkbox"]):not([type="radio"]), textarea { width: 100%; font: inherit; font-size: 1rem; color: var(--ink); background: #fff; border: 1px solid rgba(22, 20, 18, 0.22); border-radius: 10px; padding: 0.85rem 1rem; transition: border-color 0.2s, box-shadow 0.2s; }
textarea { resize: vertical; min-height: 120px; }
input:focus, textarea:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(232, 87, 42, 0.25); }
input:not([type="checkbox"]):not([type="radio"]):focus, textarea:focus { border-color: var(--ink); }
input:not([type="checkbox"]):not([type="radio"])[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: #b3261e; }
input::placeholder, textarea::placeholder { color: #9a9186; }
.field__error { color: #b3261e; font-size: 0.86rem; font-weight: 500; }
.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chip { position: relative; cursor: pointer; }
.chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.chip span { display: inline-block; border: 1px solid rgba(22, 20, 18, 0.22); background: #fff; border-radius: 999px; padding: 0.55rem 0.95rem; font-size: 0.92rem; transition: background 0.2s, color 0.2s, border-color 0.2s; }
.chip:hover span { border-color: var(--ink); }
.chip input:checked + span { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.chip input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.check { display: flex !important; gap: 0.75rem; align-items: flex-start; font-weight: 500 !important; line-height: 1.45; cursor: pointer; }
.check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); flex: none; }
.demo-note { margin-top: 1rem; color: var(--muted); font-size: 0.85rem; }
.form__error { margin-top: 1rem; color: #b3261e; font-weight: 500; font-size: 0.95rem; }
.form__error a { color: inherit; font-weight: 700; }
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.btn.is-sending { opacity: 0.6; cursor: progress; }
.thanks { outline: none; }
.thanks .title { margin: 1rem 0; }
.thanks .lead { margin-bottom: 1.75rem; }
.contact__side { display: grid; gap: 2rem; position: sticky; top: calc(var(--header-h) + 24px); }
.panel { background: var(--dark); color: var(--stone); border-radius: calc(var(--radius) * 1.4); padding: clamp(24px, 3vw, 36px); }
.panel h2 { font-size: 1.6rem; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 0.6rem; }
.panel p { color: var(--stone-2); margin-bottom: 1.4rem; }
.panel__facts { display: grid; gap: 0.9rem; margin-top: 1.6rem; padding-top: 1.3rem; border-top: 1px solid var(--line-dark); }
.panel__facts dt { font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--stone-2); }
.panel__facts dd { font-weight: 600; }
.faq__title { font-size: 1.3rem; font-weight: 700; margin-bottom: 0.5rem; }
.faq details { border-bottom: 1px solid var(--line); padding: 1rem 0; }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--accent); font-size: 1.3rem; line-height: 1; transition: transform 0.3s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--muted); margin-top: 0.6rem; }

/* ---------- footer ---------- */
.site-footer { background: var(--dark); color: var(--stone); padding: clamp(72px, 9vw, 128px) 0 2rem; }
.footer__top { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.6fr) minmax(0, 0.9fr); gap: 2.5rem; }
.footer__claim { font-weight: 800; font-size: clamp(2.2rem, 4.4vw, 4rem); line-height: 1; letter-spacing: -0.035em; margin-bottom: 2rem; }
.footer__claim em { font-family: var(--f-serif); font-weight: 400; color: var(--accent); }
.footer__nav { display: grid; align-content: start; gap: 0.6rem; }
.footer__nav a, .footer__contact a { text-decoration: none; color: var(--stone); }
.footer__nav a:hover, .footer__contact a:hover { color: var(--accent); }
.footer__contact { display: grid; align-content: start; gap: 0.45rem; }
.footer__label { font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--stone-2); margin-top: 0.8rem; }
.footer__label:first-child { margin-top: 0; }
.footer__logo { margin: clamp(56px, 8vw, 112px) 0 2rem; }
.footer__logo img { width: min(100%, 720px); height: auto; opacity: 0.95; }
/* The bottom padding keeps the last line above the WhatsApp bubble, so its links stay clickable at the end of the page. */
.footer__bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 0.75rem 2rem; border-top: 1px solid var(--line-dark); padding: 1.4rem 0 72px; color: var(--stone-2); font-size: 0.85rem; }

/* ---------- lightbox ---------- */
.lightbox { width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(10, 9, 8, 0.95); color: #fff; }
.lightbox::backdrop { background: transparent; }
.lightbox__figure { height: 100%; display: grid; place-items: center; align-content: center; gap: 0.8rem; padding: 56px 64px; }
.lightbox__figure img { max-width: 100%; max-height: calc(100vh - 140px); object-fit: contain; border-radius: 8px; }
.lightbox__figure figcaption { color: var(--stone-2); font-size: 0.9rem; }
.lightbox__btn { position: absolute; width: 48px; height: 48px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.3); background: rgba(0, 0, 0, 0.4); color: #fff; font-size: 1.6rem; line-height: 1; cursor: pointer; }
.lightbox__close { top: 16px; right: 16px; }
.lightbox__prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lightbox__next { right: 12px; top: 50%; transform: translateY(-50%); }
.lightbox__count { position: absolute; top: 28px; left: 24px; font-size: 0.85rem; color: var(--stone-2); }


/* =====================================================================================================
   GetLayers motion — ported from the library, timings untouched (see site.js for the numbers).
   Artist Loader plate + reveal primitives · Loopstack wordmark sweep · Numeral Steps (skinned to DIPIETRA).
   ===================================================================================================== */
:root { --gl-ease: cubic-bezier(.16, 1, .3, 1); --gl-ease-o: cubic-bezier(.25, 1, .5, 1); --gl-ease-sweep: cubic-bezier(.05, .9, .1, 1); }
html.gl-gated { overflow: hidden; }

/* The plate: the page's own ground, a label bottom-left, a numeral or the page name bottom-right. */
.gl-plate { display: none; }
.js .gl-plate { position: fixed; inset: 0; z-index: 300; display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; padding: clamp(1.5rem, 3vw, 3rem); background: var(--bg); color: var(--ink); transition: transform 900ms var(--gl-ease); will-change: transform; }
.js .gl-plate.-wipe { transform: translateY(-100%); pointer-events: none; }
.js .gl-plate.-from-below { transform: translateY(100%); }
.js .gl-plate.-covering { transition-duration: 700ms; }
.gl-plate__lab { display: grid; gap: 0.4rem; flex: none; font-size: 0.75rem; font-weight: 600; letter-spacing: 0.28em; text-transform: uppercase; color: rgba(22, 20, 18, 0.42); }
.gl-plate__lab > span:first-child { color: var(--ink); font-weight: 800; letter-spacing: 0.22em; }
.gl-plate__what { display: none; }
.gl-plate__num { display: none; font-family: var(--f-serif); font-size: 8vw; line-height: 1; font-variant-numeric: tabular-nums; }
.gl-plate__num::after { content: "%"; font-size: 0.35em; vertical-align: super; margin-left: 0.15em; color: rgba(22, 20, 18, 0.32); }
.gl-plate__title { font-family: var(--f-serif); font-style: italic; font-size: clamp(2.6rem, 7vw, 7.5rem); line-height: 0.95; letter-spacing: -0.01em; text-align: right; max-width: 70vw; }
.gl-intro .gl-plate__num, .gl-intro .gl-plate__what { display: block; }
.gl-intro .gl-plate__title { display: none; }
/* Safety net: if site.js never runs, the plate still leaves. */
.js.gl-off .gl-plate { animation: gl-plate-out 900ms var(--gl-ease) forwards; }
@keyframes gl-plate-out { to { transform: translateY(-100%); visibility: hidden; } }

/* Words: heading words rise out of their own clip (descender room kept); body words settle out of a blur. */
.gl-word { display: inline-block; white-space: nowrap; }
.gl-mask { display: inline-block; white-space: nowrap; overflow: hidden; vertical-align: top; padding: 0.1em 0.06em 0.14em; margin: -0.1em -0.06em -0.14em; }
.gl-ready .gl-word { opacity: 0; transform: translateY(0.5em); filter: blur(4px); transition: opacity 600ms var(--gl-ease-o), transform 800ms var(--gl-ease), filter 800ms var(--gl-ease); }
.gl-ready .gl-mask .gl-word { transform: translateY(118%); transition: transform 950ms var(--gl-ease); }
.gl-revealed .gl-word { opacity: 1; transform: none; filter: none; }
.gl-revealed .gl-mask .gl-word { transform: none; }

/* Blocks rise 1.75rem (opacity 800 ms, travel 900 ms), siblings 90 ms apart via --d; labels fade. */
.gl-ready .gl-reveal:not(.gl-revealed) [data-reveal], .gl-ready [data-reveal].gl-reveal:not(.gl-revealed) { opacity: 0; }
.gl-revealed [data-reveal], [data-reveal].gl-revealed { animation: gl-up-o 800ms var(--gl-ease) var(--d, 0ms) both, gl-up-t 900ms var(--gl-ease) var(--d, 0ms) both; }
.gl-ready .gl-reveal:not(.gl-revealed) :is(.eyebrow, .link-arrow, .back, .hint, .nl__top, .filters) { opacity: 0; }
.gl-revealed :is(.eyebrow, .link-arrow, .back, .hint, .nl__top, .filters) { animation: gl-up-o 800ms var(--gl-ease) both; }
@keyframes gl-up-o { from { opacity: 0; } to { opacity: 1; } }
@keyframes gl-up-t { from { translate: 0 1.75rem; } to { translate: 0 0; } }

/* Loopstack wordmark: one unbreakable line fitted to the frame, glyphs sweep in from the left out of a 20px blur. */
.gl-wm { margin: clamp(56px, 8vw, 112px) 0 2rem; overflow: hidden; }
.gl-wm__name { display: inline-block; white-space: nowrap; font-family: "Montserrat", var(--f-sans); font-weight: 800; font-size: 18vw; line-height: 0.8; letter-spacing: -0.03em; color: var(--stone); }
.gl-wm__mask { display: inline-block; overflow: hidden; vertical-align: bottom; line-height: 0.8; padding: 0.06em 0.05em 0; margin: 0 -0.08em 0 -0.05em; }
.gl-wm__mask:last-child { margin-right: 0; }
.gl-wm__glyph { display: inline-block; letter-spacing: 0; }
.gl-ready .gl-wm__glyph { opacity: 0; transform: translateX(-105%); filter: blur(20px); }
.gl-wm.gl-revealed .gl-wm__glyph { animation: gl-letter 1.2s var(--gl-ease-sweep) forwards; }
@keyframes gl-letter { 0% { opacity: 0; transform: translateX(-105%); filter: blur(20px); } 25% { opacity: 1; } 100% { opacity: 0.95; transform: translateX(0); filter: blur(0); } }
.gl-wm__sub { margin-top: 1rem; font-size: clamp(0.95rem, 1.7vw, 1.6rem); font-weight: 600; letter-spacing: 0.01em; color: var(--stone-2); }
.gl-ready .gl-reveal:not(.gl-revealed) .gl-wm__sub { opacity: 0; }
.gl-wm.gl-revealed .gl-wm__sub { animation: gl-up-o 800ms var(--gl-ease) 1.4s both; }

/* Numeral Steps — the orange field is DIPIETRA's own; composition and motion as shipped. */
.nl {
  --field: var(--accent); --nl-ink: #161412; --nl-line: rgba(22, 20, 18, 0.5); --nl-muted: rgba(22, 20, 18, 0.66);
  --text-label: 1.0625rem; --text-heading: 2.75rem; --text-lead: 1.3rem; --text-step: 1.0625rem; --text-number: 17.5rem;
  --section-padding-y: 7.5rem; --grid-margin: var(--gutter); --grid-gutter: 1.25rem; --content-max: calc(var(--max) - 2 * var(--gutter));
  --text-max: 33.4375rem; --intro-gap: 7.5rem; --window-h: 36rem;
  position: relative; background: var(--field); color: var(--nl-ink);
}
@media (max-width: 1439px) { .nl { --text-label: 1rem; --text-heading: 2.25rem; --text-lead: 1.2rem; --text-step: 1rem; --text-number: 12.5rem; --section-padding-y: 6rem; --intro-gap: 5rem; --window-h: 30rem; } }
@media (max-width: 1023px) { .nl { --text-heading: 2rem; --text-number: 11.25rem; --section-padding-y: 5rem; --intro-gap: 3rem; --text-max: 45.5rem; } }
@media (max-width: 767px) { .nl { --text-heading: 1.75rem; --text-lead: 1.1rem; --text-number: 7.5rem; --section-padding-y: 4rem; } }
.nl ol { list-style: none; padding: 0; }
.nl__stage { padding: var(--section-padding-y) var(--grid-margin); min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; justify-content: center; }
.nl__wrap { width: 100%; max-width: var(--content-max); margin: 0 auto; display: flex; flex-direction: column; gap: 4rem; }
.nl__top { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--grid-gutter); font-size: var(--text-label); line-height: 1.4; font-weight: 600; letter-spacing: 0.02em; }
.nl__link { position: relative; color: inherit; text-decoration: none; border-radius: 2px; }
.nl__link:focus-visible { outline: 2px solid var(--nl-ink); outline-offset: 4px; }
.nl__line { position: absolute; left: 0; right: 0; top: 1.125em; height: 1px; overflow: hidden; overflow: clip; pointer-events: none; }
.nl__line::before, .nl__line::after { content: ""; position: absolute; inset: 0; background: currentColor; }
.nl__line::after { transform: translate3d(-200%, 0, 0); }
.nl__link[data-flow] .nl__line::before { transform: translate3d(200%, 0, 0); transition: transform var(--flow, 700ms) cubic-bezier(.65, 0, .35, 1); }
.nl__link[data-flow] .nl__line::after { transform: translate3d(0, 0, 0); transition: transform var(--flow, 700ms) cubic-bezier(.65, 0, .35, 1); }
.nl__link:not(.has-fx):focus-visible .nl__line { height: 2px; }
@media (hover: hover) and (pointer: fine) { .nl__link:not(.has-fx):hover .nl__line { height: 2px; } }
@media (pointer: coarse) { .nl__link::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 2.75rem; transform: translateY(-50%); } }
.nl__main { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--grid-gutter); align-items: stretch; }
.nl__intro { grid-column: 1 / span 5; min-height: var(--window-h); display: flex; flex-direction: column; justify-content: space-between; gap: var(--intro-gap); padding-top: 1.5rem; }
.nl__heading, .nl__body { max-width: var(--text-max); }
.nl__heading { font-weight: 700; font-size: var(--text-heading); line-height: 1.08; letter-spacing: -0.02em; }
.nl__heading span { display: block; }
.nl__heading .serif { font-family: var(--f-serif); font-style: italic; font-weight: 400; color: var(--nl-ink); font-size: 1.12em; letter-spacing: -0.01em; }
.nl__body { display: flex; flex-direction: column; gap: 1.5rem; font-size: var(--text-lead); line-height: 1.45; }
.nl__window { grid-column: 7 / span 6; position: relative; }
.nl__frame { position: absolute; left: 0; right: 0; height: 1px; background: var(--nl-line); z-index: 1; pointer-events: none; }
.nl__frame--top { top: 0; }
.nl__frame--bottom { bottom: 0; }
.nl__step { position: relative; display: flex; justify-content: space-between; align-items: flex-end; gap: var(--grid-gutter); padding: 2rem 0 1.5rem; border-bottom: 1px solid var(--nl-line); }
.nl__step:last-child { border-bottom: 0; }
.nl__meta { padding-bottom: 1rem; font-size: var(--text-step); line-height: 1.4; min-width: 0; }
.nl__title { font-weight: 700; font-size: 1.15em; letter-spacing: -0.01em; }
.nl__sub { color: var(--nl-muted); }
.nl__num { flex: none; font-weight: 400; font-size: var(--text-number); line-height: 0.84; letter-spacing: -0.04em; clip-path: inset(-40% -12% 0 -12%); }
.nl__num > span { display: block; padding-right: 0.04em; will-change: transform; }
.nl.is-pinned .nl__stage { position: sticky; top: var(--pin-top, 0px); }
.nl.is-pinned .nl__window { overflow: hidden; }
.nl.is-pinned .nl__steps { position: absolute; left: 0; right: 0; top: 0; will-change: transform; }
@media (max-width: 1023px) {
  .nl__main { grid-template-columns: repeat(8, minmax(0, 1fr)); row-gap: 4rem; }
  .nl__intro, .nl__window { grid-column: 1 / -1; }
  .nl__intro { min-height: 0; justify-content: flex-start; padding-top: 0; }
}
@media (max-width: 767px) { .nl__main { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1024px) and (max-height: 880px) {
  .nl { --window-h: min(30rem, calc(100svh - 14rem)); --intro-gap: 2.5rem; }
  .nl__stage { padding: calc(var(--header-h) + 1.5rem) var(--grid-margin) 2rem; }
}

/* ---------- responsive ---------- */
@media (max-width: 1023px) {
  .menu-toggle { display: inline-block; }
  .nav-wrap { position: fixed; inset: 0; z-index: -1; display: none; flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: 2.5rem; padding: calc(var(--header-h) + 64px) var(--gutter) 40px; background: var(--bg); overflow-y: auto; }
  .is-open .nav-wrap { display: flex; }
  .nav { flex-direction: column; gap: 0.9rem; }
  .nav a { font-size: clamp(2rem, 7vw, 2.8rem); font-weight: 700; letter-spacing: -0.03em; }
  .hero__grid, .page-hero__grid, .process, .trust, .svc, .project-hero__grid, .about, .academy, .contact { grid-template-columns: minmax(0, 1fr); }
  .hero__media { max-width: 640px; }
  .svc:nth-child(even) .svc__media { order: 0; }
  .svc__media, .project-hero__media, .about__media { aspect-ratio: 4 / 4.4; }
  .process__media { position: relative; top: 0; aspect-ratio: 16 / 11; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cards--stagger .card:nth-child(3n + 2) { margin-top: 0; }
  .cards--stagger .card:nth-child(3) { display: none; }
  .steps--grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .manifesto, .story { grid-template-columns: minmax(0, 1fr); }
  .contact__side { position: static; }
  .footer__top { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .footer__top > div:first-child { grid-column: 1 / -1; }
  .trust__media { order: 2; }
}
@media (max-width: 640px) {
  :root { --header-h: 64px; }
  .logo img { height: 19px; }
  .hero__media { grid-template-columns: minmax(0, 1fr) minmax(0, 0.62fr); }
  .hero__main { aspect-ratio: 9 / 13; }
  .actions .btn { flex: 1 1 auto; }
  .cards { grid-template-columns: minmax(0, 1fr); }
  .cards--stagger .card:nth-child(3) { display: block; }
  .points, .values, .steps--grid { grid-template-columns: minmax(0, 1fr); }
  .service-row { grid-template-columns: 40px minmax(0, 1fr) 20px; gap: 0.35rem 0.75rem; }
  .service-row__d { grid-column: 2 / 3; grid-row: 2; font-size: 0.95rem; }
  .service-row__go { grid-column: 3; grid-row: 1; }
  .cta-band { grid-template-columns: minmax(0, 1fr); }
  .cta-band .btn { width: 100%; white-space: normal; }
  .contact__form .btn { width: 100%; white-space: normal; }
  .row-2 { grid-template-columns: minmax(0, 1fr); }
  .facts { grid-template-columns: minmax(0, 1fr); }
  .loops { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .loops .loop:nth-child(3):last-child { display: none; } /* three clips: two on a phone; four: a 2x2 grid */
  .gallery, .gallery--3 { columns: 2; column-gap: 10px; }
  .gallery a { margin-bottom: 10px; }
  .footer__top { grid-template-columns: minmax(0, 1fr); }
  .filters__status { margin-left: 0; width: 100%; }
  .card__meta { flex-wrap: wrap; gap: 0.2rem 1rem; }
  .lightbox__figure { padding: 64px 12px; }
  .lightbox__prev, .lightbox__next { top: auto; bottom: 16px; transform: none; }
  .lightbox__prev { left: calc(50% - 60px); }
  .lightbox__next { right: calc(50% - 60px); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .gl-plate { display: none !important; }
  .gl-word, .gl-mask .gl-word, .gl-wm__glyph, .gl-wm__sub, .gl-reveal [data-reveal], .gl-reveal :is(.eyebrow, .link-arrow, .back, .hint, .nl__top, .filters) { opacity: 1 !important; transform: none !important; filter: none !important; translate: none !important; }
}
@media (max-width: 640px) {
  .gl-plate__num { font-size: 22vw; }
  .gl-plate__title { font-size: clamp(2.2rem, 11vw, 3.6rem); max-width: 62vw; }
  .gl-plate__lab { font-size: 0.68rem; letter-spacing: 0.22em; }
}

/* ===================================================================== Hero sequence
   GetLayers "House" frame engine, full screen under the header (see site.js). Static by default — no JS, reduced motion
   or Save-Data show the finished wall with the headline; .is-live pins the stage and scrubs the job with the scroll. */
.seq { position: relative; background: var(--dark); color: var(--stone); --travel: 540svh; --pad-b: clamp(64px, 10vh, 116px); }
.seq__stage { position: relative; height: calc(100svh - var(--header-h)); min-height: 520px; overflow: hidden; }
.seq__media { position: absolute; inset: 0; margin: 0; background: #0b0a09; }
.seq__canvas, .seq__still, .seq__still img { position: absolute; inset: 0; width: 100%; height: 100%; }
.seq__canvas, .seq__still img { object-fit: cover; }
.seq__canvas { display: none; z-index: 1; }
.seq__still { z-index: 0; }
.seq__media::after { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; background: linear-gradient(to top, rgba(12, 11, 9, 0.74) 0%, rgba(12, 11, 9, 0.32) 32%, rgba(12, 11, 9, 0) 58%), linear-gradient(to right, rgba(12, 11, 9, 0.42) 0%, rgba(12, 11, 9, 0) 55%); }
.seq__ui { position: relative; z-index: 3; height: 100%; }
.seq__intro { position: absolute; left: var(--gutter); right: var(--gutter); bottom: var(--pad-b); max-width: 52rem; }
.seq__intro .display { color: #fff; margin: 1.1rem 0 1.25rem; font-size: clamp(2.7rem, 6.6vw, 6.8rem); }
.seq__intro .display .serif, .seq__name .serif { color: #f3c9b6; }
.seq__intro .lead { color: rgba(236, 230, 220, 0.88); }
.seq__intro .actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.7rem; }
.btn--ghost-light { color: #fff; background-image: linear-gradient(#fff, #fff); }
.btn--ghost-light:hover { color: var(--ink); border-color: #fff; }
.seq__aside { position: absolute; right: var(--gutter); bottom: var(--pad-b); margin: 0; display: grid; justify-items: end; gap: 0.7rem; font-size: 0.72rem; font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase; color: rgba(236, 230, 220, 0.86); }
.seq__tag { padding: 0.5rem 0.9rem; border: 1px solid rgba(255, 255, 255, 0.14); border-radius: 999px; background: rgba(11, 10, 9, 0.5); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
.seq__hint { display: none; align-items: center; gap: 0.7rem; }
.seq__hint i { width: 1px; height: 30px; background: currentColor; transform-origin: top; animation: seq-hint 1.8s cubic-bezier(.16, 1, .3, 1) infinite; }
@keyframes seq-hint { 0% { transform: scaleY(0); } 55% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1); opacity: 0; } }
.seq__steps, .seq__rail, .seq__link { display: none; }
.seq__steps { list-style: none; margin: 0; padding: 0; }
.seq__step { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0 1.1rem; max-width: 38rem; }
.seq__n { padding-top: 0.75em; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.14em; color: var(--accent); font-variant-numeric: tabular-nums; }
.seq__name { font-size: clamp(2.1rem, 4vw, 3.8rem); font-weight: 750; line-height: 1.02; letter-spacing: -0.035em; color: #fff; }
.seq__step p { margin-top: 0.7rem; max-width: 36ch; font-size: clamp(1rem, 1.2vw, 1.14rem); line-height: 1.55; color: rgba(236, 230, 220, 0.88); }
.seq__rail { position: absolute; left: var(--gutter); right: var(--gutter); bottom: clamp(24px, 4vh, 36px); height: 3px; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.seq__rail i { position: relative; overflow: hidden; border-radius: 2px; background: rgba(255, 255, 255, 0.24); }
.seq__rail i::after { content: ""; position: absolute; inset: 0; background: #fff; transform-origin: left; transform: scaleX(var(--f, 0)); }

.seq.is-live { height: calc(100svh - var(--header-h) + var(--travel)); }
.seq.is-live .seq__stage { position: sticky; top: var(--header-h); }
.seq.is-live .seq__canvas { display: block; }
.seq.is-live .seq__hint { display: inline-flex; }
.seq.is-live .seq__steps { display: block; position: absolute; left: var(--gutter); right: var(--gutter); bottom: var(--pad-b); }
.seq.is-live .seq__step { position: absolute; left: 0; bottom: 0; opacity: 0; visibility: hidden; will-change: transform, opacity, filter; }
.seq.is-live .seq__rail { display: grid; opacity: 0; }
.seq.is-live .seq__link { display: inline-flex; position: absolute; right: var(--gutter); bottom: var(--pad-b); opacity: 0; translate: 0 0.75rem; visibility: hidden; transition: opacity 0.5s, translate 0.7s cubic-bezier(.16, 1, .3, 1), visibility 0s 0.7s; }
.seq.is-live.is-end .seq__link { opacity: 1; translate: 0 0; visibility: visible; transition-delay: 0s; }
@media (max-width: 767px) {
  .seq { --travel: 440svh; --pad-b: 64px; }
  .seq--video { --pad-b: 92px; } /* the hero's buttons stay above the WhatsApp button */
  .seq__media::after { background: linear-gradient(to top, rgba(12, 11, 9, 0.84) 0%, rgba(12, 11, 9, 0.5) 36%, rgba(12, 11, 9, 0) 66%), linear-gradient(to bottom, rgba(12, 11, 9, 0.5) 0%, rgba(12, 11, 9, 0) 20%); }
  .seq__intro .display { font-size: clamp(2.4rem, 11.4vw, 3.4rem); margin: 0.9rem 0 1rem; }
  .seq__intro .lead { font-size: 1rem; }
  .seq__intro .actions { margin-top: 1.3rem; }
  .seq__intro .actions .btn { padding: 0.85rem 1.15rem; font-size: 0.95rem; }
  .seq__aside { left: var(--gutter); right: auto; top: 18px; bottom: auto; justify-items: start; }
  .seq.is-live .seq__link { left: var(--gutter); right: auto; top: 22px; bottom: auto; }
  .seq__name { font-size: clamp(1.9rem, 8.6vw, 2.5rem); }
  .seq__step { gap: 0 0.8rem; }
  .seq__step p { font-size: 0.98rem; }
}
@media (min-width: 768px) and (max-height: 760px) {
  .seq__intro .display { font-size: clamp(2.4rem, 5.6vw, 5.4rem); margin: 0.8rem 0 0.9rem; }
  .seq__intro .actions { margin-top: 1.2rem; }
}

/* hero as an autoplay video (no scroll scrub): wide cut on landscape screens, vertical cut on phones and portrait tablets */
.seq__v { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.seq__v--tall { display: none; }
@media (max-width: 767px), (orientation: portrait) and (max-width: 1023px) { .seq__v--wide { display: none; } .seq__v--tall { display: block; } }
.seq--video .seq__aside { gap: 0.8rem; min-width: 300px; }
@media (min-width: 768px) { .seq--video .seq__aside { bottom: max(var(--pad-b), 96px); } } /* clear of the WhatsApp button */
.seq__worklink { position: absolute; right: var(--gutter); top: clamp(20px, 4vh, 40px); }
@media (max-width: 767px) {
  .seq--video .seq__aside { min-width: 0; width: calc(100% - 2 * var(--gutter)); }
  .seq__worklink { display: none; }
}

/* ===================================================================== TikTok (home): a placeholder, then TikTok's own box */
.tiktok__grid { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(2.5rem, 6vw, 6rem); align-items: center; }
.tiktok__intro .lead { margin-top: 1.1rem; max-width: 32rem; }
.tiktok__intro .link-arrow { margin-top: 1.8rem; }
.tiktok__frame { position: relative; display: grid; min-height: 480px; border-radius: calc(var(--radius) * 1.3); background: var(--dark); color: var(--stone); overflow: hidden; }
.tiktok__slot { grid-area: 1 / 1; min-width: 0; align-self: start; }
.tiktok__iframe { display: block; width: 100%; height: 480px; border: 0; background: #fff; }
.tiktok__slot:empty { display: none; }
.tiktok__gate { grid-area: 1 / 1; position: relative; z-index: 1; display: grid; align-content: center; justify-items: center; gap: 0.9rem; padding: clamp(28px, 5vw, 56px); text-align: center; background: var(--dark); }
.tiktok__icon { width: 68px; height: 68px; margin-bottom: 0.3rem; border-radius: 20px; background: #000; display: grid; place-items: center; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35); }
.tiktok__icon svg { width: 34px; height: 34px; fill: #fff; filter: drop-shadow(-1.5px -1.5px 0 #25f4ee) drop-shadow(1.5px 1.5px 0 #fe2c55); }
.tiktok__handle { font-weight: 600; font-size: 1.05rem; color: #fff; }
.tiktok__status, .tiktok__failed { font-size: 0.95rem; color: #fff; max-width: 28rem; }
.tiktok__notice { max-width: 30rem; margin-top: 0.3rem; font-size: 0.82rem; line-height: 1.55; color: rgba(236, 230, 220, 0.72); }
.tiktok__notice a, .tiktok__failed a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.tiktok [hidden] { display: none !important; }
.tiktok__frame.is-loading .tiktok__icon { animation: tt-pulse 1.2s ease-in-out infinite; }
@keyframes tt-pulse { 50% { transform: scale(0.92); opacity: 0.7; } }
.tiktok__frame.is-open { background: #fff; }
.tiktok__bar { display: none; position: absolute; z-index: 2; top: 12px; right: 12px; margin: 0; } /* over the frame, top right (TikTok puts its own buttons at the bottom): opening it moves nothing */
.tiktok__frame.is-open .tiktok__bar { display: block; }
.tiktok__close { font: inherit; font-size: 0.8rem; font-weight: 600; color: var(--ink); background: rgba(255, 255, 255, 0.94); border: 1px solid rgba(22, 20, 18, 0.14); border-radius: 999px; padding: 6px 12px; cursor: pointer; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1); }
.tiktok__frame.is-open .tiktok__gate { display: none; }
html:not(.js) [data-tiktok-load] { display: none; }
@media (max-width: 900px) { .tiktok__grid { grid-template-columns: 1fr; } .tiktok__frame { min-height: 400px; } .tiktok__iframe { height: 400px; } }
@media (prefers-reduced-motion: reduce) { .tiktok__frame.is-loading .tiktok__icon { animation: none; } }
.legal__block { scroll-margin-top: calc(var(--header-h) + 24px); }

/* ===================================================================== Before / after slider */
/* the whole picture fits one screen under the header: width follows the height budget */
.ba__fig { margin: 0 auto; width: min(100%, calc((100svh - var(--header-h) - 110px) * 1.5)); }
.ba__frame { --pos: 50%; position: relative; overflow: hidden; border-radius: var(--radius); aspect-ratio: 3 / 2; background: var(--bg-2); touch-action: pan-y; -webkit-user-select: none; user-select: none; cursor: ew-resize; -webkit-tap-highlight-color: transparent; }
.ba__after, .ba__before { position: absolute; inset: 0; }
.ba__frame picture { display: block; width: 100%; height: 100%; }
.ba__frame img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; -webkit-user-drag: none; }
.ba__before { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.ba__handle { position: absolute; top: 0; bottom: 0; left: var(--pos); z-index: 3; width: 0; pointer-events: none; }
.ba__handle::before { content: ""; position: absolute; top: 0; bottom: 0; left: -1px; width: 2px; background: #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.06), 0 0 22px rgba(0, 0, 0, 0.28); }
.ba__knob { position: absolute; top: 50%; left: 0; display: grid; place-items: center; width: 58px; height: 58px; translate: -50% -50%; border-radius: 50%; background: #fff; color: var(--ink); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28); transition: scale 0.35s var(--ease), background 0.25s, color 0.25s; }
.ba__frame:hover .ba__knob { scale: 1.06; }
.ba__frame.is-dragging .ba__knob { scale: 1.1; background: var(--accent); color: #fff; }
.ba__frame:has(.ba__range:focus-visible) .ba__knob { outline: 2px solid var(--accent); outline-offset: 4px; }
.ba__tag { position: absolute; top: 16px; z-index: 2; padding: 0.45rem 0.85rem; border-radius: 999px; background: rgba(18, 17, 15, 0.62); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); color: #fff; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; pointer-events: none; transition: opacity 0.3s; }
.ba__tag--before { left: 16px; }
.ba__tag--after { right: 16px; }
.ba__frame.is-after .ba__tag--before, .ba__frame.is-before .ba__tag--after { opacity: 0; }
.ba__range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; pointer-events: none; }
.ba__cap { margin-top: 0.9rem; font-size: 0.85rem; color: var(--muted); }
.ba__note { display: block; margin-top: 0.3rem; font-size: 0.78rem; opacity: 0.85; }
@media (max-width: 767px) {
  .ba__fig { width: min(100%, calc((100svh - var(--header-h) - 110px) * 0.8)); }
  .ba__frame { aspect-ratio: 1093 / 1362; }
  .ba__knob { width: 50px; height: 50px; }
  .ba__tag { top: 12px; }
  .ba__tag--before { left: 12px; }
  .ba__tag--after { right: 12px; }
}

/* ===================================================================== Come lavoriamo: pile of step cards
   GetLayers «cards-almanac» (as ported for the lavanderia template): each card pins under the header and the next one
   settles over it — it arrives tilted (--settle) and lands flat, while the covered card steps back under a pale veil
   (--cover). Without JS or with reduced motion it is a plain list. */
.pile-sec { background: var(--accent); color: var(--ink); padding: clamp(80px, 10vw, 144px) 0; }
.pile-sec__grid { display: grid; grid-template-columns: minmax(0, 1fr); row-gap: clamp(2rem, 5vw, 3rem); }
.pile-sec__label { color: var(--ink); }
.pile-sec__heading { margin-top: 1.1rem; font-size: clamp(2.1rem, 4.4vw, 3.9rem); font-weight: 750; line-height: 1.02; letter-spacing: -0.035em; max-width: 13ch; }
.pile-sec__heading .serif { display: block; color: var(--ink); font-weight: 400; }
.pile-sec__body { display: grid; gap: 0.9rem; margin-top: 1.4rem; max-width: 42ch; font-size: 1.06rem; line-height: 1.6; color: rgba(22, 20, 18, 0.8); }
.pile-sec__link { margin-top: 1.6rem; }
.pile { display: grid; gap: 1rem; margin: 0; padding: 0; list-style: none; }
.pile__card { position: relative; min-width: 0; }
.pile__inner { --settle: 0; --cover: 0; position: relative; isolation: isolate; display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem; padding: 0.75rem 0.75rem 1.5rem; border-radius: var(--radius); background: var(--paper); box-shadow: 0 1px 0 rgba(22, 20, 18, 0.06), 0 -18px 40px -30px rgba(22, 20, 18, 0.5), 0 26px 54px -34px rgba(22, 20, 18, 0.55); overflow: hidden; transform-origin: 50% 0; }
.pile__inner::after { content: ""; position: absolute; inset: 0; z-index: 3; border-radius: inherit; background: rgba(242, 238, 231, 0.82); opacity: calc(var(--cover) * 0.6); pointer-events: none; }
.pile__ghost { position: absolute; right: 0.9rem; bottom: -0.18em; z-index: -1; font-size: clamp(6rem, 26vw, 9.5rem); font-weight: 800; line-height: 1; letter-spacing: -0.05em; color: rgba(22, 20, 18, 0.06); pointer-events: none; user-select: none; }
.pile__media { position: relative; aspect-ratio: 16 / 10; border-radius: calc(var(--radius) - 6px); overflow: hidden; background: var(--bg-2); }
.pile__media > img, .pile__media > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pile__copy { min-width: 0; padding-inline: 0.75rem; }
.pile__kicker { display: flex; align-items: center; gap: 0.6rem; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.pile__num { display: inline-grid; place-items: center; width: 1.9rem; height: 1.9rem; border-radius: 50%; background: var(--accent); color: #fff; font-size: 0.92rem; letter-spacing: 0; }
.pile__title { margin-top: 0.75rem; font-size: clamp(1.5rem, 2.3vw, 2.05rem); font-weight: 750; line-height: 1.08; letter-spacing: -0.025em; }
.pile__sub { margin-top: 0.3rem; font-family: var(--f-serif); font-style: italic; font-size: 1.18rem; color: var(--accent-2); }
.pile__text { margin-top: 0.7rem; max-width: 46ch; line-height: 1.58; color: var(--ink-2); }
.pile-sec.is-live .pile { gap: clamp(2.5rem, 22svh, 12rem); padding-bottom: 4svh; }
.pile-sec.is-live .pile__card { position: sticky; top: calc(var(--header-h) + 0.75rem + var(--i, 0) * 0.8rem); }
.pile-sec.is-live .pile__inner { transform: rotate(calc(var(--settle) * -1.4deg)) translate3d(0, calc(var(--settle) * 10px), 0) scale(calc(1 - var(--cover) * 0.055)); will-change: transform; }
@media (min-width: 640px) {
  .pile__inner { grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr); align-items: center; gap: 1.5rem; min-height: 300px; padding: 0.75rem 1.5rem 0.75rem 0.75rem; }
  .pile__media { width: 100%; aspect-ratio: 1 / 0.82; }
  .pile__copy { padding: 1rem 0; }
}
@media (min-width: 1024px) {
  .pile-sec__grid { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(1.5rem, 3vw, 3rem); align-items: start; }
  .pile-sec__side { grid-column: 1 / span 5; position: sticky; top: calc(var(--header-h) + 2rem); }
  .pile { grid-column: 6 / span 7; }
  .pile__inner { min-height: 340px; padding: 0.9rem 2rem 0.9rem 0.9rem; }
  .pile__ghost { font-size: 10rem; }
}
@media (prefers-reduced-motion: reduce) {
  .pile__inner { transform: none !important; }
  .pile__inner::after { opacity: 0; }
}

/* ===================================================================== Lavorazioni rail
   GetLayers «client-reviews-carousel»: a transform-driven rail (not scroll-snap) that bleeds into the right gutter on
   desktop; card width and gap are inline vars set by site.js from a cumulative breakpoint table (the stylesheet only
   carries structure). Without JS the viewport simply scrolls sideways. */
.rail { --card-w: 400px; --gap: 24px; --dur: 320ms; overflow: hidden; }
.rail__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; margin-bottom: clamp(28px, 4vw, 52px); }
.rail__head .title { margin-top: 1rem; max-width: 15ch; }
.rail__nav { display: flex; gap: 12px; flex: none; padding-bottom: 6px; }
.rail__btn { display: grid; place-items: center; width: 58px; height: 58px; flex: none; border: 0; border-radius: 50%; background: var(--ink); color: var(--bg); cursor: pointer; transition: transform var(--dur) cubic-bezier(.22, .61, .36, 1), opacity var(--dur) ease, background var(--dur) ease; }
.rail__btn svg { width: 20px; height: 20px; }
.rail__btn:hover { transform: translateY(-2px); background: var(--accent); }
.rail__btn:active { transform: translateY(0); }
.rail__btn[disabled] { opacity: 0.22; cursor: default; transform: none; background: var(--ink); }
.rail__viewport { overflow-x: auto; margin-right: calc(var(--gutter) * -1); padding-block: 8px; outline-offset: 6px; }
.js .rail__viewport { overflow: hidden; }
.rail__track { display: flex; gap: var(--gap); will-change: transform; transition: transform var(--dur) cubic-bezier(.22, .61, .36, 1); touch-action: pan-y; }
.rail__track.is-drag { transition: none; cursor: grabbing; }
.rail__card { flex: 0 0 var(--card-w); width: var(--card-w); min-width: 0; transition: transform var(--dur) cubic-bezier(.22, .61, .36, 1); }
.rail__card:hover { transform: translateY(-6px); }
.rail__link { display: flex; flex-direction: column; height: 100%; border-radius: var(--radius); background: var(--paper); box-shadow: inset 0 0 0 1px var(--line); text-decoration: none; color: inherit; overflow: hidden; -webkit-user-drag: none; user-select: none; -webkit-user-select: none; }
.rail__media { position: relative; aspect-ratio: 4 / 4.6; margin: 10px 10px 0; border-radius: calc(var(--radius) - 4px); overflow: hidden; background: var(--bg-2); }
.rail__media > img, .rail__media > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; transition: transform 0.8s var(--ease); }
.rail__card:hover .rail__media > * { transform: scale(1.04); }
.rail__body { display: grid; gap: 0.45rem; padding: 1.1rem 1.25rem 1.35rem; }
.rail__n { color: var(--accent); font-weight: 700; font-size: 0.85rem; letter-spacing: 0.12em; }
.rail__title { font-size: clamp(1.35rem, 1.9vw, 1.7rem); font-weight: 750; line-height: 1.08; letter-spacing: -0.025em; }
.rail__text { color: var(--muted); line-height: 1.5; }
.rail__go { margin-top: 0.4rem; font-weight: 600; font-size: 0.95rem; }
.rail__go span { display: inline-block; transition: transform 0.3s var(--ease); }
.rail__card:hover .rail__go span { transform: translateX(5px); }
.rail__card:hover .rail__title { color: var(--accent-2); }
.rail__more { display: flex; justify-content: flex-start; margin-top: clamp(26px, 3.6vw, 44px); }
@media (max-width: 1240px) { .rail__btn { width: 52px; height: 52px; } }
@media (max-width: 640px) {
  .rail__head { flex-direction: column; align-items: flex-start; gap: 1.2rem; }
  .rail__nav { padding-bottom: 0; }
  .rail__btn { width: 46px; height: 46px; }
  .rail__btn svg { width: 17px; height: 17px; }
  .rail__viewport { margin-right: 0; }
}
@media (prefers-reduced-motion: reduce) { .rail__track, .rail__card, .rail__btn, .rail__media > * { transition: none !important; } }
/* large variant (Lavorazioni page): the card is a panel with the full text, the uses and a link, not one big link */
.rail__panel { display: flex; flex-direction: column; height: 100%; border-radius: var(--radius); background: var(--paper); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.rail--lg .rail__card { scroll-margin-top: calc(var(--header-h) + 150px); }
.rail--lg .rail__card:hover { transform: none; }
.rail--lg .rail__media { aspect-ratio: 16 / 11; }
.rail--lg .rail__body { gap: 0.6rem; padding: 1.3rem 1.5rem 1.6rem; flex: 1; align-content: start; }
.rail--lg .rail__title { font-size: clamp(1.6rem, 2.4vw, 2.2rem); }
.rail--lg .rail__text { color: var(--ink-2); font-size: 1rem; line-height: 1.6; }
.rail--lg .uses { margin: 0.6rem 0 0.9rem; }
.rail--lg .link-arrow { justify-self: start; white-space: normal; }
@media (max-width: 640px) { .rail--lg .rail__body { padding: 1.1rem 1.1rem 1.3rem; } .rail--lg .rail__text { font-size: 0.97rem; } }

/* ---------- privacy page, footer legal line, cookie banner ---------- */
.footer__legal a, .footer__consent { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.footer__consent { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
.footer__legal a:hover, .footer__consent:hover { color: var(--accent); }
.footer__credit { white-space: nowrap; }
.legal { max-width: 820px; display: grid; gap: 2.2rem; }
.legal__block h2 { font-size: clamp(1.35rem, 2vw, 1.7rem); font-weight: 750; letter-spacing: -0.02em; margin-bottom: 0.7rem; }
.legal__block p { color: var(--ink-2); max-width: 70ch; }
.legal__block p + p, .legal__block p + ul, .legal__block ul + p { margin-top: 0.8rem; }
.legal__block ul { margin: 0.8rem 0 0; padding-left: 1.2rem; color: var(--ink-2); display: grid; gap: 0.45rem; max-width: 70ch; }
.legal__updated { color: var(--muted); font-size: 0.9rem; }
.check a { color: inherit; font-weight: 600; text-underline-offset: 3px; }

.consent { position: fixed; z-index: 90; left: 16px; right: 16px; bottom: 16px; max-width: 600px; max-height: calc(100vh - 32px); overflow-y: auto; margin-left: auto; background: var(--dark); color: var(--stone); border-radius: calc(var(--radius) * 1.3); padding: 22px 22px 18px; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35); transform: translateY(0); transition: transform 0.4s var(--ease), opacity 0.4s; }
.consent[hidden] { display: block; transform: translateY(calc(100% + 32px)); opacity: 0; pointer-events: none; visibility: hidden; }
.consent__title { font-size: 1.05rem; font-weight: 700; margin: 0 3.2rem 0.5rem 0; }
.consent__text { font-size: 0.92rem; line-height: 1.55; color: var(--stone-2); }
.consent__text a { color: var(--stone); text-underline-offset: 3px; }
.consent__actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 16px; }
.consent__actions .btn, .consent__save { width: 100%; padding: 0.85rem 0.6rem; white-space: normal; }
.consent__btn { background: var(--stone); color: var(--ink); border: 0; }
.consent__btn:hover { background: #fff; }
.consent__close { position: absolute; top: 12px; right: 12px; width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid var(--stone-2); background: transparent; color: var(--stone); font-size: 1.6rem; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.consent__close:hover { color: var(--ink); background: var(--stone); }
.consent__panel { margin-top: 16px; border-top: 1px solid var(--line-dark); padding-top: 14px; display: grid; gap: 14px; }
.consent__panel[hidden] { display: none; }
.consent__row { display: grid; grid-template-columns: 1fr auto; gap: 4px 14px; align-items: start; }
.consent__row b { font-size: 0.95rem; }
.consent__row p { grid-column: 1 / -1; font-size: 0.85rem; line-height: 1.5; color: var(--stone-2); }
.consent__fixed { font-size: 0.8rem; color: var(--stone-2); font-weight: 600; }
.consent__switch { appearance: none; width: 46px; height: 28px; border-radius: 14px; background: rgba(236, 230, 220, 0.25); position: relative; cursor: pointer; margin: 0; flex: none; }
.consent__switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: translate 0.2s; }
.consent__switch:checked { background: var(--accent); }
.consent__switch:checked::after { translate: 18px 0; }
.consent__switch:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
@media (max-width: 520px) {
  .consent { left: 10px; right: 10px; bottom: 10px; padding: 18px 16px 14px; }
  .consent__actions { grid-template-columns: 1fr; gap: 8px; }
}
@media (prefers-reduced-motion: reduce) { .consent { transition: none; } }

/* ---------- floating WhatsApp button (every page, desktop and phone) ---------- */
.wa-bubble { position: fixed; z-index: 70; right: max(20px, env(safe-area-inset-right)); bottom: max(20px, calc(env(safe-area-inset-bottom) + 14px)); display: flex; align-items: center; gap: 12px; text-decoration: none; -webkit-tap-highlight-color: transparent; animation: wa-in 0.5s var(--ease) 1.4s both; }
.wa-bubble__icon { width: 60px; height: 60px; border-radius: 50%; background: #25d366; color: #fff; display: grid; place-items: center; box-shadow: 0 10px 26px rgba(0, 0, 0, 0.25), 0 2px 6px rgba(0, 0, 0, 0.12); transition: transform 0.25s var(--ease), box-shadow 0.25s; }
.wa-bubble__icon svg { width: 31px; height: 31px; fill: currentColor; }
.wa-bubble__label { background: #fff; color: var(--ink); font-weight: 600; font-size: 0.9rem; padding: 0.55rem 0.95rem; border-radius: 999px; box-shadow: 0 8px 22px rgba(0, 0, 0, 0.14); white-space: nowrap; opacity: 0; transform: translateX(8px); transition: opacity 0.25s, transform 0.25s var(--ease); pointer-events: none; }
.wa-bubble:hover .wa-bubble__icon, .wa-bubble:focus-visible .wa-bubble__icon { transform: scale(1.07); box-shadow: 0 14px 30px rgba(0, 0, 0, 0.28), 0 2px 6px rgba(0, 0, 0, 0.12); }
.wa-bubble:focus-visible { outline: none; }
.wa-bubble:focus-visible .wa-bubble__icon { outline: 3px solid var(--accent); outline-offset: 3px; }
@media (hover: hover) { .wa-bubble:hover .wa-bubble__label, .wa-bubble:focus-visible .wa-bubble__label { opacity: 1; transform: none; } }
@media (max-width: 640px) {
  .wa-bubble { right: max(14px, env(safe-area-inset-right)); bottom: max(14px, calc(env(safe-area-inset-bottom) + 10px)); }
  .wa-bubble__icon { width: 56px; height: 56px; }
  .wa-bubble__icon svg { width: 29px; height: 29px; }
  .wa-bubble__label { display: none; }
}
html.menu-open .wa-bubble { opacity: 0; pointer-events: none; }
@keyframes wa-in { from { opacity: 0; transform: translateY(18px) scale(0.85); } }
@media (prefers-reduced-motion: reduce) { .wa-bubble { animation: none; } .wa-bubble__icon, .wa-bubble__label { transition: none; } }
@media print { .wa-bubble { display: none; } }

/* ---------- Dove siamo: appointment request with the calendar ---------- */
.appt-badge { display: inline-flex; align-items: center; gap: 0.55rem; width: fit-content; padding: 0.5rem 0.95rem; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); font-size: 0.86rem; font-weight: 650; letter-spacing: 0.01em; color: var(--ink); }
.appt-badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(232, 87, 42, 0.16); flex: none; }
.booking { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(36px, 5vw, 88px); align-items: start; }
.booking__intro { display: grid; gap: 1.25rem; position: sticky; top: calc(var(--header-h) + 32px); }
.booking__card { background: var(--paper); border: 1px solid var(--line); border-radius: calc(var(--radius) * 1.4); padding: clamp(22px, 4vw, 44px); }
.booking__note { margin-top: 0.9rem; font-size: 0.88rem; color: var(--muted); max-width: 52ch; }
.room-picks { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 0.75rem; }
.room-pick { position: relative; display: block; cursor: pointer; }
.room-pick input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.room-pick__body { display: grid; gap: 0.25rem; height: 100%; padding: 1rem 1.1rem 1.05rem 2.9rem; border: 1px solid rgba(22, 20, 18, 0.22); border-radius: var(--radius); background: #fff; transition: border-color 0.2s, box-shadow 0.2s; }
.room-pick__body::before { content: ""; position: absolute; left: 1.05rem; top: 1.2rem; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid rgba(22, 20, 18, 0.4); background: #fff; transition: border 0.2s; }
.room-pick__city { font-weight: 750; font-size: 1.12rem; letter-spacing: -0.01em; }
.room-pick__addr { font-size: 0.88rem; color: var(--muted); line-height: 1.4; }
.room-pick:hover .room-pick__body { border-color: var(--ink); }
.room-pick input:checked + .room-pick__body { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.room-pick input:checked + .room-pick__body::before { border: 5.5px solid var(--accent); }
.room-pick input:focus-visible + .room-pick__body { outline: 2px solid var(--accent); outline-offset: 2px; }
.cal { border: 1px solid rgba(22, 20, 18, 0.22); border-radius: var(--radius); background: #fff; padding: 0.75rem 0.75rem 0.5rem; }
.cal[aria-invalid="true"] { border-color: #b3261e; }
.cal__head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.35rem; }
.cal__month { font-weight: 700; font-size: 1.02rem; letter-spacing: -0.01em; }
.cal__month::first-letter { text-transform: uppercase; }
.cal__nav { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%; background: transparent; cursor: pointer; transition: background 0.2s, border-color 0.2s; }
.cal__nav svg { width: 18px; height: 18px; }
.cal__nav:hover:not([aria-disabled="true"]) { border-color: var(--ink); }
.cal__nav[aria-disabled="true"] { opacity: 0.3; cursor: default; }
.cal__grid { width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 3px; }
.cal__grid th { padding: 0.25rem 0 0.35rem; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.cal__grid td { padding: 0; text-align: center; }
.cal__day { position: relative; width: 100%; height: clamp(40px, 3.4vw, 46px); border: 0; border-radius: 10px; background: transparent; font-weight: 600; font-size: 0.95rem; font-variant-numeric: tabular-nums; cursor: pointer; transition: background 0.15s, color 0.15s; }
.cal__day:hover:not([aria-disabled="true"]) { background: var(--bg-2); }
.cal__day.is-today::after { content: ""; position: absolute; left: 50%; bottom: 5px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: currentColor; opacity: 0.55; }
.cal__day[aria-disabled="true"] { color: rgba(22, 20, 18, 0.32); cursor: not-allowed; }
.cal__day[aria-label$=", non disponibile"] { text-decoration: line-through; text-decoration-thickness: 1px; }
.cal__day.is-picked { background: var(--ink); color: var(--bg); }
.cal__day:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; z-index: 1; }
.cal__said { min-height: 1.4em; font-size: 0.9rem; color: var(--ink-2); }
@media (max-width: 1023px) {
  .booking { grid-template-columns: minmax(0, 1fr); }
  .booking__intro { position: static; }
}
@media (max-width: 420px) {
  .booking__card { padding: 18px 14px; }
  .cal { padding: 0.5rem 0.35rem 0.35rem; }
  .cal__grid { border-spacing: 2px; }
  .cal__day { height: 40px; font-size: 0.9rem; }
}
@media (prefers-reduced-motion: reduce) { .cal__day, .cal__nav, .room-pick__body, .room-pick__body::before { transition: none; } }

/* ---------- Header: six menu items ----------
   With «Dove siamo» the row (logo + 6 links + CTA) needs ~968 px of content width, a 1052 px window: between the burger
   (≤1023 px) and 1199 px the gaps tighten so the links never wrap (measured: 42 px to spare at 1024 px). */
@media (min-width: 1024px) and (max-width: 1199px) {
  .site-header__in, .nav-wrap, .nav { gap: 1.25rem; }
}

/* ---------- Dove siamo: the showrooms beside the drawn map ----------
   GetLayers «artist-exhibitions» (an index numeral beside a display-face name, hairline rules) as ledger rows, the map
   sticky beside them from 1024 px; below, the map follows the rows (DOM order = visual order). Reading a showroom (hover,
   keyboard focus, #anchor) lifts its pin. */
.page-hero__side { display: grid; gap: 1.1rem; justify-items: start; }
.dove { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr); gap: clamp(40px, 6vw, 104px); align-items: start; }
.dove--solo { grid-template-columns: minmax(0, 1fr); }
.dove__list { border-bottom: 1px solid var(--line); }
.loc { padding: clamp(28px, 3.2vw, 44px) 0 clamp(36px, 4.2vw, 60px); border-top: 1px solid var(--line); scroll-margin-top: calc(var(--header-h) + 16px); transition: border-color 0.4s var(--ease); }
.loc:target { border-top-color: var(--accent); }
.loc__head { display: flex; align-items: baseline; gap: 0.85rem; }
.loc__n { flex: none; font-family: var(--f-serif); font-style: italic; font-size: clamp(1.5rem, 1.9vw, 2rem); line-height: 1; color: var(--accent); }
.loc__city { min-width: 0; font-weight: 800; font-size: clamp(3rem, 4.6vw + 1rem, 6.25rem); line-height: 0.92; letter-spacing: -0.045em; overflow-wrap: anywhere; }
.loc__zone { margin-top: 0.7rem; font-family: var(--f-serif); font-style: italic; font-size: clamp(1.5rem, 1.7vw, 1.75rem); line-height: 1.2; color: var(--accent-2); }
.loc__addr { margin-top: clamp(20px, 2.2vw, 30px); font-style: normal; font-size: clamp(1.1rem, 1.25vw, 1.28rem); font-weight: 600; line-height: 1.45; letter-spacing: -0.01em; }
.loc__addr span { display: block; }
.loc__addr span + span { font-weight: 400; color: var(--muted); }
.loc__note { display: flex; align-items: baseline; gap: 0.65rem; margin-top: 1.1rem; font-weight: 650; font-size: 0.98rem; line-height: 1.5; color: var(--ink); }
.loc__note::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(232, 87, 42, 0.16); transform: translateY(-0.1em); }
.loc .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 34rem; margin-top: 1.4rem; padding-top: 0; border-top: 0; }
.loc .facts a { text-decoration: none; border-bottom: 1px solid currentColor; }
.loc__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.4rem; margin-top: clamp(24px, 2.6vw, 34px); }
.loc__actions .btn { min-height: 48px; }
.loc__actions .btn svg { width: 1.15em; height: 1.15em; flex: none; fill: currentColor; }
.loc__alt { margin-top: 1rem; }
.loc__alt a { position: relative; }
@media (pointer: coarse) { .loc__alt a::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 2.75rem; transform: translateY(-50%); } }
.dove__map { position: sticky; top: calc(var(--header-h) + 24px); margin: 0; }
/* The drawn map (inline SVG, its own colours through --map-*, fallbacks to the site's tokens). The labels are sized in
   the map's own units, so on a wide column they are trimmed and on a narrow one the country names step aside. */
.dove-map { border-radius: calc(var(--radius) * 1.4); overflow: hidden; background: #d8e1de; box-shadow: 0 0 0 1px var(--line); container-type: inline-size; }
.dove-map .dsm-mark { transform-origin: 0 0; }
@media (prefers-reduced-motion: no-preference) { .dove-map .dsm-mark { transition: transform 0.35s var(--ease); } }
@container (min-width: 720px) { .dove-map .dsm-label { font-size: 28px; } .dove-map .dsm-mark { transform: scale(0.88); } }
@container (max-width: 380px) { .dove-map .dsm-ctx { display: none; } }
.dove:has(#alassio:is(:hover, :focus-within, :target)) .dsm-mark--alassio,
.dove:has(#milano:is(:hover, :focus-within, :target)) .dsm-mark--milano { transform: scale(1.18); }
.map__cap { margin-top: 0.9rem; max-width: 46ch; font-size: 0.88rem; line-height: 1.5; color: var(--muted); }
@media (max-width: 1023px) {
  .dove { grid-template-columns: minmax(0, 1fr); }
  .dove__map { position: static; }
}
@media (min-width: 641px) and (max-width: 1023px) {
  .dove__map { display: grid; grid-template-columns: minmax(0, 36rem) minmax(11rem, 1fr); gap: 1.5rem; align-items: end; }
  .map__cap { margin-top: 0; }
}
@media (max-width: 640px) {
  .loc__actions { gap: 0.6rem; }
  .loc__actions .btn { flex: 1 1 100%; white-space: normal; }
  .loc .facts { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- Showroom links in the footer and the contact panel: town over street, 44 px tall ---------- */
.places { display: grid; gap: 0.2rem; }
.places a { display: grid; align-content: center; min-height: 44px; line-height: 1.3; text-decoration: none; }
.places b { font-weight: 600; }
.places span { font-size: 0.9rem; font-weight: 400; color: var(--stone-2); }
.places a:hover b, .places a:hover span { color: var(--accent); }
.panel__facts .places { margin-top: 0.15rem; }
.panel__facts .places b { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.places .places__note, .footer__appt { font-size: 0.85rem; color: var(--stone-2); }
.footer__appt { margin-top: 0.1rem; }

/* Windows contrast themes: the chosen day and time keep a visible state, days that cannot be booked look unavailable. */
@media (forced-colors: active) {
  .cal__day.is-picked, .chip input:checked + span { forced-color-adjust: none; background: Highlight; color: HighlightText; }
  .cal__day[aria-disabled="true"] { color: GrayText; }
}
