/* Base & Variables */
:root {
  --primary-color: #1a3622; /* Deep Olive Green */
  --secondary-color: #c9a25b; /* Elegant Warm Gold */
  --accent-color: #c9a25b; /* Elegant Warm Gold */
  --text-color: #2b2b2b;
  --text-light: #5c5c5c;
  --bg-light: #f4f6f5; /* Soft grey-green tint */
  --bg-dark: #121c17; /* Dark Olive */
  --bg-card-dark: rgba(26, 38, 30, 0.66);
  --white: #ffffff;
  --black: #000000;
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  --border-radius: 8px;
  --box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  --box-shadow-dark: 0 10px 35px rgba(0, 0, 0, 0.45);
  /* Glassmorphism Variables */
  --glass-bg: rgba(255, 255, 255, 0.15);
  --glass-border: rgba(255, 255, 255, 0.2);
  --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.2);
  --glass-backdrop-blur: blur(10px);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  scroll-behavior: smooth;
}

body {
  font-family: "Poppins", sans-serif;
  color: var(--text-color);
  line-height: 1.6;
  background-color: var(--white);
  overflow-x: hidden;
}

/* Custom Premium Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--bg-light);
}

body.dark ::-webkit-scrollbar-track {
  background: #0f1511;
}

::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--secondary-color);
}

body.dark {
  background-color: var(--bg-dark);
  color: #f0f5ff;
}

body.dark .navbar,
body.dark .hero,
body.dark .about,
body.dark .properties,
body.dark .videos,
body.dark .testimonials,
body.dark .agent,
body.dark .contact,
body.dark footer {
  background-color: rgba(18, 24, 44, 0.94);
}

body.dark .navbar.scrolled {
  background-color: rgba(18, 24, 44, 0.94);
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

body.dark .navbar .nav-links a,
body.dark .navbar .brand-name,
body.dark .navbar .brand-sub {
  color: #f1f3ff;
}

body.dark .btn-primary {
  background-color: #3b7a54;
  border-color: #3b7a54;
  color: #fff !important;
}

body.dark .btn-outline {
  background-color: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
  color: #f1f3ff;
}

body.dark .property-card,
body.dark .details-card,
body.dark .agent-profile,
body.dark .testimonial-card,
body.dark .video-card,
body.dark .contact-info,
body.dark .contact-form {
  background: var(--bg-card-dark);
  box-shadow: var(--box-shadow-dark);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark input,
body.dark textarea,
body.dark select {
  background: rgba(255, 255, 255, 0.08);
  color: #ebf2ff;
  border: 1px solid rgba(255, 255, 255, 0.16);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Playfair Display", serif;
  font-weight: 700;
  line-height: 1.2;
}

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

ul {
  list-style: none;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: 80px 0;
}

.bg-light {
  background-color: var(--bg-light);
}

/* Glassmorphism Effect */
.glassmorphism {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop-blur);
  -webkit-backdrop-filter: var(--glass-backdrop-blur);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
}

/* Typography & Utilities */
.highlight {
  color: var(--secondary-color);
}

.highlight-text {
  color: var(--primary-color);
}

.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  border: 2px solid transparent;
}

.btn-primary {
  background-color: var(--primary-color);
  color: var(--white) !important;
}

.btn-primary:hover {
  background-color: transparent;
  border-color: var(--primary-color);
  color: var(--primary-color) !important;
}

.btn-gold {
  background-color: var(--secondary-color);
  color: var(--white) !important;
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.4);
}

.btn-gold:hover {
  background-color: var(--white);
  color: var(--secondary-color) !important;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(212, 175, 55, 0.5);
}

.btn-outline {
  background-color: transparent;
  border-color: var(--primary-color);
  color: var(--primary-color);
}

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

.btn-block {
  display: flex;
  width: 100%;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

.section-title {
  text-align: center;
  margin-bottom: 50px;
}

.section-title h2 {
  font-size: 2.5rem;
  margin-bottom: 10px;
}

.underline {
  height: 3px;
  width: 60px;
  background: linear-gradient(
    to right,
    var(--primary-color),
    var(--secondary-color)
  );
  margin: 0 auto;
  border-radius: 3px;
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 20px 0;
  z-index: 1000;
  transition: var(--transition);
  background-color: transparent;
}

.navbar.scrolled {
  background-color: var(--white);
  padding: 10px 0;
  box-shadow: var(--box-shadow);
  /* Add glassmorphism */
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop-blur);
  -webkit-backdrop-filter: var(--glass-backdrop-blur);
  border-bottom: 1px solid var(--glass-border);
}

