/* Basic Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Smooth scrolling behavior */
html {
  scroll-behavior: smooth;
}

/* Body and General Styling */
body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f4f4f4;
}

/* Watermark Styling */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("images/logo0.jpeg");
  background-repeat: no-repeat;
  background-position: center center;
  background-size: 90%;
  opacity: 0.15;
  z-index: 0;
  pointer-events: none;
}

/* Header Section */
header {
  background-color: #424242ff;
  color: white;
  padding: 10px 0;
  position: sticky;
  top: 0;
  z-index: 2000;
  text-align: center;
  overflow-x: visible;
}

/* Navbar */
.navbar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0 60px;
  gap: 0px;
  flex-wrap: wrap;
  width: 100%;
  position: relative;
  z-index: 2001;
  overflow: visible;
}

/* Logo Grouping */
.navbar .logo {
  display: flex;
  align-items: center;
  margin-left: 0;
  gap: 0px; 
}

.second-logo {
  margin-left: 0px;
}

.logo {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0px;
}

.logo img:first-of-type {
  height: 110px;
  transform: scale(1);
}

.logo img:nth-of-type(2) {
  transform: scale(1);
}

.navbar .logo img {
  height: 120px;
  width: auto;
  margin-right: 0;
  gap: 0;
}

.navbar .logo h1 {
  margin: 0;
  font-size: 24px;
  color: white;
}

.logo-extra {
  margin: 0;
  padding: 0;
  display: inline-block;
  vertical-align: middle;
}

.logo-extra second-logo {
  margin-left: 0px;
  width: 200px;
  height: auto;
}

/* Nav Links */
.nav-links {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  margin-left: auto;
  overflow: visible;
}

.nav-links li {
  margin-left: 30px;
  position: relative;
}

.nav-links a {
  text-decoration: none;
  color: white;
  font-size: 18px;
}

.nav-links a:hover {
  color: #ff9800;
}

nav ul {
  display: flex;
  justify-content: center;
  gap: 40px;
  font-size: 2rem;
}

/* Dropdown Menu Styling */
.nav-links .dropdown .dropbtn {
  background-color: #424242ff;
  color: white;
  padding: 14px 20px;
  font-size: 18px;
  border: none;
  cursor: pointer;
  width: 200px;
  text-align: left;
}

.nav-links .dropdown:hover .dropbtn {
  background-color: #424242ff;
  color: #ff9800;
}

.nav-links .dropdown-content {
  display: none;
  position: absolute;
  background-color: #424242ff;
  color: #ff9800;
  width: 200px;
  z-index: 3000;
  left: 0;
  top: 100%;
  border: 1px solid #424242ff;
  padding: 0;
}

.nav-links .dropdown:hover .dropdown-content {
  display: block;
}

.nav-links .dropdown-content li {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links .dropdown-content a {
  color: white;
  padding: 12px 20px;
  text-decoration: none;
  display: block;
  text-align: left;
  width: 100%;
  box-sizing: border-box;
}

.nav-links .dropdown-content a:hover {
  background-color: #424242ff;
  color: #ff9800;
}

/* Call Now Button */
.call-now {
  background-color: #ff9800;
  color: white;
  padding: 10px 20px;
  font-size: 16px;
  border: none;
  border-radius: 5px;
  text-decoration: none;
  margin-left: 20px;
}

.call-now:hover {
  background-color: #e65100;
}

/* Facebook Icon Styling */
.facebook-icon {
  font-size: 24px;
  color: white;
  margin-left: 20px;
}

/* Image Slider */
#image-slider {
  padding: 50px 0;
  background-color: #fff3e0;
  text-align: center;
}

.slider-container {
  width: 80%;
  margin: 0 auto;
  overflow: hidden;
}

.slider {
  display: flex;
  transition: transform 0.5s ease;
}

.slider img {
  width: 100%;
  height: auto;
}

/* Main Content Section */
#home {
  background-image: url("images/emergclean1.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  position: relative;
  z-index: 1;
}

.home-overlay {
  background-color: rgba(0, 0, 0, 0.5);
  padding: 2em;
  border-radius: 10px;
}

#home h1 {
  font-size: 3em;
  color: white;
}

#home p {
  font-size: 1.2em;
  margin-top: 1em;
}


.hamburger {
  display: none;
}

/* Welcome Box Styles */
.welcome-box {
  background-color: rgba(66, 66, 66, 0.75);
  border: 2px solid rgba(255, 255, 255, 0.3);
  padding: 30px;
  max-width: 400px;
  margin-top: 10px;
  color: white;
  position: relative;
  z-index: 1;
  border-radius: 10px;
  box-sizing: border-box;
  margin-left: 140px;
}

.welcome-box h2,
.welcome-box p {
  text-align: center;
  color: #ff9800;
  margin-bottom: 15px;
}

