/* Base Styles */
html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  font-family: "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.4286;
  color: #ffffff;
  background-color: #515151;
  text-align: center;
  font-weight: normal;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
  font-family: "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-weight: normal;
  line-height: 1.1;
  color: #333;
}
h1 { font-size: 45px; line-height: 48px; }
h2 { font-size: 36px; line-height: 40px; }
h3 { font-size: 30px; line-height: 32px; }
h4 { font-size: 26px; line-height: 28px; }
h5 { font-size: 20px; line-height: 24px; }
h6 { font-size: 18px; line-height: 22px; }

/* Links */
a {
  color: black;
  text-decoration: none;
}
a:hover, a:focus {
  color: #3282e6;
  text-decoration: underline;
}

/* Top bar */
.top-bar {
  height: 20px;
  background: linear-gradient(to bottom, #71a100 0%, #6fa100 100%);
}

/* Navigation */
nav {
  background-color: #333;
  font-size: 18px;
}
nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: space-around;
  align-items: center;
}
nav ul li a {
  display: block;
  color: white;
  padding: 14px 16px;
  transition: color 0.3s ease;
}
nav ul li a:hover {
  color: #3282e6;
}

/* Containers */
.container {
  margin: 48px auto 0;
  max-width: 90%;
  padding: 0 10px;
}

/* Footer */
.footer {
  position: relative;
  height: 60px;
  clear: both;
  text-align: center;
  font-size: 14px;
  margin-top: 80px;
}

/* Reset images globally */
img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 0;
  margin: 0;
  box-sizing: border-box;
}

/* --- Properties Grid --- */
.properties-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: stretch;
  gap: 40px;
  margin: 40px auto 60px;
  color: #515151;
  max-width: 1400px;
  padding: 0 10px;
  box-sizing: border-box;
}

.properties {
  width: 30%;
  background: #fff;
  border-radius: 8px;
  padding: 15px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  height: auto;
  text-align: center;
  position: relative;
  box-sizing: border-box;
}

.properties .meta {
  margin-top: auto;
  width: 100%;
}

.properties h5 {
  margin-top: 5px;
  margin-bottom: 4px;
  line-height: .5;
}
.properties h6 {
  margin-top: 4px;
  margin-bottom: 4px;
  line-height: 1.1;
}
.properties p {
  margin-top: 4px;
}

/* --- Mini Property Carousel --- */
.property-carousel {
  margin: 0 auto;
  background-color: #000;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  position: relative;
  width: 100%;
  aspect-ratio: 1:1;
  border-radius: 10px;
}

.property-carousel .carousel-slide {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.6s ease;
}

.property-carousel .carousel-slide.active {
  opacity: 1;
  z-index: 1;
}

.property-carousel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 16px;
}

/* Align text under carousel consistently */
.properties .meta {
  text-align: center;
  margin-top: 10px;
}

/* --- Carousel Buttons --- */
.property-carousel .carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;
  background-color: rgba(0,0,0,0.5);
  color: #fff;
  font-size: 18px;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  z-index: 20;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
.property-carousel .carousel-btn:hover {
  background-color: rgba(0,0,0,0.8);
}
.property-carousel .carousel-btn.prev { left: 8px; }
.property-carousel .carousel-btn.next { right: 8px; }

/* Round standalone property images */
.properties > img,
.property-carousel {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  object-fit: cover;
  margin-bottom: 20px; /* consistent gap under both */
}

/* --- Responsive Adjustments --- */
@media (max-width: 900px) {
  .properties {
    width: 45%;
  }
  .property-carousel {
    max-width: 100%;
    aspect-ratio: 1 / 1;
  }
}

@media (max-width: 600px) {
  .properties {
    width: 90%;
  }
  .property-carousel {
    width: 100%;
    max-width: 100%;
    aspect-ratio: 1 / 1;
  }
  button, 
  .contact-button, 
  a.contact-button {
    width: calc(100% - 20px);
  }
  .property-carousel .carousel-btn {
    width: 34px;
    height: 34px;
    font-size: 16px;
  }
}

