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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #121417;
    color: #e0e6ed;
    overflow: hidden;
    width: 100vw;
    height: 100vh;
    user-select: none;
}

#map-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    cursor: grab;
    image-rendering: pixelated;
    background: radial-gradient(circle at center, #1e232a 0%, #101216 100%);
}

#map-canvas:active {
    cursor: grabbing;
}

/* Header & Controls */
.top-bar {
    position: absolute;
    top: 14px;
    left: 14px;
    right: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    pointer-events: none;
    z-index: 10;
}

.panel {
    background: rgba(22, 27, 34, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 8px 14px;
    pointer-events: auto;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.brand-icon {
    font-size: 20px;
}

.brand-title {
    font-weight: 700;
    font-size: 15px;
    letter-spacing: 0.5px;
    color: #4ade80;
}

.badge {
    background: #238636;
    color: #ffffff;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 20px;
    text-transform: uppercase;
}

.actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.btn {
    background: #21262d;
    color: #c9d1d9;
    border: 1px solid rgba(240, 246, 252, 0.1);
    border-radius: 6px;
    padding: 7px 12px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn:hover {
    background: #30363d;
    border-color: #8b949e;
    color: #ffffff;
}

.btn.primary {
    background: #238636;
    border-color: rgba(240, 246, 252, 0.1);
    color: #ffffff;
}

.btn.primary:hover {
    background: #2ea043;
}

.btn.active {
    background: #1f6feb;
    color: #ffffff;
    border-color: #58a6ff;
}

/* Floating Zoom / Center Controls */
.nav-controls {
    position: absolute;
    right: 14px;
    top: 75px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    z-index: 10;
}

.btn-icon {
    width: 38px;
    height: 38px;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 16px;
    font-weight: 700;
}

/* Inspector Tooltip */
.inspector-panel {
    position: absolute;
    bottom: 14px;
    left: 14px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 220px;
    z-index: 10;
}

.inspector-row {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
}

.inspector-label {
    color: #8b949e;
}

.inspector-value {
    font-weight: 600;
    color: #58a6ff;
    font-family: monospace;
}

.block-preview {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 2px;
    margin-right: 6px;
    vertical-align: middle;
}

/* Legend */
.legend-panel {
    position: absolute;
    bottom: 14px;
    right: 14px;
    display: flex;
    gap: 12px;
    font-size: 12px;
    color: #8b949e;
    z-index: 10;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 3px;
}

/* Drop Overlay */
#drop-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(13, 17, 23, 0.85);
    border: 3px dashed #58a6ff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

#drop-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

#drop-overlay h2 {
    color: #58a6ff;
    font-size: 24px;
    margin-bottom: 8px;
}

#drop-overlay p {
    color: #8b949e;
}
