:root {
    --primary-color: #0b3d91;
    --primary-hover: #1056c0;
    --secondary-color: #fc3d21;
    --secondary-hover: #ff5a3d;
    --dark-bg: #050a14;
    --light-bg: #0f1525;
    --text-color: #f0f0f0;
    --accent-color: #4da6ff;
    --highlight-color: #f5a623;
    --blue-glow: rgba(77, 166, 255, 0.6);
    --red-glow: rgba(252, 61, 33, 0.6);
    --glass-bg: rgba(23, 32, 56, 0.65);
    --glass-border: rgba(120, 180, 255, 0.2);
    --card-shadow: 0 15px 45px rgba(0, 0, 0, 0.7);
    --text-shadow: 0 0 10px rgba(77, 166, 255, 0.6);
    --cosmic-glow: 0 0 15px var(--blue-glow), 0 0 30px rgba(77, 166, 255, 0.3);
}

@font-face {
    font-family: 'Space Grotesk';
    src: url('https://fonts.gstatic.com/s/spacegrotesk/v15/V8mQoQDjQSkFtoMM3T6r8E7mF71Q-gOoraIAEj7oUXskPMBBSSJLm2E.woff2') format('woff2');
    font-weight: 300 700;
    font-style: normal;
    font-display: swap;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Space Grotesk', 'Segoe UI', 'Roboto', sans-serif;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

body {
    background: radial-gradient(ellipse at bottom, #0B1830 0%, #050A14 100%);
    color: var(--text-color);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    font-size: 16px;
    line-height: 1.6;
}


    .sharing-container {
        position: absolute !important;
        bottom: 15px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        display: flex !important;
        gap: 10px !important;
        background: rgba(0, 0, 0, 0.6) !important;
        padding: 8px !important;
        border-radius: 20px !important;
        z-index: 9999 !important;
        top: auto !important;
        right: auto !important;
    }

    .share-button {
        width: 40px !important;
        height: 40px !important;
        font-size: 1.2rem !important;
        opacity: 1 !important;
    }


/* Enhanced star background with multiple parallax layers */
.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.stars:before, .stars:after, .stars .layer-1, .stars .layer-2, .stars .layer-3 {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.8;
}

.stars:before {
    background-image: 
        radial-gradient(2px 2px at 20px 30px, #eee, rgba(0,0,0,0)),
        radial-gradient(2px 2px at 40px 70px, #fff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 90px 40px, #fff, rgba(0,0,0,0)),
        radial-gradient(2px 2px at 160px 120px, #ddd, rgba(0,0,0,0));
    background-repeat: repeat;
    background-size: 200px 200px;
    animation: rotate-stars 300s linear infinite;
}

.stars:after {
    background-image: 
        radial-gradient(1px 1px at 120px 90px, #eee, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 10px 10px, #fff, rgba(0,0,0,0)),
        radial-gradient(2px 2px at 70px 30px, #fff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 20px 120px, #ddd, rgba(0,0,0,0));
    background-repeat: repeat;
    background-size: 250px 250px;
    animation: rotate-stars 250s linear infinite reverse;
}

/* Multiple parallax star layers */
.stars .layer-1, .stars .layer-2, .stars .layer-3 {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-repeat: repeat;
}

.stars .layer-1 {
    background-image: 
        radial-gradient(2px 2px at 30px 40px, rgba(255, 255, 255, 0.9), rgba(0,0,0,0)),
        radial-gradient(2px 2px at 150px 80px, rgba(255, 255, 255, 0.9), rgba(0,0,0,0)),
        radial-gradient(2px 2px at 250px 180px, rgba(255, 255, 255, 0.9), rgba(0,0,0,0));
    background-size: 300px 300px;
    animation: parallax-stars-1 350s linear infinite;
}

.stars .layer-2 {
    background-image: 
        radial-gradient(1px 1px at 80px 120px, rgba(255, 255, 255, 0.8), rgba(0,0,0,0)),
        radial-gradient(1px 1px at 200px 40px, rgba(255, 255, 255, 0.8), rgba(0,0,0,0)),
        radial-gradient(1px 1px at 300px 200px, rgba(255, 255, 255, 0.8), rgba(0,0,0,0));
    background-size: 400px 400px;
    animation: parallax-stars-2 450s linear infinite;
}

.stars .layer-3 {
    background-image: 
        radial-gradient(1px 1px at 100px 200px, rgba(255, 255, 255, 0.7), rgba(0,0,0,0)),
        radial-gradient(1px 1px at 250px 100px, rgba(255, 255, 255, 0.7), rgba(0,0,0,0)),
        radial-gradient(1px 1px at 350px 300px, rgba(255, 255, 255, 0.7), rgba(0,0,0,0));
    background-size: 500px 500px;
    animation: parallax-stars-3 550s linear infinite;
}

@keyframes rotate-stars {
    from { background-position: 0 0; }
    to { background-position: 200px 200px; }
}

@keyframes parallax-stars-1 {
    from { background-position: 0 0; }
    to { background-position: 300px 300px; }
}

@keyframes parallax-stars-2 {
    from { background-position: 0 0; }
    to { background-position: 400px 400px; }
}

@keyframes parallax-stars-3 {
    from { background-position: 0 0; }
    to { background-position: 500px 500px; }
}

.about-us {
    margin-top: 40px;
    background: var(--glass-bg);
    padding: 40px;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
    perspective: 1000px;
}

.about-us h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #00d4ff;
}

.about-us p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1rem;
}

/* Learn More Section Styles */
.learn-more {
    margin-top: 40px;
    background: var(--glass-bg);
    padding: 40px;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
    perspective: 1000px;
}

.learn-more h2 {
    font-size: 24px;
    margin-bottom: 10px;
}

.learn-more ul {
    list-style-type: none;
    padding: 0;
}

.learn-more li {
    margin: 10px 0;
}

.learn-more a {
    color: #0066cc;
    text-decoration: none;
}

.learn-more a:hover {
    text-decoration: underline;
}

/* Quote Section Styles */
.quote-section {
    margin-top: 40px;
    background: var(--glass-bg);
    padding: 40px;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
    perspective: 1000px;
}

.quote {
    margin: 0;
    font-size: 20px;
}

.quote p {
    margin: 0;
}

/* Add floating nebulae and cosmic dust effects */
.cosmic-dust {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.3;
    background: 
        radial-gradient(circle at 20% 30%, rgba(77, 166, 255, 0.1) 0%, transparent 25%),
        radial-gradient(circle at 80% 20%, rgba(252, 61, 33, 0.05) 0%, transparent 20%),
        radial-gradient(circle at 40% 80%, rgba(245, 166, 35, 0.05) 0%, transparent 30%),
        radial-gradient(circle at 70% 60%, rgba(77, 166, 255, 0.07) 0%, transparent 25%);
    filter: blur(30px);
    animation: cosmic-float 120s ease-in-out infinite alternate;
}

@keyframes cosmic-float {
    0% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(2%, 1%) scale(1.02); }
    50% { transform: translate(-1%, 2%) scale(0.98); }
    75% { transform: translate(1%, -1%) scale(1.01); }
    100% { transform: translate(-2%, -2%) scale(0.99); }
}

/* Enhanced header with advanced glass morphism and light effects */
.header {
    padding: 20px 40px;
    background: linear-gradient(90deg, rgba(11, 61, 145, 0.75) 0%, rgba(15, 80, 180, 0.6) 100%);
    backdrop-filter: blur(12px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5), 0 0 15px rgba(77, 166, 255, 0.2);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--glass-border);
    overflow: hidden;
}

/* Add light beam effect to header */
.header:before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent 45%, rgba(255, 255, 255, 0.1) 50%, transparent 55%);
    transform: rotate(45deg);
    animation: light-beam 10s infinite;
}

@keyframes light-beam {
    0% { 
        transform: rotate(45deg) translateX(-100%);
        opacity: 0; 
    }
    10% { opacity: 0.5; }
    20% { opacity: 0; }
    100% { 
        transform: rotate(45deg) translateX(100%);
        opacity: 0; 
    }
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
    z-index: 1;
}

.logo i {
    font-size: 2.8rem;
    color: var(--secondary-color);
    text-shadow: 0 0 15px var(--red-glow), 0 0 30px rgba(252, 61, 33, 0.3);
    animation: logo-pulse 3s infinite alternate;
    position: relative;
}

.logo i:after {
    content: '';
    position: absolute;
    width: 120%;
    height: 120%;
    top: -10%;
    left: -10%;
    background: radial-gradient(circle, rgba(252, 61, 33, 0.2) 0%, transparent 70%);
    border-radius: 50%;
    z-index: -1;
    animation: glow-pulse 3s infinite alternate;
}

@keyframes logo-pulse {
    from {
        text-shadow: 0 0 15px var(--red-glow), 0 0 30px rgba(252, 61, 33, 0.3);
        transform: scale(1);
    }
    to {
        text-shadow: 0 0 25px var(--red-glow), 0 0 50px rgba(252, 61, 33, 0.5);
        transform: scale(1.08);
    }
}

@keyframes glow-pulse {
    from { opacity: 0.4; transform: scale(1); }
    to { opacity: 0.7; transform: scale(1.2); }
}

.logo h1 {
    font-size: 2.2rem;
    font-weight: 700;
    background: linear-gradient(to right, var(--secondary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 2px;
    text-shadow: var(--text-shadow);
    position: relative;
}

.logo h1:before {
    content: '';
    position: absolute;
    top: -10px;
    left: -15px;
    width: calc(100% + 30px);
    height: calc(100% + 20px);
    background: radial-gradient(ellipse at center, rgba(77, 166, 255, 0.05) 0%, transparent 70%);
    border-radius: 10px;
    z-index: -1;
}

.logo h1:after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, var(--secondary-color), transparent);
}

.main-container {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 30px;
    position: relative;
}

/* Enhanced image container with advanced hover effects and 3D perspective */
.image-container {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 2px solid transparent;
    transform-style: preserve-3d;
    perspective: 1000px;
    width: 1000px;  /* Adjusted width */
    height: 700px; /* Adjusted height */
    margin: 0 auto; /* Center horizontally */
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-container:hover {
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.9), 0 0 20px var(--blue-glow);
    transform: translateY(-10px) rotateX(2deg) rotateY(-2deg);
    border: 2px solid var(--glass-border);
}

#apod-image {
    max-width: 85%;
    max-height: 85%;
    width: auto;     /* Allow the width to adjust automatically */
    height: auto;    /* Allow the height to adjust automatically */
    object-fit: contain; /* Maintain aspect ratio without distortion */
    display: block;
    transition: transform 0.8s cubic-bezier(0.215, 0.61, 0.355, 1);
    margin: auto;    /* Center the image inside the container */
}

