html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Poppins', sans-serif;
  margin: 0;
  color: #3A3A3A;
  line-height: 1.6;
  overflow-x: hidden;
}

section {
  padding: 2.5rem 1rem;   /* ≈ 80px top/bottom */
}

.site-header {
  background-color: #F7F5F2;
  padding: 1rem;
  border-bottom: 1px solid #ddd;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap; 
  gap: 0.75rem;
}

h1 {
  text-align: center;
}

.hero {
  padding: 2rem 0;
  text-align: center;
  position: relative;
  z-index: 1;
}

.hero-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 100%;
  margin: 0 auto;
  padding: 0 2rem;
}

.hero-content {
  position: relative;
  height: 50vh;
  overflow: hidden;
}

.hero-text {
  position: absolute;
  top: 60%;
  left: 50%;
  transform: translate(-50%, -60%);
  color: white;
  text-align: center;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  width: 90%;
  max-width: 500px;
  padding: 0;
}

.hero-text h1 {
  font-size: 1.5rem;
}

.hero-text p {
  font-size: 1rem;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.6;
  object-position: center 20%;
}

.living {
  text-align: center;
  padding: 2.5rem 1rem;
  padding-bottom: 1.5rem;
  background-color: #EAE4DC;
}

.living-container {
  position: relative;
  width: 100%;
  height: clamp(320px, 55vh, 700px); /* mobile/tablet */
  overflow: hidden;
  border-radius: 10px;
}

.living-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center 20%; /* tweak if needed */
}

.site-logo img {
  max-height: 60px;   
  margin: 0 auto;
  mix-blend-mode: multiply;
}

.menu-toggle {
  display: inline-flex;
  flex-direction: column;
  position: relative;
  top: -4px;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  padding: 8px;
  border: 1px solid #CFC6BC;
  border-radius: 10px;
  background: #F7F5F2;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.menu-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background-color: #7A5C4F; /* site-friendly brown */
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.menu-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}
.menu-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.main-nav {
  width: 100%;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(-6px);
  transition: max-height 0.35s ease, opacity 0.25s ease, transform 0.25s ease;
}

.main-nav.open {
  max-height: 320px; /* enough for links */
  opacity: 1;
  transform: translateY(0);
}

.main-nav ul {
  list-style: none;
  margin: 0.75rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  align-items: flex-start;
  width: 100%;
}

.main-nav a {
  display: block;
  width: 100%;
  padding: 0.65rem 0.25rem;
  color: #3A3A3A;
  text-decoration: none;
  font-weight: 500;
}

.main-nav a:hover {
  background-color: rgba(43, 27, 23, 0.08);
  color: #CFC6BC;
}

.info {
  justify-content: center;
  border-top: 40px solid #F7F5F2;
  background-color: #EAE4DC;
  text-align: center;
}

.info h1 {
  margin-bottom: 2rem;
}

.info-card {
  max-width: 100%;
  margin: 0 auto;
  background: #f9f7f5;
  padding: 1.5rem;
  border-radius: 20px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.05);
  text-align: left;
}

.button-link {
  margin: 20px auto;
  background-color: #CFC6BC;
  color: white;
  border: none;
  border-radius: 30px; 
  padding: 12px 30px;
  cursor: pointer;
  display: block;
  max-width: 300px;
  text-decoration: none;
  text-align: center;
}

.button-link:hover {
  background-color: #7A5C4F;
}

.intro {
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.price {
  font-weight: bold;
  margin-bottom: 1rem;
}

.portfolio {
  background-color: #F7F5F2;      
  padding: 2.5rem 1rem;
  text-align: center;         
}

.portfolio h1 {                
  margin-bottom: 2rem;
  font-size: 2rem;
  letter-spacing: 1px;
}

.portfolio-logos {
  display: flex;
  align-items: center;
  gap: 1.5rem;                  
  flex-direction: column;            
}

.portfolio-logos img {
  height: auto;                /* Adjust as needed */
  width: 100%;
  max-width: 300px;
  border-radius: 20px;
  transition: transform 0.3s;
}

.portfolio-logos img:hover {
  transform: scale(1.05);
}

.about {
  border-top: 40px solid #F7F5F2;
  padding: 5rem 1rem;
  text-align: center;
  background-color: #EAE4DC;
}

.testimonial {
  border-top: 40px solid #F7F5F2;
  padding: 5rem 1rem;
  text-align: center;
  background: #EAE4DC;
}

.testimonial-card {
  max-width: 600px;
  margin: 2rem auto;
  padding: 2rem;
  background: #f9f7f5;
  border-radius: 20px;
}

.testimonial-text {
  margin: 0;
  line-height: 1.6;
}

.project { 
  padding: 2.5rem 1rem;
  text-align: center;
}

.gallery-button {
    height: 400px;
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    background-image: 
      linear-gradient(rgba(247, 245, 242, 0.7), rgba(247, 245, 242, 0.7)),
        url("images/house.jpeg");
    background-position: 50% 50%;
    color: #7A5C4F;
    font-size: 20px;
    font-weight: 600;
    cursor: pointer;
    border-radius: 10px;
    transition: 0.3s;
}

.gallery-button:hover {
    background-image: 
        linear-gradient(rgba(247, 245, 242, 0.55), rgba(247, 245, 242, 0.55)),
        url("images/house.jpeg");
}

.lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #F7F5F2;
    justify-content: center;
    align-items: center;
}

.lightbox-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    max-width: 85%;
    max-height: 90%;
}