.navbar.scrolled .nav-links a {
  color: var(--text-color);
}

.navbar.scrolled .logo-icon {
  color: var(--primary-color);
}

.navbar.scrolled .brand-name {
  color: var(--primary-color);
}

.navbar.scrolled .brand-sub {
  color: var(--text-color);
}

.navbar.scrolled .hamburger i {
  color: var(--primary-color);
}

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

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

.logo-icon {
  font-size: 2rem;
  color: var(--white);
  transition: var(--transition);
}

.logo-text {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-family: "Playfair Display", serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1;
  transition: var(--transition);
}

.brand-sub {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--secondary-color);
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: var(--transition);
}

.group-name {
  color: #e74c3c; /* RkGroup accent color from image */
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav-links a {
  color: var(--white);
  font-weight: 500;
  position: relative;
  transition: var(--transition);
}

.nav-links a:not(.btn)::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--secondary-color);
  transition: var(--transition);
}

.nav-links a:not(.btn):hover::after {
  width: 100%;
}

.hamburger {
  display: none;
  font-size: 1.8rem;
  color: var(--white);
  cursor: pointer;
}

/* Hero Section */
.hero {
  height: 100vh;
  min-height: 600px;
  position: relative;
  background-color: var(--primary-color);
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-slider {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  overflow: hidden;
}

.hero-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0;
  transition: opacity 1.5s ease-in-out;
  transform: scale(1);
}

.hero-slide.active {
  opacity: 1;
  animation: zoomBg 20s forwards linear;
}

@keyframes zoomBg {
  0% {
    transform: scale(1);
  }
  100% {
    transform: scale(1.15);
  }
}

.cursor {
  display: inline-block;
  color: var(--secondary-color);
  font-weight: bold;
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0;
  }
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to right,
    rgba(26, 54, 34, 0.8) 0%,
    rgba(26, 54, 34, 0.4) 50%,
    rgba(0, 0, 0, 0.2) 100%
  );
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  color: var(--white);
  max-width: 800px;
}

.hero-content h1 {
  font-size: 4.5rem;
  margin-bottom: 20px;
}

.hero-content p {
  font-size: 1.2rem;
  margin-bottom: 30px;
  opacity: 0.9;
  max-width: 600px;
}

.hero-actions {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.hero-actions .btn-outline-hero {
  border-color: #fff;
  color: #fff;
  background-color: rgba(255, 255, 255, 0.15);
  transition: all 0.3s ease;
}

.hero-actions .btn-outline-hero:hover {
  background-color: rgba(255, 255, 255, 0.25);
  color: #fff;
}

#themeToggle {
  margin-right: 10px;
  font-size: 0.85rem;
  min-width: 130px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
}

#themeToggle .theme-icon {
  font-size: 1rem;
}

#themeToggle .theme-label {
  font-size: 0.85rem;
}

@media (max-width: 768px) {
  #themeToggle {
    width: 40px;
    min-width: 40px;
    padding: 0;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
  }

  #themeToggle .theme-label {
    display: none;
  }
}

.contact-title {
  margin-bottom: 20px;
  color: var(--primary-color);
}

.input-icon {
  top: 15px;
  transform: translateY(0);
}

/* Hero Search Bar */
.hero-search {
  margin: 30px 0;
  max-width: 650px;
  padding: 8px 8px 8px 20px;
  border-radius: 50px;
  /* Glassmorphism for search bar */
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.15);
}

.search-form {
  display: flex;
  align-items: center;
  gap: 10px;
}

.search-input-group {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-input-group i {
  color: var(--white);
  font-size: 1.1rem;
  opacity: 0.8;
}

.search-input-group input {
  width: 100%;
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 1rem;
  color: var(--white);
  background: transparent;
}

.search-input-group input::placeholder {
  color: rgba(255, 255, 255, 0.7);
  opacity: 1; /* Firefox */
}

.search-divider {
  width: 1px;
  height: 24px;
  background-color: rgba(255, 255, 255, 0.3);
  margin: 0 5px;
}

.search-select {
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 1rem;
  color: var(--white);
  background: transparent;
  cursor: pointer;
  padding-right: 5px;
}

.search-select option {
  color: var(--text-color); /* Set dropdown option text color */
}

.search-select:hover {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

.search-btn {
  padding: 12px 30px;
  border-radius: 50px;
  white-space: nowrap;
  border: none;
}

.curve-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  overflow: hidden;
  line-height: 0;
  transform: rotate(180deg);
}

.curve-bottom svg {
  position: relative;
  display: block;
  width: calc(100% + 1.3px);
  height: 120px;
}

.curve-bottom .shape-fill {
  fill: #ffffff;
}

/* About Section */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
}

