:root {
	--bg: #fdf6fa;
	--surface: #ffffff;
	--surface-2: #f7eef5;
	--border: #f1e2ec;
	--text: #1a1240;
	--muted: #6e6787;
	--accent: #e8338f;
	--accent-2: #7b3df5;
	--accent-soft: #fde6f2;
	--on-accent: #ffffff;
	--online: #1fc46f;
	--danger: #e5484d;
	--grad: linear-gradient(90deg, #ff4fa3 0%, #d244e6 52%, #7b3df5 100%);
	--grad-text: linear-gradient(90deg, #ff2e93, #e040fb);
	--bubble-in: #ffffff;
	--bubble-out: linear-gradient(135deg, #ff4fa3, #9b3df5);
	--shadow: 0 2px 6px rgba(120, 40, 140, .05), 0 10px 30px rgba(120, 40, 140, .08);
	--shadow-lg: 0 24px 60px rgba(70, 20, 110, .22);
	--radius: 20px;
	--header-h: 72px;
	--nav-h: 64px;
	color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body.nc-body {
	background: var(--bg);
	color: var(--text);
	font: 15px/1.5 "Plus Jakarta Sans", Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	-webkit-font-smoothing: antialiased;
	min-height: 100vh;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent); text-decoration: none; }
svg[viewBox="0 0 24 24"] { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
[hidden] { display: none !important; }
.nc-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Header: state (left) + search (right) */
.nc-header {
	position: sticky; top: 0; z-index: 30;
	height: var(--header-h);
	display: flex; align-items: center; justify-content: space-between; gap: 12px;
	padding: 0 max(16px, calc((100vw - 1200px) / 2));
	background: color-mix(in srgb, var(--bg) 82%, transparent);
	backdrop-filter: saturate(1.6) blur(14px);
	-webkit-backdrop-filter: saturate(1.6) blur(14px);
	border-bottom: 1px solid var(--border);
}
.nc-state, .nc-search {
	display: flex; align-items: center; gap: 8px;
	height: 44px; padding: 0 14px;
	background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
	box-shadow: var(--shadow);
	transition: border-color .15s, box-shadow .15s;
}
.nc-state:focus-within, .nc-search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.nc-state { position: relative; max-width: 46%; color: var(--accent); }
.nc-state select {
	appearance: none; -webkit-appearance: none; border: 0; background: transparent; outline: 0;
	font-weight: 600; color: var(--text); padding-right: 22px; cursor: pointer;
	min-width: 0; width: 100%; text-overflow: ellipsis;
}
.nc-state select option { color: #14152b; background: #fff; }
.nc-state .nc-caret { position: absolute; right: 12px; width: 16px; height: 16px; color: var(--muted); pointer-events: none; }
.nc-search { flex: 0 1 380px; color: var(--muted); min-width: 0; }
.nc-search input { border: 0; outline: 0; background: transparent; width: 100%; min-width: 0; }
.nc-search input::-webkit-search-cancel-button { cursor: pointer; }

/* Main */
.nc-main { max-width: 1200px; margin: 0 auto; padding: 20px 16px calc(var(--nav-h) + 40px); outline: 0; }
.nc-boot { display: grid; place-items: center; min-height: 50vh; }
.nc-spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--border); border-top-color: var(--accent); animation: nc-spin .8s linear infinite; }
@keyframes nc-spin { to { transform: rotate(360deg); } }

.nc-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 4px 0 14px; flex-wrap: wrap; }
.nc-hero h1 { margin: 0; font-size: clamp(22px, 4vw, 30px); letter-spacing: -.02em; line-height: 1.15; }
.nc-hero p { margin: 4px 0 0; color: var(--muted); }
.nc-pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); font-weight: 600; font-size: 13px; white-space: nowrap; }
.nc-live { width: 8px; height: 8px; border-radius: 50%; background: var(--online); box-shadow: 0 0 0 0 rgba(25, 195, 125, .6); animation: nc-pulse 2s infinite; }
@keyframes nc-pulse { 70% { box-shadow: 0 0 0 8px rgba(25, 195, 125, 0); } 100% { box-shadow: 0 0 0 0 rgba(25, 195, 125, 0); } }

