/* ==========================================================================
   Components
   ========================================================================== */

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 0.9em 1.8em;
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast), color var(--transition-fast), border-color var(--transition-fast);
  white-space: nowrap;
  line-height: 1;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--color-black); color: var(--color-white); }
.btn-primary:hover { background: var(--color-red); box-shadow: var(--shadow-md); }

.btn-accent { background: linear-gradient(135deg, var(--color-accent-light), var(--color-accent) 60%, var(--color-accent-dark)); color: var(--color-black); }
.btn-accent:hover { box-shadow: var(--shadow-accent); }

.btn-outline { background: transparent; color: var(--color-text); border-color: currentColor; }
.btn-outline:hover { background: var(--color-black); color: var(--color-white); border-color: var(--color-black); }

.btn-outline-light { background: transparent; color: var(--color-white); border-color: rgba(255,255,255,0.5); }
.btn-outline-light:hover { background: var(--color-white); color: var(--color-black); border-color: var(--color-white); }

.btn-ghost { background: transparent; color: var(--color-text); padding-inline: 0.4em; text-transform: none; letter-spacing: var(--ls-normal); font-weight: 500; }
.btn-ghost:hover { color: var(--color-red); transform: none; }

.btn-whatsapp { background: #25d366; color: #fff; }
.btn-whatsapp:hover { background: #1ebe57; box-shadow: var(--shadow-md); }

.btn-sm { padding: 0.6em 1.3em; font-size: var(--fs-xs); }
.btn-lg { padding: 1.1em 2.4em; font-size: var(--fs-base); }
.btn-block { width: 100%; }
.btn-icon-only { padding: 0.75em; border-radius: var(--radius-full); }

.btn[disabled] { opacity: 0.5; cursor: not-allowed; transform: none; }

/* --- Eyebrow / kicker label --- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: var(--ls-wider);
  text-transform: uppercase;
  color: var(--color-accent-dark);
  margin-bottom: var(--space-3);
}
.eyebrow::before {
  content: '';
  width: 28px;
  height: 2px;
  background: var(--color-accent);
  display: inline-block;
}
.theme-dark .eyebrow { color: var(--color-accent-light); }

/* --- Section heading block --- */
.section-head { max-width: 720px; margin-bottom: var(--space-8); }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head p { color: var(--color-text-muted); font-size: var(--fs-md); }

/* --- Site header / nav --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  height: var(--header-height);
  display: flex;
  align-items: center;
  background: rgba(252, 251, 248, 0.82);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(20,20,26,0.06);
  transition: background-color var(--transition-base), box-shadow var(--transition-base);
}
.site-header.is-scrolled { box-shadow: var(--shadow-sm); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: var(--space-6); }

.brand { display: flex; align-items: center; gap: var(--space-3); font-family: var(--font-heading); }
.brand-mark {
  width: 42px; height: 42px; border-radius: var(--radius-sm);
  background: var(--color-black);
  display: flex; align-items: center; justify-content: center;
  color: var(--color-accent-light);
  font-weight: 700; font-size: 1.1rem;
  flex-shrink: 0;
}
.brand-logo-img { height: 36px; width: auto; display: block; }
.brand-logo-img--footer { height: 40px; }
.brand-name { font-weight: 700; font-size: var(--fs-md); letter-spacing: var(--ls-tight); line-height: 1.1; }
.brand-name small { display: block; font-family: var(--font-body); font-size: 0.55rem; letter-spacing: var(--ls-wider); text-transform: uppercase; color: var(--color-accent-dark); font-weight: 600; margin-top: 2px; }

.main-nav { display: flex; align-items: center; gap: var(--space-6); }
.main-nav ul { display: flex; align-items: center; gap: var(--space-5); }
.main-nav a.nav-link {
  font-size: var(--fs-sm); font-weight: 500; position: relative; padding: var(--space-2) 0;
}
.main-nav a.nav-link::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px;
  background: var(--color-red); transform: scaleX(0); transform-origin: right;
  transition: transform var(--transition-base);
}
.main-nav a.nav-link:hover::after, .main-nav a.nav-link.active::after { transform: scaleX(1); transform-origin: left; }
.main-nav a.nav-link.active { color: var(--color-red); }

.nav-actions { display: flex; align-items: center; gap: var(--space-3); }

.nav-toggle {
  display: none;
  width: 44px; height: 44px; border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  background: var(--color-white);
  align-items: center; justify-content: center;
  cursor: pointer;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ''; display: block; width: 20px; height: 2px; background: var(--color-black);
  position: relative; transition: transform var(--transition-fast), opacity var(--transition-fast);
}
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after { position: absolute; top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: rotate(45deg); top: 0; }
.nav-toggle[aria-expanded="true"] span::after { transform: rotate(-45deg); top: 0; }

@media (max-width: 980px) {
  .main-nav { position: fixed; inset: var(--header-height) 0 0 0; background: var(--color-paper); flex-direction: column; align-items: stretch; padding: var(--space-6) var(--container-pad); gap: var(--space-6); transform: translateX(100%); transition: transform var(--transition-base); overflow-y: auto; }
  .main-nav.is-open { transform: translateX(0); }
  .main-nav ul { flex-direction: column; align-items: flex-start; gap: var(--space-1); }
  .main-nav a.nav-link { display: block; padding: var(--space-3) 0; font-size: var(--fs-md); width: 100%; }
  .nav-toggle { display: flex; }
  .nav-actions .btn-outline { display: none; }
}

/* --- Mega dropdown (Properties) --- */
.has-mega { position: relative; }
.mega-panel {
  position: absolute; top: calc(100% + 14px); left: 50%; transform: translateX(-50%) translateY(8px);
  background: var(--color-white); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  padding: var(--space-6); display: grid; grid-template-columns: repeat(3, 200px); gap: var(--space-2) var(--space-6);
  opacity: 0; visibility: hidden; transition: opacity var(--transition-base), transform var(--transition-base);
  z-index: 50;
}
.has-mega:hover .mega-panel, .has-mega:focus-within .mega-panel { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.mega-panel a { display: block; padding: var(--space-2) var(--space-3); border-radius: var(--radius-sm); font-size: var(--fs-sm); }
.mega-panel a:hover { background: var(--color-cream); color: var(--color-red); }
@media (max-width: 980px) { .mega-panel { position: static; transform: none; opacity: 1; visibility: visible; box-shadow: none; grid-template-columns: 1fr; padding: 0 0 0 var(--space-4); display: none; }
  .has-mega.is-open .mega-panel { display: grid; } }

/* --- Hero --- */
.hero {
  position: relative;
  min-height: 76vh;
  display: flex;
  align-items: center;
  color: var(--color-white);
  overflow: hidden;
}
.hero-media { position: absolute; inset: 0; z-index: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-media::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.35) 40%, rgba(0,0,0,0.75) 100%);
}
.hero-content { position: relative; z-index: 1; padding-block: var(--space-11); }
.hero h1 { font-size: var(--fs-4xl); max-width: 16ch; }
.hero .lede { color: rgba(255,255,255,0.85); max-width: 46ch; margin-bottom: var(--space-6); }
.hero-cta-row { display: flex; flex-wrap: wrap; gap: var(--space-4); margin-bottom: var(--space-8); }

.hero-stats { display: flex; flex-wrap: wrap; gap: var(--space-8); margin-top: var(--space-9); }
.hero-stat .num { font-family: var(--font-heading); font-size: var(--fs-2xl); color: var(--color-accent-light); line-height: 1; }
.hero-stat .label { font-size: var(--fs-xs); letter-spacing: var(--ls-wide); text-transform: uppercase; color: rgba(255,255,255,0.7); margin-top: var(--space-2); }

/* --- Search bar (hero) --- */
.search-panel {
  position: relative; z-index: 2;
  background: rgba(255,255,255,0.97);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  padding: var(--space-5);
  margin-top: var(--space-8);
  color: var(--color-text);
}
.search-panel form { display: grid; grid-template-columns: repeat(4, 1fr) auto; gap: var(--space-3); align-items: end; }
.search-tabs { display: flex; gap: var(--space-1); margin-bottom: var(--space-4); }
.search-tab { padding: var(--space-2) var(--space-5); border-radius: var(--radius-full); font-size: var(--fs-sm); font-weight: 600; cursor: pointer; border: 1px solid transparent; }
.search-tab.active { background: var(--color-black); color: var(--color-white); }
.search-tab:not(.active):hover { background: var(--color-cream); }

@media (max-width: 980px) {
  .search-panel form { grid-template-columns: 1fr 1fr; }
  .search-panel form .btn { grid-column: 1 / -1; }
}

/* --- Form fields --- */
.field { display: flex; flex-direction: column; gap: var(--space-2); }
.field label { font-size: var(--fs-xs); font-weight: 600; letter-spacing: var(--ls-wide); text-transform: uppercase; color: var(--color-text-muted); }
.field input, .field select, .field textarea {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 0.8em 1em;
  background: var(--color-white);
  font-size: var(--fs-sm);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--color-accent); box-shadow: 0 0 0 3px rgba(200,16,46,0.16);
}
.field textarea { resize: vertical; min-height: 120px; }
.field-hint { font-size: var(--fs-xs); color: var(--color-text-muted); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); }
@media (max-width: 640px) { .field-row { grid-template-columns: 1fr; } }

