/* ==========================================================================
   ABS MATH (Assam Bangiya Saraswat Math) - Design System & Theme
   Aesthetic: Saffron Sanatan Dharma × Neumorphism × Spiritual Maximalism
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cinzel+Decorative:wght@700;900&family=Marcellus&family=Plus+Jakarta+Sans:wght@300;400;500;600;700&family=Rozha+One&display=swap');

:root {
  /* Saffron Sanatan Dharma Palette */
  --color-bhagwa-primary: #FF7722;
  --color-bhagwa-deep: #E65100;
  --color-bhagwa-glow: rgba(255, 119, 34, 0.45);
  
  --color-ochre-gold: #FFB300;
  --color-haldi-gold: #D4AF37;
  --color-gold-light: #FFE082;
  --color-gold-dark: #B8860B;
  
  --color-sandstone-light: #FAF6EE;
  --color-sandstone-base: #F5EFEB;
  --color-sandstone-shadow: #E2D9CC;
  --color-sandstone-white: #FFFFFF;
  
  --color-kumkum-red: #B71C1C;
  --color-kumkum-glow: rgba(183, 28, 28, 0.4);
  --color-basil-green: #2E7D32;
  
  --color-text-dark: #2C1810;
  --color-text-muted: #6D5648;
  --color-deep-night: #1A0D08;
  
  /* Neumorphic Dual-Elevation Shadows */
  --neu-flat: 8px 8px 18px var(--color-sandstone-shadow), -8px -8px 18px var(--color-sandstone-white);
  --neu-lifted: 12px 12px 24px var(--color-sandstone-shadow), -12px -12px 24px var(--color-sandstone-white);
  --neu-soft: 5px 5px 12px var(--color-sandstone-shadow), -5px -5px 12px var(--color-sandstone-white);
  --neu-pressed: inset 4px 4px 8px var(--color-sandstone-shadow), inset -4px -4px 8px var(--color-sandstone-white);
  --neu-pressed-deep: inset 6px 6px 12px var(--color-sandstone-shadow), inset -6px -6px 12px var(--color-sandstone-white);
  
  /* Gold Foil Gradients */
  --grad-gold-foil: linear-gradient(135deg, #FFE082 0%, #D4AF37 50%, #FFB300 100%);
  --grad-bhagwa: linear-gradient(135deg, #FF7722 0%, #E65100 100%);
  --grad-bhagwa-glow: linear-gradient(135deg, #FF8F00 0%, #FF5722 100%);
  --grad-dark-temple: linear-gradient(180deg, #2C1810 0%, #1A0D08 100%);
  
  /* Fonts */
  --font-display: 'Cinzel Decorative', serif;
  --font-heading: 'Rozha One', serif;
  --font-accent: 'Marcellus', serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--color-sandstone-base);
  color: var(--color-text-dark);
  overflow-x: hidden;
  width: 100%;
}

body {
  font-family: var(--font-body);
  line-height: 1.65;
  background-color: var(--color-sandstone-base);
  color: var(--color-text-dark);
  overflow-x: hidden;
  width: 100%;
}

/* Notice Ticker Animation */
.notice-ticker-wrapper {
  background: var(--grad-dark-temple);
  color: #FFE082;
  font-family: var(--font-body);
  font-size: 0.75rem;
  overflow: hidden;
  white-space: nowrap;
  padding: 6px 0;
  border-bottom: 1px solid rgba(212, 175, 55, 0.4);
  width: 100%;
  position: relative;
  z-index: 40;
}
.notice-ticker-content {
  display: inline-block;
  white-space: nowrap;
  padding-left: 100%;
  animation: noticeTickerScroll 35s linear infinite;
}
.notice-ticker-content:hover {
  animation-play-state: paused;
}
@keyframes noticeTickerScroll {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-100%, 0, 0); }
}

