/* ============================================================
   GREEN PARK POTOCKIEGO — style.css
   Complete CSS: design system, layout, components, animations
   ============================================================ */

/* ─── CSS CUSTOM PROPERTIES ──────────────────────────────── */
:root {
  --font-family: 'DM Sans', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --filters-font-family: var(--font-family);
  --max-width: 1280px;
  --side-padding: 80px;
  --section-padding: 120px;
  --nav-height: 70px;
  --nav-brand-logo-scale: 88;
  --nav-brand-primary-size: 24px;
  --nav-brand-accent-size: 12px;
  --nav-brand-sep-size: 12px;
}

/* ─── DARK THEME (default) ───────────────────────────────── */
[data-theme="dark"] {
  --green-primary: #284023;
  --gold-accent:   #CAB591;
  --dark-bg:       #1A2A17;
  --light-bg:      #F5F0E8;
  --white:         #FFFFFF;
  --text-body:     #333333;
  --text-muted:    #777777;
}

/* ─── LIGHT THEME ────────────────────────────────────────── */
[data-theme="light"] {
  --green-primary: #3A6032;
  --gold-accent:   #9A7B4F;
  --dark-bg:       #FFFFFF;
  --light-bg:      #F0EDE5;
  --white:         #1A2A17;
  --text-body:     #1A2A17;
  --text-muted:    #555555;
}

/* ─── RESET & BASE ───────────────────────────────────────── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
}

body {
  font-family: var(--font-family);
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-body);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.menu-open {
  overflow: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  cursor: pointer;
  font-family: inherit;
  border: none;
  background: none;
}

/* ─── FOCUS VISIBLE ──────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--gold-accent);
  outline-offset: 3px;
}

/* ─── THEME TOGGLE ───────────────────────────────────────── */
.theme-toggle {
  background: none;
  border: 1px solid rgba(202,181,145,0.3);
  border-radius: 50%;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.3s, border-color 0.3s;
  flex-shrink: 0;
  margin-right: 8px;
}
.theme-toggle:hover {
  background: rgba(202,181,145,0.15);
  border-color: var(--gold-accent);
}
.theme-toggle .icon-sun,
.theme-toggle .icon-moon { width: 20px; height: 20px; }
[data-theme="dark"] .theme-toggle .icon-sun  { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
[data-theme="light"] .theme-toggle .icon-sun  { display: none; }
[data-theme="light"] .theme-toggle .icon-moon { display: block; }

body {
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* ─── TYPOGRAPHY ─────────────────────────────────────────── */
.display-heading {
  font-size: 72px;
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.02em;
}

h1 { font-size: 48px; font-weight: 700; color: var(--green-primary); line-height: 1.15; }
h2 { font-size: 32px; font-weight: 600; color: var(--green-primary); line-height: 1.25; }
h3 { font-size: 20px; font-weight: 600; color: var(--green-primary); line-height: 1.35; }

.section-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold-accent);
  text-align: center;
  margin-bottom: 16px;
}

.section-label::before,
.section-label::after {
  content: '';
  width: 40px;
  height: 1px;
  background: var(--gold-accent);
  opacity: 0.4;
}

/* ─── LAYOUT ─────────────────────────────────────────────── */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: var(--side-padding);
  padding-right: var(--side-padding);
}

section {
  padding-top: var(--section-padding);
  padding-bottom: var(--section-padding);
}

/* ─── BUTTONS ────────────────────────────────────────────── */
.btn-primary {
  display: inline-block;
  background: var(--green-primary);
  color: var(--white);
  border: 2px solid var(--green-primary);
  padding: 14px 36px;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  border-radius: 6px;
  transition: all 0.3s ease;
  text-align: center;
  letter-spacing: 0.05em;
  box-shadow: 0 4px 15px rgba(40, 64, 35, 0.25);
}

.btn-primary:hover {
  background: transparent;
  color: var(--green-primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(40, 64, 35, 0.3);
}

.btn-gold-outline {
  display: inline-block;
  background: transparent;
  color: var(--gold-accent);
  border: 2px solid var(--gold-accent);
  padding: 14px 36px;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  border-radius: 6px;
  transition: all 0.3s ease;
  text-align: center;
  letter-spacing: 0.05em;
}

.btn-gold-outline:hover {
  background: var(--gold-accent);
  color: var(--dark-bg);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(202, 181, 145, 0.3);
}

/* ─── REVEAL ANIMATION ───────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

.reveal > *:nth-child(1) { transition-delay: 0s; }
.reveal > *:nth-child(2) { transition-delay: 0.1s; }
.reveal > *:nth-child(3) { transition-delay: 0.2s; }
.reveal > *:nth-child(4) { transition-delay: 0.3s; }
.reveal > *:nth-child(5) { transition-delay: 0.4s; }
.reveal > *:nth-child(6) { transition-delay: 0.5s; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   1. NAVIGATION
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(26, 42, 23, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 0 var(--side-padding);
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-height);
  border-bottom: 1px solid rgba(202, 181, 145, 0.1);
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

#navbar.scrolled {
  background: rgba(26, 42, 23, 0.95);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.25);
}

.nav-brand {
  display: flex;
  align-items: center;
  align-self: stretch;
  height: 100%;
  gap: 12px;
  flex-shrink: 0;
  min-height: 0;
  padding: 10px 0;
}

.nav-brand[data-brand-mode="image-only"] {
  justify-content: center;
  padding: 0;
}

.nav-brand-logo {
  width: auto;
  height: 100%;
  max-height: 100%;
  object-fit: contain;
  object-position: center;
  flex-shrink: 0;
  filter: brightness(0) invert(1);
  transition: filter 0.3s;
}

.nav-brand[data-brand-mode="image-only"] .nav-brand-logo {
  width: auto;
  height: calc(var(--nav-height) * var(--nav-brand-logo-scale) / 100);
  max-width: min(280px, 42vw);
  max-height: calc(var(--nav-height) * var(--nav-brand-logo-scale) / 100);
}

.nav-brand-text {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  font-weight: 700;
  color: var(--white);
  white-space: nowrap;
}

.nav-brand-text .brand-primary {
  font-size: var(--nav-brand-primary-size);
  line-height: 1;
}

.nav-brand-text .brand-sep {
  font-size: var(--nav-brand-sep-size);
  color: var(--text-muted);
  line-height: 1;
}

.nav-brand-text .brand-accent {
  font-size: var(--nav-brand-accent-size);
  color: var(--gold-accent);
  line-height: 1;
}

.nav-brand-text[hidden] {
  display: none;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-link {
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--white);
  transition: color 0.3s ease;
  position: relative;
  padding-bottom: 4px;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gold-accent);
  transition: width 0.3s ease;
}

.nav-link.active::after,
.nav-link:hover::after {
  width: 100%;
}

.nav-link.active,
.nav-link:hover {
  color: var(--gold-accent);
}

.nav-cta {
  flex-shrink: 0;
}

.nav-cta .btn-gold-outline {
  padding: 10px 24px;
  font-size: 13px;
}

#hamburger-btn {
  display: none;
  color: var(--white);
  background: none;
  border: none;
  padding: 8px;
}

#hamburger-btn svg { width: 28px; height: 28px; }

/* Mobile menu overlay */
#mobile-menu {
  position: fixed;
  inset: 0;
  background: var(--dark-bg);
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
  transform: translateX(100%);
  transition: transform 0.35s ease;
}

#mobile-menu.open {
  transform: translateX(0);
}

.mobile-menu-close {
  position: absolute;
  top: 16px;
  right: 16px;
  color: var(--white);
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
  transition: color 0.3s;
  z-index: 1;
}
.mobile-menu-close:hover {
  color: var(--gold-accent);
}

#mobile-menu a {
  font-size: 24px;
  font-weight: 700;
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  transition: color 0.3s;
}

#mobile-menu a:hover {
  color: var(--gold-accent);
}

.mobile-menu-cta {
  margin-top: 16px;
  font-size: 14px !important;
  padding: 12px 32px;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   2. HERO
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#hero {
  height: 100vh;
  min-height: 600px;
  background: url('https://images.unsplash.com/photo-1560448204-e02f11c3d0e2?w=1920') center/cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  text-align: center;
}

#hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(26, 42, 23, 0.3) 0%,
    rgba(26, 42, 23, 0.5) 40%,
    rgba(26, 42, 23, 0.75) 100%
  );
}

#hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 120px;
  background: linear-gradient(to top, var(--light-bg), transparent);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  padding: 0 20px;
  animation: heroFadeIn 1.2s ease-out;
}

@keyframes heroFadeIn {
  0% { opacity: 0; transform: translateY(40px); }
  100% { opacity: 1; transform: translateY(0); }
}

.hero-content .section-label {
  margin-bottom: 20px;
  font-size: 14px;
  letter-spacing: 0.25em;
}

.hero-content .display-heading {
  color: var(--white);
  margin-bottom: 16px;
  text-shadow: 0 2px 30px rgba(0, 0, 0, 0.3);
}

.hero-content .hero-sub {
  color: var(--gold-accent);
  font-size: 20px;
  margin-bottom: 40px;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.2);
}

.hero-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.scroll-arrow {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); opacity: 1; }
  50%      { transform: translateX(-50%) translateY(10px); opacity: 0.5; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   3. ABOUT
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#o-inwestycji {
  background: var(--light-bg);
}

.about-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 60px;
  align-items: start;
}

.about-text h2 {
  margin-bottom: 20px;
  text-align: center;
}

.about-text p {
  margin-bottom: 24px;
  color: var(--text-body);
  text-align: center;
}

.about-image-wrap {
  margin-top: 24px;
  border-radius: 16px;
  overflow: hidden;
}

.about-image {
  width: 100%;
  max-height: 500px;
  display: block;
  object-fit: cover;
  border-radius: 16px;
}

.about-features {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 10px;
}

.about-features li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 16px;
  padding: 12px 16px;
  border-radius: 10px;
  transition: background 0.3s ease, transform 0.2s ease;
}

.about-features li:hover {
  background: rgba(202, 181, 145, 0.08);
  transform: translateX(4px);
}

.about-features li svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  margin-top: 3px;
  stroke: var(--gold-accent);
  fill: none;
  stroke-width: 2;
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.stat-card {
  text-align: center;
  background: var(--white);
  padding: 32px 20px;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
  border: 1px solid transparent;
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.stat-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 36px rgba(0,0,0,0.1);
  border-color: rgba(202, 181, 145, 0.3);
}

.stat-number {
  font-size: 48px;
  font-weight: 700;
  color: var(--green-primary);
  line-height: 1;
  text-shadow: 0 1px 0 rgba(255,255,255,0.08);
}

.stat-label {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold-accent);
  margin-top: 10px;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   4. OFFER / MAP
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#oferta {
  background: var(--dark-bg);
  color: var(--white);
}

#oferta h2 {
  color: var(--white);
  text-align: center;
  margin-bottom: 32px;
}

.offer-plan-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.offer-plan-map {
  min-width: 0;
}

.filters-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  align-items: stretch;
  gap: 14px 16px;
  margin-bottom: 24px;
  width: 100%;
  margin-inline: auto;
  padding: 18px 20px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px;
  font-family: var(--filters-font-family, var(--font-family));
}

