/* 
    Premium 3D Astrology Website Styles
*/

/* --- Variables & Imports --- */
:root {
  --primary-gold: #e2c074;
  --secondary-gold: #c5a059;
  --dark-bg: #0b0c10;
  --glass-bg: rgba(20, 25, 40, 0.4);
  --glass-border: rgba(255, 255, 255, 0.1);
  --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
  --text-light: #f5f5f5;
  --text-muted: #b0b0b0;
  
  --font-heading: 'Marcellus', serif;
  --font-body: 'Outfit', sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-body);
  color: var(--text-light);
  background-color: var(--dark-bg); /* Fallback */
  overflow-x: hidden;
  line-height: 1.6;
}

/* --- 3D Canvas Background --- */
#bg-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none; /* Let clicks pass through to content */
}

/* --- Utility Classes --- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

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

.section-title {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  color: var(--primary-gold);
  margin-bottom: 30px;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.section-subtitle {
  font-weight: 300;
  color: var(--text-muted);
  letter-spacing: 3px;
  text-transform: uppercase;
  font-size: 1rem;
  margin-bottom: 5px;
}

/* --- Glassmorphism Base --- */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: 16px;
  /* Preserve 3D is important for child elements animating smoothly inside a tilted card */
  transform-style: preserve-3d;
}

/* --- Header & Nav --- */
.glass-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(10, 10, 15, 0.7);
  backdrop-filter: blur(15px);
  border-bottom: 1px solid var(--glass-border);
  padding: 15px 0;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-img {
  height: 50px;
  width: auto;
  filter: drop-shadow(0px 0px 5px rgba(226, 192, 116, 0.3));
}

.main-nav ul {
  display: flex;
  gap: 30px;
  list-style: none;
}

.main-nav a {
  text-decoration: none;
  color: var(--text-light);
  font-weight: 400;
  font-size: 1.05rem;
  transition: color 0.3s ease;
  position: relative;
}

.main-nav a:hover, .main-nav a.active {
  color: var(--primary-gold);
}

.main-nav a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -5px;
  left: 0;
  background-color: var(--primary-gold);
  transition: width 0.3s ease;
}

.main-nav a:hover::after, .main-nav a.active::after {
  width: 100%;
}

.menu-toggle {
  display: none;
  font-size: 1.8rem;
  color: var(--primary-gold);
  cursor: pointer;
}

/* --- Hero Section --- */
.hero-section {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 20px;
}

.hero-content {
  max-width: 800px;
  padding: 60px 40px;
  text-align: center;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: 3.5rem;
  color: var(--primary-gold);
  margin-bottom: 20px;
  line-height: 1.2;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-bottom: 40px;
  font-weight: 300;
}

.primary-btn {
  display: inline-block;
  padding: 15px 35px;
  border-radius: 30px;
  background: linear-gradient(135deg, var(--primary-gold), var(--secondary-gold));
  color: #111;
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: 1px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 15px rgba(226, 192, 116, 0.4);
}

.primary-btn:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 25px rgba(226, 192, 116, 0.6);
}

/* --- About Section --- */
.about-section {
  padding: 100px 20px;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-grid .text-content {
  padding: 40px;
}

.about-grid p {
  margin-bottom: 20px;
  font-size: 1.1rem;
  color: var(--text-muted);
}

.about-grid .image-content {
  padding: 15px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.about-grid img {
  width: 100%;
  border-radius: 10px;
  object-fit: cover;
}

/* --- Zodiac Section (Marquee Animation) --- */
.zodiac-section {
  padding: 80px 0;
  overflow: hidden;
}

.zodiac-marquee-container {
  display: flex;
  overflow: hidden;
  user-select: none;
  gap: 30px;
  padding: 20px 0;
  mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.zodiac-marquee {
  display: flex;
  flex-shrink: 0;
  gap: 30px;
  animation: marquee-scroll 40s linear infinite;
}

.zodiac-marquee:hover {
  animation-play-state: paused;
}

@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(calc(-100% - 30px)); }
}

.zodiac-card {
  flex: 0 0 160px;
  padding: 25px 15px;
  text-align: center;
  transition: transform 0.3s;
  cursor: pointer;
}

.card-img-wrapper {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 50%;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 15px;
  padding: 15px;
  /* Add 3D translation for elements inside tilted card */
  transform: translateZ(30px);
}

.zodiac-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.2));
}

.zodiac-card h3 {
  font-family: var(--font-heading);
  color: var(--primary-gold);
  font-size: 1.2rem;
  transform: translateZ(20px);
}

/* --- Services Section --- */
.services-section {
  padding: 80px 20px;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.service-card {
  overflow: hidden;
  cursor: pointer;
}

.service-img-wrapper {
  width: 100%;
  height: 200px;
  overflow: hidden;
  border-bottom: 1px solid var(--glass-border);
}

.service-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.service-card:hover .service-img-wrapper img {
  transform: scale(1.1);
}

.service-info {
  padding: 25px;
  transform: translateZ(20px); /* Pops out in 3D tilt */
  display: flex;
  flex-direction: column;
  height: calc(100% - 200px);
}

.service-info h3 {
  font-family: var(--font-heading);
  color: var(--primary-gold);
  font-size: 1.3rem;
  margin-bottom: 10px;
}

.service-info p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 20px;
  flex-grow: 1;
}

