html, body {
  max-width: 100vw;
  overflow-x: hidden;

}

/* === GLOBAL === */
body {
  margin: 0;
  font-family: 'Poppins', sans-serif;
  background: linear-gradient(to right top, #e0c3fc, #8ec5fc);
  color: #333;
  backdrop-filter: blur(10px);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  flex-direction: column;
  padding: 20px;
}

/* === LOGO === */
#logo {
  margin-top: 10px;
  max-width: 120px;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.6));
}


h1, h2, h3, h4, h5, h6, p {
  margin: 0;
}

/* === LOGIN PAGE === */
.auth-container {
  background: white;
  padding: 50px 30px;
  border-radius: 20px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  text-align: center;
  max-width: 400px;
  width: 90%;
  animation: fadeIn 1.2s ease-in-out;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.auth-container::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, #e0c3fc, #8ec5fc);
  z-index: -1;
  animation: rotate 6s linear infinite;
  opacity: 0.1;
}

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.auth-container h2 {
  margin-bottom: 25px;
  color: #6a11cb;
  font-size: 2rem;
}

.auth-container button {
  background-color: #ffffff;
  color: #444;
  border: 2px solid #ccc;
  padding: 12px 18px;
  border-radius: 50px;
  font-size: 1rem;
  cursor: pointer;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 5px 15px rgba(66, 133, 244, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;

  /* Add this */
  width: fit-content;
  margin: 0 auto;
}

.auth-container .no-account-button {
  background-color: #ffffff; /* White background like Google button */
  color: #3c4043; /* Darker text for better contrast, similar to Google's */
  border: 1px solid #dadce0; /* Subtle grey border, typical of Google buttons */
  padding: 12px 18px;
  border-radius: 50px; /* Makes the button pill-shaped */
  font-size: 0.9rem; /* Equivalent to 14px, common for Google buttons */
  cursor: pointer;
  font-weight: 500; /* Medium font-weight, similar to Google's */
  font-family: 'Roboto', sans-serif; /* Google often uses Roboto; ensure it's imported or available */
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05), 0 1px 3px 1px rgba(0, 0, 0, 0.01); /* More subtle shadow */
  transition: background-color 0.3s ease, box-shadow 0.3s ease; /* Transition for hover effects */

  width: fit-content;
  margin: 20px auto 0 auto;
  transform: scale(1.1);
}

.auth-container .no-account-button:hover {
  background-color: #f0f8ff; /* Light blue tint on hover (AliceBlue) */
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.08), 0 4px 6px 2px rgba(0, 0, 0, 0.04);
}

.auth-container .no-account-button:active {
  background-color: #e6f2ff; /* Slightly darker light blue on active */
  box-shadow: none; /* Remove shadow on click for a pressed effect */
}


/* === MAIN CONTENT === */
.container {
  display: none;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: white;
  padding: 30px 20px;
  border-radius: 20px;
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.1);
  width: 95%;
  max-width: 700px;
  animation: slideUp 0.8s ease-out;
  margin: 20px;
}

.container h1 {
  color: #4a148c;
  font-size: 1.8rem;
  margin-bottom: 15px;
  font-weight: 700;
}

.swami-image {
  width: 100%;
  max-width: 350px;
  border-radius: 20px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2);
  margin-bottom: 20px;
}

/* === INSTRUCTIONS === */
.description-container {
  width: 100%;
  text-align: left;
  margin-bottom: 20px;
}

.toggle-button {
  background: linear-gradient(135deg, #1e3a8a, #3b82f6); /* dark blue to sky blue */
  color: white;
  padding: 14px 20px;
  border: none;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  font-size: 1.1em;
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.3);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.toggle-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(59, 130, 246, 0.4);
}

.toggle-button:active {
  transform: scale(0.98);
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}


.description-content {
  display: none;
  background-color: #f5f2fc;
  padding: 15px 20px;
  border-radius: 12px;
  font-size: 1rem;
  color: #4a148c;
  font-weight: 600;
  animation: fadeIn 0.5s ease;
}

.description-content ul {
  padding-left: 20px;
}

/* === JAPAM BUTTONS === */
.word-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: nowrap; /* Force buttons to stay in same row */
  margin-bottom: 20px;
  gap: 7px;
}