.image-container:hover #apod-image {
    transform: scale(1.08) translateZ(10px);
}

/* Advanced image overlay with glowing edge effect */
.image-container:after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, 
        rgba(0,0,0,0.1) 0%, 
        rgba(0,0,0,0.3) 50%, 
        rgba(0,0,0,0.6) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.image-container:hover:after {
    opacity: 1;
}

/* Add glowing edge effect */
.image-container:before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--secondary-color), var(--accent-color), var(--highlight-color), var(--accent-color));
    z-index: -1;
    border-radius: 22px;
    opacity: 0;
    transition: opacity 0.4s ease;
    animation: edge-glow 3s linear infinite;
}

.image-container:hover:before {
    opacity: 0.6;
}

@keyframes edge-glow {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Enhanced info panel with atmospheric glass morphism effects */
.info-panel {
    margin-top: 40px;
    background: var(--glass-bg);
    padding: 40px;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
    perspective: 1000px;
}

/* Add atmospheric glow effect */
.info-panel:before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at center, rgba(77, 166, 255, 0.1) 0%, transparent 70%);
    transform: rotate(30deg);
    z-index: -1;
    animation: atmospheric-glow 15s ease-in-out infinite alternate;
}

@keyframes atmospheric-glow {
    0% { opacity: 0.1; transform: rotate(30deg) scale(1); }
    50% { opacity: 0.2; transform: rotate(30deg) scale(1.05); }
    100% { opacity: 0.1; transform: rotate(30deg) scale(1); }
}

