:root {
    --bg: #07080c;
    --panel: #10131b;
    --panel-2: #151927;
    --line: #252a38;
    --text: #eef3f0;
    --muted: #9aa5a2;
    --lime: #b6ff2e;
    --violet: #8f5cff;
    --amber: #ffca5c;
    --red: #ff6470;
}

* { box-sizing: border-box; }
body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a { color: inherit; text-decoration: none; }
button, input { font: inherit; }

.guest-shell {
    background:
        radial-gradient(circle at 20% 20%, rgba(182, 255, 46, .12), transparent 24rem),
        radial-gradient(circle at 80% 10%, rgba(143, 92, 255, .16), transparent 28rem),
        linear-gradient(90deg, rgba(7,8,12,.92), rgba(7,8,12,.82)),
        url("/images/netstar/hero-propuesta-4-backbone-premium.png") center / cover no-repeat,
        var(--bg);
}

.login-screen {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 420px;
    gap: 48px;
    min-height: 100vh;
    align-items: center;
    padding: 56px clamp(24px, 6vw, 96px);
}

.login-brand h1 {
    margin: 12px 0;
    max-width: 760px;
    font-size: clamp(48px, 7vw, 92px);
    line-height: .92;
    letter-spacing: 0;
}

.login-brand p { max-width: 620px; color: var(--muted); font-size: 18px; }
.nexo-logo-lockup {
    display: flex;
    align-items: center;
    gap: 18px;
    width: fit-content;
    color: var(--text);
    filter: drop-shadow(0 12px 30px rgba(0, 0, 0, .42));
}
.netstar-logo-crop {
    display: block;
    overflow: visible;
    width: 232px;
    height: 82px;
}
.netstar-logo-crop img {
    display: block;
    width: 252px;
    height: auto;
    margin-left: -18px;
    margin-top: -10px;
}
.nexo-logo-word {
    position: relative;
    display: inline-flex;
    align-items: center;
    min-height: 52px;
    padding-left: 19px;
    border-left: 2px solid rgba(238, 243, 240, .7);
    color: var(--text);
    font-size: 42px;
    font-weight: 900;
    line-height: 1;
    letter-spacing: .15em;
}
.nexo-logo-word::after {
    content: "";
    position: absolute;
    left: 19px;
    right: .15em;
    bottom: 2px;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--lime), rgba(143, 92, 255, .75));
}
.hero-logo { margin: 0 0 26px 0; }
.brand-mark {
    display: grid;
    place-items: center;
    width: 64px;
    height: 64px;
    border: 1px solid rgba(182, 255, 46, .4);
    background: linear-gradient(135deg, rgba(182,255,46,.18), rgba(143,92,255,.24));
    color: var(--lime);
    font-weight: 900;
    font-size: 32px;
}
.brand-mark.small { width: 42px; height: 42px; font-size: 21px; }

.login-signals { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.login-signals span {
    border: 1px solid var(--line);
    background: rgba(255,255,255,.04);
    padding: 9px 12px;
    color: var(--muted);
}

.login-panel, .panel, .hero-panel, .stat-card {
    border: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(255,255,255,.045), rgba(255,255,255,.02));
    box-shadow: 0 18px 60px rgba(0,0,0,.28);
}

.login-panel { padding: 32px; }
.login-panel h2 { margin: 6px 0 24px; font-size: 30px; }
.login-form { display: grid; gap: 18px; }
.login-form label { display: grid; gap: 8px; color: var(--muted); }
.login-form input {
    width: 100%;
    border: 1px solid var(--line);
    background: #080a10;
    color: var(--text);
    padding: 13px 14px;
    outline: none;
}
.login-form input:focus { border-color: var(--lime); }
.check-row { grid-template-columns: 18px 1fr; align-items: center; }
.login-form button, .hero-panel button, .logout-form button {
    border: 0;
    background: var(--lime);
    color: #111;
    padding: 13px 16px;
    font-weight: 800;
    cursor: pointer;
}
.alert.error {
    margin-bottom: 16px;
    border: 1px solid rgba(255,100,112,.35);
    color: #ffd4d8;
    background: rgba(255,100,112,.1);
    padding: 12px;
}

.app-shell {
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    font-size: 12px;
}
.sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    border-right: 1px solid var(--line);
    background: #080a10;
    padding: 12px 8px;
    display: flex;
    flex-direction: column;
}
.brand-row { display: flex; align-items: center; margin-bottom: 10px; }
.brand-row strong, .brand-row small { display: block; }
.brand-row small { color: var(--lime); letter-spacing: .16em; font-size: 11px; }
.sidebar-logo {
    gap: 9px;
    transform: scale(.42);
    transform-origin: left center;
    margin: -22px 0 -20px 0;
}
.sidebar nav { display: grid; gap: 2px; }
.sidebar nav a {
    display: grid;
    grid-template-columns: 30px 1fr;
    align-items: center;
    min-height: 46px;
    padding: 0 10px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}
.nav-icon {
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border: 0;
    background: transparent;
    color: var(--lime);
}
.nav-icon svg {
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.sidebar nav a.active, .sidebar nav a:hover {
    background: rgba(182,255,46,.08);
    color: var(--text);
}
.sidebar nav a.active { border-left: 3px solid var(--lime); }
.logout-form { margin-top: auto; }
.logout-form button { width: 100%; background: #1d2230; color: var(--text); }

.main-panel { min-width: 0; padding: 0; overflow: hidden; }
.topbar {
    display: grid;
    grid-template-columns: minmax(360px, 1fr) auto auto;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
    min-height: 44px;
    padding: 6px 14px;
    margin-bottom: 0;
    border-bottom: 1px solid var(--line);
    background: #090c12;
}
.topbar h1 { margin: 3px 0 0; font-size: 20px; }
.top-search {
    display: grid;
    grid-template-columns: 20px 1fr 24px;
    align-items: center;
    gap: 8px;
    max-width: 650px;
    min-height: 32px;
    padding: 0 10px;
    border: 1px solid var(--line);
    background: #111721;
    color: var(--muted);
}
.top-search svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
}
.top-search kbd {
    display: grid;
    place-items: center;
    min-width: 22px;
    min-height: 20px;
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(255,255,255,.04);
    color: var(--muted);
    font: inherit;
}
.top-status {
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
}
.date-chip, .operator-chip {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 10px;
    border: 1px solid var(--line);
    background: #101621;
}
.operator-chip i {
    width: 8px;
    height: 8px;
    margin-right: 7px;
    border-radius: 50%;
    background: var(--lime);
}
.notification-dot {
    display: grid;
    place-items: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--violet);
    color: white;
    font-weight: 900;
}
.eyebrow {
    margin: 0;
    color: var(--lime);
    text-transform: uppercase;
    letter-spacing: .14em;
    font-size: 11px;
    font-weight: 800;
}
.user-chip { text-align: right; color: var(--muted); }
.user-chip span, .user-chip small { display: block; }
.user-chip span { color: var(--text); font-weight: 700; }
.top-tabs {
    display: flex;
    align-items: center;
    gap: 26px;
    min-height: 35px;
    padding: 0 14px;
    border-bottom: 1px solid var(--line);
    background: #080b10;
}
.top-tabs a {
    position: relative;
    display: inline-flex;
    align-items: center;
    height: 35px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .08em;
}
.top-tabs a.active {
    color: var(--text);
}
.top-tabs a.active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 3px;
    background: var(--violet);
}

