@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap");

:root {
  --primary-color: #dcb106;
  --primary-color-dark: #161614;
  --primary-color-light: #fef9e7;
  --secondary-color: #dad015;
  --text-head: #131312;
  --text-dark: #0d0d0d;
  --text-light: #161614;
  --white: #ffffff;
  --max-width: 1500px;
  --btn-hover: #e8c423;
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.section-container {
  max-width: var(--max-width);
  margin: auto;
  padding: 5rem 1rem;
  user-select: none;
}

.section-header {
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-head);
}

.btn {
  padding: 0.75rem 2rem;
  outline: none;
  border: none;
  font-size: 1rem;
  white-space: nowrap;
  color: var(--white);
  background-color: var(--secondary-color);
  border-radius: 5px;
  cursor: pointer;
}

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

img {
  width: 100%;
  display: flex;
}

a {
  text-decoration: none;
}

body {
  font-family: "Poppins", sans-serif;
}

/* Header section */

header {
  background-image: linear-gradient(
      to left,
      rgba(0, 0, 0, 0.5),
      rgba(0, 0, 0, 0.5)
    ),
    url("/assets/homeBg.jpg");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
}

.nav-container {
  padding: 2rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--primary-color-light);
  max-width: 100%;
}

.logo {
  /* These properties stay on the main container */
  font-size: 1.5rem;
  font-weight: 600;
}

.logo a {
  /* This is the new flex container */
  display: flex;
  align-items: center;

  /* Styling for the link itself */
  text-decoration: none; /* Removes underline */
  color: var(--text-head); /* Sets text color */
  gap: 0.5rem; /* Optional: adds space between image and text */
}

.logo img {
  /* This rule remains the same */
  width: 70px;
  height: 70px;
  background-image: transparent;
}

.nav-link-container {
  display: flex;
}

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}

.nav-link-container .nav-close {
  display: none;
  color: var(--text-head);
  font-size: 1.5rem;
}

.nav-container .nav-open {
  display: bold;
  color: var(--text-head);
  font-size: 1.5rem;
}

.nav-container .nav-open[aria-expanded="true"] + .nav-link-container {
  translate: 0;
}
.link a {
  padding: 0.5rem;
  color: var(--primary-color);
}

.link a:hover {
  color: var(--secondary-color);
}

/* Style for the new "Login" button */
.btn.btn-secondary {
  background-color: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.btn.btn-secondary:hover {
  background-color: var(--primary-color);
  color: var(--white);
}

/* Container for the new auth buttons */
.nav-auth-btns {
  display: flex;
  gap: 1rem;
}

/* Make the main nav container align all items (links and buttons) */
.nav-link-container {
  align-items: center;
  gap: 2rem;
}

/* === User Dropdown Menu === */
.user-menu {
  position: relative;
}

.user-menu-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: var(--primary-color);
}

/* Dropdown arrow icon */
.user-menu-btn .fa-chevron-down {
  font-size: 0.8rem;
  transition: transform 0.3s;
}

/* Add 'open' class with JS to rotate arrow */
.user-menu-btn.open .fa-chevron-down {
  transform: rotate(180deg);
}

.user-dropdown {
  display: none; /* Hidden by default */
  position: absolute;
  top: 110%; /* Position just below the button */
  right: 0;
  background-color: var(--white);
  border-radius: 8px;
  box-shadow: 5px 5px 25px rgba(0, 0, 0, 0.15);
  min-width: 200px;
  z-index: 100;
  overflow: hidden; /* Ensures border-radius on links */
}

/* Add 'show' class with JS to display */
.user-dropdown.show {
  display: block;
}

.user-dropdown a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  color: var(--text-dark);
  text-decoration: none;
  transition: background-color 0.2s;
}

.user-dropdown a i {
  width: 20px; /* Aligns icons nicely */
  text-align: center;
}

.user-dropdown a:hover {
  background-color: var(--primary-color-light);
  color: var(--primary-color);
}

@media (width < 900px) {
  /* Stack all button groups vertically in the mobile menu */
  .contact-btn {
    margin-top: 2rem;
  }

  .nav-auth-btns {
    flex-direction: column;
    width: 100%;
    margin-top: 1rem;
  }

  .nav-auth-btns .btn {
    width: 100%;
    text-align: center;
  }
}

