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

:root {
  --dark: #071c2d;
  --blue: #0f2f4a;
  --gold: #c89b3c;
  --light: #f5f7fa;
  --text: #1e293b;
  --muted: #64748b;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  color: var(--text);
  background: white;
}

.header {
  width: 100%;
  padding: 18px 8%;
  background: rgba(7, 28, 45, 0.97);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 8px 25px rgba(0,0,0,0.18);
}

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

.logo-icon {
  width: 44px;
  height: 44px;
  border: 2px solid var(--gold);
  color: var(--gold);
  display: grid;
  place-items: center;
  border-radius: 8px;
  font-size: 28px;
}

.logo strong {
  display: block;
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: .5px;
}

.logo span {
  color: var(--gold);
  font-size: 12px;
  text-transform: uppercase;
}

.nav {
  display: flex;
  gap: 28px;
}

.nav a {
  color: white;
  text-decoration: none;
  font-weight: bold;
  font-size: 14px;
  transition: .2s;
}

.nav a:hover {
  color: var(--gold);
}

.hero {
  min-height: 78vh;
  background-image: url("../img/Propiedad1.jpeg");
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  align-items: center;
  padding: 90px 8%;
  color: white;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(7,28,45,.9), rgba(7,28,45,.55), rgba(7,28,45,.2));
}

.hero-content {
  position: relative;
  max-width: 690px;
  z-index: 2;
}

.pretitle {
  color: var(--gold);
  text-transform: uppercase;
  font-weight: bold;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.hero h1 {
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.05;
  margin-bottom: 20px;
}

.hero p {
  font-size: 20px;
  line-height: 1.6;
  margin-bottom: 30px;
}

.btn {
  display: inline-block;
  padding: 14px 26px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  border: none;
  cursor: pointer;
}

.btn-gold {
  background: var(--gold);
  color: var(--dark);
}

.btn-dark {
  background: var(--dark);
  color: white;
}

.section {
  padding: 70px 8%;
}

.section-light {
  background: var(--light);
}

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

.section-title p {
  color: var(--gold);
  font-weight: bold;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.section-title h2 {
  color: var(--dark);
  font-size: 36px;
}

.property-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 34px;
}

.property-card {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 12px 35px rgba(15, 47, 74, .12);
  transition: .25s;
}

.property-card:hover {
  transform: translateY(-5px);
}

.property-image {
  position: relative;
  height: 300px;
  overflow: hidden;
}

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

.badge {
  display: inline-block;
  background: var(--dark);
  color: white;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: bold;
  border-radius: 3px;
}

.property-image .badge {
  position: absolute;
  top: 16px;
  left: 16px;
}

.price-tag {
  position: absolute;
  left: 16px;
  bottom: 16px;
  background: var(--gold);
  color: white;
  padding: 10px 16px;
  border-radius: 4px;
  font-weight: bold;
  font-size: 18px;
}

.property-body {
  padding: 22px;
}

.property-body h3 {
  color: var(--dark);
  font-size: 24px;
  margin-bottom: 14px;
}

.features {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 14px 0;
  color: #334155;
  font-size: 15px;
}

.location {
  color: var(--muted);
  margin-bottom: 18px;
}

.card-btn {
  display: block;
  width: fit-content;
  margin: 18px auto 0;
  background: var(--dark);
  color: white;
  padding: 13px 34px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  font-weight: bold;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 26px;
}

.service-card {
  background: white;
  padding: 30px;
  border-left: 5px solid var(--gold);
  border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0,0,0,.06);
}

.service-card h3 {
  color: var(--dark);
  margin-bottom: 12px;
}

.about {
  background: linear-gradient(rgba(7,28,45,.9), rgba(7,28,45,.9)), url("../img/Propiedad2.jpeg");
  background-size: cover;
  background-position: center;
  color: white;
  padding: 80px 8%;
  text-align: center;
}

.about div {
  max-width: 820px;
  margin: auto;
}

.about h2 {
  font-size: 38px;
  margin-bottom: 18px;
}

.about p {
  font-size: 18px;
  line-height: 1.7;
}

.contact-form {
  max-width: 720px;
  margin: auto;
  background: white;
  padding: 32px;
  box-shadow: 0 12px 35px rgba(15,47,74,.12);
  border-radius: 8px;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 15px;
  margin-bottom: 14px;
  border: 1px solid #d0d7de;
  border-radius: 5px;
  font-size: 15px;
}