.checkbox-row { display: flex; align-items: center; gap: var(--space-2); font-size: var(--fs-sm); }
.checkbox-row input { width: 18px; height: 18px; accent-color: var(--color-red); }

fieldset { border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: var(--space-5); }
legend { padding: 0 var(--space-2); font-weight: 600; font-size: var(--fs-sm); }

.form-card { background: var(--color-white); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); padding: var(--space-7); }

.form-success { background: #eaf6ee; border: 1px solid #bfe4cb; color: var(--color-success); padding: var(--space-5); border-radius: var(--radius-md); }
.form-error { background: #fbeaec; border: 1px solid #f0c1c8; color: var(--color-danger); padding: var(--space-5); border-radius: var(--radius-md); }

/* --- Cards --- */
.card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }

.grid { display: grid; gap: var(--space-6); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 980px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

/* --- Property card --- */
.property-card { display: flex; flex-direction: column; position: relative; }
.property-card .media-frame { aspect-ratio: 4 / 3; }
.property-card .badges { position: absolute; top: var(--space-4); left: var(--space-4); display: flex; gap: var(--space-2); z-index: 2; }
.property-card .fav-btn {
  position: absolute; top: var(--space-4); right: var(--space-4); z-index: 2;
  width: 38px; height: 38px; border-radius: var(--radius-full); background: rgba(255,255,255,0.9);
  display: flex; align-items: center; justify-content: center; border: none; cursor: pointer;
  transition: background var(--transition-fast), transform var(--transition-fast);
}
.property-card .fav-btn:hover { transform: scale(1.08); }
.property-card .fav-btn.is-active svg { fill: var(--color-red); stroke: var(--color-red); }
.property-card .body { padding: var(--space-5); display: flex; flex-direction: column; gap: var(--space-3); flex: 1; }
.property-card .price { font-family: var(--font-heading); font-size: var(--fs-lg); font-weight: 700; color: var(--color-black); }
.property-card .price .period { font-family: var(--font-body); font-size: var(--fs-xs); font-weight: 500; color: var(--color-text-muted); }
.property-card h3 { font-size: var(--fs-md); margin-bottom: 0; }
.property-card .loc { display: flex; align-items: center; gap: var(--space-2); font-size: var(--fs-sm); color: var(--color-text-muted); }
.property-card .meta { display: flex; gap: var(--space-4); font-size: var(--fs-xs); color: var(--color-text-muted); border-top: 1px solid var(--color-border); padding-top: var(--space-3); margin-top: auto; }
.property-card .meta span { display: flex; align-items: center; gap: var(--space-1); }
.card-actions { display: flex; align-items: center; gap: var(--space-2); margin-top: var(--space-3); }
.card-actions .btn { flex: 1; padding: 0.55em 0.8em; font-size: 0.72rem; }
.card-action-icon { width: 34px; height: 34px; border-radius: var(--radius-full); border: 1px solid var(--color-border); display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--color-text); transition: background var(--transition-fast), color var(--transition-fast), border-color var(--transition-fast); }
.card-action-icon:hover { background: var(--color-black); color: var(--color-white); border-color: var(--color-black); }
.card-action-icon--whatsapp:hover { background: #25d366; border-color: #25d366; }
.property-card .compare-row { display: flex; align-items: center; justify-content: space-between; }

.badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: var(--fs-xs); font-weight: 700; text-transform: uppercase; letter-spacing: var(--ls-wide);
  padding: 0.35em 0.9em; border-radius: var(--radius-full);
}
.badge-sale { background: var(--color-black); color: var(--color-white); }
.badge-rent { background: var(--color-red); color: var(--color-white); }
.badge-new { background: var(--color-white); color: var(--color-black); border: 1px solid var(--color-black); }
.badge-featured { background: var(--color-white); color: var(--color-accent-dark); border: 1px solid var(--color-accent); }
.badge-outline { border: 1px solid var(--color-border); color: var(--color-text-muted); }

/* --- Investment score ring --- */
.score-ring { position: relative; width: 84px; height: 84px; display: flex; align-items: center; justify-content: center; }
.score-ring svg { transform: rotate(-90deg); }
.score-ring .track { stroke: var(--color-cloud); fill: none; }
.score-ring .value { stroke: var(--color-accent); fill: none; stroke-linecap: round; transition: stroke-dashoffset 1s var(--ease-luxury); }
.score-ring .num { position: absolute; font-family: var(--font-heading); font-weight: 700; font-size: var(--fs-md); }

/* --- District / category cards --- */
.district-card, .category-card { position: relative; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 3/4; }
.district-card img, .category-card img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--transition-slow); }
.district-card:hover img, .category-card:hover img { transform: scale(1.08); }
.district-card::after, .category-card::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,0.85) 100%); }
.district-card .info, .category-card .info { position: absolute; left: 0; right: 0; bottom: 0; padding: var(--space-5); z-index: 1; color: var(--color-white); }
.district-card h3, .category-card h3 { color: var(--color-white); margin-bottom: var(--space-1); }
.district-card .tag, .category-card .tag { font-size: var(--fs-xs); color: var(--color-accent-light); text-transform: uppercase; letter-spacing: var(--ls-wide); }