.book-btn {
  display: block;
  width: 100%;
  padding: 12px;
  text-align: center;
  background: transparent;
  border: 1px solid var(--primary-gold);
  color: var(--primary-gold);
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.3s ease;
  transform: translateZ(10px);
}

.book-btn:hover {
  background: var(--primary-gold);
  color: #111;
  box-shadow: 0 0 20px rgba(226, 192, 116, 0.3);
}

/* --- Counters Section --- */
.counter-section {
  padding: 60px 20px 100px;
}

.counter-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.counter-card {
  padding: 40px 20px;
  text-align: center;
}

.counter-card h1 {
  font-family: var(--font-heading);
  font-size: 3.5rem;
  color: var(--primary-gold);
  margin-bottom: 10px;
  transform: translateZ(30px);
}

.counter-card p {
  font-size: 1.1rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 2px;
  transform: translateZ(20px);
}

/* --- Footer --- */
.glass-footer {
  background: rgba(10, 10, 15, 0.8);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--glass-border);
  padding: 60px 0 20px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-column h3 {
  font-family: var(--font-heading);
  color: var(--primary-gold);
  font-size: 1.3rem;
  margin-bottom: 20px;
}

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

.footer-column ul li {
  margin-bottom: 12px;
}

.footer-column ul li a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.3s;
}

.footer-column ul li a:hover {
  color: var(--primary-gold);
}

.social-links {
  display: flex;
  gap: 15px;
}

.glass-icon {
  width: 45px;
  height: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  color: var(--text-light);
  font-size: 1.2rem;
  text-decoration: none;
  transition: all 0.3s ease;
}

.glass-icon:hover {
  background: var(--primary-gold);
  color: #111;
  transform: translateY(-5px);
}

.footer-bottom {
  text-align: center;
  color: #777;
  font-size: 0.9rem;
  border-top: 1px solid rgba(255,255,255,0.05);
  padding-top: 20px;
}

/* --- Glassmorphism Auth Modal --- */
.auth-modal-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  background: rgba(5, 5, 10, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.auth-modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.auth-modal {
  width: 100%;
  max-width: 450px;
  padding: 40px;
  transform: translateY(30px);
  transition: transform 0.4s ease;
}

.auth-modal-overlay.active .auth-modal {
  transform: translateY(0);
}

.auth-header {
  text-align: center;
  margin-bottom: 30px;
}

.auth-header h2 {
  font-family: var(--font-heading);
  color: var(--primary-gold);
  font-size: 2rem;
  margin-bottom: 5px;
}

.auth-header p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.auth-form-group {
  margin-bottom: 20px;
  position: relative;
}

.auth-form-group label {
  display: block;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.auth-input {
  width: 100%;
  padding: 14px 15px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  color: var(--text-light);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: all 0.3s ease;
  outline: none;
}

.auth-input:focus {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--primary-gold);
  box-shadow: 0 0 10px rgba(226, 192, 116, 0.2);
}

.auth-btn {
  width: 100%;
  padding: 15px;
  margin-top: 10px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--primary-gold), var(--secondary-gold));
  color: #111;
  border: none;
  font-weight: 600;
  font-size: 1.1rem;
  font-family: var(--font-body);
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.auth-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(226, 192, 116, 0.4);
}

.auth-footer {
  text-align: center;
  margin-top: 25px;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.auth-footer a {
  color: var(--primary-gold);
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
}

.auth-footer a:hover {
  text-decoration: underline;
}

.auth-close {
  position: absolute;
  top: 15px;
  right: 20px;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  transition: color 0.3s;
}

.auth-close:hover {
  color: var(--primary-gold);
}

.login-btn-nav {
  margin-left: 15px;
  padding: 8px 20px !important;
  border: 1px solid var(--primary-gold);
  border-radius: 20px;
  color: var(--primary-gold) !important;
  cursor: pointer;
}
.login-btn-nav:hover {
  background: var(--primary-gold);
  color: #111 !important;
}
.login-btn-nav::after {
    display: none;
}

/* User Profile Nav Item */
.user-profile-nav {
  display: flex !important;
  align-items: center;
  gap: 10px;
  color: var(--text-light) !important;
  font-weight: 500;
  cursor: pointer;
  margin-left: 15px;
  background: rgba(255,255,255,0.05);
  padding: 8px 20px !important;
  border-radius: 20px;
  border: 1px solid rgba(226, 192, 116, 0.3);
}
.user-profile-nav i {
  color: var(--primary-gold);
}
.user-profile-nav::after {
    display: none;
}
.user-profile-nav:hover {
    border-color: var(--primary-gold);
}

/* Error message styling */
.auth-error {
  color: #ff5e5e;
  font-size: 0.85rem;
  margin-top: 5px;
  display: none;
}


/* --- Responsive Design --- */
@media (max-width: 992px) {
  .about-grid {
    grid-template-columns: 1fr;
  }
  .counter-grid {
    grid-template-columns: 1fr;
  }
  .hero-title {
    font-size: 2.8rem;
  }
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }
  
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: rgba(15, 15, 20, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
    transition: clip-path 0.4s ease-out;
  }
  
  .main-nav.active {
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
  }
  
  .main-nav ul {
    flex-direction: column;
    padding: 30px;
    align-items: center;
    gap: 20px;
  }
  
  .hero-title {
    font-size: 2.2rem;
  }
  
  .hero-content {
    padding: 40px 20px;
  }
}