/* Custom Saffron Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--color-sandstone-base);
}
::-webkit-scrollbar-thumb {
  background: var(--grad-bhagwa);
  border-radius: 5px;
  border: 2px solid var(--color-sandstone-base);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-bhagwa-deep);
}

/* Selection */
::selection {
  background-color: var(--color-bhagwa-primary);
  color: #ffffff;
}

/* Typography Classes */
.font-display { font-family: var(--font-display); }
.font-heading { font-family: var(--font-heading); }
.font-accent { font-family: var(--font-accent); }
.font-body { font-family: var(--font-body); }

/* Spiritual Maximalism Backgrounds & Textures */
.bg-parchment {
  background-color: var(--color-sandstone-base);
  background-image: 
    radial-gradient(#E2D9CC 0.75px, transparent 0.75px),
    radial-gradient(#FAF6EE 0.75px, var(--color-sandstone-base) 0.75px);
  background-size: 30px 30px;
  background-position: 0 0, 15px 15px;
}

.bg-temple-dark {
  background: var(--grad-dark-temple);
  color: #FAF6EE;
}

.mandala-watermark {
  position: relative;
  overflow: hidden;
}
.mandala-watermark::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 600px;
  height: 600px;
  transform: translate(-50%, -50%);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 500 500' fill='none' stroke='%23D4AF37' stroke-width='1.2' opacity='0.08'%3E%3Ccircle cx='250' cy='250' r='230'/%3E%3Ccircle cx='250' cy='250' r='180' stroke-dasharray='6,6'/%3E%3Ccircle cx='250' cy='250' r='120'/%3E%3Cpolygon points='250,30 430,370 70,370'/%3E%3Cpolygon points='250,470 70,130 430,130'/%3E%3Ccircle cx='250' cy='250' r='60'/%3E%3Cpolygon points='250,110 370,320 130,320'/%3E%3Cpolygon points='250,390 130,180 370,180'/%3E%3Ccircle cx='250' cy='250' r='20' fill='%23D4AF37' opacity='0.08'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  pointer-events: none;
  z-index: 0;
}

/* Neumorphic Components */
.neu-card {
  background: var(--color-sandstone-base);
  box-shadow: var(--neu-flat);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s ease;
  position: relative;
  z-index: 1;
}

.neu-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--neu-lifted);
  border-color: var(--color-haldi-gold);
}

.neu-card-recessed {
  background: var(--color-sandstone-base);
  box-shadow: var(--neu-pressed);
  border-radius: 16px;
  border: 1px solid rgba(226, 217, 204, 0.5);
}

.neu-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1;
  white-space: nowrap;
  vertical-align: middle;
  text-decoration: none;
  border-radius: 50px;
  background: var(--color-sandstone-base);
  color: var(--color-text-dark);
  box-shadow: var(--neu-flat);
  border: 1px solid rgba(255, 255, 255, 0.8);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.neu-btn:hover {
  box-shadow: var(--neu-lifted);
  transform: translateY(-2px);
  color: var(--color-bhagwa-deep);
}

.neu-btn:active {
  box-shadow: var(--neu-pressed);
  transform: translateY(1px);
}

.neu-btn-primary {
  background: var(--grad-bhagwa);
  color: #ffffff !important;
  box-shadow: 6px 6px 16px rgba(230, 81, 0, 0.35), -4px -4px 12px var(--color-sandstone-white);
  border: 1px solid rgba(255, 183, 77, 0.5);
}

.neu-btn-primary:hover {
  box-shadow: 8px 8px 20px rgba(230, 81, 0, 0.45), -4px -4px 12px var(--color-sandstone-white);
  transform: translateY(-2px);
  color: #ffffff !important;
}

.neu-btn-primary:active {
  box-shadow: inset 3px 3px 6px rgba(183, 28, 28, 0.4), inset -3px -3px 6px rgba(255, 183, 77, 0.3);
  transform: translateY(1px);
}

.neu-icon-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--color-sandstone-base);
  box-shadow: var(--neu-soft);
  border: 1px solid rgba(255, 255, 255, 0.8);
  cursor: pointer;
  color: var(--color-text-dark);
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.neu-icon-btn:hover {
  box-shadow: var(--neu-lifted);
  color: var(--color-bhagwa-primary);
  transform: scale(1.05);
}

