/* Luxury Real Estate Style - JamesEdition Inspired */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Luxury Color Palette */
  --primary-black: #000000;
  --dark-gray: #1a1a1a;
  --medium-gray: #666666;
  --light-gray: #999999;
  --border-gray: #e5e5e5;
  --background-gray: #e6eaef;
  --white: #ffffff;
  --gold-accent: #c9a961;

  /* Typography */
  --font-primary: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --font-secondary: Georgia, 'Times New Roman', serif;

  /* Spacing */
  --spacing-xs: 8px;
  --spacing-sm: 16px;
  --spacing-md: 24px;
  --spacing-lg: 32px;
  --spacing-xl: 48px;
  --spacing-xxl: 64px;

  /* Theme surfaces */
  --page-bg: #e6eaef;
  --panel-bg: #eef1f4;
  --card-bg: #f9fafb;
  --card-border: #e6e8ee;
}

/* Base Typography */
html {
  background-color: var(--page-bg);
}

body {
  font-family: var(--font-primary);
  font-size: 14px;
  line-height: 1.6;
  color: var(--dark-gray);
  background-color: var(--page-bg);
  font-weight: 300;
  letter-spacing: 0.3px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 300;
  letter-spacing: -0.5px;
  color: var(--primary-black);
  margin: 0;
}

h1 {
  font-size: 48px;
  line-height: 1.1;
  font-weight: 200;
  letter-spacing: -1px;
}

h2 {
  font-size: 32px;
  line-height: 1.2;
  font-weight: 300;
}

h3 {
  font-size: 24px;
  line-height: 1.3;
}

h4 {
  font-size: 18px;
  line-height: 1.4;
}

a {
  color: inherit;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

a:hover {
  opacity: 0.7;
}

/* Skip to main content link */
.skip-to-main:focus {
  position: fixed;
  top: 10px;
  left: 10px;
  background: var(--primary-black);
  color: var(--white);
  padding: 12px 16px;
  text-decoration: none;
  border-radius: 4px;
  z-index: 9999;
}

/* Container */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

.container-full {
  max-width: 100%;
  padding: 0 var(--spacing-lg);
}

/* Luxury Header */
.luxury-header {
  background: var(--panel-bg);
  border-bottom: 1px solid var(--border-gray);
  position: relative; /* Changed from fixed to not block content */
  width: 100%;
  z-index: 1000;
}

.header-top {
  border-bottom: 1px solid var(--border-gray);
  padding: var(--spacing-xs) 0;
  font-size: 12px;
  color: var(--medium-gray);
}

.header-top-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-phone-link {
  color: inherit;
  text-decoration: underline;
}

.header-main {
  padding: var(--spacing-md) 0;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Header tweaks for small screens */
@media (max-width: 480px) {
  .header-main {
    padding: var(--spacing-sm) 0;
  }
  .logo .company-name {
    font-size: 18px;
    letter-spacing: 1px;
  }
}

.gti-hero {
  position: relative;
  background: linear-gradient(180deg, #e2e7ef 0%, #dbe2ec 100%);
  overflow: hidden;
}

.gti-hero-content {
  position: relative;
  z-index: 2;
  max-width: 760px;
  padding: var(--spacing-md) 0;
}

.gti-hero-title {
  font-size: 56px;
  line-height: 1.05;
  font-weight: 200;
  letter-spacing: -1.2px;
  margin-bottom: var(--spacing-sm);
}

.gti-hero-subtitle {
  font-size: 18px;
  color: var(--medium-gray);
  margin-bottom: var(--spacing-lg);
}

.gti-hero-cta {
  display: inline-block;
}

.gti-hero-media {
  position: absolute;
  bottom: 40px;
  left: 0;
  right: 0;
  overflow: hidden;
  z-index: 1;
  mask-image: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.9),
    rgba(0, 0, 0, 0.2),
    rgba(0, 0, 0, 0)
  );
  content-visibility: auto; /* Performance optimization */
}

.media-row {
  display: flex;
  gap: var(--spacing-md);
  padding: 0 var(--spacing-lg);
}

.media-strip {
  display: inline-flex;
  gap: var(--spacing-md);
  animation: hero-scroll 200s linear infinite;
}

.media-strip img {
  height: 180px;
  width: 270px;
  object-fit: cover;
  border: 1px solid var(--border-gray);
  background: var(--background-gray);
}

@keyframes hero-scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

.logo {
  display: flex;
  align-items: center;
  gap: 15px;
}

.logo img {
  height: 70px;
  width: auto;
  object-fit: contain;
}

.logo .company-name {
  font-size: 24px;
  font-weight: 300;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--primary-black);
}