.header-container {
  display: flex;
  align-items: center;
  gap: 5rem;
}

.header-container h1 {
  margin-bottom: 1rem;
  max-width: 800px;
  font-size: 3.4rem;
  line-height: 4rem;
  color: var(--white);
}

.header-container p {
  margin-bottom: 2rem;
  max-width: 600px;
  color: var(--primary-color-light);
}

/* Header form section */

.header-form {
  width: 100%;
  max-width: 350px;
}

.header-form form {
  display: grid;
  gap: 1rem;
  padding: 2rem;
  border-radius: 10px;
  background-color: var(--white);
  box-shadow: 5px 5px 25px #1a4b46bd;
}

.header-form h4 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-color);
}

.header-form input {
  padding: 1rem;
  border: 2px solid #46c8bb;
  border-radius: 6px;
  outline: none;
}

.header-form input::placeholder {
  color: var(--text-head);
}

.form-btn:hover {
  background-color: var(--btn-hover);
}

/* Service section */

.service-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.service-head-content p {
  max-width: 600px;
  color: var(--text-light);
}

.service-head-content h2 {
  color: var(--primary-color);
}

.service-btn {
  padding: 0.75rem 1rem;
  outline: none;
  border: none;
  font-size: 1rem;
  color: var(--white);
  background-color: var(--primary-color);
  border-radius: 5px;
  white-space: nowrap;
  cursor: pointer;
  transition: 0.3s;
}

.service-btn:hover {
  background-color: var(--primary-color-dark);
}

.service-grid {
  margin-top: 4rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.service-card {
  padding: 2rem;
  text-align: center;
  border-radius: 10px;
  box-shadow: 5px 5px 20px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition: ease-in-out 0.3s;
}

.service-card span {
  display: inline-block;
  box-shadow: 5px 5px 20px rgba(0, 0, 0, 0.1);
  margin-bottom: 1rem;
  padding: 10px 20px;
  font-size: 2.5rem;
  color: var(--primary-color);
  background-color: var(--primary-color-light);
  border-radius: 100%;
  transition: 0.3s;
}

.service-card span:hover {
  background-color: var(--text-head);
  color: var(--white);
}

.service-card h4 {
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-dark);
}

.service-card p {
  margin-bottom: 1rem;
  color: var(--text-light);
}

.service-card a {
  color: var(--text-head);
}

.service-card a:hover {
  color: var(--primary-color);
}

.service-card:hover {
  scale: 105%;
}

/* About section */

.about-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  align-items: center;
}

.about-content p {
  margin-bottom: 1rem;
  color: var(--text-light);
}

.about-content h2 {
  color: var(--primary-color);
}

.about-img img {
  max-width: 500px;
  margin: auto;
  border-radius: 8px;
  box-shadow: 10px 10px 20px rgba(0, 0, 0, 0.1);
}

/* Why us section */

.whyUs-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  align-items: center;
}

.whyUs-img img {
  max-width: 500px;
  margin: auto;
  border-radius: 8px;
  box-shadow: 10px 10px 20px rgba(0, 0, 0, 0.1);
}

.whyUs-content p {
  color: var(--text-light);
}

.whyUs-content h2 {
  color: var(--primary-color);
}

/* why us feature list section */

.features {
  margin-top: 4rem;
  display: grid;
  grid-template-columns: 80px auto;
  gap: 2rem;
}

.features span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: var(--primary-color);
  border-radius: 10px;
  box-shadow: 5px 5px 20px rgba(0, 0, 0, 0.1);
}

.features span:hover {
  color: var(--text-head);
}

.features h4 {
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-dark);
}

.features p {
  color: var(--text-light);
}

/* Doctors Section */

.doctors-container {
  background-color: var(--primary-color-light);
}

.doctor-grid {
  margin-top: 4rem;
  display: grid;
  /* Adjust grid columns as needed */
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.doctor-card {
  background: var(--white);
  border-radius: 10px;
  box-shadow: 5px 5px 20px rgba(0, 0, 0, 0.08);
  text-align: center;
  overflow: hidden;
  transition: all 0.3s ease;
}

.doctor-card:hover {
  transform: translateY(-5px);
  box-shadow: 5px 10px 25px rgba(0, 0, 0, 0.12);
}

.doctor-card-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  object-position: top; /* Focuses on the face */
}