/* Add subtle particle effect */
.info-panel:after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(1px 1px at 60px 40px, rgba(255, 255, 255, 0.6), transparent),
        radial-gradient(1px 1px at 100px 90px, rgba(255, 255, 255, 0.5), transparent),
        radial-gradient(1px 1px at 150px 150px, rgba(255, 255, 255, 0.4), transparent),
        radial-gradient(1px 1px at 230px 70px, rgba(255, 255, 255, 0.5), transparent);
    background-repeat: repeat;
    background-size: 250px 250px;
    opacity: 0.05;
    z-index: -1;
    animation: particle-float 40s linear infinite;
}

@keyframes particle-float {
    from { background-position: 0 0; }
    to { background-position: 250px 250px; }
}

.date-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--glass-border);
    position: relative;
}

/* Add glowing line under date navigation */
.date-nav:after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(to right, 
        transparent 0%, 
        var(--accent-color) 50%, 
        transparent 100%);
    opacity: 0.5;
    filter: blur(1px);
}

/* Enhanced buttons with cosmic glow and particle effects */
.nav-button {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 50px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(11, 61, 145, 0.4);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

/* Add cosmic glow effect */
.nav-button:before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    z-index: -2;
    border-radius: 54px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nav-button:after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    z-index: -1;
    border-radius: 50px;
    transition: all 0.3s ease;
}