.about-text h3 {
  font-size: 2rem;
  margin-bottom: 20px;
  color: var(--primary-color);
}

.about-text p {
  color: var(--text-light);
  margin-bottom: 20px;
  font-size: 1.1rem;
}

.features-list li {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 15px;
  font-weight: 500;
}

.features-list i {
  color: var(--secondary-color);
  font-size: 1.5rem;
}

.about-image {
  position: relative;
}

.about-image img {
  width: 100%;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  transition: var(--transition);
}

.about-image:hover img {
  transform: scale(1.02);
}

.about-image::before {
  content: "";
  position: absolute;
  top: -20px;
  right: -20px;
  width: 100%;
  height: 100%;
  border: 3px solid var(--secondary-color);
  border-radius: var(--border-radius);
  z-index: -1;
}

/* Properties Section */
.property-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  overflow-x: hidden;
  margin-top: 15px;
}

.property-card {
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--glass-shadow);
  transition: var(--transition);
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop-blur);
  -webkit-backdrop-filter: var(--glass-backdrop-blur);
  border: 1px solid var(--glass-border);
}

.property-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.22);
  background: rgba(255, 255, 255, 0.4);
}

.card-img {
  position: relative;
  height: 250px;
  overflow: hidden;
  background-color: #f4f4f4;
}

.card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.5s ease;
}

.property-card:hover .card-img img {
  transform: scale(1.1);
}

.badge {
  position: absolute;
  top: 20px;
  right: 20px;
  background-color: var(--secondary-color);
  color: var(--white);
  padding: 5px 15px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  z-index: 2;
}

.card-content {
  padding: 25px;
}

.card-content h3 {
  font-size: 1.5rem;
  margin-bottom: 10px;
  color: var(--primary-color);
}

.card-content p {
  color: var(--text-light);
  font-size: 0.95rem;
  margin-bottom: 20px;
}

.card-actions {
  display: flex;
  gap: 10px;
  margin-top: auto;
}

.btn-sm {
  padding: 8px 15px;
  font-size: 0.85rem;
  flex: 1;
}

/* Testimonials Section */
.testimonial-slider-wrapper {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
}

.testimonial-grid {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  gap: 30px;
  padding-bottom: 20px;
  /* Hide scrollbar */
  -ms-overflow-style: none; /* IE and Edge */
  scrollbar-width: none; /* Firefox */
}

.testimonial-grid::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

.testimonial-card {
  flex: 0 0 calc(33.333% - 20px); /* Show 3 cards on desktop */
  scroll-snap-align: start;
  padding: 30px;
  border-radius: var(--border-radius);
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop-blur);
  -webkit-backdrop-filter: var(--glass-backdrop-blur);
  border: 1px solid var(--glass-border);
  box-shadow: var(--box-shadow);
  transition: var(--transition);
}

.testimonial-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.quote-icon {
  font-size: 2rem;
  color: var(--secondary-color);
  margin-bottom: 20px;
  opacity: 0.5;
}

.testimonial-text {
  font-size: 1rem;
  font-style: italic;
  margin-bottom: 20px;
  color: var(--text-color);
}

.author-info h4 {
  color: var(--primary-color);
  font-size: 1.1rem;
  margin-bottom: 5px;
}

.stars i {
  color: var(--secondary-color);
  font-size: 0.9rem;
}

/* Agent Profile Section */
.agent-profile {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 50px;
  align-items: center;
  background: var(--white);
  border-radius: 15px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
  padding: 40px;
  /* Add glassmorphism */
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop-blur);
  -webkit-backdrop-filter: var(--glass-backdrop-blur);
  border: 1px solid var(--glass-border);
}

.agent-image {
  display: flex;
  justify-content: center;
  align-items: center;
}

.agent-image img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 550px;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
}

.agent-details h3 {
  font-size: 2.2rem;
  color: var(--primary-color);
  margin-bottom: 5px;
}

.agent-role {
  font-size: 1.1rem;
  color: var(--secondary-color);
  font-weight: 600;
  margin-bottom: 20px;
}

.agent-bio {
  color: var(--text-light);
  font-size: 1.05rem;
  margin-bottom: 25px;
  line-height: 1.8;
}

.agent-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 30px;
}

