.master-image-container {
  width: 100%;
  height: 90vh;
  display: flex;
  flex-direction: column;
  position: relative;
}

.master-image-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.master-image-container video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  display: none;
}

.master-details {
  position: absolute;
  bottom: 0;
  width: calc(100% - 30px);
  padding: 5px 15px;
  display: flex;
  flex-direction: column;
  background-color: rgba(255, 255, 255, 0.71);
   background: rgba(255, 255, 255, 0.467);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(10px);
  
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.ad-title {
  font-size: 2.1em;
  color: rgb(0, 0, 0);
  margin: 0px 0px 10px 0px;
  font-family: "Gill Sans", "Gill Sans MT", Calibri, "Trebuchet MS", sans-serif;
  font-weight: 500;
  padding: 0;
}

.master-details h4 {
  font-size: 1.2em;
  color: rgb(55, 55, 55);
  margin: 5px 0px 10px 5px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
  padding: 0;
}

.price-location {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  background-color: #ffffff;
}

.ad-price {
  font-size: 1.9em;
  color: rgb(0, 0, 0);
  width: calc(100% - 40px);
  padding: 10px 20px;
  margin: 0 10px;
  font-family: Georgia, "Times New Roman", Times, serif;
  font-weight: 500;
}

.ad-location-container {
  width: calc(100% - 20px);
  text-align: start;
  padding: 10px;
  display: flex;
  flex-direction: row;
  justify-content: start;
  align-items: center;
}

.ad-location-container img {
  height: 20px;
  margin-left: 20px;
  margin-right: 10px;
}

.ad-location-container h5 {
  font-size: 1.2em;
  color: rgb(0, 0, 0);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
  padding: 0;
  margin: 0;
}

.ad-section-1 {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  width: 100%;
}

.area-1 {
  flex: 1;
  background-color: rgb(255, 255, 255);
  padding: 10px 20px;
  width: calc(100% - 40px);
}

.area-2 {
  background-color: rgb(255, 255, 255);
  padding: 10px 20px;
  width: calc(100% - 40px);
  flex: 0.8;
  display: flex;
  flex-direction: column;
}

.property-overview {
  display: flex;
  flex-direction: column;
  padding: 10px;
  border-radius: 10px;
  border: solid 2px rgba(157, 157, 157, 0);
  margin: 20px 0px 20px 0px;
  box-shadow: 0px 0px 15px rgba(0, 0, 0, 0.13);
}

.property-overview h3 {
  font-size: 1.2em;
  color: rgb(0, 0, 0);
  margin: 5px 20px 20px 20px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
}

.property-overview-line-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 25px;
}

.property-overview-line {
  display: flex;
  flex-direction: column;
  align-self: center;
  width: 100px;
}

.property-overview-line h4 {
  margin: 5px;
  padding: 0;
  font-size: 1em;
  color: rgb(144, 144, 144);
  font-weight: 500;
}

.property-overview-line h5 {
  margin: 5px auto;
  padding: 0;
  font-size: 1.2em;
  color: rgb(0, 0, 0);
  font-weight: 500;
}

.nearby-locations {
  display: flex;
  flex-direction: column;
  padding: 20px;
  border: solid 1px #9a9a9a;
  border-radius: 10px;
}

.nearby-locations-topic {
  display: flex;
  flex-direction: row;
  justify-content: start;
  width: 100%;
  align-items: center;
  margin-bottom: 10px;
}

.nearby-locations-topic h3 {
  font-size: 1.2em;
  color: rgb(0, 0, 0);
  margin: 5px 20px 5px 10px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
}

.nearby-locations img {
  height: 25px;
}

.nearby-line {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: start;
  padding: 5px;
  width: calc(100% - 10px);
  background-color: rgb(255, 255, 255);
  margin: 10px 0px;
  box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.166);
  border-radius: 20px;
  height: 35px;
}

.nearby-line img {
  height: 25px;
  padding: 5px;
  border-radius: 50%;
  background-color: rgb(223, 223, 223);
}

.nearby-line-text {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
}

.nearby-line-text h4 {
  font-size: 1em;
  color: rgb(0, 0, 0);
  margin: 5px 20px 5px 10px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
}