.call-now-btn {
  display: inline-block;
  padding: 20px 30px;
  font-size: 18px;
  text-align: center;
  background-color: #ff9800;
  color: white;
  text-decoration: none;
  font-weight: bold;
  border: 2px solid rgba(255, 255, 255, 0.6);
  border-radius: 5px;
  transition: background-color 0.3s ease;
  cursor: pointer;
}

#home .container {
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  padding-left: 80px;
  padding-top: 60px;
  max-width: 100%;
}

.call-now-btn:hover {
  background-color: #424242ff;
  color: #ff9800;
}

/* Services Section */
#services {
  padding: 50px 20px;
  text-align: center;
  background-color: #fff3e0;
}

#services h2 {
  font-size: 32px;
  margin-bottom: 20px;
}

#services ul {
  list-style: none;
  padding: 0;
}

#services ul li {
  margin: 10px 0;
  font-size: 20px;
}

#services ul li a {
  color: #e65100;
  text-decoration: none;
}

#services ul li a:hover {
  color: #ff9800;
}

/* Call Now Button Styling */
.home-flex {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 40px;
  flex-wrap: wrap;
}

.call-now-box {
  border: 2px solid lightgray;
  padding: 10px 20px;
  background-color: transparent;
  color: white;
  font-weight: bold;
  text-align: center;
  border-radius: 8px;
}

.call-now-box a {
  color: white;
  text-decoration: none;
  font-size: 1.1em;
}

.call-now-box a:hover {
  text-decoration: underline;
}

/* Service Sections */
section {
  padding: 50px 20px;
  text-align: center;
  position: relative;
  z-index: 1;
}

section h3 {
  font-size: 28px;
  margin-bottom: 15px;
}

section p {
  font-size: 18px;
  max-width: 800px;
  margin: 0 auto;
  line-height: 1.6;
}

/* Service Images Styling */
.service-images {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.service-images img {
  width: 45%;
  max-width: 400px;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.image-slider {
  position: relative;
  max-width: 600px;
  margin: 20px auto;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 0 10px rgba(0,0,0,0.2);
}

.image-slider img.slide {
  display: none;
  width: 100%;
  height: auto;
  border-radius: 12px;
}

.image-slider img.slide.active {
  display: block;
}

.image-slider .prev,
.image-slider .next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2rem;
  background-color: rgba(0,0,0,0.5);
  color: white;
  border: none;
  padding: 10px;
  cursor: pointer;
  z-index: 10;
}

.image-slider .prev {
  left: 10px;
}

.image-slider .next {
  right: 10px;
}

/* Footer Section */
footer {
  background-color: #242424ff;
  color: white;
  padding: 20px 0;
  text-align: center;
  position: relative;
  z-index: 1;
}

footer p {
  margin: 0;
}

footer a {
  color: white;
  text-decoration: none; /* optional: removes underline */
}

footer a:hover {
  text-decoration: underline; /* optional: underline on hover */
}

/* Responsive Header Layout for Mobile */
@media (max-width: 768px) {
  .navbar {
    justify-content: space-between;
    padding: 10px 10px;
    display: flex;
    align-items: center;
    gap: 5px;
    position: relative;
  }

  .hamburger {
    width: 30px;
    height: 22px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
    z-index: 1001;
  }

  .hamburger span {
    display: block;
    height: 4px;
    width: 100%;
    background-color: white;
    border-radius: 2px;
    transition: all 0.3s ease-in-out;
    position: relative;
  }

  .hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }

  .navbar .logo {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    flex-grow: 1;
    gap: 5px;
    margin: 0 auto;
  }

  .navbar .logo img:first-of-type,
  .navbar .logo img:nth-of-type(2) {
    height: 30px;
    width: auto;
  }

  .facebook-icon {
    display: block;
    font-size: 24px;
    color: white;
    margin-left: auto;
    margin-right: 10px;
    text-decoration: none;
    z-index: 3001;
  }

  .nav-links {
    position: fixed;
    top: 0;
    left: -250px;
    height: 100%;
    width: 200px;
    background-color: #424242;
    flex-direction: column;
    padding-top: 60px;
    transition: left 0.3s ease;
    z-index: 1000;
    display: flex;
    overflow-y: auto;
  }

  .nav-links.active {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 250px;
    background-color: #333;
    z-index: 1000;
    padding: 80px 20px 20px 20px;
    gap: 15px;
    overflow-y: auto;
  }

  .nav-links.active li {
    width: 100%;
  }

  .nav-links.active li a {
    display: block;
    width: 100%;
    color: white;
    text-decoration: none;
    padding: 12px 10px;
    font-size: 18px;
    border-bottom: 1px solid #444;
  }
}

@media (min-width: 320px) and (max-width: 374px) {
  .navbar .logo img:first-of-type {
    height: 30px;
  }
  .navbar .logo img:nth-of-type(2) {
    height: 30px;
  }
  .hamburger,
  .facebook-icon {
    font-size: 14px;
  }
}