/* Luxury Navigation */
.luxury-nav {
  display: flex;
  gap: var(--spacing-xl);
  align-items: center;
}

.luxury-nav a {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--dark-gray);
  font-weight: 400;
  position: relative;
  padding: 12px 8px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.luxury-nav a::after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--primary-black);
  transition: width 0.3s ease;
}

.luxury-nav a:hover::after {
  width: 100%;
}

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

.btn-icon {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
  color: var(--dark-gray);
  padding: var(--spacing-xs);
}

/* Search Bar - Luxury Style */
.search-luxury {
  background: var(--background-gray);
  padding: var(--spacing-lg) 0;
  /* Removed margin-top since header is no longer fixed */
}

.search-container {
  display: flex;
  gap: var(--spacing-sm);
  align-items: center;
  background: var(--card-bg);
  border: 1px solid var(--border-gray);
  padding: var(--spacing-xs);
}

.search-field {
  flex: 1;
  display: flex;
  align-items: center;
  border-right: 1px solid var(--border-gray);
  padding: 0 var(--spacing-md);
}

.search-field:last-of-type {
  border-right: none;
}

.search-field input,
.search-field select {
  width: 100%;
  border: none;
  outline: none;
  font-size: 14px;
  padding: var(--spacing-sm);
  background: transparent;
  font-family: var(--font-primary);
}

.search-field label {
  font-size: 11px;
  text-transform: uppercase;
  color: var(--medium-gray);
  letter-spacing: 1px;
  margin-right: var(--spacing-sm);
  min-width: 80px;
}

.btn-search {
  background: var(--primary-black);
  color: var(--white);
  border: none;
  padding: var(--spacing-sm) var(--spacing-lg);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: background 0.3s ease;
  font-weight: 400;
}

.btn-search:hover {
  background: var(--dark-gray);
}

/* Filter Bar */
.filter-bar {
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-gray);
  padding: var(--spacing-sm) 0;
}

.filter-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.map-embed {
  width: 100%;
  height: 360px;
  border: 0;
}
.section-spaced {
  margin-top: var(--spacing-lg);
}

.filter-tags {
  display: flex;
  gap: var(--spacing-sm);
  align-items: center;
}

.filter-tag {
  padding: 12px 16px; /* Larger tap target - min 48px height */
  min-height: 48px;
  min-width: 48px;
  border: 1px solid var(--card-border);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: all 0.2s ease;
  background: var(--card-bg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-primary);
  font-weight: 400;
  color: var(--dark-gray);
}

.filter-tag:hover {
  background: var(--primary-black);
  color: var(--white);
  border-color: var(--primary-black);
}

.filter-tag.active {
  background: var(--primary-black);
  color: var(--white);
  border-color: var(--primary-black);
}

.results-count {
  font-size: 13px;
  color: var(--medium-gray);
}

/* Property Grid - Luxury */
.property-grid-luxury {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px; /* Better spacing between cards */
  margin-top: var(--spacing-lg);
}

.property-card-luxury {
  background: var(--card-bg);
  position: relative;
  overflow: hidden;
  border: 1px solid var(--card-border);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%; /* Ensure all cards are same height */
  contain: layout style paint; /* Performance optimization */
}

.property-card-clickable {
  cursor: pointer;
}

.property-card-static {
  cursor: default;
}

