/* 🌌 Layout & Theme */
html, body {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: url("/static/guru.png") no-repeat center center fixed;
  background-size: cover;
  color: white;
  min-height: 100vh;
  -webkit-background-size: cover; /* iOS fix */
  -webkit-overflow-scrolling: touch;
}

/* 🧘 Sticky Header */
header {
  padding: 1.5rem 2rem;
  font-size: 2rem;
  font-weight: 600;
  position: sticky;
  top: 0;
  z-index: 100;
  border: none;
  background: none;
  box-shadow: none;
  backdrop-filter: none;
  font-family: 'Cinzel', serif;
  color: #fff;
  letter-spacing: 1px;
}

/* 💬 Chat Area */
main {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 800px;
  margin: 3rem auto 8rem;
  padding: 0 1rem;
  min-height: calc(100vh - 3rem);
}

#chat-container {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding-bottom: 14rem;
}

/* 🗯️ Message Bubbles */
.message {
  max-width: 75%;
  padding: 1rem 1.2rem;
  border-radius: 1.5rem;
  font-size: 1.05rem;
  line-height: 1.6;
  backdrop-filter: blur(6px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
  word-wrap: break-word;
  white-space: pre-wrap;
  animation: fadeInUp 0.3s ease;
}

.message.user {
  align-self: flex-end;
  background-color: rgba(0, 128, 255, 0.35);
  text-align: right;
}

.message.bot {
  align-self: flex-start;
  background-color: rgba(255, 255, 255, 0.15);
  text-align: left;
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* 📥 Prompt Input Form */
form#chat-form {
  position: sticky;
  bottom: 0;
  margin: 0 auto;
  padding: 1rem;
  display: flex;
  gap: 10px;
  width: 90%;
  max-width: 800px;
  background-color: rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(6px);
  border-radius: 20px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  z-index: 100;
}

textarea {
  flex: 1;
  resize: none;
  padding: 1rem;
  font-size: 1.1rem;
  border: none;
  border-radius: 12px;
  background-color: rgba(255, 255, 255, 0.12);
  color: white;
  outline: none;
}

button {
  padding: 0 20px;
  font-size: 1.2rem;
  font-weight: bold;
  border: none;
  border-radius: 12px;
  background-color: rgba(50, 50, 50, 0.8);
  color: white;
  cursor: pointer;
  transition: background 0.3s ease;
}

button:hover {
  background-color: rgba(80, 80, 80, 0.9);
}

/* 📞 Contact Section */
#contact-section {
  margin-top: 8rem;
  padding: 4rem 2rem;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(5px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 3rem;
}

#contact-section h2 {
  font-size: 2rem;
  margin-bottom: 2rem;
  color: white;
}

/* 🧾 Contact Cards Grid */
.contact-cards {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  width: 100%;
  max-width: 1000px;
}

/* Individual Contact Card */
.contact-card {
  background: rgba(255, 255, 255, 0.1);
  padding: 1.5rem;
  border-radius: 20px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  text-align: center;
  width: 280px;
  transition: transform 0.2s ease;
}

.contact-card:hover {
  transform: translateY(-5px);
}

.contact-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: #fff;
}

.contact-card p {
  margin: 0;
  font-size: 0.95rem;
  color: #ccc;
  line-height: 1.5;
}

/* 📬 Contact Form */
.contact-form {
  margin-top: 3rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.contact-form .form-row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 600px) {
  .contact-form .form-row {
    flex-direction: row;
  }
}

.contact-form input,
.contact-form textarea {
  flex: 1;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.07);
  color: white;
  border: none;
  border-radius: 10px;
  outline: none;
  font-size: 1rem;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: #ccc;
}

.contact-form button[type="submit"] {
  align-self: center;
  margin-top: 1rem;
  background-color: #aa7ef9;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 0.8rem 2rem;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.3s ease;
}

.contact-form button[type="submit"]:hover {
  background-color: #c49aff;
}

/* 📱 Mobile Responsive Adjustments */
@media screen and (max-width: 600px) {
  main {
    margin: 2rem 1rem 6rem;
  }

  form#chat-form {
    width: 95%;
  }

  #chat-container {
    padding-bottom: 12rem;
  }

  .contact-cards {
    flex-direction: column;
    align-items: center;
  }

  #contact-section h2 {
    font-size: 1.5rem;
  }
}

.social-links {
  margin-top: 0.5rem;
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.social-links a {
  color: #ccc;
  font-size: 1.2rem;
  transition: color 0.3s;
}

.social-links a:hover {
  color: #fff;
}

/* 🔚 Footer */
footer#footer-section {
  padding: 1rem;
  text-align: center;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(5px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: white;
  margin-top: 2rem;
}
