/* Root Variables */
:root {
    --primary-color: #4a5fc1;
    --primary-dark: #3a4fa0;
    --secondary-color: #6366f1;
    --accent-color: #818cf8;
    --dark-blue: #0f172a;
    --dark-blue-light: #1e293b;
    --night-sky: #0a0e27;
    --text-primary: #e2e8f0;
    --text-secondary: #cbd5e1;
    --text-muted: #94a3b8;
    --background-light: #1e293b;
    --background-white: #0f172a;
    --background-card: #1e293b;
    --border-light: #334155;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.5);
    --transition: all 0.3s ease;
}

/* Global Styles */
* {
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Lora', serif;
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.6;
    background-color: var(--background-white);
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    line-height: 1.3;
    margin: 0 0 1rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: var(--background-white);
    box-shadow: var(--shadow-sm);
    z-index: 1000;
    padding: 1rem 0;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-family: 'Montserrat', sans-serif;
    font-size: 24px;
    font-weight: 700;
    color: #ffffff;
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 2rem;
}

.nav-menu li a {
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.1em;
    color: var(--text-secondary);
    text-transform: uppercase;
    padding: 0.5rem 0;
    position: relative;
}

.nav-menu li a:hover {
    color: var(--primary-color);
}

.nav-menu li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-menu li a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero-section {
    position: relative;
    height: 600px;
    background-image: url('https://images.unsplash.com/photo-1419242902214-272b3f66ee7a?w=1600');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 60px;
    background-color: #0a0e27;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(10, 14, 39, 0.85), rgba(20, 25, 60, 0.85));
}

.hero-overlay::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(2px 2px at 20% 30%, white, transparent),
        radial-gradient(2px 2px at 60% 70%, white, transparent),
        radial-gradient(1px 1px at 50% 50%, white, transparent),
        radial-gradient(1px 1px at 80% 10%, white, transparent),
        radial-gradient(2px 2px at 90% 60%, white, transparent),
        radial-gradient(1px 1px at 33% 80%, white, transparent),
        radial-gradient(1px 1px at 15% 60%, white, transparent);
    background-size: 200% 200%, 200% 200%, 300% 300%, 250% 250%, 200% 200%, 280% 280%, 250% 250%;
    background-position: 0% 0%, 40% 40%, 50% 50%, 80% 10%, 0% 80%, 70% 20%, 15% 60%;
    opacity: 0.6;
    animation: twinkle 3s ease-in-out infinite;
}

@keyframes twinkle {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 0.8; }
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: white;
    max-width: 800px;
    padding: 0 20px;
}