.grid { display: grid; gap: 16px; }
.stats-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.stat-card { padding: 18px; min-height: 120px; }
.stat-card span, .stat-card small { display: block; color: var(--muted); }
.stat-card strong { display: block; margin: 12px 0 10px; font-size: 34px; }
.stat-card.lime strong { color: var(--lime); }
.stat-card.violet strong { color: var(--violet); }
.stat-card.amber strong { color: var(--amber); }
.stat-card.red strong { color: var(--red); }

.workspace-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(300px, .7fr);
    gap: 16px;
    margin-top: 16px;
}
.panel, .hero-panel { padding: 12px; }
.panel h2, .hero-panel h2 { margin: 6px 0 12px; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.ops-list, .module-list, .kv-list { display: grid; gap: 12px; margin-top: 18px; }
.ops-list div, .module-list div, .kv-list div {
    border: 1px solid var(--line);
    background: rgba(0,0,0,.18);
    padding: 14px;
}
.ops-list time { color: var(--lime); font-size: 12px; font-weight: 800; }
.ops-list strong, .module-list strong { display: block; margin: 4px 0; }
.ops-list p, .module-list p, .muted { color: var(--muted); margin: 0; }
.module-list div { display: grid; grid-template-columns: 12px 1fr; column-gap: 12px; }
.module-list span {
    width: 10px;
    height: 10px;
    margin-top: 5px;
    background: var(--lime);
}
.module-list p { grid-column: 2; }
.kv-list div { display: flex; justify-content: space-between; gap: 12px; }
.kv-list dt { color: var(--muted); }
.kv-list dd { margin: 0; font-weight: 800; }
.hero-panel {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    align-items: flex-start;
    margin-bottom: 16px;
}
.hero-panel p { max-width: 780px; color: var(--muted); }

.dashboard-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 18px;
    margin: 12px 14px;
}
.dashboard-toolbar h2 {
    margin: 3px 0 0;
    font-size: 28px;
}
.toolbar-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}
.toolbar-actions span, .toolbar-actions a, .panel-head a {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 11px;
    border: 1px solid var(--line);
    background: rgba(255,255,255,.035);
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}
.panel-head a { color: var(--lime); }
.kpi-strip {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
    margin: 0 14px 10px;
}
.kpi-card {
    min-height: 84px;
    padding: 12px;
    border: 1px solid var(--line);
    background:
        linear-gradient(180deg, rgba(255,255,255,.052), rgba(255,255,255,.018)),
        #10131b;
}
.kpi-card span, .kpi-card small {
    display: block;
    color: var(--muted);
}
.kpi-card strong {
    display: block;
    margin: 6px 0 5px;
    font-size: clamp(22px, 2.2vw, 30px);
    line-height: 1;
}
.kpi-card.lime strong { color: var(--lime); }
.kpi-card.violet strong { color: var(--violet); }
.kpi-card.amber strong { color: var(--amber); }
.kpi-card.red strong { color: var(--red); }
.console-access-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 16px;
}
.console-access-card {
    position: relative;
    display: grid;
    gap: 12px;
    min-height: 238px;
    padding: 18px;
    overflow: hidden;
    border: 1px solid var(--line);
    background:
        radial-gradient(circle at 100% 0%, rgba(182,255,46,.13), transparent 11rem),
        linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.018));
    box-shadow: 0 16px 46px rgba(0,0,0,.22);
}
.console-access-card::after {
    content: "";
    position: absolute;
    right: 16px;
    bottom: 16px;
    width: 66px;
    height: 66px;
    border: 1px solid rgba(255,255,255,.06);
    transform: rotate(18deg);
}
.console-access-card:hover {
    transform: translateY(-2px);
    border-color: rgba(182,255,46,.36);
}
.console-access-icon {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255,255,255,.1);
    background: rgba(0,0,0,.28);
    color: var(--lime);
    font-size: 14px;
    font-weight: 900;
}
.console-access-card.violet .console-access-icon { color: var(--violet); }
.console-access-card.amber .console-access-icon { color: var(--amber); }
.console-access-card.red .console-access-icon { color: var(--red); }
.console-access-card strong {
    position: relative;
    z-index: 1;
    font-size: 23px;
}
.console-access-card p {
    position: relative;
    z-index: 1;
    margin: 0;
    color: var(--muted);
}
.console-access-card dl {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 7px;
    margin: auto 0 0;
}
.console-access-card dl div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding-top: 7px;
    border-top: 1px solid rgba(255,255,255,.07);
}
.console-access-card dt { color: var(--muted); }
.console-access-card dd { margin: 0; font-weight: 900; }
.dashboard-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
    gap: 16px;
}
.chart-panel { min-height: 340px; }
.bar-chart {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    align-items: end;
    gap: 14px;
    height: 230px;
    margin-top: 20px;
    padding: 14px 0 0;
    border-top: 1px solid rgba(255,255,255,.06);
}
.bar-chart div {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: end;
    gap: 5px;
    height: 100%;
}
.bar-chart small {
    grid-column: 1 / -1;
    color: var(--muted);
    text-align: center;
    font-size: 11px;
}
.bar {
    display: block;
    min-height: 18px;
    background: var(--violet);
}
.bar.paid { background: var(--lime); }
.payment-bars { display: grid; gap: 16px; margin-top: 18px; }
.payment-bars div {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px 12px;
}
.payment-bars span { color: var(--muted); }
.payment-bars strong { font-size: 13px; }
.payment-bars i {
    grid-column: 1 / -1;
    display: block;
    height: 8px;
    background: linear-gradient(90deg, var(--lime), var(--violet));
}
.network-summary, .support-summary { min-height: 340px; }
.mini-map {
    position: relative;
    height: 190px;
    margin-top: 16px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.07);
    background:
        linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px),
        #080b11;
    background-size: 32px 32px;
}
.mini-map .line {
    position: absolute;
    height: 3px;
    background: var(--lime);
    transform-origin: left center;
    opacity: .8;
}
.mini-map .line.warning { background: var(--red); }
.mini-map .l1 { left: 24%; top: 52%; width: 45%; transform: rotate(-22deg); }
.mini-map .l2 { left: 49%; top: 42%; width: 32%; transform: rotate(28deg); }
.mini-map .l3 { left: 22%; top: 53%; width: 28%; transform: rotate(28deg); background: var(--violet); }
.node-dot {
    position: absolute;
    width: 15px;
    height: 15px;
    border-radius: 999px;
    border: 3px solid #07080c;
    box-shadow: 0 0 18px currentColor;
}
.node-dot.online { background: var(--lime); color: var(--lime); }
.node-dot.unstable { background: var(--amber); color: var(--amber); }
.node-dot.down { background: var(--red); color: var(--red); }
.node-dot.core { left: 20%; top: 48%; }
.node-dot.a { left: 46%; top: 28%; }
.node-dot.b { left: 73%; top: 53%; }
.node-dot.c { left: 42%; top: 72%; }
.node-dot.d { left: 77%; top: 73%; }
.status-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 12px;
}
.status-grid div {
    border: 1px solid var(--line);
    padding: 10px;
    background: rgba(0,0,0,.2);
}
.status-grid strong { display: block; font-size: 24px; }
.status-grid span { color: var(--muted); font-size: 12px; }
.ticket-list { display: grid; gap: 10px; margin-top: 16px; }
.ticket-list div {
    position: relative;
    display: grid;
    grid-template-columns: 13px 72px 1fr auto;
    gap: 10px;
    align-items: center;
    padding: 12px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.2);
}
.dot {
    width: 9px;
    height: 9px;
    border-radius: 999px;
}
.dot.red { background: var(--red); }
.dot.amber { background: var(--amber); }
.dot.lime { background: var(--lime); }
.dot.violet { background: var(--violet); }
.ticket-list p { margin: 0; color: var(--muted); }
.ticket-list small { color: var(--text); font-weight: 800; }
.full-span { grid-column: 1 / -1; }
.data-table { overflow: auto; margin-top: 14px; }
.data-table table {
    width: 100%;
    border-collapse: collapse;
}
.data-table th, .data-table td {
    padding: 12px 10px;
    border-bottom: 1px solid var(--line);
    text-align: left;
    white-space: nowrap;
}
.data-table th {
    color: var(--muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .08em;
}
.badge {
    display: inline-flex;
    min-height: 24px;
    align-items: center;
    padding: 0 8px;
    border: 1px solid var(--line);
    font-size: 12px;
    font-weight: 800;
}
.badge.amber { color: var(--amber); border-color: rgba(255,202,92,.3); }
.badge.red { color: var(--red); border-color: rgba(255,100,112,.3); }
.badge.violet { color: var(--violet); border-color: rgba(143,92,255,.3); }

.badge.lime { color: var(--lime); border-color: rgba(182,255,46,.32); }

.module-toolbar {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-end;
    margin: 10px 14px 8px;
    padding-bottom: 0;
    border-bottom: 1px solid var(--line);
}
.module-toolbar h2 {
    margin: 2px 0;
    font-size: 22px;
}
.module-toolbar span { color: var(--muted); }
.kpi-strip.dense .kpi-card { min-height: 70px; }
.kpi-strip.finance { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.kpi-strip.mini {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin: 14px 0;
}
.kpi-strip.mini .kpi-card {
    min-height: 94px;
    padding: 14px;
}
.kpi-strip.mini .kpi-card strong { font-size: 25px; }

.gis-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 8px;
    margin: 0 14px 8px;
}
.gis-map-panel { position: relative; padding: 12px; }
.gis-map-canvas {
    position: relative;
    min-height: 515px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.09);
    background:
        linear-gradient(180deg, rgba(6,8,12,.18), rgba(6,8,12,.34)),
        url("/images/netstar/gis-map-crop.jpg") center / cover no-repeat,
        #0b0f16;
}
.gis-real-shell {
    position: relative;
    min-height: 515px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.09);
    background: #0b0f16;
}
.leaflet-gis-map {
    position: absolute;
    inset: 0;
    z-index: 1;
    min-height: 515px;
    background: #0b0f16;
}
.leaflet-gis-map .leaflet-tile {
    filter: saturate(.82) brightness(.58) contrast(1.2);
}
.leaflet-gis-map .leaflet-control-attribution,
.leaflet-gis-map .leaflet-control-zoom a {
    background: rgba(7,9,13,.86);
    color: var(--muted);
    border-color: rgba(255,255,255,.12);
}
.nexo-leaflet-node {
    display: grid;
    place-items: center;
}
.nexo-leaflet-node span {
    display: block;
    width: 16px;
    height: 16px;
    border: 3px solid rgba(7,9,13,.95);
    border-radius: 999px;
    background: var(--lime);
    box-shadow: 0 0 20px rgba(182,255,46,.72);
}
.gis-import-panel {
    position: absolute;
    z-index: 4;
    right: 14px;
    bottom: 14px;
    display: grid;
    gap: 6px;
    min-width: 210px;
    padding: 12px;
    border: 1px solid rgba(255,255,255,.12);
    background: rgba(7,9,13,.86);
    box-shadow: 0 16px 36px rgba(0,0,0,.36);
    backdrop-filter: blur(10px);
}
.gis-import-panel strong,
.gis-import-panel span {
    display: block;
}
.gis-import-panel span {
    color: var(--muted);
    font-size: 12px;
}
.dude-map-list {
    display: grid;
    gap: 7px;
    max-height: 198px;
    overflow: auto;
}
.dude-map-list div {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 9px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.17);
}
.dude-map-list strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.dude-map-list span {
    color: var(--muted);
    white-space: nowrap;
}
.gis-next-list {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}
.gis-next-list div {
    display: grid;
    grid-template-columns: 34px 1fr;
    gap: 10px;
    align-items: center;
    padding: 10px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.17);
}
.gis-next-list strong {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border: 1px solid rgba(182,255,46,.34);
    background: rgba(182,255,46,.1);
    color: var(--lime);
}
.gis-next-list span {
    color: var(--text);
}
.equipment-catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
}
.equipment-catalog-item {
    min-height: 128px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, .025);
    padding: 10px;
    display: grid;
    grid-template-rows: 52px auto auto;
    gap: 7px;
    align-items: center;
}
.equipment-catalog-item img {
    max-width: 76px;
    max-height: 48px;
    object-fit: contain;
    justify-self: start;
}
.equipment-catalog-item strong {
    color: var(--text);
    font-size: .82rem;
    line-height: 1.2;
}
.equipment-catalog-item span {
    color: var(--muted);
    font-size: .72rem;
    line-height: 1.25;
}
.table-actions-mini {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}
.table-actions-mini button {
    border: 1px solid rgba(255, 255, 255, .12);
    background: rgba(255, 255, 255, .04);
    color: var(--text);
    padding: 5px 8px;
    font-size: .72rem;
    cursor: pointer;
}
.table-actions-mini button:hover {
    border-color: rgba(182, 255, 46, .5);
    color: var(--lime);
}
.submap-overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 10px;
}
.submap-card {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, .025);
    padding: 11px;
    display: grid;
    gap: 7px;
}
.submap-card strong {
    color: var(--text);
}
.submap-card span {
    color: var(--muted);
    font-size: .78rem;
}
.gis-map-canvas::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px);
    background-size: 58px 58px;
    pointer-events: none;
}
.map-layer-box {
    position: absolute;
    z-index: 5;
    top: 16px;
    left: 16px;
    display: grid;
    gap: 9px;
    min-width: 160px;
    padding: 10px;
    border: 1px solid rgba(255,255,255,.12);
    background: rgba(8,10,16,.82);
    backdrop-filter: blur(10px);
}
.map-layer-box strong { margin-bottom: 4px; }
.map-layer-box span { display: flex; align-items: center; gap: 9px; color: var(--text); font-size: 11px; }
.line-sample {
    display: inline-block;
    width: 28px;
    height: 3px;
    border-radius: 999px;
}
.line-sample.fiber { background: var(--lime); }
.line-sample.radio { background: repeating-linear-gradient(90deg, var(--violet), var(--violet) 7px, transparent 8px, transparent 13px); }
.gis-fiber, .gis-radio {
    position: absolute;
    z-index: 2;
    height: 4px;
    border-radius: 999px;
    transform-origin: left center;
}
.gis-fiber { background: var(--lime); box-shadow: 0 0 16px rgba(182,255,46,.5); }
.gis-fiber.down { background: var(--red); box-shadow: 0 0 18px rgba(255,100,112,.5); }
.gis-radio {
    height: 3px;
    background: repeating-linear-gradient(90deg, var(--violet), var(--violet) 10px, transparent 11px, transparent 18px);
}
.gf1 { left: 27%; top: 46%; width: 29%; transform: rotate(-24deg); }
.gf2 { left: 47%; top: 34%; width: 27%; transform: rotate(29deg); }
.gf3 { left: 36%; top: 60%; width: 28%; transform: rotate(-7deg); }
.gf4 { left: 53%; top: 53%; width: 16%; transform: rotate(32deg); }
.gr1 { left: 25%; top: 49%; width: 25%; transform: rotate(12deg); }
.gis-node {
    position: absolute;
    z-index: 4;
    min-width: 118px;
    border: 1px solid rgba(255,255,255,.14);
    background: rgba(7,9,13,.9);
    color: var(--text);
    padding: 8px 10px 8px 30px;
    text-align: left;
    box-shadow: 0 16px 35px rgba(0,0,0,.4);
}
.gis-node::before {
    content: "";
    position: absolute;
    left: 11px;
    top: 13px;
    width: 13px;
    height: 13px;
    border-radius: 999px;
    border: 3px solid rgba(7,9,13,.95);
    box-shadow: 0 0 18px currentColor;
}
.gis-node.online::before { background: var(--lime); color: var(--lime); }
.gis-node.unstable::before { background: var(--amber); color: var(--amber); }
.gis-node.down::before { background: var(--red); color: var(--red); }
.gis-node.unknown::before { background: #9aa5b8; color: #9aa5b8; }
.gis-node strong, .gis-node small { display: block; }
.gis-node small { color: var(--muted); margin-top: 2px; }
.gis-node.central { left: 41%; top: 46%; }
.gis-node.norte { left: 47%; top: 18%; }
.gis-node.centro { left: 69%; top: 39%; }
.gis-node.oeste { left: 19%; top: 37%; }
.gis-node.sur { left: 62%; top: 65%; }
.gis-node.ribera { left: 82%; top: 45%; }
.incident-pin {
    position: absolute;
    z-index: 4;
    left: 55%;
    top: 57%;
    padding: 4px 8px;
    border: 1px solid rgba(255,100,112,.45);
    background: rgba(255,100,112,.18);
    color: #ffd2d5;
    font-size: 11px;
    font-weight: 900;
}
.map-scale {
    position: absolute;
    left: 18px;
    bottom: 18px;
    z-index: 4;
    padding: 8px 12px;
    background: rgba(0,0,0,.72);
    color: var(--text);
    font-size: 12px;
}
.node-detail { display: grid; align-content: start; gap: 16px; }
.node-title { display: flex; gap: 12px; align-items: flex-start; }
.node-title h2 { margin: 0; font-size: 26px; }
.node-title p { margin: 3px 0 0; color: var(--red); font-weight: 800; }
.tabs-line {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid var(--line);
    overflow: auto;
}
.tabs-line span {
    padding: 9px 9px;
    color: var(--muted);
    white-space: nowrap;
}
.tabs-line .active {
    color: var(--text);
    border-bottom: 3px solid var(--violet);
}
.alert-card {
    border: 1px solid rgba(255,100,112,.45);
    background: rgba(255,100,112,.12);
    padding: 12px;
}
.alert-card strong { color: #ff9aa2; font-size: 16px; }
.alert-card p { color: #ffd1d5; margin: 8px 0 0; }
.service-status { display: grid; gap: 7px; }
.service-status div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 10px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.18);
}
.red-text { color: var(--red) !important; }
.lime-text { color: var(--lime) !important; }
.amber-text { color: var(--amber) !important; }
.billing-rules {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 14px;
}
.billing-rules div {
    min-height: 112px;
    padding: 14px;
    border: 1px solid var(--line);
    background:
        radial-gradient(circle at 100% 0, rgba(143,92,255,.14), transparent 9rem),
        rgba(0,0,0,.18);
}
.billing-rules strong {
    display: block;
    margin-bottom: 8px;
    color: var(--text);
    font-size: 15px;
}
.billing-rules span {
    color: var(--muted);
    line-height: 1.45;
}
.split-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.split-actions button, .conversation-head button, .reply-bar button, .client-list button, .account-line button {
    border: 0;
    background: var(--lime);
    color: #0a0d12;
    min-height: 42px;
    padding: 0 14px;
    font-weight: 900;
    cursor: pointer;
}
.split-actions .secondary {
    background: var(--violet);
    color: white;
}
.data-panels {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(320px, .8fr);
    gap: 8px;
    margin: 0 14px 8px;
}
.compact-table th, .compact-table td { padding: 10px 9px; }
.metric-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr auto);
    gap: 12px;
    align-items: center;
    margin-top: 18px;
}
.metric-row span { color: var(--muted); }
.sparkline, .mini-chart {
    height: 84px;
    margin-top: 18px;
    border: 1px solid rgba(255,255,255,.06);
    background:
        linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px),
        linear-gradient(135deg, transparent 15%, rgba(182,255,46,.7) 16%, transparent 18%, transparent 38%, rgba(143,92,255,.75) 39%, transparent 41%, transparent 67%, rgba(182,255,46,.65) 68%, transparent 71%),
        rgba(0,0,0,.2);
    background-size: 32px 24px, 32px 24px, 100% 100%, auto;
}