.contact-form button {
  width: 100%;
  background: var(--dark);
  color: white;
  padding: 16px;
  border: none;
  border-radius: 5px;
  font-weight: bold;
  cursor: pointer;
}

.footer {
  background: var(--dark);
  color: white;
  text-align: center;
  padding: 24px;
}

.whatsapp {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 58px;
  height: 58px;
  background: #25D366;
  color: white;
  display: grid;
  place-items: center;
  border-radius: 50%;
  text-decoration: none;
  font-size: 26px;
  z-index: 40;
  box-shadow: 0 10px 25px rgba(0,0,0,.25);
}

/* MODAL */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
}

.modal.active {
  display: block;
}

.modal-bg {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.68);
  backdrop-filter: blur(3px);
}

.modal-content {
  position: relative;
  z-index: 101;
  background: white;
  max-width: 1240px;
  width: calc(100% - 48px);
  max-height: 92vh;
  overflow-y: auto;
  overflow-x: hidden;
  margin: 4vh auto;
  border-radius: 10px;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, .55fr);
  gap: 28px;
  padding: 28px;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 18px;
  background: transparent;
  border: none;
  font-size: 34px;
  cursor: pointer;
  color: var(--dark);
  z-index: 102;
}

.modal-gallery {
  position: relative;
}

.modal-gallery > img {
  width: 100%;
  height: 500px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

.counter {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(7,28,45,.92);
  color: white;
  padding: 8px 12px;
  border-radius: 5px;
  font-weight: bold;
  z-index: 3;
}

.arrow {
  position: absolute;
  top: 235px;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: rgba(7,28,45,.75);
  color: white;
  font-size: 42px;
  line-height: 1;
  cursor: pointer;
  z-index: 3;
}

.arrow.left {
  left: 14px;
}

.arrow.right {
  right: 14px;
}

.thumbs {
  display: flex;
  gap: 9px;
  margin-top: 12px;
  overflow-x: auto;
  padding-bottom: 6px;
}

.thumbs img {
  width: 92px;
  height: 66px;
  object-fit: cover;
  border-radius: 5px;
  cursor: pointer;
  border: 3px solid transparent;
  opacity: .72;
}

.thumbs img.active {
  border-color: var(--gold);
  opacity: 1;
}

.modal-info {
  padding: 18px 8px;
}

.modal-info h2 {
  color: var(--dark);
  font-size: 36px;
  margin: 18px 0 10px;
}

.modal-price {
  display: inline-block;
  background: var(--gold);
  color: white;
  padding: 10px 16px;
  border-radius: 5px;
  font-weight: bold;
  font-size: 22px;
  margin-bottom: 18px;
}

.modal-info hr {
  border: none;
  border-top: 1px solid #dde3ea;
  margin: 24px 0;
}

.modal-info h3 {
  color: var(--dark);
  margin-bottom: 10px;
}

.modal-info p {
  color: #475569;
  line-height: 1.7;
  margin-bottom: 24px;
}

@media (max-width: 900px) {
  .header {
    align-items: flex-start;
    gap: 16px;
  }

  .nav {
    flex-wrap: wrap;
    gap: 14px;
  }

  .modal-content {
    grid-template-columns: 1fr;
  }

  .modal-gallery > img {
    height: 360px;
  }

  .arrow {
    top: 180px;
  }
}

@media (max-width: 600px) {
  .header {
    padding: 16px 5%;
  }

  .section {
    padding: 55px 5%;
  }

  .hero {
    padding: 70px 5%;
  }

  .property-image {
    height: 240px;
  }

  .modal-content {
    padding: 18px;
  }

  .modal-info h2 {
    font-size: 28px;
  }
}

.modal-info .features {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  font-size: 16px;
  margin: 20px 0;
}

.whatsapp-btn {
  background: #25D366 !important;
  color: white !important;
  width: 100%;
  text-align: center;
  font-size: 17px;
  padding: 16px 22px;
  border-radius: 7px;
  box-shadow: 0 8px 20px rgba(37, 211, 102, .28);
}

.whatsapp-btn:hover {
  filter: brightness(.95);
}

.modal-info {
  min-width: 0;
}

.modal-info p,
.modal-info span,
.modal-info h2 {
  word-break: normal;
  overflow-wrap: break-word;
}