.offer-plan-layout .filters-bar {
  margin-bottom: 0;
}

.apt-list-filters {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
  width: 100%;
  margin-inline: auto;
  padding: 20px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px;
  font-family: var(--filters-font-family, var(--font-family));
}

#offer-tab-plan[data-filters-placement="left"] .offer-plan-layout,
#offer-tab-plan[data-filters-placement="right"] .offer-plan-layout {
  grid-template-columns: minmax(320px, 420px) minmax(0, 1fr);
}

#offer-tab-plan[data-filters-placement="left"] .filters-bar,
#offer-tab-plan[data-filters-placement="right"] .filters-bar {
  width: 100%;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-inline: auto;
  align-self: start;
}

#offer-tab-plan[data-filters-placement="right"] .filters-bar {
  order: 2;
}

#offer-tab-plan[data-filters-placement="right"] .offer-plan-map {
  order: 1;
}

#oferta .container[data-filters-placement="left"] .apt-list-filters {
  width: 100%;
  margin-inline: auto;
}

#oferta .container[data-filters-placement="right"] .apt-list-filters {
  width: 100%;
  margin-inline: auto;
}

#oferta .container[data-filters-placement="center"] .filters-bar,
#oferta .container[data-filters-placement="center"] .apt-list-filters {
  width: 100%;
  margin-inline: auto;
}

.filters-bar .filter-group {
  background: none;
  border: none;
  border-radius: 0;
  box-shadow: none;
  padding: 0;
  min-width: 100px;
  max-width: none;
}

.filters-bar .filter-group[data-filter-group="floor"],
.filters-bar .filter-group[data-filter-group="status"] {
  grid-column: span 1;
}

.filters-bar .filter-group[data-filter-group="size"],
.filters-bar .filter-group[data-filter-group="price"] {
  grid-column: span 2;
}

.filter-group {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 12px;
  min-width: 0;
  padding: 14px 16px;
  background: rgba(5, 12, 8, 0.18);
  border: 1px solid rgba(202,181,145,0.12);
  border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
  font-family: inherit;
}

.filter-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-weight: 500;
  color: rgba(255,255,255,0.82);
  font-size: 13px;
}

.filter-group-title {
  font-weight: 700;
  color: var(--gold-accent);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.filter-group select,
.filter-group input[type="text"] {
  width: 100%;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.12);
  color: #fff;
  padding: 12px 14px;
  border-radius: 12px;
  font-family: inherit;
  font-size: 14px;
}

.filter-group select option {
  background: var(--dark-bg);
  color: #fff;
}

.filter-choice-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-choice-wrap label {
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
}

.filter-group input[type="radio"],
.filter-group input[type="checkbox"] {
  accent-color: var(--gold-accent);
  width: 16px;
  height: 16px;
}

.range-stack {
  display: grid;
  gap: 10px;
}

.range-stack label {
  display: grid;
  grid-template-columns: 26px 1fr;
  gap: 10px;
  align-items: center;
}

.range-stack span {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(255,255,255,0.62);
}

.filter-group input[type="range"] {
  accent-color: var(--gold-accent);
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  background: rgba(202,181,145,0.3);
  border-radius: 4px;
  outline: none;
}

.filter-group input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--gold-accent);
  cursor: pointer;
}

.filter-size-label {
  font-size: 13px;
  color: var(--gold-accent);
  min-width: 80px;
  font-weight: 600;
}

.filter-group-search {
  grid-column: 1 / -1;
}

/* Map container */
#map-container {
  min-height: 300px;
  position: relative;
}

/* SVG map step 1 */
.estate-svg {
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  display: block;
}

.section-group {
  cursor: pointer;
  pointer-events: all;
}

.section-group rect.map-cell {
  transition: filter 0.2s ease, opacity 0.2s ease;
}

.section-group rect.map-cell:hover {
  filter: brightness(1.35) drop-shadow(0 0 6px rgba(202,181,145,0.5));
}

.section-group:hover rect.map-cell:not(:hover) {
  opacity: 0.6;
}

.section-group:focus rect.map-cell {
  filter: brightness(1.25);
}

/* ─── MAP TOOLTIP ────────────────────────────────────────── */
.map-tooltip {
  position: fixed;
  z-index: 10000;
  pointer-events: none;
  background: #1A2A17;
  border: 1px solid rgba(202,181,145,0.35);
  border-radius: 10px;
  padding: 14px 18px;
  min-width: 210px;
  max-width: 520px;
  box-shadow: 0 8px 28px rgba(0,0,0,0.45);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s ease, visibility 0.15s ease;
  font-family: var(--font-family);
}

.map-tooltip.visible {
  opacity: 1;
  visibility: visible;
}

.tt-title {
  color: #CAB591;
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: 0.02em;
}

.tt-row {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  color: #F5F0E8;
  line-height: 1.6;
}

.tt-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.tt-divider {
  height: 1px;
  background: rgba(202,181,145,0.18);
  margin: 7px 0;
}

.tt-price {
  color: #CAB591;
  font-size: 13px;
  font-weight: 600;
  margin-top: 4px;
}

.tt-price-m2 {
  color: #CAB591;
  font-size: 12px;
  opacity: 0.85;
}

.tt-size {
  color: #F5F0E8;
  font-size: 12px;
  opacity: 0.8;
}

.map-counter {
  text-align: center;
  color: var(--gold-accent);
  font-size: 15px;
  margin-top: 16px;
  font-weight: 600;
}

.map-counter strong {
  color: var(--white);
  font-size: 1.1em;
}

.map-hint {
  text-align: center;
  color: rgba(255,255,255,0.55);
  font-size: 13px;
  margin-top: 12px;
}

/* Map step 2 */
.map-step {
  position: relative;
}

.btn-back {
  color: var(--gold-accent);
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
  background: none;
  border: none;
  cursor: pointer;
  transition: color 0.3s;
}

.btn-back:hover {
  color: var(--white);
}

.map-section-title {
  color: var(--white);
  text-align: center;
  margin-bottom: 20px;
}

.section-grid {
  display: flex;
  gap: 12px;
  justify-content: center;
  max-width: 100%;
  overflow-x: auto;
}

.section-detail-layout {
  display: grid;
  gap: 18px;
}

.section-grid-card,
.section-photo-card,
.seg-photos-gallery {
  padding: 18px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px;
}

.section-photo-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.section-photo-header h4 {
  color: var(--gold-accent);
  margin-bottom: 4px;
}

.section-photo-header p {
  color: rgba(255,255,255,0.7);
  font-size: 14px;
}

.section-photo-stage {
  aspect-ratio: var(--map2d-aspect-ratio, 16 / 9);
}

.section-photo-overlay {
  pointer-events: auto;
}

.section-photo-zone,
.section-photo-hotspot {
  cursor: pointer;
}

.section-photo-zone {
  transition: opacity 0.2s ease, stroke-width 0.2s ease;
}

.section-photo-zone:hover,
.section-photo-zone.is-active {
  opacity: 0.3;
  stroke-width: 3;
}

.section-photo-hotspot rect {
  transition: fill 0.2s ease, stroke 0.2s ease, stroke-width 0.2s ease;
}

.section-photo-hotspot text {
  pointer-events: none;
}

.section-photo-hotspot:hover rect,
.section-photo-hotspot.is-active rect {
  fill: rgba(8,15,12,0.92);
}

.section-photo-hotspot.is-active rect {
  stroke: #E1CCA6;
  stroke-width: 2;
}

.section-photo-hotspot.is-active text:last-of-type {
  fill: #E1CCA6;
}

.grid-labels {
  display: flex;
  flex-direction: column;
  gap: 8px;
  justify-content: center;
}

.floor-label {
  height: 70px;
  display: flex;
  align-items: center;
  font-size: 13px;
  font-weight: 600;
  color: var(--gold-accent);
  white-space: nowrap;
}

.grid-cells {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.grid-row {
  display: flex;
  gap: 6px;
}

.grid-cell {
  width: 80px;
  height: 70px;
  border-radius: 6px;
  border: 2px solid transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  cursor: pointer;
  transition: border-color 0.2s ease, transform 0.2s ease;
  color: var(--white);
  font-family: inherit;
}

.grid-cell:hover:not([disabled]) {
  border-color: var(--gold-accent);
  transform: scale(1.05);
}

.grid-cell.is-photo-focus:not([disabled]) {
  border-color: rgba(202,181,145,0.9);
  box-shadow: 0 0 0 3px rgba(202,181,145,0.18);
}

.grid-cell.is-selected:not([disabled]) {
  border-color: var(--gold-accent);
  box-shadow: 0 0 0 4px rgba(202,181,145,0.22);
  transform: translateY(-1px);
}

.grid-cell[disabled] {
  cursor: not-allowed;
  opacity: 0.4;
}

.grid-cell.cell-premium {
  width: 120px;
}

.cell-id {
  font-size: 11px;
  font-weight: 700;
}

.cell-size {
  font-size: 10px;
  opacity: 0.9;
}

/* Map step 3 — Side-by-side layout */
.step3-layout {
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

.step3-grid-col {
  flex: 1;
  min-width: 0;
  overflow-x: auto;
}

.step3-panel-col {
  flex-shrink: 0;
  width: 360px;
}

.estate-overview-card {
  margin-top: 18px;
  padding: 16px;
  border: 1px solid rgba(202, 181, 145, 0.24);
  border-radius: 12px;
  background: rgba(245, 240, 232, 0.06);
}

.estate-overview-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}

.estate-overview-header h4 {
  font-size: 15px;
  color: var(--gold-accent);
  margin-bottom: 2px;
}

.estate-overview-header p {
  font-size: 12px;
  color: rgba(245, 240, 232, 0.82);
}

.estate-overview-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(202, 181, 145, 0.18);
  color: var(--white);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.estate-overview-map {
  min-height: 220px;
}

.estate-overview-note {
  margin-top: 10px;
  font-size: 12px;
  color: rgba(245, 240, 232, 0.76);
}

.estate-overview-pin-ring {
  transform-origin: center;
  animation: estatePinPulse 1.8s ease-out infinite;
}

@keyframes estatePinPulse {
  0% { transform: scale(0.82); opacity: 0.95; }
  70% { transform: scale(1.18); opacity: 0.2; }
  100% { transform: scale(1.18); opacity: 0; }
}

.apartment-panel {
  width: 100%;
  max-height: none;
  overflow: visible;
  background: rgba(12,18,14,0.96);
  border: 1px solid rgba(202,181,145,0.32);
  border-radius: 18px;
  padding: 24px;
  position: relative;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.28s ease, transform 0.28s ease;
}

.apartment-panel.visible {
  opacity: 1;
  transform: translateY(0);
}

.apartment-panel-below {
  margin-top: 18px;
}

.panel-close {
  position: absolute;
  top: 12px;
  right: 16px;
  color: var(--gold-accent);
  font-size: 14px;
  font-weight: 600;
  background: none;
  border: none;
  cursor: pointer;
}

.panel-header {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 20px;
  padding-top: 4px;
}

.apt-id-badge {
  background: var(--gold-accent);
  color: var(--dark-bg);
  font-weight: 700;
  font-size: 16px;
  padding: 4px 12px;
  border-radius: 4px;
}

.apt-type-chip {
  font-size: 12px;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: 4px;
}

.chip-standard { background: rgba(76,175,80,0.2); color: #4CAF50; }
.chip-premium  { background: rgba(202,181,145,0.2); color: var(--gold-accent); }

.apt-status {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 4px;
}

.status-available { background: rgba(76,175,80,0.15); color: #4CAF50; }
.status-reserved  { background: rgba(255,152,0,0.15); color: #FF9800; }
.status-sold      { background: rgba(239,83,80,0.15); color: #EF5350; }

.panel-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.apartment-summary-row {
  flex-wrap: wrap;
  gap: 10px;
}

.apartment-summary-row span {
  color: rgba(255,255,255,0.45);
}

.detail-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  color: var(--white);
}

.detail-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.detail-price {
  font-size: 32px;
  font-weight: 700;
  color: var(--gold-accent);
}

.parking-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--white);
  cursor: pointer;
}

.parking-toggle input {
  accent-color: var(--gold-accent);
  width: 18px;
  height: 18px;
}

.features-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.feature-badge {
  background: rgba(202,181,145,0.12);
  color: var(--gold-accent);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid rgba(202,181,145,0.3);
}

.panel-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.panel-actions .btn-primary,
.panel-actions .btn-gold-outline {
  flex: 1;
  min-width: 140px;
  padding: 12px 16px;
  font-size: 13px;
  text-align: center;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   5. LOCATION
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#lokalizacja {
  background: var(--light-bg);
}

.location-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.location-text h2 {
  margin-bottom: 24px;
}

.advantage-list {
  list-style: none;
  margin-bottom: 32px;
}

.advantage-list li {
  padding: 8px 0;
  font-size: 16px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.advantage-list li::before {
  content: '•';
  color: var(--gold-accent);
  font-size: 24px;
  line-height: 1;
  flex-shrink: 0;
}

#leaflet-map {
  height: 420px;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  border: 1px solid rgba(202, 181, 145, 0.15);
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   6. GALLERY
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#galeria {
  background: var(--dark-bg);
}

#galeria h2 {
  color: var(--white);
  text-align: center;
  margin-bottom: 40px;
}

.gallery-grid {
  columns: 3;
  column-gap: 12px;
}

.gallery-grid figure {
  break-inside: avoid;
  margin-bottom: 14px;
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  transition: box-shadow 0.4s ease;
}

.gallery-grid figure:hover {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
}

.gallery-grid figure img {
  width: 100%;
  display: block;
  transition: transform 0.4s ease;
}

.gallery-grid figure:hover img {
  transform: scale(1.05);
}

.gallery-grid figure::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(26,42,23,0.7) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.gallery-grid figure:hover::after {
  opacity: 1;
}

.gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px;
  color: var(--gold-accent);
  font-size: 14px;
  font-weight: 600;
  transform: translateY(100%);
  transition: transform 0.3s ease;
  z-index: 1;
}