.agent-stats li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1rem;
  background: var(--bg-light);
  padding: 10px 15px;
  border-radius: 8px;
  color: var(--text-color);
}

.agent-stats i {
  color: var(--primary-color);
  font-size: 1.2rem;
}

.agent-cta {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

/* Contact Section */
.contact {
  background: linear-gradient(
    135deg,
    rgba(26, 54, 34, 0.05) 0%,
    rgba(201, 162, 91, 0.05) 100%
  );
}

.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 50px;
  background: var(--white);
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.08);
}

.contact-info {
  background-color: var(--primary-color);
  color: var(--white);
  padding: 50px;
  position: relative;
  overflow: hidden;
}

.contact-info::before {
  content: "";
  position: absolute;
  bottom: -50px;
  right: -50px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
}

.contact-info h2 {
  font-size: 2.2rem;
  margin-bottom: 15px;
}

.contact-info .highlight-text {
  color: var(--secondary-color);
}

.contact-info > p {
  margin-bottom: 40px;
  opacity: 0.9;
}

.info-item {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 30px;
}

.icon-box {
  width: 50px;
  height: 50px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.2rem;
  color: var(--secondary-color);
  flex-shrink: 0;
}

.info-item h4 {
  font-family: "Poppins", sans-serif;
  font-size: 1.1rem;
  margin-bottom: 5px;
  color: var(--secondary-color);
}

.info-item p {
  opacity: 0.9;
}

.contact-form {
  padding: 50px;
  position: relative;
}

.form-group {
  position: relative;
  margin-bottom: 25px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 15px 20px 15px 50px;
  border: 1px solid #e0e0e0;
  border-radius: var(--border-radius);
  font-family: inherit;
  font-size: 1rem;
  transition: var(--transition);
  background-color: var(--bg-light);
}

.form-group textarea {
  resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  background-color: var(--white);
  box-shadow: 0 0 0 4px rgba(26, 54, 34, 0.15);
}

.input-icon {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  transition: var(--transition);
}

.form-group input:focus ~ .input-icon,
.form-group textarea:focus ~ .input-icon {
  color: var(--primary-color);
}

.form-success {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--white);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 40px;
  z-index: 10;
  border-radius: 15px;
}

.form-success.hidden {
  display: none;
}