.support-console {
    display: grid;
    grid-template-columns: 360px minmax(0, 1fr) 360px;
    gap: 8px;
    margin: 10px 14px 8px;
}
.pill-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin: 12px 0;
}
.pill-tabs span {
    padding: 8px 10px;
    border: 1px solid var(--line);
    color: var(--muted);
    background: rgba(0,0,0,.18);
}
.pill-tabs .active { color: white; background: var(--violet); }
.inbox-panel { padding: 16px; }
.inbox-item {
    display: grid;
    grid-template-columns: 44px 1fr;
    gap: 12px;
    padding: 10px;
    border-bottom: 1px solid var(--line);
}
.inbox-item.selected {
    border: 1px solid var(--violet);
    background: rgba(143,92,255,.13);
}
.inbox-item > span, .avatar {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--violet), #3d4cff);
    color: white;
    font-weight: 900;
}
.avatar.large { width: 58px; height: 58px; font-size: 20px; }
.inbox-item strong, .inbox-item p, .inbox-item small { display: block; }
.inbox-item p { margin: 3px 0; color: var(--muted); }
.inbox-item small { color: #aeb6c5; }
.conversation-panel { display: grid; grid-template-rows: auto 1fr auto auto; min-height: 650px; }
.conversation-head, .client-card-head, .record-head {
    display: flex;
    align-items: center;
    gap: 14px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--line);
}
.conversation-head h2, .client-card-head h2, .record-head h2 { margin: 0; }
.conversation-head p, .client-card-head p, .record-head p { margin: 4px 0 0; color: var(--muted); }
.conversation-head button { margin-left: auto; background: #23293a; color: white; }
.message-thread {
    display: flex;
    flex-direction: column;
    gap: 12px;
    justify-content: center;
    padding: 12px 0;
}
.bubble {
    max-width: 70%;
    padding: 10px 12px;
    border: 1px solid rgba(255,255,255,.1);
    background: rgba(255,255,255,.07);
}
.bubble.outbound {
    align-self: flex-end;
    background: linear-gradient(135deg, rgba(90,70,255,.92), rgba(143,92,255,.88));
}
.internal-chat {
    display: grid;
    gap: 10px;
    padding: 12px;
    border: 1px solid rgba(143,92,255,.38);
    background: rgba(67,35,142,.22);
}
.reply-bar {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    margin-top: 14px;
}
.reply-bar span, .search-box {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 0 14px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.2);
    color: var(--muted);
}
.customer-side { display: grid; align-content: start; gap: 16px; }
.service-card, .ticket-mini {
    padding: 11px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.2);
}
.service-card strong { display: block; font-size: 20px; margin-bottom: 8px; }
.service-card p { color: var(--muted); margin: 9px 0 0; }
.quality-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}
.quality-grid div {
    padding: 10px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.17);
}
.quality-grid span { display: block; color: var(--muted); }
.quality-grid strong { display: block; margin-top: 5px; font-size: 23px; }
.account-line {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    align-items: center;
}
.account-line button { grid-column: 1 / -1; }