.gallery-grid figure:hover .gallery-caption {
  transform: translateY(0);
}

/* ─── LIGHTBOX ─────────────────────────────────────────────── */
#lightbox {
  position: fixed;
  inset: 0;
  background: rgba(26, 42, 23, 0.95);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

#lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

#lightbox-img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: 8px;
}

.lb-close {
  position: absolute;
  top: 20px;
  right: 24px;
  color: var(--gold-accent);
  font-size: 32px;
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1;
}

.lb-prev, .lb-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--gold-accent);
}

.lb-prev { left: 20px; }
.lb-next { right: 20px; }

.lb-prev svg, .lb-next svg {
  width: 40px;
  height: 40px;
}

/* ─── TYPE SHOWCASE ──────────────────────────────────────────── */
.type-showcase-sub {
  color: rgba(255,255,255,0.65);
  max-width: 600px;
  margin: 0 auto 40px;
  text-align: center;
  font-size: 15px;
}

.type-showcase-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.type-tile {
  background: rgba(255,255,255,0.06);
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s, background 0.3s;
  border: 1px solid rgba(202,181,145,0.1);
}
.type-tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.3);
  background: rgba(255,255,255,0.1);
  border-color: rgba(202,181,145,0.3);
}

.type-tile-thumb {
  position: relative;
  width: 100%;
  height: 200px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--green-primary), var(--dark-bg));
}
.type-tile-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}
.type-tile:hover .type-tile-thumb img {
  transform: scale(1.05);
}
.type-tile-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.type-tile-placeholder span {
  font-size: 48px;
  font-weight: 800;
  color: rgba(202,181,145,0.3);
  letter-spacing: 2px;
}
.type-tile-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(26,42,23,0.85);
  color: var(--gold-accent);
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
  backdrop-filter: blur(6px);
}

.type-tile-info {
  padding: 16px;
}
.type-tile-name {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 6px;
}
.type-tile-meta {
  display: flex;
  gap: 12px;
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  margin-bottom: 6px;
}
.type-tile-price {
  color: var(--gold-accent);
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
}
.type-tile-avail {
  font-size: 12px;
  color: rgba(255,255,255,0.7);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
}
.avail-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}
.avail-dot.green { background: #4CAF50; }
.avail-dot.red { background: #EF5350; }

.type-tile-features {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.type-feat-tag {
  background: rgba(202,181,145,0.15);
  color: var(--gold-accent);
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 10px;
  white-space: nowrap;
}

/* ─── TYPE DETAIL OVERLAY ──────────────────────────────────── */
.type-detail-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 1500;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
  backdrop-filter: blur(4px);
}
.type-detail-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.type-detail-modal {
  background: var(--dark-bg);
  border-radius: 16px;
  max-width: 960px;
  width: 92vw;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  border: 1px solid rgba(202,181,145,0.2);
}

.type-detail-modal,
.type-detail-modal * {
  color: inherit;
}
.type-detail-close {
  position: absolute;
  top: 14px;
  right: 18px;
  background: none;
  border: none;
  color: var(--gold-accent);
  font-size: 30px;
  cursor: pointer;
  z-index: 2;
  line-height: 1;
}

.type-detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}
.type-detail-left {
  padding: 28px;
  border-right: 1px solid rgba(255,255,255,0.06);
}
.type-detail-left h4 {
  color: var(--gold-accent);
  font-size: 14px;
  margin: 16px 0 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.type-detail-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
}
.type-detail-gallery img {
  width: 100%;
  border-radius: 8px;
  cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s;
}
.type-detail-gallery img:hover {
  transform: scale(1.04);
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}
.type-detail-no-images {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 200px;
  color: rgba(255,255,255,0.4);
  font-style: italic;
}

.type-detail-right {
  padding: 28px;
}
.type-detail-right h2 {
  color: #fff;
  font-size: 24px;
  margin-bottom: 8px;
}
.type-detail-desc {
  color: rgba(255,255,255,0.65);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 20px;
}
.type-detail-stats {
  display: flex;
  gap: 20px;
  margin-bottom: 16px;
}
.type-stat {
  text-align: center;
  padding: 12px 16px;
  background: rgba(255,255,255,0.04);
  border-radius: 10px;
  min-width: 80px;
}
.type-stat-val {
  display: block;
  font-size: 22px;
  font-weight: 700;
  color: var(--gold-accent);
}
.type-stat-label {
  font-size: 11px;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.type-detail-price {
  color: var(--gold-accent);
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 12px;
}
.type-detail-badges {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.type-badge {
  background: rgba(255,255,255,0.06);
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 13px;
  color: rgba(255,255,255,0.8);
}
.type-detail-rooms table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 16px;
}
.type-detail-rooms h4,
.type-detail-features h4 {
  color: var(--gold-accent);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
}
.type-detail-rooms td {
  padding: 6px 8px;
  font-size: 13px;
  color: rgba(255,255,255,0.75);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.type-detail-rooms td:last-child {
  text-align: right;
  color: var(--gold-accent);
  font-weight: 600;
}
.type-feat-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 20px;
}
.type-detail-cta {
  width: 100%;
  padding: 14px;
  font-size: 15px;
  margin-top: 10px;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   7. CONTACT
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#kontakt {
  background: var(--green-primary);
}

.contact-wrap {
  max-width: 1120px;
  margin: 0 auto;
  text-align: center;
}

.contact-wrap.has-both-agents {
  max-width: 1600px;
}

.contact-layout {
  display: grid;
  gap: 28px;
  max-width: 980px;
  margin: 0 auto;
  align-items: start;
}

.contact-layout[data-agent-layout="left"],
.contact-layout[data-agent-layout="right"] {
  max-width: 1120px;
  grid-template-columns: minmax(320px, 420px) minmax(0, 1fr);
}

.contact-layout[data-agent-layout="right"] #agent-card-container {
  order: 2;
}

.contact-layout[data-agent-layout="right"] .contact-form-panel {
  order: 1;
}

/* Both-sides layout: agent left | form | agent right */
.contact-layout[data-agent-layout="both"] {
  --agent-slot-width: 420px;
  max-width: 1600px;
  grid-template-columns: var(--agent-slot-width, 420px) minmax(320px, 1fr) var(--agent-slot-width, 420px);
}

.contact-layout[data-agent-layout="both"] .agent-card-slot-left {
  order: 1;
}

.contact-layout[data-agent-layout="both"] .contact-form-panel {
  order: 2;
}

.contact-layout[data-agent-layout="both"] .agent-card-slot-right {
  order: 3;
}

/* Hide slots that are not active */
.agent-card-slot:empty {
  display: none;
}

.contact-layout:not([data-agent-layout="both"]) .agent-card-slot-left,
.contact-layout:not([data-agent-layout="both"]) .agent-card-slot-right {
  display: none;
}

.contact-layout[data-agent-layout="both"] #agent-card-container {
  display: none;
}

.contact-layout .agent-card-slot .agent-card {
  margin: 0;
}

/* Force side-slot cards to fit narrow columns */
.contact-layout .agent-card-slot {
  min-width: 0;
  overflow: hidden;
}

.contact-layout .agent-card-slot .agent-card .agent-card-person {
  grid-template-columns: 1fr;
}

.contact-layout .agent-card-slot .agent-card .agent-card-media {
  max-width: 220px;
  margin: 0 auto;
}

.contact-layout .agent-card-slot .agent-card .agent-card-detail-grid {
  grid-template-columns: 1fr;
}

.contact-layout .agent-card-slot .agent-card .agent-card-copy h3 {
  font-size: clamp(22px, 3vw, 30px);
}

.contact-layout .agent-card-slot .agent-card .agent-card-brand {
  flex-wrap: wrap;
}

.contact-layout .agent-card-slot .agent-card .agent-card-website {
  white-space: normal;
  word-break: break-all;
}

.contact-layout .agent-card-slot .agent-card .agent-card-bio {
  max-width: 100%;
  overflow-wrap: break-word;
}

.contact-layout:not(.has-agent) {
  grid-template-columns: 1fr;
  max-width: 640px;
}

.contact-layout #agent-card-container:empty {
  display: none;
}

.contact-layout #agent-card-container .agent-card {
  margin: 0;
}

.contact-form-panel {
  width: 100%;
}

.contact-wrap h2 {
  color: var(--white);
  margin-bottom: 8px;
}

.contact-sub {
  color: var(--gold-accent);
  margin-bottom: 36px;
  font-size: 16px;
}