.form-success i {
  font-size: 5rem;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.form-success h3 {
  font-size: 2rem;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.form-success p {
  color: var(--text-light);
  margin-bottom: 30px;
}

/* Footer */
footer {
  background-color: #111;
  color: var(--white);
  padding: 30px 0;
  text-align: center;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

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

.footer-logo i {
  font-size: 2rem;
  color: var(--secondary-color);
}

.footer-logo .brand-name {
  color: var(--white);
}

.footer-logo .brand-sub {
  color: var(--text-light);
}

.social-links {
  display: flex;
  gap: 15px;
}

.social-links a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: center;
  align-items: center;
  transition: var(--transition);
}

.social-links a:hover {
  background-color: var(--secondary-color);
  transform: translateY(-3px);
}

/* Animations & Responsive */
@keyframes bounceIn {
  0% {
    transform: scale(0.8);
    opacity: 0;
  }
  60% {
    transform: scale(1.05);
    opacity: 1;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

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

@keyframes slideInLeft {
  from {
    transform: translateX(-50px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideInRight {
  from {
    transform: translateX(50px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

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

.bounce-in {
  animation: bounceIn 1s cubic-bezier(0.215, 0.61, 0.355, 1) forwards;
}
.fade-in-up {
  opacity: 0;
  animation: fadeInUp 0.8s ease forwards;
}
.slide-in-left {
  opacity: 0;
  animation: slideInLeft 0.8s ease forwards;
}
.slide-in-right {
  opacity: 0;
  animation: slideInRight 0.8s ease forwards;
}
.scale-up {
  opacity: 0;
  animation: scaleUp 0.8s ease forwards;
}

.delay-1 {
  animation-delay: 0.2s;
}
.delay-2 {
  animation-delay: 0.4s;
}

/* Property Details Page */
.page-header {
  height: 40vh;
  min-height: 300px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-top: 80px;
}

.page-header h1 {
  color: var(--white);
  font-size: 3.5rem;
  text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
}

.property-details-wrapper {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
}

.main-image-container {
  position: relative;
  border-radius: var(--border-radius);
  overflow: hidden;
  height: 500px;
  box-shadow: var(--box-shadow);
  margin-bottom: 20px;
  background-color: #f4f4f4;
  display: flex;
  align-items: center;
  justify-content: center;
}

.main-image-container img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: var(--transition);
}

.gallery-thumbs {
  display: flex;
  gap: 15px;
  margin-bottom: 40px;
  overflow-x: auto;
  padding-bottom: 10px;
}

.gallery-thumbs .gallery-img {
  width: 120px;
  height: 90px;
  border-radius: var(--border-radius);
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  flex-shrink: 0;
}

.gallery-thumbs .gallery-img:hover {
  border-color: var(--primary-color);
}

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

.details-card {
  background: var(--white);
  padding: 40px;
  border-radius: 15px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
  /* Add glassmorphism */
  background: var(--glass-bg);
  backdrop-filter: var(--glass-backdrop-blur);
  -webkit-backdrop-filter: var(--glass-backdrop-blur);
  border: 1px solid var(--glass-border);
}

.price-tag {
  font-size: 1.5rem;
  color: var(--secondary-color);
  font-weight: 700;
  margin-bottom: 20px;
}

.description p {
  color: var(--text-light);
  line-height: 1.8;
  margin-bottom: 30px;
}

.features-title {
  margin-bottom: 20px;
  color: var(--primary-color);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 15px;
}

.features-grid li {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-color);
}

.features-grid i {
  color: var(--secondary-color);
}

/* Sidebar */
.details-sidebar {
  position: sticky;
  top: 100px;
  height: fit-content;
}

.sidebar-agent {
  background: var(--white);
  padding: 40px 30px;
  border-radius: 15px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
  text-align: center;
}

.sidebar-agent-img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  margin-bottom: 15px;
  border: 3px solid var(--primary-color);
}

.sidebar-agent h3 {
  color: var(--primary-color);
  font-size: 1.4rem;
  margin-bottom: 5px;
}

.sidebar-agent p {
  color: var(--text-light);
  margin-bottom: 15px;
}

.agent-trust-badge {
  color: var(--primary-color) !important;
  font-weight: 600;
  background: rgba(26, 54, 34, 0.1);
  padding: 8px 15px;
  border-radius: 50px;
  display: inline-block;
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.sidebar-form {
  margin: 30px 0;
  text-align: left;
}

.sidebar-form h4 {
  margin-bottom: 15px;
  color: var(--primary-color);
}

.sidebar-form input {
  width: 100%;
  padding: 12px 15px;
  margin-bottom: 15px;
  border: 1px solid #e0e0e0;
  border-radius: var(--border-radius);
  font-family: inherit;
}

.sidebar-form input:focus {
  outline: none;
  border-color: var(--primary-color);
}

.sidebar-ctas {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

/* Floating WhatsApp Button */
.floating-wa {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background-color: #25d366;
  color: white;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 2.5rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  z-index: 1000;
  transition: var(--transition);
}

.floating-wa:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
  color: white;
}

/* Video Gallery Slider */
.videos {
  background-color: var(--white);
}

.video-slider-wrapper {
  position: relative;
  max-width: 1000px;
  margin: 40px auto 0;
}

.video-grid {
  display: flex;
  /* Enable horizontal scrolling and snapping */
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  gap: 30px;
  padding-bottom: 20px; /* Space for shadow */

  /* Hide scrollbar */
  -ms-overflow-style: none; /* IE and Edge */
  scrollbar-width: none; /* Firefox */
}

.video-grid::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

.video-card {
  /* Each card takes up 100% of the visible container */
  flex: 0 0 100%;
  scroll-snap-align: center;
  background-color: var(--white);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(0, 0, 0, 0.05);
}

.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  background: var(--white);
  color: var(--primary-color);
  border: none;
  border-radius: 50%;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 10;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: var(--transition);
}

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

.prev-btn {
  left: -25px;
}

.next-btn {
  right: -25px;
}

@media (max-width: 768px) {
  .slider-btn {
    width: 40px;
    height: 40px;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.9); /* Slightly transparent on mobile */
  }
  .prev-btn {
    left: 10px; /* Bring them inside the screen slightly */
  }
  .next-btn {
    right: 10px;
  }
}

.video-container {
  position: relative;
  width: 100%;
  /* 16:9 Aspect Ratio */
  padding-bottom: 56.25%;
  background-color: #000;
}

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

.video-info {
  padding: 20px;
  text-align: center;
}

.video-info h3 {
  font-size: 1.25rem;
  color: var(--primary-color);
}

/* Video Modal Styling */
.video-modal {
  display: none; /* Hidden by default */
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85); /* Black w/ opacity */
  opacity: 0;
  transition: opacity 0.4s ease;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  pointer-events: none; /* Disables interaction when hidden */
}

.video-modal.show-modal {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

.video-modal-content {
  position: relative;
  width: 100%;
  max-width: 800px;
  background-color: #000;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  transform: scale(0.9);
  transition: transform 0.4s ease;
  /* Removed overflow: hidden so close button can float outside the box. */
  /* Add glassmorphism overlay */
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.video-modal.show-modal .video-modal-content {
  transform: scale(1);
}

.close-video-modal {
  position: absolute;
  top: 20px;
  right: 30px;
  color: #fff;
  font-size: 50px;
  font-weight: bold;
  cursor: pointer;
  z-index: 2100; /* Ensure it is top most element above the modal overlay */
  text-shadow: 0 4px 15px rgba(0, 0, 0, 1);
  transition: color 0.3s;
  line-height: 1;
}

.close-video-modal:hover,
.close-video-modal:focus {
  color: var(--secondary-color);
  text-decoration: none;
}

.video-modal-container {
  width: 100%;
  /* 16:9 Aspect ratio container */
  padding-top: 56.25%;
  position: relative;
}

.video-modal-container video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #000;
}

/* Responsive Design */
@media (max-width: 992px) {
  .about-grid,
  .agent-profile {
    grid-template-columns: 1fr;
  }

  .agent-profile {
    padding: 30px 20px;
  }

  .contact-wrapper {
    grid-template-columns: 1fr;
  }

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

  .main-image-container {
    height: 350px;
  }

  .contact-info::before {
    display: none;
  }

  .testimonial-card {
    flex: 0 0 calc(50% - 15px); /* Show 2 cards on tablet */
  }
}

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

  .nav-links {
    position: absolute;
    top: 100%;
    left: -100%;
    width: 100%;
    background-color: var(--white);
    flex-direction: column;
    padding: 30px 0;
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
    transition: 0.4s ease;
  }

  .nav-links li {
    margin: 10px 0;
    text-align: center;
  }

  .nav-links.active {
    left: 0;
  }

  .nav-links a {
    color: var(--text-color);
    font-size: 1.1rem;
  }

  .hero-content h1 {
    font-size: 3rem;
  }

  .hero-search {
    border-radius: var(--border-radius);
    padding: 15px;
  }
  .search-form {
    flex-direction: column;
  }
  .search-input-group {
    flex-wrap: wrap;
    width: 100%;
    padding: 0;
    border-bottom: none;
    margin-bottom: 15px;
  }
  .search-input-group input {
    flex: 1;
    min-width: 150px;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
  }
  .search-divider {
    display: none;
  }
  .search-select {
    width: 100%;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    margin-top: 5px;
  }
  .search-btn {
    width: 100%;
  }

  .section {
    padding: 60px 0;
  }

  .contact-form,
  .contact-info {
    padding: 30px 20px;
  }

  .testimonial-card {
    flex: 0 0 100%; /* Show 1 card on mobile */
  }

  /* 2-column property cards on tablet, 1-column on small phones */
  .property-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px;
  }
}

@media (max-width: 480px) {
  .property-grid {
    grid-template-columns: repeat(1, 1fr) !important;
    gap: 12px;
  }

  .card-content {
    padding: 12px !important;
  }

  .card-content h3 {
    font-size: 1rem !important;
  }

  .property-location {
    font-size: 0.8rem !important;
  }

  .card-content p:not(.property-location) {
    display: none !important;
  }
}
/* Style 2-column property cards for mobile readability */
.card-content {
  padding: 10px !important;
  text-align: center;
}
.card-content h3 {
  font-size: 0.85rem !important;
  margin-bottom: 5px !important;
  line-height: 1.2;
}
.property-location {
  font-size: 0.7rem !important;
  margin-bottom: 8px !important;
  line-height: 1.2;
}
.card-content p:not(.property-location) {
  display: none !important; /* Hide description only */
}

/* Restore and scale buttons for 2-column mobile layout */
.card-actions {
  display: flex !important;
  flex-direction: column;
  gap: 5px;
  margin-top: auto;
}
.btn-sm {
  padding: 6px 5px !important;
  font-size: 0.65rem !important;
  width: 100%;
}

.badge {
  font-size: 0.55rem;
  padding: 4px 8px;
  top: 5px;
  right: 5px;
}

@media (max-width: 480px) {
  .hero-content h1 {
    font-size: 2.2rem;
  }

  .section-title h2 {
    font-size: 2rem;
  }
}