.doctor-card-content {
  padding: 1.5rem;
}

.doctor-card-content h3 {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--text-head);
}

.doctor-card-content .specialty {
  font-size: 1rem;
  font-weight: 500;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

/* Footer Section */

/* Responsive adjustments for doctors */
@media (width < 900px) {
  .doctor-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (width < 600px) {
  .doctor-grid {
    grid-template-columns: repeat(1, 1fr);
  }
}

/* Footer section */

.footer {
  /* This uses your existing light yellow background */
  background-color: var(--primary-color-light);
  /* We remove padding here to let the containers manage it */
  padding-top: 5rem;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  gap: 3rem;
  flex-wrap: wrap; /* Allows columns to stack on small screens */
  padding-bottom: 3rem; /* Spacing before the copyright bar */
}

.footer-col {
  /* Each column will share space, but won't shrink below 250px */
  flex: 1;
  min-width: 250px;
}

/* Footer Brand/Logo Column */
.footer-col .logo {
  margin-bottom: 1rem;
}
.footer-col p {
  color: var(--text-light);
  max-width: 300px;
}

/* Footer Links & Contact Columns */
.footer-col h4 {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--text-dark); /* Dark text for heading */
  margin-bottom: 1.5rem;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 0.75rem;
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-col ul li a {
  color: var(--text-light);
  transition: 0.3s;
}

.footer-col ul li a:hover {
  /* Uses your primary yellow for hover */
  color: var(--primary-color);
}

/* Footer Social Icons */
.footer-socials {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

.footer-socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  font-size: 1rem;
  color: var(--primary-color); /* Icon color */
  border: 1px solid var(--primary-color); /* Border color */
  border-radius: 50%;
  transition: 0.3s ease-in-out;
}

.footer-socials a:hover {
  background-color: var(--primary-color); /* Background on hover */
  color: var(--white); /* Icon color on hover */
  border-color: var(--primary-color);
}

/* Footer Copyright Bar */
.footer-bar {
  padding: 1.5rem 1rem;
  text-align: center;
  /* Adds a subtle line to separate it */
  border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.footer-bar p {
  color: var(--text-dark);
  font-weight: 500;
}

.footer-bar p a {
  color: var(--primary-color);
  font-weight: 500;
}

/* Cleanup old footer styles */
.footer-container p {
  /* This is no longer needed */
  display: none;
}

@media (width < 900px) {
  .nav-link-container {
    position: fixed;
    background-color: var(--primary-color-light);
    padding: 1.5rem;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    translate: 100vw 0;
    transition: translate 0.5s ease-in-out;
  }

  .nav-link-container .nav-close {
    display: block;
    background: none;
    width: 30px;
    height: 30px;
    border: none;
    padding-top: 30px;
    margin-inline-start: auto;
    margin-block-end: 8rem;
  }

  .nav-container .nav-open {
    display: block;
    background: none;
    width: 30px;
    height: 30px;
    border: none;
    padding: 5px;
  }

  .nav-links {
    display: flex;
    flex-direction: column;
  }

  .contact-btn {
    margin-top: 2rem;
  }

  .header-container {
    flex-direction: column;
  }

  .header-form {
    max-width: 400px;
  }

  .service-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .about-container {
    grid-template-columns: repeat(1, 1fr);
  }

  .about-img {
    grid-area: 1/1/2/2;
  }

  .about-content {
    text-align: center;
  }

  .whyUs-container {
    grid-template-columns: repeat(1, 1fr);
  }

  .whyUs-content {
    text-align: center;
  }

  .features {
    text-align: left;
  }
}

@media (width < 600px) {
  .service-head {
    flex-direction: column;
    text-align: center;
  }

  .service-grid {
    grid-template-columns: repeat(1, 1fr);
  }

  .features {
    column-gap: 1rem;
  }
}

@media (width < 410px) {
  .header-container h1 {
    font-size: 2.5rem;
    line-height: 3rem;
  }
}

/* Responsive (Stacking in mobile menu) */
@media (width < 900px) {
  .user-menu {
    margin-top: 1rem;
    width: 100%;
  }
  .user-menu-btn {
    width: 100%;
    justify-content: center;
  }
  .user-dropdown {
    width: 100%;
    top: 110%;
    right: auto;
  }
}
