:root {
    --cyber-green: #00ff41;
    --cyber-red: #ff0055;
    --cyber-blue: #00d4ff;
    --cyber-purple: #9d00ff;
    --matrix-white: #e0ffe0;
    --deep-black: #000000;
    --matrix-glow: rgba(0, 255, 65, 0.3);
}

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

body {
    font-family: 'Courier New', 'Consolas', monospace;
    background: radial-gradient(ellipse at center, #001a00 0%, var(--deep-black) 100%);
    color: var(--matrix-white);
    overflow: hidden;
    height: 100vh;
    cursor: grab;
}

body.grabbing {
    cursor: grabbing;
}

/* Background Stars */
#stars-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

/* Globe Canvas */
#globe-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

/* Intro Overlay */
#intro-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, rgba(0, 26, 0, 0.98) 0%, rgba(0, 0, 0, 0.99) 100%);
    backdrop-filter: blur(15px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

#intro-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.matrix-rain {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 255, 65, 0.03) 2px,
        rgba(0, 255, 65, 0.03) 4px
    );
    animation: rain 20s linear infinite;
    opacity: 0.3;
    pointer-events: none;
}

@keyframes rain {
    0% { transform: translateY(-100%); }
    100% { transform: translateY(100%); }
}

.intro-content {
    text-align: center;
    padding: 3rem;
    max-width: 800px;
    position: relative;
    z-index: 1;
}

.intro-text {
    background: rgba(0, 0, 0, 0.6);
    padding: 3rem;
    border-radius: 20px;
    border: 1px solid rgba(0, 255, 65, 0.2);
    box-shadow: 0 0 40px rgba(0, 255, 65, 0.1),
                inset 0 0 40px rgba(0, 255, 65, 0.05);
    backdrop-filter: blur(10px);
}

.glitch-text {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 900;
    margin-bottom: 0.5rem;
    color: var(--cyber-green);
    text-shadow: 
        0 0 10px var(--cyber-green),
        0 0 20px var(--cyber-green),
        0 0 40px rgba(0, 255, 65, 0.5),
        2px 2px 0 var(--cyber-blue),
        -2px -2px 0 var(--cyber-red);
    letter-spacing: 0.1em;
    animation: glitchText 5s infinite;
    position: relative;
}

@keyframes glitchText {
    0%, 90%, 100% { 
        text-shadow: 
            0 0 10px var(--cyber-green),
            0 0 20px var(--cyber-green),
            0 0 40px rgba(0, 255, 65, 0.5);
    }
    92% {
        text-shadow: 
            0 0 10px var(--cyber-green),
            0 0 20px var(--cyber-green),
            2px 2px 0 var(--cyber-blue),
            -2px -2px 0 var(--cyber-red);
        transform: translate(2px, -2px);
    }
    94% {
        text-shadow: 
            0 0 10px var(--cyber-green),
            0 0 20px var(--cyber-green),
            -2px -2px 0 var(--cyber-blue),
            2px 2px 0 var(--cyber-red);
        transform: translate(-2px, 2px);
    }
}

