/* Modern Moon Phase Tracker - Responsive CSS */

/* CSS Variables for consistent theming */
:root {
    /* Colors */
    --primary-color: #4f46e5;
    --secondary-color: #7c3aed;
    --accent-color: #f59e0b;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --text-light: #9ca3af;
    --background-primary: #0f172a;
    --background-secondary: #1e293b;
    --background-card: rgba(255, 255, 255, 0.95);
    --background-card-dark: rgba(30, 41, 59, 0.9);
    --moon-glow: #fbbf24;
    --moon-shadow: #374151;
    
    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;
    
    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    
    /* Border radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-full: 9999px;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-glow: 0 0 20px rgba(251, 191, 36, 0.3);
}

/* Global Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--text-primary);
    background: 
        linear-gradient(45deg, #0f172a 0%, #1e293b 25%, #0f172a 50%, #1e293b 75%, #0f172a 100%),
        radial-gradient(ellipse at center, rgba(79, 70, 229, 0.15) 0%, transparent 70%),
        linear-gradient(180deg, #0a0f1a 0%, #0f172a 50%, #1e293b 100%);
    background-size: 400% 400%, 100% 100%, 100% 100%;
    animation: cosmicBackground 20s ease infinite;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

@keyframes cosmicBackground {
    0%, 100% { background-position: 0% 50%, center, center; }
    50% { background-position: 100% 50%, center, center; }
}

/* Magical Cosmic Background */
.stars-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    background: 
        radial-gradient(ellipse at top, rgba(79, 70, 229, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at bottom, rgba(124, 58, 237, 0.1) 0%, transparent 50%);
}

/* Floating Cosmic Particles */
.cosmic-particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.8) 0%, transparent 70%);
    border-radius: 50%;
    animation: floatParticle 15s linear infinite;
}

@keyframes floatParticle {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100px) rotate(360deg);
        opacity: 0;
    }
}

/* Shooting Stars */
.shooting-star {
    position: fixed;
    top: 0;
    left: 0;
    width: 2px;
    height: 2px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 0 10px white;
    animation: shootingStar 3s linear infinite;
    z-index: 1;
}

@keyframes shootingStar {
    0% {
        transform: translateX(-100px) translateY(0);
        opacity: 0;
    }
    5% {
        opacity: 1;
    }
    95% {
        opacity: 1;
    }
    100% {
        transform: translateX(100vw) translateY(50vh);
        opacity: 0;
    }
}

/* Comet Effect */
.comet {
    position: absolute;
    left: -200px;
    width: 8px;
    height: 8px;
    background: linear-gradient(45deg, #fbbf24, #f59e0b, #d97706);
    border-radius: 50%;
    box-shadow: 
        0 0 20px #fbbf24,
        0 0 40px #f59e0b,
        0 0 60px #d97706;
    animation: cometTrail 6s linear infinite;
    z-index: 2;
}

.comet::before {
    content: '';
    position: absolute;
    top: 50%;
    left: -200px;
    width: 200px;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(251, 191, 36, 0.8), rgba(251, 191, 36, 0.4), transparent);
    transform: translateY(-50%);
    border-radius: 2px;
}

