/* --- Global Reset & Basics --- */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  background: #f6f6f6;
  padding-top: 70px; /* Space for fixed header */
  padding-bottom: 60px; /* Space for fixed footer */
}

/* --- Header --- */
.header {
  position: fixed;
  top: 0;
  width: 100%;
  background: #2e7d32;
  color: white;
  padding: 10px;
  text-align: center;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}
.header-content {
  display: flex;
  align-items: center;
  justify-content: center;
}
.header img {
  height: 40px;
  margin-right: 15px;
}
.header h1 {
  font-size: 22px;
  margin: 0;
}

/* --- Footer --- */
.footer {
  position: fixed;
  bottom: 0;
  width: 100%;
  background: #2e7d32;
  color: white;
  text-align: center;
  padding: 12px;
  font-size: 14px;
  z-index: 1000;
}

/* --- Section Dividers --- */
.section-divider {
  margin-top: 40px;
  text-align: center;
  border-bottom: 2px solid #ccc;
  margin-bottom: 20px;
  padding-bottom: 10px;
}
.section-divider h2, .section-divider h3 {
  color: #1b5e20;
}

/* --- Booking Button Section --- */
.booking-cta {
  text-align: center;
  margin: 30px auto 10px;
  padding: 0 15px;
}
.btn-book {
  background-color: #d32f2f; /* Red for urgency */
  color: white;
  border: none;
  padding: 15px 30px;
  font-size: 18px;
  font-weight: bold;
  border-radius: 50px;
  cursor: pointer;
  box-shadow: 0 4px 6px rgba(0,0,0,0.2);
  transition: transform 0.2s, background 0.2s;
  width: 100%;
  max-width: 300px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.btn-book:hover {
  background-color: #b71c1c;
  transform: scale(1.05);
}

/* --- Map Section --- */
.map-wrapper {
  padding: 15px;
  max-width: 800px;
  margin: 0 auto;
}
.map-card {
  width: 100%;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  border: 1px solid #ddd;
}

/* --- Services & Doctor Grid --- */
.cards-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); /* Responsive Grid */
  gap: 15px;
  padding: 20px;
  max-width: 1000px;
  margin: 0 auto;
}
.card {
  background: white;
  padding: 10px;
  border-radius: 10px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  text-align: center;
  transition: transform 0.2s;
}
.card:hover {
  transform: translateY(-5px);
}
.card img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-radius: 8px;
}
.card p {
  margin-top: 10px;
  font-weight: bold;
  font-size: 14px;
  color: #333;
}

/* --- DOCTOR SPECIFIC STYLES --- */
.doctor-card {
  background: white;
  padding: 15px;
  border-radius: 12px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
  border: 1px solid #eee;
}
.doctor-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 15px rgba(0,0,0,0.2);
  border-color: #2e7d32;
}
.doctor-img {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 10px;
  border: 3px solid #e0f2f1;
}
.doc-name {
  color: #004d40;
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 5px;
}
.doc-spec {
  color: #666;
  font-size: 13px;
  margin-bottom: 10px;
}
.doc-badge {
  background-color: #e8f5e9;
  color: #2e7d32;
  padding: 4px 8px;
  border-radius: 15px;
  font-size: 12px;
  font-weight: bold;
  display: inline-block;
}

/* Doctor Details Modal Specifics */
.doc-detail-header {
  text-align: center;
  margin-bottom: 20px;
}
.doc-detail-img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 4px solid #2e7d32;
  margin-bottom: 15px;
}
.detail-row {
  margin-bottom: 15px;
  border-bottom: 1px solid #eee;
  padding-bottom: 10px;
}
.detail-label {
  font-weight: bold;
  color: #333;
  display: block;
  margin-bottom: 3px;
}
.detail-text {
  color: #555;
  font-size: 15px;
}
.btn-book-doc {
  background-color: #2e7d32;
  color: white;
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  margin-top: 10px;
}
.btn-book-doc:hover {
  background-color: #1b5e20;
}

/* --- MODAL (POPUP) FORM STYLES --- */
.modal {
  display: none; 
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.6); 
  backdrop-filter: blur(3px);
}

.modal-content {
  background-color: #fefefe;
  margin: 5% auto;
  padding: 20px;
  border: 1px solid #888;
  width: 90%;
  max-width: 500px;
  border-radius: 12px;
  position: relative;
  animation: slideIn 0.3s;
}

@keyframes slideIn {
  from {transform: translateY(-50px); opacity: 0;}
  to {transform: translateY(0); opacity: 1;}
}

.close {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}
.close:hover,
.close:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

/* Form Styles */
.form-header {
  text-align: center;
  margin-bottom: 20px;
  color: #2e7d32;
}
.form-group {
  margin-bottom: 15px;
}
.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
  color: #333;
}
.form-group input, 
.form-group select {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 16px; 
}
.btn-submit {
  width: 100%;
  padding: 12px;
  background-color: #2e7d32;
  color: white;
  border: none;
  border-radius: 5px;
  font-size: 18px;
  cursor: pointer;
  font-weight: bold;
}
.btn-submit:disabled {
  background-color: #ccc;
}
#loadingMsg {
  display: none;
  text-align: center;
  margin-top: 10px;
  color: #2e7d32;
  font-weight: bold;
}

/* Mobile Adjustments */
@media (min-width: 600px) {
  .cards-container {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }
  .card img {
    height: 150px;
  }
}
