/* ========================================
   LUXURY REAL ESTATE WEBSITE - CSS
   Brand Colors: Navy #0E1C2B, Gold #C9A227, Ivory #F7F4EC
   Typography: Playfair (display), Inter (body)
   ======================================== */

/* ========== ROOT VARIABLES ========== */
:root {
  --color-navy: #0E1C2B;
  --color-gold: #C9A227;
  --color-ivory: #F7F4EC;
  --color-text: #1a1a1a;
  --color-text-light: #666;
  --color-border: rgba(201, 162, 39, 0.15);
  --color-hover: rgba(201, 162, 39, 0.1);

  --font-display: 'Playfair Display', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2rem;
  --spacing-xl: 3rem;
  --spacing-2xl: 4rem;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.12);
}

/* ========== RESET & BASICS ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background-color: var(--color-ivory);
  line-height: 1.6;
}

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

a {
  color: var(--color-navy);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

button {
  cursor: pointer;
  border: none;
  font-family: var(--font-body);
}

/* ========== TYPOGRAPHY ========== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
}

h1 {
  font-size: clamp(2rem, 8vw, 3.5rem);
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.75rem, 5vw, 2.75rem);
  color: var(--color-navy);
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.5rem;
  color: var(--color-navy);
}

p {
  font-size: 1rem;
  color: var(--color-text);
  margin-bottom: var(--spacing-md);
}

/* ========== CONTAINER ========== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

@media (max-width: 768px) {
  .container {
    padding: 0 var(--spacing-md);
  }
}

/* ========== HEADER / NAVIGATION ========== */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-ivory);
  border-bottom: 1px solid var(--color-border);
  backdrop-filter: blur(10px);
}

.header__content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-md) 0;
}

.header__logo {
  flex: 1;
}

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-navy);
  letter-spacing: -0.02em;
  margin: 0;
}

.header__nav {
  display: flex;
  list-style: none;
  gap: var(--spacing-xl);
  align-items: center;
  flex: 1;
  justify-content: center;
}

.nav-link {
  color: var(--color-text);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
  transition: color 0.3s ease;
}

.nav-link:hover {
  color: var(--color-gold);
  text-decoration: none;
}

@media (max-width: 768px) {
  .header__nav {
    display: none;
  }

  .header__content {
    flex-wrap: wrap;
    gap: var(--spacing-md);
  }
}

/* ========== BUTTONS ========== */
.btn {
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
  text-align: center;
  cursor: pointer;
}

.btn--primary {
  background: var(--color-gold);
  color: white;
  border: 2px solid var(--color-gold);
}

.btn--primary:hover {
  background: #b89216;
  border-color: #b89216;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  text-decoration: none;
}

.btn--secondary {
  background: transparent;
  color: var(--color-navy);
  border: 2px solid var(--color-navy);
}

.btn--secondary:hover {
  background: var(--color-navy);
  color: var(--color-ivory);
  transform: translateY(-2px);
  text-decoration: none;
}

.btn--tertiary {
  background: transparent;
  color: var(--color-gold);
  border: 1px solid var(--color-gold);
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
}

.btn--tertiary:hover {
  background: var(--color-gold);
  color: white;
  text-decoration: none;
}

.btn--link {
  background: none;
  color: var(--color-gold);
  border: none;
  padding: 0;
  font-weight: 600;
  text-decoration: none;
}

.btn--link:hover {
  color: var(--color-navy);
  text-decoration: underline;
}

.btn--small {
  padding: 0.6rem 1.2rem;
  font-size: 0.9rem;
}

.btn--large {
  padding: 1rem 2rem;
  font-size: 1rem;
  width: 100%;
}

/* ========== DIVIDER ========== */
.divider {
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, var(--color-gold) 0%, transparent 100%);
  margin: var(--spacing-md) 0 var(--spacing-xl) 0;
}

.divider--left {
  margin-left: 0;
  margin-right: auto;
}

/* ========== SECTION HEADER ========== */
.section__header {
  text-align: center;
  margin-bottom: var(--spacing-2xl);
}

.section__title {
  margin-bottom: var(--spacing-md);
}

/* ========== HERO SECTION ========== */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero__image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(14, 28, 43, 0.4);
  z-index: 1;
}

.hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: white;
  padding: var(--spacing-lg);
  max-width: 800px;
}