.finance-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(420px, .8fr) 290px;
    gap: 8px;
    margin: 0 14px 8px;
}
.finance-grid .wide-table { grid-column: 1 / 3; }
.event-rail { grid-row: span 2; }
.timeline {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}
.timeline div {
    position: relative;
    display: grid;
    grid-template-columns: 48px 1fr;
    gap: 4px 10px;
}
.timeline time { color: var(--muted); }
.timeline strong { display: block; }
.timeline span { grid-column: 2; color: var(--muted); font-size: 13px; }
.timeline.compact div { grid-template-columns: 42px 1fr; }
.bar-chart.labeled { height: 300px; }

.client-console {
    display: grid;
    grid-template-columns: 350px minmax(0, 1fr) 330px;
    gap: 8px;
    margin: 10px 14px 8px;
}
.client-list { display: grid; align-content: start; gap: 10px; min-height: 0; }
.client-search-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 8px;
    align-items: center;
}
.client-search-form input {
    min-width: 0;
    height: 40px;
    padding: 0 12px;
    border: 1px solid var(--line);
    background: rgba(3,5,9,.74);
    color: var(--text);
}
.client-search-form button,
.client-search-form a {
    display: inline-flex;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    border: 1px solid rgba(182,255,46,.35);
    background: rgba(182,255,46,.12);
    color: var(--text);
    font-weight: 800;
    text-decoration: none;
}
.client-list-meta {
    color: var(--muted);
    font-size: 12px;
}
.client-scroll-list {
    display: grid;
    align-content: start;
    gap: 10px;
    max-height: calc(100vh - 265px);
    overflow: auto;
    padding-right: 4px;
}
.client-row {
    display: grid;
    grid-template-columns: 70px 1fr auto;
    gap: 6px 10px;
    align-items: center;
    padding: 9px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.18);
    color: var(--text);
    text-decoration: none;
}
.client-row.selected { border-color: var(--lime); background: rgba(182,255,46,.08); }
.client-row small { grid-column: 2; color: var(--muted); }
.client-row i { font-style: normal; font-size: 12px; }
.client-row i.lime { color: var(--lime); }
.client-row i.amber { color: var(--amber); }
.client-row i.red { color: var(--red); }
.client-row b { grid-column: 3; grid-row: 1 / 3; }
.customer-record { min-height: 650px; }
.state-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin: 10px 0;
}
.state-cards div {
    padding: 10px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.2);
    font-weight: 900;
}
.state-cards .ok { border-color: rgba(182,255,46,.35); color: var(--lime); }
.state-cards .bad { border-color: rgba(255,100,112,.35); color: var(--red); }
.state-cards .warn { border-color: rgba(255,202,92,.35); color: var(--amber); }
.account-side { display: grid; align-content: start; gap: 16px; }
.kv-list.clean div {
    border: 0;
    border-bottom: 1px solid var(--line);
    background: transparent;
    padding: 8px 0;
}