@media (min-width: 375px) and (max-width: 425px) {
  .navbar .logo img:first-of-type {
    height: 40px;
  }
  .navbar .logo img:nth-of-type(2) {
    height: 40px;
  }
  .hamburger,
  .facebook-icon {
    font-size: 16px;
  }
}

@media (min-width: 426px) and (max-width: 480px) {
  .navbar .logo img:first-of-type {
    height: 40px;
  }
  .navbar .logo img:nth-of-type(2) {
    height: 40px;
  }
  .hamburger,
  .facebook-icon {
    font-size: 18px;
  }
}

@media (min-width: 481px) and (max-width: 768px) {
  .navbar .logo img:first-of-type {
    height: 50px;
  }
  .navbar .logo img:nth-of-type(2) {
    height: 50px;
  }
  .hamburger,
  .facebook-icon {
    font-size: 20px;
  }
}

@media (min-width: 769px) and (max-width: 1023px) {
  .navbar .logo img:first-of-type {
    height: 80px;
  }

  .navbar .logo img:nth-of-type(2) {
    height: 80px;
  }
}


@media (min-width: 769px) {
  .hamburger {
    display: none;
  }

  .nav-links {
    display: flex !important;
  }
}

/* Main content image adjustment for mobile */
@media (max-width: 768px) {
  #home {
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
    height: 60vh;
    width: 100%;
  }

  .nav-links {
    position: fixed;
    top: 0;
    left: -250px;
    height: 100%;
    width: 200px;
    background-color: #424242ff;
    flex-direction: column;
    padding-top: 60px;
    transition: left 0.3s ease;
    z-index: 3000;
    max-height: 100vh;
    overflow-y: auto;
  }

  .nav-links.active {
    display: flex;
    left: 0;
  }

  .nav-links li {
    width: 100%;
    text-align: left;
    padding: 12px 20px;
    box-sizing: border-box;
    margin: 0;
    padding-left: 20px;
  }

  .nav-links a {
    font-size: 20px;
    color: white;
  }

  .nav-links .dropdown .dropbtn {
    width: 100%;
    text-align: left;
    padding: 12px 20px;
    font-size: 16px;
    background: none;
    border: none;
    box-sizing: border-box;
  }

  .nav-links .dropdown-content a {
    padding: 5px 10px 10px 20px;
    font-size: 15px;
  }

  .navbar .nav-links li.dropdown > .dropbtn {
    text-align: left;
    display: block;
    width: 100%;
    padding-left: 0px;
    margin-left: 0;
    font-size: 20px;
  }

  .navbar .nav-links li.dropdown .dropdown-content {
    padding-left: 0px;
  }

  .nav-links li.dropdown {
    text-align: left;
    width: 100%;
    padding-left: 20px;
    margin: 0;
  }

  .nav-links li.dropdown > .dropbtn {
    display: block;
    width: 100%;
    text-align: left;
    margin: 0;
    padding-left: 0;
  }

  .welcome-box {
    max-width: 100%;
    max-height: 100%;
    margin-left: auto;
    margin-right: auto;
    padding: 20px;
  }

  .welcome-box h2,
  .welcome-box p {
    font-size: 1.2rem;
    margin-bottom: 10px;
  }

  .call-now-btn {
    padding: 15px 25px;
    font-size: 16px;
  }

  #home .container {
    padding-left: 100px;
    padding-top: 25px;
    justify-content: center;
  }
}

/* Further adjustments for smaller phones */

@media (max-width: 480px) {
  #home {
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center top;
    height: auto;
    position: relative;
  }

  .welcome-box {
    position: static;
    margin-top: 75px; /* small buffer below image */
    margin-bottom: 10px;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
    padding: 60px;
    border-radius: 10px;
    background-color: rgba(66, 66, 66, 0.75);
    color: white;
    z-index: 2;
  }

  .welcome-box h2,
  .welcome-box p {
    font-size: 1rem;
  }

  .call-now-btn {
    padding: 12px 20px;
    font-size: 20px;
  }

  #home .container {
    padding-left: 20px;
    padding-right: 20px;
    padding-top: 200px;
  }

  #tree-removal {
    margin-top: -25px;
  }
}

@media (min-width: 481px) and (max-width: 768px) {
  #home {
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center top;
    height: auto;
    position: relative;
    padding-bottom: 0;
  }

  #home .container {
    padding-left: 20px;
    padding-right: 20px;
    padding-top: 60vw; /* scales space above the welcome-box based on screen width */
  }

  .welcome-box {
    position: static;
    margin-top: 20px; /* spacing below the image */
    margin-bottom: 40px;
    max-width: 95%;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
    padding: 50px;
    border-radius: 10px;
    background-color: rgba(66, 66, 66, 0.75);
    color: white;
    z-index: 2;
  }

  .welcome-box h2,
  .welcome-box p {
    font-size: 1.1rem;
    margin-bottom: 10px;
  }

  .call-now-btn {
    padding: 12px 20px;
    font-size: 18px;
  }

  #tree-removal {
    margin-top: 60px;
  }
}

form[hidden] {
  display: none !important;
}

