/* ============================================
   MAMA JAFALI - DARK MYSTICAL THEME
   Static styles extracted from inline layout
   ============================================ */

body {
    font-family: var(--font-secondary);
    background-color: var(--color-body);
    color: var(--color-moonlight);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
}

/* Color utilities */
.bg-primary { background-color: var(--color-primary); }
.bg-secondary { background-color: var(--color-secondary); }
.bg-accent { background-color: var(--color-accent); }
.bg-dark { background-color: var(--color-dark); }
.bg-black { background-color: var(--color-black); }
.bg-offwhite { background-color: var(--color-body); }
.bg-cream { background-color: var(--color-surface); }
.bg-surface { background-color: var(--color-surface); }
.bg-surface-light { background-color: var(--color-surface-light); }

.text-primary { color: var(--color-primary); }
.text-secondary { color: var(--color-moonlight); }
.text-accent { color: var(--color-accent); }
.text-dark { color: var(--color-dark); }
.text-charcoal { color: var(--color-moonlight); }
.text-moonlight { color: var(--color-moonlight); }

.border-primary { border-color: var(--color-primary); }
.border-secondary { border-color: var(--color-secondary); }

/* Hover states */
.hover\:bg-primary:hover { background-color: var(--color-primary); }
.hover\:text-primary:hover { color: var(--color-primary); }
.hover\:border-primary:hover { border-color: var(--color-primary); }

/* Mystical gradient for special elements */
.gradient-gold,
.gradient-mystical {
    background: linear-gradient(135deg, var(--color-primary) 0%, #A78BFA 50%, var(--color-primary-dark) 100%);
}

/* ============================================
   DARK MYSTICAL - WITCHCRAFT DESIGN SYSTEM
   ============================================ */

/* Dark Card */
.glass-card {
    background: var(--color-surface);
    border: 1px solid rgba(139, 92, 246, 0.15);
    border-radius: 1.25rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3), 0 0 40px rgba(139, 92, 246, 0.05);
    transition: all 0.3s ease;
}

.glass-card:hover {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4), 0 0 60px rgba(139, 92, 246, 0.1);
    border-color: rgba(139, 92, 246, 0.3);
}