.nc-chips { display: flex; gap: 8px; margin-bottom: 18px; overflow-x: auto; scrollbar-width: none; }
.nc-chips::-webkit-scrollbar { display: none; }
.nc-chip { border: 1px solid var(--border); background: var(--surface); padding: 7px 14px; border-radius: 999px; font-weight: 600; font-size: 13px; cursor: pointer; white-space: nowrap; color: var(--muted); }
.nc-chip[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }

.nc-cta {
	display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
	padding: 18px 20px; margin-bottom: 18px; border-radius: var(--radius);
	background: linear-gradient(120deg, var(--accent), var(--accent-2)); color: #fff;
}
.nc-cta b { font-size: 17px; display: block; }
.nc-cta span { opacity: .9; font-size: 14px; }
.nc-cta .nc-btn { background: #fff; color: #3a2ccc; }

/* Grid of member cards */
.nc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
.nc-card {
	position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
	padding: 18px 16px 16px; display: flex; flex-direction: column; align-items: center; text-align: center;
	box-shadow: var(--shadow); cursor: pointer; transition: transform .15s, box-shadow .15s, border-color .15s;
	min-width: 0;
}
.nc-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); }
.nc-card:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.nc-card h3 { margin: 10px 0 0; font-size: 16px; font-weight: 700; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nc-card .nc-meta { color: var(--muted); font-size: 13px; margin-top: 2px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nc-card .nc-bio { color: var(--muted); font-size: 13px; margin: 8px 0 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.9em; }
.nc-card .nc-status { font-size: 12px; font-weight: 600; margin-top: 6px; color: var(--muted); }
.nc-card .nc-status.on { color: var(--online); }
.nc-card .nc-btn { margin-top: 12px; width: 100%; }

/* Avatar */
.nc-av { position: relative; flex: none; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: #fff; overflow: visible; }
.nc-av img, .nc-av .nc-ini { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: grid; place-items: center; }
.nc-av .nc-dot { position: absolute; right: 2%; bottom: 2%; width: 26%; height: 26%; min-width: 10px; min-height: 10px; border-radius: 50%; background: var(--online); border: 2.5px solid var(--surface); }
.nc-av-xl { width: 112px; height: 112px; font-size: 40px; }
.nc-av-lg { width: 84px; height: 84px; font-size: 30px; }
.nc-av-md { width: 48px; height: 48px; font-size: 18px; }
.nc-av-sm { width: 38px; height: 38px; font-size: 15px; }

/* Buttons & forms */
.nc-btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	height: 42px; padding: 0 18px; border-radius: 12px; border: 0; cursor: pointer; font-weight: 600;
	background: var(--accent); color: var(--on-accent); transition: filter .15s, transform .05s;
}
.nc-btn:hover { filter: brightness(1.07); }
.nc-btn:active { transform: scale(.98); }
.nc-btn:disabled { opacity: .55; cursor: default; }
.nc-btn.ghost { background: var(--surface-2); color: var(--text); }
.nc-btn.soft { background: var(--accent-soft); color: var(--accent); }
.nc-btn.danger { background: transparent; color: var(--danger); border: 1px solid color-mix(in srgb, var(--danger) 40%, transparent); }
.nc-btn.block { width: 100%; }
.nc-btn svg { width: 18px; height: 18px; }
.nc-icon-btn { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; border: 0; background: transparent; color: var(--text); cursor: pointer; }
.nc-icon-btn:hover { background: var(--surface-2); }

.nc-field { display: block; margin-bottom: 12px; }
.nc-field > span { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: var(--muted); }
.nc-input {
	width: 100%; height: 44px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--border);
	background: var(--surface); outline: 0; transition: border-color .15s, box-shadow .15s;
}
textarea.nc-input { height: auto; padding: 10px 14px; resize: vertical; min-height: 84px; }
.nc-input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.nc-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.nc-check { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--muted); margin: 4px 0 14px; }
.nc-check input { margin-top: 3px; accent-color: var(--accent); }
.nc-hp { position: absolute; left: -9999px; }
.nc-error { color: var(--danger); font-size: 13px; min-height: 18px; margin: 0 0 8px; }