.nav-button:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(11, 61, 145, 0.6), 0 0 15px var(--blue-glow);
    color: white;
}

.nav-button:hover:before {
    opacity: 0.5;
    animation: button-glow 2s linear infinite;
}

.nav-button:hover:after {
    background: linear-gradient(135deg, var(--primary-hover), var(--primary-color));
    transform: scale(0.98);
}

@keyframes button-glow {
    0% { opacity: 0.5; transform: scale(1); filter: blur(1px); }
    50% { opacity: 0.7; transform: scale(1.03); filter: blur(2px); }
    100% { opacity: 0.5; transform: scale(1); filter: blur(1px); }
}

.nav-button:active {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(11, 61, 145, 0.4);
}

.nav-button i {
    transition: transform 0.3s ease;
}

.nav-button:hover i {
    transform: translateX(-5px) scale(1.2);
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

#next-day:hover i {
    transform: translateX(5px) scale(1.2);
}

/* Enhanced date display */
#current-date {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--accent-color);
    text-shadow: var(--text-shadow);
    position: relative;
    padding: 0 15px;
    text-align: center;
    display: inline-block;
}

#current-date:before, #current-date:after {
    content: '';
    position: absolute;
    top: 50%;
    width: 50px;
    height: 1px;
    background: linear-gradient(to right, transparent, var(--glass-border), transparent);
}

#current-date:before {
    left: -60px;
}

#current-date:after {
    right: -60px;
}

/* Add cosmic particles around date */
#current-date:hover:before, #current-date:hover:after {
    animation: line-shimmer 2s infinite;
}

@keyframes line-shimmer {
    0% { opacity: 0.5; width: 50px; }
    50% { opacity: 1; width: 70px; }
    100% { opacity: 0.5; width: 50px; }
}

h2 {
    margin-bottom: 25px;
    font-size: 2.6rem;
    color: var(--accent-color);
    font-weight: 800;
    text-transform: capitalize;
    letter-spacing: 1px;
    text-shadow: var(--text-shadow);
    position: relative;
    display: inline-block;
}

h2:after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60%;
    height: 3px;
    background: linear-gradient(to right, var(--accent-color), transparent);
    box-shadow: 0 0 10px var(--blue-glow);
}

/* Add shimmer effect to the heading */
h2:before {
    content: '';
    position: absolute;
    top: 0;
    left: -20%;
    width: 40%;
    height: 100%;
    background: linear-gradient(to right, 
        transparent 0%, 
        rgba(255, 255, 255, 0.1) 50%, 
        transparent 100%);
    transform: skewX(-20deg);
    animation: heading-shimmer 6s infinite;
}

@keyframes heading-shimmer {
    0% { left: -20%; opacity: 0; }
    10% { opacity: 0.4; }
    20% { opacity: 0; }
    100% { left: 120%; opacity: 0; }
}

p {
    line-height: 1.8;
    margin-bottom: 25px;
    font-size: 1.15rem;
    color: rgba(240, 240, 240, 0.9);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 1;
    opacity: 1; /* Ensure text is visible immediately */
}

/* Enhanced loading spinner with cosmic animation */
.loading {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(15px);
}

.spinner {
    width: 80px;
    height: 80px;
    border: 4px solid rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    border-top-color: var(--secondary-color);
    position: relative;
    animation: spin 1.2s cubic-bezier(0.68, -0.55, 0.27, 1.55) infinite;
    box-shadow: 0 0 30px var(--red-glow);
}

.spinner:before, .spinner:after {
    content: '';
    position: absolute;
    border-radius: 50%;
}

.spinner:before {
    top: 5px;
    left: 5px;
    right: 5px;
    bottom: 5px;
    border: 3px solid transparent;
    border-right-color: var(--accent-color);
    border-left-color: var(--accent-color);
    animation: spin-reverse 1s linear infinite;
}

