/*
Theme Name: AstroShala
Theme URI: https://astroshala.lovable.app
Author: Somnath Banga
Author URI: https://astroshala.lovable.app
Description: Premium Astrology & Vastu consultation theme with dark royal aesthetic. Optimized for WooCommerce and Tutor LMS.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: astroshala
Tags: dark, one-column, custom-menu, featured-images, theme-options, e-commerce, education
*/

/* ============================================
   ASTROSHALA DESIGN SYSTEM
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700&family=DM+Sans:wght@300;400;500;600;700&display=swap');

:root {
  /* Primary Colors */
  --as-gold: #C9A84C;
  --as-gold-light: #D4BC6B;
  --as-gold-dark: #A88A3C;
  --as-bg: #0E1219;
  --as-bg-card: #141C2B;
  --as-bg-secondary: #132242;
  --as-bg-muted: #1A2538;
  --as-text: #F5F2EC;
  --as-text-muted: #7E8A9E;
  --as-border: #544A2E;
  --as-border-subtle: rgba(201, 168, 76, 0.15);
  --as-sacred-red: #7A3333;

  /* Gradients */
  --as-gradient-gold: linear-gradient(135deg, #D4BC6B, #C9A84C, #A88A3C);
  --as-gradient-bg: linear-gradient(180deg, #0E1219, #0A0E14);
  --as-gradient-card: linear-gradient(145deg, #182030, #101828);

  /* Shadows */
  --as-shadow-gold: 0 4px 30px rgba(201, 168, 76, 0.15);
  --as-shadow-card: 0 8px 32px rgba(10, 14, 20, 0.3);
  --as-shadow-elevated: 0 20px 60px rgba(10, 14, 20, 0.5);

  /* Spacing */
  --as-radius: 0.5rem;
  --as-radius-lg: 0.75rem;
  --as-radius-xl: 1rem;

  /* Typography */
  --as-font-heading: 'Playfair Display', Georgia, serif;
  --as-font-body: 'DM Sans', system-ui, sans-serif;
}


/* ============================================
   GLOBAL RESET & BASE
   ============================================ */

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden !important;
  width: 100%;
  max-width: 100vw;
}

body {
  font-family: var(--as-font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  color: var(--as-text);
  background-color: var(--as-bg);
  overflow-x: hidden !important;
  width: 100%;
  max-width: 100vw;
  position: relative;
}

/* Add bottom padding on mobile/tablet for sticky nav */
@media (max-width: 1023px) {
  body {
    padding-bottom: 70px;
  }
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--as-font-heading);
  font-weight: 600;
  line-height: 1.2;
  color: var(--as-text);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.125rem; }
h6 { font-size: 1rem; }

@media (min-width: 768px) {
  h1 { font-size: 3.5rem; }
  h2 { font-size: 2.5rem; }
  h3 { font-size: 1.75rem; }
}

a {
  color: var(--as-gold);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--as-gold-light);
}

img {
  max-width: 100%;
  height: auto;
}

::selection {
  background-color: rgba(201, 168, 76, 0.3);
  color: var(--as-text);
}

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--as-bg);
}

::-webkit-scrollbar-thumb {
  background: rgba(201, 168, 76, 0.3);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--as-gold);
}


/* ============================================
   LAYOUT
   ============================================ */

.as-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 1024px) {
  .as-container {
    padding: 0 2rem;
  }
}

.as-section {
  padding: 4rem 0;
}

@media (min-width: 768px) {
  .as-section {
    padding: 6rem 0;
  }
}


/* ============================================
   BUTTONS
   ============================================ */

.as-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--as-radius);
  font-family: var(--as-font-body);
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  text-decoration: none;
  line-height: 1;
}

.as-btn-gold {
  background: var(--as-gradient-gold);
  color: #0E1219;
  box-shadow: var(--as-shadow-gold);
}

.as-btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 40px rgba(201, 168, 76, 0.25);
  color: #0E1219;
}

.as-btn-gold-outline {
  background: transparent;
  color: var(--as-gold);
  border: 1.5px solid var(--as-gold);
}

.as-btn-gold-outline:hover {
  background: rgba(201, 168, 76, 0.1);
  color: var(--as-gold-light);
}

.as-btn-lg {
  padding: 1rem 2rem;
  font-size: 1rem;
}


/* ============================================
   CARDS
   ============================================ */

.as-card {
  background: var(--as-gradient-card);
  border: 1px solid var(--as-border-subtle);
  border-radius: var(--as-radius-lg);
  padding: 1.5rem;
  transition: all 0.3s ease;
}

.as-card:hover {
  border-color: rgba(201, 168, 76, 0.3);
  box-shadow: var(--as-shadow-card);
  transform: translateY(-2px);
}


/* ============================================
   FORMS (Global + WooCommerce)
   ============================================ */

input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="url"],
input[type="tel"],
input[type="number"],
input[type="date"],
textarea,
select {
  font-family: var(--as-font-body);
  font-size: 0.875rem;
  color: var(--as-text);
  background-color: var(--as-bg-muted);
  border: 1px solid var(--as-border-subtle);
  border-radius: var(--as-radius);
  padding: 0.75rem 1rem;
  width: 100%;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
  outline: none;
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--as-gold);
  box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.15);
}

label {
  font-family: var(--as-font-body);
  font-weight: 500;
  font-size: 0.875rem;
  color: var(--as-text);
  display: block;
  margin-bottom: 0.5rem;
}