@keyframes cometTrail {
    0% {
        transform: translateX(-200px) translateY(0) rotate(45deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateX(calc(100vw + 200px)) translateY(60vh) rotate(45deg);
        opacity: 0;
    }
}

.stars, .stars2, .stars3 {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
}

.stars {
    background-image: 
        radial-gradient(2px 2px at 20px 30px, white, transparent),
        radial-gradient(2px 2px at 40px 70px, white, transparent),
        radial-gradient(1px 1px at 90px 40px, white, transparent),
        radial-gradient(1px 1px at 130px 80px, white, transparent),
        radial-gradient(2px 2px at 160px 30px, white, transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: twinkle 3s linear infinite;
}

.stars2 {
    background-image: 
        radial-gradient(1px 1px at 40px 60px, white, transparent),
        radial-gradient(1px 1px at 120px 10px, white, transparent),
        radial-gradient(1px 1px at 160px 70px, white, transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: twinkle 2s linear infinite;
}

.stars3 {
    background-image: 
        radial-gradient(1px 1px at 10px 10px, white, transparent),
        radial-gradient(1px 1px at 150px 60px, white, transparent),
        radial-gradient(1px 1px at 60px 80px, white, transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: twinkle 4s linear infinite;
}

@keyframes twinkle {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    backdrop-filter: blur(20px);
    background: rgba(15, 23, 42, 0.9);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1000;
    transition: all 0.3s ease;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-md) var(--spacing-lg);
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1.25rem;
    color: white;
}

.moon-icon {
    font-size: 1.5rem;
    filter: drop-shadow(0 0 10px var(--moon-glow));
}

.nav-links {
    display: flex;
    gap: var(--spacing-xl);
}

.nav-link {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-weight: 500;
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-md);
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: white;
    background: 
        linear-gradient(135deg, rgba(79, 70, 229, 0.3), rgba(124, 58, 237, 0.3)),
        rgba(255, 255, 255, 0.1);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 5px 15px rgba(79, 70, 229, 0.3);
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
    padding: var(--spacing-sm);
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: white;
    border-radius: var(--radius-full);
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* Hero Section */
.hero {
    padding: 120px var(--spacing-lg) var(--spacing-3xl);
    position: relative;
    z-index: 1;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
}

.hero-content {
    text-align: center;
    margin-bottom: var(--spacing-3xl);
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    color: white;
    margin-bottom: var(--spacing-lg);
    line-height: 1.1;
    text-shadow: 
        0 0 20px rgba(251, 191, 36, 0.5),
        0 0 40px rgba(79, 70, 229, 0.3),
        0 0 60px rgba(124, 58, 237, 0.2);
}

@keyframes titleGlow {
    0% {
        text-shadow: 
            0 0 20px rgba(251, 191, 36, 0.5),
            0 0 40px rgba(79, 70, 229, 0.3),
            0 0 60px rgba(124, 58, 237, 0.2);
    }
    100% {
        text-shadow: 
            0 0 30px rgba(251, 191, 36, 0.8),
            0 0 50px rgba(79, 70, 229, 0.5),
            0 0 80px rgba(124, 58, 237, 0.4);
    }
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.8);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Current Moon Section */
.current-moon-section {
    background: 
        linear-gradient(135deg, rgba(15, 23, 42, 0.15) 0%, rgba(30, 41, 59, 0.1) 100%),
        radial-gradient(ellipse at top left, rgba(79, 70, 229, 0.05) 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(251, 191, 36, 0.05) 0%, transparent 50%);
    border-radius: var(--radius-xl);
    padding: var(--spacing-2xl);
    box-shadow: 
        var(--shadow-xl),
        0 0 40px rgba(251, 191, 36, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(79, 70, 229, 0.2);
    backdrop-filter: blur(3px);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

.current-moon-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    z-index: 1;
}

@keyframes shimmer {
    0% { left: -100%; }
    50% { left: 100%; }
    100% { left: 100%; }
}

.current-moon-section:hover {
    transform: translateY(-5px);
    box-shadow: 
        var(--shadow-xl),
        0 0 60px rgba(251, 191, 36, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.moon-display-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-2xl);
    align-items: center;
    margin-bottom: var(--spacing-2xl);
}

/* Moon Visual */
.moon-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.moon-sphere {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    position: relative;
    box-shadow: 
        var(--shadow-glow),
        0 0 60px rgba(251, 191, 36, 0.4),
        0 0 120px rgba(251, 191, 36, 0.2),
        inset 0 0 20px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    animation: moonFloat 6s ease-in-out infinite;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.moon-sphere:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 
        var(--shadow-glow),
        0 0 80px rgba(251, 191, 36, 0.6),
        0 0 160px rgba(251, 191, 36, 0.3),
        inset 0 0 30px rgba(0, 0, 0, 0.3);
}

@keyframes moonPulse {
    0% {
        box-shadow: 
            var(--shadow-glow),
            0 0 60px rgba(251, 191, 36, 0.4),
            0 0 120px rgba(251, 191, 36, 0.2);
    }
    100% {
        box-shadow: 
            var(--shadow-glow),
            0 0 80px rgba(251, 191, 36, 0.6),
            0 0 160px rgba(251, 191, 36, 0.3);
    }
}

.moon-image {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    transition: all 0.5s ease;
}

.moon-shadow {
    display: none;
}

.moon-glow {
    position: absolute;
    top: -20px;
    left: -20px;
    right: -20px;
    bottom: -20px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.3) 0%, transparent 70%);
}

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

@keyframes moonGlow {
    0% { opacity: 0.6; transform: scale(1); }
    100% { opacity: 1; transform: scale(1.1); }
}

/* Moon Info */
.moon-info {
    color: white;
}

.current-phase {
    margin-bottom: var(--spacing-xl);
}

.phase-label {
    display: block;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--spacing-sm);
}

.phase-name {
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 600;
    color: white;
}

.moon-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
}

.stat-item {
    text-align: center;
    padding: var(--spacing-md);
    background: 
        linear-gradient(135deg, rgba(79, 70, 229, 0.1) 0%, rgba(124, 58, 237, 0.05) 100%),
        radial-gradient(circle at center, rgba(251, 191, 36, 0.05) 0%, transparent 70%);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(79, 70, 229, 0.2);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
}

.stat-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