.property-card-luxury:hover {
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.property-card-luxury:hover .property-image-luxury img {
  transform: scale(1.05);
}

.property-image-luxury {
  position: relative;
  width: 100%;
  height: 300px; /* Fixed height for all images */
  aspect-ratio: 3 / 2; /* Maintain aspect ratio */
  overflow: hidden;
  background: var(--background-gray);
}

.property-image-luxury img {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  object-fit: cover; /* Ensures image covers entire container */
  object-position: center center;
  transition: transform 0.5s ease;
}

/* Support for custom image positioning via data-position attribute */
.property-image-luxury img[data-position] {
  object-position: var(--img-position, center center);
}

.property-card-luxury:hover .property-image-luxury img {
  transform: translate(-50%, -50%) scale(1.05);
}

.property-label {
  position: absolute;
  top: var(--spacing-md);
  left: var(--spacing-md);
  background: var(--white);
  padding: 6px 12px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 500;
  z-index: 1;
}

/* Badge Styles - Modular System */
.property-badge-featured {
  background: var(--gold-accent);
  color: var(--white);
}

.property-badge-new {
  background: #22c55e;
  color: var(--white);
}

.property-badge-hot {
  background: #ef4444;
  color: var(--white);
}

.property-badge-available {
  background: #3b82f6;
  color: var(--white);
}

.property-badge-reduced {
  background: #f97316;
  color: var(--white);
}

.property-badge-default {
  background: var(--white);
  color: var(--dark-gray);
}

/* Legacy support */
.property-label.exclusive {
  background: var(--primary-black);
  color: var(--white);
}

.property-info-luxury {
  padding: var(--spacing-md);
  flex: 1; /* Takes remaining space */
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.property-location-luxury {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--medium-gray);
  margin-bottom: var(--spacing-xs);
}

.property-title-luxury {
  font-size: 16px;
  font-weight: 400;
  color: var(--primary-black);
  margin-bottom: var(--spacing-xs);
  line-height: 1.4;
}

.property-details-luxury {
  display: flex;
  gap: var(--spacing-md);
  margin: var(--spacing-sm) 0;
  font-size: 13px;
  color: var(--medium-gray);
}

.property-detail {
  display: flex;
  align-items: center;
  gap: 4px;
}

.property-view-details {
  margin-top: 0.5rem;
  font-size: 0.875rem;
  color: #0066cc;
}

.property-price-luxury {
  font-size: 18px;
  font-weight: 400;
  color: var(--primary-black);
  margin-top: var(--spacing-sm);
}

.property-price-luxury .period {
  font-size: 13px;
  color: var(--medium-gray);
  font-weight: 300;
}

/* Featured Section */
.featured-section {
  padding: var(--spacing-xxl) 0;
  background: var(--background-gray);
}

.section-header {
  text-align: center;
  margin-bottom: var(--spacing-xl);
}

.section-subtitle {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--medium-gray);
  margin-bottom: var(--spacing-sm);
}

.section-title {
  font-size: 36px;
  font-weight: 200;
  color: var(--primary-black);
}

/* Luxury Buttons */
.btn-luxury {
  background: var(--card-bg);
  color: var(--primary-black);
  border: 1px solid var(--primary-black);
  padding: var(--spacing-sm) var(--spacing-lg);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 400;
}

.btn-luxury:hover {
  background: var(--primary-black);
  color: var(--white);
}

.btn-luxury-primary {
  background: var(--primary-black);
  color: var(--white);
}

.btn-luxury-primary:hover {
  background: var(--dark-gray);
}

/* Footer Luxury */
.footer-luxury {
  background: var(--primary-black);
  color: var(--white);
  padding: var(--spacing-xxl) 0 var(--spacing-lg);
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: var(--spacing-xxl);
  margin-bottom: var(--spacing-xl);
}

.footer-bottom-links {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: var(--spacing-lg);
  text-align: center;
}

.footer-brand h3 {
  font-size: 24px;
  font-weight: 300;
  letter-spacing: 1px;
  margin-bottom: var(--spacing-md);
}

.footer-brand p {
  font-size: 13px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.7);
}

.footer-column h3 {
  font-size: 16px;
  font-weight: 400;
  letter-spacing: 1px;
  margin-bottom: var(--spacing-md);
  text-transform: uppercase;
}

.footer-disclosure {
  font-size: 13px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.7);
}

.footer-trec-links {
  margin-bottom: var(--spacing-md);
  font-size: 12px;
  line-height: 2;
}

.footer-trec-links a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-trec-links a:hover {
  color: var(--white);
}

.footer-legal-links {
  margin-bottom: var(--spacing-md);
  font-size: 11px;
  opacity: 0.7;
}

.footer-legal-links a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-legal-links a:hover {
  color: var(--white);
}

.footer-copyright {
  font-size: 11px;
  opacity: 0.5;
  margin: 0;
}

.footer-credit {
  margin-top: var(--spacing-sm);
  font-size: 11px;
  letter-spacing: 0.5px;
  color: rgba(255, 255, 255, 0.35);
}

.footer-credit a {
  color: rgba(255, 255, 255, 0.5);
  text-decoration: none;
  transition: color 0.3s ease;
  font-weight: 400;
}

.footer-credit a:hover {
  color: var(--white);
}

.footer-column h4 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: var(--spacing-md);
  font-weight: 400;
}

.footer-column ul {
  list-style: none;
}

.footer-column li {
  margin-bottom: var(--spacing-xs);
}

.footer-column a {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
  transition: color 0.2s ease;
}

.footer-column a:hover {
  color: var(--white);
}