/* Empty states */
.nc-empty { text-align: center; padding: 56px 20px; color: var(--muted); }
.nc-empty .nc-empty-ic { width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center; margin: 0 auto 14px; background: var(--accent-soft); color: var(--accent); }
.nc-empty .nc-empty-ic svg { width: 30px; height: 30px; }
.nc-empty h3 { margin: 0 0 6px; color: var(--text); }
.nc-empty p { margin: 0 auto 16px; max-width: 360px; }
.nc-more { display: grid; place-items: center; padding: 24px 0; }

/* Bottom nav */
.nc-nav {
	position: fixed; z-index: 40; left: 50%; transform: translateX(-50%);
	bottom: max(14px, env(safe-area-inset-bottom));
	display: flex; gap: 4px; padding: 6px; border-radius: 22px;
	background: color-mix(in srgb, var(--surface) 90%, transparent);
	backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
	border: 1px solid var(--border); box-shadow: var(--shadow-lg);
}
.nc-nav a {
	position: relative; display: flex; align-items: center; gap: 8px; height: 48px; padding: 0 18px; border-radius: 16px;
	color: var(--muted); font-weight: 600; font-size: 14px;
}
.nc-nav a.active { background: var(--accent); color: #fff; }
.nc-nav a:not(.active):hover { background: var(--surface-2); color: var(--text); }
.nc-nav-av { width: 24px; height: 24px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; }
.nc-nav-av img { width: 100%; height: 100%; object-fit: cover; }
.nc-badge { position: absolute; top: 4px; left: 30px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--danger); color: #fff; font-size: 11px; line-height: 18px; text-align: center; font-weight: 700; border: 2px solid var(--surface); box-sizing: content-box; }

/* Chats */
.nc-chats {
	display: grid; grid-template-columns: 340px 1fr; gap: 0;
	height: calc(100dvh - var(--header-h) - var(--nav-h) - 64px); min-height: 420px;
	background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
}
.nc-conv-list { border-right: 1px solid var(--border); display: flex; flex-direction: column; min-height: 0; }
.nc-pane-title { padding: 16px 18px 10px; font-size: 20px; font-weight: 800; letter-spacing: -.01em; }
.nc-conv-scroll { overflow-y: auto; flex: 1; padding: 0 8px 8px; }
.nc-conv { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 14px; cursor: pointer; color: var(--text); }
.nc-conv:hover { background: var(--surface-2); }
.nc-conv.active { background: var(--accent-soft); }
.nc-conv-body { flex: 1; min-width: 0; }
.nc-conv-top { display: flex; justify-content: space-between; gap: 8px; }
.nc-conv-top b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nc-conv-top time { font-size: 12px; color: var(--muted); flex: none; }
.nc-conv-bot { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.nc-conv-bot span { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nc-conv.unread .nc-conv-bot span { color: var(--text); font-weight: 600; }
.nc-count { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; flex: none; }

.nc-chat-pane { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--bg); }
.nc-chat-placeholder { flex: 1; display: grid; place-items: center; }
.nc-chat-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--surface); border-bottom: 1px solid var(--border); }
.nc-chat-head .nc-who { flex: 1; min-width: 0; cursor: pointer; }
.nc-chat-head .nc-who b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nc-chat-head .nc-who small { color: var(--muted); font-size: 12px; }
.nc-chat-head .nc-who small.on { color: var(--online); font-weight: 600; }
.nc-chat-head .nc-back { display: none; }

