/* =========================================================
   BS4YC – prezentační web
   Paleta: vápenec, grafit, mosaz. Typo: Cormorant Garamond + Manrope
   ========================================================= */

/* ---------- Fonty (self-hosted, latin + latin-ext pro češtinu) ---------- */
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 300; font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-ext-300-normal.woff2") 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-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 300; font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-300-normal.woff2") 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: "Cormorant Garamond"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-ext-400-normal.woff2") 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-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-400-normal.woff2") 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: "Cormorant Garamond"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-ext-500-normal.woff2") 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-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-500-normal.woff2") 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: "Manrope"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/manrope-latin-ext-400-normal.woff2") 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-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/manrope-latin-400-normal.woff2") 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: "Manrope"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/manrope-latin-ext-500-normal.woff2") 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-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/manrope-latin-500-normal.woff2") 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: "Manrope"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("../fonts/manrope-latin-ext-600-normal.woff2") 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-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("../fonts/manrope-latin-600-normal.woff2") 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; }

/* ---------- Tokeny ---------- */
:root {
  --stone: #F5F5F2;      /* pozadí – světlý vápenec */
  --paper: #FFFFFF;      /* střídavé sekce */
  --ink: #1D2328;        /* grafit – text */
  --ink-2: #555D64;      /* sekundární text */
  --line: #DEDFDA;       /* linky */
  --brass: #7A5630;      /* bronz – akcent, sytější a hlubší (kontrast 6,9:1 na bílé) */
  --brass-soft: #BA9B6E; /* bronz – linky, hover */
  --slot: #E8E9E4;       /* místo pro fotografii */

  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;

  --wrap: 1200px;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --section: clamp(4.5rem, 9vw, 7.5rem);
  --header-h: 68px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);    /* dlouhý, měkký dojezd */
  --ease-io: cubic-bezier(.65, 0, .35, 1);   /* plynulý rozjezd i dojezd */
}

/* ---------- Základ ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  /* plynulé scrollování řeší JS (pomalejší a jemnější než nativní) */
  scroll-padding-top: calc(var(--header-h) + 8px);
  -webkit-text-size-adjust: 100%;
  scrollbar-gutter: stable; /* intro: layout se nehne, když se scrollbar vrátí */
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--stone);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15.5px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
main { flex: 1 0 auto; }

img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
dl, dd { margin: 0; }
address { font-style: normal; }

::selection { background: var(--brass-soft); color: var(--ink); }

:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; border-radius: 2px; }

