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

body {
    font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
    background: #0a0a0f;
    color: #ffffff;
    overflow: hidden;
    height: 100vh;
    width: 100vw;
}

/* Globe Container */
#globeContainer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: grab;
}

#globeContainer:active {
    cursor: grabbing;
}

/* Tooltip */
#tooltip {
    position: fixed;
    background: rgba(13, 13, 13, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 12px;
    padding: 14px 18px;
    pointer-events: none;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.2s ease;
    min-width: 220px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5), 
                0 0 20px rgba(0, 212, 255, 0.1);
}

.tooltip-row {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 4px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.tooltip-row:last-child {
    border-bottom: none;
}

.tooltip-label {
    color: #a0a0a0;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tooltip-value {
    color: #ffffff;
    font-size: 12px;
    font-weight: 600;
    text-align: right;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tooltip-value.mono {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
}

/* UI Panel */
#uiPanel {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 320px;
    max-height: calc(100vh - 40px);
    background: rgba(13, 13, 13, 0.85);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 24px;
    z-index: 100;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

/* Panel Header */
.panel-header {
    text-align: center;
}

.logo-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.btc-icon {
    width: 48px;
    height: 48px;
    color: #f7931a;
    filter: drop-shadow(0 0 10px rgba(247, 147, 26, 0.5));
    animation: glow-pulse 3s ease-in-out infinite;
}

@keyframes glow-pulse {
    0%, 100% { filter: drop-shadow(0 0 10px rgba(247, 147, 26, 0.5)); }
    50% { filter: drop-shadow(0 0 20px rgba(247, 147, 26, 0.8)); }
}

.title-group {
    text-align: center;
}

h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: 24px;
    font-weight: 900;
    letter-spacing: 4px;
    background: linear-gradient(135deg, #f7931a 0%, #ffd700 50%, #f7931a 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
}

.subtitle {
    font-size: 11px;
    color: #888;
    margin-top: 4px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Stats Section */
.stats-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.stat-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 212, 255, 0.05);
    border: 1px solid rgba(0, 212, 255, 0.15);
    border-radius: 10px;
    padding: 12px 16px;
}

.stat-label {
    font-size: 10px;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stat-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 16px;
    font-weight: 600;
    color: #00d4ff;
    text-shadow: 0 0 10px rgba(0, 212, 255, 0.3);
}

/* Node Details */
.node-details {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    overflow: hidden;
}

.details-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    background: rgba(247, 147, 26, 0.1);
    border-bottom: 1px solid rgba(247, 147, 26, 0.2);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: #f7931a;
}

.details-icon {
    font-size: 14px;
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.details-content {
    padding: 16px;
}

.placeholder-message {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 20px;
    color: #666;
    font-size: 13px;
    text-align: center;
}

.pulse-ring {
    width: 40px;
    height: 40px;
    border: 2px solid rgba(0, 212, 255, 0.3);
    border-radius: 50%;
    animation: ring-pulse 2s ease-in-out infinite;
}

@keyframes ring-pulse {
    0% { transform: scale(0.8); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 1; }
    100% { transform: scale(0.8); opacity: 0.5; }
}

.detail-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.detail-row:last-of-type {
    border-bottom: none;
}

.detail-label {
    color: #888;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-value {
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    text-align: right;
    max-width: 180px;
    word-break: break-all;
}

.detail-value.mono {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
}

.detail-summary {
    margin-top: 14px;
    padding: 12px;
    background: rgba(247, 147, 26, 0.08);
    border-radius: 8px;
    font-size: 11px;
    color: #ccc;
    line-height: 1.5;
    border-left: 3px solid #f7931a;
}

/* Error Message */
.error-message {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px;
    background: rgba(255, 107, 107, 0.1);
    border: 1px solid rgba(255, 107, 107, 0.3);
    border-radius: 10px;
    color: #ff6b6b;
    font-size: 12px;
}

.error-message.hidden {
    display: none;
}

/* Panel Footer */
.panel-footer {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 11px;
    color: #666;
}

.panel-footer a {
    color: #00d4ff;
    text-decoration: none;
    transition: color 0.2s;
}

.panel-footer a:hover {
    color: #f7931a;
}

/* Loading Overlay */
#loadingOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #0a0a0f;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    transition: opacity 0.5s ease;
}

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

.btc-spinner {
    font-size: 64px;
    color: #f7931a;
    animation: spin 2s linear infinite;
    text-shadow: 0 0 30px rgba(247, 147, 26, 0.5);
}

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

.loading-content p {
    margin-top: 20px;
    font-size: 14px;
    color: #888;
    letter-spacing: 2px;
}

/* Easter Egg */
.easter-egg {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, rgba(247, 147, 26, 0.9), rgba(255, 215, 0, 0.9));
    color: #0a0a0f;
    padding: 20px 40px;
    border-radius: 50px;
    font-family: 'Orbitron', sans-serif;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 2px;
    z-index: 3000;
    animation: easter-pop 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    transition: opacity 0.5s ease;
}

@keyframes easter-pop {
    0% { transform: translate(-50%, -50%) scale(0); }
    100% { transform: translate(-50%, -50%) scale(1); }
}

/* Monospace utility */
.mono {
    font-family: 'JetBrains Mono', monospace;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    #uiPanel {
        top: auto;
        bottom: 0;
        right: 0;
        left: 0;
        width: 100%;
        max-height: 50vh;
        border-radius: 20px 20px 0 0;
        padding: 20px;
    }
    
    .stats-section {
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    .stat-card {
        flex: 1 1 calc(50% - 5px);
        min-width: 120px;
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
        padding: 10px 12px;
    }
    
    .stat-value {
        font-size: 14px;
    }
    
    h1 {
        font-size: 20px;
    }
    
    .btc-icon {
        width: 36px;
        height: 36px;
    }
}

@media (max-width: 480px) {
    #uiPanel {
        padding: 16px;
        gap: 14px;
    }
    
    .stat-card {
        flex: 1 1 100%;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

/* Scrollbar styling */
#uiPanel::-webkit-scrollbar {
    width: 6px;
}

#uiPanel::-webkit-scrollbar-track {
    background: transparent;
}

#uiPanel::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

#uiPanel::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}