@keyframes progressFlow {
    0%, 100% { width: 0%; }
    50% { width: 100%; }
}

.stat-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.1) 50%, transparent 70%);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.stat-item:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 30px rgba(79, 70, 229, 0.3);
    border-color: rgba(79, 70, 229, 0.4);
}

.stat-item:hover::before {
    transform: translateX(100%);
}

.stat-label {
    display: block;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--spacing-xs);
}

.stat-value {
    display: block;
    font-size: 1.25rem;
    font-weight: 600;
    color: white;
    text-shadow: 0 0 10px rgba(251, 191, 36, 0.6);
}

@keyframes valueShimmer {
    0%, 100% { 
        background-position: 0% 50%;
        filter: hue-rotate(0deg);
    }
    50% { 
        background-position: 100% 50%;
        filter: hue-rotate(20deg);
    }
}

/* Current Effects */
.current-effects {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: var(--spacing-2xl);
}

.effects-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xl);
}

.effect-category {
    padding: var(--spacing-lg);
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.1), rgba(30, 41, 59, 0.08));
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

.effect-category.mood {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.1), rgba(30, 41, 59, 0.08));
    border-color: rgba(34, 197, 94, 0.2);
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

.effect-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: var(--spacing-md);
    color: white;
}

.effect-description {
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.6;
}

/* Container and Section Styles */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-3xl);
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 600;
    color: white;
    margin-bottom: var(--spacing-lg);
}

.section-description {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.7);
    max-width: 600px;
    margin: 0 auto;
}

/* Calendar Section */
.calendar-section {
    padding: var(--spacing-3xl) 0;
    position: relative;
    z-index: 1;
}

.calendar-container {
    background: 
        linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.9) 100%);
    border-radius: var(--radius-xl);
    padding: var(--spacing-2xl);
    box-shadow: var(--shadow-xl);
    border: 1px solid rgba(255, 255, 255, 0.3);
    margin-bottom: var(--spacing-2xl);
}

.calendar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-xl);
}

.calendar-nav {
    background: var(--primary-color);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.25rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-nav:hover {
    background: var(--secondary-color);
    transform: scale(1.1);
}

.calendar-title {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.calendar-day {
    aspect-ratio: 1;
    background: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 60px;
}

.calendar-day:hover {
    background: rgba(79, 70, 229, 0.05);
}

.calendar-day.other-month {
    color: var(--text-light);
    background: rgba(0, 0, 0, 0.02);
}

.calendar-day.today {
    background: var(--primary-color);
    color: white;
}

.calendar-day.moon-phase {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.1), rgba(251, 191, 36, 0.05));
}

.calendar-day-number {
    font-weight: 500;
    margin-bottom: 2px;
}

.calendar-moon-icon {
    font-size: 0.75rem;
    opacity: 0.7;
}

/* Upcoming Phases */
.upcoming-phases {
    background: 
        linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.9) 100%);
    border-radius: var(--radius-xl);
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.upcoming-title {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--spacing-lg);
}

.phases-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.phase-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-md);
    background: rgba(79, 70, 229, 0.05);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(79, 70, 229, 0.1);
}

.phase-date {
    font-weight: 600;
    color: var(--text-primary);
}

.phase-name-small {
    color: var(--text-secondary);
}

/* Effects Guide */
.effects-guide {
    padding: var(--spacing-3xl) 0;
    position: relative;
    z-index: 1;
}

.phases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-xl);
}

.phase-card {
    background: 
        linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.85) 100%),
        radial-gradient(circle at top right, rgba(79, 70, 229, 0.03) 0%, transparent 70%),
        radial-gradient(circle at bottom left, rgba(251, 191, 36, 0.03) 0%, transparent 70%);
    border-radius: var(--radius-xl);
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.phase-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(251, 191, 36, 0.1) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.phase-card:hover::after {
    opacity: 1;
}

.phase-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.phase-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 
        var(--shadow-xl),
        0 20px 40px rgba(79, 70, 229, 0.2),
        0 0 60px rgba(251, 191, 36, 0.1);
    border-color: rgba(79, 70, 229, 0.3);
}

.phase-card-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
}

.phase-icon {
    font-size: 2rem;
    filter: drop-shadow(0 0 10px var(--moon-glow));
}

.phase-card-title {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

.phase-description {
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
    line-height: 1.6;
}

.phase-effects {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.phase-effect {
    padding: var(--spacing-md);
    border-radius: var(--radius-lg);
    background: rgba(79, 70, 229, 0.05);
    border-left: 4px solid var(--primary-color);
}

.effect-category-title {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--spacing-xs);
    font-size: 0.875rem;
}

.effect-text {
    color: var(--text-secondary);
    font-size: 0.875rem;
    line-height: 1.5;
}

/* Insights Section */
.insights-section {
    padding: var(--spacing-3xl) 0;
    position: relative;
    z-index: 1;
}

.insights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-xl);
}