.word-buttons button {
  min-width: 80px; /* Ensure button is big enough */
  flex-shrink: 0;   /* Prevent button from shrinking */
  font-size: 1.1rem;
  padding: 14px 28px;
  border-radius: 50px;
  color: white;
  box-shadow: 0 4px 12px rgba(106, 17, 203, 0.4);
  transition: all 0.3s ease-in-out;
  -webkit-tap-highlight-color: transparent;
  outline: none;
  position: relative;
  overflow: hidden;
}


.word-buttons button:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 18px rgba(106, 17, 203, 0.5);
}

.ripple {
  position: absolute;
  border-radius: 50%;
  transform: scale(0);
  animation: ripple-animation 0.2s linear;
  background: rgba(255, 215, 0, 0.5); /* Light gold */
  pointer-events: none;
}

@keyframes ripple-animation {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

.disabled-glow {
  box-shadow: 0 0 10px gold;
}

.gold-glow {
  animation: goldPulse 1s infinite alternate;
}

@keyframes goldPulse {
  from {
    box-shadow: 0 0 10px #FFD700;
  }
  to {
    box-shadow: 0 0 20px #FFA500;
  }
}

.top-toast {
  position: fixed;
  top: 10px;
  left: 50%;
  transform: translateX(-50%) scale(0.9);
  background: #FFD700;
  color: black;
  padding: 10px 20px;
  border-radius: 6px;
  z-index: 9999;
  opacity: 0;
  transition: all 0.4s ease;
  font-weight: bold;
  font-size: 1em;
  text-align: center;
}

.top-toast.show {
  opacity: 1;
  transform: translateX(-50%) scale(1);
}


button:focus {
  outline: none;
  box-shadow: none;
}

.word-buttons button:hover {
  transform: scale(1.07);
  box-shadow: 0 4px 12px rgba(106, 17, 203, 0.4);
}

.word-buttons button:disabled {
  background-color: gold;
  color: purple;
}

/* === COUNTER & OFFER BUTTON === */
#counter, #user-total {
  font-size: 1.1rem;
  color: #333;
  font-weight: bold;
  margin: 10px 0;
}

#offer-button {
  /* Keep display: none as the initial state */
  display: none;
  margin-top: 1rem;
  padding: 12px 20px;
  font-size: 1.2rem; /* Adjusted for better appearance */
  font-weight: bold;
  background-color: #FFD700; /* Default color before glow */
  color: #000;
  border: none;
  border-radius: 8px; /* Consistent with other buttons */
  cursor: pointer;
  
  /* Initial state for transition when .show is applied */
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.5s ease; /* Smooth transition for appearance */
}

#offer-button.show {
  display: inline-block; /* Make it visible */
  opacity: 1; /* Make it opaque */
  transform: translateY(0); /* Move it into place */
}

/* Keep your .gold-glow and @keyframes glow styles as they are. */
/* They will now correctly apply on top of the visible button. */

.gold-glow {
  box-shadow: 0 0 15px 5px gold;
  animation: glow 1s ease-in-out infinite alternate;
}

@keyframes glow {
  from {
    box-shadow: 0 0 10px gold;
  }
  to {
    box-shadow: 0 0 20px 10px gold;
  }
}