.nearby-line-text h5 {
  font-size: 0.9em;
  color: rgb(64, 64, 64);
  margin: 5px 20px 5px 10px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 400;
}

.description {
  display: flex;
  flex-direction: column;
  padding: 10px;
  margin-top: 10px;
  text-align: left;
  flex: 1;
}

.description h3 {
  font-size: 1.3em;
  color: rgb(0, 0, 0);
  margin: 5px 20px 5px 20px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
}

.description pre {
  font-size: 1.1em;
  color: rgb(40, 40, 40);
  margin: 5px 20px 20px 20px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 400;
  white-space: pre-wrap;
  word-break: break-word;
}

.features {
  display: flex;
  flex-direction: column;
  padding: 5px 7.5px;
  margin: 0 15px;
  background-color: rgb(255, 255, 255);
  border-radius: 10px;
  border: solid 1px #393333;
}

.features h3 {
  font-size: 1.3em;
  color: rgb(4, 0, 37);
  margin: 5px 10px 5px 10px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
}

.features-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  /* Two main columns */
  grid-template-rows: auto;
  gap: 10px;
  list-style-type: disc;
  font-family: Arial, sans-serif;
  color: rgb(55, 55, 55);
  font-size: 1.1em;
}

.features-list li {
  margin: 5px 10px;
}

.ad-gallery {
  display: flex;
  flex-direction: column;
  width: 100%;
  margin: 20px auto;
  background-color: rgb(255, 255, 255);
}

.ad-gallery h2 {
  font-size: 1.8em;
  color: rgb(0, 0, 0);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
  margin: 5px auto;
}

.ad-gallery p {
  font-size: 1em;
  color: rgb(45, 45, 45);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 400;
  margin: 5px auto;
  width: 60%;
  text-align: center;
}

.gallery-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);

  grid-auto-flow: dense;
  gap: 10px;
  width: 80%;
  margin: 5px auto;
}

.video-container {
  width: 100%;
  height: 100%;
  max-height: 600px;
  grid-column: span 2;
  grid-row: span 2;
  overflow: hidden;
  display: none;
}

.video-container video {
  width: 100%;
  height: 100%;
  border-radius: 10px;
}

.ad-gallery-large {
  width: 100%;
  height: auto;
  border-radius: 10px;
  object-fit: cover;
  grid-column: span 1;
  grid-row: span 1;
}

.ad-gallery-small {
  width: 100%;
  height: auto;
  border-radius: 10px;
  object-fit: cover;
  grid-column: span 1;
  grid-row: span 1;
  justify-self: start;
}

.adview-contact {
  display: flex;
  flex-direction: row;
  width: calc(80% - 40px);
  padding: 20px;
  margin: 20px auto 50px auto;
  border-radius: 20px;
  background-color: rgb(255, 255, 255);
  box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.166);
}

.agent-sec1 {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: rgba(250, 235, 215, 0);
}

.agent-sec1 h5 {
  font-size: 1.8em;
  color: rgb(0, 0, 0);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 700;
  margin: 5px auto;
}

.agent-sec1 img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto;
}

.agent-sec1 h6 {
  font-size: 1em;
  color: rgb(29, 29, 29);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
  margin: 5px auto;
}

.agent-sec1 span {
  font-size: 0.8em;
  color: rgb(18, 227, 255);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 700;
  margin: 0px auto;
}

.agent-sec1 a {
  font-size: 1.2em;
  color: rgb(255, 255, 255);
  margin: 5px 20px 5px 20px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 500;
  margin: 5px auto;
  background-color: rgb(0, 0, 0);
  box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.166);
  width: 200px;
  padding: 10px;
  text-align: center;
  border-radius: 10px;
  cursor: pointer;
  transition: 0.5s;
  text-decoration: none;
}

.agent-sec1 a:hover {
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  transform: scale(1.05);
}

.agent-sec2 {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  flex-direction: column;
  background-color: rgba(204, 255, 185, 0);
}

.agent-sec2 h5 {
  font-size: 1.5em;
  color: rgb(0, 0, 0);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 700;
  margin: 20px auto 5px auto;
}