.glass-card-cream {
    background: var(--color-surface-light);
    border: 1px solid rgba(139, 92, 246, 0.1);
    border-radius: 1.25rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

/* Parallax Background */
.parallax-bg {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

@media (max-width: 768px) {
    .parallax-bg {
        background-attachment: scroll;
    }
}

/* Section with subtle background */
.section-hero-bg {
    position: relative;
    overflow: hidden;
    background: var(--color-body);
}

.section-hero-bg > * {
    position: relative;
    z-index: 2;
}

/* Overlay Variants - Dark theme */
.overlay-light {
    background: linear-gradient(180deg,
        rgba(8, 5, 16, 0.95) 0%,
        rgba(17, 13, 31, 0.9) 100%);
}

.overlay-warm {
    background: linear-gradient(180deg,
        rgba(15, 10, 26, 0.85) 0%,
        rgba(8, 5, 16, 0.95) 100%);
}

.overlay-gold-light {
    background: linear-gradient(135deg,
        rgba(139, 92, 246, 0.05) 0%,
        rgba(17, 13, 31, 0.4) 50%,
        rgba(16, 185, 129, 0.03) 100%);
}

/* Button styles */
.btn-primary {
    background: linear-gradient(135deg, var(--color-primary) 0%, #A78BFA 100%);
    color: #FFFFFF;
    padding: 1rem 2.5rem;
    border-radius: 0.75rem;
    font-weight: 700;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.btn-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #A78BFA 0%, var(--color-primary) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.4), 0 0 30px rgba(139, 92, 246, 0.2);
}

.btn-primary:hover::before {
    opacity: 1;
}

.btn-primary span {
    position: relative;
    z-index: 1;
}

.btn-primary i {
    position: relative;
    z-index: 1;
}

.btn-outline {
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
    padding: 1rem 2.5rem;
    border-radius: 0.75rem;
    font-weight: 700;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: transparent;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-outline:hover {
    background: var(--color-primary);
    color: #FFFFFF;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.3);
}

/* Accent button (Emerald) */
.btn-accent {
    background: var(--color-accent);
    color: #FFFFFF;
    padding: 1rem 2.5rem;
    border-radius: 0.75rem;
    font-weight: 700;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
}

.btn-accent:hover {
    background: var(--color-accent-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.3);
}

/* Card styles - Dark theme */
.card {
    background: var(--color-surface);
    border: 1px solid rgba(139, 92, 246, 0.1);
    border-radius: 1.25rem;
    padding: 2rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, var(--color-primary), var(--color-primary-light));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.card:hover {
    border-color: rgba(139, 92, 246, 0.25);
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4), 0 0 40px rgba(139, 92, 246, 0.08);
}

.card:hover::before {
    opacity: 1;
}

/* Card with top border accent */
.card-top-accent {
    border-top: 3px solid var(--color-primary);
}

/* Card with left border accent */
.card-left-accent::before {
    opacity: 1;
}

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

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

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

@keyframes fadeInLeft {
    from { opacity: 0; transform: translateX(-40px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes fadeInRight {
    from { opacity: 0; transform: translateX(40px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(2deg); }
}

@keyframes floatSlow {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes floatDeep {
    0%, 100% { transform: translateY(0) translateX(0); }
    25% { transform: translateY(-15px) translateX(5px); }
    50% { transform: translateY(-25px) translateX(0); }
    75% { transform: translateY(-15px) translateX(-5px); }
}

@keyframes glow {
    0%, 100% { box-shadow: 0 0 20px rgba(139, 92, 246, 0.3); }
    50% { box-shadow: 0 0 50px rgba(139, 92, 246, 0.6); }
}

@keyframes glowPulse {
    0%, 100% { box-shadow: 0 0 20px rgba(139, 92, 246, 0.3), 0 0 40px rgba(139, 92, 246, 0.1); }
    50% { box-shadow: 0 0 40px rgba(139, 92, 246, 0.5), 0 0 80px rgba(139, 92, 246, 0.2); }
}

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

@keyframes lightRay {
    0% { opacity: 0.2; transform: rotate(15deg) translateX(-100%) scaleY(1); }
    50% { opacity: 0.5; }
    100% { opacity: 0.2; transform: rotate(15deg) translateX(100vw) scaleY(1); }
}

@keyframes lightRaySlow {
    0% { opacity: 0.1; transform: rotate(-10deg) translateX(-50%); }
    100% { opacity: 0.3; transform: rotate(-10deg) translateX(150vw); }
}

@keyframes twinkle {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.2); }
}

@keyframes shootingStar {
    0% { transform: translateX(0) translateY(0); opacity: 1; }
    70% { opacity: 1; }
    100% { transform: translateX(300px) translateY(300px); opacity: 0; }
}

@keyframes ripple {
    0% { transform: scale(1); opacity: 0.4; }
    100% { transform: scale(2); opacity: 0; }
}

@keyframes pulseRing {
    0% { transform: scale(0.8); opacity: 0.8; }
    100% { transform: scale(1.5); opacity: 0; }
}

@keyframes revealChar {
    from { opacity: 0; transform: translateY(20px) rotateX(-90deg); }
    to { opacity: 1; transform: translateY(0) rotateX(0); }
}

@keyframes iconGlow {
    0%, 100% { filter: drop-shadow(0 0 5px rgba(139, 92, 246, 0.5)); }
    50% { filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.8)); }
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes breathe {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Witchcraft-specific animations */
@keyframes candleFlicker {
    0%, 100% { opacity: 1; filter: brightness(1); }
    25% { opacity: 0.85; filter: brightness(0.9); }
    50% { opacity: 0.95; filter: brightness(1.1); }
    75% { opacity: 0.8; filter: brightness(0.85); }
}

@keyframes smokeRise {
    0% { transform: translateY(0) translateX(0) scale(1); opacity: 0.3; }
    50% { transform: translateY(-40px) translateX(10px) scale(1.3); opacity: 0.15; }
    100% { transform: translateY(-80px) translateX(-5px) scale(1.5); opacity: 0; }
}

@keyframes moonGlow {
    0%, 100% { box-shadow: 0 0 30px rgba(192, 192, 208, 0.2), 0 0 60px rgba(139, 92, 246, 0.1); }
    50% { box-shadow: 0 0 50px rgba(192, 192, 208, 0.4), 0 0 100px rgba(139, 92, 246, 0.2); }
}

@keyframes starTwinkle {
    0%, 100% { opacity: 0.2; transform: scale(0.8); }
    50% { opacity: 1; transform: scale(1.2); }
}

@keyframes mysticPulse {
    0%, 100% { box-shadow: 0 0 20px rgba(139, 92, 246, 0.3); }
    50% { box-shadow: 0 0 40px rgba(139, 92, 246, 0.6), 0 0 80px rgba(139, 92, 246, 0.2); }
}

/* Animation Classes */
.animate-fade-in-up { animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards; opacity: 0; }
.animate-fade-in { animation: fadeIn 0.6s ease forwards; opacity: 0; }
.animate-fade-in-left { animation: fadeInLeft 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards; opacity: 0; }
.animate-fade-in-right { animation: fadeInRight 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards; opacity: 0; }
.animate-scale-in { animation: scaleIn 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards; opacity: 0; }
.animate-float { animation: float 6s ease-in-out infinite; }
.animate-float-slow { animation: floatSlow 8s ease-in-out infinite; }
.animate-float-deep { animation: floatDeep 10s ease-in-out infinite; }
.animate-glow { animation: glow 3s ease-in-out infinite; }
.animate-glow-pulse { animation: glowPulse 4s ease-in-out infinite; }
.animate-twinkle { animation: twinkle 3s ease-in-out infinite; }
.animate-icon-glow { animation: iconGlow 3s ease-in-out infinite; }
.animate-breathe { animation: breathe 4s ease-in-out infinite; }
.animate-candle-flicker { animation: candleFlicker 3s ease-in-out infinite; }
.animate-smoke-rise { animation: smokeRise 6s ease-in-out infinite; }
.animate-moon-glow { animation: moonGlow 4s ease-in-out infinite; }
.animate-star-twinkle { animation: starTwinkle 3s ease-in-out infinite; }
.animate-mystic-pulse { animation: mysticPulse 3s ease-in-out infinite; }

/* Staggered animation delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }
.delay-600 { animation-delay: 0.6s; }
.delay-700 { animation-delay: 0.7s; }
.delay-800 { animation-delay: 0.8s; }
.delay-900 { animation-delay: 0.9s; }
.delay-1000 { animation-delay: 1s; }
.delay-1200 { animation-delay: 1.2s; }
.delay-1500 { animation-delay: 1.5s; }

/* Mystical Light Ray Effect */
.light-rays {
    position: relative;
    overflow: hidden;
}

.light-rays::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(139, 92, 246, 0.03) 45%,
        rgba(139, 92, 246, 0.08) 50%,
        rgba(139, 92, 246, 0.03) 55%,
        transparent 100%
    );
    animation: lightRay 12s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

/* Decorative particles */
.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--color-primary);
    border-radius: 50%;
    opacity: 0.6;
    animation: floatDeep 8s ease-in-out infinite;
}

.particle-sm { width: 2px; height: 2px; }
.particle-lg { width: 6px; height: 6px; }

/* Section backgrounds - Dark theme */
.section-offwhite { background: var(--color-body); }
.section-cream { background: var(--color-surface); }
.section-white { background: var(--color-surface-light); }
.section-gradient { background: linear-gradient(180deg, var(--color-body) 0%, var(--color-surface) 100%); }
.section-gradient-reverse { background: linear-gradient(180deg, var(--color-surface) 0%, var(--color-body) 100%); }
.section-dark { background: var(--color-dark); }

/* Text gradient - Mystical */
.text-gradient {
    background: linear-gradient(135deg, var(--color-primary) 0%, #A78BFA 50%, var(--color-primary) 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 6s ease infinite;
}

.text-gradient-static {
    background: linear-gradient(135deg, var(--color-primary) 0%, #A78BFA 50%, var(--color-primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Text shadow for readability */
.text-shadow { text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5), 0 4px 20px rgba(0, 0, 0, 0.3); }
.text-shadow-lg { text-shadow: 0 4px 20px rgba(0, 0, 0, 0.6), 0 8px 40px rgba(0, 0, 0, 0.4); }

/* Star rating */
.star-rating {
    color: var(--color-primary);
    filter: drop-shadow(0 0 3px rgba(139, 92, 246, 0.5));
}

/* Quote styling */
.quote-mark {
    font-size: 6rem;
    line-height: 1;
    color: var(--color-primary);
    opacity: 0.2;
    font-family: Georgia, serif;
    position: absolute;
    top: -1rem;
    left: -0.5rem;
}

.quote-mark-lg { font-size: 10rem; opacity: 0.1; }

/* Mystical border accent */
.border-glow {
    position: relative;
}

.border-glow::after {
    content: '';
    position: absolute;
    inset: -2px;
    background: linear-gradient(135deg, var(--color-primary) 0%, transparent 50%, var(--color-primary) 100%);
    border-radius: inherit;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.border-glow:hover::after {
    opacity: 1;
}

/* Image frame effect */
.img-frame {
    position: relative;
    padding: 8px;
    background: linear-gradient(135deg, var(--color-primary) 0%, rgba(139, 92, 246, 0.3) 50%, var(--color-primary) 100%);
    border-radius: 1rem;
}

.img-frame img { border-radius: 0.75rem; }

/* Form inputs - Dark theme */
.form-input {
    background: var(--color-surface-light);
    border: 1px solid rgba(139, 92, 246, 0.15);
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
    color: var(--color-moonlight);
    width: 100%;
    transition: all 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
    background: var(--color-surface);
}

.form-input::placeholder {
    color: rgba(192, 192, 208, 0.4);
}

/* Mobile menu - Dark theme */
.mobile-menu-overlay {
    background: rgba(8, 5, 16, 0.98);
    backdrop-filter: blur(20px);
}

/* Scroll indicator */
.scroll-indicator { animation: bounce 2.5s ease-in-out infinite; }

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-15px); }
    60% { transform: translateY(-7px); }
}

/* Link hover underline animation */
.link-underline { position: relative; }

.link-underline::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--color-primary), #A78BFA);
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.link-underline:hover::after { width: 100%; }

/* Wave Divider */
.wave-divider {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
}

.wave-divider svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 80px;
}

.wave-divider .shape-fill { fill: var(--color-body); }

/* Diagonal Divider */
.diagonal-divider {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background: linear-gradient(to bottom right, transparent 49.5%, var(--color-body) 50%);
}

/* Gradient border */
.gradient-border {
    position: relative;
    background: var(--color-surface);
}

.gradient-border::before {
    content: '';
    position: absolute;
    inset: 0;
    padding: 2px;
    background: linear-gradient(135deg, var(--color-primary) 0%, transparent 50%, var(--color-primary) 100%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    border-radius: inherit;
}

/* Icon container - Dark theme */
.icon-glow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 4rem;
    height: 4rem;
    border-radius: 1rem;
    background: rgba(139, 92, 246, 0.15);
    color: var(--color-primary);
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

.icon-glow:hover {
    background: rgba(139, 92, 246, 0.25);
    transform: translateY(-2px);
}

/* Icon circle variant */
.icon-circle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background: var(--color-primary);
    color: #FFFFFF;
    font-size: 1rem;
}

/* Badge styles - Dark theme */
.badge-gold,
.badge-mystical {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(139, 92, 246, 0.15);
    border: 1px solid rgba(139, 92, 246, 0.2);
    border-radius: 2rem;
    color: var(--color-primary-light);
    font-size: 0.875rem;
    font-weight: 600;
}

.badge-sage {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: 2rem;
    color: var(--color-accent);
    font-size: 0.875rem;
    font-weight: 600;
}

/* Prose overrides for dark mode */
.prose { color: var(--color-moonlight); }
.prose h1, .prose h2, .prose h3, .prose h4, .prose h5, .prose h6 { color: #E8E0F0; font-family: var(--font-primary); }
.prose a { color: var(--color-primary); }
.prose strong { color: #E8E0F0; }
.prose blockquote { border-left-color: var(--color-primary); color: rgba(192, 192, 208, 0.8); }
.prose code { color: var(--color-accent); background: var(--color-surface-light); }
.prose hr { border-color: rgba(139, 92, 246, 0.1); }
.prose ul li::marker { color: var(--color-primary); }
.prose ol li::marker { color: var(--color-primary); }

/* Line clamp utilities */
.line-clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-5 { display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; }

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .parallax-bg { background-attachment: scroll; }
}
