/* ── Hero ─────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg-slides {
  position: absolute;
  inset: 0;
}

.hero-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.5s ease;
  transform: scale(1.08);
  animation: none;
}

.hero-slide.active {
  opacity: 1;
  animation: heroZoom 8s ease forwards;
}

@keyframes heroZoom {
  from { transform: scale(1.08); }
  to   { transform: scale(1); }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(10,10,10,0.85) 0%,
    rgba(10,10,10,0.5) 50%,
    rgba(10,10,10,0.3) 100%
  );
}

.hero-grain {
  display: none;
}

/* Vertical side text */
.hero-vertical-text {
  position: absolute;
  left: 2.5rem;
  top: 50%;
  transform: translateY(-50%) rotate(-90deg);
  transform-origin: center;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  z-index: 2;
  white-space: nowrap;
}

.hero-vertical-text span {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(201,168,76,0.6);
}

.hero-vertical-text .divider-line {
  display: block;
  width: 40px;
  height: 1px;
  background: rgba(201,168,76,0.4);
}

/* Hero content */
.hero-content {
  position: relative;
  z-index: 2;
  padding: calc(var(--nav-height) + 4rem) clamp(1.5rem, 5vw, 6rem) 6rem;
  max-width: 900px;
  width: 100%;
}

.hero-eyebrow {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  animation: fadeInDown 0.8s 0.2s both;
}

.hero-eyebrow-dot {
  display: block;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--gold);
}

@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-20px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero-title {
  display: flex;
  flex-direction: column;
  margin-bottom: 1.5rem;
  animation: fadeInUp 0.8s 0.4s both;
}

.hero-title-line {
  font-family: var(--font-display);
  font-size: clamp(4rem, 8vw, 8rem);
  font-weight: 300;
  line-height: 1.0;
  color: var(--cream);
  letter-spacing: -0.02em;
}

.hero-title-line.italic { font-style: italic; }
.hero-title-line.gold { color: var(--gold); }

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero-subtitle {
  color: rgba(248,244,238,0.7);
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  line-height: 1.7;
  margin-bottom: 3rem;
  animation: fadeInUp 0.8s 0.6s both;
}

/* Hero search */
.hero-search {
  background: rgba(20,20,20,0.85);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(201,168,76,0.2);
  border-radius: var(--radius-xl);
  padding: 8px;
  max-width: 800px;
  animation: fadeInUp 0.8s 0.8s both;
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}

.hero-search-inner {
  display: flex;
  align-items: stretch;
}

.hero-search-field {
  flex: 1;
  padding: 1rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.hero-search-field label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
}

.hero-search-field input,
.hero-search-field select {
  background: none;
  border: none;
  color: var(--cream);
  font-size: 0.95rem;
  outline: none;
  padding: 0;
  width: 100%;
  appearance: none;
}

/* Hero search bar is always dark — force white text in light mode */
body.light-mode .hero-search-field input,
body.light-mode .hero-search-field select {
  color: #ffffff;
}

.hero-search-field input::placeholder { color: rgba(248,244,238,0.4); }
body.light-mode .hero-search-field input::placeholder { color: rgba(255,255,255,0.45); }
.hero-search-field select option { background: var(--charcoal-2); color: #f8f4ee; }

.hero-search-divider {
  width: 1px;
  background: rgba(201,168,76,0.15);
  margin: 0.5rem 0;
  flex-shrink: 0;
}

.hero-search-btn {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1rem 2rem;
  background: var(--gold);
  color: var(--black);
  border-radius: calc(var(--radius-xl) - 6px);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  white-space: nowrap;
  margin: 2px;
  transition: var(--transition);
  flex-shrink: 0;
}

.hero-search-btn:hover {
  background: var(--gold-light);
  transform: scale(1.02);
}

/* Autocomplete */
.search-autocomplete-wrapper { position: relative; }

.autocomplete-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0; right: 0;
  background: var(--charcoal-2);
  border: 1px solid var(--border-hard);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  z-index: 100;
  display: none;
}

.autocomplete-dropdown.open { display: block; }

.autocomplete-item {
  padding: 0.75rem 1rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--cream);
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.autocomplete-item:hover {
  background: var(--charcoal-3);
  color: var(--gold);
}

/* Quick tags */
.hero-quick-tags {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s 1s both;
  margin-top: 1.5rem;
}

.hero-tag-label {
  font-size: 0.78rem;
  color: var(--text-dim);
  font-weight: 500;
}

.hero-tag {
  padding: 0.35rem 1rem;
  border-radius: 100px;
  border: 1px solid rgba(201,168,76,0.25);
  color: rgba(248,244,238,0.75);
  font-size: 0.8rem;
  transition: var(--transition);
}

.hero-tag:hover {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(201,168,76,0.08);
}

/* Slide indicators */
.hero-indicators {
  position: absolute;
  bottom: 3rem;
  right: 3rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  z-index: 2;
}

.hero-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,0.3);
  transition: var(--transition);
}

.hero-dot.active {
  background: var(--gold);
  transform: scale(1.3);
}

/* Scroll cue */
.hero-scroll-cue {
  position: absolute;
  bottom: 3rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  z-index: 2;
  animation: fadeIn 1s 1.5s both;
}

.hero-scroll-line {
  width: 1px;
  height: 50px;
  background: linear-gradient(to bottom, var(--gold), transparent);
  animation: scrollPulse 2s ease infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.4; transform: scaleY(1); }
  50% { opacity: 1; transform: scaleY(1.2); }
}