.nc-msgs { flex: 1; overflow-y: auto; padding: 16px 14px 8px; display: flex; flex-direction: column; gap: 3px; overscroll-behavior: contain; }
.nc-day { align-self: center; font-size: 12px; font-weight: 600; color: var(--muted); background: var(--surface); border: 1px solid var(--border); padding: 3px 10px; border-radius: 999px; margin: 12px 0 8px; }
.nc-msg { display: flex; max-width: min(76%, 560px); }
.nc-msg.mine { align-self: flex-end; }
.nc-bubble {
	position: relative; padding: 8px 12px 6px; border-radius: 18px; background: var(--bubble-in); border: 1px solid var(--border);
	white-space: pre-wrap; word-wrap: break-word; overflow-wrap: anywhere; min-width: 64px;
}
.nc-msg.mine .nc-bubble { background: var(--bubble-out); color: #fff; border-color: transparent; border-bottom-right-radius: 6px; }
.nc-msg:not(.mine) .nc-bubble { border-bottom-left-radius: 6px; }
.nc-msg.mine .nc-bubble a { color: #fff; text-decoration: underline; }
.nc-bubble img { display: block; max-width: 100%; max-height: 320px; border-radius: 12px; margin: 2px 0 4px; cursor: zoom-in; }
.nc-stamp { display: flex; justify-content: flex-end; align-items: center; gap: 3px; font-size: 11px; opacity: .7; margin-top: 2px; }
.nc-stamp svg { width: 15px; height: 15px; }
.nc-stamp .read { color: #9ff5d0; opacity: 1; }
.nc-msg.pending .nc-bubble { opacity: .65; }
.nc-msg.failed .nc-bubble { outline: 2px solid var(--danger); }
.nc-typing { align-self: flex-start; padding: 10px 14px; border-radius: 18px; background: var(--bubble-in); border: 1px solid var(--border); display: flex; gap: 4px; margin-top: 4px; }
.nc-typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: nc-bounce 1.2s infinite; }
.nc-typing i:nth-child(2) { animation-delay: .15s; }
.nc-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes nc-bounce { 0%, 60%, 100% { transform: translateY(0); opacity: .5; } 30% { transform: translateY(-4px); opacity: 1; } }

.nc-composer { display: flex; align-items: flex-end; gap: 8px; padding: 10px 12px; background: var(--surface); border-top: 1px solid var(--border); }
.nc-composer textarea {
	flex: 1; resize: none; max-height: 140px; min-height: 42px; padding: 10px 14px; border-radius: 21px;
	border: 1px solid var(--border); background: var(--surface-2); outline: 0; line-height: 1.4;
}
.nc-composer textarea:focus { border-color: var(--accent); }
.nc-composer .nc-send { width: 42px; height: 42px; border-radius: 50%; padding: 0; }
.nc-composer label.nc-icon-btn { color: var(--muted); }
.nc-blocked-note { padding: 14px; text-align: center; color: var(--muted); background: var(--surface); border-top: 1px solid var(--border); font-size: 14px; }

/* Menus */
.nc-menu { position: absolute; z-index: 80; min-width: 200px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow-lg); padding: 6px; }
.nc-menu button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border: 0; background: none; border-radius: 10px; cursor: pointer; text-align: left; }
.nc-menu button:hover { background: var(--surface-2); }
.nc-menu button.danger { color: var(--danger); }
.nc-menu svg { width: 18px; height: 18px; }

/* Modal */
.nc-modal-wrap { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px; background: rgba(10, 10, 25, .55); animation: nc-fade .15s ease; }
.nc-modal {
	position: relative; width: 100%; max-width: 440px; max-height: calc(100dvh - 32px); overflow-y: auto;
	background: var(--surface); border-radius: 22px; box-shadow: var(--shadow-lg); padding: 24px; animation: nc-rise .2s ease;
}
.nc-modal.wide { max-width: 520px; }
.nc-modal h2 { margin: 0 0 4px; padding-right: 36px; font-size: 22px; letter-spacing: -.01em; }
.nc-modal .nc-sub { color: var(--muted); margin: 0 0 18px; }
.nc-modal-close { position: absolute; top: 12px; right: 12px; }
.nc-modal.img { background: transparent; box-shadow: none; padding: 0; max-width: min(92vw, 1000px); display: grid; place-items: center; }
.nc-modal.img img { max-width: 100%; max-height: 88dvh; border-radius: 14px; }
@keyframes nc-fade { from { opacity: 0; } }
@keyframes nc-rise { from { opacity: 0; transform: translateY(12px) scale(.98); } }