.category-card-sm { display: flex; flex-direction: column; align-items: center; gap: var(--space-3); text-align: center; padding: var(--space-6) var(--space-4); border-radius: var(--radius-lg); background: var(--color-white); box-shadow: var(--shadow-sm); transition: box-shadow var(--transition-base), transform var(--transition-base); }
.category-card-sm:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }
.category-card-sm .icon-wrap { width: 60px; height: 60px; border-radius: var(--radius-full); background: var(--color-cream); display: flex; align-items: center; justify-content: center; color: var(--color-accent-dark); }

/* --- Stat counters --- */
.stat-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-6); }
.stat-item { text-align: center; }
.stat-item .num { font-family: var(--font-heading); font-size: var(--fs-2xl); font-weight: 700; }
.stat-item .label { color: var(--color-text-muted); font-size: var(--fs-sm); margin-top: var(--space-2); }
@media (max-width: 720px) { .stat-strip { grid-template-columns: repeat(2, 1fr); } }

/* --- Testimonials --- */
.testimonial-card { background: var(--color-white); border-radius: var(--radius-lg); padding: var(--space-7); box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: var(--space-5); height: 100%; }
.testimonial-card .stars { color: var(--color-accent); letter-spacing: 2px; }
.testimonial-card .quote { font-family: var(--font-heading); font-size: var(--fs-md); line-height: var(--lh-snug); }
.testimonial-card .person { display: flex; align-items: center; gap: var(--space-3); margin-top: auto; }
.testimonial-card .person .name { font-weight: 700; font-size: var(--fs-sm); }
.testimonial-card .person .role { font-size: var(--fs-xs); color: var(--color-text-muted); }