.neu-icon-btn:active {
  box-shadow: var(--neu-pressed);
  transform: scale(0.95);
}

/* Golden Filigree & Dividers */
.gold-filigree-border {
  border: 2px solid transparent;
  background: linear-gradient(var(--color-sandstone-base), var(--color-sandstone-base)) padding-box,
              var(--grad-gold-foil) border-box;
}

.filigree-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin: 32px 0;
}

.filigree-divider::before,
.filigree-divider::after {
  content: '';
  height: 2px;
  flex: 1;
  max-width: 140px;
  background: linear-gradient(90deg, transparent, var(--color-haldi-gold), transparent);
}

/* Diya Flame Flicker Glow Animation */
@keyframes flameFlicker {
  0%, 100% {
    filter: drop-shadow(0 0 6px rgba(255, 119, 34, 0.8)) drop-shadow(0 0 14px rgba(255, 179, 0, 0.5));
    transform: scale(1);
  }
  50% {
    filter: drop-shadow(0 0 10px rgba(255, 119, 34, 1)) drop-shadow(0 0 20px rgba(255, 179, 0, 0.8));
    transform: scale(1.04);
  }
}

.diya-glow {
  animation: flameFlicker 2.5s ease-in-out infinite;
}

/* Shimmer Effect for Cards and Badges */
@keyframes goldShimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.shimmer-gold {
  background: linear-gradient(90deg, transparent, rgba(255, 224, 130, 0.4), transparent);
  background-size: 200% 100%;
  animation: goldShimmer 3s infinite linear;
}

/* Ticker Marquee */
.notice-ticker-wrapper {
  background: var(--color-kumkum-red);
  color: #FFF8E1;
  overflow: hidden;
  white-space: nowrap;
  font-size: 0.84rem;
  font-weight: 500;
  padding: 6px 0;
  border-bottom: 2px solid var(--color-haldi-gold);
}

.notice-ticker-content {
  display: inline-block;
  padding-left: 100%;
  animation: tickerScroll 35s linear infinite;
}

.notice-ticker-content:hover {
  animation-play-state: paused;
}

@keyframes tickerScroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-100%); }
}

/* Responsive Container Utility */
.ashram-container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 16px;
}

@media (min-width: 640px) {
  .ashram-container {
    padding: 0 24px;
  }
}

/* Copy Tooltip */
.copy-tooltip {
  position: relative;
}
.copy-tooltip::after {
  content: 'Copied to Clipboard!';
  position: absolute;
  bottom: 120%;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--color-basil-green);
  color: #ffffff;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
  pointer-events: none;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}
.copy-tooltip.active::after {
  opacity: 1;
  visibility: visible;
  bottom: 130%;
}

/* Mobile Slide-Over Drawer */
.mobile-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 85%;
  max-width: 320px;
  height: 100vh;
  background: var(--color-sandstone-base);
  box-shadow: -10px 0 30px rgba(44, 24, 16, 0.25);
  z-index: 9999;
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 24px;
  overflow-y: auto;
}
.mobile-drawer.open {
  right: 0;
}
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(44, 24, 16, 0.5);
  backdrop-filter: blur(4px);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
.drawer-backdrop.open {
  opacity: 1;
  visibility: visible;
}

/* Container Utility */
.ashram-container {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 16px;
  padding-right: 16px;
}
@media (min-width: 640px) {
  .ashram-container {
    padding-left: 24px;
    padding-right: 24px;
  }
}
@media (max-width: 480px) {
  .ashram-container {
    padding-left: 10px;
    padding-right: 10px;
  }
}

/* Mobile Typography & Layout Fine-tuning */
@media (max-width: 640px) {
  .neu-card {
    padding: 20px 16px !important;
    border-radius: 16px;
  }
  .neu-btn {
    padding: 8px 16px;
    font-size: 0.82rem;
  }
}