.footer-bottom {
  padding-top: var(--spacing-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

/* Responsive */
@media (max-width: 1024px) {
  .gti-hero-title {
    font-size: 44px;
  }
  .media-strip img {
    height: 160px;
    width: 240px;
  }
  .property-grid-luxury {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile menu toggle */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  z-index: 1001;
}

.mobile-menu-toggle span {
  display: block;
  width: 25px;
  height: 2px;
  background: var(--primary-black);
  margin: 5px 0;
  transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(7px, 7px);
}

.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

@media (max-width: 768px) {
  .mobile-menu-toggle {
    display: block;
  }

  .logo img {
    height: 60px;
  }

  .luxury-nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 250px;
    height: 100vh;
    background: var(--white);
    flex-direction: column;
    align-items: flex-start;
    padding: 80px 30px 30px;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
    transition: right 0.3s ease;
    z-index: 1000;
    gap: 0;
  }

  .luxury-nav.active {
    right: 0;
  }

  .luxury-nav a {
    font-size: 16px;
    padding: 15px 0;
    width: 100%;
    border-bottom: 1px solid var(--border-gray);
  }

  .luxury-nav a::after {
    display: none;
  }

  /* Overlay when menu is open */
  body.menu-open::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
  }

  body.menu-open {
    overflow: hidden;
  }

  /* Mobile button sizing */
  .btn-luxury {
    padding: 12px 24px;
    font-size: 11px;
  }

  .gti-hero-content {
    padding: var(--spacing-sm) 0;
  }
  .gti-hero-title {
    font-size: 32px;
    margin-bottom: 8px;
  }
  .gti-hero-subtitle {
    font-size: 14px;
    margin-bottom: var(--spacing-md);
  }
  .gti-hero-media {
    bottom: 20px;
  }
  .media-strip img {
    height: 100px;
    width: 150px;
  }

  .property-grid-luxury {
    grid-template-columns: 1fr;
  }

  .search-container {
    flex-direction: column;
  }

  .search-field {
    border-right: none;
    border-bottom: 1px solid var(--border-gray);
    width: 100%;
  }
  .search-field:last-of-type {
    border-bottom: none;
  }
  .search-container {
    gap: var(--spacing-xs);
  }

  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .footer-bottom {
    flex-direction: column;
    gap: var(--spacing-sm);
  }
}
/* Enhanced Responsive Design */
@media (max-width: 1400px) {
  .property-grid-luxury {
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
  }
}

@media (max-width: 1200px) {
  .property-grid-luxury {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .property-image-luxury {
    height: 280px;
  }
}

@media (max-width: 768px) {
  .property-image-luxury {
    height: 250px;
  }

  .filter-content {
    flex-direction: column;
    align-items: stretch;
    gap: var(--spacing-sm);
  }
  .filter-tags {
    width: 100%;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
    overflow-x: visible;
    white-space: normal;
  }
  .results-count {
    margin-top: var(--spacing-xs);
  }

  .btn-search {
    width: 100%;
    padding: var(--spacing-md);
  }
}

@media (max-width: 480px) {
  .gti-hero-title {
    font-size: 28px;
  }
  .gti-hero-subtitle {
    font-size: 13px;
  }
  .media-strip img {
    height: 80px;
    width: 120px;
  }

  .property-grid-luxury {
    gap: 15px;
  }

  .property-image-luxury {
    height: 200px;
  }

  .logo {
    font-size: 18px;
    text-align: center;
  }

  .header-top {
    display: none;
  }
}

/* Utility refinements */
.section-properties {
  padding: 40px 0;
}
.load-more-container {
  text-align: center;
  margin-top: 60px;
}

/* Content Page Styling */
.section-properties h1 {
  margin-bottom: 1rem;
}

.section-properties h2 {
  margin-top: 3rem;
  margin-bottom: 1rem;
}

.section-properties h3 {
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  font-size: 20px;
}

.section-properties p {
  line-height: 1.8;
  margin-bottom: 1rem;
}

.section-properties ul {
  margin: 1rem 0;
  padding-left: 2rem;
  line-height: 1.8;
}

.section-properties li {
  margin-bottom: 0.5rem;
}

.section-properties section {
  margin: 3rem 0;
}

.intro-text {
  margin: 2rem 0;
  font-size: 16px;
  color: var(--medium-gray);
}

.content-section {
  margin: 2rem 0;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}

.info-card {
  padding: 2rem;
  background: var(--card-bg);
  border-radius: 8px;
  border: 1px solid var(--card-border);
}

.info-card h2,
.info-card h3 {
  margin-top: 0;
  margin-bottom: 1rem;
}

.cta-section {
  margin: 3rem 0;
  padding: 2rem;
  background: #f5f5f5;
  border-radius: 8px;
  text-align: center;
}

.cta-section h2 {
  margin-top: 0;
}

.cta-section p {
  margin: 1rem 0;
}

.map-container {
  margin: 2rem 0;
}

.map-embed {
  width: 100%;
  height: 450px;
  border: 0;
  border-radius: 8px;
}