/* --- Avatar (initials, no photo dependency) --- */
.avatar {
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--color-charcoal), var(--color-black));
  color: var(--color-accent-light);
  font-family: var(--font-heading); font-weight: 700;
  flex-shrink: 0;
}
.avatar-sm { width: 38px; height: 38px; font-size: var(--fs-xs); }
.avatar-md { width: 54px; height: 54px; font-size: var(--fs-sm); }
.avatar-lg { width: 92px; height: 92px; font-size: var(--fs-lg); }

/* --- Agent card --- */
.agent-card { text-align: center; padding: var(--space-7); background: var(--color-white); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.agent-card .avatar-lg { margin-inline: auto; margin-bottom: var(--space-5); }
.agent-card h3 { margin-bottom: var(--space-1); }
.agent-card .role { color: var(--color-accent-dark); font-size: var(--fs-sm); font-weight: 600; margin-bottom: var(--space-4); }
.agent-card .contact-row { display: flex; justify-content: center; gap: var(--space-3); margin-top: var(--space-4); }

/* --- Sticky contact/CTA sidebar card (property detail) --- */
.sticky-cta { position: sticky; top: calc(var(--header-height) + 24px); background: var(--color-white); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); padding: var(--space-6); }
.sticky-cta .price-block { border-bottom: 1px solid var(--color-border); padding-bottom: var(--space-5); margin-bottom: var(--space-5); }
.sticky-cta .agent-mini { display: flex; align-items: center; gap: var(--space-3); margin-bottom: var(--space-5); }
.sticky-cta .cta-stack { display: flex; flex-direction: column; gap: var(--space-3); }