.agent-sec2 p {
  font-size: 1em;
  color: rgb(25, 25, 25);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-weight: 600;
}

.imageview-window {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 2;
  background-color: #000000;
  display: flex;
  display: none;
}

.window-close-btn {
  right: 0;
  position: fixed;
  margin: 10px;
  padding: 5px 10px;
  border-radius: 10px;
  outline: none;
  background-color: #ffffff;
  border: none;
  color: #000000;
}

.imageview-window-image {
  position: fixed;
   max-width: 80vw;
  max-height: 80vh;
  width: auto;
  height: auto;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 3;
}

.imagewindow-prev-btn,
.imagewindow-next-btn {
  position: fixed;
  z-index: 4;
  width: 80px;
  background-color: transparent;
  top: 50%;
  display: flex;
  align-items: center;
}

.imagewindow-prev-btn {
  left: 0%;
  transform: translate(0%, -50%);
  justify-content: start;
  margin-left: 10px;
}

.imagewindow-next-btn {
  right: 0%;
  transform: translate(0%, -50%);
  justify-content: end;
  margin-right: 10px;
}

.image-window-icon-button {
  width: 40px;
}

.ytvideo-container {
  position: relative;
  width: 90%;
  margin: auto;
  height: 90vh;
}

.ytvideo-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 10px;
}





@media (min-width: 800px) and (max-width: 1000px) {
  .header-wide {
    height: 60px;
    width: 100%;
  }

  .header-wide img {
    height: 40px;
    margin-left: 20px;
  }

  .master-image-container {
    width: 100%;
    height: 70vh;
  }

  .master-image-container img {
    width: 100%;
    height: 100%;
  }

  .master-image-container video {
    width: 100%;
    height: 100%;
  }

  .master-details {
    width: calc(100% - 30px);
    padding: 5px 15px;
  }

  .ad-location-container img {
    height: 20px;
    margin-left: 20px;
    margin-right: 10px;
  }

  .area-1 {
    flex: 1;
    padding: 10px 10px;
    width: calc(100% - 20px);
  }

  .area-2 {
    padding: 10px 10px;
    flex: 0.9;
    width: calc(100% - 20px);
  }

  .property-overview {
    padding: 10px;
    margin: 20px 0px 20px 0px;
  }

  .property-overview h3 {
    margin: 5px 20px 20px 20px;
  }

  .property-overview-line-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 25px;
  }

  .property-overview-line {
    width: 100px;
  }

  .property-overview-line h4 {
    margin: 5px;
  }

  .property-overview-line h5 {
    margin: 5px auto;
  }

  .nearby-locations {
    padding: 15px;
    border-radius: 10px;
  }

  .nearby-line {
    padding: 5px;
    width: calc(100% - 10px);
    margin: 10px 0px;
  }

  .nearby-line img {
    height: 25px;
    padding: 5px;
  }

  .features-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .features-list li {
    margin: 5px 5px;
  }

  .ad-gallery {
    width: 100%;
    margin: 20px auto;
  }

  .gallery-container {
    grid-template-columns: repeat(3, 1fr);
    /* Two main columns */
    gap: 15px;
    width: 80%;
    margin: 5px auto;
  }

  .video-container {
    max-height: 400px;
  }

  .video-container video {
    width: 100%;
    height: 100%;
  }

  .adview-contact {
    width: calc(90% - 20px);
    padding: 10px;
    margin: 20px auto 50px auto;
  }
}