.lightbox img {
    max-width: 90vw;
    max-height: 70vh;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #CFC6BC;
    font-size: 45px;
    font-weight: bold;
    border: 2px solid #CFC6BC;
    border-radius: 0px;
    padding: 3px 10px;
    cursor: pointer;
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #CFC6BC;
    font-size: 50px;
    cursor: pointer;
}

.lightbox-prev {
    left: 30px;
}

.lightbox-next {
    right: 30px;
}

#image-caption {
    color: white;
    text-align: center;
    color: #CFC6BC;
    font-size: 18px;
    font-weight: 600;
    margin-top: 15px;
    max-width: 800px;
}

#image-counter {
    position: absolute;
    bottom: 25px;
    color: #CFC6BC;
    font-size: 16px;
    font-weight: 600;
}

.gallery-view {
    display: none;
    position: fixed;
    z-index: 9998;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: #F7F5F2;
    padding: 4rem 1rem 2rem;
    overflow-y: auto;
    box-sizing: border-box;
}

.gallery-view h2 {
    text-align: center;
    color: #CFC6BC;
    margin-bottom: 1rem;
}

.gallery-view p {
    text-align: center;
    color: #CFC6BC;
    line-height: 1.6;
}

.gallery-close {
    position: absolute;
    top: 10px;
    right: 25px;
    color: #CFC6BC;
    font-size: 30px;
    font-weight: bold;
    border: 2px solid #CFC6BC;
    padding: 0px 6px;
    cursor: pointer;
}

.gallery-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 35px;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.room-gallery {
    width: 100%;
}

.image-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.pair-image {
    text-align: left;
    cursor: pointer;
}

.gallery-thumbnail {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 8px;
    display: block;
    transition: transform 0.3s ease;
}

.pair-image:hover .gallery-thumbnail {
    transform: scale(1.03);
}

.room-title {
    color: #CFC6BC;
    font-size: 15px;
    font-weight: 600;
    margin-top: 8px;
}

.thumbnail-labels {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    color: #CFC6BC;
    font-size: 14px;
    font-weight: 600;
    margin-top: 2px;
}

.contact { 
  display: flex; 
  background-color: #F7F5F2; 
  flex-direction: column; 
  align-items: center; 
  padding: 2.5rem 1rem; 
}

.contact-card {
  max-width: 600px;
  margin: 0 auto;
  background: #F7F5F2;
  padding: 2rem;
  border-radius: 20px;
  text-align: left;
}

.features {
  list-style: none;
  padding: 0;
  margin-top: 1rem;
}

.features li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 10px;
}

.features li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: #2B1B17;
}

.contact form {
  max-width: 600px;
  width: 100%;
  margin: 0 auto;
  font-family: 'Poppins', sans-serif;
}

.contact label {
  display: block;
  margin-top: 15px;
}

.contact input,
.contact textarea {
  width: 100%;
  padding: 10px;
  margin-top: 5px;
  box-sizing: border-box;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-family: inherit;
}

.contact textarea {
  resize: vertical;
}

.contact button {
  font-size: 1rem;
  margin: 20px auto;
  background-color: #CFC6BC;
  color: white;
  border: none;
  border-radius: 30px; 
  padding: 12px 30px;
  cursor: pointer;
  display: block;
}

.contact button:hover {
  background-color: #7A5C4F;
}

.name-fields {
  display: flex;
  gap: 10px;
  width: 100%;
}

.name-fields input {
  flex: 1;
}

.footer {
  text-align: center;
  padding: 1rem;
  background: #eee;
}

@media (min-width: 768px) {
  section {
    padding: 5rem 1rem;   /* ≈ 48px */
  }
 
   .hero-content {
    height: 75vh;
  }

 .site-header {
    flex-wrap: nowrap;
    padding: 1rem 2rem;
  }

  .site-logo img {
    margin: 0;
  }
  
  .hero-text {
    top: 60%;
    transform: translate(-50%, -60%);
    width: auto;
    max-width: none;
    padding: 0;
  }

  .hero-text h1 {
    font-size: 2.1rem;
  }

  .hero-text p {
    font-size: 1.2rem;
  }

  .menu-toggle {
    display: none;
  }

  .main-nav {
    display: block;
    width: auto;
    max-height: none;   /* critical reset */
    overflow: visible;  /* critical reset */
    opacity: 1;         /* critical reset */
    transform: none;    /* critical reset */
    margin-top: 0;
  }

   .main-nav ul {
    margin: 0;
    flex-direction: row;
    align-items: center;
    gap: 1.5rem;
  }

   .main-nav a {
    width: auto;
    padding: 0;
  }

  .living-container {
    height: 200vh;        /* was 75vh */
    min-height: 750px;   /* was 500px */
  }

  .portfolio-logos {
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 4rem;
  }

  .portfolio-logos img {
    width: auto;
    height: 500px;
    max-width: 700px;
  }

  .button-link,
  .contact button {
    width: fit-content;
  }

  .info-card {
    max-width: 600px;
    padding: 2rem;
  }

  .name-fields {
    flex-direction: row;
    gap: 20px;
  }

  .lightbox img {
        max-width: 80vw;
        max-height: 75vh;
    }

  .gallery-view {
        padding: 5rem 2rem 3rem;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px 25px;
    }

    .gallery-close {
        right: 45px;
        font-size: 45px;
        padding: 3px 10px;
    }
}

@media (min-width: 1024px) {
  .info-card {
    max-width: 700px;
  }

  .living-container {
    max-height: 1100px;
  }
}