/* --- Gallery / lightbox --- */
.gallery-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: 1fr 1fr; gap: var(--space-2); border-radius: var(--radius-lg); overflow: hidden; height: 380px; }
.gallery-grid .media-frame { height: 100%; cursor: pointer; }
.gallery-grid a:first-child .media-frame { grid-row: 1 / 3; }
.gallery-grid .view-all { position: absolute; bottom: var(--space-4); right: var(--space-4); z-index: 2; }
@media (max-width: 860px) { .gallery-grid { grid-template-columns: 1fr 1fr; grid-template-rows: repeat(3, 160px); height: auto; } .gallery-grid a:nth-child(n+4) { display: none; } .gallery-grid a:first-child .media-frame { grid-row: auto; grid-column: 1 / 3; } }

.lightbox { position: fixed; inset: 0; background: rgba(0,0,0,0.94); z-index: var(--z-modal); display: none; align-items: center; justify-content: center; }
.lightbox.is-open { display: flex; }
.lightbox img { max-width: 90vw; max-height: 80vh; object-fit: contain; border-radius: var(--radius-md); }
.lightbox .lb-close, .lightbox .lb-prev, .lightbox .lb-next { position: absolute; background: rgba(255,255,255,0.1); color: #fff; border: none; width: 48px; height: 48px; border-radius: var(--radius-full); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.lightbox .lb-close { top: var(--space-6); right: var(--space-6); }
.lightbox .lb-prev { left: var(--space-6); top: 50%; transform: translateY(-50%); }
.lightbox .lb-next { right: var(--space-6); top: 50%; transform: translateY(-50%); }
.lightbox .lb-counter { position: absolute; bottom: var(--space-6); left: 50%; transform: translateX(-50%); color: #fff; font-size: var(--fs-sm); }

/* --- Filter sidebar --- */
.filter-panel { background: var(--color-white); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); padding: var(--space-6); }
.filter-group { border-bottom: 1px solid var(--color-border); padding-block: var(--space-5); }
.filter-group:first-child { padding-top: 0; }
.filter-group:last-child { border-bottom: none; padding-bottom: 0; }
.filter-group h4 { font-size: var(--fs-sm); text-transform: uppercase; letter-spacing: var(--ls-wide); margin-bottom: var(--space-4); }
.filter-chip-row { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.filter-chip { padding: var(--space-2) var(--space-4); border-radius: var(--radius-full); border: 1px solid var(--color-border); font-size: var(--fs-xs); cursor: pointer; transition: all var(--transition-fast); }
.filter-chip:hover { border-color: var(--color-accent); }
.filter-chip.active { background: var(--color-black); color: var(--color-white); border-color: var(--color-black); }

.results-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--space-4); margin-bottom: var(--space-6); }
.results-count { font-size: var(--fs-sm); color: var(--color-text-muted); }
.view-toggle { display: flex; gap: var(--space-1); background: var(--color-cream); border-radius: var(--radius-full); padding: 4px; }
.view-toggle button { padding: var(--space-2) var(--space-4); border-radius: var(--radius-full); border: none; background: transparent; cursor: pointer; font-size: var(--fs-xs); }
.view-toggle button.active { background: var(--color-white); box-shadow: var(--shadow-sm); }