/* === ANIMATIONS === */
@keyframes slideUp {
  from { transform: translateY(40px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* === RESPONSIVE FIXES === */
@media (max-width: 480px) {
  .auth-container h2 {
    font-size: 1.5rem;
  }

  .container h1 {
    font-size: 1.4rem;
  }

  .description-content {
    font-size: 0.95rem;
  }

  .word-buttons button {
    font-size: 1.1rem;
    padding: 10px 18px;
  }
}

#logout-button { /* Styling for the new logout button */
    background-color: #f44336; /* Red color, common for logout */
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    border: none;
    font-size: 0.9rem;
    cursor: pointer;
    margin-top: 10px; /* Space it from welcome message */
    transition: background-color 0.3s ease;
}

#logout-button:hover {
    background-color: #d32f2f;
}

.quote-container {
    background-color: rgba(255, 255, 255, 0.8); /* Slightly transparent white */
    margin-top: 25px; /* Space from the login box */
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    max-width: 600px; /* Wider than login for readability */
    width: 90%;
    text-align: center;
    font-style: italic;
    color: #4a148c; /* Match your existing theme purple */
    line-height: 1.6;
    animation: fadeIn 1s ease-in-out 0.5s forwards; /* Delayed fade-in */
    opacity: 0; /* Start hidden for animation */
}

.quote-text {
    font-size: 1.1rem;
    margin-bottom: 15px;
}

.quote-source {
    font-size: 0.9rem;
    font-weight: bold;
    color: #6a11cb;
    text-align: right;
    margin-top: 10px; /* Space from quote text */
}

.auth-container .subtitle {
    font-size: 0.95rem; /* Slightly smaller than the main heading */
    color: #6a11cb; /* Matches your existing purple theme */
    margin-top: -15px; /* Pull it up a bit closer to the main title */
    margin-bottom: 25px; /* Space it out from the button */
    font-weight: 600; /* Make it a bit bolder */
}

/* Add a responsive adjustment for smaller screens */
@media (max-width: 480px) {
    .auth-container .subtitle {
        font-size: 0.85rem;
    }
}

/* === COUNTER DISPLAY === */
#counter, #user-total {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 12px;
  padding: 10px 20px;
  backdrop-filter: blur(6px);
  color: #4a148c;
  font-size: 1.2rem;
  font-weight: 600;
  margin-top: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* === OFFER BUTTON === */
#offer-button {
  background: linear-gradient(to right, #ff416c, #ff4b2b);
  color: white;
  border-radius: 50px;
  padding: 14px 26px;
  font-size: 1.05rem;
  box-shadow: 0 6px 15px rgba(255, 65, 108, 0.4);
  transition: all 0.3s ease;
  display: inline-block;
}

#offer-button:hover {
  transform: scale(1.08);
  background: linear-gradient(to right, #ff4b2b, #ff416c);
  box-shadow: 0 8px 20px rgba(255, 65, 108, 0.5);
}

/* === LOGOUT BUTTON === */
#logout-button {
  background: linear-gradient(to right, #f44336, #e53935);
  padding: 10px 20px;
  border-radius: 30px;
  font-size: 0.95rem;
  font-weight: bold;
  box-shadow: 0 4px 12px rgba(244, 67, 54, 0.4);
}

#logout-button:hover {
  background: linear-gradient(to right, #e53935, #d32f2f);
  transform: scale(1.05);
}

/* === WELCOME MESSAGE === */
#welcome-message {
  font-family: 'Great Vibes', cursive;
  font-size: 2rem;
  color: darkcyan;
  margin-bottom: 10px;
  font-weight: bolder;
}

/* === TOTAL JAPAM DISPLAY (GLOBAL COUNT) === */
.total-japam-box {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 15px;
  padding: 15px 30px;
  backdrop-filter: blur(12px);
  color: #4a148c;
  font-size: 1.4rem;
  font-weight: bold;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
  margin-top: 20px;
  border: 2px solid gold;
  text-shadow: 0 1px 2px white;
}

/* === SWAMI IMAGE === */
.swami-image {
  border-radius: 20px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
  pointer-events: none; /* disables right-click & drag */
  user-select: none;
}

.swami-image:hover {
  transform: scale(1.02);
}

/* === RESPONSIVE === */
@media (max-width: 500px) {
  #welcome-message {
    font-size: 2rem;
  }
  .total-japam-box {
    font-size: 1.2rem;
    padding: 12px 20px;
  }
}

#grand-total {
  background: rgba(255, 255, 255, 0.15); /* translucent glass */
  border-radius: 18px;
  padding: 20px 30px;
  margin: 20px auto;
  max-width: 90%;
  text-align: center;
  color: #4a148c; /* deep purple */
  font-size: 1.5rem;
  font-weight: bold;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(10px);
  border: 2px solid gold;
  text-shadow: 0 1px 2px #fff;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

#grand-total:hover {
  transform: scale(1.02);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

#offer-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.japam-popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh; /* Covers only the visible screen */
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeIn 0.3s ease-in-out;
}