.hero__heading {
  color: white;
  margin-bottom: var(--spacing-md);
  font-size: clamp(2.5rem, 10vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.hero__subheading {
  color: rgba(255, 255, 255, 0.95);
  font-size: clamp(1rem, 3vw, 1.5rem);
  margin-bottom: var(--spacing-xl);
  font-weight: 300;
}

.hero__buttons {
  display: flex;
  gap: var(--spacing-md);
  justify-content: center;
  flex-wrap: wrap;
}

@media (max-width: 768px) {
  .hero {
    min-height: 500px;
    height: auto;
    padding: var(--spacing-2xl) 0;
  }

  .hero__buttons {
    flex-direction: column;
  }

  .hero__buttons .btn {
    width: 100%;
  }
}

/* ========== LISTINGS SECTION ========== */
.listings {
  padding: var(--spacing-2xl) 0;
  background: white;
}

.listings__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--spacing-xl);
}

.listing-card {
  background: white;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
  animation: fadeInUp 0.6s ease;
}

.listing-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-8px);
}

.listing-card__image-wrapper {
  height: 300px;
  overflow: hidden;
  background: #f5f5f5;
}

.listing-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.listing-card:hover .listing-card__image {
  transform: scale(1.05);
}

.listing-card__content {
  padding: var(--spacing-lg);
}

.listing-card__price {
  color: var(--color-gold);
  font-size: 1.75rem;
  margin-bottom: var(--spacing-sm);
}

.listing-card__specs {
  color: var(--color-text-light);
  font-size: 0.95rem;
  margin-bottom: var(--spacing-sm);
}

.listing-card__location {
  color: var(--color-text-light);
  font-size: 0.95rem;
  margin-bottom: var(--spacing-md);
  font-weight: 500;
}

/* ========== AGENT SECTION ========== */
.agent {
  padding: var(--spacing-2xl) 0;
  background: var(--color-ivory);
}

.agent__content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-2xl);
  align-items: center;
}

.agent__image-wrapper {
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.agent__image {
  width: 100%;
  height: auto;
  display: block;
}

.agent__bio {
  padding: var(--spacing-lg);
}

.agent__experience {
  color: var(--color-gold);
  font-weight: 600;
  font-size: 1.1rem;
  margin-bottom: var(--spacing-md);
}

.agent__quote {
  color: var(--color-text);
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: var(--spacing-xl);
  font-style: italic;
  border-left: 3px solid var(--color-gold);
  padding-left: var(--spacing-md);
}

@media (max-width: 768px) {
  .agent__content {
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
  }

  .agent__bio {
    padding: 0;
  }
}

/* ========== SERVICES SECTION ========== */
.services {
  padding: var(--spacing-2xl) 0;
  background: white;
}

.services__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--spacing-xl);
}

.service-card {
  padding: var(--spacing-xl);
  background: var(--color-ivory);
  border-radius: var(--radius-lg);
  text-align: center;
  transition: all 0.3s ease;
  animation: fadeInUp 0.6s ease;
}

.service-card:hover {
  background: white;
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.service-card__icon {
  font-size: 3rem;
  margin-bottom: var(--spacing-md);
  display: block;
}

.service-card__title {
  margin-bottom: var(--spacing-md);
}

.service-card__description {
  color: var(--color-text-light);
  margin-bottom: var(--spacing-md);
  line-height: 1.7;
}

/* ========== NEIGHBORHOODS SECTION ========== */
.neighborhoods {
  padding: var(--spacing-2xl) 0;
  background: var(--color-ivory);
}

.neighborhoods__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacing-lg);
}

.neighborhood-card {
  background: white;
  padding: var(--spacing-xl);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  animation: fadeInUp 0.6s ease;
}

.neighborhood-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  color: var(--color-navy);
}

.neighborhood-card__title {
  color: var(--color-navy);
  font-size: 1.25rem;
  margin-bottom: var(--spacing-md);
}

.neighborhood-card__description {
  color: var(--color-text-light);
  flex: 1;
}

.neighborhood-card:hover .neighborhood-card__description {
  color: var(--color-text);
}

/* ========== TESTIMONIALS SECTION ========== */
.testimonials {
  padding: var(--spacing-2xl) 0;
  background: white;
}

.testimonials__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--spacing-xl);
}

.testimonial {
  background: var(--color-ivory);
  padding: var(--spacing-xl);
  border-radius: var(--radius-lg);
  border-left: 4px solid var(--color-gold);
  transition: all 0.3s ease;
  animation: fadeInUp 0.6s ease;
}

.testimonial:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.testimonial__stars {
  color: var(--color-gold);
  font-size: 1.1rem;
  margin-bottom: var(--spacing-md);
  letter-spacing: 2px;
}