/* --- Pagination --- */
.pagination { display: flex; justify-content: center; align-items: center; gap: var(--space-2); margin-top: var(--space-9); }
.pagination a, .pagination span { width: 42px; height: 42px; display: flex; align-items: center; justify-content: center; border-radius: var(--radius-full); font-size: var(--fs-sm); }
.pagination a:hover { background: var(--color-cream); }
.pagination .current { background: var(--color-black); color: var(--color-white); }

/* --- Calculators (mortgage / ROI) --- */
.calc-card { background: var(--color-cream); border-radius: var(--radius-lg); padding: var(--space-7); }
.calc-card .slider-row { display: flex; justify-content: space-between; font-size: var(--fs-sm); margin-bottom: var(--space-2); }
input[type="range"] { width: 100%; accent-color: var(--color-red); }
.calc-result { background: var(--color-black); color: var(--color-white); border-radius: var(--radius-md); padding: var(--space-6); text-align: center; margin-top: var(--space-6); }
.calc-result .amount { font-family: var(--font-heading); font-size: var(--fs-2xl); color: var(--color-accent-light); }
.calc-breakdown { display: flex; justify-content: space-between; font-size: var(--fs-sm); padding: var(--space-2) 0; border-bottom: 1px dashed var(--color-border); }

/* --- Tabs --- */
.tabs-nav { display: flex; gap: var(--space-6); border-bottom: 1px solid var(--color-border); margin-bottom: var(--space-6); overflow-x: auto; }
.tabs-nav button { padding: var(--space-3) 0; font-weight: 600; font-size: var(--fs-sm); border-bottom: 2px solid transparent; white-space: nowrap; cursor: pointer; background: none; border-top: none; border-left: none; border-right: none; }
.tabs-nav button.active { color: var(--color-red); border-color: var(--color-red); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* --- Feature/amenity list --- */
.feature-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-3) var(--space-6); }
.feature-grid li { display: flex; align-items: center; gap: var(--space-3); font-size: var(--fs-sm); }
.feature-grid li svg { color: var(--color-accent); flex-shrink: 0; }
@media (max-width: 560px) { .feature-grid { grid-template-columns: 1fr; } }