.subtitle {
    font-size: clamp(1rem, 2vw, 1.3rem);
    margin-bottom: 2.5rem;
    opacity: 0.9;
    color: var(--cyber-green);
    font-weight: 400;
    letter-spacing: 0.05em;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin: 2rem 0 2.5rem;
    padding: 1.5rem;
    background: rgba(0, 255, 65, 0.03);
    border-radius: 15px;
    border: 1px solid rgba(0, 255, 65, 0.15);
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 12px;
    border: 1px solid rgba(0, 255, 65, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-item:hover {
    transform: translateY(-3px);
    border-color: var(--cyber-green);
    box-shadow: 0 5px 20px rgba(0, 255, 65, 0.2);
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--cyber-green);
    text-shadow: 0 0 10px var(--cyber-green);
    line-height: 1;
}

.stat-label {
    font-size: 0.85rem;
    opacity: 0.7;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.cyber-button {
    background: linear-gradient(135deg, rgba(0, 255, 65, 0.1) 0%, rgba(0, 255, 65, 0.05) 100%);
    border: 2px solid var(--cyber-green);
    color: var(--cyber-green);
    padding: 1rem 3rem;
    font-size: 1.1rem;
    font-family: inherit;
    border-radius: 0;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px var(--matrix-glow), inset 0 0 20px transparent;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
}

.cosmic-button:hover {
    background: var(--cyber-green);
    color: black;
    transform: scale(1.05);
    box-shadow: 0 0 30px var(--cyber-green), inset 0 0 10px rgba(0, 255, 65, 0.5);
}

/* Cyber Button Styles */
.cyber-button {
    background: linear-gradient(135deg, rgba(0, 255, 65, 0.1) 0%, rgba(0, 255, 65, 0.05) 100%);
    border: 2px solid var(--cyber-green);
    color: var(--cyber-green);
    padding: 1.2rem 3rem;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-weight: 800;
    position: relative;
    overflow: hidden;
    border-radius: 50px;
    box-shadow: 0 4px 15px rgba(0, 255, 65, 0.2),
                inset 0 0 20px rgba(0, 255, 65, 0.1);
    font-family: inherit;
}

.button-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    position: relative;
    z-index: 2;
}

.button-icon {
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.button-text {
    font-weight: 800;
}

.button-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(0, 255, 65, 0.4) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    transition: all 0.5s ease;
    z-index: 1;
    border-radius: 50%;
}

.cyber-button:hover .button-glow,
.cyber-button:focus .button-glow {
    width: 300px;
    height: 300px;
}

.cyber-button:hover,
.cyber-button:focus {
    background: linear-gradient(135deg, rgba(0, 255, 65, 0.2) 0%, rgba(0, 255, 65, 0.1) 100%);
    border-color: var(--cyber-green);
    box-shadow: 0 0 30px rgba(0, 255, 65, 0.4),
                0 0 60px rgba(0, 255, 65, 0.2),
                inset 0 0 30px rgba(0, 255, 65, 0.1);
    transform: translateY(-2px);
}

.cyber-button:hover .button-icon {
    transform: translateX(5px);
}

.cyber-button:active {
    transform: translateY(0);
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.3),
                inset 0 0 20px rgba(0, 255, 65, 0.15);
}

.hint {
    font-size: 0.9rem;
    opacity: 0.6;
    font-style: italic;
}

/* Info Panel */
.info-panel {
    position: fixed;
    top: 50%;
    right: 2rem;
    transform: translateY(-50%);
    background: linear-gradient(135deg, rgba(0, 10, 5, 0.95) 0%, rgba(10, 1, 24, 0.95) 100%);
    backdrop-filter: blur(25px);
    border: 2px solid var(--cyber-green);
    border-radius: 20px;
    padding: 0;
    width: 450px;
    max-height: 85vh;
    z-index: 100;
    box-shadow: 0 0 60px rgba(0, 255, 65, 0.3),
                0 20px 60px rgba(0, 0, 0, 0.5),
                inset 0 0 30px rgba(0, 255, 65, 0.05);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 1;
    pointer-events: all;
}

.info-panel.hidden {
    opacity: 0;
    transform: translateY(-50%) translateX(120%);
    pointer-events: none;
}

.panel-header {
    padding: 2rem 2rem 1.5rem;
    border-bottom: 1px solid rgba(0, 255, 65, 0.2);
    background: rgba(0, 255, 65, 0.03);
    border-radius: 18px 18px 0 0;
}

.panel-header h2 {
    margin: 0 0 1rem;
    font-size: 1.8rem;
    color: var(--cyber-green);
    text-shadow: 0 0 10px rgba(0, 255, 65, 0.5);
}

.panel-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.panel-tag {
    background: rgba(0, 255, 65, 0.1);
    border: 1px solid rgba(0, 255, 65, 0.3);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--cyber-green);
}

.panel-body {
    padding: 2rem;
    overflow-y: auto;
    max-height: calc(85vh - 150px);
}

.panel-body::-webkit-scrollbar {
    width: 8px;
}

.panel-body::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 4px;
}

.panel-body::-webkit-scrollbar-thumb {
    background: var(--cyber-green);
    border-radius: 4px;
}

