:root {
    --bg: #060d18;
    --sidebar-bg: #080f1e;
    --cyan: #00c8ff;
    --cyan-dim: #0d3a52;
    --cyan-glow: rgba(0, 200, 255, 0.08);
    --text: #a8d4e8;
    --text-muted: #2e5f7a;
    --sidebar-w: 52px;
    --sidebar-w-open: 205px;
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    background: var(--bg);
    font-family: 'Space Grotesk', sans-serif;
    min-height: 100vh;
    overflow: hidden;
}

h1, h2, h3 {
    font-family: 'Space Grotesk', sans-serif;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(0, 200, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 200, 255, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: 0;
}

#sidebar {
    position: fixed;
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
    width: var(--sidebar-w);
    background: var(--sidebar-bg);
    border: 1px solid var(--cyan-dim);
    border-radius: 10px;
    overflow: hidden;
    transition: width 0.3s var(--ease);
    display: flex;
    flex-direction: column;
    padding: 8px 6px;
    gap: 2px;
    box-shadow:
        0 0 20px rgba(0, 0, 0, 0.8),
        0 0 0 1px rgba(0, 200, 255, 0.04),
        inset 0 1px 0 rgba(0, 200, 255, 0.06);
    z-index: 100;
}

#sidebar:hover {
    width: var(--sidebar-w-open);
}

@media (max-width: 768px) {
    #sidebar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        top: auto;
        transform: none;
        width: 100%;
        height: auto;
        border-radius: 10px 10px 0 0;
        flex-direction: row;
        flex-wrap: nowrap;
        justify-content: space-between;
        align-items: center;
        padding: 8px 4px;
        gap: 0;
        overflow: hidden;
    }

    #sidebar:hover {
        width: 100%;
    }

    .sidebar-btn {
        flex: 1 1 auto;
        padding: 8px 2px;
        min-width: 0;
        gap: 2px;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        height: 50px;
    }

    .btn-icon {
        width: 20px;
        height: 20px;
        font-size: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .btn-label {
        display: none;
        font-size: 0.35rem;
    }

    .sidebar-divider {
        display: none;
    }
}

.sidebar-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 9px 8px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 6px;
    color: var(--text-muted);
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.25s var(--ease), background 0.25s var(--ease), border-color 0.25s var(--ease);
    width: 100%;
}

#sidebar:hover .sidebar-btn {
    justify-content: flex-start;
    gap: 12px;
    padding: 9px 10px;
}

.sidebar-btn:hover {
    color: var(--cyan);
    background: var(--cyan-glow);
    border-color: var(--cyan-dim);
}


.btn-icon {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.btn-label {
    width: 0;
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.2s var(--ease);
}

#sidebar:hover .btn-label {
    width: auto;
    opacity: 1;
}

.sidebar-divider {
    height: 1px;
    background: var(--cyan-dim);
    opacity: 0.4;
    margin: 4px 2px;
}

/* #map-placeholder {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
} */

.cosmos-title {
    font-size: 0.65rem;
    letter-spacing: 0.4em;
    color: var(--text-muted);
    text-transform: uppercase;
    animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.9; }
}


.switch {
  position: relative;
  display: inline-block;
  width: 30px;
  height: 17px;
  border-radius: 20;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
  border-radius: 20;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 20;
}

.slider:before {
  position: absolute;
  content: "";
  height: 13px;
  width: 13px;
  left: 2px;
  bottom: 2px;
  background-color: #2196F3;
;
  transition: .4s;
  border-radius: 20;
}

input:checked + .slider {
  background-color: #2196F3;
  border-radius: 20;
}

input:checked + .slider:before {
  transform: translateX(13px);
  background-color: #ccc;
  border-radius: 20;
}

input[type="text"] {
    width: 100%;
    background: rgba(0, 200, 255, 0.04);
    border: 1px solid var(--cyan-dim);
    border-radius: 6px;
    padding: 0.6rem 0.75rem;
    color: var(--text);
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.65rem;
    letter-spacing: 0.05em;
    outline: none;
    transition: border-color 0.25s var(--ease), background 0.25s var(--ease), box-shadow 0.25s var(--ease);
    margin-bottom: 1rem;
}