.hero-scroll-cue span {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(201,168,76,0.6);
}

/* ── Stats Bar ───────────────────────────────────────────── */
.stats-bar {
  background: var(--black);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 2.5rem clamp(1.5rem, 5vw, 4rem);
}

.stats-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  max-width: 900px;
  margin: 0 auto;
}

.stat-item {
  text-align: center;
  flex: 1;
  padding: 0.5rem 2rem;
}

.stat-number {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: 400;
  color: var(--gold);
  line-height: 1;
  margin-bottom: 0.4rem;
}

.stat-label {
  font-size: 0.78rem;
  color: var(--text-dim);
  font-weight: 500;
  letter-spacing: 0.05em;
}

.stat-divider {
  width: 1px;
  height: 50px;
  background: var(--border);
  flex-shrink: 0;
}

/* ── Featured Section ────────────────────────────────────── */
.featured-section {
  background: var(--charcoal);
}

.featured-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: clamp(2rem, 4vw, 3rem);
  flex-wrap: wrap;
  gap: 1.5rem;
}

.featured-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  grid-template-rows: auto auto;
  gap: 1.5rem;
}

.featured-grid .house-card:first-child {
  grid-row: span 2;
}

.featured-grid .house-card:first-child .house-card-image {
  aspect-ratio: unset;
  height: 100%;
  min-height: 300px;
}

.featured-grid .house-card:first-child .house-card-price {
  font-size: 2rem;
}

.featured-grid .house-card:first-child .house-card-title {
  font-size: 1.4rem;
}

/* ── Why Section ─────────────────────────────────────────── */
.why-section {
  background: linear-gradient(135deg, var(--black) 0%, var(--charcoal) 100%);
}

.why-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}

.why-features {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.why-feature {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem;
  background: var(--charcoal-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.why-feature:hover {
  border-color: var(--border-hard);
  background: var(--charcoal-3);
}

.why-feature-icon {
  font-size: 1.5rem;
  line-height: 1;
  flex-shrink: 0;
}

.why-feature h4 {
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--cream);
  margin-bottom: 0.3rem;
}

.why-feature p {
  font-size: 0.85rem;
  color: var(--text-dim);
  line-height: 1.6;
}

/* Image stack */
.why-visual {
  position: relative;
}

.why-image-stack {
  position: relative;
  height: 520px;
}

.why-img {
  position: absolute;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.why-img img {
  width: 100%; height: 100%;
  object-fit: cover;
}

.why-img-1 {
  width: 70%;
  height: 65%;
  top: 0; left: 0;
}

.why-img-2 {
  width: 55%;
  height: 50%;
  bottom: 0; right: 0;
  border: 4px solid var(--charcoal);
}

.why-stat-card {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-30%, -50%);
  background: var(--gold);
  color: var(--black);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.75rem;
  text-align: center;
  box-shadow: 0 12px 40px rgba(201,168,76,0.35);
  z-index: 2;
}

.why-stat-number {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 600;
  line-height: 1;
}

.why-stat-label {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.8;
  margin-top: 0.3rem;
}

/* ── Type Grid ───────────────────────────────────────────── */
.type-section {
  background: var(--charcoal-2);
}

.type-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}

.type-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 3/4;
  cursor: pointer;
}

.type-card-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.7s ease;
}

.type-card:hover .type-card-bg {
  transform: scale(1.08);
}

.type-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,10,10,0.9) 0%, rgba(10,10,10,0.3) 60%, transparent 100%);
  transition: var(--transition);
}

.type-card:hover .type-card-overlay {
  background: linear-gradient(to top, rgba(10,10,10,0.95) 0%, rgba(10,10,10,0.5) 70%, rgba(10,10,10,0.1) 100%);
}

.type-card-content {
  position: absolute;
  bottom: 1.5rem;
  left: 1.5rem;
  right: 1.5rem;
}

.type-card-icon {
  font-size: 2rem;
  margin-bottom: 0.6rem;
}

.type-card-content h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--cream);
  margin-bottom: 0.3rem;
}

.type-card-count {
  font-size: 0.78rem;
  color: var(--gold);
  font-weight: 500;
  letter-spacing: 0.05em;
}

/* ── Recent Section ─────────────────────────────────────── */
.recent-section {
  background: var(--charcoal);
}

/* ── CTA ────────────────────────────────────────────────── */
.cta-section {
  position: relative;
  padding: clamp(5rem, 10vw, 10rem) clamp(1.5rem, 5vw, 4rem);
  text-align: center;
  overflow: hidden;
}

.cta-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.cta-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10,10,10,0.8);
}

.cta-content {
  position: relative;
  z-index: 1;
  max-width: 600px;
  margin: 0 auto;
}

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 1200px) {
  .type-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 1024px) {
  .featured-grid { grid-template-columns: 1fr; }
  .featured-grid .house-card:first-child { grid-row: span 1; }
  .featured-grid .house-card:first-child .house-card-image { aspect-ratio: 4/3; height: auto; }
  .why-grid { grid-template-columns: 1fr; }
  .why-visual { display: none; }
}

@media (max-width: 768px) {
  .hero-vertical-text { display: none; }
  .hero-search-inner { flex-direction: column; }
  .hero-search-divider { display: none; }
  .hero-search-btn { border-radius: var(--radius-md); width: 100%; justify-content: center; }
  .stats-inner { flex-wrap: wrap; }
  .stat-divider { display: none; }
  .type-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .type-grid { grid-template-columns: 1fr 1fr; }
  .featured-header { flex-direction: column; align-items: flex-start; }
}