@media (min-width: 600px) and (max-width: 800px) {
  .header-wide {
    height: 60px;
    width: 100%;
  }

  .header-wide img {
    height: 40px;
    margin-left: 20px;
  }

  .master-image-container {
    width: 100%;
    height: 60vh;
  }

  .master-image-container img {
    width: 100%;
    height: 100%;
  }

  .master-image-container video {
    width: 100%;
    height: 100%;
  }

  .master-details {
    width: calc(100% - 30px);
    padding: 5px 15px;
  }

  .ad-location-container img {
    height: 20px;
    margin-left: 20px;
    margin-right: 10px;
  }

  .area-1 {
    flex: 1;
    padding: 10px 5px;
    width: calc(100% - 10px);
  }

  .area-2 {
    padding: 10px 5px;
    flex: 0.9;
    width: calc(100% - 10px);
  }

  .property-overview {
    padding: 10px;
    margin: 20px 5px 20px 5px;
  }

  .property-overview h3 {
    margin: 5px 20px 20px 10px;
  }

  .property-overview-line-container {
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 25px;
  }

  .property-overview-line h4 {
    margin: 5px;
  }

  .property-overview-line h5 {
    margin: 5px auto;
  }

  .nearby-locations {
    padding: 15px;
    border-radius: 10px;
  }

  .nearby-line {
    padding: 5px;
    width: calc(100% - 10px);
    margin: 10px 0px;
  }

  .nearby-line img {
    height: 25px;
    padding: 5px;
  }

  .features-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .features-list li {
    margin: 5px 5px;
  }

  .ad-gallery {
    width: 100%;
    margin: 20px auto;
  }

  .gallery-container {
    grid-template-columns: repeat(3, 1fr);
    /* Two main columns */
    gap: 15px;
    width: 90%;
    margin: 5px auto;
  }

  .ytvideo-container {
    max-height: 400px;
  }

  .ytvideo-container video {
    width: 100%;
    height: 100%;
  }

  .adview-contact {
    width: calc(90% - 20px);
    padding: 10px;
    margin: 20px auto 50px auto;
  }

  .ytvideo-container {
    position: relative;
    width: 90%;
    margin: auto;
    height: 60vh;
  }
  .ytvideo-container iframe {
    border-radius: 6px;
  }
}