.form-group {
  margin-bottom: 16px;
  text-align: left;
  position: relative;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: rgba(255,255,255,0.7);
  margin-bottom: 4px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px;
  border: 1px solid rgba(255,255,255,0.3);
  background: transparent;
  color: var(--white);
  border-radius: 4px;
  font-family: inherit;
  font-size: 16px;
  transition: border-color 0.3s;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(255,255,255,0.4);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--gold-accent);
  outline: none;
  box-shadow: 0 0 0 3px rgba(202, 181, 145, 0.15);
}

.form-group textarea {
  resize: vertical;
}

.form-group input[readonly] {
  opacity: 0.7;
}

.form-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 20px;
  text-align: left;
}

.form-check input {
  accent-color: var(--gold-accent);
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 3px;
}

.form-check span {
  font-size: 13px;
  color: rgba(255,255,255,0.7);
  line-height: 1.5;
}

.consent-legal-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: -8px 0 18px;
}

.consent-legal-prefix {
  font-size: 12px;
  color: rgba(255,255,255,0.62);
  letter-spacing: 0.03em;
}

.consent-legal-helper {
  margin: -8px 0 18px;
  font-size: 12px;
  color: rgba(255,255,255,0.48);
}

.legal-link-button {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  width: 100%;
  padding: 0;
  border: none;
  background: none;
  color: rgba(255,255,255,0.64);
  font-size: 14px;
  line-height: 1.8;
  text-align: left;
  transition: color 0.25s ease, transform 0.25s ease;
}

.legal-link-button:hover {
  color: var(--gold-accent);
  transform: translateX(2px);
}

.legal-link-button.is-inline {
  width: auto;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(202, 181, 145, 0.14);
  color: var(--gold-accent);
  font-size: 12px;
  line-height: 1;
}

.legal-link-button.is-inline:hover {
  transform: none;
  background: rgba(202, 181, 145, 0.22);
}

.btn-submit {
  width: 100%;
  background: var(--gold-accent);
  color: var(--dark-bg);
  font-weight: 700;
  font-size: 16px;
  padding: 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s, transform 0.2s, box-shadow 0.3s;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  box-shadow: 0 4px 15px rgba(202, 181, 145, 0.3);
}

.btn-submit:hover {
  background: #D9C8A5;
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(202, 181, 145, 0.4);
}

.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.field-error {
  display: block;
  color: #EF5350;
  font-size: 12px;
  margin-top: 4px;
}

.form-banner {
  padding: 0;
  margin-top: 0;
  font-size: 15px;
  font-weight: 600;
  border-radius: 4px;
  text-align: center;
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.3s ease, padding 0.3s ease, margin-top 0.3s ease;
}

.form-banner.success {
  max-height: 100px;
  padding: 14px 20px;
  margin-top: 16px;
  background: rgba(76,175,80,0.15);
  color: #4CAF50;
}

.form-banner.error {
  max-height: 100px;
  padding: 14px 20px;
  margin-top: 16px;
  background: rgba(239,83,80,0.15);
  color: #EF5350;
}

.contact-info {
  margin-top: 36px;
  color: rgba(255,255,255,0.8);
  font-size: 15px;
  line-height: 2;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   8. FOOTER
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
footer {
  background: var(--dark-bg);
  border-top: 1px solid rgba(202, 181, 145, 0.25);
  padding: 70px 0 40px;
  position: relative;
}

footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: var(--gold-accent);
  border-radius: 2px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  margin-bottom: 40px;
}

.footer-col h4 {
  color: var(--gold-accent);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 16px;
}

.footer-col p,
.footer-col a {
  color: rgba(255,255,255,0.6);
  font-size: 14px;
  line-height: 2;
  display: block;
  transition: color 0.3s;
}

.footer-col a:hover {
  color: var(--gold-accent);
}

.footer-legal-links {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.footer-brand svg {
  width: 30px;
  height: 38px;
}

.footer-brand-name {
  color: var(--white);
  font-size: 16px;
  font-weight: 700;
}

.footer-tagline {
  color: var(--gold-accent);
  font-size: 13px;
  font-style: italic;
}

.footer-bottom {
  text-align: center;
  font-size: 13px;
  color: var(--gold-accent);
  border-top: 1px solid rgba(202,181,145,0.15);
  padding-top: 24px;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   RESPONSIVE
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 1024px) {
  :root {
    --side-padding: 40px;
    --section-padding: 80px;
  }
  .about-grid { grid-template-columns: 1fr; }
  .location-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { columns: 2; }
  .type-showcase-grid { grid-template-columns: repeat(2, 1fr); }
  .display-heading { font-size: 52px; }
  h1 { font-size: 36px; }

  .legal-modal-layout {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
  }

  .legal-modal-sidebar {
    border-right: none;
    border-bottom: 1px solid rgba(202, 181, 145, 0.12);
    padding: 30px 24px 20px;
  }

  .legal-modal-content {
    padding: 26px 24px 30px;
  }

  .legal-modal-nav {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .legal-modal-tab {
    width: auto;
  }
}

@media (max-width: 768px) {
  :root {
    --side-padding: 16px;
    --section-padding: 56px;
  }

  .display-heading { font-size: 36px; }
  h1 { font-size: 28px; }
  h2 { font-size: 24px; }
  h3 { font-size: 18px; }

  /* ── Navbar mobile ───────────────────────────── */
  #navbar {
    padding: 0 16px;
    height: 60px;
  }
  .nav-links, .nav-cta { display: none; }
  #hamburger-btn { display: block; }

  .nav-brand {
    gap: 8px;
    max-width: 65vw;
  }
  .nav-brand-text .brand-primary { font-size: 18px; }
  .nav-brand-text .brand-accent { font-size: 10px; }
  .nav-brand-text .brand-sep { font-size: 10px; }

  /* Mobile menu */
  #mobile-menu a {
    font-size: 20px;
    gap: 24px;
  }

  /* ── Hero ─────────────────────────────────────── */
  #hero {
    min-height: 100svh;
    min-height: 500px;
  }
  .hero-content {
    padding: 0 16px;
  }
  .hero-content .section-label {
    font-size: 11px;
    letter-spacing: 0.15em;
  }
  .hero-content .hero-sub {
    font-size: 16px;
    margin-bottom: 28px;
  }
  .hero-buttons {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
  }
  .hero-buttons .btn-primary,
  .hero-buttons .btn-gold-outline {
    width: 100%;
    padding: 14px 20px;
    font-size: 13px;
  }
  .scroll-arrow { bottom: 24px; }

  /* ── Section labels ──────────────────────────── */
  .section-label {
    font-size: 11px;
    letter-spacing: 0.15em;
    gap: 12px;
  }
  .section-label::before,
  .section-label::after {
    width: 28px;
  }

  /* ── About ───────────────────────────────────── */
  .about-text h2,
  .about-text p {
    text-align: left;
  }
  .about-features {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .about-features li {
    font-size: 14px;
    padding: 10px 12px;
  }
  .stats-grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .stat-card {
    padding: 20px 12px;
  }
  .stat-number { font-size: 32px; }
  .stat-label { font-size: 11px; }

  /* ── Offer section ───────────────────────────── */
  .offer-tabs { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .offer-tab-btn { padding: 10px 14px; font-size: 13px; white-space: nowrap; }

  /* Filters */
  .filters-bar,
  .apt-list-filters { grid-template-columns: 1fr; padding: 14px; }
  .filter-group-search { grid-column: auto; }
  .filter-group {
    padding: 12px;
  }
  .filter-group select,
  .filter-group input[type="text"] {
    padding: 10px 12px;
    font-size: 14px;
  }

  /* Map grid */
  .grid-cell { width: 56px; height: 52px; }
  .grid-cell.cell-premium { width: 84px; }
  .cell-id { font-size: 10px; }
  .cell-size { font-size: 9px; }
  .section-grid {
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  /* Apartment panel */
  .apartment-panel {
    max-height: none;
    border-radius: 14px;
    padding: 18px;
  }
  .detail-price { font-size: 26px; }
  .panel-actions {
    flex-direction: column;
  }
  .panel-actions .btn-primary,
  .panel-actions .btn-gold-outline {
    min-width: 0;
    width: 100%;
  }

  .step3-layout {
    flex-direction: column;
  }
  .step3-panel-col {
    width: 100%;
  }

  /* 3D map */
  .map3d-callout-panel {
    position: fixed;
    inset: auto 0 0 0;
    width: 100%;
    border-radius: 16px 16px 0 0;
    max-height: 60vh;
    overflow-y: auto;
    transform: translateY(100%);
  }
  .map3d-callout-panel.visible { transform: translateY(0); }
  .map3d-drilldown-body {
    grid-template-columns: 1fr;
  }
  .map3d-segment-detail {
    position: static;
    max-height: none;
  }
  .map3d-segments-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  }

  /* ── Location ────────────────────────────────── */
  .location-grid {
    gap: 32px;
  }
  .advantage-list li {
    font-size: 14px;
    padding: 6px 0;
  }
  #leaflet-map {
    height: 300px;
  }

  /* ── Gallery / Type showcase ─────────────────── */
  .gallery-grid { columns: 1; }
  .type-showcase-grid { grid-template-columns: 1fr; }
  .type-showcase-sub { font-size: 14px; margin-bottom: 24px; }
  .type-tile-images {
    grid-template-columns: 1fr;
    height: auto;
  }
  .type-detail-content {
    grid-template-columns: 1fr;
  }
  .type-detail-left {
    border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    padding: 20px;
  }
  .type-detail-right {
    padding: 20px;
  }
  .type-detail-stats {
    flex-wrap: wrap;
    gap: 10px;
  }

  /* ── Contact ─────────────────────────────────── */
  .contact-sub { font-size: 14px; margin-bottom: 24px; }
  .form-group input,
  .form-group textarea {
    padding: 12px;
    font-size: 16px; /* prevent iOS zoom */
  }
  .btn-submit {
    padding: 14px;
    font-size: 15px;
  }

  /* Agent card */
  .agent-card-brand {
    flex-direction: column;
    align-items: stretch;
  }
  .agent-card-person,
  .agent-card-detail-grid {
    grid-template-columns: 1fr;
  }
  .agent-card-count-2 .agent-card-people {
    grid-template-columns: 1fr;
  }
  .agent-card-media,
  .agent-card-person .agent-card-media {
    max-width: 200px;
    margin: 0 auto;
  }
  .agent-card-copy h3 {
    font-size: clamp(24px, 5vw, 32px);
  }
  .agent-card-bio { font-size: 14px; }
  .agent-card-shell { padding: 18px; }

  /* ── Footer ──────────────────────────────────── */
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  footer { padding: 48px 0 32px; }
  .footer-bottom { font-size: 12px; }

  /* ── Consent / Legal ─────────────────────────── */
  .consent-legal-links {
    gap: 6px;
  }

  .legal-modal-overlay {
    padding: 8px;
    align-items: flex-start;
  }

  .legal-modal {
    border-radius: 16px;
    height: auto;
    min-height: min(90vh, 920px);
  }

  .legal-modal-sidebar {
    padding: 24px 18px 16px;
  }

  .legal-modal-sidebar h2 {
    font-size: 24px;
  }

  .legal-modal-content {
    padding: 20px 18px 24px;
  }

  .legal-modal-close {
    top: 10px;
    right: 10px;
    width: 38px;
    height: 38px;
    font-size: 24px;
  }

  /* ── Diary ───────────────────────────────────── */
  .diary-grid {
    grid-template-columns: 1fr;
  }
  .diary-modal {
    padding: 20px;
    width: 95vw;
  }

  /* ── Buttons ─────────────────────────────────── */
  .btn-primary,
  .btn-gold-outline {
    padding: 12px 24px;
    font-size: 13px;
  }

  /* ── Map tooltip ─────────────────────────────── */
  .map-tooltip {
    max-width: calc(100vw - 32px);
    min-width: 180px;
  }

  /* ── Estate overview ─────────────────────────── */
  .estate-overview-map {
    min-height: 180px;
  }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   RESPONSIVE — SMALL MOBILE (≤480px)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 480px) {
  :root {
    --side-padding: 12px;
    --section-padding: 40px;
  }

  .display-heading { font-size: 28px; }
  h1 { font-size: 24px; }
  h2 { font-size: 20px; }

  /* Nav brand compact */
  #navbar { height: 56px; }
  .nav-brand { max-width: 55vw; gap: 6px; }
  .nav-brand-text .brand-primary { font-size: 16px; }
  .nav-brand[data-brand-mode="image-only"] .nav-brand-logo {
    max-width: min(200px, 40vw);
  }

  /* Hero */
  .hero-content .hero-sub { font-size: 14px; }
  .hero-buttons { max-width: 280px; }
  .hero-buttons .btn-primary,
  .hero-buttons .btn-gold-outline {
    padding: 12px 16px;
    font-size: 12px;
  }

  /* About features */
  .about-features li {
    font-size: 13px;
    padding: 8px 10px;
    gap: 10px;
  }
  .about-features li svg { width: 18px; height: 18px; }

  /* Stats */
  .stat-card { padding: 16px 10px; border-radius: 10px; }
  .stat-number { font-size: 28px; }
  .stat-label { font-size: 10px; letter-spacing: 0.08em; }

  /* Apartment detail */
  .apt-detail-grid { grid-template-columns: 1fr; }
  .detail-price { font-size: 22px; }

  /* Filters compact */
  .filters-bar,
  .apt-list-filters {
    padding: 10px;
    border-radius: 12px;
  }
  .filter-group {
    padding: 10px;
    border-radius: 12px;
  }
  .filter-group-title { font-size: 11px; }

  /* Map cells even smaller */
  .grid-cell { width: 48px; height: 44px; }
  .grid-cell.cell-premium { width: 72px; }
  .cell-id { font-size: 9px; }
  .cell-size { font-size: 8px; }

  /* Location */
  #leaflet-map { height: 250px; }
  .advantage-list li { font-size: 13px; }

  /* Type tiles compact */
  .type-tile-thumb { height: 160px; }
  .type-tile-info { padding: 12px; }
  .type-tile-name { font-size: 16px; }
  .type-tile-meta { font-size: 12px; }

  /* Type detail */
  .type-detail-modal { width: 96vw; }
  .type-detail-gallery {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  }

  /* Agent card compact */
  .agent-card { border-radius: 18px; }
  .agent-card-shell { padding: 14px; gap: 16px; }
  .agent-card-media { max-width: 160px; }
  .agent-card-copy h3 { font-size: clamp(20px, 5vw, 28px); }
  .agent-card-title { font-size: 12px; }
  .agent-card-line { padding: 10px 12px; }

  /* Contact */
  .contact-sub { font-size: 13px; }

  /* Footer */
  footer { padding: 36px 0 24px; }
  .footer-col h4 { font-size: 13px; margin-bottom: 10px; }
  .footer-col p,
  .footer-col a { font-size: 13px; }

  /* Legal modal very compact */
  .legal-modal { border-radius: 12px; }
  .legal-modal-sidebar { padding: 18px 14px 12px; }
  .legal-modal-content { padding: 16px 14px 20px; }
  .legal-modal-sidebar h2 { font-size: 22px; }
  .legal-modal-tab { padding: 10px 12px; font-size: 13px; }

  /* Diary */
  .diary-modal { padding: 16px; }
  .diary-card-img { height: 160px; }
  .diary-card-body { padding: 12px; }

  /* Lightbox */
  #lightbox-img {
    max-width: 95vw;
    max-height: 80vh;
  }
  .lb-prev { left: 8px; }
  .lb-next { right: 8px; }
  .lb-close { top: 12px; right: 12px; font-size: 28px; }
}

