/* ==========================================================
   Stara Piekarnia — portal inwestycji
   Styl deweloperski: grotesk, siatka, dane na pierwszym planie.
   Paleta z wizualizacji: grafit, piaskowa elewacja, zieleń dachu.
   ========================================================== */

:root {
  --bg: #f5f4f1;
  --tint: #ebe8e2;
  --white: #ffffff;
  --ink: #16181b;
  --ink-2: #3b3f44;
  --muted: #6d7177;
  --graphite: #1e2125;
  --graphite-2: #2a2e33;
  --sand: #b08a5c;
  --sand-dark: #8f6d44;
  --sand-soft: #e9dfd0;
  --green: #4f7a4a;
  --amber: #b9862b;
  --red: #a4513f;
  --line: #d9d6cf;
  --line-dark: rgba(255, 255, 255, 0.14);

  --display: "Inter Tight", "Inter", system-ui, sans-serif;
  --sans: "Inter", system-ui, -apple-system, sans-serif;

  --container: 1280px;
  --gutter: clamp(16px, 4vw, 48px);
  --section-y: clamp(72px, 9vw, 120px);
  --radius: 4px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--sans); font-size: 16px; line-height: 1.65;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; cursor: pointer; color: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

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

/* ---------- Typografia ---------- */
h1, h2, h3 { font-family: var(--display); font-weight: 500; letter-spacing: -0.025em; line-height: 1.08; margin: 0 0 .6em; }
h1 { font-size: clamp(2.3rem, 5vw, 4.2rem); font-weight: 400; }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.9rem); font-weight: 400; max-width: 18em; }
h3 { font-size: 1.2rem; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
.overline {
  font-family: var(--display); font-size: .78rem; font-weight: 500; letter-spacing: .08em; text-transform: uppercase;
  color: var(--sand-dark); margin-bottom: 1.2rem;
}
.section--dark .overline { color: var(--sand); }
.text { color: var(--ink-2); font-size: 1.05rem; max-width: 36em; }
.text--light { color: rgba(255,255,255,.7); }
.note { font-size: .82rem; color: var(--muted); margin: 1.5rem 0 0; }

/* ---------- Przyciski ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6em;
  padding: .95em 1.6em; border-radius: var(--radius); border: 1px solid var(--sand);
  background: var(--sand); color: #fff; text-decoration: none; font-weight: 500; font-size: .92rem;
  transition: background .2s, border-color .2s, color .2s;
}
.btn::after { content: "→"; transition: transform .25s var(--ease); }
.btn:hover { background: var(--sand-dark); border-color: var(--sand-dark); }
.btn:hover::after { transform: translateX(3px); }
.btn--outline-light { background: transparent; border-color: rgba(255,255,255,.4); }
.btn--outline-light:hover { background: #fff; color: var(--ink); border-color: #fff; }
.btn--sm { padding: .6em 1.1em; font-size: .85rem; }
.btn--sm::after { display: none; }
.btn--full { width: 100%; }

/* ---------- Nawigacja ---------- */
.nav { position: fixed; inset: 0 0 auto; z-index: 50; color: #fff; transition: background .3s, color .3s, box-shadow .3s; }
.nav.is-scrolled, .nav.is-open { background: rgba(255,255,255,.96); color: var(--ink); box-shadow: 0 1px 0 var(--line); backdrop-filter: blur(10px); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem; height: 76px; }
.nav__logo { display: flex; align-items: center; gap: .75rem; text-decoration: none; }
.nav__logo svg { width: 30px; height: 30px; color: var(--sand); flex: none; }
.nav__logo span { display: flex; flex-direction: column; font-family: var(--display); font-weight: 600; font-size: 1.05rem; line-height: 1.15; letter-spacing: -0.01em; }
.nav__logo small { font-family: var(--sans); font-weight: 400; font-size: .72rem; letter-spacing: 0; opacity: .65; }
.nav__menu { display: flex; align-items: center; gap: 1.8rem; }
.nav__menu a:not(.btn) { text-decoration: none; font-size: .9rem; font-weight: 500; opacity: .85; }
.nav__menu a:not(.btn):hover { opacity: 1; color: var(--sand); }
.nav__toggle { display: none; background: none; border: 0; width: 40px; height: 40px; position: relative; }
.nav__toggle span { position: absolute; left: 9px; right: 9px; height: 2px; background: currentColor; transition: transform .25s; }
.nav__toggle span:first-child { top: 15px; }
.nav__toggle span:last-child { top: 23px; }
.nav.is-open .nav__toggle span:first-child { transform: translateY(4px) rotate(45deg); }
.nav.is-open .nav__toggle span:last-child { transform: translateY(-4px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { position: relative; color: #fff; padding: 160px 0 0; min-height: 92vh; display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden; }
.hero__bg { position: absolute; inset: 0; z-index: -1; background: var(--graphite); }
.hero__bg img { width: 100%; height: 100%; object-fit: cover; }
.hero__bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(22,24,27,.88) 0%, rgba(22,24,27,.55) 50%, rgba(22,24,27,.15) 100%),
              linear-gradient(0deg, rgba(22,24,27,.7) 0%, rgba(22,24,27,0) 40%);
}
.hero__inner { flex: 1; display: flex; align-items: center; }
.hero__text { max-width: 760px; padding-bottom: 64px; }
.hero__lead { font-size: 1.12rem; color: rgba(255,255,255,.8); max-width: 34em; margin-bottom: 2rem; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .8rem; }
.badge {
  display: inline-flex; align-items: center; gap: .6em; margin-bottom: 1.6rem;
  padding: .45em .9em; border: 1px solid rgba(255,255,255,.25); border-radius: 999px;
  font-size: .8rem; font-weight: 500; background: rgba(255,255,255,.06); backdrop-filter: blur(6px);
}
.badge i { width: 8px; height: 8px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 4px rgba(185,134,43,.25); }

.keybar {
  display: grid; grid-template-columns: repeat(4, 1fr); margin: 0;
  background: var(--white); color: var(--ink); border-radius: var(--radius) var(--radius) 0 0;
}
.keybar > div { padding: 1.5rem 1.6rem; border-left: 1px solid var(--line); }
.keybar > div:first-child { border-left: 0; }
.keybar dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: .3rem; }
.keybar dd { margin: 0; font-family: var(--display); font-size: 1.15rem; font-weight: 500; letter-spacing: -0.01em; }

/* ---------- Sekcje ---------- */
.section { padding: var(--section-y) 0; }
.section--tint { background: var(--tint); }
.section--dark { background: var(--graphite); color: #fff; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: start; }
.grid-2--center { align-items: center; }
.head { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 1.5rem 3rem; margin-bottom: 2.5rem; }
.head h2 { margin: 0; }

/* ---------- Parametry ---------- */
.specs {
  display: grid; grid-template-columns: repeat(6, 1fr); margin-top: clamp(48px, 6vw, 80px);
  border-top: 1px solid var(--ink); border-bottom: 1px solid var(--line);
}
.spec { padding: 1.8rem 1.2rem 1.8rem 0; display: flex; flex-direction: column; gap: .4rem; }
.spec + .spec { padding-left: 1.2rem; border-left: 1px solid var(--line); }
.spec__value { font-family: var(--display); font-size: clamp(2rem, 3.2vw, 2.8rem); font-weight: 300; line-height: 1; letter-spacing: -0.03em; }
.spec__value small { font-size: .45em; margin-left: .15em; color: var(--muted); font-weight: 400; }
.spec__label { font-size: .85rem; color: var(--muted); line-height: 1.4; }

/* ---------- Przed / po ---------- */
.tabs, .filters { display: inline-flex; padding: 4px; border-radius: 6px; gap: 2px; }
.tabs { background: rgba(255,255,255,.08); }
.filters { background: var(--white); border: 1px solid var(--line); }
.tab, .filter {
  background: none; border: 0; padding: .55em 1.1em; border-radius: 4px; font-size: .88rem; font-weight: 500;
  white-space: nowrap; transition: background .2s, color .2s;
}
.tab { color: rgba(255,255,255,.7); }
.tab:hover { color: #fff; }
.tab.is-active { background: #fff; color: var(--ink); }
.filter { color: var(--muted); }
.filter:hover { color: var(--ink); }
.filter.is-active { background: var(--graphite); color: #fff; }

.compare { position: relative; overflow: hidden; aspect-ratio: 900 / 506; user-select: none; background: #111; border-radius: var(--radius); }
.compare__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .3s; }
.compare__before { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.compare.is-loading .compare__img { opacity: .4; }
.compare__handle { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; background: #fff; transform: translateX(-1px); pointer-events: none; }
.compare__handle span {
  position: absolute; top: 50%; left: 50%; width: 44px; height: 44px; border-radius: 50%; transform: translate(-50%, -50%);
  background: #fff; box-shadow: 0 4px 16px rgba(0,0,0,.3);
}
.compare__handle span::before {
  content: "‹ ›"; position: absolute; inset: 0; display: grid; place-items: center; color: var(--ink); font-size: 1.1rem; font-weight: 600; letter-spacing: .1em;
}
.compare__tag {
  position: absolute; top: 1rem; padding: .35em .8em; border-radius: 3px; font-size: .78rem; font-weight: 600;
  background: rgba(22,24,27,.75); color: #fff; pointer-events: none;
}
.compare__tag--before { left: 1rem; }
.compare__tag--after { right: 1rem; background: var(--sand); }
.compare__range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; -webkit-appearance: none; appearance: none; }
.compare:focus-within .compare__handle span { box-shadow: 0 0 0 4px rgba(176,138,92,.6); }

/* ---------- Kondygnacje ---------- */
.floors { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(32px, 5vw, 72px); margin-top: 2.5rem; align-items: center; }
.floors__stack { display: flex; flex-direction: column; gap: 6px; padding: 24px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.floor {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem; text-align: left;
  padding: 1.6rem 1.4rem; border: 1px solid var(--line); border-radius: 3px; background: var(--bg);
  transition: background .25s, border-color .25s, color .25s, transform .25s var(--ease);
}
.floor span { font-family: var(--display); font-size: 1.1rem; font-weight: 500; }
.floor b { font-size: .78rem; font-weight: 500; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.floor--roof { width: 62%; margin-left: auto; background: #e3eadf; border-color: #c9d6c3; padding: 1rem 1.4rem; }
.floor--new { border-style: dashed; border-color: var(--sand); }
.floor:hover { border-color: var(--ink-2); }
.floor.is-active { background: var(--graphite); border-color: var(--graphite); color: #fff; transform: translateX(8px); }
.floor.is-active b { color: var(--sand); }
.floor-panel__tag { font-size: .8rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--sand-dark); margin-bottom: .6rem; }
.floor-panel h3 { font-size: clamp(1.6rem, 2.4vw, 2.1rem); font-weight: 400; letter-spacing: -0.02em; }
.floor-panel p { color: var(--ink-2); }
.floor-panel:not([hidden]) { animation: fadeUp .4s var(--ease); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } }

.kv { margin: 1.6rem 0 0; border-top: 1px solid var(--line); }
.kv > div { display: flex; justify-content: space-between; gap: 1rem; padding: .8rem 0; border-bottom: 1px solid var(--line); }
.kv dt { color: var(--muted); font-size: .9rem; }
.kv dd { margin: 0; font-weight: 600; text-align: right; }

/* ---------- Tabela lokali ---------- */
.table-wrap { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow-x: auto; }
.units { width: 100%; border-collapse: collapse; font-size: .95rem; min-width: 640px; }
.units th { text-align: left; font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 600; color: var(--muted); padding: 1rem 1.2rem; border-bottom: 1px solid var(--line); background: #faf9f7; }
.units td { padding: 1rem 1.2rem; border-bottom: 1px solid var(--line); }
.units tbody tr:last-child td { border-bottom: 0; }
.units tbody tr { transition: background .15s; }
.units tbody tr:hover { background: #faf8f4; }
.units td:first-child { font-family: var(--display); font-weight: 600; }
.units td:last-child { text-align: right; }
.units tr[hidden] { display: none; }
.status {
  display: inline-flex; align-items: center; gap: .45em; font-size: .82rem; font-weight: 500; color: var(--muted);
}
.status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #b9bcc0; }
.status--free { color: var(--green); }
.status--free::before { background: var(--green); }
.status--reserved { color: var(--amber); }
.status--reserved::before { background: var(--amber); }
.status--sold { color: var(--red); }
.status--sold::before { background: var(--red); }
.units tbody tr { cursor: pointer; }
.units td { vertical-align: middle; white-space: nowrap; }
.units__thumb { width: 96px; padding-top: .6rem !important; padding-bottom: .6rem !important; }
.units__thumb img { display: block; width: 84px; height: 56px; object-fit: contain; background: #fff; border: 1px solid var(--line); border-radius: 3px; padding: 3px; }
.view {
  display: inline-flex; align-items: center; gap: .5em; white-space: nowrap;
  background: none; border: 1px solid var(--line); border-radius: var(--radius); padding: .5em 1em; font-size: .85rem; font-weight: 500;
  transition: all .2s;
}
.view::before {
  content: ""; width: 14px; height: 14px; flex: none;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.4'%3E%3Crect x='1.5' y='1.5' width='13' height='13'/%3E%3Cpath d='M1.5 8h6v6.5M7.5 1.5V5M10 8h4.5'/%3E%3C/svg%3E") center/contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.4'%3E%3Crect x='1.5' y='1.5' width='13' height='13'/%3E%3Cpath d='M1.5 8h6v6.5M7.5 1.5V5M10 8h4.5'/%3E%3C/svg%3E") center/contain no-repeat;
}
.units tbody tr:hover .view, .view:hover { background: var(--graphite); color: #fff; border-color: var(--graphite); }

/* ---------- Karta lokalu (rzut) ---------- */
.unit-modal {
  position: fixed; inset: 0; z-index: 90; background: rgba(18,20,23,.72); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center; padding: clamp(0px, 3vw, 40px);
  animation: umFade .25s var(--ease);
}
.unit-modal[hidden] { display: none; }
@keyframes umFade { from { opacity: 0; } }
.unit-modal__dialog {
  background: var(--bg); width: 100%; max-width: 1280px; max-height: 100%; overflow: auto;
  border-radius: var(--radius); box-shadow: 0 40px 80px -30px rgba(0,0,0,.5); animation: umRise .35s var(--ease);
}
@keyframes umRise { from { transform: translateY(16px); opacity: 0; } }
.unit-modal__head {
  position: sticky; top: 0; z-index: 2; display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding: 1.2rem 1.6rem; background: var(--bg); border-bottom: 1px solid var(--line);
}
.unit-modal__head .overline { margin: 0 0 .2rem; }
.unit-modal__head h3 { margin: 0; font-size: 1.6rem; font-weight: 400; letter-spacing: -0.02em; }
.unit-modal__nav { display: flex; gap: .4rem; }
.icon-btn { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: var(--white); font-size: 1.1rem; display: grid; place-items: center; transition: all .2s; }
.icon-btn:hover { background: var(--graphite); color: #fff; border-color: var(--graphite); }
.unit-modal__body { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 1.6rem; padding: 1.6rem; }
.unit-modal__body > * { min-width: 0; }
.sheet { margin: 0; background: #fbfaf7; border: 1px solid var(--line); display: flex; flex-direction: column; }
.sheet__plan { flex: 1; display: grid; place-items: center; padding: 1rem; min-height: 360px; }
.sheet__plan { position: relative; background: #fff; }
.sheet__plan img { display: block; width: 100%; height: 62vh; object-fit: contain; transition: opacity .25s; }
.sheet__plan img.is-loading { opacity: .25; }
.sheet__zoom {
  position: absolute; right: .8rem; top: .8rem; padding: .4em .8em; font-size: .78rem; font-weight: 500; text-decoration: none;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); transition: all .2s;
}
.sheet__zoom:hover { background: var(--graphite); color: #fff; border-color: var(--graphite); }
.sheet__title {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: .4rem 1.5rem; padding: .7rem 1rem;
  border-top: 1px solid var(--line); font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
}
.sheet__title b { color: var(--ink); font-weight: 600; }
.unit-info { display: flex; flex-direction: column; gap: 1.2rem; }
.unit-info__key { display: grid; grid-template-columns: 1fr 1fr; margin: 0; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.unit-info__key > div { padding: 1rem; }
.unit-info__key > div + div { border-left: 1px solid var(--line); }
.unit-info__key dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: .3rem; }
.unit-info__key dd { margin: 0; font-family: var(--display); font-size: 1.5rem; font-weight: 400; letter-spacing: -0.02em; }
.unit-info__key dd .status { font-family: var(--sans); font-size: .9rem; letter-spacing: 0; }
.rooms { width: 100%; border-collapse: collapse; font-size: .9rem; }
.rooms th, .rooms td { padding: .55rem 0; border-bottom: 1px solid var(--line); text-align: left; }
.rooms th:last-child, .rooms td:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.rooms thead th { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 600; }
.rooms tfoot th { border-bottom: 0; border-top: 1px solid var(--ink); font-weight: 600; }
.unit-info__extra { margin: 0; font-size: .88rem; color: var(--ink-2); }
.unit-info .btn:disabled { opacity: .45; cursor: not-allowed; }
.unit-info .note { margin: 0; }

/* ---------- Atuty ---------- */
.features { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 2.5rem; border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.feature { padding: 2rem; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); transition: background .25s; }
.feature:hover { background: var(--white); }
.feature svg { width: 40px; height: 40px; fill: none; stroke: var(--sand); stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; margin-bottom: 1.4rem; }
.feature p { color: var(--muted); font-size: .95rem; margin: 0; }

/* ---------- Lokalizacja ---------- */
.distances { list-style: none; padding: 0; margin: 2rem 0 0; border-top: 1px solid var(--line); }
.distances li { display: flex; justify-content: space-between; gap: 1rem; padding: .85rem 0; border-bottom: 1px solid var(--line); }
.distances span { color: var(--ink-2); }
.distances b { font-weight: 600; white-space: nowrap; }
.map { position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4/3; background: var(--graphite); }
.map img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(.7) contrast(1.05) brightness(.8); }
.map__pin { position: absolute; left: 52%; top: 46%; width: 22px; height: 22px; border-radius: 50%; background: var(--sand); border: 3px solid #fff; transform: translate(-50%, -50%); box-shadow: 0 0 0 10px rgba(176,138,92,.3); }
.map__label { position: absolute; left: 1rem; bottom: 1rem; padding: .4em .8em; background: rgba(255,255,255,.92); border-radius: 3px; font-size: .8rem; font-weight: 500; }

/* ---------- Postęp prac ---------- */
.progress { min-width: min(100%, 360px); }
.progress__top { display: flex; justify-content: space-between; font-size: .9rem; color: var(--muted); margin-bottom: .5rem; }
.progress__top b { font-family: var(--display); font-size: 1.4rem; color: var(--ink); font-weight: 500; }
.progress__bar { height: 6px; background: var(--line); border-radius: 3px; overflow: hidden; }
.progress__bar span { display: block; height: 100%; background: var(--sand); border-radius: 3px; }
.timeline { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.timeline li { background: var(--bg); padding: 1.8rem 1.6rem; position: relative; display: flex; flex-direction: column; }
.timeline li.is-current { background: var(--white); box-shadow: inset 0 3px 0 var(--sand); }
.timeline li.is-done { box-shadow: inset 0 3px 0 var(--graphite); }
.timeline__date { font-family: var(--display); font-weight: 600; font-size: .9rem; color: var(--sand-dark); }
.timeline h3 { margin: .4rem 0 .5rem; }
.timeline p { color: var(--muted); font-size: .92rem; flex: 1; }

/* ---------- Galeria ---------- */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 2.5rem; }
.gallery__item { position: relative; padding: 0; border: 0; overflow: hidden; background: #ccc; aspect-ratio: 16/10; border-radius: var(--radius); }
.gallery__item--wide { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; }
.gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.gallery__item:hover img { transform: scale(1.04); }
.gallery__item span { position: absolute; left: .8rem; bottom: .8rem; padding: .3em .7em; border-radius: 3px; font-size: .78rem; font-weight: 500; background: rgba(255,255,255,.92); color: var(--ink); }

/* ---------- Inwestor ---------- */
.kv--inline { margin-top: 2rem; }

/* ---------- Kontakt ---------- */
.person { display: flex; gap: 1.2rem; align-items: flex-start; margin-top: 2.5rem; padding: 1.5rem; border: 1px solid var(--line-dark); border-radius: var(--radius); max-width: 420px; }
.person__avatar { flex: none; width: 56px; height: 56px; border-radius: 50%; background: var(--sand); color: #fff; display: grid; place-items: center; font-family: var(--display); font-weight: 600; }
.person div:last-child { display: flex; flex-direction: column; gap: .15rem; }
.person b { font-family: var(--display); font-size: 1.1rem; font-weight: 500; }
.person span { font-size: .85rem; color: rgba(255,255,255,.55); margin-bottom: .5rem; }
.person a { text-decoration: none; color: #fff; }
.person a:hover { color: var(--sand); }

.form { background: var(--white); color: var(--ink); padding: clamp(24px, 3.5vw, 40px); border-radius: var(--radius); display: grid; gap: 1rem; }
.form__row--2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form label { display: grid; gap: .35rem; font-size: .85rem; font-weight: 500; color: var(--ink-2); }
.form input[type=text], .form input[type=email], .form input[type=tel], .form select, .form textarea {
  width: 100%; font: inherit; font-size: .95rem; color: var(--ink); background: var(--bg);
  border: 1px solid var(--line); border-radius: var(--radius); padding: .75em .9em; transition: border-color .2s, background .2s;
}
.form select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%236d7177' stroke-width='1.5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .9em center; padding-right: 2.4em; }
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--sand); background: #fff; }
.form .is-invalid { border-color: var(--red) !important; }
.form textarea { resize: vertical; }
.form__consent { display: flex !important; align-items: flex-start; gap: .6rem !important; font-weight: 400 !important; font-size: .8rem !important; color: var(--muted) !important; }
.form__consent input { margin-top: .2em; accent-color: var(--sand); }
.form__consent.is-invalid { color: var(--red) !important; }
.form__msg { margin: 0; font-size: .9rem; font-weight: 500; color: var(--green); min-height: 1.2em; }
.form__msg.is-error { color: var(--red); }

/* ---------- Stopka ---------- */
.footer { background: #121417; color: rgba(255,255,255,.5); font-size: .8rem; padding: 1.6rem 0; }
.footer__inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem 2rem; }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(14,15,17,.95); display: flex; align-items: center; justify-content: center; padding: 4vw; }
.lightbox[hidden] { display: none; }
.lightbox figure { margin: 0; max-width: 1100px; width: 100%; }
.lightbox img { width: 100%; border-radius: var(--radius); }
.lightbox figcaption { color: rgba(255,255,255,.7); text-align: center; margin-top: 1rem; font-size: .9rem; }
.lightbox__close, .lightbox__nav { position: absolute; background: rgba(255,255,255,.1); color: #fff; border: 0; border-radius: 50%; width: 48px; height: 48px; font-size: 1.3rem; display: grid; place-items: center; }
.lightbox__close { font-size: 1.7rem; top: 20px; right: 20px; }
.lightbox__close:hover, .lightbox__nav:hover { background: rgba(255,255,255,.25); }
.lightbox__prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox__next { right: 20px; top: 50%; transform: translateY(-50%); }

/* ---------- Animacje wejścia ---------- */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- Responsywność ---------- */
@media (max-width: 1100px) {
  .nav__menu { gap: 1.2rem; }
  .specs { grid-template-columns: repeat(3, 1fr); }
  .spec:nth-child(4) { padding-left: 0; border-left: 0; }
  .spec:nth-child(n+4) { border-top: 1px solid var(--line); }
}

@media (max-width: 960px) {
  .nav__toggle { display: block; }
  .nav__menu {
    position: fixed; top: 76px; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; color: var(--ink); padding: .5rem var(--gutter) 1.5rem; border-bottom: 1px solid var(--line);
    transform: translateY(-8px); opacity: 0; pointer-events: none; transition: all .25s;
  }
  .nav.is-open .nav__menu { transform: none; opacity: 1; pointer-events: auto; }
  .nav__menu a:not(.btn) { padding: .9rem 0; border-bottom: 1px solid var(--line); opacity: 1; }
  .nav__menu .btn { margin-top: 1rem; }
  .grid-2, .floors { grid-template-columns: 1fr; }
  .keybar { grid-template-columns: 1fr 1fr; }
  .keybar > div:nth-child(3) { border-left: 0; }
  .keybar > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .features { grid-template-columns: 1fr 1fr; }
  .timeline { grid-template-columns: 1fr 1fr; }
  .unit-modal__body { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 620px) {
  .hero { padding-top: 120px; min-height: 0; }
  .hero__text { padding-bottom: 40px; }
  .hero__bg::after { background: linear-gradient(180deg, rgba(22,24,27,.75), rgba(22,24,27,.85)); }
  .keybar > div { padding: 1.1rem 1rem; }
  .keybar dd { font-size: 1rem; }
  .specs { grid-template-columns: 1fr 1fr; }
  .spec, .spec + .spec { padding: 1.4rem 1rem 1.4rem 0; border-left: 0; }
  .spec:nth-child(even) { padding-left: 1rem; border-left: 1px solid var(--line); }
  .spec:nth-child(n+3) { border-top: 1px solid var(--line); }
  .features, .timeline, .form__row--2 { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr 1fr; gap: 8px; }
  .gallery__item--wide { grid-row: auto; aspect-ratio: 16/10; }
  .gallery__item span { font-size: .68rem; }
  .tabs, .filters { width: 100%; overflow-x: auto; }
  .tab, .filter { flex: 1 0 auto; }
  .floor.is-active { transform: none; }
  .floors__stack { padding: 14px; }
  .floor { padding: 1.3rem 1rem; }
  .floor--roof { width: 78%; padding: .9rem 1rem; }
  .floor b { font-size: .7rem; }
  .lightbox__nav { top: auto; bottom: 20px; transform: none; }
  .unit-modal__head { padding: 1rem; }
  .unit-modal__head h3 { font-size: 1.25rem; }
  .icon-btn { width: 38px; height: 38px; }
  .unit-modal__body { padding: 1rem; }
  .sheet__plan { min-height: 0; padding: .4rem; }
  .unit-modal { padding: 0; }
  .unit-modal__dialog { border-radius: 0; height: 100%; }
  .units { min-width: 0; }
  .units th:nth-child(3), .units td:nth-child(3),
  .units th:nth-child(4), .units td:nth-child(4),
  .units th:nth-child(6), .units td:nth-child(6),
  .units th:nth-child(8), .units td:nth-child(8) { display: none; }
  .units th, .units td { padding: .8rem .7rem; }
  .units__thumb { width: 76px; }
  .units__thumb img { width: 60px; height: 44px; }
  .units td:nth-child(5) { white-space: normal; }
  .sheet__plan img { height: 52vh; }
}