.japam-popup {
  background: #fff;
  border-radius: 1.5rem;
  padding: 2rem;
  max-width: 450px;
  width: 90%;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  animation: scaleIn 0.25s ease;
  font-family: 'Segoe UI', sans-serif;
  color: #333;
}


.japam-popup h2 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  text-align: center;
  color: #1d4ed8;
}

.japam-popup ul {
  padding-left: 1.2rem;
  list-style-type: disc;
  margin-bottom: 1.5rem;
}

.japam-popup ul li {
  margin-bottom: 0.8rem;
  line-height: 1.5;
}

.japam-close-btn {
  background-color: #2563eb;
  color: #fff;
  padding: 12px;
  font-size: 1rem;
  font-weight: bold;
  border: none;
  border-radius: 12px;
  width: 100%;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.japam-close-btn:hover {
  background-color: #1e40af;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes scaleIn {
  from { transform: scale(0.95); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

.info-banner {
  max-width: 800px;
  margin: 1.5rem auto;
  padding: 1rem 1.5rem;
  background: rgba(255, 251, 235, 0.75); /* Light yellow glassy */
  backdrop-filter: blur(8px);
  border: 1px solid #facc15; /* Tailwind amber-400 */
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(251, 191, 36, 0.2); /* Glow */
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 1rem;
  color: #78350f; /* Tailwind amber-900 */
  line-height: 1.5;
}

.info-banner .info-icon {
  font-size: 1.5rem;
  margin-top: 2px;
  flex-shrink: 0;
}

.return-button {
  margin-top: 2rem; /* Add this line */
  display: inline-block;
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  padding: 12px 20px;
  border-radius: 10px;
  text-decoration: none;
  font-size: 1rem;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.3);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}


.return-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.return-button:active {
  transform: scale(0.97);
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.g_id_signin {
  transform: scale(1.2); /* Scale up size */
}

.mail-link {
  display: inline-flex;
  align-items: center;
  font-family: Arial, sans-serif;
  font-size: 18px;
  font-weight: bold;
  color: #007BFF;
  text-decoration: none; /* Remove underline */
  padding: 10px 15px;
  border-radius: 8px;
  transition: 0.3s ease-in-out;
  margin-top: 5px;
}

.mail-link:hover {
  color: #0056b3;
  transform: scale(1.05);
  text-decoration: none; /* Ensure no underline on hover */
}

/* Glassy FAQ Section with light purple gradient */
.glassy-faq-section {
  max-width: 768px;
  margin: 2rem auto;
  padding: 2rem 1.5rem;
  border-radius: 20px;
  background: linear-gradient(135deg, #f5e8ff, #e3d0ff);
  border: 1px solid rgba(180, 130, 255, 0.2);
  box-shadow: 0 8px 24px rgba(153, 102, 255, 0.15);
  color: #2d0039;
}

/* Heading */
.faq-heading {
  text-align: center;
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 2rem;
  color: #c59d00;
}

/* FAQ Item */
.faq-item {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(204, 174, 255, 0.3);
  border-radius: 16px;
  margin-bottom: 1.5rem;
  box-shadow: 0 6px 16px rgba(90, 50, 150, 0.15);
  overflow: hidden;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.faq-item:hover {
  background: rgba(255, 255, 255, 0.8);
  box-shadow: 0 10px 30px rgba(90, 50, 150, 0.25);
}

/* FAQ Question */
.faq-question {
  padding: 1.25rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  font-weight: 600;
  font-size: 1.05rem;
  color: #4c0050;
}

.faq-toggle-icon .chevron {
  transition: transform 0.3s ease;
}

.faq-item.open .faq-toggle-icon .chevron {
  transform: rotate(180deg);
}

/* FAQ Answer */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 1.5rem;
  font-size: 0.95rem;
  color: #333;
  line-height: 1.6;
  transition: max-height 0.35s ease, padding 0.3s ease;
}

.faq-item.open .faq-answer {
  padding: 1rem 1.5rem 1.25rem;
  max-height: 500px;
}

/* Responsive */
@media (max-width: 600px) {
  .faq-heading {
    font-size: 1.5rem;
  }

  .faq-question {
    font-size: 1rem;
  }

  .faq-answer {
    font-size: 0.9rem;
  }
}