/* ═══════════════════════════════════════════════════════════
   9. OFFER TABS (3-tab system)
   ═══════════════════════════════════════════════════════════ */
.offer-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 24px;
  border-bottom: 2px solid rgba(202, 181, 145, 0.2);
}
.offer-tab-btn {
  padding: 12px 24px;
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.5);
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  transition: color 0.3s, border-color 0.3s;
  position: relative;
  bottom: -2px;
}
.offer-tab-btn:hover { color: rgba(255,255,255,0.8); }
.offer-tab-btn.active {
  color: var(--gold-accent);
  border-bottom-color: var(--gold-accent);
}
.offer-tab-panel { display: none; }
.offer-tab-panel.active { display: block; }

/* ═══════════════════════════════════════════════════════════
   10. 3D MAP
   ═══════════════════════════════════════════════════════════ */
.map3d-container {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  min-height: 500px;
  background: var(--dark-bg);
}
.map3d-container img.map3d-aerial {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.6s ease;
}
.map3d-container.zoomed img.map3d-aerial {
  transform: scale(1.5);
}

/* 3D Overview */
.map3d-image-wrap { position: relative; border-radius: 12px; overflow: hidden; }
.map3d-image-wrap img { width: 100%; display: block; }
.map3d-svg-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.map3d-zone-rect {
  transition: opacity 0.3s, stroke-width 0.2s;
}

/* 3D Drilldown */
.map3d-drilldown {
  padding: 20px;
}
.map3d-drilldown-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}
.map3d-drilldown-header h3 {
  color: var(--gold-accent);
  font-size: 20px;
}
.map3d-drilldown-body {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 20px;
}
.map3d-segments-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
}
.map3d-segment-card {
  background: rgba(255,255,255,0.05);
  border-radius: 8px;
  padding: 14px;
  transition: background 0.2s, transform 0.15s;
}
.map3d-segment-card:hover,
.map3d-segment-card.active {
  background: rgba(202, 181, 145, 0.12);
  transform: translateY(-2px);
}
.map3d-seg-title {
  font-weight: 700;
  font-size: 16px;
  color: #fff;
  margin-bottom: 6px;
}
.map3d-seg-stats {
  display: flex;
  gap: 8px;
  font-size: 12px;
  margin-bottom: 4px;
}
.map3d-seg-price {
  font-size: 13px;
  color: var(--gold-accent);
}
.map3d-segment-detail {
  background: rgba(26, 42, 23, 0.9);
  border: 1px solid var(--gold-accent);
  border-radius: 12px;
  padding: 20px;
  color: #fff;
  position: sticky;
  top: 100px;
  max-height: 500px;
  overflow-y: auto;
}
.map3d-segment-detail h4 {
  color: var(--gold-accent);
  font-size: 16px;
}
.map3d-detail-floors {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.map3d-floor-row {
  padding: 10px 12px;
  background: rgba(255,255,255,0.04);
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s;
  font-size: 13px;
  line-height: 1.6;
}
.map3d-floor-row:hover {
  background: rgba(255,255,255,0.08);
}

/* Legacy styles kept for compat */
.map3d-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.map3d-overlay svg { width: 100%; height: 100%; }
.map3d-callout-panel {
  position: absolute;
  right: 20px;
  top: 20px;
  width: 320px;
  background: rgba(26, 42, 23, 0.95);
  border: 1px solid var(--gold-accent);
  border-radius: 12px;
  padding: 20px;
  color: #fff;
  backdrop-filter: blur(10px);
  transform: translateX(120%);
  transition: transform 0.4s ease;
  z-index: 5;
}
.map3d-callout-panel.visible { transform: translateX(0); }
.map3d-callout-panel h3 {
  color: var(--gold-accent);
  margin-bottom: 12px;
  font-size: 18px;
}
.map3d-floor-band {
  padding: 10px 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  cursor: pointer;
  transition: background 0.2s;
}
.map3d-floor-band:hover { background: rgba(255,255,255,0.05); }
.map3d-floor-band:last-child { border-bottom: none; }
.map3d-floor-number {
  font-weight: 700;
  color: var(--gold-accent);
  font-size: 14px;
}
.map3d-floor-stats {
  font-size: 13px;
  color: rgba(255,255,255,0.7);
  margin-top: 4px;
}

/* ═══════════════════════════════════════════════════════════
   11. APARTMENT LIST TABLE
   ═══════════════════════════════════════════════════════════ */
.apt-list-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
}
.apt-list-table thead th {
  text-align: left;
  padding: 12px 10px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gold-accent);
  border-bottom: 2px solid rgba(202, 181, 145, 0.3);
}
.apt-list-table tbody tr {
  border-bottom: 1px solid rgba(255,255,255,0.05);
  transition: background 0.2s;
  cursor: pointer;
}
.apt-list-table tbody tr:hover {
  background: rgba(202, 181, 145, 0.05);
}
.apt-list-table td {
  padding: 10px;
  font-size: 14px;
  color: rgba(255,255,255,0.85);
}
.apt-list-status {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}
.apt-list-status.available { background: rgba(76, 175, 80, 0.2); color: #4CAF50; }
.apt-list-status.reserved { background: rgba(255, 152, 0, 0.2); color: #FF9800; }
.apt-list-status.sold { background: rgba(239, 83, 80, 0.2); color: #EF5350; }

/* Apartment list cards (mobile) */
.apt-list-cards { display: none; }

@media (max-width: 768px) {
  .apt-list-table { display: none; }
  .apt-list-cards { display: grid; gap: 12px; }
  .apt-list-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 16px;
  }
  .apt-list-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
  }
  .apt-list-card-id { font-weight: 700; color: var(--gold-accent); }
  .apt-list-card-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    font-size: 13px;
    color: rgba(255,255,255,0.7);
  }
}

/* List filters */
.apt-list-filters {
  margin-bottom: 16px;
}

.apt-list-empty {
  margin-top: 18px;
  padding: 36px 24px;
  border-radius: 18px;
  border: 1px dashed rgba(202,181,145,0.35);
  background: rgba(255,255,255,0.03);
  text-align: center;
  display: grid;
  gap: 8px;
  color: rgba(255,255,255,0.72);
}

.apt-list-empty strong {
  font-size: 18px;
  color: #fff;
}

/* Clickable rows in apartment list */
.apt-list-row-clickable { cursor: pointer; transition: background 0.15s; }
.apt-list-row-clickable:hover { background: rgba(202, 181, 145, 0.08); }
.apt-list-card { cursor: pointer; transition: border-color 0.15s; }
.apt-list-card:hover { border-color: var(--gold-accent); }