@media (min-width: 500px) and (max-width: 600px) {
  .header-wide {
    height: 60px;
    width: 100%;
  }

  .header-wide img {
    height: 40px;
    margin-left: 20px;
  }

  .master-image-container {
    width: 100%;
    height: 50vh;
  }

  .master-image-container img {
    width: 100%;
    height: 100%;
  }

  .master-image-container video {
    width: 100%;
    height: 100%;
  }

  .master-details {
    width: calc(100% - 20px);
    padding: 5px 10px;
  }

  .ad-title {
    font-size: 1.6em;
    margin: 0px 0px 10px 0px;
  }

  .master-details h4 {
    font-size: 1.1em;
    margin: 5px 0px 10px 5px;
  }

  .ad-price {
    font-size: 1.6em;
    color: rgb(0, 0, 0);
    width: calc(100% - 20px);
    padding: 10px 10px;
    margin: 0 10px;
  }

  .ad-location-container {
    width: calc(100% - 10px);
    text-align: start;
    padding: 5px;
  }

  .ad-location-container img {
    height: 20px;
    margin-left: 10px;
    margin-right: 5px;
  }

  .ad-location-container h5 {
    font-size: 1.1em;
  }

  .ad-section-1 {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
  }

  .area-1 {
    flex: 1;
    padding: 10px 5px;
    width: calc(100% - 10px);
  }

  .area-2 {
    padding: 10px 5px;
    width: calc(100% - 10px);
    flex: 1;
    display: flex;
    flex-direction: column;
  }

  .property-overview {
    padding: 5px;
    margin: 20px 0px 20px 0px;
  }

  .property-overview h3 {
    font-size: 1.1em;
    margin: 5px 10px 10px 10px;
  }

  .property-overview-line-container {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .property-overview-line {
    width: 100px;
  }

  .nearby-locations {
    padding: 10px;
  }

  .nearby-locations-topic h3 {
    font-size: 1.1em;
    margin: 5px 10px 5px 5px;
  }

  .nearby-locations img {
    height: 25px;
  }

  .nearby-line {
    padding: 5px;
    width: calc(100% - 10px);
    margin: 10px 0px;
    border-radius: 20px;
    height: 35px;
  }

  .nearby-line img {
    height: 25px;
    padding: 5px;
  }

  .nearby-line-text h4 {
    font-size: 0.9em;
    margin: 5px 10px 5px 5px;
  }

  .nearby-line-text h5 {
    font-size: 0.8em;
    margin: 5px 5px 5px 5px;
  }

  .description {
    padding: 5px;
    margin-top: 5px;
    flex: 1;
  }

  .description h3 {
    font-size: 1.2em;
    margin: 5px 10px 5px 10px;
  }

  .description pre {
    font-size: 1em;
    margin: 5px 10px 20px 10px;
  }

  .features {
    padding: 5px 5px;
    margin: 0 5px;
  }

  .features h3 {
    font-size: 1.2em;
    margin: 5px 10px 5px 10px;
  }

  .features-list {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 5px;
    font-size: 1em;
  }

  .features-list li {
    margin: 5px 0px;
  }

  .ad-gallery {
    width: 100%;
    margin: 20px auto;
  }

  .ad-gallery p {
    font-size: 1em;
    width: 80%;
  }

  .gallery-container {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    width: 90%;
    margin: 5px auto;
  }

  .video-container {
    max-height: 500px;
    grid-column: span 2;
    grid-row: span 2;
  }

  .ad-gallery-large {
    width: 100%;
    height: auto;
    border-radius: 10px;
    grid-column: span 1;
    grid-row: span 1;
  }

  .adview-contact {
    width: calc(90% - 30px);
    padding: 15px;
    margin: 20px auto 40px auto;
    border-radius: 20px;
    flex-direction: column;
  }

  .imagewindow-prev-btn,
  .imagewindow-next-btn {
    display: none;
  }

  .ytvideo-container {
    position: relative;
    width: 90%;
    margin: auto;
    height: 50vh;
  }
  .ytvideo-container iframe {
    border-radius: 3px;
  }
}

@media (min-width: 400px) and (max-width: 500px) {
  .header-wide {
    height: 60px;
    width: 100%;
  }

  .header-wide img {
    height: 40px;
    margin-left: 20px;
  }

  .master-image-container {
    height: 50vh;
  }

  .master-details {
    width: calc(100% - 20px);
    padding: 5px 10px;
  }

  .ad-title {
    font-size: 1.8em;
    margin: 0px 0px 10px 0px;
    padding: 0;
  }

  .master-details h4 {
    font-size: 1.1em;
    margin: 5px 0px 5px 5px;
  }

  .price-location {
    flex-direction: column;
    justify-content: start;
  }

  .ad-price {
    font-size: 1.5em;
    width: calc(100% - 30px);
    padding: 10px 15px;
    margin: 0 10px;
  }

  .ad-location-container {
    width: calc(100% - 10px);
    padding: 5px;
  }

  .ad-location-container h5 {
    font-size: 0.9em;
  }

  .ad-section-1 {
    display: flex;
    flex-direction: column-reverse;
    align-items: flex-start;
  }

  .area-1 {
    flex: 1;
    padding: 10px 10px;
    width: calc(100% - 20px);
  }

  .area-2 {
    padding: 10px 10px;
    width: calc(100% - 20px);
    flex: 1;
    flex-direction: column;
  }

  .property-overview {
    display: flex;
    flex-direction: column;
    padding: 10px;
    border-radius: 10px;
    margin: 20px 0px 20px 0px;
  }

  .property-overview h3 {
    font-size: 1em;
    margin: 5px 20px 10px 20px;
  }

  .property-overview-line-container {
    grid-template-columns: repeat(auto-fit, minmax(83px, 1fr));
    gap: 10px;
  }

  .property-overview-line {
    display: flex;
    flex-direction: column;
    align-self: center;
    width: 82.5px;
  }

  .property-overview-line h4 {
    margin: 5px;
    padding: 0;
    font-size: 0.8em;
  }

  .property-overview-line h5 {
    margin: 5px auto;
    padding: 0;
    font-size: 1em;
  }

  .nearby-locations {
    padding: 10px;
    border-radius: 10px;
  }

  .nearby-locations-topic {
    margin-bottom: 10px;
  }

  .nearby-locations-topic h3 {
    font-size: 1em;
    margin: 5px 20px 5px 10px;
  }

  .nearby-locations img {
    height: 20px;
  }

  .nearby-line {
    padding: 5px;
    width: calc(100% - 10px);
    margin: 10px 0px;
    border-radius: 20px;
    height: 30px;
  }

  .nearby-line img {
    height: 20px;
    padding: 5px;
  }

  .nearby-line-text h4 {
    font-size: 0.8em;
    margin: 5px 40px 5px 10px;
  }

  .nearby-line-text h5 {
    font-size: 0.8em;
    margin: 5px 20px 5px 10px;
  }

  .description {
    display: flex;
    flex-direction: column;
    padding: 10px;
    margin-top: 10px;
    flex: 1;
  }

  .description h3 {
    font-size: 1.1em;
    margin: 5px 20px 5px 20px;
  }

  .description pre {
    font-size: 0.9em;
    margin: 5px 10px 20px 10px;
  }

  .features {
    display: flex;
    flex-direction: column;
    padding: 5px 5px;
    margin: 0 10px;
    border-radius: 10px;
  }

  .features h3 {
    font-size: 1.3em;
    margin: 5px 10px 5px 10px;
  }

  .features-list {
    grid-template-columns: repeat(1, 1fr);
    gap: 10px;
    font-size: 1em;
  }

  .features-list li {
    margin: 5px 5px;
  }

  .ad-gallery {
    margin: 20px auto;
  }

  .ad-gallery h2 {
    font-size: 1.8em;
    margin: 5px auto;
  }

  .ad-gallery p {
    font-size: 0.8em;
    width: 80%;
  }

  .gallery-container {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    width: 90%;
    margin: 5px auto;
  }

  .video-container {
    width: 100%;
    height: 100%;
    max-height: 400px;
    grid-column: span 2;
    grid-row: span 2;
  }

  .adview-contact {
    flex-direction: column;
    width: calc(90% - 20px);
    padding: 10px;
    margin: 20px auto 50px auto;
    border-radius: 20px;
  }

  .agent-sec1 {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }

  .agent-sec1 h5 {
    font-size: 1.3em;
    margin: 5px auto;
  }

  .agent-sec1 img {
    width: 120px;
    height: 120px;
    margin: 0 auto;
  }

  .agent-sec1 h6 {
    font-size: 1em;
    margin: 5px auto;
  }

  .agent-sec1 span {
    font-size: 0.8em;
    margin: 0px auto;
  }

  .agent-sec1 a {
    font-size: 1em;
    margin: 5px 20px 5px 20px;
    margin: 5px auto;
    width: 180px;
    padding: 10px;
    border-radius: 10px;
  }

  .agent-sec2 h5 {
    font-size: 1.2em;
    margin: 20px auto 5px auto;
  }

  .agent-sec2 p {
    font-size: 0.8em;
  }

  .imagewindow-prev-btn,
  .imagewindow-next-btn {
    display: none;
  }

  .ytvideo-container {
    position: relative;
    width: 95%;
    margin: auto;
    height: 40vh;
  }
  .ytvideo-container iframe {
    border-radius: 2px;
  }
}

@media (max-width: 400px) {
  .header-wide {
    height: 50px;
    width: 100%;
  }

  .header-wide img {
    height: 30px;
    margin-left: 10px;
  }

  .master-image-container {
    height: 70vh;
  }

  .master-details {
    width: calc(100% - 10px);
    padding: 5px 5px;
  }

  .ad-title {
    font-size: 1.6em;
    margin: 0px 0px 5px 0px;
    padding: 0;
  }

  .master-details h4 {
    font-size: 1em;
    margin: 5px 0px 5px 5px;
  }

  .price-location {
    flex-direction: column;
    justify-content: start;
  }

  .ad-price {
    font-size: 1.3em;
    width: calc(100% - 20px);
    padding: 10px 10px;
    margin: 0 10px;
  }

  .ad-location-container {
    width: calc(100% - 10px);
    padding: 5px;
  }

  .ad-location-container h5 {
    font-size: 0.9em;
  }

  .ad-section-1 {
    display: flex;
    flex-direction: column-reverse;
    align-items: flex-start;
  }

  .area-1 {
    flex: 1;
    padding: 10px 10px;
    width: calc(100% - 20px);
  }

  .area-2 {
    padding: 10px 10px;
    width: calc(100% - 20px);
    flex: 1;
    flex-direction: column;
  }

  .property-overview {
    display: flex;
    flex-direction: column;
    padding: 10px;
    border-radius: 10px;
    margin: 20px 0px 20px 0px;
  }

  .property-overview h3 {
    font-size: 1em;
    margin: 5px 20px 10px 20px;
  }

  .property-overview-line-container {
    grid-template-columns: repeat(auto-fit, minmax(83px, 1fr));
    gap: 10px;
  }

  .property-overview-line {
    display: flex;
    flex-direction: column;
    align-self: center;
    width: 82.5px;
  }

  .property-overview-line h4 {
    margin: 5px;
    padding: 0;
    font-size: 0.8em;
  }

  .property-overview-line h5 {
    margin: 5px auto;
    padding: 0;
    font-size: 1em;
  }

  .nearby-locations {
    padding: 10px;
    border-radius: 10px;
  }

  .nearby-locations-topic {
    margin-bottom: 10px;
  }

  .nearby-locations-topic h3 {
    font-size: 1em;
    margin: 5px 20px 5px 10px;
  }

  .nearby-locations img {
    height: 20px;
  }

  .nearby-line {
    padding: 5px;
    width: calc(100% - 10px);
    margin: 10px 0px;
    border-radius: 20px;
    height: 30px;
  }

  .nearby-line img {
    height: 20px;
    padding: 5px;
  }

  .nearby-line-text h4 {
    font-size: 0.8em;
    margin: 5px 40px 5px 10px;
  }

  .nearby-line-text h5 {
    font-size: 0.8em;
    margin: 5px 20px 5px 10px;
  }

  .description {
    display: flex;
    flex-direction: column;
    padding: 5px;
    margin-top: 10px;
    flex: 1;
  }

  .description h3 {
    font-size: 1.1em;
    margin: 5px 20px 5px 20px;
  }

  .description pre {
    font-size: 0.9em;
    margin: 5px 10px 20px 10px;
  }

  .features {
    display: flex;
    flex-direction: column;
    padding: 5px 5px;
    margin: 0 10px;
    border-radius: 10px;
  }

  .features h3 {
    font-size: 1.3em;
    margin: 5px 10px 5px 10px;
  }

  .features-list {
    grid-template-columns: repeat(1, 1fr);
    gap: 10px;
    font-size: 1em;
  }

  .features-list li {
    margin: 5px 5px;
  }

  .ad-gallery {
    margin: 20px auto;
  }

  .ad-gallery h2 {
    font-size: 1.8em;
    margin: 5px auto;
  }

  .ad-gallery p {
    font-size: 0.8em;
    width: 80%;
  }

  .gallery-container {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    width: 90%;
    margin: 5px auto;
  }

  .video-container {
    width: 100%;
    height: 100%;
    max-height: 400px;
    grid-column: span 2;
    grid-row: span 2;
  }

  .adview-contact {
    flex-direction: column;
    width: calc(90% - 20px);
    padding: 10px;
    margin: 20px auto 50px auto;
    border-radius: 20px;
  }

  .agent-sec1 {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }

  .agent-sec1 h5 {
    font-size: 1.3em;
    margin: 5px auto;
  }

  .agent-sec1 img {
    width: 120px;
    height: 120px;
    margin: 0 auto;
  }

  .agent-sec1 h6 {
    font-size: 1em;
    margin: 5px auto;
  }

  .agent-sec1 span {
    font-size: 0.8em;
    margin: 0px auto;
  }

  .agent-sec1 a {
    font-size: 1em;
    margin: 5px 20px 5px 20px;
    margin: 5px auto;
    width: 180px;
    padding: 10px;
  }

  .agent-sec2 h5 {
    font-size: 1.2em;
    margin: 20px auto 5px auto;
  }

  .agent-sec2 p {
    font-size: 0.8em;
  }

  .imagewindow-prev-btn,
  .imagewindow-next-btn {
    display: none;
  }

  .ytvideo-container {
    position: relative;
    width: 95%;
    margin: auto;
    height: 40vh;
  }
  .ytvideo-container iframe {
    border-radius: 2px;
  }
}