/* Console-04: patrón visual base del sistema NEXO */
.violet-text { color: var(--violet) !important; }
.blue-text { color: #5f8cff !important; }
.badge.blue { color: #6ea2ff; border-color: rgba(95,140,255,.34); }
.badge.dark { color: #dce4ee; border-color: rgba(255,255,255,.12); background: rgba(255,255,255,.045); }

.ticket-console {
    display: grid;
    gap: 8px;
    margin: 8px 10px 10px;
}
.ticket-filter-row {
    display: grid;
    grid-template-columns: repeat(5, minmax(120px, 1fr)) 150px 150px;
    gap: 8px;
}
.filter-box {
    display: grid;
    grid-template-columns: 72px 1fr;
    align-items: center;
    min-height: 39px;
    padding: 0 10px;
    border: 1px solid var(--line);
    background: #101720;
}
.filter-box span {
    color: var(--muted);
    font-size: 11px;
}
.filter-box strong {
    justify-self: end;
    font-size: 12px;
}
.action-btn {
    min-height: 39px;
    border: 1px solid var(--line);
    color: var(--text);
    font-weight: 900;
    cursor: pointer;
}
.action-btn.violet {
    border-color: rgba(143,92,255,.55);
    background: linear-gradient(135deg, #5f35ff, #7e49ff);
}
.action-btn.dark { background: #121824; }

.ticket-kpi-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr)) minmax(260px, 1.35fr);
    gap: 8px;
}
.ticket-kpi, .sla-panel {
    min-height: 78px;
    border: 1px solid var(--line);
    background:
        radial-gradient(circle at 12% 50%, rgba(255,255,255,.05), transparent 4rem),
        linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.018)),
        #10131b;
}
.ticket-kpi {
    display: grid;
    grid-template-columns: 48px 1fr;
    align-items: center;
    gap: 10px;
    padding: 10px;
}
.ticket-kpi i {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(0,0,0,.24);
    font-style: normal;
    font-weight: 900;
}
.ticket-kpi strong {
    display: inline-block;
    margin-right: 8px;
    font-size: 27px;
    line-height: 1;
}
.ticket-kpi span {
    font-weight: 900;
}
.ticket-kpi small {
    display: block;
    margin-top: 2px;
    color: var(--muted);
}
.ticket-kpi.lime i, .ticket-kpi.lime strong { color: var(--lime); }
.ticket-kpi.amber i, .ticket-kpi.amber strong { color: var(--amber); }
.ticket-kpi.violet i, .ticket-kpi.violet strong { color: var(--violet); }
.ticket-kpi.blue i, .ticket-kpi.blue strong { color: #6ea2ff; }
.ticket-kpi.red i, .ticket-kpi.red strong { color: var(--red); }
.sla-panel {
    display: grid;
    gap: 8px;
    align-content: center;
    padding: 10px 12px;
}
.sla-panel > div:first-child {
    display: flex;
    gap: 6px;
    align-items: baseline;
}
.sla-panel span, .sla-panel p {
    margin: 0;
    color: var(--muted);
}
.sla-bar {
    display: grid;
    grid-template-columns: 72fr 18fr 10fr;
    height: 11px;
    overflow: hidden;
    background: #1d2430;
}
.sla-bar i.ok { background: var(--lime); }
.sla-bar i.risk { background: var(--amber); }
.sla-bar i.bad { background: var(--red); }
.sla-panel p {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    font-size: 11px;
}

.ticket-main-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 390px;
    gap: 8px;
}
.tickets-board {
    display: grid;
    gap: 8px;
    padding: 8px;
    overflow: hidden;
}
.ticket-board-tabs {
    display: grid;
    grid-template-columns: repeat(4, auto) minmax(180px, 1fr);
    align-items: center;
    gap: 4px;
    border-bottom: 1px solid var(--line);
}
.ticket-board-tabs span, .ticket-board-tabs div {
    min-height: 34px;
    padding: 9px 12px;
    color: var(--muted);
    font-weight: 800;
}
.ticket-board-tabs .active {
    color: var(--text);
    border-bottom: 3px solid var(--violet);
}
.ticket-board-tabs div {
    justify-self: end;
    font-size: 11px;
}
.ticket-board-tabs strong {
    color: var(--text);
}
.tickets-table {
    overflow: auto;
    border: 1px solid rgba(255,255,255,.055);
    background: rgba(0,0,0,.13);
}
.tickets-table table {
    width: 100%;
    min-width: 980px;
    border-collapse: collapse;
}
.tickets-table th, .tickets-table td {
    padding: 8px 9px;
    border-bottom: 1px solid rgba(255,255,255,.065);
    text-align: left;
    white-space: nowrap;
}
.tickets-table th {
    color: var(--muted);
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: .04em;
}
.tickets-table tr.selected {
    background: linear-gradient(90deg, rgba(84,68,255,.48), rgba(84,68,255,.18));
}
.check-cell {
    display: block;
    width: 14px;
    height: 14px;
    border: 1px solid #3a4354;
    background: #101722;
}
.check-cell.on {
    border-color: var(--violet);
    background: var(--violet);
}
.channel-pill {
    display: inline-flex;
    min-height: 20px;
    align-items: center;
    padding: 0 7px;
    border: 1px solid rgba(255,255,255,.09);
    background: rgba(255,255,255,.05);
    font-size: 11px;
    font-weight: 900;
}
.channel-pill.whatsapp { color: #7eff8f; border-color: rgba(126,255,143,.24); }
.channel-pill.app { color: #6ea2ff; border-color: rgba(110,162,255,.25); }
.channel-pill.teléfono { color: var(--violet); border-color: rgba(143,92,255,.25); }

.ticket-selected {
    display: grid;
    gap: 8px;
    border: 1px solid var(--line);
    background: #0c1118;
    padding: 8px;
}
.ticket-selected-head {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 36px;
}
.ticket-selected-head div {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-right: 6px;
}
.ticket-selected-head strong {
    font-size: 18px;
}
.ticket-selected-head span {
    font-weight: 900;
}
.ticket-selected-head small, .ticket-selected-head em {
    color: var(--muted);
    font-style: normal;
}
.ticket-selected-head em {
    margin-left: auto;
}
.ticket-metrics {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}
.ticket-metrics div {
    padding: 9px 10px;
    border-right: 1px solid var(--line);
}
.ticket-metrics div:last-child { border-right: 0; }
.ticket-metrics small {
    display: block;
    color: var(--muted);
}
.ticket-metrics strong {
    display: block;
    margin-top: 3px;
    font-size: 16px;
}
.ticket-actions {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}
.ticket-actions button {
    min-height: 33px;
    border: 1px solid var(--line);
    background: #111923;
    color: var(--text);
    font-weight: 800;
}
.ticket-bottom-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.ticket-chat, .ticket-notes {
    display: grid;
    gap: 8px;
    min-height: 175px;
    padding: 10px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.17);
}
.ticket-notes {
    border-color: rgba(143,92,255,.38);
    background: linear-gradient(180deg, rgba(83,45,166,.22), rgba(83,45,166,.1));
}
.chat-line, .note-line {
    display: grid;
    grid-template-columns: 34px 1fr auto;
    gap: 8px;
    align-items: start;
}
.chat-line b, .note-line b {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    background: rgba(143,92,255,.32);
    color: white;
    font-size: 11px;
}
.chat-line p, .note-line p {
    margin: 0;
    color: #dbe2e8;
    line-height: 1.35;
}
.chat-line time {
    color: var(--muted);
    font-size: 11px;
}
.reply-bar.compact {
    grid-template-columns: 1fr 82px;
    margin-top: 0;
}
.reply-bar.compact span {
    min-height: 34px;
}
.reply-bar.compact button {
    min-height: 34px;
}

.dispatch-column {
    display: grid;
    gap: 8px;
    align-content: start;
}
.dispatch-panel, .tech-field-panel, .incident-general {
    padding: 10px;
}
.dispatch-flow {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin: 12px 0;
}
.dispatch-flow div {
    min-height: 64px;
    padding: 10px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.16);
}
.dispatch-flow div.done { border-color: rgba(182,255,46,.35); }
.dispatch-flow div.active { border-color: rgba(143,92,255,.45); background: rgba(143,92,255,.12); }
.dispatch-flow strong, .dispatch-flow span {
    display: block;
}
.dispatch-flow span {
    margin-top: 3px;
    color: var(--muted);
}
.dispatch-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.dispatch-form label {
    display: grid;
    gap: 5px;
    padding: 8px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.15);
    color: var(--muted);
}
.dispatch-form strong {
    color: var(--text);
}
.dispatch-form textarea {
    grid-column: 1 / -1;
    min-height: 54px;
    resize: vertical;
    border: 1px solid var(--line);
    background: #0a0f16;
    color: var(--text);
    padding: 10px;
}
.dispatch-panel .split-actions {
    margin-top: 10px;
}
.tech-list {
    display: grid;
    gap: 7px;
    margin-top: 8px;
}
.tech-list div {
    display: grid;
    grid-template-columns: 34px 1fr auto;
    gap: 4px 8px;
    align-items: center;
    padding: 8px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.16);
}
.tech-list span {
    display: grid;
    grid-row: span 2;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    background: #5d6680;
    color: white;
    font-weight: 900;
}
.tech-list em {
    justify-self: end;
    font-style: normal;
    font-weight: 900;
}
.tech-list small {
    color: var(--muted);
}
.tech-list b {
    justify-self: end;
    color: #d7dcff;
}
.incident-general {
    border-color: rgba(255,100,112,.4);
    background: linear-gradient(180deg, rgba(255,100,112,.14), rgba(255,100,112,.06));
}
.incident-general > strong {
    display: block;
    margin-top: 6px;
    color: #ffd1d5;
    font-size: 16px;
}
.incident-general p {
    color: #f4c7cc;
    line-height: 1.45;
}
.incident-general div {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted);
    font-size: 11px;
}
.incident-general button {
    width: 100%;
    min-height: 36px;
    margin-top: 10px;
    border: 1px solid rgba(143,92,255,.55);
    background: rgba(143,92,255,.18);
    color: var(--text);
    font-weight: 900;
}