/* Apartment detail view */
.apt-detail-view { max-width: 640px; margin: 0 auto; }
.apt-detail-back {
  background: none; border: none; color: var(--gold-accent); cursor: pointer;
  font-family: var(--font-family); font-size: 14px; padding: 0; margin-bottom: 20px;
  display: inline-flex; align-items: center; gap: 4px;
}
.apt-detail-back:hover { text-decoration: underline; }
.apt-detail-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 24px;
}
.apt-detail-header h3 { margin: 0; color: #fff; font-size: 22px; }
.apt-detail-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
  margin-bottom: 24px;
}
.apt-detail-item {
  background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px; padding: 14px;
}
.apt-detail-label { display: block; font-size: 12px; color: rgba(255,255,255,0.5); margin-bottom: 4px; text-transform: uppercase; letter-spacing: 0.5px; }
.apt-detail-value { font-size: 16px; font-weight: 600; color: #fff; }
.apt-detail-price { color: var(--gold-accent); }
.apt-detail-features, .apt-detail-extras, .apt-detail-parking {
  margin-bottom: 20px;
}
.apt-detail-features h4, .apt-detail-extras h4, .apt-detail-parking h4 {
  color: var(--gold-accent); font-size: 14px; margin: 0 0 8px; text-transform: uppercase; letter-spacing: 0.5px;
}
.apt-detail-features ul, .apt-detail-extras ul, .apt-detail-parking ul {
  list-style: none; padding: 0; margin: 0;
}
.apt-detail-features li, .apt-detail-extras li, .apt-detail-parking li {
  padding: 6px 0; color: rgba(255,255,255,0.8); font-size: 14px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.apt-detail-reserve { margin-top: 20px; width: 100%; padding: 14px; font-size: 15px; }

@media (max-width: 480px) {
  .apt-detail-grid { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════════
   12. CONSTRUCTION DIARY
   ═══════════════════════════════════════════════════════════ */
#dziennik {
  padding: 80px 0;
  background: var(--light-bg);
}
.diary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
  margin-top: 24px;
}
.diary-card {
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  border: 1px solid transparent;
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
  cursor: pointer;
}
.diary-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 36px rgba(0,0,0,0.12);
  border-color: rgba(202, 181, 145, 0.25);
}
.diary-card-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.diary-card-body { padding: 16px; }
.diary-card-body h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--green-primary);
  margin-bottom: 6px;
}
.diary-card-body p {
  font-size: 14px;
  color: #555;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.diary-date-badge {
  display: inline-block;
  padding: 4px 12px;
  background: var(--green-primary);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  border-radius: 20px;
  margin-bottom: 8px;
}
.diary-no-photo {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, var(--green-primary), var(--dark-bg));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-accent);
  font-size: 40px;
}

/* Diary modal */
.diary-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}
.diary-modal-overlay.active { opacity: 1; visibility: visible; }
.diary-modal {
  background: #fff;
  border-radius: 16px;
  max-width: 700px;
  width: 90vw;
  max-height: 90vh;
  overflow-y: auto;
  padding: 32px;
}
.diary-modal h2 {
  color: var(--green-primary);
  margin-bottom: 4px;
}
.diary-modal-date {
  color: #888;
  font-size: 14px;
  margin-bottom: 16px;
}
.diary-modal-body {
  font-size: 15px;
  line-height: 1.7;
  color: #333;
  margin-bottom: 20px;
}
.diary-modal-photos {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
}
.diary-modal-photos img {
  width: 100%;
  border-radius: 8px;
  cursor: pointer;
  transition: transform 0.3s;
}
.diary-modal-photos img:hover { transform: scale(1.03); }
.diary-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: #666;
}

.legal-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 10, 8, 0.84);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 1400;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.28s ease, visibility 0.28s ease;
  backdrop-filter: blur(8px);
  overscroll-behavior: contain;
}

.legal-modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.legal-modal {
  position: relative;
  width: min(1120px, 100%);
  height: min(88vh, 920px);
  min-height: 0;
  overflow: hidden;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(12, 26, 19, 0.98), rgba(9, 18, 14, 0.98));
  border: 1px solid rgba(202, 181, 145, 0.22);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.38);
  margin: auto;
}

.legal-modal-layout {
  display: grid;
  grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
  height: 100%;
  min-height: 0;
}

.legal-modal-sidebar {
  padding: 36px 28px;
  border-right: 1px solid rgba(202, 181, 145, 0.12);
  background: linear-gradient(180deg, rgba(255,255,255,0.03), transparent 65%);
  min-height: 0;
}

.legal-modal-eyebrow {
  display: inline-block;
  margin-bottom: 14px;
  color: var(--gold-accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.legal-modal-sidebar h2 {
  margin-bottom: 12px;
  color: var(--white);
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.05;
}

.legal-modal-intro {
  color: rgba(245, 240, 232, 0.72);
  font-size: 14px;
  line-height: 1.7;
}

.legal-modal-nav {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 26px;
}

.legal-modal-tab {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid rgba(202, 181, 145, 0.12);
  border-radius: 16px;
  background: rgba(255,255,255,0.03);
  color: rgba(245, 240, 232, 0.78);
  font-size: 14px;
  font-weight: 600;
  text-align: left;
  transition: border-color 0.25s ease, background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.legal-modal-tab:hover,
.legal-modal-tab.active {
  border-color: rgba(202, 181, 145, 0.34);
  background: rgba(202, 181, 145, 0.12);
  color: var(--white);
  transform: translateX(3px);
}

.legal-modal-content {
  padding: 36px 36px 42px;
  overflow-y: auto;
  min-height: 0;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}

.legal-doc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.legal-doc-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(202, 181, 145, 0.12);
  color: var(--gold-accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.legal-modal-content h3 {
  color: var(--white);
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.12;
}

.legal-doc-subtitle {
  margin-top: 10px;
  color: rgba(245, 240, 232, 0.72);
  font-size: 16px;
  line-height: 1.65;
}

.legal-doc-intro {
  margin-top: 22px;
  color: rgba(245, 240, 232, 0.82);
  font-size: 15px;
  line-height: 1.9;
}

.legal-doc-intro p,
.legal-section-body p {
  margin-bottom: 14px;
}

.legal-doc-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.legal-doc-highlight {
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: 14px;
  background: rgba(255,255,255,0.05);
  color: var(--white);
  font-size: 13px;
  line-height: 1.45;
}

.legal-doc-sections {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 28px;
}

.legal-section-card {
  padding: 20px 22px;
  border-radius: 18px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(202, 181, 145, 0.1);
}

.legal-section-card h4 {
  margin-bottom: 10px;
  color: var(--gold-accent);
  font-size: 15px;
  letter-spacing: 0.03em;
}

.legal-section-body {
  color: rgba(245, 240, 232, 0.82);
  font-size: 15px;
  line-height: 1.9;
}

.legal-doc-contact {
  margin-top: 28px;
  padding: 18px 20px;
  border-radius: 18px;
  background: rgba(202, 181, 145, 0.09);
  color: rgba(245, 240, 232, 0.86);
  font-size: 14px;
  line-height: 1.75;
}

.legal-doc-contact strong {
  display: block;
  margin-bottom: 6px;
  color: var(--gold-accent);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.legal-doc-contact a {
  color: var(--white);
}

.legal-modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(202, 181, 145, 0.22);
  background: rgba(255,255,255,0.04);
  color: var(--gold-accent);
  font-size: 28px;
  line-height: 1;
  z-index: 2;
}

.legal-modal-close:hover {
  background: rgba(202, 181, 145, 0.14);
}

/* ═══════════════════════════════════════════════════════════
   13. AGENT CARD (public)
   ═══════════════════════════════════════════════════════════ */
.agent-card {
  --agent-card-bg: #143122;
  --agent-card-surface: #0f2419;
  --agent-card-accent: #d8bd8b;
  --agent-card-text: #f7f3ea;
  --agent-card-muted: #ced4c8;
  --agent-card-border: #9d8b63;
  --agent-card-overlay: #07120d;
  --agent-card-overlay-opacity: 0.52;
  --agent-card-heading-font: 'Playfair Display', serif;
  --agent-card-body-font: 'DM Sans', sans-serif;
  --agent-card-logo-width: 132px;
  --agent-card-photo-radius: 28px;
  --agent-card-bg-image: none;
  position: relative;
  overflow: hidden;
  margin-top: 32px;
  margin-bottom: 24px;
  border-radius: 28px;
  border: 1px solid rgba(255,255,255,0.08);
  background: var(--agent-card-bg);
  color: var(--agent-card-text);
  box-shadow: 0 24px 70px rgba(0,0,0,0.24);
  font-family: var(--agent-card-body-font);
}

.agent-card-backdrop,
.agent-card-overlay-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.agent-card-backdrop {
  background-image: var(--agent-card-bg-image);
  background-size: cover;
  background-position: center;
  opacity: 0.62;
}

.agent-card-overlay-layer {
  background: linear-gradient(135deg, rgba(255,255,255,0.08), transparent 55%), var(--agent-card-overlay);
  opacity: var(--agent-card-overlay-opacity);
}

.agent-card-shell {
  position: relative;
  z-index: 1;
  min-height: 100%;
  padding: clamp(22px, 4vw, 32px);
  display: grid;
  gap: 24px;
  background: linear-gradient(135deg, rgba(255,255,255,0.06), transparent 58%), var(--agent-card-surface);
}

.agent-card-brand {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.agent-card-brand-lockup {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.agent-card-logo {
  width: min(100%, var(--agent-card-logo-width));
  max-width: var(--agent-card-logo-width);
  max-height: 70px;
  object-fit: contain;
}

.agent-card-logo-fallback {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.14);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--agent-card-heading-font);
  font-size: 22px;
  color: var(--agent-card-accent);
  flex-shrink: 0;
}

.agent-card-kicker {
  display: block;
  margin-bottom: 6px;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--agent-card-accent);
}

.agent-card-company {
  font-family: var(--agent-card-heading-font);
  font-size: clamp(18px, 2vw, 24px);
  line-height: 1.1;
  color: var(--agent-card-text);
}

.agent-card-website {
  align-self: flex-start;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.04);
  color: var(--agent-card-accent);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

.agent-card-website:hover {
  background: rgba(255,255,255,0.08);
}

.agent-card-people {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.agent-card-count-2 .agent-card-people {
  grid-template-columns: 1fr 1fr;
}

.agent-card-person {
  display: grid;
  grid-template-columns: minmax(140px, 180px) 1fr;
  gap: 20px;
  align-items: start;
}

.agent-card-count-1 .agent-card-person {
  grid-template-columns: minmax(180px, 220px) 1fr;
  align-items: center;
}

.agent-card-layout-stacked .agent-card-person {
  grid-template-columns: 1fr;
}

.agent-card-layout-stacked .agent-card-person .agent-card-media {
  max-width: 220px;
}

.agent-card-count-2.agent-card-layout-stacked .agent-card-person .agent-card-media {
  max-width: 180px;
}

.agent-card-shared-details {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 16px;
}

.agent-card-media {
  width: 100%;
}

.agent-card-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: top center;
  border: none;
  border-bottom: 1px solid rgba(255,255,255,0.14);
  border-radius: 0;
  box-shadow: none;
}

.agent-card-photo-placeholder {
  width: 100%;
  aspect-ratio: 4 / 5;
  border: none;
  border-bottom: 1px solid rgba(255,255,255,0.14);
  border-radius: 0;
  background: linear-gradient(145deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--agent-card-heading-font);
  font-size: clamp(28px, 4vw, 42px);
  color: var(--agent-card-accent);
}

.agent-card-copy h3 {
  margin: 0;
  font-family: var(--agent-card-heading-font);
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.05;
  color: var(--agent-card-text);
}

.agent-card-count-2 .agent-card-copy h3 {
  font-size: clamp(22px, 3vw, 30px);
}

.agent-card-title {
  margin-top: 8px;
  color: var(--agent-card-accent);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.agent-card-count-2 .agent-card-title {
  font-size: 13px;
}

.agent-card-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.agent-card-count-2 .agent-card-person .agent-card-detail-grid {
  grid-template-columns: 1fr;
}

.agent-card-line {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.04);
}

.agent-card-line-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--agent-card-muted);
}

.agent-card-line-value {
  color: var(--agent-card-text);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  word-break: break-word;
}

.agent-card-line a.agent-card-line-value:hover {
  color: var(--agent-card-accent);
}

.agent-card-bio {
  margin-top: 18px;
  max-width: 54ch;
  color: var(--agent-card-muted);
  line-height: 1.75;
  font-size: 15px;
}

/* ── Compact agent cards on medium screens (Safari-safe) ── */
@media (max-width: 1400px) {
  .contact-wrap.has-both-agents {
    max-width: 100%;
  }

  .contact-layout[data-agent-layout="both"] {
    grid-template-columns: min(220px, 30vw) minmax(0, 1fr) min(220px, 30vw);
    gap: 16px;
  }

  /* Hide heavy parts — keep name, title, phone, photo */
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-brand,
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-bio,
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-shared-details,
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-website {
    display: none;
  }

  /* Compact card shell */
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-shell {
    padding: 16px;
    gap: 12px;
  }

  /* Horizontal: small square photo left, info right, details below */
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-person {
    grid-template-columns: 72px 1fr;
    gap: 10px 14px;
    align-items: center;
    text-align: left;
  }

  /* Break .agent-card-copy so children participate in person grid */
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-copy {
    display: contents;
  }

  /* Photo spans both name rows */
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-media {
    grid-column: 1;
    grid-row: 1 / 3;
    max-width: 72px;
    margin: 0;
    align-self: center;
  }

  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-photo,
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-photo-placeholder {
    aspect-ratio: 1;
  }

  /* Name next to photo */
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-copy h3 {
    grid-column: 2;
    grid-row: 1;
    align-self: end;
    font-size: clamp(16px, 2vw, 22px);
  }

  /* Title next to photo, below name */
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-title {
    grid-column: 2;
    grid-row: 2;
    align-self: start;
    font-size: 11px;
  }

  /* Detail grid (phone, email) below — full width */
  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-detail-grid {
    grid-column: 1 / -1;
    grid-row: 3;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-top: 4px;
  }

  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card-line {
    padding: 6px 10px;
    border-radius: 10px;
  }

  .contact-layout[data-agent-layout="both"] .agent-card-slot .agent-card {
    border-radius: 18px;
  }
}

@media (max-width: 1024px) {
  .contact-layout[data-agent-layout="both"] {
    grid-template-columns: 1fr 1fr;
    max-width: 800px;
  }

  .contact-layout[data-agent-layout="both"] .agent-card-slot-left { order: 1; }
  .contact-layout[data-agent-layout="both"] .agent-card-slot-right { order: 2; }
  .contact-layout[data-agent-layout="both"] .contact-form-panel {
    order: 3;
    grid-column: 1 / -1;
  }
}

@media (max-width: 768px) {
  .contact-layout,
  .contact-layout[data-agent-layout="left"],
  .contact-layout[data-agent-layout="right"],
  .contact-layout[data-agent-layout="both"] {
    grid-template-columns: 1fr;
    max-width: 640px;
  }

  .contact-layout[data-agent-layout="both"] .agent-card-slot {
    margin-top: 0;
  }

  .contact-layout[data-agent-layout="right"] #agent-card-container,
  .contact-layout[data-agent-layout="right"] .contact-form-panel {
    order: initial;
  }

  .contact-layout[data-agent-layout="both"] .agent-card-slot-left { order: 1; }
  .contact-layout[data-agent-layout="both"] .contact-form-panel { order: 3; }
  .contact-layout[data-agent-layout="both"] .agent-card-slot-right { order: 2; }

  .offer-tabs { overflow-x: auto; }
  .offer-tab-btn { padding: 10px 16px; font-size: 13px; white-space: nowrap; }
  .map3d-callout-panel {
    position: fixed;
    inset: auto 0 0 0;
    width: 100%;
    border-radius: 16px 16px 0 0;
    max-height: 60vh;
    overflow-y: auto;
    transform: translateY(100%);
  }
  .map3d-callout-panel.visible { transform: translateY(0); }
  .map3d-drilldown-body {
    grid-template-columns: 1fr;
  }
  .map3d-segment-detail {
    position: static;
    max-height: none;
  }
  .type-showcase-grid {
    grid-template-columns: 1fr;
  }
  .type-tile-images {
    grid-template-columns: 1fr;
    height: auto;
  }
  .type-detail-content {
    grid-template-columns: 1fr;
  }
  .agent-card-brand {
    flex-direction: column;
    align-items: stretch;
  }
  .agent-card-person,
  .agent-card-detail-grid {
    grid-template-columns: 1fr;
  }
  .agent-card-count-2 .agent-card-people {
    grid-template-columns: 1fr;
  }
  .agent-card-media,
  .agent-card-person .agent-card-media {
    max-width: 220px;
    margin: 0 auto;
  }
  .agent-card-copy {
    text-align: left;
  }
}

@media (max-width: 1200px) {
  .filters-bar {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  }

  #offer-tab-plan[data-filters-placement="left"] .offer-plan-layout,
  #offer-tab-plan[data-filters-placement="right"] .offer-plan-layout {
    grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  }

  .filters-bar .filter-group[data-filter-group="size"],
  .filters-bar .filter-group[data-filter-group="price"] {
    grid-column: span 2;
  }

  .section-photo-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 768px) {
  .offer-plan-layout,
  #offer-tab-plan[data-filters-placement="left"] .offer-plan-layout,
  #offer-tab-plan[data-filters-placement="right"] .offer-plan-layout {
    grid-template-columns: 1fr;
  }

  .filters-bar {
    grid-template-columns: 1fr;
    padding: 16px;
  }

  #offer-tab-plan[data-filters-placement="right"] .filters-bar,
  #offer-tab-plan[data-filters-placement="right"] .offer-plan-map {
    order: initial;
  }

  #oferta .container[data-filters-placement] .filters-bar,
  #oferta .container[data-filters-placement] .apt-list-filters {
    width: 100%;
    margin-inline: auto;
  }

  .filters-bar .filter-group[data-filter-group="size"],
  .filters-bar .filter-group[data-filter-group="price"] {
    grid-column: span 1;
  }
}