/* --- FAQ accordion --- */
.accordion-item { border-bottom: 1px solid var(--color-border); }
.accordion-trigger { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: var(--space-4); padding: var(--space-5) 0; background: none; border: none; text-align: left; cursor: pointer; font-family: var(--font-heading); font-size: var(--fs-md); font-weight: 600; }
.accordion-trigger .icon { flex-shrink: 0; transition: transform var(--transition-base); }
.accordion-trigger[aria-expanded="true"] .icon { transform: rotate(45deg); }
.accordion-panel { max-height: 0; overflow: hidden; transition: max-height var(--transition-slow); }
.accordion-panel-inner { padding-bottom: var(--space-5); color: var(--color-text-muted); line-height: var(--lh-relaxed); }

/* --- Breadcrumbs --- */
.breadcrumbs { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); font-size: var(--fs-xs); color: var(--color-text-muted); margin-bottom: var(--space-6); }
.breadcrumbs a:hover { color: var(--color-red); }
.breadcrumbs .sep { opacity: 0.5; }

/* --- Blog card --- */
.post-card .media-frame { aspect-ratio: 16/10; }
.post-card .body { padding: var(--space-5) 0 0; }
.post-card .meta { display: flex; gap: var(--space-3); font-size: var(--fs-xs); color: var(--color-text-muted); text-transform: uppercase; letter-spacing: var(--ls-wide); margin-bottom: var(--space-3); }
.post-card h3 { font-size: var(--fs-md); }
.post-card .excerpt { color: var(--color-text-muted); font-size: var(--fs-sm); }

.article-body { font-size: var(--fs-md); line-height: var(--lh-relaxed); }
.article-body h2 { font-size: var(--fs-xl); margin-top: var(--space-8); }
.article-body h3 { font-size: var(--fs-lg); margin-top: var(--space-6); }
.article-body ul, .article-body ol { padding-left: 1.4em; list-style: disc; margin-bottom: 1em; }
.article-body ol { list-style: decimal; }
.article-body a { color: var(--color-red); text-decoration: underline; text-underline-offset: 3px; }
.article-body p { margin-bottom: 1.2em; }

.toc-card { background: var(--color-cream); border-radius: var(--radius-md); padding: var(--space-5); }
.toc-card h4 { font-size: var(--fs-sm); text-transform: uppercase; letter-spacing: var(--ls-wide); margin-bottom: var(--space-3); }
.toc-card ol { list-style: decimal; padding-left: 1.2em; font-size: var(--fs-sm); }
.toc-card li { margin-bottom: var(--space-2); }
.toc-card a:hover { color: var(--color-red); }

/* --- CTA band --- */
.cta-band { background: var(--color-black); color: var(--color-white); border-radius: var(--radius-xl); padding: var(--space-9); text-align: center; position: relative; overflow: hidden; }
.cta-band::before { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 20% 20%, rgba(200,16,46,0.22), transparent 55%), radial-gradient(circle at 80% 80%, rgba(255,255,255,0.06), transparent 50%); }
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 { max-width: 24ch; margin-inline: auto; }
.cta-band .actions { display: flex; gap: var(--space-4); justify-content: center; flex-wrap: wrap; margin-top: var(--space-6); }

/* --- Footer --- */
.site-footer { background: var(--color-black); color: var(--color-fog); padding-block: var(--space-10) var(--space-6); }
.footer-grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: var(--space-8); }
.footer-grid h4 { color: var(--color-white); font-size: var(--fs-sm); text-transform: uppercase; letter-spacing: var(--ls-wide); margin-bottom: var(--space-4); }
.footer-grid ul li { margin-bottom: var(--space-3); }
.footer-grid a:hover { color: var(--color-accent-light); }
.footer-brand p { color: var(--color-mist); max-width: 32ch; }
.footer-social { display: flex; gap: var(--space-3); margin-top: var(--space-5); }
.footer-social a { width: 40px; height: 40px; border-radius: var(--radius-full); border: 1px solid rgba(255,255,255,0.15); display: flex; align-items: center; justify-content: center; transition: background var(--transition-fast), border-color var(--transition-fast); }
.footer-social a:hover { background: var(--color-accent); border-color: var(--color-accent); color: var(--color-black); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); margin-top: var(--space-9); padding-top: var(--space-6); display: flex; justify-content: space-between; flex-wrap: wrap; gap: var(--space-3); font-size: var(--fs-xs); color: var(--color-mist); }
.newsletter-form { display: flex; gap: var(--space-2); margin-top: var(--space-4); }
.newsletter-form input { flex: 1; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.15); color: #fff; border-radius: var(--radius-sm); padding: 0.8em 1em; }
.newsletter-form input::placeholder { color: var(--color-mist); }

