:root {
    --netpin-accent: #ff00ff;
}

html,
body {
    font-family: sans-serif;
    margin: 0;
    padding: 0;
    height: 100%;
    overflow: hidden;
}

#map {
    width: 100%;
    height: 100%;
}

.leaflet-popup-content {
    font-family: sans-serif;
    max-height: 300px;
    overflow-y: auto;
    line-height: 1.4;
}

@media (max-width: 768px) {
    .leaflet-popup-content {
        width: 230px;
    }
}

#header {
    position: absolute;
    top: 10px;
    left: 55px;
    z-index: 1000;
    background: rgba(20, 20, 20, 0.92);
    color: white;
    padding: 10px 14px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(6px);
}

#title {
    font-size: 15px;
    font-weight: bold;
}

#stats {
    margin-top: 4px;
    font-size: 12px;
    color: var(--netpin-accent);
}

#search-container {
    position: relative;
    margin-top: 10px;
}

#search {
    width: 220px;
    box-sizing: border-box;
    padding: 8px 32px 8px 32px;
    border: none;
    border-radius: 8px;
    outline: none;
    background: rgba(255,255,255,0.12);
    color: white;
    font-size: 13px;
}

#search::placeholder {
    color: #bdbdbd;
}

#search-icon {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
}

#clear-search {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    display: none;
    user-select: none;
}

#clear-search.visible {
    display: block;
}

#qr-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.7);
    z-index: 5000;
    align-items: center;
    justify-content: center;
}

#qr-modal.visible {
    display: flex;
}

#qr-card {
    background: #ffffff;
    color: #111;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0,0,0,.4);
}

#qr-title {
    margin-bottom: 12px;
    font-size: 16px;
    font-weight: bold;
    color: #111;
    word-break: break-word;
}

.show-qr,
.copy-ssid,
.copy-password,
#qr-close {
    border: none;
    border-radius: 8px;
    background: var(--netpin-accent);
    color: white;
    font-weight: bold;
    cursor: pointer;
    transition: opacity .2s;
}

.show-qr,
.copy-ssid,
.copy-password {
    width: 100%;
    margin-top: 6px;
    padding: 6px 12px;
    font-size: 13px;
}

.show-qr:hover {
    opacity: .85;
}

#qr-close {
    margin-top: 16px;
    padding: 8px 16px;
}

#qr-close:hover {
    opacity: .85;
}

#toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(20,20,20,.95);
    color: white;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: bold;
    z-index: 6000;
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s;
}

#toast.visible {
    opacity: 1;
}