.spinner:after {
    top: 15px;
    left: 15px;
    right: 15px;
    bottom: 15px;
    border: 2px solid transparent;
    border-top-color: var(--highlight-color);
    animation: spin 1.5s ease-in-out infinite alternate;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes spin-reverse {
    to { transform: rotate(-360deg); }
}

/* Enhanced footer with cosmic effects */
.footer {
    text-align: center;
    padding: 50px 20px;
    margin-top: 80px;
    background: linear-gradient(0deg, rgba(11, 61, 145, 0.8) 0%, rgba(11, 61, 145, 0.3) 100%);
    backdrop-filter: blur(15px);
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.05rem;
    position:relative;
    overflow: hidden;
    box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.3), inset 0 0 30px rgba(77, 166, 255, 0.1);
    border-top: 1px solid var(--glass-border);
}

/* Add floating cosmic effect */
.footer:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 20%, rgba(77, 166, 255, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 80% 80%, rgba(77, 166, 255, 0.1) 0%, transparent 40%);
    z-index: -1;
    animation: footer-glow 10s ease-in-out infinite alternate;
}

@keyframes footer-glow {
    0% { opacity: 0.5; transform: translateY(0) scale(1); }
    100% { opacity: 0.8; transform: translateY(-20px) scale(1.2); }
}

/* Add shooting star effect */
.footer:after {
    content: '';
    position: absolute;
    top: 20px;
    left: -100px;
    width: 100px;
    height: 2px;
    background: linear-gradient(to right, transparent, white);
    filter: blur(1px);
    animation: shooting-star 8s linear infinite;
}

@keyframes shooting-star {
    0% { 
        left: -100px;
        top: 20px;
        opacity: 0;
        transform: rotate(45deg) translateX(0);
    }
    10% { opacity: 1; }
    20% { opacity: 0; }
    100% { 
        left: 120%;
        top: 60%;
        opacity: 0;
        transform: rotate(45deg) translateX(0);
    }
}

.footer p {
    margin-bottom: 10px;
    text-shadow: var(--text-shadow);
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease, color 0.3s ease;
}

.footer p:hover {
    transform: translateY(-3px);
    color: var(--accent-color);
}

.footer p:last-child {
    margin-top: 20px;
    font-weight: 600;
    position: relative;
    display: inline-block;
}

.media-credits {
    font-style: italic;
    color: #cccccc;
    margin-top: 20px;
    font-size: 0.95rem;
    position: relative;
    display: inline-block;
}

.media-credits:before, .media-credits:after {
    content: '';
    position: absolute;
    top: 50%;
    width: 30px;
    height: 1px;
    background: linear-gradient(to right, transparent, var(--glass-border), transparent);
    animation: credits-line-float 3s infinite alternate;
}

@keyframes credits-line-float {
    from { width: 30px; opacity: 0.5; }
    to { width: 50px; opacity: 0.8; }
}

.media-credits:before {
    left: -40px;
}

.media-credits:after {
    right: -40px;
}

.media-credits:hover {
    color: var(--accent-color);
    text-shadow: 0 0 10px var(--blue-glow);
}

/* Advanced 3D mouse tracking effect for image */
.image-container {
    transform-style: preserve-3d;
    perspective: 1000px;
    will-change: transform;
}

.parallax-card {
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.1s ease;
}

/* Enhanced Zoom Controls */
.zoom-controls {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
    gap: 10px;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    transform: translateY(20px);
    z-index: 5;
}

.image-container:hover .zoom-controls {
    opacity: 1;
    transform: translateY(0);
}

.zoom-btn {
    background: rgba(15, 32, 56, 0.8);
    color: white;
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(77, 166, 255, 0.2);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

.zoom-btn i {
    font-size: 1.2rem;
    transition: transform 0.2s ease;
}

.zoom-btn:hover {
    background: rgba(77, 166, 255, 0.8);
    transform: scale(1.1);
    box-shadow: 0 0 15px var(--blue-glow);
}

.zoom-btn:hover i {
    transform: scale(1.2);
}

.zoom-btn:active {
    transform: scale(0.95);
}

/* Add image info overlay */
.image-info-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, transparent 100%);
    color: white;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 4;
}

.image-container:hover .image-info-overlay {
    opacity: 1;
    transform: translateY(0);
}