.module-toolbar, .dashboard-toolbar {
    margin-left: 10px;
    margin-right: 10px;
}
.kpi-strip, .gis-layout, .data-panels, .finance-grid, .client-console, .dashboard-layout {
    margin-left: 10px;
    margin-right: 10px;
}

.command-hero {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    align-items: flex-end;
    min-height: 220px;
    margin-bottom: 18px;
    padding: 28px;
    border: 1px solid var(--line);
    background:
        linear-gradient(120deg, rgba(12, 16, 23, .94), rgba(12, 16, 23, .76)),
        url("/images/netstar/hero-propuesta-4-backbone-premium.png") center / cover no-repeat;
    box-shadow: 0 18px 70px rgba(0,0,0,.28);
}
.command-hero h2 {
    max-width: 850px;
    margin: 6px 0 10px;
    font-size: clamp(32px, 4vw, 58px);
    line-height: .98;
}
.command-hero p { max-width: 760px; margin: 0; color: var(--muted); }
.status-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}
.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 34px;
    padding: 0 12px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.28);
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}
.status-pill::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--muted);
}
.status-pill.online::before, .map-legend .online, .node.online::before { background: var(--lime); }
.status-pill.unstable::before, .map-legend .unstable, .node.unstable::before { background: var(--amber); }
.status-pill.down::before, .map-legend .down, .node.down::before { background: var(--red); }