/* ═══════════════════════════════════════════════════════════
   14. LIGHT THEME OVERRIDES
   ═══════════════════════════════════════════════════════════ */
[data-theme="light"] #navbar {
  background: rgba(245, 240, 232, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(58,96,50,0.1);
}
[data-theme="light"] .nav-brand-text,
[data-theme="light"] .nav-link { color: var(--green-primary); }
[data-theme="light"] .nav-brand-logo { filter: none; }
[data-theme="light"] #mobile-menu { background: #F5F0E8; }
[data-theme="light"] #mobile-menu a { color: var(--green-primary); }
[data-theme="light"] #hero::before {
  background: linear-gradient(
    180deg,
    rgba(26, 42, 23, 0.2) 0%,
    rgba(26, 42, 23, 0.35) 40%,
    rgba(26, 42, 23, 0.55) 100%
  );
}
[data-theme="light"] #hero::after {
  background: linear-gradient(to top, var(--light-bg), transparent);
}
[data-theme="light"] .hero-content .display-heading {
  color: #FFFFFF;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.4);
}
[data-theme="light"] .hero-content .hero-sub {
  color: var(--gold-accent);
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.3);
}
[data-theme="light"] .hero-content .section-label {
  color: var(--gold-accent);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.3);
}
[data-theme="light"] .hero-content .section-label::before,
[data-theme="light"] .hero-content .section-label::after {
  background: var(--gold-accent);
}
[data-theme="light"] #oferta { background: #F5F0E8; }
[data-theme="light"] #oferta h2 { color: var(--green-primary); }
[data-theme="light"] .map-counter {
  color: #6f5730;
  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(58,96,50,0.12);
  border-radius: 999px;
  padding: 10px 16px;
  width: fit-content;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  box-shadow: 0 10px 28px rgba(58,96,50,0.08);
}
[data-theme="light"] .map-counter strong { color: var(--green-primary); }
[data-theme="light"] .map-section-title { color: var(--green-primary); }
[data-theme="light"] .grid-cell { color: #fff; }
[data-theme="light"] .offer-tab-btn { color: rgba(58,96,50,0.5); }
[data-theme="light"] .offer-tab-btn.active { color: var(--gold-accent); }
[data-theme="light"] #galeria { background: var(--green-primary); }
[data-theme="light"] #galeria h2 { color: #fff; }
[data-theme="light"] #galeria .section-label { color: var(--gold-accent); }
[data-theme="light"] #galeria .section-label::before,
[data-theme="light"] #galeria .section-label::after { background: var(--gold-accent); }
[data-theme="light"] #kontakt { background: var(--green-primary); }
[data-theme="light"] #kontakt .contact-wrap h2 { color: #FFFFFF; }
[data-theme="light"] #kontakt .contact-sub { color: var(--gold-accent); }
[data-theme="light"] #kontakt .form-group label { color: rgba(255,255,255,0.7); }
[data-theme="light"] #kontakt .form-group input,
[data-theme="light"] #kontakt .form-group textarea {
  color: #FFFFFF;
  border-color: rgba(255,255,255,0.3);
}
[data-theme="light"] #kontakt .form-group input::placeholder,
[data-theme="light"] #kontakt .form-group textarea::placeholder {
  color: rgba(255,255,255,0.4);
}
[data-theme="light"] #kontakt .form-check span { color: rgba(255,255,255,0.7); }
[data-theme="light"] #kontakt .consent-legal-prefix { color: rgba(255,255,255,0.62); }
[data-theme="light"] #kontakt .consent-legal-helper { color: rgba(255,255,255,0.55); }
[data-theme="light"] #kontakt .legal-link-button.is-inline { color: #1A2A17; background: rgba(255,255,255,0.92); }
[data-theme="light"] #kontakt .legal-link-button.is-inline:hover { background: #FFFFFF; }
[data-theme="light"] #kontakt .contact-info { color: rgba(255,255,255,0.8); }
[data-theme="light"] #kontakt .btn-submit {
  background: var(--gold-accent);
  color: #1A2A17;
}
[data-theme="light"] footer { background: #1A2A17; }
[data-theme="light"] .footer-bottom { color: var(--gold-accent); }
[data-theme="light"] .legal-modal { background: linear-gradient(180deg, rgba(17, 35, 26, 0.98), rgba(13, 26, 19, 0.98)); }
[data-theme="light"] .filters-bar { background: rgba(58,96,50,0.06); border-color: rgba(58,96,50,0.12); }
[data-theme="light"] .apt-list-filters { background: rgba(58,96,50,0.08); border-color: rgba(58,96,50,0.12); }
[data-theme="light"] .filters-bar .filter-group { background: none; border-color: transparent; }
[data-theme="light"] .apt-list-filters .filter-group { background: rgba(255,255,255,0.72); border-color: rgba(58,96,50,0.12); }
[data-theme="light"] .filter-group,
[data-theme="light"] .filter-group label { color: var(--green-primary); }
[data-theme="light"] .filter-group select,
[data-theme="light"] .filter-group input[type="text"] { background: rgba(58,96,50,0.06); color: var(--text-body); border-color: rgba(58,96,50,0.2); }
[data-theme="light"] .filter-choice-wrap label { background: rgba(58,96,50,0.04); border-color: rgba(58,96,50,0.12); }
[data-theme="light"] .apt-list-table td { color: var(--text-body); }
[data-theme="light"] .apt-list-empty { background: rgba(58,96,50,0.04); color: rgba(26,42,23,0.68); border-color: rgba(58,96,50,0.24); }
[data-theme="light"] .apt-list-empty strong { color: var(--green-primary); }
[data-theme="light"] #dziennik { background: #fff; }
[data-theme="light"] .apartment-panel { background: #F5F0E8; border-color: var(--gold-accent); }
[data-theme="light"] .apartment-panel .detail-row { color: var(--text-body); }
[data-theme="light"] .apartment-panel .apartment-summary-row span { color: rgba(26,42,23,0.35); }
[data-theme="light"] .apartment-panel .parking-toggle { color: var(--text-body); }
[data-theme="light"] .panel-close { color: var(--gold-accent); }
[data-theme="light"] .section-grid-card,
[data-theme="light"] .section-photo-card,
[data-theme="light"] .seg-photos-gallery { background: rgba(255,255,255,0.82); border-color: rgba(58,96,50,0.14); }
[data-theme="light"] .section-photo-header p { color: rgba(26,42,23,0.66); }
[data-theme="light"] .type-tile { background: rgba(255,255,255,0.9); border-color: rgba(58,96,50,0.14); }
[data-theme="light"] .type-tile:hover { background: #FFFFFF; }
[data-theme="light"] .type-tile-name { color: var(--green-primary); }
[data-theme="light"] .type-tile-meta { color: rgba(26,42,23,0.68); }
[data-theme="light"] .type-tile-price { color: #7a6036; }
[data-theme="light"] .type-tile-avail { color: rgba(26,42,23,0.68); }
[data-theme="light"] .type-feat-tag { background: rgba(202,181,145,0.24); color: #6f5730; }
[data-theme="light"] .type-detail-modal {
  background: linear-gradient(180deg, #FFFFFF, #F6F1E7);
  border-color: rgba(58,96,50,0.14);
}
[data-theme="light"] .type-detail-left { border-right-color: rgba(58,96,50,0.12); }
[data-theme="light"] .type-detail-right h2,
[data-theme="light"] .type-detail-no-images,
[data-theme="light"] .type-tile-badge {
  color: var(--green-primary);
}
[data-theme="light"] .type-detail-desc,
[data-theme="light"] .type-stat-label,
[data-theme="light"] .type-badge,
[data-theme="light"] .type-detail-rooms td:first-child,
[data-theme="light"] .type-detail-rooms td {
  color: rgba(26,42,23,0.72);
}
[data-theme="light"] .type-stat {
  background: rgba(58,96,50,0.06);
  border: 1px solid rgba(58,96,50,0.08);
}
[data-theme="light"] .type-stat-val,
[data-theme="light"] .type-detail-price,
[data-theme="light"] .type-detail-rooms td:last-child,
[data-theme="light"] .type-detail-left h4,
[data-theme="light"] .type-detail-rooms h4,
[data-theme="light"] .type-detail-features h4,
[data-theme="light"] .type-detail-close {
  color: #7a6036;
}
[data-theme="light"] .type-badge {
  background: rgba(58,96,50,0.06);
  border: 1px solid rgba(58,96,50,0.08);
}
[data-theme="light"] .type-detail-gallery img:hover { box-shadow: 0 8px 24px rgba(58,96,50,0.18); }
[data-theme="light"] .type-detail-cta.btn-primary {
  color: #FFFFFF;
}
[data-theme="light"] .type-detail-cta.btn-primary:hover {
  color: var(--green-primary);
}

[data-theme="light"] .stat-card {
  background: rgba(255,255,255,0.95);
  border-color: rgba(58,96,50,0.12);
  box-shadow: 0 12px 32px rgba(58,96,50,0.08);
}
[data-theme="light"] .stat-number { color: #24411d; }
[data-theme="light"] .stat-label { color: #7a6036; }

[data-theme="light"] .legal-modal {
  background: linear-gradient(180deg, #FFFFFF, #F6F1E7);
  border-color: rgba(58,96,50,0.14);
}
[data-theme="light"] .legal-modal-sidebar {
  border-right-color: rgba(58,96,50,0.12);
  background: linear-gradient(180deg, rgba(58,96,50,0.04), rgba(255,255,255,0));
}
[data-theme="light"] .legal-modal-sidebar h2,
[data-theme="light"] .legal-modal-content h3,
[data-theme="light"] .legal-section-card h4,
[data-theme="light"] .legal-doc-contact a {
  color: var(--green-primary);
}
[data-theme="light"] .legal-modal-intro,
[data-theme="light"] .legal-doc-subtitle,
[data-theme="light"] .legal-doc-intro,
[data-theme="light"] .legal-section-body,
[data-theme="light"] .legal-doc-contact {
  color: rgba(26,42,23,0.74);
}
[data-theme="light"] .legal-modal-tab {
  background: rgba(58,96,50,0.05);
  border-color: rgba(58,96,50,0.12);
  color: rgba(26,42,23,0.72);
}
[data-theme="light"] .legal-modal-tab:hover,
[data-theme="light"] .legal-modal-tab.active {
  background: rgba(154,123,79,0.14);
  border-color: rgba(154,123,79,0.36);
  color: var(--green-primary);
}
[data-theme="light"] .legal-doc-meta-chip,
[data-theme="light"] .legal-doc-contact strong {
  color: #7a6036;
}
[data-theme="light"] .legal-doc-highlight,
[data-theme="light"] .legal-section-card,
[data-theme="light"] .legal-doc-contact {
  background: rgba(58,96,50,0.05);
  border-color: rgba(58,96,50,0.08);
}
[data-theme="light"] .legal-modal-close {
  background: rgba(58,96,50,0.05);
  border-color: rgba(58,96,50,0.12);
  color: #7a6036;
}

/* Light theme: ensure offer section text stays readable */
[data-theme="light"] #oferta .offer-tab-btn { color: rgba(26,42,23,0.5); }
[data-theme="light"] #oferta .offer-tab-btn.active { color: var(--gold-accent); }
[data-theme="light"] #oferta .filter-group,
[data-theme="light"] #oferta .filter-group label { color: var(--text-body); }
[data-theme="light"] #oferta .filter-group select,
[data-theme="light"] #oferta .filter-group input[type="text"] { color: var(--text-body); }
[data-theme="light"] #oferta .filter-group-title { color: var(--gold-accent); }
[data-theme="light"] .apt-list-table thead th { color: var(--gold-accent); }

/* Light theme: btn-primary on light bg needs correct text */
[data-theme="light"] .btn-primary {
  color: #FFFFFF;
  border-color: var(--green-primary);
}
[data-theme="light"] .btn-primary:hover {
  color: var(--green-primary);
  background: transparent;
}

/* Light theme: hero buttons override (on dark overlay) */
[data-theme="light"] .hero-buttons .btn-primary {
  background: var(--gold-accent);
  border-color: var(--gold-accent);
  color: #1A2A17;
}
[data-theme="light"] .hero-buttons .btn-primary:hover {
  background: transparent;
  color: #FFFFFF;
  border-color: #FFFFFF;
}
[data-theme="light"] .hero-buttons .btn-gold-outline {
  color: #FFFFFF;
  border-color: #FFFFFF;
}
[data-theme="light"] .hero-buttons .btn-gold-outline:hover {
  background: #FFFFFF;
  color: var(--green-primary);
}

/* ═══════════════════════════════════════════════════════════
   15. SEGMENT PHOTOS GALLERY
   ═══════════════════════════════════════════════════════════ */
.seg-photos-gallery {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid rgba(202,181,145,0.2);
}
.seg-photos-group { margin-bottom: 16px; }
.seg-photos-group h4 {
  color: var(--gold-accent);
  font-size: 14px;
  margin-bottom: 8px;
}
.seg-photos-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.seg-photo-thumb {
  width: 100px;
  height: 70px;
  object-fit: cover;
  border-radius: 6px;
  cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s;
  border: 1px solid rgba(202,181,145,0.2);
}
.seg-photo-thumb:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

/* ═══════════════════════════════════════════════════════════
   2D Zone Map (Plan osiedla with admin zones)
   ═══════════════════════════════════════════════════════════ */
.map2d-zone-wrap {
  position: relative;
  aspect-ratio: var(--map2d-aspect-ratio, 21 / 4);
  width: 100%;
  max-width: 100%;
  margin-inline: auto;
  border-radius: 12px;
  overflow: hidden;
  min-height: 0;
  background-color: #18261d;
  background-image: var(--map2d-placeholder, none);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.map2d-zone-wrap::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, rgba(202, 181, 145, 0.08), rgba(202, 181, 145, 0) 42%),
    linear-gradient(180deg, rgba(26, 42, 23, 0.18), rgba(26, 42, 23, 0.38));
  opacity: 1;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.map2d-zone-wrap.is-ready::before {
  opacity: 0;
}

.map2d-zone-wrap img,
.map2d-aerial {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
  opacity: 1;
  transition: opacity 0.16s ease;
}

.map2d-svg-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 1;
  transition: opacity 0.16s ease;
}

.map2d-zone {
  transition: opacity 0.3s, stroke-width 0.2s;
}
.map-zone-status-layer {
  transition: opacity 0.2s ease;
}
.map-zone-status-pill,
.map2d-zone-label-badge {
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.3));
}
.map-zone-status-pill text {
  letter-spacing: 0.01em;
  paint-order: stroke;
  stroke: rgba(26, 42, 23, 0.72);
  stroke-width: 1.6px;
  stroke-linejoin: round;
}
.map-zone-status-pill .status-pill-header {
  font-weight: 800;
}
.map-zone-status-pill .status-pill-line {
  font-weight: 700;
}
.map-zone-status-pill .status-pill-icon {
  stroke-width: 1.1px;
}

/* ═══════════════════════════════════════════════════════════
   LOADING SCREEN
   ═══════════════════════════════════════════════════════════ */
#page-loader {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
#page-loader.fade-out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
#page-loader img {
  max-width: 320px;
  width: 60vw;
  height: auto;
}
#page-loader .loader-bar {
  width: 120px;
  height: 3px;
  background: #e8e3da;
  border-radius: 3px;
  margin-top: 32px;
  overflow: hidden;
}
#page-loader .loader-bar-inner {
  width: 40%;
  height: 100%;
  background: #CAB591;
  border-radius: 3px;
  animation: loaderSlide 1.2s ease-in-out infinite;
}
@keyframes loaderSlide {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(350%); }
}
