/**
 * ═══════════════════════════════════════════════════════════════════════════
 * STANSHARE - STARRY SPACE THEME (SITE-WIDE)
 * ═══════════════════════════════════════════════════════════════════════════
 *
 * Deep space background with animated stars - consistent across all pages
 * Inspired by the globe animation's beautiful night sky
 *
 * CREATED: January 18, 2026
 * ═══════════════════════════════════════════════════════════════════════════
 */

/* ═════════════════ BASE THEME ═════════════════ */
html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background: linear-gradient(180deg, #000000 0%, #0a0e27 30%, #000814 70%, #000000 100%);
    background-attachment: fixed;
    color: #ffffff;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    position: relative;
    overflow-x: hidden;
}

/* ═════════════════ ANIMATED STARFIELD ═════════════════ */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    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% 95%, white, transparent),
        radial-gradient(1px 1px at 10% 40%, white, transparent),
        radial-gradient(2px 2px at 40% 80%, white, transparent);
    background-size: 200% 200%;
    background-position: 0% 0%;
    animation: stars-move 120s linear infinite;
    opacity: 0.6;
    pointer-events: none;
}

/* ═════════════════ TWINKLING STARS ═════════════════ */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-image: 
        radial-gradient(1px 1px at 25% 25%, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 75% 75%, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 15% 85%, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 85% 15%, rgba(255,255,255,0.8), transparent);
    background-size: 300% 300%;
    background-position: 0% 0%;
    animation: stars-twinkle 4s ease-in-out infinite;
    opacity: 0.4;
    pointer-events: none;
}

@keyframes stars-move {
    from {
        background-position: 0% 0%;
    }
    to {
        background-position: 100% 100%;
    }
}

@keyframes stars-twinkle {
    0%, 100% {
        opacity: 0.3;
    }
    50% {
        opacity: 0.7;
    }
}

/* ═════════════════ STATIC TWINKLING STARS (GOOGLE EARTH STYLE) ═════════════════ */
.shooting-star {
    position: fixed;
    width: 2px;
    height: 2px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 0 4px 1px rgba(255, 255, 255, 0.5);
    animation: twinkle-star 3s ease-in-out infinite;
    z-index: -1;
}

/* Distribute stars across the screen */
.shooting-star:nth-child(1) {
    top: 15%;
    left: 10%;
    animation-delay: 0s;
}

.shooting-star:nth-child(2) {
    top: 35%;
    left: 75%;
    animation-delay: 1s;
}

.shooting-star:nth-child(3) {
    top: 65%;
    left: 25%;
    animation-delay: 2s;
}

/* Twinkle animation - stars stay in place but fade in/out */
@keyframes twinkle-star {
    0%, 100% {
        opacity: 0.3;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.2);
    }
}

/* ═════════════════ LIQUID GLASS CARDS ═════════════════ */
.glass-card {
    background: rgba(10, 14, 39, 0.3);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    box-shadow:
        0 4px 20px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    color: #ffffff;
}

.glass-card:hover {
    background: rgba(10, 14, 39, 0.5);
    border-color: rgba(0, 212, 255, 0.2);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* ═════════════════ GLASS BUTTONS ═════════════════ */
.glass-button {
    background: rgba(0, 212, 255, 0.15);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 12px;
    color: #ffffff;
    padding: 12px 24px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 212, 255, 0.2);
}

.glass-button:hover {
    background: rgba(0, 212, 255, 0.25);
    border-color: rgba(0, 212, 255, 0.5);
    box-shadow: 0 6px 20px rgba(0, 212, 255, 0.4);
    transform: translateY(-1px);
}

/* ═════════════════ NEBULA GRADIENT ACCENTS ═════════════════ */
.nebula-gradient {
    background: linear-gradient(135deg, 
        rgba(0, 212, 255, 0.2) 0%,
        rgba(157, 78, 221, 0.2) 50%,
        rgba(255, 0, 110, 0.2) 100%
    );
}

/* ═════════════════ CONTENT SECTIONS ═════════════════ */
section {
    position: relative;
    z-index: 1;
}

/* ═════════════════ TEXT COLORS (FORCE WHITE) ═════════════════ */
h1, h2, h3, h4, h5, h6 {
    color: #ffffff !important;
}

p, span, div, a, li, label, input, select, textarea, button {
    color: #ffffff !important;
}

a {
    text-decoration: none;
}

a:hover {
    color: #ffffff !important;
}

/* Force white text on all interactive elements */
.btn, button, .button, input[type="button"], input[type="submit"] {
    color: #ffffff !important;
}

/* Override cyan colors to white */
.text-cyan, .text-primary {
    color: #ffffff !important;
}

/* Section titles and headers */
.section-title, .page-title, .card-title, .panel-title {
    color: #ffffff !important;
}

/* Filter and form labels */
.filter-label, .form-label, .input-label {
    color: #ffffff !important;
}

/* Statistics and metrics */
.stat-value, .metric-value, .stat-label, .metric-label {
    color: #ffffff !important;
}

/* Panel headers */
.panel-header, .sidebar-header, .filter-header {
    color: #ffffff !important;
}

/* ═════════════════ RESPONSIVE ADJUSTMENTS ═════════════════ */
@media (max-width: 768px) {
    body::before,
    body::after {
        background-size: 300% 300%;
    }
}

/* ═════════════════ ACCESSIBILITY ═════════════════ */
@media (prefers-reduced-motion: reduce) {
    body::before,
    body::after,
    .shooting-star {
        animation: none !important;
    }
}

/* ═════════════════ PRINT STYLES ═════════════════ */
@media print {
    body::before,
    body::after,
    .shooting-star {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
}