.testimonial__quote {
  color: var(--color-text);
  margin-bottom: var(--spacing-md);
  font-style: italic;
  line-height: 1.8;
}

.testimonial__author {
  color: var(--color-text-light);
  font-weight: 600;
  font-size: 0.95rem;
}

/* ========== VALUATION SECTION ========== */
.valuation {
  padding: var(--spacing-2xl) 0;
  background: linear-gradient(135deg, var(--color-navy) 0%, #1a2d3f 100%);
  color: white;
}

.valuation__content {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.valuation__title {
  color: white;
  margin-bottom: var(--spacing-md);
  font-size: clamp(2rem, 5vw, 2.75rem);
}

.valuation__subtitle {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.1rem;
  margin-bottom: var(--spacing-xl);
}

.valuation__form {
  margin-top: var(--spacing-xl);
}

/* ========== CONTACT SECTION ========== */
.contact {
  padding: var(--spacing-2xl) 0;
  background: var(--color-ivory);
}

.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-2xl);
}

.contact__form-wrapper {
  background: white;
  padding: var(--spacing-xl);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.contact__map-wrapper {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
}

.contact__info {
  background: white;
  padding: var(--spacing-lg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.contact__info h3 {
  margin-bottom: var(--spacing-md);
}

.contact__info p {
  margin-bottom: var(--spacing-sm);
  color: var(--color-text-light);
}

.contact__info a {
  color: var(--color-gold);
  font-weight: 600;
  text-decoration: none;
}

.contact__info a:hover {
  text-decoration: underline;
}

@media (max-width: 768px) {
  .contact__grid {
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
  }
}

/* ========== FORMS ========== */
.form__group {
  margin-bottom: var(--spacing-lg);
}

.form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-lg);
}

input[type="text"],
input[type="email"],
input[type="tel"],
select,
textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--color-text);
  transition: all 0.3s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--color-gold);
  box-shadow: 0 0 0 3px rgba(201, 162, 39, 0.1);
}

textarea {
  resize: none;
  font-family: var(--font-body);
}

@media (max-width: 768px) {
  .form__row {
    grid-template-columns: 1fr;
  }
}

/* ========== FOOTER ========== */
.footer {
  background: var(--color-navy);
  color: white;
  padding: var(--spacing-2xl) 0;
  border-top: 1px solid rgba(201, 162, 39, 0.2);
}

.footer__content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacing-2xl);
}

.footer__logo {
  font-size: 1.25rem;
  margin-bottom: var(--spacing-md);
}

.footer__tagline {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
}

.footer__brand p,
.footer__contact p,
.footer__links p,
.footer__legal p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.95rem;
  margin-bottom: var(--spacing-sm);
}

.footer__contact p,
.footer__links p {
  line-height: 1.8;
}

.footer__social {
  color: var(--color-gold);
  text-decoration: none;
  margin-right: var(--spacing-md);
  font-weight: 500;
}

.footer__social:hover {
  text-decoration: underline;
}

.footer__legal p:first-child {
  color: var(--color-gold);
  font-weight: 600;
}

@media (max-width: 768px) {
  .footer__content {
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
  }
}

/* ========== MODAL ========== */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}

.modal.active {
  display: flex;
}

.modal__content {
  background: white;
  padding: var(--spacing-xl);
  border-radius: var(--radius-lg);
  max-width: 500px;
  width: 90%;
  position: relative;
  animation: slideIn 0.3s ease;
}

.modal__close {
  position: absolute;
  top: var(--spacing-md);
  right: var(--spacing-md);
  background: none;
  border: none;
  font-size: 2rem;
  cursor: pointer;
  color: var(--color-text-light);
}

.modal__close:hover {
  color: var(--color-navy);
}

.modal h3 {
  margin-bottom: var(--spacing-md);
}

.modal p {
  margin-bottom: var(--spacing-lg);
}

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

@keyframes slideIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Intersection Observer animation trigger */
.fade-in {
  animation: fadeInUp 0.6s ease;
}

/* ========== ACCESSIBILITY ========== */
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}

/* High contrast mode */
@media (prefers-contrast: more) {
  :root {
    --color-border: rgba(201, 162, 39, 0.3);
  }

  .btn--primary {
    border-width: 3px;
  }
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
  body {
    background: var(--color-navy);
    color: #f0f0f0;
  }

  .hero__heading,
  .hero__subheading {
    color: white;
  }
}