.image-info-overlay h3 {
    font-size: 1.3rem;
    margin-bottom: 8px;
    color: var(--highlight-color);
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.image-info-overlay p {
    font-size: 0.9rem;
    margin-bottom: 0;
    line-height: 1.4;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease;
}

.image-container:hover .image-info-overlay p {
    max-height: 100px;
}

/* Add Tooltip System */
[data-tooltip] {
    position: relative;
}

[data-tooltip]:before {
    content: attr(data-tooltip);
    position: absolute;
    right: 100%; /* Position to the left */
    top: 50%; /* Center vertically */
    transform: translateY(-50%) translateX(-5px); /* Adjust position */
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    border-radius: 6px;
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

[data-tooltip]:after {
    content: '';
    position: absolute;
    right: 100%; /* Align with the tooltip */
    top: 50%; /* Center vertically */
    transform: translateY(-50%);
    border: 5px solid transparent;
    border-right-color: rgba(0, 0, 0, 0.8); /* Arrow pointing right */
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

[data-tooltip]:hover:before,
[data-tooltip]:hover:after {
    opacity: 1;
    visibility: visible;
    transform: translateY(-50%) translateX(-10px); /* Adjust tooltip animation */
}

/* Enhanced Dark Mode Toggle */
.dark-mode-toggle {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    color: var(--text-color);
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 101;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.dark-mode-toggle:hover {
    background: rgba(77, 166, 255, 0.1);
    color: var(--highlight-color);
    transform: rotate(180deg);
    box-shadow: 0 0 15px var(--blue-glow);
}

/* Add custom scroll progress indicator */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(to right, var(--secondary-color), var(--highlight-color));
    z-index: 1000;
    transition: width 0.1s ease;
    box-shadow: 0 0 10px var(--red-glow);
}

/* Advanced custom scrollbar */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: var(--dark-bg);
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.3);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
    border-radius: 6px;
    border: 3px solid var(--dark-bg);
    transition: all 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(to bottom, var(--primary-hover), var(--secondary-hover));
    box-shadow: 0 0 8px var(--blue-glow);
}

/* Add fancy blurry glow effect to header and buttons */
.cosmic-glow {
    position: relative;
}

.cosmic-glow:after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: inherit;
    filter: blur(20px) brightness(1.2);
    opacity: 0.5;
    z-index: -1;
    transform: scale(0.9);
    border-radius: inherit;
    transition: all 0.3s ease;
}

.cosmic-glow:hover:after {
    opacity: 0.8;
    transform: scale(1.1);
}

/* Add floating particles effect to the page */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.particle {
    position: absolute;
    background: white;
    border-radius: 50%;
    opacity: 0.3;
    animation: float-particle var(--duration) linear infinite;
}

@keyframes float-particle {
    0% {
        transform: translateY(0) translateX(0);
        opacity: 0;
    }
    10% {
        opacity: var(--opacity);
    }
    90% {
        opacity: var(--opacity);
    }
    100% {
        transform: translateY(calc(-100vh - 10px)) translateX(var(--travel));
        opacity: 0;
    }
}

/* Responsive enhancement */
@media (max-width: 768px) {
    .header {
        flex-direction: column;
        text-align: center;
        padding: 20px 15px;
    }

    .logo {
        margin-bottom: 15px;
    }

    .logo i {
        font-size: 2.2rem;
    }

    .logo h1 {
        font-size: 1.8rem;
    }

    .date-nav {
        flex-direction: column;
        gap: 15px;
    }

    #current-date {
        order: -1;
        margin-bottom: 15px;
        font-size: 1.2rem;
    }

    #current-date:before, #current-date:after {
        width: 30px;
    }

    .nav-button {
        width: 100%;
        justify-content: center;
    }

    h2 {
        font-size: 1.8rem;
    }

    p {
        font-size: 1rem;
    }

    .spinner {
        width: 60px;
        height: 60px;
    }

    .zoom-controls {
        bottom: 10px;
        right: 10px;
    }

    .zoom-btn {
        width: 36px;
        height: 36px;
    }

    .image-info-overlay {
        padding: 15px;
    }

    .image-info-overlay h3 {
        font-size: 1.1rem;
    }

    .image-info-overlay p {
        font-size: 0.8rem;
    }
    
    /* Responsive image container for mobile */
    .image-container {
        width: 100%;
        max-width: 90%;
        height: 350px;
    }
    
    /* Enhance video container to fit mobile view better */
    .image-container iframe {
        max-width: 100% !important;
        max-height: 330px !important;
    }
}