.panel-body::-webkit-scrollbar-thumb:hover {
    background: var(--cyber-blue);
}

.panel-body a {
    color: var(--cyber-blue);
    text-decoration: none;
    position: relative;
    padding: 0.3rem 0.6rem;
    border-radius: 8px;
    background: rgba(0, 212, 255, 0.05);
    border: 1px solid rgba(0, 212, 255, 0.2);
    display: inline-block;
    margin: 0.2rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 600;
}

.panel-body a::before {
    content: '→';
    margin-right: 0.5rem;
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s ease;
}

.panel-body a:hover,
.panel-body a:focus {
    color: var(--cyber-green);
    background: rgba(0, 255, 65, 0.15);
    border-color: var(--cyber-green);
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.3),
                inset 0 0 10px rgba(0, 255, 65, 0.1);
    transform: translateX(5px);
}

.panel-body a:hover::before {
    opacity: 1;
    transform: translateX(0);
}

.close-button {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: rgba(255, 0, 85, 0.1);
    border: 2px solid rgba(255, 0, 85, 0.3);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cyber-red);
    font-size: 1.3rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
}

.close-button:hover,
.close-button:focus {
    background: rgba(255, 0, 85, 0.2);
    border-color: var(--cyber-red);
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 0 20px rgba(255, 0, 85, 0.5);
}

.close-icon {
    font-weight: 700;
}

#panel-title {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--cyber-green);
    text-shadow: 0 0 10px var(--cyber-green);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

#panel-content {
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
}

#panel-content p {
    margin-bottom: 1rem;
}

#panel-content ul {
    list-style: none;
    padding-left: 0;
}

#panel-content li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
}

#panel-content li:before {
    content: "✦";
    position: absolute;
    left: 0;
    color: var(--cosmic-purple);
}

#panel-content a {
    color: var(--cosmic-blue);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

#panel-content a:hover {
    border-bottom-color: var(--cosmic-blue);
}

/* Legend */
.legend {
    position: fixed;
    bottom: 2rem;
    left: 2rem;
    background: rgba(10, 1, 24, 0.8);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 1.5rem;
    z-index: 100;
}

.legend h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
    opacity: 0.8;
    font-weight: 400;
    letter-spacing: 0.05em;
}

.legend-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
}

.legend-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 0.75rem;
    box-shadow: 0 0 10px currentColor;
}

.legend-dot.projects {
    background: var(--cyber-green);
}

.legend-dot.skills {
    background: var(--cyber-blue);
}

.legend-dot.achievements {
    background: var(--cyber-red);
}

.legend-dot.connections {
    background: var(--cyber-purple);
}

/* Controls */
.controls {
    position: fixed;
    top: 2rem;
    right: 2rem;
    display: flex;
    gap: 0.8rem;
    z-index: 100;
}

.control-button {
    background: linear-gradient(135deg, rgba(0, 10, 5, 0.9) 0%, rgba(10, 1, 24, 0.9) 100%);
    backdrop-filter: blur(20px);
    border: 2px solid rgba(0, 255, 65, 0.3);
    color: var(--cyber-green);
    width: 56px;
    height: 56px;
    border-radius: 16px;
    font-size: 1.4rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3),
                inset 0 0 20px rgba(0, 255, 65, 0.05);
}

.control-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(0, 255, 65, 0.3) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    transition: all 0.4s ease;
    border-radius: 50%;
}

.control-button:hover::before {
    width: 100px;
    height: 100px;
}

.control-button:hover {
    background: linear-gradient(135deg, rgba(0, 255, 65, 0.15) 0%, rgba(0, 255, 65, 0.1) 100%);
    border-color: var(--cyber-green);
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.4),
                0 6px 20px rgba(0, 0, 0, 0.4),
                inset 0 0 20px rgba(0, 255, 65, 0.1);
}

.control-button.active {
    background: linear-gradient(135deg, rgba(0, 255, 65, 0.2) 0%, rgba(0, 255, 65, 0.15) 100%);
    border-color: var(--cyber-green);
    box-shadow: 0 0 25px rgba(0, 255, 65, 0.5),
                inset 0 0 25px rgba(0, 255, 65, 0.15);
}