input[type="submit"],
button[type="submit"] {
  background: var(--as-gradient-gold);
  color: #0E1219;
  font-family: var(--as-font-body);
  font-weight: 600;
  font-size: 0.875rem;
  border: none;
  border-radius: var(--as-radius);
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

input[type="submit"]:hover,
button[type="submit"]:hover {
  transform: translateY(-2px);
  box-shadow: var(--as-shadow-gold);
}


/* ============================================
   TABLES
   ============================================ */

table {
  width: 100%;
  border-collapse: collapse;
}

table th {
  font-family: var(--as-font-heading);
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--as-gold);
  text-align: left;
  padding: 1rem;
  background: var(--as-bg-muted);
  border-bottom: 1px solid var(--as-border-subtle);
}

table td {
  padding: 1rem;
  border-bottom: 1px solid rgba(201, 168, 76, 0.08);
  color: var(--as-text-muted);
  font-size: 0.875rem;
}

table tr:hover td {
  background: rgba(201, 168, 76, 0.03);
}


/* ============================================
   PAGINATION
   ============================================ */

.pagination,
.woocommerce-pagination,
nav.navigation .nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 2rem;
}

.pagination a,
.pagination span,
.woocommerce-pagination a,
.woocommerce-pagination span,
.nav-links a,
.nav-links span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  height: 2.5rem;
  padding: 0 0.75rem;
  border-radius: var(--as-radius);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--as-text-muted);
  background: var(--as-bg-card);
  border: 1px solid var(--as-border-subtle);
  transition: all 0.3s ease;
  text-decoration: none;
}

.pagination a:hover,
.woocommerce-pagination a:hover,
.nav-links a:hover {
  color: var(--as-gold);
  border-color: var(--as-gold);
  background: rgba(201, 168, 76, 0.1);
}

.pagination .current,
.woocommerce-pagination .current,
.nav-links .current {
  background: var(--as-gradient-gold);
  color: #0E1219;
  border-color: transparent;
  font-weight: 600;
}


/* ============================================
   BREADCRUMBS
   ============================================ */

.woocommerce-breadcrumb,
.breadcrumbs,
.tutor-breadcrumb {
  font-size: 0.8125rem;
  color: var(--as-text-muted);
  padding: 1rem 0;
  margin-bottom: 1rem;
}

.woocommerce-breadcrumb a,
.breadcrumbs a,
.tutor-breadcrumb a {
  color: var(--as-gold);
}

.woocommerce-breadcrumb a:hover,
.breadcrumbs a:hover,
.tutor-breadcrumb a:hover {
  color: var(--as-gold-light);
}


/* ============================================
   BADGES & TAGS
   ============================================ */

.as-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.75rem;
  background: rgba(201, 168, 76, 0.1);
  border: 1px solid rgba(201, 168, 76, 0.2);
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--as-gold);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}


/* ============================================
   NOTICES & ALERTS
   ============================================ */

.woocommerce-message,
.woocommerce-info,
.tutor-alert-info {
  background: rgba(201, 168, 76, 0.08);
  border: 1px solid rgba(201, 168, 76, 0.2);
  border-left: 4px solid var(--as-gold);
  color: var(--as-text);
  padding: 1rem 1.5rem;
  border-radius: var(--as-radius);
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
}

.woocommerce-message a,
.woocommerce-info a {
  color: var(--as-gold);
  font-weight: 600;
}

.woocommerce-error,
.tutor-alert-danger {
  background: rgba(122, 51, 51, 0.15);
  border: 1px solid rgba(122, 51, 51, 0.3);
  border-left: 4px solid var(--as-sacred-red);
  color: var(--as-text);
  padding: 1rem 1.5rem;
  border-radius: var(--as-radius);
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
}

.woocommerce-error li {
  list-style: none;
}


/* ============================================
   WORDPRESS DEFAULTS
   ============================================ */

.wp-block-image img {
  border-radius: var(--as-radius);
}

.wp-block-quote {
  border-left: 4px solid var(--as-gold);
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
  background: rgba(201, 168, 76, 0.05);
  border-radius: 0 var(--as-radius) var(--as-radius) 0;
}

.wp-block-quote p {
  font-family: var(--as-font-heading);
  font-style: italic;
  color: var(--as-text);
  font-size: 1.125rem;
}

.wp-block-quote cite {
  color: var(--as-gold);
  font-size: 0.875rem;
  font-style: normal;
}

.entry-content p {
  margin-bottom: 1.25rem;
  color: var(--as-text-muted);
  line-height: 1.7;
}

.entry-content ul,
.entry-content ol {
  margin-bottom: 1.25rem;
  padding-left: 1.5rem;
  color: var(--as-text-muted);
}

.entry-content li {
  margin-bottom: 0.5rem;
}


/* ============================================
   UTILITY CLASSES
   ============================================ */

.as-gold-text {
  color: var(--as-gold);
}

.as-gold-gradient-text {
  background: var(--as-gradient-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.as-text-muted {
  color: var(--as-text-muted);
}

.as-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}


/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes as-fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

@keyframes as-shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.as-animate-fade-in {
  animation: as-fadeIn 0.6s ease-out forwards;
}

.as-animate-fade-in-up {
  animation: as-fadeInUp 0.6s ease-out forwards;
}