/* Add tablet responsiveness */
@media (min-width: 769px) and (max-width: 1024px) {
    .main-container {
        padding: 0 25px;
    }

    .info-panel {
        padding: 35px 25px;
    }

    h2 {
        font-size: 2.2rem;
    }
    
    .logo h1 {
        font-size: 2rem;
    }
    
    .date-nav {
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
    }
    
    #current-date {
        order: -1;
        width: 100%;
        margin-bottom: 15px;
    }
    
    .nav-button {
        min-width: 180px;
    }
    
    /* Responsive image container for tablets */
    .image-container {
        width: 90%;
        max-width: 700px;
        height: 500px;
    }
}

/* High resolution screens */
@media (min-width: 1800px) {
    .main-container {
        max-width: 1600px;
    }
    
    body {
        font-size: 18px;
    }
    
    .logo i {
        font-size: 3.2rem;
    }
    
    .logo h1 {
        font-size: 2.8rem;
    }
    
    h2 {
        font-size: 3.2rem;
    }
    
    p {
        font-size: 1.3rem;
    }
    
    .nav-button {
        padding: 16px 32px;
        font-size: 1.1rem;
    }
    
    #current-date {
        font-size: 1.6rem;
    }
}

/* Animation for content reveal on page load */
.reveal-animation {
    opacity: 0;
    transform: translateY(30px);
    animation: reveal 0.8s forwards;
}

.header {
    animation-delay: 0.1s;
}

.image-container {
    animation-delay: 0.3s;
}

.info-panel {
    animation-delay: 0.5s;
}

.footer {
    animation-delay: 0.7s;
}

@keyframes reveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Add interactive image tilt effect on mouse move */
.js-tilt-container {
    transform-style: preserve-3d;
    transform: perspective(1000px);
}

.js-tilt-inner {
    transform-style: preserve-3d;
    transition: transform 0.1s ease-out;
    will-change: transform;
}

/* Add advanced focus styles for accessibility */
:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 3px;
    box-shadow: 0 0 0 5px rgba(77, 166, 255, 0.2);
}

:focus:not(:focus-visible) {
    outline: none;
    box-shadow: none;
}

/* Add screen reader only class for accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Enhanced cosmic backdrop effects */
.cosmic-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    overflow: hidden;
}