@media (max-width: 980px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

/* --- Language picker (first-visit overlay) --- */
.lang-picker-overlay {
  position: fixed; inset: 0; z-index: var(--z-lang-picker);
  background: rgba(10,10,10,0.92);
  display: flex; align-items: center; justify-content: center;
  padding: var(--space-6);
}
.lang-picker-card {
  background: var(--color-white); border-radius: var(--radius-lg);
  padding: var(--space-8); max-width: 420px; width: 100%; text-align: center;
  box-shadow: var(--shadow-xl);
}
.lang-picker-card h2 { font-size: var(--fs-xl); margin-bottom: var(--space-2); }
.lang-picker-options { display: flex; flex-direction: column; gap: var(--space-3); margin-top: var(--space-6); }
.lang-picker-option {
  display: flex; align-items: center; justify-content: center; gap: var(--space-3);
  padding: var(--space-4); border-radius: var(--radius-md); border: 1px solid var(--color-border);
  font-weight: 600; transition: border-color var(--transition-fast), background var(--transition-fast);
}
.lang-picker-option:hover { border-color: var(--color-accent); background: var(--color-cream); }
.lang-picker-option span { font-size: 1.3rem; }

.lang-switch { position: relative; }

/* --- Floating WhatsApp button --- */
.float-whatsapp {
  position: fixed; bottom: var(--space-6); right: var(--space-6); z-index: var(--z-toast);
  width: 60px; height: 60px; border-radius: var(--radius-full); background: #25d366; color: #fff;
  display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-lg);
  transition: transform var(--transition-fast);
}
.float-whatsapp:hover { transform: scale(1.08); }

/* --- Compare table --- */
.compare-table-wrap { overflow-x: auto; }
.compare-table { width: 100%; border-collapse: collapse; min-width: 720px; }
.compare-table th, .compare-table td { padding: var(--space-4); border-bottom: 1px solid var(--color-border); text-align: left; vertical-align: top; }
.compare-table th.row-label { width: 200px; color: var(--color-text-muted); font-weight: 600; font-size: var(--fs-sm); }
.compare-table .remove-col { text-align: right; }

/* --- Skeleton loaders --- */
.skeleton { background: linear-gradient(90deg, var(--color-cloud) 25%, var(--color-cream-dark) 37%, var(--color-cloud) 63%); background-size: 400% 100%; animation: skeleton-loading 1.4s ease infinite; border-radius: var(--radius-md); }
@keyframes skeleton-loading { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }

/* --- Alert / toast --- */
.toast { position: fixed; bottom: var(--space-6); left: 50%; transform: translateX(-50%) translateY(20px); background: var(--color-black); color: #fff; padding: var(--space-4) var(--space-6); border-radius: var(--radius-full); box-shadow: var(--shadow-lg); font-size: var(--fs-sm); opacity: 0; visibility: hidden; transition: all var(--transition-base); z-index: var(--z-toast); }
.toast.is-visible { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }

/* --- Map --- */
.map-frame { border-radius: var(--radius-lg); overflow: hidden; height: 420px; background: var(--color-cream-dark); }
.map-frame iframe, .map-frame > div { width: 100%; height: 100%; border: 0; }

/* --- 404 --- */
.error-page { min-height: 70vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.error-page .code { font-family: var(--font-heading); font-size: var(--fs-4xl); color: var(--color-accent); }