.console-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 18px;
}
.console-card {
    position: relative;
    display: grid;
    gap: 12px;
    min-height: 260px;
    padding: 20px;
    overflow: hidden;
    border: 1px solid var(--line);
    background:
        radial-gradient(circle at 100% 0%, rgba(182,255,46,.12), transparent 14rem),
        linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.018));
    box-shadow: 0 16px 48px rgba(0,0,0,.22);
}
.console-card::after {
    content: "";
    position: absolute;
    inset: auto 18px 18px auto;
    width: 70px;
    height: 70px;
    border: 1px solid rgba(255,255,255,.06);
    transform: rotate(18deg);
}
.console-card:hover {
    transform: translateY(-2px);
    border-color: rgba(182,255,46,.36);
}
.console-card strong {
    position: relative;
    z-index: 1;
    font-size: 24px;
}
.console-card p {
    position: relative;
    z-index: 1;
    margin: 0;
    color: var(--muted);
}
.console-icon {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255,255,255,.1);
    background: rgba(0,0,0,.28);
    color: var(--lime);
    font-size: 14px;
    font-weight: 900;
}
.console-card dl {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 8px;
    margin: auto 0 0;
}
.console-card dl div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding-top: 8px;
    border-top: 1px solid rgba(255,255,255,.07);
}
.console-card dt { color: var(--muted); }
.console-card dd { margin: 0; font-weight: 900; }
.console-card.violet .console-icon { color: var(--violet); }
.console-card.amber .console-icon { color: var(--amber); }
.console-card.red .console-icon { color: var(--red); }

.network-console, .console-workbench {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(320px, .65fr);
    gap: 16px;
    margin-bottom: 16px;
}
.network-map { min-height: 520px; }
.map-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}
.map-legend span { display: inline-flex; align-items: center; gap: 7px; }
.map-legend i {
    width: 9px;
    height: 9px;
    border-radius: 999px;
}
.map-canvas {
    position: relative;
    min-height: 410px;
    margin-top: 18px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.07);
    background:
        linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px),
        radial-gradient(circle at 48% 46%, rgba(182,255,46,.16), transparent 13rem),
        radial-gradient(circle at 75% 27%, rgba(143,92,255,.18), transparent 11rem),
        #090c12;
    background-size: 44px 44px, 44px 44px, auto, auto, auto;
}
.fiber, .radio {
    position: absolute;
    height: 3px;
    transform-origin: left center;
    border-radius: 999px;
    opacity: .82;
}
.fiber { background: linear-gradient(90deg, rgba(182,255,46,.2), var(--lime), rgba(182,255,46,.15)); }
.radio {
    height: 2px;
    background: repeating-linear-gradient(90deg, rgba(143,92,255,.1), var(--violet) 9px, transparent 10px, transparent 18px);
}
.f1 { left: 18%; top: 55%; width: 38%; transform: rotate(-19deg); }
.f2 { left: 45%; top: 42%; width: 31%; transform: rotate(26deg); }
.f3 { left: 45%; top: 48%; width: 34%; transform: rotate(-30deg); }
.r1 { left: 47%; top: 48%; width: 28%; transform: rotate(8deg); }
.r2 { left: 18%; top: 56%; width: 27%; transform: rotate(27deg); }
.node {
    position: absolute;
    min-width: 118px;
    border: 1px solid rgba(255,255,255,.12);
    background: rgba(9,12,18,.86);
    color: var(--text);
    padding: 11px 12px 11px 28px;
    text-align: left;
    box-shadow: 0 14px 38px rgba(0,0,0,.32);
}
.node::before {
    content: "";
    position: absolute;
    left: 11px;
    top: 16px;
    width: 9px;
    height: 9px;
    border-radius: 999px;
    box-shadow: 0 0 18px currentColor;
}
.node strong, .node small { display: block; }
.node small { margin-top: 3px; color: var(--muted); }
.node.core { left: 12%; top: 48%; }
.node.n1 { left: 38%; top: 25%; }
.node.n2 { left: 69%; top: 35%; }
.node.n3 { left: 72%; top: 67%; }
.node.n4 { left: 40%; top: 70%; }
.node.n5 { left: 17%; top: 76%; }
.incident-panel .compact div, .ops-list.compact div { padding: 12px; }
.console-main-panel { min-height: 420px; }
.kanban-preview {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 18px;
}
.kanban-preview div {
    min-height: 132px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.2);
    padding: 15px;
}
.kanban-preview span {
    display: block;
    width: 32px;
    height: 4px;
    margin-bottom: 12px;
    background: linear-gradient(90deg, var(--lime), var(--violet));
}
.kanban-preview strong { display: block; margin-bottom: 6px; }
.kanban-preview p { margin: 0; color: var(--muted); }