.control-button:active {
    transform: translateY(0);
}

.control-icon {
    position: relative;
    z-index: 2;
    transition: transform 0.3s ease;
}

.control-button:hover .control-icon {
    transform: scale(1.1);
}

.control-button[title]::after {
    content: attr(title);
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: rgba(0, 0, 0, 0.95);
    color: var(--cyber-green);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 255, 65, 0.3);
    font-family: 'Courier New', monospace;
    letter-spacing: 0.05em;
}

.control-button:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Animations */
@keyframes matrixGlitch {
    0%, 100% {
        text-shadow: 0 0 10px var(--cyber-green), 0 0 20px var(--cyber-green);
        opacity: 1;
    }
    25% {
        text-shadow: -2px 0 10px var(--cyber-green), 2px 0 20px var(--cyber-red);
        opacity: 0.95;
    }
    50% {
        text-shadow: 0 0 10px var(--cyber-green), 0 0 20px var(--cyber-green);
        opacity: 1;
    }
    75% {
        text-shadow: 2px 0 10px var(--cyber-green), -2px 0 20px var(--cyber-blue);
        opacity: 0.95;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.8;
    }
}

@keyframes twinkle {
    0%, 100% {
        opacity: 0.3;
    }
    50% {
        opacity: 1;
    }
}

/* Scrollbar Styling */
.info-panel::-webkit-scrollbar {
    width: 8px;
}

.info-panel::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.info-panel::-webkit-scrollbar-thumb {
    background: rgba(107, 70, 193, 0.5);
    border-radius: 10px;
}

.info-panel::-webkit-scrollbar-thumb:hover {
    background: rgba(107, 70, 193, 0.7);
}

/* Loading Indicator */
#loading-indicator .loader-spinner {
    border: 4px solid rgba(0, 255, 65, 0.1);
    border-top: 4px solid var(--cyber-green);
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Skip Link for Accessibility */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--cyber-green);
    color: black;
    padding: 8px;
    text-decoration: none;
    z-index: 100;
    font-family: inherit;
}

.skip-link:focus {
    top: 0;
}

