@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;700&display=swap');

body {
    font-family: 'Roboto', sans-serif;
    background-color: #000000;
    margin: 0;
    overflow: hidden;
    touch-action: none;
}
/* Enhanced Starfield Styles */
#starfield {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.star {
    position: absolute;
    background-color: white;
    border-radius: 50%;
    animation: twinkle var(--duration) infinite ease-in-out;
    opacity: 0;
}

/* Different star sizes */
.small-star { width: 1px; height: 1px; }
.medium-star{ width:2px; height: 2px; }
.large-star { width: 3px; height: 3px; }

/* Twinkling animation with different speeds */
@keyframes twinkle {
    0%, 100% { opacity: 0.1; }
    50% { opacity: var(--opacity); }
}

/* Shooting stars */
.shooting-star {
    position: absolute;
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, rgba(255,255,255,0) 0%, white 50%, rgba(255,255,255,0) 100%);
    transform-origin: left center;
    animation: shoot var(--shoot-duration) linear infinite;
    opacity: 0;
}

@keyframes shoot {
    0% { 
        transform: translateX(0) rotate(var(--angle));
        opacity: 0;
    }
    10% { opacity: 1; }
    90% { opacity: 1; }
    100% { 
        transform: translateX(var(--distance)) rotate(var(--angle));
        opacity: 0;
    }
}

/* Constellation effects */
.constellation {
    position: absolute;
    width: 1px;
    height: 1px;
    background-color: rgba(173, 216, 230, 0.7);
    border-radius: 50%;
    box-shadow: 0 0 5px 1px rgba(173, 216, 230, 0.7);
    animation: pulse 4s infinite alternate;
}

@keyframes pulse {
    0% { opacity: 0.3; box-shadow: 0 0 3px 1px rgba(173, 216, 230, 0.3); }
    100% { opacity: 0.8; box-shadow: 0 0 10px 2px rgba(173, 216, 230, 0.7); }
}

/* Elegant Loader Animation */
.loader-globe {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 3px solid #4a5568;
    border-top-color: #63b3ed;
    animation: spin 1.5s linear infinite;
    position: relative;
}

.loader-globe::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px dashed #4a5568;
    animation: spin-reverse 3s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes spin-reverse {
    to { transform: rotate(-360deg); }
}

/* Country info panel animations */
.info-panel-entry {
    animation: fadeInUp 0.5s ease-out forwards;
    opacity: 0;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile specific adjustments */
@media (max-width: 640px) {
    #search-container {
        width: 150px;
    }
    
    #search-box {
        font-size: 0.8rem;
        padding: 0.25rem 0.5rem;
    }
    
    #info-panel {
        width: 90%;
        padding: 1rem;
    }
    
    #panel-content {
        font-size: 0.9rem;
    }
    
    .info-panel-entry {
        margin-bottom: 0.75rem;
    }
}