.animated-gradient {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        radial-gradient(circle at 30% 40%, rgba(11, 61, 145, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 70% 60%, rgba(252, 61, 33, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 50% 50%, rgba(21, 40, 80, 0.6) 0%, rgba(5, 10, 20, 0.8) 100%);
    animation: rotate-gradient 60s linear infinite;
}

@keyframes rotate-gradient {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.nebula-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.05' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.15;
    mix-blend-mode: overlay;
}

/* Light mode styles */
.light-mode {
    --dark-bg: #f0f5ff;
    --light-bg: #ffffff;
    --text-color: #0a1525;
    --primary-color: #1a56c0;
    --secondary-color: #e83a10;
    --accent-color: #0062cc;
    --blue-glow: rgba(10, 83, 158, 0.4);
    --red-glow: rgba(232, 58, 16, 0.4);
    --glass-bg: rgba(240, 245, 255, 0.8);
    --glass-border: rgba(26, 86, 192, 0.2);
    --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    --text-shadow: 0 0 5px rgba(10, 83, 158, 0.3);
}

.light-mode .stars,
.light-mode .stars:before,
.light-mode .stars:after,
.light-mode .cosmic-dust {
    opacity: 0.3;
}

.light-mode .animated-gradient {
    background: 
        radial-gradient(circle at 30% 40%, rgba(26, 86, 192, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 70% 60%, rgba(232, 58, 16, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 50% 50%, rgba(240, 245, 255, 0.9) 0%, rgba(220, 230, 250, 1) 100%);
}

.light-mode .header {
    background: linear-gradient(90deg, rgba(26, 86, 192, 0.75) 0%, rgba(60, 120, 230, 0.6) 100%);
}

.light-mode .footer {
    background: linear-gradient(0deg, rgba(26, 86, 192, 0.7) 0%, rgba(26, 86, 192, 0.2) 100%);
}

.light-mode h2 {
    color: var(--primary-color);
}

.light-mode p {
    color: rgba(10, 21, 37, 0.9);
}

.light-mode .nav-button {
    background: linear-gradient(135deg, var(--primary-color), #276bdb);
}

.light-mode .nav-button:hover {
    background: linear-gradient(135deg, #276bdb, var(--primary-color));
}

.light-mode .spinner {
    border-top-color: var(--secondary-color);
    box-shadow: 0 0 30px var(--red-glow);
}

.light-mode .spinner:before {
    border-right-color: var(--accent-color);
    border-left-color: var(--accent-color);
}

.light-mode .spinner:after {
    border-top-color: var(--primary-color);
}

/* Skip link for accessibility */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px 16px;
    z-index: 10000;
    transition: top 0.3s ease;
}

.skip-link:focus {
    top: 0;
}

/* Animation for elements coming into view */
[class*="info-panel"],
[class*="footer"] {
    transform: translateY(30px);
    opacity: 0;
    transition: transform 0.6s ease-out, opacity 0.6s ease-out;
}

.in-view {
    transform: translateY(0) !important;
    opacity: 1 !important;
}

/* Mobile Optimization for Space Weather Dashboard */
@media (max-width: 768px) {
    /* Responsive Dashboard Container */
    .weather-overlay {
        padding: 0 10px;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch; /* Smooth scrolling for iOS */
    }

    .weather-container {
        width: 100% !important;
        max-width: 100% !important;
        padding: 20px 10px;
        box-sizing: border-box;
    }

    /* Responsive Grid Layout */
    .dashboard-grid {
        grid-template-columns: 1fr !important; /* Stack panels vertically */
        gap: 15px !important;
    }

    /* Panel Adjustments */
    .weather-panel {
        padding: 15px !important;
        margin-bottom: 10px;
    }

    /* Typography Adjustments */
    h2 {
        font-size: 1.6rem !important;
        margin-bottom: 15px !important;
    }

    h3 {
        font-size: 1.2rem !important;
        margin-bottom: 10px !important;
    }

    h4 {
        font-size: 0.9rem !important;
    }

    /* Geomagnetic Gauge Responsiveness */
    .kp-index-display {
        transform: scale(0.8);
        margin: 0 auto 10px !important;
    }

    /* Aurora Map Responsiveness */
    .aurora-map-container {
        max-height: 250px;
        overflow: hidden;
    }

    #aurora-map {
        object-fit: cover;
        max-height: 250px;
    }

    /* Button and Interactive Element Sizing */
    #set-location-btn,
    #close-weather {
        width: 100%;
        max-width: 300px;
        margin: 10px auto;
        padding: 12px 15px !important;
        font-size: 1rem !important;
    }

    /* List Adjustments */
    #flare-list {
        max-height: 120px !important;
    }

    /* Forecast Bars Responsiveness */
    #forecast-bars {
        flex-direction: column;
        gap: 10px !important;
    }

    .forecast-day {
        width: 100%;
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .forecast-day > div:first-child {
        width: 100px;
        height: 50px !important;
    }

    /* Close Button Positioning */
    #close-weather {
        position: sticky !important;
        top: 10px !important;
        right: 10px !important;
        z-index: 2100;
        background: rgba(0,0,0,0.5);
        border-radius: 50%;
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Data Sources and Last Updated */
    .data-sources {
        font-size: 0.8rem !important;
        text-align: center;
        padding: 0 10px;
    }

    /* Space Weather Button */
    .space-weather-button {
        width: 40px !important;
        height: 40px !important;
        right: 10px !important;
        top: 450px !important;
    }

    /* Touch Target Improvements */
    .weather-panel button,
    .nav-button {
        min-height: 44px;
        min-width: 44px;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    /* Responsive Text Sizing */
    body {
        font-size: 14px;
    }

    .status-value {
        font-size: 0.9rem;
    }

    /* Scrollbar and Overflow Handling */
    .weather-overlay {
        overscroll-behavior-y: contain;
    }

    #flare-list,
    .solar-flare-history {
        scrollbar-width: thin;
        scrollbar-color: rgba(255,255,255,0.2) transparent;
    }

    #flare-list::-webkit-scrollbar,
    .solar-flare-history::-webkit-scrollbar {
        width: 6px;
    }

    #flare-list::-webkit-scrollbar-thumb,
    .solar-flare-history::-webkit-scrollbar-thumb {
        background-color: rgba(255,255,255,0.2);
        border-radius: 3px;
    }
}

/* Ultra-Small Devices */
@media (max-width: 375px) {
    .kp-index-display {
        transform: scale(0.7);
    }

    h2 {
        font-size: 1.4rem !important;
    }

    .data-sources {
        font-size: 0.7rem !important;
    }
}

/* High Contrast and Accessibility */
@media (prefers-contrast: high) {
    .weather-panel {
        border: 2px solid var(--accent-color);
    }

    h2, h3, h4 {
        text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
    }
}