.hero-content h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-content p {
    font-size: 18px;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.cta-button {
    display: inline-block;
    padding: 14px 32px;
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid white;
    border-radius: 4px;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    transition: var(--transition);
}

.cta-button:hover {
    background-color: white;
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

/* Quick Navigation */
.quick-nav {
    background-color: var(--background-white);
    padding: 2rem 0;
    box-shadow: var(--shadow-sm);
}

.quick-nav-items {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.quick-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.5rem;
    background-color: var(--background-light);
    border-radius: 8px;
    transition: var(--transition);
}

.quick-nav-item span {
    font-size: 40px;
    margin-bottom: 0.5rem;
}

.quick-nav-item h4 {
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    color: var(--text-primary);
}

.quick-nav-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    background-color: var(--primary-color);
    color: white;
}

.quick-nav-item:hover h4 {
    color: white;
}

/* Main Sections */
.main-section {
    padding: 62px 0;
    background-color: var(--background-light);
}

.main-section.bottom-padding {
    padding-bottom: 89px;
}

.section-title {
    font-size: 32px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.section-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 16px;
    margin-bottom: 3rem;
}

/* Featured Section */
.featured-section {
    background-color: var(--background-white);
}

.featured-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.featured-card {
    background-color: var(--background-card);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    display: block;
    border: 1px solid var(--border-light);
}

.featured-card.large {
    grid-column: 1;
    grid-row: 1 / 3;
}

.featured-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.card-image {
    position: relative;
    padding-top: 60%;
    background-size: cover;
    background-position: center;
    overflow: hidden;
}

.featured-card.large .card-image {
    padding-top: 100%;
}

.post-category {
    position: absolute;
    top: 16px;
    left: 16px;
    padding: 6px 12px;
    background-color: var(--primary-color);
    color: white;
    font-family: 'Montserrat', sans-serif;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 4px;
}

.card-content {
    padding: 1.5rem;
}

.card-content h3 {
    font-size: 24px;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.featured-card.large .card-content h3 {
    font-size: 28px;
}

.card-content p {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.card-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 13px;
    color: var(--text-muted);
    font-family: 'Montserrat', sans-serif;
}

.card-meta .author {
    font-weight: 500;
}

/* Planets Section */
.planets-section {
    background-color: var(--background-light);
}

.planets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 2rem;
}

.planet-card {
    background-color: var(--background-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    display: block;
}

.planet-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.planet-image {
    position: relative;
    padding-top: 100%;
    background-color: #000;
    overflow: hidden;
}

.planet-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.planet-info {
    padding: 1.5rem;
}

.planet-info h3 {
    font-size: 22px;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.planet-info p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Recent Posts Section */
.recent-posts {
    background-color: var(--background-light);
}

.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 2rem;
}

.post-card {
    background-color: var(--background-white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    display: block;
}

.post-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.post-image {
    position: relative;
    padding-top: 60%;
    background-size: cover;
    background-position: center;
}

.post-content {
    padding: 1.5rem;
}

.post-content h3 {
    font-size: 20px;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.post-content p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.post-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-muted);
    font-family: 'Montserrat', sans-serif;
}

.post-meta .author {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.post-meta .author img {
    width: 28px;
    height: 28px;
    border-radius: 50%;
}

/* Newsletter Section */
.newsletter-section {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    padding: 4rem 0;
}

.newsletter-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
    color: white;
}

.newsletter-content h2 {
    font-size: 36px;
    margin-bottom: 1rem;
}

.newsletter-content p {
    font-size: 16px;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.newsletter-form {
    display: flex;
    gap: 1rem;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-form input {
    flex: 1;
    padding: 14px 20px;
    border: none;
    border-radius: 4px;
    font-family: 'Lora', serif;
    font-size: 14px;
}

.newsletter-form button {
    padding: 14px 32px;
    background-color: rgba(0, 0, 0, 0.2);
    color: white;
    border: 2px solid white;
    border-radius: 4px;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.newsletter-form button:hover {
    background-color: white;
    color: var(--primary-color);
}

/* Footer */
.footer {
    background-color: #2d3748;
    color: #cbd5e0;
    padding: 3rem 0 1.5rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-brand h3 {
    font-size: 24px;
    color: white;
    margin-bottom: 0.5rem;
}

.footer-brand p {
    font-size: 14px;
    color: #a0aec0;
}

.footer-links {
    display: flex;
    gap: 3rem;
}

.footer-column h4 {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: white;
    margin-bottom: 1rem;
}

.footer-column ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-column ul li {
    margin-bottom: 0.5rem;
}

.footer-column ul li a {
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    color: #a0aec0;
    transition: var(--transition);
}

.footer-column ul li a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #4a5568;
}

.footer-bottom p {
    font-size: 13px;
    color: #a0aec0;
    margin: 0;
}

/* Responsive Design */
@media (max-width: 968px) {
    .nav-menu {
        display: none;
    }

    .hero-content h1 {
        font-size: 36px;
    }

    .hero-content p {
        font-size: 16px;
    }

    .featured-grid {
        grid-template-columns: 1fr;
    }

    .featured-card.large {
        grid-column: 1;
        grid-row: auto;
    }

    .planets-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1.5rem;
    }

    .posts-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .newsletter-form {
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    .hero-section {
        height: 400px;
    }

    .hero-content h1 {
        font-size: 28px;
    }

    .hero-content p {
        font-size: 14px;
    }

    .section-title {
        font-size: 26px;
    }

    .quick-nav-items {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .planets-grid {
        grid-template-columns: 1fr;
    }

    .newsletter-content h2 {
        font-size: 28px;
    }
}
/* Additional dark theme updates */

/* Planet cards */
.planet-card {
    background-color: var(--background-card);
    border: 1px solid var(--border-light);
}

/* Post cards */
.post-card {
    background-color: var(--background-card);
    border: 1px solid var(--border-light);
}

/* Newsletter darker background */
.newsletter-section {
    background: linear-gradient(135deg, #1e3a8a, #312e81);
}

/* Footer already dark, but ensure consistency */
.footer {
    background-color: #1e293b;
    border-top: 1px solid var(--border-light);
}