.nc-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: var(--surface-2); border-radius: 14px; margin-bottom: 18px; }
.nc-tabs button { height: 38px; border: 0; border-radius: 10px; background: transparent; font-weight: 600; cursor: pointer; color: var(--muted); }
.nc-tabs button[aria-selected="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }

/* Profile view & modal */
.nc-profile-head { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; }
.nc-profile-head h2 { margin: 10px 0 0; }
.nc-profile-head .nc-meta { color: var(--muted); }
.nc-tags { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 12px 0 0; }
.nc-tag { padding: 4px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-size: 12px; font-weight: 600; }
.nc-profile-bio { margin: 14px 0 0; color: var(--text); white-space: pre-wrap; text-align: center; }
.nc-profile-actions { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin-top: 20px; }

.nc-page { max-width: 640px; margin: 0 auto; }
.nc-card-box { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); margin-bottom: 14px; }
.nc-card-box h3 { margin: 0 0 14px; font-size: 16px; }
.nc-avatar-edit { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.nc-avatar-edit .nc-av { cursor: pointer; }
.nc-list-row { display: flex; align-items: center; gap: 12px; padding: 8px 0; }
.nc-list-row b { flex: 1; }
.nc-help { font-size: 13px; color: var(--muted); }

/* Toasts */
#nc-toasts { position: fixed; z-index: 120; top: calc(var(--header-h) + 10px); left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; width: min(420px, calc(100vw - 32px)); pointer-events: none; }
.nc-toast {
	pointer-events: auto; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 16px;
	background: var(--text); color: var(--bg); box-shadow: var(--shadow-lg); animation: nc-rise .2s ease; cursor: default;
}
.nc-toast.msg { background: var(--surface); color: var(--text); border: 1px solid var(--border); cursor: pointer; }
.nc-toast.err { background: var(--danger); color: #fff; }
.nc-toast small { display: block; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 300px; }
.nc-toast > div { min-width: 0; }

/* Responsive */
@media (max-width: 860px) {
	.nc-chats { grid-template-columns: 1fr; height: auto; min-height: 0; background: transparent; border: 0; box-shadow: none; border-radius: 0; }
	.nc-conv-list { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
	.nc-conv-scroll { overflow: visible; }
	.nc-chat-pane { display: none; }
	.nc-chats.open .nc-chat-pane {
		display: flex; position: fixed; inset: 0; z-index: 60; height: 100dvh;
		padding-bottom: env(safe-area-inset-bottom);
	}
	.nc-chats.open .nc-conv-list { display: none; }
	.nc-chat-head .nc-back { display: grid; }
	body.nc-in-chat .nc-nav, body.nc-in-chat .nc-header { display: none; }
	.nc-msg { max-width: 84%; }
}
@media (max-width: 560px) {
	.nc-header { gap: 8px; }
	.nc-state { padding: 0 10px; max-width: 44%; }
	.nc-state > svg:first-child { display: none; }
	.nc-search { padding: 0 12px; }
	.nc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.nc-card { padding: 14px 10px 12px; }
	.nc-card .nc-bio { display: none; }
	.nc-av-lg { width: 68px; height: 68px; font-size: 24px; }
	.nc-nav { left: 12px; right: 12px; transform: none; justify-content: space-around; }
	.nc-nav a { flex: 1; justify-content: center; padding: 0 8px; flex-direction: column; gap: 2px; height: 52px; font-size: 11px; }
	.nc-badge { left: calc(50% + 4px); top: 2px; }
	.nc-row { grid-template-columns: 1fr; gap: 0; }
	.nc-modal { padding: 20px 18px; }
}
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ================= Neon map ================= */
.nc-mapwrap {
	position: relative; height: 56vh; height: min(56vh, 540px); min-height: 320px; margin: 0 0 18px;
	border-radius: 22px; overflow: hidden; background: #05010f; isolation: isolate;
	border: 1px solid rgba(0, 229, 255, .38);
	box-shadow: 0 0 0 1px rgba(255, 43, 214, .14), 0 0 28px rgba(0, 229, 255, .18), 0 0 70px rgba(123, 44, 255, .2);
}
.nc-map { position: absolute; top: 0; right: 0; bottom: 0; left: 0; background: #05010f; }
.nc-mapwrap.full { position: fixed; top: 0; right: 0; bottom: 0; left: 0; height: auto; z-index: 90; margin: 0; border-radius: 0; border: 0; }
body.nc-map-open { overflow: hidden; }
body.nc-map-open .nc-nav, body.nc-map-open .nc-header { display: none; }
.nc-mapwrap.failed .nc-map { display: none; }
.nc-mapwrap.failed { height: auto; min-height: 0; padding: 70px 16px 16px; }

.nc-mapwrap .leaflet-container { background: #05010f; font-family: inherit; outline: 0; }
.nc-tiles { filter: grayscale(1) invert(1) sepia(1) hue-rotate(195deg) saturate(2.4) brightness(.62) contrast(1.35); }
.nc-mapwrap .leaflet-ncNeon-pane { filter: drop-shadow(0 0 2px #00e5ff) drop-shadow(0 0 7px rgba(0, 229, 255, .7)); }

.nc-pin { background: none; border: 0; }
.nc-pin-av {
	display: block; width: 46px; height: 46px; border-radius: 50%; padding: 3px;
	background: linear-gradient(135deg, #7b2cff, #00e5ff);
	box-shadow: 0 0 10px rgba(0, 229, 255, .8), 0 0 22px rgba(123, 44, 255, .6);
	transition: transform .15s;
}
.nc-pin.on .nc-pin-av {
	background: linear-gradient(135deg, #19ff9c, #00e5ff);
	box-shadow: 0 0 10px rgba(25, 255, 156, .9), 0 0 26px rgba(25, 255, 156, .5);
	animation: nc-glow 2.2s ease-in-out infinite;
}
.nc-pin-av img, .nc-pin-av i {
	display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; border-radius: 50%;
	object-fit: cover; border: 2px solid #05010f; font-style: normal; font-weight: 700; color: #fff; font-size: 14px;
}
.nc-pin:hover .nc-pin-av { transform: scale(1.14); }
@keyframes nc-glow { 50% { box-shadow: 0 0 16px rgba(25, 255, 156, 1), 0 0 42px rgba(25, 255, 156, .6); } }

.nc-cluster { background: none; }
.nc-cluster span {
	display: flex; align-items: center; justify-content: center; width: 46px; height: 46px; border-radius: 50%;
	color: #fff; font-weight: 800; font-size: 15px; text-shadow: 0 0 6px #00e5ff;
	background: radial-gradient(circle, rgba(123, 44, 255, .9), rgba(123, 44, 255, .35));
	border: 2px solid #00e5ff; box-shadow: 0 0 12px #00e5ff, inset 0 0 12px rgba(0, 229, 255, .6);
}
.nc-cluster.on span { border-color: #19ff9c; box-shadow: 0 0 12px #19ff9c, inset 0 0 12px rgba(25, 255, 156, .5); }

.leaflet-tooltip.nc-tip {
	background: rgba(8, 4, 24, .94); color: #e9e6ff; border: 1px solid rgba(0, 229, 255, .6); border-radius: 10px;
	box-shadow: 0 0 14px rgba(0, 229, 255, .35); font: 600 12px/1.45 Inter, system-ui, sans-serif; padding: 6px 10px;
}
.leaflet-tooltip.nc-tip::before { display: none; }
.nc-tip .on { color: #19ff9c; }

.nc-map-hud {
	position: absolute; z-index: 500; top: 12px; left: 12px; max-width: 58%;
	display: flex; flex-direction: column; padding: 10px 14px; border-radius: 14px; pointer-events: none;
	background: rgba(8, 4, 24, .74); border: 1px solid rgba(0, 229, 255, .4); color: #e9e6ff;
	-webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.nc-map-hud b { font-size: 19px; line-height: 1.2; color: #fff; letter-spacing: .02em; text-shadow: 0 0 8px #00e5ff, 0 0 18px rgba(0, 229, 255, .7); }
.nc-map-hud span { font-size: 12px; color: #9ff3ff; margin-top: 2px; }
.nc-map-tools { position: absolute; z-index: 500; top: 12px; right: 12px; display: flex; gap: 8px; }
.nc-map-btn {
	display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 12px; border-radius: 12px; cursor: pointer;
	border: 1px solid rgba(0, 229, 255, .5); background: rgba(8, 4, 24, .78); color: #e9e6ff; font-weight: 600; font-size: 13px;
	-webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); box-shadow: 0 0 12px rgba(0, 229, 255, .25);
}
.nc-map-btn:hover { border-color: #00e5ff; box-shadow: 0 0 18px rgba(0, 229, 255, .6); }
.nc-map-btn svg { width: 18px; height: 18px; color: #00e5ff; }
.nc-mapwrap .leaflet-control-zoom { border: 1px solid rgba(0, 229, 255, .35) !important; box-shadow: 0 0 12px rgba(0, 229, 255, .25) !important; }
.nc-mapwrap .leaflet-control-zoom a { background: rgba(8, 4, 24, .88) !important; color: #00e5ff !important; border-color: rgba(0, 229, 255, .3) !important; }
.nc-mapwrap .leaflet-control-attribution { background: rgba(5, 1, 15, .7) !important; color: #8a86b5 !important; font-size: 10px; }
.nc-mapwrap .leaflet-control-attribution a { color: #9ff3ff !important; }

/* Toggle switch */
.nc-switch { position: relative; display: inline-block; width: 46px; height: 26px; flex: none; }
.nc-switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.nc-switch span { position: absolute; top: 0; right: 0; bottom: 0; left: 0; border-radius: 13px; background: var(--border); transition: background .15s; }
.nc-switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .3); transition: transform .15s; }
.nc-switch input:checked + span { background: var(--accent); }
.nc-switch input:checked + span::after { transform: translateX(20px); }
.nc-switch input:focus-visible + span { outline: 3px solid var(--accent-soft); }

@media (max-width: 560px) {
	.nc-mapwrap { height: 50vh; min-height: 290px; border-radius: 18px; }
	.nc-map-btn span { display: none; }
	.nc-map-btn { width: 40px; padding: 0; justify-content: center; }
	.nc-map-hud { padding: 8px 12px; }
	.nc-map-hud b { font-size: 15px; }
}

/* Fallbacks for older browsers (no color-mix / dvh / inset) */
@supports not (background: color-mix(in srgb, red 50%, blue)) {
	.nc-header { background: var(--bg); }
	.nc-nav { background: var(--surface); }
	.nc-card:hover { border-color: var(--accent); }
	.nc-btn.danger { border-color: var(--danger); }
}
@supports not (height: 100dvh) {
	.nc-chats { height: calc(100vh - var(--header-h) - var(--nav-h) - 64px); }
	.nc-modal { max-height: calc(100vh - 32px); }
	.nc-modal.img img { max-height: 88vh; }
}
@supports not (inset: 0) {
	.nc-modal-wrap { top: 0; right: 0; bottom: 0; left: 0; }
}
@media (max-width: 860px) {
	@supports not (inset: 0) { .nc-chats.open .nc-chat-pane { top: 0; right: 0; bottom: 0; left: 0; } }
	@supports not (height: 100dvh) { .nc-chats.open .nc-chat-pane { height: 100vh; } }
}
