:root {
    --space-dark-blue: #0a0e27;
    --space-blue: #1a1f3a;
    --space-light-blue: #2a2f4a;
    --moon-silver: #e8f4f8;
    --moon-gold: #ffd700;
    --moon-accent: #00d4ff;
    --moon-purple: #8a2be2;
    --space-black: #050505;
    --space-charcoal: #121212;
    --space-panel: rgba(12, 12, 12, 0.88);
    --space-border: rgba(255, 255, 255, 0.14);
    --space-text: #f5f5f5;
    --space-muted: #b6b6b6;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', Arial, sans-serif;
    background: radial-gradient(circle at top, #1a1a1a 0%, var(--space-black) 45%, #000 100%);
    color: var(--space-text);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.55;
    background-image:
        radial-gradient(2px 2px at 20px 30px, rgba(255, 255, 255, 0.9), transparent),
        radial-gradient(1px 1px at 40px 70px, rgba(255, 255, 255, 0.65), transparent),
        radial-gradient(1px 1px at 90px 40px, rgba(255, 255, 255, 0.8), transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(255, 255, 255, 0.5), transparent),
        radial-gradient(2px 2px at 160px 30px, rgba(255, 255, 255, 0.75), transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: stars 20s linear infinite;
    z-index: -1;
}

@keyframes stars {
    from { transform: translateY(0); }
    to { transform: translateY(-100px); }
}

.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

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

.top-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1100;
    background: rgba(0, 0, 0, 0.86);
    border-bottom: 1px solid var(--space-border);
    backdrop-filter: blur(12px);
    min-height: 74px;
    transition: background 0.25s ease, box-shadow 0.25s ease;
}

.nav-shell {
    max-width: 1440px;
    padding: 0.35rem 1rem;
}

.navbar-brand.brand-link {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    text-decoration: none;
}

.brand-wordmark {
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-size: 1.18rem;
    letter-spacing: 0.16em;
    color: var(--space-text);
    font-weight: 600;
}

.top-nav .sidebar-logo {
    height: 38px;
    width: auto;
    border-radius: 3px;
    filter: grayscale(10%) contrast(1.05);
    cursor: pointer;
    transition: transform 0.3s ease;
}

.top-nav .sidebar-logo:hover {
    transform: scale(1.05);
}

.main-nav-list .nav-link {
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-size: 0.95rem;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: var(--space-text) !important;
    margin: 0 0.25rem;
    padding: 0.7rem 0.55rem !important;
    border-bottom: 2px solid transparent;
    transition: color 0.2s ease, border-color 0.2s ease;
    position: relative;
}

.main-nav-list .nav-link:hover,
.main-nav-list .nav-link.active {
    color: #ffffff !important;
    border-bottom-color: #ffffff;
}

.main-nav-list .nav-link::before {
    content: '';
    position: absolute;
    left: 8%;
    right: 8%;
    top: 45%;
    height: 18px;
    border-radius: 999px;
    background: radial-gradient(
        ellipse at center,
        rgba(255, 255, 255, 0.62) 0%,
        rgba(255, 255, 255, 0.38) 42%,
        rgba(255, 255, 255, 0) 75%
    );
    filter: blur(8px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
}

.main-nav-list .nav-link:hover::before,
.main-nav-list .nav-link:focus-visible::before {
    opacity: 1;
}

.navbar-toggler {
    border-color: rgba(255, 255, 255, 0.45);
}

.main-content-wrapper {
    margin-left: 0;
    min-height: 100vh;
    padding-top: 88px;
}

.main-content {
    background: linear-gradient(180deg, rgba(20, 20, 20, 0.92), rgba(6, 6, 6, 0.92));
    border: 1px solid var(--space-border);
    border-radius: 14px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(8px);
    margin: 2rem auto;
    padding: 2rem;
    max-width: 1200px;
    position: relative;
    overflow: hidden;
}

.main-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
    animation: scan 3s ease-in-out infinite;
}

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

.hero-section {
    text-align: center;
    padding: 4rem 1rem 3rem;
    background: linear-gradient(180deg, rgba(18, 18, 18, 0.9), rgba(8, 8, 8, 0.92));
    border: 1px solid var(--space-border);
    border-radius: 14px;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.hero-section h1 {
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.hero-section p.lead {
    font-size: 1.15rem;
    color: var(--space-muted);
    max-width: 760px;
    margin: 0 auto 0.5rem;
}

.content-section {
    line-height: 1.8;
    color: #e7e7e7;
    position: relative;
    z-index: 1;
}

.content-section h1,
.content-section h2,
.content-section h3,
.hero-section h1,
.card-title,
.footer h6 {
    font-family: 'Barlow Condensed', Arial, sans-serif;
    letter-spacing: 0.05em;
}

.content-section h1 {
    font-size: 2.5rem;
    color: #fff;
    border-bottom: 2px solid rgba(255, 255, 255, 0.45);
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

.content-section h2 {
    font-size: 1.8rem;
    color: #fff;
    margin-top: 2rem;
}

.content-section h3 {
    font-size: 1.35rem;
    color: #fff;
    margin-top: 1.5rem;
}

.content-section p,
.content-section li {
    font-size: 1.05rem;
    margin-bottom: 1rem;
}

.content-section ul,
.content-section ol {
    padding-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.btn-moon {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.75);
    color: #fff;
    border-radius: 2px;
    text-transform: uppercase;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    letter-spacing: 0.11em;
    font-weight: 600;
    padding: 12px 28px;
    transition: all 0.3s ease;
}

.btn-moon:hover {
    background: rgba(255, 255, 255, 0.16);
    border-color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.14);
    color: #fff;
}

.card {
    background: var(--space-panel);
    border: 1px solid var(--space-border);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.32);
    box-shadow: 0 14px 26px rgba(0, 0, 0, 0.35);
}

.card-title {
    color: #fff;
    font-weight: 700;
}

.card-text {
    color: #d8d8d8;
}

.footer {
    background: rgba(0, 0, 0, 0.92);
    color: var(--space-text);
    padding: 2rem 0;
    margin-top: 3rem;
    border-top: 1px solid var(--space-border);
    border-radius: 14px 14px 0 0;
}

.social-icons {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 50%;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    border-color: #fff;
    color: #fff;
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.17);
}

.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.modal-content {
    background: rgba(12, 12, 12, 0.96);
    border: 1px solid var(--space-border);
    color: var(--space-text);
}

.logo-modal-image {
    max-height: 320px;
    width: auto;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--space-black);
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.35);
    border-radius: 4px;
}

@media (max-width: 768px) {
    .main-content {
        margin: 1rem;
        padding: 1.25rem;
    }

    .social-icons {
        justify-content: center;
        margin-top: 1rem;
    }

    .footer .col-md-6 {
        text-align: center !important;
    }

    .brand-wordmark {
        display: none;
    }
}

@media (min-width: 769px) {
    .brand-wordmark {
        display: inline;
    }
}