.insight-card {
    background: 
        linear-gradient(135deg, rgba(255, 255, 255, 0.92) 0%, rgba(255, 255, 255, 0.88) 100%);
    border-radius: var(--radius-xl);
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.insight-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-color), var(--primary-color));
}

.insight-card:hover {
    transform: translateY(-8px) scale(1.03) rotate(1deg);
    box-shadow: 
        var(--shadow-xl),
        0 15px 35px rgba(251, 191, 36, 0.2),
        0 0 50px rgba(79, 70, 229, 0.1);
    border-color: rgba(251, 191, 36, 0.3);
}

.insight-icon {
    font-size: 3rem;
    margin-bottom: var(--spacing-lg);
    display: block;
}

.insight-title {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--spacing-md);
}

.insight-description {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: var(--spacing-lg);
}

.insight-phase {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 500;
}

/* Footer */
.footer {
    background: var(--background-secondary);
    padding: var(--spacing-3xl) 0 var(--spacing-xl);
    position: relative;
    z-index: 1;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: var(--spacing-2xl);
    margin-bottom: var(--spacing-xl);
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1.25rem;
    color: white;
    margin-bottom: var(--spacing-lg);
}

.footer-description {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
    max-width: 400px;
}

.footer-links {
    color: white;
}

.footer-links h4 {
    font-family: var(--font-display);
    font-weight: 600;
    margin-bottom: var(--spacing-md);
}

.footer-links a {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    padding: var(--spacing-xs) 0;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--spacing-lg);
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(15, 23, 42, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: var(--spacing-2xl);
        z-index: 1000;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
    }
    
    .nav-links.active {
        display: flex;
        opacity: 1;
        visibility: visible;
    }
    
    .nav-link {
        font-size: 1.5rem;
        font-weight: 600;
        color: white;
        text-decoration: none;
        padding: var(--spacing-lg);
        border-radius: var(--radius-lg);
        transition: all 0.3s ease;
        text-align: center;
        min-width: 200px;
    }
    
    .nav-link:hover {
        background: rgba(79, 70, 229, 0.2);
        transform: scale(1.05);
    }
    
    .mobile-menu-toggle {
        display: flex;
        position: relative;
        z-index: 1001;
    }
    
    .hero {
        padding: 100px var(--spacing-md) var(--spacing-2xl);
    }
    
    .moon-display-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--spacing-xl);
    }
    
    .moon-sphere {
        width: 150px;
        height: 150px;
    }
    
    .effects-container {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }
    
    .calendar-day {
        min-height: 50px;
    }
    
    .calendar-day-number {
        font-size: 0.875rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-xl);
    }
    
    .phases-grid,
    .insights-grid {
        grid-template-columns: 1fr;
    }
    
    .current-moon-section,
    .calendar-container,
    .upcoming-phases {
        padding: var(--spacing-lg);
        margin: 0 var(--spacing-sm);
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    .phase-name {
        font-size: 2rem;
    }
    
    .moon-stats {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .nav-container {
        padding: var(--spacing-md);
    }
}

/* Loading States */
.loading {
    opacity: 0.6;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* Magical Enhancement Classes */
.magic-border {
    position: relative;
    background: linear-gradient(45deg, #0f172a, #1e293b, #0f172a);
    background-size: 400% 400%;
    animation: magicBorderGradient 6s ease infinite;
}

.magic-border::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color), var(--accent-color), var(--primary-color));
    background-size: 400% 400%;
    border-radius: inherit;
    z-index: -1;
    animation: magicBorderGradient 4s ease infinite;
}

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

.pulse-glow {
    animation: pulseGlow 2s ease-in-out infinite alternate;
}

@keyframes pulseGlow {
    0% {
        box-shadow: 0 0 20px rgba(79, 70, 229, 0.3);
        transform: scale(1);
    }
    100% {
        box-shadow: 0 0 40px rgba(79, 70, 229, 0.6);
        transform: scale(1.02);
    }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.hidden { display: none; }
.visible { display: block; }

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

/* Smooth transitions for dynamic content */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

/* Custom scrollbar */
/* Enhanced Scrollbar */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: linear-gradient(180deg, var(--background-primary), var(--background-secondary));
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--primary-color), var(--secondary-color));
    border-radius: 10px;
    border: 2px solid var(--background-primary);
    box-shadow: inset 0 0 10px rgba(251, 191, 36, 0.3);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--secondary-color), var(--accent-color));
    box-shadow: 
        inset 0 0 10px rgba(251, 191, 36, 0.5),
        0 0 20px rgba(79, 70, 229, 0.3);
}