/* Custom scrollbar */
html { scrollbar-width: thin; scrollbar-color: #B9BAB4 var(--stone); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--stone); }
::-webkit-scrollbar-thumb { background: #C4C5BF; border-radius: 10px; border: 3px solid var(--stone); }
::-webkit-scrollbar-thumb:hover { background: var(--brass-soft); }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: 1rem; top: -3rem; z-index: 100;
  background: var(--ink); color: var(--paper); padding: .5rem 1rem; text-decoration: none;
}
.skip-link:focus { top: 1rem; }

/* ---------- Tlačítka ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px; padding: .7rem 1.4rem;
  font: 500 .875rem/1 var(--sans); letter-spacing: .01em;
  text-decoration: none; border: 1px solid transparent; border-radius: 2px;
  transition: background-color .6s var(--ease-out), color .6s var(--ease-out), border-color .6s var(--ease-out);
}
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: var(--brass); }
.btn-ghost { border-color: var(--ink); color: var(--ink); }
.btn-ghost:hover { border-color: var(--brass); color: var(--brass); }
.btn:active { transform: translateY(1px); }

/* ---------- Hlavička ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  height: var(--header-h);
  background: transparent;
  transition: background-color .8s var(--ease-out), box-shadow .8s var(--ease-out), opacity 1.4s var(--ease-out) .9s;
}
.site-header.is-scrolled {
  background: rgba(245, 245, 242, .92);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  box-shadow: 0 1px 0 var(--line);
}
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 2rem; }

.brand { display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; }
.brand-mark { width: 26px; height: 26px; fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: square; }
.brand-name { font: 500 1.35rem/1 var(--serif); letter-spacing: .14em; }

.site-nav ul { display: flex; align-items: center; gap: clamp(1rem, 2.2vw, 2rem); }
.site-nav a {
  font-size: .84rem; font-weight: 500; text-decoration: none; color: var(--ink-2);
  padding-block: .4rem; position: relative; transition: color .5s var(--ease-out);
}
.site-nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: var(--brass); transform: scaleX(0); transform-origin: right; transition: transform .7s var(--ease-out);
}
.site-nav a:hover, .site-nav a.is-current { color: var(--ink); }
.site-nav a:hover::after, .site-nav a.is-current::after { transform: scaleX(1); transform-origin: left; }
.site-nav a.nav-cta { color: var(--ink); border: 1px solid var(--ink); padding: .45rem 1rem; border-radius: 2px; }
.site-nav a.nav-cta::after { display: none; }
.site-nav a.nav-cta:hover { border-color: var(--brass); color: var(--brass); }

.nav-toggle { display: none; }

@media (max-width: 900px) {
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px; background: none; border: 0; cursor: pointer; margin-right: -10px;
  }
  .nav-toggle-lines, .nav-toggle-lines::before, .nav-toggle-lines::after {
    display: block; width: 22px; height: 1.5px; background: var(--ink); position: relative;
    transition: transform .5s var(--ease-out), background-color .3s;
  }
  .nav-toggle-lines::before, .nav-toggle-lines::after { content: ""; position: absolute; left: 0; }
  .nav-toggle-lines::before { top: -7px; }
  .nav-toggle-lines::after { top: 7px; }
  .nav-toggle[aria-expanded="true"] .nav-toggle-lines { background: transparent; }
  .nav-toggle[aria-expanded="true"] .nav-toggle-lines::before { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .nav-toggle-lines::after { transform: translateY(-7px) rotate(-45deg); }

  .site-nav {
    position: fixed; inset: var(--header-h) 0 auto 0;
    background: var(--stone); border-bottom: 1px solid var(--line);
    padding: 1rem var(--gutter) 2rem;
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity .6s var(--ease-out), transform .6s var(--ease-out), visibility .6s;
  }
  .site-nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .site-nav ul { flex-direction: column; align-items: stretch; gap: 0; }
  .site-nav li + li { border-top: 1px solid var(--line); }
  .site-nav a { display: block; padding: .95rem 0; font-size: 1rem; }
  .site-nav a::after { display: none; }
  .site-nav a.nav-cta { border: 0; padding: .95rem 0; color: var(--brass); }
  .site-header.menu-open { background: var(--stone); box-shadow: 0 1px 0 var(--line); }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  padding: calc(var(--header-h) + 3rem) 0 3rem;
  overflow: hidden;
}
.hero-inner {
  position: relative;
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  gap: clamp(2rem, 6vw, 6rem); align-items: center;
}
/* logo + nápis v jedné řadě: domky stojí na stejné základně jako písmena */
.hero-brand {
  display: flex; align-items: baseline; gap: .26em;
  font-size: clamp(3.4rem, 8vw, 6.25rem); /* = velikost nadpisu, logo se měří v em */
}
.hero-mark {
  flex: none; width: .9em; height: .9em;
  margin-bottom: -.075em; /* čára terénu (y 44 ze 48) přesně na účaří písma */
  fill: none; stroke: var(--brass); stroke-width: 1.1; stroke-linecap: square;
}
.hero-mark path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 2.4s var(--ease-io) forwards; }
.hero-mark path:nth-child(2) { animation-delay: .35s; }
.hero-mark path:nth-child(3) { animation-delay: .6s; }
.hero-mark path:nth-child(4) { animation-delay: .85s; }
.hero-mark path:nth-child(5) { animation-delay: 1.5s; animation-duration: 1.6s; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.hero-title {
  font: 300 1em/.95 var(--serif);
  letter-spacing: .12em;
}
.hero-sub {
  margin-top: 1rem;
  font: 400 clamp(1.15rem, 1.8vw, 1.4rem)/1.3 var(--serif);
  color: var(--brass);
  letter-spacing: .02em;
}
.hero-lead { margin-top: 1.75rem; max-width: 34rem; color: var(--ink-2); font-size: 1rem; }
.hero-actions { margin-top: 2.25rem; display: flex; flex-wrap: wrap; gap: .75rem; }

.hero-text > * { opacity: 0; transform: translateY(22px); animation: rise 1.8s var(--ease-out) forwards; }
.hero-text > .hero-brand { opacity: 1; transform: none; animation: none; }
.hero-brand .hero-title { opacity: 0; transform: translateX(-14px); animation: rise 1.8s var(--ease-out) forwards; }
.hero-title { animation-delay: .6s !important; }
.hero-sub { animation-delay: .85s !important; }
.hero-lead { animation-delay: 1.05s !important; }
.hero-actions { animation-delay: 1.25s !important; }
@keyframes rise { to { opacity: 1; transform: none; } }

.hero-figure { margin: 0; position: relative; }
.hero-figure::before {
  content: ""; position: absolute; inset: 1.25rem -1.25rem -1.25rem 1.25rem;
  border: 1px solid var(--brass-soft); pointer-events: none;
}
.hero-figure .img-slot { position: relative; animation: unveil 2.2s var(--ease-io) .5s both; }
.hero-figure .img-slot img { animation: settle 3.2s var(--ease-out) .5s both; }
.hero-figure::before { animation: frameIn 2.4s var(--ease-out) 1.3s both; }
@keyframes unveil { from { clip-path: inset(100% 0 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes settle { from { transform: scale(1.14); } to { transform: scale(1); } }
/* výkres kolem fotky – vlasové linky, objeví se po odkrytí fotky */
.hero-plan {
  position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none;
  fill: none; opacity: 0; animation: fadeIn 1.6s var(--ease-out) 2.2s forwards;
}
.plan-parcel { stroke: var(--ink); stroke-opacity: .2; stroke-width: .65; stroke-dasharray: 10 3 1.5 3; }
.plan-dim path { stroke: var(--brass); stroke-opacity: .6; stroke-width: .65; }
/* kóta se „dokreslí“: čára se natáhne od středu, pak zarážky a vynášecí čáry */
.hero-plan { --plan-d: 2.2s; }
.plan-line { transform-box: fill-box; transform-origin: center; animation: dimX 1.6s var(--ease-io) calc(var(--plan-d) + .2s) both; }
.plan-dim--side .plan-line { animation-name: dimY; animation-delay: calc(var(--plan-d) + .5s); }
.plan-ext, .plan-tick, .hero-plan text { animation: fadeIn 1.2s var(--ease-out) calc(var(--plan-d) + 1.1s) both; }
.plan-dim--side .plan-ext, .plan-dim--side .plan-tick, .plan-dim--side text { animation-delay: calc(var(--plan-d) + 1.4s); }
.plan-ext, .plan-tick, .hero-plan text { opacity: 0; }
@keyframes dimX { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes dimY { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.hero-plan text {
  fill: var(--brass); stroke: none;
  font: 500 6.5px/1 var(--sans); letter-spacing: .14em; text-anchor: middle;
}
.hero-plan .plan-label { fill: var(--ink-2); opacity: .7; letter-spacing: .08em; }
@keyframes frameIn { from { opacity: 0; transform: translate(-1.25rem, -1.25rem); } to { opacity: 1; transform: none; } }

.hero-facts {
  position: relative;
  margin-top: clamp(3rem, 7vw, 5rem);
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
}
.hero-facts > div { padding: 1.25rem 1.5rem 0 0; }
.hero-facts > div + div { padding-left: 1.5rem; border-left: 1px solid var(--line); }
.hero-facts dt { font-size: .78rem; color: var(--ink-2); }
.hero-facts dd { font: 400 1.5rem/1.3 var(--serif); margin-top: .2rem; }

@media (max-width: 900px) {
  .hero { min-height: auto; padding-top: calc(var(--header-h) + 2.5rem); }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-figure { margin-right: 1.25rem; }
  .plan-parcel, .plan-label, .plan-dim--side { display: none; }
  .hero-inner { gap: 3.25rem; } /* místo pro kótu nad fotkou */
  .hero-plan text { font-size: 8px; }
  .hero-facts { grid-template-columns: repeat(2, 1fr); }
  .hero-facts > div:nth-child(3) { padding-left: 0; border-left: 0; }
  .hero-facts > div:nth-child(n+3) { margin-top: 1.25rem; }
}

/* ---------- Místa pro fotografie ---------- */
/* Pokud fotka na FTP ještě není, JS přidá .is-missing a ukáže očekávanou cestu */
.img-slot {
  position: relative; overflow: hidden; background: var(--slot);
  aspect-ratio: 4 / 3;
}
.img-slot--tall { aspect-ratio: 3 / 4; }
.img-slot--wide { aspect-ratio: 3 / 2; }
.img-slot img { width: 100%; height: 100%; object-fit: cover; }
.img-slot.is-missing img { visibility: hidden; }
.img-slot.is-missing::after {
  content: "Fotografie: " attr(data-path);
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  padding: 1rem; text-align: center;
  font-size: .78rem; color: #8A8F93; letter-spacing: .01em;
  background:
    linear-gradient(135deg, transparent calc(50% - .5px), rgba(29,35,40,.08) 50%, transparent calc(50% + .5px)),
    linear-gradient(45deg, transparent calc(50% - .5px), rgba(29,35,40,.08) 50%, transparent calc(50% + .5px)),
    var(--slot);
}

/* ---------- Sekce ---------- */
.section { padding-block: var(--section); }
.section--paper { background: var(--paper); }

h2 {
  font: 300 clamp(2.1rem, 3.6vw, 2.9rem)/1.1 var(--serif);
  letter-spacing: .01em;
}
h3 { font: 600 .95rem/1.4 var(--sans); }

.split { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(2rem, 5vw, 5rem); }
.split-head { align-self: start; position: sticky; top: calc(var(--header-h) + 2rem); }
/* číslo sekce jako legenda výkresu: 01 ——— */
.split-head[data-num]::before {
  content: attr(data-num);
  content: attr(data-num) / "";
  display: inline-block; margin-bottom: 1.1rem; padding-right: 3.25rem;
  font: 600 .72rem/1 var(--sans); letter-spacing: .2em; color: var(--brass);
  background: linear-gradient(var(--brass-soft), var(--brass-soft)) right center / 2.4rem 1px no-repeat;
}
.split-lead { margin-top: 1rem; color: var(--ink-2); max-width: 18rem; font: 400 1.15rem/1.45 var(--serif); }
.split-body { min-width: 0; }

@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; gap: 2rem; }
  .split-head { position: static; }
}

.prose { max-width: 40rem; }
.prose p + p { margin-top: 1rem; }
.prose p { color: var(--ink-2); }
.prose p:first-child { color: var(--ink); font-size: 1.05rem; }

.sub-title { margin: 3.5rem 0 1.25rem; font: 400 1.5rem/1.2 var(--serif); }

/* O nás */
.about-figure { margin: 3rem 0 0; }
.values { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem 2.5rem; }
.values h4 { font: 600 .95rem/1.4 var(--sans); }
.values li { border-top: 1px solid var(--ink); padding-top: 1rem; }
.values p { margin-top: .4rem; color: var(--ink-2); font-size: .92rem; }
@media (max-width: 700px) { .values { grid-template-columns: 1fr; gap: 1.5rem; } }

.motto {
  margin: 3rem 0 0; padding: .25rem 0 .25rem 1.5rem; border-left: 1px solid var(--brass);
}
.motto p { font: 300 clamp(1.5rem, 2.4vw, 1.9rem)/1.3 var(--serif); max-width: 32rem; }

/* Činnosti */
.services li {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 1.5rem;
  padding: 1.5rem 0; border-top: 1px solid var(--line);
}
.services li:last-child { border-bottom: 1px solid var(--line); }
.services h3 { font: 400 1.4rem/1.25 var(--serif); }
.services p { color: var(--ink-2); }
.services p + p { margin-top: .75rem; }
@media (max-width: 600px) { .services li { grid-template-columns: 1fr; gap: .4rem; } }

/* ---------- Projekty ---------- */
.section-head {
  display: flex; align-items: end; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap;
  margin-bottom: 2.5rem;
}
.projects-intro { margin-bottom: 3rem; }
.projects-intro .split-head { position: static; }
.filters { display: flex; flex-wrap: wrap; gap: .25rem; margin-bottom: 2rem; }
.filter {
  font: 500 .82rem/1 var(--sans); color: var(--ink-2);
  background: none; border: 1px solid transparent; border-radius: 2px;
  padding: .6rem .9rem; cursor: pointer; min-height: 38px;
  transition: color .5s var(--ease-out), border-color .5s var(--ease-out);
}
.filter:hover { color: var(--ink); }
.filter.is-active { color: var(--ink); border-color: var(--ink); }

.projects { display: grid; grid-template-columns: repeat(12, 1fr); gap: clamp(1.25rem, 2.5vw, 2rem); }
.project { grid-column: span 4; }
.project.is-featured { grid-column: span 8; grid-row: span 2; }
.project.is-hidden { display: none; }
.projects { transition: opacity .45s var(--ease-io); }
.projects.is-switching { opacity: 0; }
@media (max-width: 1000px) {
  .project { grid-column: span 6; }
  .project.is-featured { grid-column: span 12; grid-row: auto; }
}
@media (max-width: 600px) { .project, .project.is-featured { grid-column: span 12; } }

.project-btn {
  display: block; width: 100%; text-align: left; padding: 0; border: 0; background: none;
  color: inherit; font: inherit; cursor: pointer;
}
.project .img-slot img { transition: transform 1.8s var(--ease-out), opacity .6s; }
.project-btn:hover .img-slot img { transform: scale(1.03); }
.project.is-featured .img-slot { aspect-ratio: 16 / 11; }

.project-info { padding-top: 1rem; display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; }
.project-name { font: 400 1.35rem/1.25 var(--serif); }
.project.is-featured .project-name { font-size: 1.7rem; }
.project-place { font-size: .85rem; color: var(--ink-2); margin-top: .15rem; }
.project-status {
  flex: none; font-size: .75rem; font-weight: 500; color: var(--ink-2);
  padding: .25rem .55rem; border: 1px solid var(--line); border-radius: 2px; white-space: nowrap;
}
.project-status[data-stav="Ve výstavbě"] { color: var(--brass); border-color: var(--brass-soft); }
.project-status[data-stav="Připravujeme"] { color: var(--ink); border-style: dashed; border-color: #B9BAB4; }

/* ---------- Firemní údaje (kontakt) ---------- */
.company-data { margin-top: 2.5rem; max-width: 40rem; }
.company-data a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--brass-soft); }
.company-data a:hover { color: var(--brass); }
.company-data > div { display: grid; grid-template-columns: 11rem 1fr; gap: 1rem; padding: .85rem 0; border-top: 1px solid var(--line); }
.company-data dt { color: var(--ink-2); font-size: .86rem; }
.company-data dd { font-size: .92rem; font-weight: 500; }
.company-data > div:last-child { border-bottom: 1px solid var(--line); }
@media (max-width: 480px) { .company-data > div { grid-template-columns: 1fr; gap: .1rem; } }

/* ---------- Patička ---------- */
.site-footer { flex-shrink: 0; background: var(--ink); color: #B8BDC1; padding: 2.25rem 0; font-size: .82rem; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem 2rem; flex-wrap: wrap; }
.footer-brand { display: inline-flex; align-items: center; gap: .6rem; color: var(--paper); font: 500 1.05rem/1 var(--serif); letter-spacing: .08em; }
.footer-brand .brand-mark { stroke: var(--brass-soft); width: 22px; height: 22px; }

/* razítko výkresu */
.site-footer:has(.stamp) { padding: 2.5rem 0 3rem; }
.stamp {
  display: grid; grid-template-columns: 1.5fr 1.3fr 1fr .8fr;
  border: 1px solid rgba(255, 255, 255, .28);
}
.stamp > div {
  padding: .85rem 1.1rem .9rem;
  border-right: 1px solid rgba(255, 255, 255, .12);
  border-bottom: 1px solid rgba(255, 255, 255, .12);
  min-width: 0;
}
.stamp > div:nth-child(4), .stamp > div:nth-child(7) { border-right: 0; }
.stamp > div:nth-child(n+5) { border-bottom: 0; }
.stamp-brand {
  grid-row: span 2;
  display: flex; align-items: center; gap: .8rem;
  color: var(--paper); font: 500 1.35rem/1 var(--serif); letter-spacing: .08em;
  border-bottom: 0 !important; border-right-color: rgba(255, 255, 255, .28) !important;
}
.stamp-brand .brand-mark { flex: none; width: 34px; height: 34px; fill: none; stroke: var(--brass-soft); stroke-width: 1.4; }
.stamp dt { font-size: .64rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: #868D93; }
.stamp dd { margin-top: .35rem; color: #DADDDF; font-size: .84rem; }
@media (max-width: 700px) {
  .stamp { grid-template-columns: 1fr 1fr; }
  .stamp-brand { grid-row: auto; grid-column: 1 / -1; padding-block: 1.1rem !important; border-right: 0 !important; border-bottom: 1px solid rgba(255, 255, 255, .28) !important; }
  .stamp > div, .stamp > div:nth-child(n+5) { border-bottom: 1px solid rgba(255, 255, 255, .12); border-right: 0; }
  .stamp > div:nth-child(even) { border-right: 1px solid rgba(255, 255, 255, .12); }
  .stamp > div:nth-child(n+6) { border-bottom: 0; }
  .stamp > div:nth-child(4) { border-right: 1px solid rgba(255, 255, 255, .12); }
}

/* ---------- Šipka nahoru ---------- */
.to-top {
  position: fixed; right: clamp(1rem, 3vw, 2rem); bottom: clamp(1rem, 3vw, 2rem); z-index: 40;
  width: 46px; height: 46px; display: grid; place-items: center;
  background: var(--paper); border: 1px solid var(--line); border-radius: 50%;
  box-shadow: 0 6px 20px rgba(29, 35, 40, .08);
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity .9s var(--ease-out), transform .9s var(--ease-out), visibility .9s, border-color .5s;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { border-color: var(--brass-soft); }
.to-top svg { width: 18px; height: 18px; fill: none; stroke: var(--ink); stroke-width: 1.5; }

/* ---------- Galerie (lightbox) ---------- */
.lightbox {
  width: min(1100px, 100vw - 2rem); max-height: calc(100vh - 2rem);
  padding: 0; border: 0; background: var(--paper); color: var(--ink);
  overflow: auto;
}
.lightbox::backdrop { background: rgba(29, 35, 40, .72); backdrop-filter: blur(4px); }
.lightbox[open] { animation: lbIn .9s var(--ease-out); }
.lightbox[open]::backdrop { animation: lbFade .9s var(--ease-out); }
@keyframes lbIn { from { opacity: 0; transform: translateY(24px) scale(.985); } }
@keyframes lbFade { from { opacity: 0; } }
.lightbox.is-closing { animation: lbOut .45s var(--ease-io) forwards; }
.lightbox.is-closing::backdrop { animation: lbFadeOut .45s var(--ease-io) forwards; }
@keyframes lbOut { to { opacity: 0; transform: translateY(16px) scale(.99); } }
@keyframes lbFadeOut { to { opacity: 0; } }
#lb-img { transition: opacity .6s var(--ease-out); }
#lb-img.is-fading { opacity: 0; }
.lb-inner { padding: clamp(1rem, 3vw, 1.75rem); }
.lb-head { display: flex; justify-content: space-between; align-items: start; gap: 1rem; margin-bottom: 1rem; }
.lb-head h3 { font: 400 1.8rem/1.15 var(--serif); }
.lb-meta { color: var(--ink-2); font-size: .86rem; margin-top: .2rem; }
.lb-close, .lb-nav {
  width: 44px; height: 44px; display: grid; place-items: center; flex: none;
  background: var(--paper); border: 1px solid var(--line); border-radius: 50%; cursor: pointer;
  transition: border-color .5s var(--ease-out);
}
.lb-close:hover, .lb-nav:hover { border-color: var(--brass-soft); }
.lb-close svg, .lb-nav svg { width: 18px; height: 18px; fill: none; stroke: var(--ink); stroke-width: 1.5; }
.lb-stage { position: relative; }
.lb-slot { aspect-ratio: auto; height: min(62vh, 620px); }
.lb-slot img { object-fit: contain; background: var(--slot); }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; }
.lb-prev { left: .75rem; }
.lb-next { right: .75rem; }
.lb-nav[hidden] { display: none; }
.lb-foot { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 1rem 2rem; margin-top: 1.25rem; }
.lb-desc { color: var(--ink-2); }
.lb-params > div { display: flex; justify-content: space-between; gap: 1rem; padding: .45rem 0; border-top: 1px solid var(--line); font-size: .88rem; }
.lb-params dt { color: var(--ink-2); }
.lb-params dd { font-weight: 500; text-align: right; }
.lb-count { grid-column: 1 / -1; font-size: .8rem; color: var(--ink-2); }
@media (max-width: 700px) { .lb-foot { grid-template-columns: 1fr; } }

/* ---------- Intro: logo přes celou obrazovku → po scrollu odletí na místo ---------- */
.intro { display: none; }
html.intro-pending, html.intro-pending body { overflow: hidden; }
html.intro-pending .intro, html.intro-playing .intro { display: block; position: fixed; inset: 0; z-index: 200; }
html.intro-playing .intro { pointer-events: none; }

.intro-bg {
  position: absolute; inset: 0;
  background: var(--stone);
  transition: opacity 1.6s var(--ease-io) .25s;
}
html.intro-playing .intro-bg { opacity: 0; }

.intro-center {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: clamp(1.75rem, 3.5vh, 2.75rem);
  padding-bottom: 6vh; /* opticky trochu nad středem, ať je místo pro nápovědu */
}
.intro-mark {
  width: clamp(168px, 24vw, 300px); height: clamp(168px, 24vw, 300px);
  fill: none; stroke: var(--brass); stroke-width: .4; stroke-linecap: square; /* JS dopočítá pevnou tloušťku v px (INTRO_STROKE_PX) */
  transform-origin: 0 0;
  transition: transform 1.8s var(--ease-io), stroke-width 1.8s var(--ease-io);
  will-change: transform;
}
.intro-mark path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 2.8s var(--ease-io) .3s forwards; }
.intro-mark path:nth-child(2) { animation-delay: .7s; }
.intro-mark path:nth-child(3) { animation-delay: 1s; }
.intro-mark path:nth-child(4) { animation-delay: 1.3s; }
.intro-mark path:nth-child(5) { animation-delay: 2.1s; animation-duration: 1.8s; }

.intro-word {
  font: 400 clamp(1.5rem, 2.6vw, 2.25rem)/1 var(--serif);
  letter-spacing: .5em; margin-right: -.5em; /* vyrovnání prostrkání */
  color: var(--ink);
  opacity: 0; transform: translateY(12px);
  animation: rise 2s var(--ease-out) 2.4s forwards;
  transition: opacity .7s var(--ease-io), transform .9s var(--ease-io);
}
.intro-hint {
  position: absolute; left: 50%; bottom: clamp(2rem, 7vh, 4rem); transform: translateX(-50%);
  opacity: 0; animation: fadeIn 1.6s var(--ease-out) 3s forwards;
  transition: opacity .6s var(--ease-io);
}
/* plovoucí šipka dolů */
.intro-chevron {
  display: block; width: 28px; height: 14px;
  fill: none; stroke: var(--brass); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round;
  animation: hintBob 2.4s var(--ease-io) infinite;
}
@keyframes hintBob { 0%, 100% { transform: translateY(-4px); opacity: .5; } 50% { transform: translateY(8px); opacity: 1; } }
@keyframes fadeIn { to { opacity: 1; } }

/* přechod: slovo a nápověda zmizí, pozadí se rozplyne, logo letí */
html.intro-playing .intro-word { animation: none; opacity: 0; transform: translateY(-8px); }
html.intro-playing .intro-hint { animation: none; opacity: 0; }

/* hero čeká, dokud intro neodstartuje */
html.intro-pending .site-header { opacity: 0; }
html.intro-pending .hero-text > *,
html.intro-pending .hero-figure .img-slot,
html.intro-pending .hero-figure .img-slot img,
html.intro-pending .hero-figure::before,
html.intro-pending .hero-brand .hero-title,
html.intro-pending .hero-plan, html.intro-pending .hero-plan * { animation-play-state: paused; }
/* po intru se hero vynoří až ve chvíli, kdy logo dosedá */
html.from-intro .hero-title { animation-delay: 1.2s !important; }
html.from-intro .hero-sub { animation-delay: 1.4s !important; }
html.from-intro .hero-lead { animation-delay: 1.6s !important; }
html.from-intro .hero-actions { animation-delay: 1.8s !important; }
html.from-intro .hero-figure .img-slot,
html.from-intro .hero-figure .img-slot img { animation-delay: .9s; }
html.from-intro .hero-figure::before { animation-delay: 1.9s; }
html.from-intro .hero-plan { animation-delay: 2.6s; --plan-d: 2.6s; }
html.from-intro .site-header { transition-delay: 0s, 0s, 1.6s; }
/* logo v hero se nekreslí znovu – přiletí z intra */
html.intro-playing .hero-mark { opacity: 0; }
html.intro-playing .hero-mark path, html.intro-done .hero-mark path { animation: none; stroke-dashoffset: 0; }

/* ---------- Postupné odkrývání při scrollu (třídy přidává JS) ---------- */
.reveal {
  opacity: 0; transform: translateY(32px);
  transition: opacity 1.6s var(--ease-out), transform 1.6s var(--ease-out);
  transition-delay: var(--d, 0s);
}
.reveal.is-in { opacity: 1; transform: none; }

/* Fotky se odkrývají „oponou“ zdola a jemně dosednou */
.reveal-img { clip-path: inset(100% 0 0 0); transition: clip-path 1.9s var(--ease-io); transition-delay: var(--d, 0s); }
.reveal-img img { transform: scale(1.12); transition: transform 2.8s var(--ease-out); transition-delay: var(--d, 0s); }
.reveal-img.is-in { clip-path: inset(0 0 0 0); }
.reveal-img.is-in img { transform: scale(1); }

/* ---------- Omezený pohyb ---------- */
@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal-img, .reveal-img img { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
}
