html, body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    font-family: Arial, sans-serif;
    background-color: #000;
}

#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.loading-content {
    text-align: center;
    color: white;
}

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

#loading-text {
    font-size: 1.2em;
    color: #fff;
    font-family: Arial, sans-serif;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

#info {
    position: absolute;
    top: 10px;
    left: 10px;
    color: white;
    z-index: 100;
    text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.5);
}

#planet-info {
    position: absolute;
    bottom: 10px;
    left: 10px;
    color: white;
    z-index: 100;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 10px;
    border-radius: 5px;
    display: none;
}

canvas {
    display: block;
    background-color: #000;
}

#navbar {
    position: fixed;
    right: 0;
    top: 0;
    height: 100%;
    width: 250px;
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    transform: translateX(250px);
    transition: transform 0.3s ease-in-out;
}

#navbar.open {
    transform: translateX(0);
}

#toggle-navbar {
    position: absolute;
    left: -40px;
    top: 10px;
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    border: none;
    padding: 10px;
    cursor: pointer;
}

#navbar-content {
    padding: 20px;
    overflow-y: auto;
    height: calc(100% - 40px);  /* Adjust for padding */
}

#object-list {
    padding: 0;
}

#object-list .section {
    margin-bottom: 20px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    overflow: hidden;
}

#object-list .section-header {
    background-color: rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 10px;
    font-size: 1.1em;
    font-weight: bold;
    margin: 0;
}

#object-list ul {
    list-style-type: none;
    padding: 10px;
    margin: 0;
}

#object-list li {
    cursor: pointer;
    padding: 8px 10px;
    border-radius: 3px;
    transition: background-color 0.3s ease;
}

#object-list li:not(.mission-item):hover {
    background-color: rgba(52, 152, 219, 0.5);  /* Light blue background on hover */
    color: #fff;
}

#object-list .single-item {
    padding: 8px 10px;
    color: #ffd700;  /* Gold color for Sun */
    font-weight: bold;
    cursor: pointer;
}

#object-list .single-item:hover {
    background-color: rgba(255, 215, 0, 0.2);  /* Light gold background on hover */
}

/* Mission item specific styles */
.mission-item {
    display: flex !important;
    align-items: center;
    padding: 5px 10px !important;
    transition: background-color 0.3s ease;
}

.checkbox-wrapper {
    display: flex;
    align-items: center;
    cursor: pointer;
    width: 100%;
    padding: 5px 0;
}

.checkbox-wrapper input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border: 2px solid #666;
    border-radius: 3px;
    background-color: transparent;
    display: inline-block;
    position: relative;
    margin-right: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.checkbox-wrapper input[type="checkbox"]:checked {
    background-color: #3498db;
    border-color: #3498db;
}

.checkbox-wrapper input[type="checkbox"]:checked::after {
    content: '';
    position: absolute;
    left: 4px;
    top: 1px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.checkbox-wrapper label {
    cursor: pointer;
    flex-grow: 1;
    user-select: none;
    color: white;
    transition: color 0.3s ease;
}

.checkbox-wrapper:hover label {
    color: #3498db;
}

.checkbox-wrapper:hover input[type="checkbox"]:not(:checked) {
    border-color: #3498db;
}

/* Special colors for different sections */
#object-list .section:nth-child(1) .single-item { /* Sun */
    color: #ffd700;
}

#object-list .section:nth-child(3) .single-item { /* Pluto */
    color: #bb8e51;
}

/* Responsive design for smaller screens */
@media (max-width: 600px) {
    #navbar {
        width: 100%;
        transform: translateX(100%);
    }

    #navbar.open {
        transform: translateX(0);
    }

    #toggle-navbar {
        left: -50px;
    }

    .checkbox-wrapper {
        padding: 8px 0;
    }
}

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