/* Focus Indicators */
button:focus-visible,
a:focus-visible,
canvas:focus-visible {
    outline: 3px solid var(--cyber-green);
    outline-offset: 3px;
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    body {
        background: #000;
    }
    
    .legend, .info-panel, .controls button {
        border: 2px solid var(--cyber-green);
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Large Desktop Screens (1920px+) */
@media (min-width: 1920px) {
    .intro-content {
        max-width: 1000px;
    }
    
    .intro-text {
        padding: 4rem;
    }
    
    .glitch-text {
        font-size: 4.5rem;
    }
    
    .subtitle {
        font-size: 1.6rem;
    }
    
    .stats-grid {
        gap: 2rem;
        padding: 2rem;
    }
    
    .stat-value {
        font-size: 3.5rem;
    }
    
    .cyber-button {
        padding: 1.5rem 4rem;
        font-size: 1.3rem;
    }
    
    .info-panel {
        width: 550px;
        max-height: 90vh;
    }
    
    .control-button {
        width: 64px;
        height: 64px;
        font-size: 1.6rem;
    }
}

/* Tablet & Small Laptop (768px - 1024px) */
@media (max-width: 1024px) and (min-width: 769px) {
    .intro-text {
        padding: 2.5rem;
    }
    
    .glitch-text {
        font-size: 3rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
    
    .info-panel {
        width: 400px;
    }
}

/* Mobile & Small Tablet (up to 768px) */
@media (max-width: 768px) {
    .intro-text {
        padding: 2rem 1.5rem;
        border-radius: 15px;
    }
    
    .glitch-text {
        font-size: 1.8rem;
        letter-spacing: 0.05em;
    }
    
    .subtitle {
        font-size: 0.95rem;
        margin-bottom: 2rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 1rem;
        margin: 1.5rem 0 2rem;
    }
    
    .stat-value {
        font-size: 2rem;
    }
    
    .stat-label {
        font-size: 0.75rem;
    }
    
    .cyber-button {
        padding: 1rem 2rem;
        font-size: 0.9rem;
        border-radius: 40px;
    }
    
    .button-icon {
        font-size: 1rem;
    }
    
    .controls {
        top: 0.5rem;
        right: 0.5rem;
        gap: 0.4rem;
        flex-wrap: wrap;
        max-width: calc(100% - 1rem);
    }
    
    .control-button {
        width: 44px;
        height: 44px;
        font-size: 1.1rem;
        border-radius: 12px;
    }
    
    .control-button[title]::after {
        display: none; /* Hide tooltips on mobile */
    }
    
    .info-panel {
        right: 0.5rem;
        left: 0.5rem;
        bottom: 0;
        top: auto;
        transform: translateY(0);
        width: auto;
        max-height: 70vh;
        border-radius: 15px 15px 0 0;
        z-index: 1000;
        box-shadow: 0 -4px 30px rgba(0, 255, 65, 0.4),
                    0 -10px 60px rgba(0, 0, 0, 0.8);
    }
    
    .info-panel.hidden {
        transform: translateY(100%);
        opacity: 0;
    }
    
    .panel-header {
        padding: 1.5rem 1.5rem 1rem;
    }
    
    .panel-header h2 {
        font-size: 1.3rem;
        margin-right: 2rem;
    }
    
    .panel-tags {
        flex-wrap: wrap;
        gap: 0.4rem;
    }
    
    .panel-tag {
        font-size: 0.7rem;
        padding: 0.3rem 0.8rem;
    }
    
    .panel-body {
        padding: 1.5rem;
        max-height: calc(70vh - 120px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .close-button {
        width: 36px;
        height: 36px;
        top: 1rem;
        right: 1rem;
        font-size: 1.1rem;
    }
}

/* Small Mobile (up to 480px) */
@media (max-width: 480px) {
    .intro-text {
        padding: 1.5rem 1rem;
    }
    
    .glitch-text {
        font-size: 1.5rem;
    }
    
    .subtitle {
        font-size: 0.85rem;
    }
    
    .stats-grid {
        gap: 0.8rem;
        padding: 0.8rem;
    }
    
    .stat-item {
        padding: 0.8rem;
    }
    
    .stat-value {
        font-size: 1.8rem;
    }
    
    .cyber-button {
        padding: 0.9rem 1.5rem;
        font-size: 0.85rem;
    }
    
    .control-button {
        width: 40px;
        height: 40px;
        font-size: 1rem;
        border-radius: 10px;
    }
    
    .info-panel {
        right: 0;
        left: 0;
        border-radius: 15px 15px 0 0;
        max-height: 75vh;
        z-index: 1000;
    }
    
    .panel-header h2 {
        font-size: 1.1rem;
    }
    
    .panel-body {
        padding: 1rem;
        font-size: 0.9rem;
        max-height: calc(75vh - 100px);
        overflow-y: auto;
    }
}

/* Touch Target Optimization for Mobile */
@media (hover: none) and (pointer: coarse) {
    .control-button {
        min-width: 48px;
        min-height: 48px;
    }
    
    .close-btn {
        min-width: 48px;
        min-height: 48px;
    }
    
    .cosmic-button {
        min-height: 48px;
        padding: 1rem 3rem;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .celestial-title {
        font-size: 2.5rem;
    }

    .legend {
        bottom: 1rem;
        left: 1rem;
        padding: 1rem;
        font-size: 0.8rem;
    }

    .info-panel {
        right: 1rem;
        left: 1rem;
        max-width: none;
        padding: 1.5rem;
    }

    .controls {
        top: 1rem;
        right: 1rem;
    }

    .control-btn {
        width: 48px;
        height: 48px;
        font-size: 1.2rem;
    }
}

/* Print Styles */
@media print {
    body {
        background: white;
        color: black;
    }
    
    #intro-overlay,
    #controls,
    .control-btn,
    #stars-bg {
        display: none !important;
    }
    
    .info-panel {
        position: static;
        background: white;
        color: black;
        border: 1px solid black;
    }
}