.ghost-button {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, .04);
    color: var(--text);
    padding: 9px 12px;
    cursor: pointer;
}
.ghost-button:hover {
    border-color: rgba(182, 255, 46, .5);
    color: var(--lime);
}
.survey-editor {
    display: grid;
    grid-template-columns: 280px minmax(520px, 1fr) 360px;
    gap: 12px;
    align-items: start;
}
.survey-tools,
.survey-inspector {
    position: sticky;
    top: 16px;
}
.tool-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}
.tool-grid button,
.map-actions button {
    border: 1px solid var(--line);
    background: rgba(255,255,255,.035);
    color: var(--text);
    min-height: 38px;
    cursor: pointer;
}
.tool-grid button.active,
.tool-grid button:hover,
.map-actions button:hover {
    border-color: rgba(182,255,46,.55);
    background: rgba(182,255,46,.12);
    color: var(--lime);
}
.editor-hint,
.layer-list,
.online-image-policy,
.analysis-box {
    margin-top: 14px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.18);
    padding: 12px;
    display: grid;
    gap: 8px;
}
.editor-hint strong,
.layer-list strong,
.online-image-policy strong,
.analysis-box strong {
    color: var(--text);
}
.editor-hint span,
.online-image-policy span,
.analysis-box span {
    color: var(--muted);
    font-size: .82rem;
    line-height: 1.35;
}
.layer-list label {
    display: flex;
    gap: 8px;
    align-items: center;
    color: var(--muted);
    font-size: .84rem;
}
.compact-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.image-search-results {
    border: 1px solid var(--line);
    background: rgba(115, 92, 255, .07);
    padding: 10px;
    display: grid;
    gap: 8px;
}
.image-search-results strong {
    color: var(--text);
}
.image-search-results a {
    color: var(--lime);
    text-decoration: none;
    border: 1px solid var(--line);
    background: rgba(0,0,0,.18);
    padding: 8px;
    font-size: .8rem;
}
.image-search-results span {
    color: var(--muted);
    font-size: .76rem;
    line-height: 1.35;
}
.survey-map-card {
    min-height: 710px;
}
.survey-map-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}
.survey-map-head strong,
.survey-map-head span {
    display: block;
}
.survey-map-head span {
    color: var(--muted);
    font-size: .82rem;
    margin-top: 3px;
}
.map-actions {
    display: flex;
    gap: 8px;
}
.survey-map {
    min-height: 650px;
    border: 1px solid var(--line);
    background: #071018;
    position: relative;
}
.survey-map-loading {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: var(--muted);
    background:
        linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px),
        #071018;
    background-size: 42px 42px;
}
.survey-submap-marker,
.survey-device-marker {
    display: grid;
    place-items: center;
}
.survey-submap-marker span,
.survey-device-marker span {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border: 2px solid var(--lime);
    background: rgba(8,10,14,.9);
    box-shadow: 0 0 18px rgba(182,255,46,.28);
}
.survey-submap-marker span {
    border-color: var(--violet);
    box-shadow: 0 0 18px rgba(115,92,255,.32);
}
.survey-submap-marker img,
.survey-device-marker img {
    max-width: 24px;
    max-height: 24px;
    object-fit: contain;
}
.survey-submap-marker b,
.survey-device-marker b {
    font-size: .66rem;
    color: var(--text);
}
.inspector-form {
    display: grid;
    gap: 10px;
}
.inspector-form label {
    display: grid;
    gap: 5px;
    color: var(--muted);
    font-size: .78rem;
}
.inspector-form input,
.inspector-form select,
.inspector-form textarea {
    width: 100%;
    border: 1px solid var(--line);
    background: rgba(2,5,10,.72);
    color: var(--text);
    padding: 9px;
    outline: none;
}
.inspector-form input:focus,
.inspector-form select:focus,
.inspector-form textarea:focus {
    border-color: var(--lime);
}
.form-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}
.monitoring-model {
    display: grid;
    gap: 10px;
}
.monitoring-model div {
    border: 1px solid var(--line);
    background: rgba(255,255,255,.025);
    padding: 11px;
}
.monitoring-model strong,
.monitoring-model span {
    display: block;
}
.monitoring-model span {
    color: var(--muted);
    margin-top: 5px;
    font-size: .82rem;
    line-height: 1.35;
}
.network-help-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(0, 0, 0, .72);
    display: grid;
    place-items: center;
    padding: 24px;
}
.network-help-overlay[hidden] {
    display: none;
}
.network-help-dialog {
    width: min(980px, 96vw);
    max-height: 88vh;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.14);
    background: #080c12;
    box-shadow: 0 30px 90px rgba(0,0,0,.55);
}
.network-help-head {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: center;
    padding: 18px 20px;
    border-bottom: 1px solid var(--line);
    background: rgba(255,255,255,.03);
}
.network-help-head span {
    display: block;
    color: var(--lime);
    text-transform: uppercase;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .08em;
}
.network-help-head h2 {
    margin: 4px 0 0;
    font-size: 1.35rem;
}
.network-help-head button {
    border: 1px solid var(--line);
    background: rgba(255,255,255,.04);
    color: var(--text);
    padding: 9px 12px;
    cursor: pointer;
}
.network-help-body {
    max-height: calc(88vh - 88px);
    overflow: auto;
    padding: 18px 20px 22px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}
.network-help-body section {
    border: 1px solid var(--line);
    background: rgba(255,255,255,.025);
    padding: 14px;
}
.network-help-body h3 {
    margin: 0 0 8px;
    font-size: .98rem;
}
.network-help-body p,
.network-help-body li {
    color: var(--muted);
    line-height: 1.45;
    font-size: .86rem;
}
.network-help-body p {
    margin: 0;
}
.network-help-body ol {
    margin: 0;
    padding-left: 18px;
}

@media (max-width: 1050px) {
    .login-screen, .app-shell, .workspace-grid, .console-grid, .console-access-grid, .network-console, .console-workbench, .dashboard-layout, .gis-layout, .support-console, .ticket-filter-row, .ticket-kpi-grid, .ticket-main-grid, .ticket-bottom-grid, .finance-grid, .client-console, .data-panels, .survey-editor { grid-template-columns: 1fr; }
    .sidebar { position: static; height: auto; }
    .stats-grid, .kpi-strip, .kpi-strip.finance, .kpi-strip.mini { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .command-hero { display: grid; }
    .finance-grid .wide-table, .event-rail { grid-column: auto; grid-row: auto; }
}

@media (max-width: 640px) {
    .main-panel { padding: 18px; }
    .stats-grid, .kpi-strip, .kpi-strip.finance, .kpi-strip.mini, .status-grid, .state-cards, .quality-grid, .split-actions, .ticket-metrics, .ticket-actions, .dispatch-form { grid-template-columns: 1fr; }
    .hero-panel, .topbar, .dashboard-toolbar, .module-toolbar { display: grid; }
    .toolbar-actions { justify-content: flex-start; }
    .ticket-list div { grid-template-columns: 12px 1fr; }
    .ticket-list p, .ticket-list small { grid-column: 2; }
    .kanban-preview { grid-template-columns: 1fr; }
    .map-canvas { min-height: 520px; }
    .gis-map-canvas { min-height: 520px; }
    .map-layer-box { position: relative; top: auto; left: auto; margin-bottom: 10px; }
    .conversation-head, .record-head { align-items: flex-start; }
    .conversation-head button { margin-left: 0; }
}
