
/* ==========================================
   NYC 3D URBAN HEAT INTELLIGENCE
   Fullscreen Digital Twin Dashboard
========================================== */

:root {
    --background: #07101e;
    --panel: rgba(8, 20, 38, 0.94);
    --panel-strong: rgba(7, 17, 32, 0.97);

    --purple: #9b70ff;
    --purple-light: #c7aaff;
    --cyan: #27cfff;
    --orange: #ff825e;
    --green: #54dfa0;
    --red: #ff555d;

    --white: #f4f7ff;
    --muted: #a1aec2;
    --border: rgba(130, 158, 198, 0.22);
}

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

html,
body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: var(--background);
    color: var(--white);
    font-family: Inter, "Segoe UI", Arial, sans-serif;
}

button {
    font: inherit;
}

.main-scene {
    position: fixed;
    inset: 0;
    overflow: hidden;
    background: #07101e;
}

/* ==========================================
   3D CITY VIEW
========================================== */

#cesiumContainer {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    background: #07101e;
}

.cesium-viewer {
    width: 100%;
    height: 100%;
}

.cesium-viewer-bottom {
    display: none !important;
}

.cesium-widget-credits {
    display: none !important;
}

/* ==========================================
   TOP HEADER
========================================== */

.topbar {
    position: absolute;
    z-index: 20;
    top: 15px;
    left: 18px;
    right: 18px;
    height: 72px;
    padding: 0 22px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    border: 1px solid var(--border);
    border-radius: 13px;

    background: rgba(5, 14, 29, 0.88);
    backdrop-filter: blur(20px);

    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.22);
}

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

.brand-icon {
    width: 45px;
    height: 45px;
    display: grid;
    place-items: center;

    border-radius: 11px;
    border: 1px solid rgba(39, 207, 255, 0.6);

    color: var(--cyan);
    background: rgba(39, 207, 255, 0.1);

    font-size: 15px;
    font-weight: 800;
    letter-spacing: 1px;

    box-shadow: 0 0 20px rgba(39, 207, 255, 0.13);
}

.brand-copy h1 {
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 1.2px;
    color: var(--white);
}

.brand-copy p {
    margin-top: 6px;
    color: var(--muted);
    font-size: 10px;
    letter-spacing: 1.3px;
}

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

.top-chip {
    min-height: 37px;
    padding: 0 13px;

    display: flex;
    align-items: center;
    gap: 9px;

    border: 1px solid var(--border);
    border-radius: 8px;

    background: rgba(255, 255, 255, 0.045);
    color: #dce6f6;

    font-size: 9px;
    letter-spacing: 1px;
}

.live-dot,
.scene-live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 12px rgba(84, 223, 160, 0.8);
}

.chip-icon {
    color: var(--cyan);
    font-size: 16px;
}

/* ==========================================
   LEFT LAYER MENU
========================================== */

.layer-menu {
    position: absolute;
    z-index: 12;
    top: 108px;
    left: 20px;
    width: 275px;
    padding: 18px;

    border: 1px solid var(--border);
    border-radius: 13px;

    background: var(--panel);
    backdrop-filter: blur(20px);

    box-shadow: 0 16px 45px rgba(0, 0, 0, 0.35);
}

.menu-heading {
    padding: 3px 3px 16px;
}

.eyebrow {
    color: var(--purple-light);
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 2px;
}

.menu-heading h2 {
    margin-top: 8px;
    font-size: 21px;
    font-weight: 600;
    color: var(--white);
}

.layer-item {
    width: 100%;
    min-height: 65px;
    padding: 9px 8px;

    display: flex;
    align-items: center;
    gap: 10px;

    border: 1px solid transparent;
    border-radius: 9px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.055);

    color: var(--white);
    background: transparent;

    text-align: left;
    cursor: pointer;

    transition:
        background 0.22s ease,
        border-color 0.22s ease,
        transform 0.22s ease;
}

.layer-item:hover {
    background: rgba(155, 112, 255, 0.10);
    border-color: rgba(155, 112, 255, 0.23);
}

.layer-item.active {
    background: linear-gradient(
        110deg,
        rgba(39, 207, 255, 0.18),
        rgba(39, 207, 255, 0.045)
    );

    border: 1px solid rgba(39, 207, 255, 0.5);

    box-shadow: inset 3px 0 0 var(--cyan);
}

.layer-icon {
    width: 36px;
    height: 36px;
    flex-shrink: 0;

    display: grid;
    place-items: center;

    border-radius: 8px;
    background: rgba(255, 255, 255, 0.055);

    font-size: 19px;
}

.building-icon { color: #c9d7eb; }
.temperature-icon { color: #ff825e; }
.ndvi-icon { color: var(--green); }
.density-icon { color: var(--cyan); }
.ai-icon { color: var(--purple-light); }

.layer-info {
    flex: 1;
    min-width: 0;

    display: flex;
    flex-direction: column;
    gap: 5px;
}

.layer-info b {
    font-size: 10px;
    font-weight: 600;
    color: #f0f4ff;
}

.layer-info small {
    font-size: 8px;
    color: var(--muted);
}

.layer-state {
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 0.7px;
}

.active-state { color: var(--green); }
.pending-state { color: #b5a2eb; }

.menu-divider {
    height: 1px;
    margin: 14px 0;
    background: rgba(255, 255, 255, 0.10);
}

.connection-box {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 3px 2px;
}

.connection-indicator {
    width: 8px;
    height: 8px;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--purple);
    box-shadow: 0 0 12px rgba(155, 112, 255, 0.7);
}

.connection-box div {
    display: flex;
    flex-direction: column;
    gap: 5px;
    min-width: 0;
}

.connection-box b {
    color: var(--purple-light);
    font-size: 8px;
    letter-spacing: 1.3px;
}

.connection-box small {
    color: var(--muted);
    font-size: 8px;
    line-height: 1.5;
}

/* ==========================================
   RIGHT OVERVIEW PANEL
========================================== */

.overview-panel {
    position: absolute;
    z-index: 12;
    top: 108px;
    right: 20px;
    width: 260px;
    padding: 19px;

    border: 1px solid var(--border);
    border-radius: 13px;

    background: var(--panel);
    backdrop-filter: blur(20px);

    box-shadow: 0 16px 45px rgba(0, 0, 0, 0.35);
}

.card-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}

.card-heading h3 {
    margin-top: 7px;
    font-size: 15px;
    font-weight: 600;
}

.heading-icon {
    color: var(--cyan);
    font-size: 25px;
}

.overview-stat {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 17px;
}

.overview-stat span {
    color: #bdc8d9;
    font-size: 10px;
}

.overview-stat strong {
    color: var(--cyan);
    font-size: 23px;
    font-weight: 700;
    letter-spacing: 0.2px;
}

.overview-stat strong.hot-value {
    color: var(--orange);
}

.overview-stat strong.cool-value {
    color: #56d8ff;
}

.temperature-scale {
    margin-top: 18px;
}

.scale-gradient,
.heat-gradient {
    height: 10px;
    border-radius: 20px;
    background: linear-gradient(
        90deg,
        #258bff,
        #27d5d0,
        #bce96a,
        #ffd54c,
        #ff8a36,
        #f23e42
    );
}

.scale-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 7px;

    color: #c7d1e0;
    font-size: 8px;
    font-weight: 700;
}

.overview-divider {
    height: 1px;
    margin: 16px 0;
    background: rgba(255, 255, 255, 0.10);
}

.compact-stat {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    margin-top: 12px;
}

.compact-stat strong {
    font-size: 15px;
}

/* ==========================================
   SELECTED LOCATION CARD
========================================== */

.location-card {
    position: absolute;
    z-index: 11;
    top: 50%;
    left: 50%;

    width: 315px;
    padding: 19px;

    transform: translate(-20%, -42%);

    border: 1px solid rgba(39, 207, 255, 0.34);
    border-radius: 13px;

    background: rgba(7, 18, 34, 0.94);
    backdrop-filter: blur(20px);

    box-shadow:
        0 18px 50px rgba(0, 0, 0, 0.4),
        0 0 25px rgba(39, 207, 255, 0.06);
}

.location-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.location-card h3 {
    margin-top: 8px;
    font-size: 17px;
    font-weight: 700;
}

.location-symbol {
    color: var(--cyan);
    font-size: 23px;
}

.details-description {
    margin-top: 12px;
    color: var(--muted);
    font-size: 9px;
    line-height: 1.7;
}

.location-divider {
    height: 1px;
    margin: 15px 0;
    background: rgba(255, 255, 255, 0.10);
}

.location-metric {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 14px 0;
}

.metric-symbol {
    width: 35px;
    height: 35px;
    flex-shrink: 0;

    display: grid;
    place-items: center;

    border-radius: 9px;
    background: rgba(255, 255, 255, 0.06);

    font-size: 19px;
}

.thermal-symbol { color: var(--orange); }
.air-symbol { color: var(--cyan); }
.risk-symbol { color: var(--red); }

.location-metric div {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.location-metric small {
    color: #c0cada;
    font-size: 9px;
}

.location-metric strong {
    color: var(--cyan);
    font-size: 17px;
}

#areaTemperature { color: var(--orange); }
#areaNDVI { color: var(--green); }
#areaClassification { color: var(--red); }

#aiInsight {
    margin-top: 9px;
    color: #aab9cf;
    font-size: 9px;
    line-height: 1.8;
}

/* ==========================================
   MINI MAP
========================================== */

.map-label {
    position: absolute;
    z-index: 10;
    left: 20px;
    bottom: 73px;

    width: 235px;
    padding: 10px;

    display: flex;
    align-items: center;
    gap: 12px;

    border: 1px solid var(--border);
    border-radius: 11px;

    background: rgba(7, 18, 34, 0.91);
    backdrop-filter: blur(15px);
}

.mini-map {
    position: relative;
    width: 85px;
    height: 65px;
    overflow: hidden;
    flex-shrink: 0;

    border-radius: 7px;
    background: #102c43;
}

.map-grid {
    position: absolute;
    inset: 0;

    background-image:
        linear-gradient(rgba(78, 161, 191, 0.20) 1px, transparent 1px),
        linear-gradient(90deg, rgba(78, 161, 191, 0.20) 1px, transparent 1px);

    background-size: 10px 10px;
}

.map-river {
    position: absolute;
    top: -12px;
    left: 36px;
    width: 24px;
    height: 95px;
    transform: rotate(24deg);
    background: rgba(38, 141, 202, 0.45);
    border-radius: 50%;
}

.map-focus {
    position: absolute;
    top: 23px;
    left: 25px;
    width: 28px;
    height: 20px;
    border: 2px solid var(--cyan);
    box-shadow: 0 0 12px var(--cyan);
}

.north-label {
    position: absolute;
    top: 4px;
    right: 5px;
    color: white;
    font-size: 8px;
}

.map-caption {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.map-caption b {
    font-size: 10px;
    letter-spacing: 0.5px;
}

.map-caption small {
    color: var(--muted);
    font-size: 7px;
    letter-spacing: 0.5px;
}

/* ==========================================
   TEMPERATURE TREND
========================================== */

.trend-panel {
    position: absolute;
    z-index: 10;
    right: 20px;
    bottom: 73px;

    width: 300px;
    min-height: 175px;
    padding: 17px;

    border: 1px solid var(--border);
    border-radius: 12px;

    background: var(--panel);
    backdrop-filter: blur(18px);

    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.30);
}

.trend-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.trend-header h3 {
    margin-top: 7px;
    font-size: 14px;
}

.trend-period {
    color: var(--muted);
    font-size: 7px;
    letter-spacing: 0.8px;
}

.trend-placeholder {
    height: 95px;
    margin-top: 12px;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;

    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.trend-axis {
    align-self: stretch;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    color: #9aa9bf;
    font-size: 8px;
}

.trend-empty {
    flex: 1;
    height: 75px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;

    border-left: 1px solid rgba(255, 255, 255, 0.10);
    background:
        linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px);
    background-size: 100% 18px;

    text-align: center;
}

.trend-line-icon {
    color: var(--orange);
    font-size: 26px;
}

.trend-empty p {
    color: #e5eaf5;
    font-size: 8px;
}

.trend-empty small {
    color: var(--muted);
    font-size: 7px;
}

/* ==========================================
   SCENE LABEL AND STATUS
========================================== */

.scene-label {
    position: absolute;
    z-index: 8;
    left: 320px;
    bottom: 27px;

    display: flex;
    align-items: center;
    gap: 9px;

    color: #dce6f5;
    font-size: 8px;
    letter-spacing: 1.2px;

    text-shadow: 0 1px 5px #000;
}

.scene-live-dot {
    width: 6px;
    height: 6px;
}

.scene-separator {
    color: var(--purple-light);
}

.status {
    position: absolute;
    z-index: 20;
    top: 103px;
    left: 320px;

    display: flex;
    align-items: center;

    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 7px;

    background: rgba(7, 18, 34, 0.88);
    backdrop-filter: blur(10px);

    color: #dce6f5;
    font-size: 8px;
    letter-spacing: 1px;
}

.pulse {
    width: 7px;
    height: 7px;
    margin-right: 8px;
    flex-shrink: 0;

    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 10px var(--green);

    animation: pulseGlow 1.8s infinite;
}

@keyframes pulseGlow {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.35; }
}

/* ==========================================
   THERMAL LEGEND
========================================== */

.thermal-legend {
    position: absolute;
    z-index: 14;
    right: 300px;
    bottom: 270px;
    width: 210px;
    padding: 13px;

    border: 1px solid var(--border);
    border-radius: 9px;

    background: rgba(7, 18, 34, 0.94);
    backdrop-filter: blur(15px);

    color: white;
    font-size: 10px;
}

.thermal-legend b {
    font-size: 10px;
}

.heat-gradient {
    margin-top: 10px;
}

.heat-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 6px;
    color: var(--muted);
    font-size: 8px;
}

/* ==========================================
   RESPONSIVE
========================================== */

@media (max-width: 1250px) {
    .layer-menu {
        width: 245px;
    }

    .overview-panel {
        width: 230px;
    }

    .location-card {
        width: 280px;
        transform: translate(-15%, -40%);
    }

    .trend-panel {
        width: 260px;
    }

    .thermal-legend {
        right: 275px;
    }
}

@media (max-width: 950px) {
    .topbar {
        left: 10px;
        right: 10px;
    }

    .layer-menu {
        left: 10px;
        width: 220px;
    }

    .overview-panel {
        right: 10px;
        width: 205px;
    }

    .location-card {
        left: 50%;
        top: 55%;
        width: 255px;
        transform: translate(-50%, -50%);
    }

    .trend-panel {
        right: 10px;
        bottom: 65px;
        width: 230px;
    }

    .map-label {
        left: 10px;
        bottom: 65px;
        width: 210px;
    }

    .status {
        left: 245px;
    }

    .scene-label {
        display: none;
    }

    .thermal-legend {
        display: none;
    }
}

@media (max-width: 650px) {
    .topbar {
        height: 62px;
        padding: 0 10px;
    }

    .brand {
        gap: 8px;
    }

    .brand-icon {
        width: 35px;
        height: 35px;
        font-size: 12px;
    }

    .brand-copy h1 {
        font-size: 9px;
        letter-spacing: 0.4px;
    }

    .brand-copy p {
        font-size: 7px;
        letter-spacing: 0.4px;
    }

    .top-info {
        display: none;
    }

    .layer-menu {
        top: 87px;
        width: 190px;
        padding: 11px;
    }

    .menu-heading h2 {
        font-size: 16px;
    }

    .layer-item {
        min-height: 55px;
        gap: 7px;
        padding: 7px 4px;
    }

    .layer-icon {
        width: 29px;
        height: 29px;
        font-size: 15px;
    }

    .layer-info b {
        font-size: 8px;
    }

    .layer-info small {
        font-size: 7px;
    }

    .layer-state {
        font-size: 7px;
    }

    .overview-panel {
        top: auto;
        right: 10px;
        bottom: 70px;
        width: 165px;
        padding: 12px;
    }

    .card-heading h3 {
        font-size: 11px;
    }

    .overview-stat {
        margin-top: 11px;
    }

    .overview-stat span {
        font-size: 8px;
    }

    .overview-stat strong {
        font-size: 17px;
    }

    .compact-stat strong {
        font-size: 12px;
    }

    .location-card {
        top: 48%;
        left: 52%;
        width: 210px;
        padding: 12px;
    }

    .location-card h3 {
        font-size: 13px;
    }

    .location-metric {
        margin: 9px 0;
    }

    .location-metric strong {
        font-size: 14px;
    }

    .trend-panel {
        display: none;
    }

    .map-label {
        display: none;
    }

    .status {
        top: 91px;
        left: auto;
        right: 10px;
        font-size: 7px;
    }
}

/* =========================================
   NYC DIGITAL TWIN - NEON UI REDESIGN
   ========================================= */

:root {
    --cyan: #00cfff;
    --blue: #087cff;
    --purple: #a56bff;
    --orange: #ff642d;
    --green: #40e9a0;

    --panel: rgba(5, 16, 34, 0.91);
    --border: rgba(44, 172, 255, 0.35);
}

/* MAIN HEADER */

.topbar {
    top: 10px;
    left: 14px;
    right: 14px;
    height: 65px;
    padding: 0 16px;
    border-radius: 13px;
    border: 1px solid rgba(35, 170, 255, .45);

    background: linear-gradient(
        110deg,
        rgba(3, 19, 43, .96),
        rgba(12, 28, 57, .91)
    );

    box-shadow:
        0 0 25px rgba(0, 145, 255, .15),
        inset 0 0 20px rgba(0, 140, 255, .06);
}

.brand-icon {
    width: 43px;
    height: 43px;
    font-size: 16px;
    box-shadow: 0 0 18px rgba(0, 207, 255, .35);
}

.brand-copy h1 {
    font-size: 15px;
    letter-spacing: .7px;
}

.brand-copy p {
    font-size: 10px;
}

.top-chip {
    min-height: 34px;
    border-radius: 9px;
    background: rgba(0, 130, 255, .09);
    border-color: rgba(55, 165, 255, .3);
}

/* LEFT LAYER MENU */

.layer-menu {
    top: 88px;
    left: 14px;
    width: 122px;
    padding: 8px;

    border: 1px solid rgba(50, 160, 255, .42);
    border-radius: 12px;

    background: rgba(3, 15, 34, .91);

    box-shadow:
        0 0 22px rgba(0, 130, 255, .12),
        0 12px 30px rgba(0, 0, 0, .35);
}

/* Remove the large heading and connection section */

.menu-heading,
.menu-divider,
.connection-box {
    display: none;
}

.layer-item {
    min-height: 54px;
    padding: 7px 5px;
    gap: 7px;
    border-radius: 9px;
    border-bottom: 1px solid rgba(255,255,255,.07);
}

.layer-item.active {
    background: linear-gradient(
        110deg,
        rgba(0, 130, 255, .48),
        rgba(0, 65, 160, .24)
    );

    border: 1px solid rgba(0, 190, 255, .85);

    box-shadow:
        inset 3px 0 0 #00cfff,
        0 0 16px rgba(0, 145, 255, .25);
}

.layer-icon {
    width: 27px;
    height: 29px;
    font-size: 17px;
    border-radius: 7px;
}

.layer-info {
    gap: 3px;
}

.layer-info b {
    font-size: 9px;
    white-space: nowrap;
}

.layer-info small {
    display: none;
}

.layer-state {
    font-size: 7px;
}

/* RIGHT THERMAL OVERVIEW */

.overview-panel {
    top: 88px;
    right: 14px;
    width: 220px;
    padding: 14px;

    border: 1px solid rgba(0, 175, 255, .55);
    border-radius: 12px;

    background: rgba(4, 17, 39, .93);

    box-shadow:
        0 0 22px rgba(0, 130, 255, .17),
        0 15px 35px rgba(0, 0, 0, .3);
}

.card-heading {
    padding-bottom: 11px;
}

.card-heading h3 {
    font-size: 13px;
}

.heading-icon {
    font-size: 22px;
}

.overview-stat {
    margin-top: 12px;
    gap: 4px;
}

.overview-stat span {
    font-size: 9px;
}

.overview-stat strong {
    font-size: 20px;
}

.temperature-scale {
    margin-top: 14px;
}

.scale-gradient {
    height: 10px;
    box-shadow: 0 0 10px rgba(0, 180, 255, .2);
}

.overview-divider {
    margin: 12px 0;
}

.compact-stat {
    margin-top: 9px;
}

.compact-stat strong {
    font-size: 13px;
}

/* LOCATION INTELLIGENCE */

.location-card {
    top: 23%;
    left: 55%;
    width: 270px;
    padding: 15px;

    transform: none;

    border: 1px solid rgba(0, 170, 255, .75);
    border-radius: 12px;

    background: rgba(3, 17, 39, .94);

    box-shadow:
        0 0 25px rgba(0, 140, 255, .2),
        0 15px 40px rgba(0, 0, 0, .35);
}

.location-card h3 {
    font-size: 15px;
}

.details-description {
    display: none;
}

.location-divider {
    margin: 10px 0;
}

.location-metric {
    margin: 10px 0;
    gap: 10px;
}

.metric-symbol {
    width: 32px;
    height: 32px;
}

.location-metric small {
    font-size: 9px;
}

.location-metric strong {
    font-size: 16px;
}

#aiInsight {
    font-size: 8px;
    line-height: 1.6;
}

/* MINI MAP */

.map-label {
    left: 14px;
    bottom: 14px;
    width: 165px;
    padding: 8px;
    gap: 8px;

    border: 1px solid rgba(0, 160, 255, .45);
    background: rgba(3, 17, 38, .91);

    box-shadow: 0 0 16px rgba(0, 140, 255, .13);
}

.mini-map {
    width: 78px;
    height: 58px;
}

.map-caption b {
    font-size: 9px;
}

.map-caption small {
    font-size: 7px;
}

/* TEMPERATURE TREND */

.trend-panel {
    right: 14px;
    bottom: 14px;
    width: 250px;
    min-height: 135px;
    padding: 12px;

    border: 1px solid rgba(0, 165, 255, .48);
    border-radius: 12px;

    background: rgba(3, 17, 38, .94);

    box-shadow:
        0 0 20px rgba(0, 130, 255, .15),
        0 12px 30px rgba(0, 0, 0, .3);
}

.trend-header h3 {
    font-size: 12px;
}

.trend-period {
    font-size: 6px;
}

.trend-placeholder {
    height: 75px;
    margin-top: 8px;
}

/* SCENE STATUS */

.scene-label {
    left: 195px;
    bottom: 17px;
    font-size: 8px;
}

.status {
    top: 88px;
    left: 155px;
    padding: 7px 10px;
    font-size: 7px;
    border-color: rgba(0, 190, 255, .3);
}

/* REMOVE EXTRA FLOATING LEGEND */

.thermal-legend {
    display: none;
}

/* NEON HOVER EFFECT */

.layer-item,
.top-chip,
.overview-panel,
.location-card,
.trend-panel,
.map-label {
    transition:
        border-color .25s ease,
        box-shadow .25s ease;
}

.layer-item:hover {
    border-color: var(--cyan);
    box-shadow: 0 0 13px rgba(0, 180, 255, .2);
}

/* RESPONSIVE */

@media (max-width: 950px) {
    .layer-menu {
        width: 112px;
    }

    .location-card {
        left: 40%;
        width: 245px;
    }

    .overview-panel {
        width: 195px;
    }

    .trend-panel {
        width: 220px;
    }
}

@media (max-width: 650px) {
    .layer-menu {
        top: 85px;
        width: 105px;
    }

    .location-card {
        top: 44%;
        left: 35%;
        width: 205px;
    }

    .overview-panel {
        width: 155px;
    }

    .trend-panel {
        display: none;
    }

    .map-label {
        display: none;
    }

    .status {
        display: none;
    }
}

/* ===== FINAL LAYOUT CORRECTION ===== */

/* Left menu */
.layer-menu {
    width: 175px !important;
    padding: 9px !important;
    top: 90px !important;
    left: 14px !important;
}

.layer-item {
    min-height: 55px !important;
    padding: 7px !important;
    gap: 8px !important;
}

.layer-icon {
    width: 30px !important;
    height: 30px !important;
    flex-shrink: 0;
}

.layer-info {
    flex: 1;
    min-width: 0;
}

.layer-info b {
    font-size: 10px !important;
    white-space: normal !important;
}

.layer-info small {
    display: block !important;
    font-size: 8px !important;
}

.layer-state {
    font-size: 8px !important;
    flex-shrink: 0;
}

/* Location card: hidden until building selection */
.location-card {
    display: none;
    top: 22% !important;
    left: 55% !important;
    width: 295px !important;
    transform: none !important;
}

.location-card.is-visible {
    display: block !important;
}

/* Overview */
.overview-panel {
    top: 90px !important;
    right: 14px !important;
    width: 220px !important;
}

/* Bottom temperature chart */
.trend-panel {
    display: block !important;
    right: 14px !important;
    bottom: 14px !important;
    width: 300px !important;
    min-height: 160px !important;
    padding: 14px !important;
    z-index: 15;
}

.trend-placeholder {
    height: 105px !important;
    margin-top: 8px !important;
    display: block !important;
    border: 0 !important;
}

@media (max-width: 950px) {
    .location-card {
        left: 40% !important;
        width: 250px !important;
    }
}

@media (max-width: 650px) {
    .layer-menu {
        width: 145px !important;
    }

    .trend-panel {
        width: 230px !important;
    }

    .location-card {
        left: 35% !important;
        width: 205px !important;
    }
}
.location-card-header {
    position: relative;
}

#closeLocation {
    border: 0;
    background: transparent;
    color: white;
    font-size: 23px;
    cursor: pointer;
}

#closeLocation:hover {
    color: #00cfff;
}

/* ===== FINAL LAYOUT CORRECTION ===== */

/* Left menu */
.layer-menu {
    width: 175px !important;
    padding: 9px !important;
    top: 90px !important;
    left: 14px !important;
}

.layer-item {
    min-height: 55px !important;
    padding: 7px !important;
    gap: 8px !important;
}

.layer-icon {
    width: 30px !important;
    height: 30px !important;
    flex-shrink: 0;
}

.layer-info {
    flex: 1;
    min-width: 0;
}

.layer-info b {
    font-size: 10px !important;
    white-space: normal !important;
}

.layer-info small {
    display: block !important;
    font-size: 8px !important;
}

.layer-state {
    font-size: 8px !important;
    flex-shrink: 0;
}

/* Location card: hidden until building selection */
.location-card {
    display: none;
    top: 22% !important;
    left: 55% !important;
    width: 295px !important;
    transform: none !important;
}

.location-card.is-visible {
    display: block !important;
}

/* Overview */
.overview-panel {
    top: 90px !important;
    right: 14px !important;
    width: 220px !important;
}

/* Bottom temperature chart */
.trend-panel {
    display: block !important;
    right: 14px !important;
    bottom: 14px !important;
    width: 300px !important;
    min-height: 160px !important;
    padding: 14px !important;
    z-index: 15;
}

.trend-placeholder {
    height: 105px !important;
    margin-top: 8px !important;
    display: block !important;
    border: 0 !important;
}

@media (max-width: 950px) {
    .location-card {
        left: 40% !important;
        width: 250px !important;
    }
}

@media (max-width: 650px) {
    .layer-menu {
        width: 145px !important;
    }

    .trend-panel {
        width: 230px !important;
    }

    .location-card {
        left: 35% !important;
        width: 205px !important;
    }
}

/* ==========================================
   FINAL GLASSMORPHISM EFFECT
   NYC 3D URBAN HEAT INTELLIGENCE
========================================== */

/* Main top bar */
.topbar {
    background: rgba(5, 14, 29, 0.48) !important;
    backdrop-filter: blur(18px) saturate(145%);
    -webkit-backdrop-filter: blur(18px) saturate(145%);
    border-color: rgba(39, 207, 255, 0.28);
}

/* Left Data Layers */
.layer-menu {
    background: rgba(3, 15, 34, 0.48) !important;
    backdrop-filter: blur(18px) saturate(145%);
    -webkit-backdrop-filter: blur(18px) saturate(145%);
    border-color: rgba(50, 160, 255, 0.32);
}

/* Right Thermal Overview */
.overview-panel {
    background: rgba(4, 17, 39, 0.48) !important;
    backdrop-filter: blur(18px) saturate(145%);
    -webkit-backdrop-filter: blur(18px) saturate(145%);
    border-color: rgba(0, 175, 255, 0.38);
}

/* Selected Location */
.location-card {
    background: rgba(3, 17, 39, 0.48) !important;
    backdrop-filter: blur(18px) saturate(145%);
    -webkit-backdrop-filter: blur(18px) saturate(145%);
    border-color: rgba(0, 170, 255, 0.48);
}

/* Temperature Trend */
.trend-panel {
    background: rgba(3, 17, 38, 0.48) !important;
    backdrop-filter: blur(18px) saturate(145%);
    -webkit-backdrop-filter: blur(18px) saturate(145%);
    border-color: rgba(0, 165, 255, 0.35);
}

/* Bottom Map Label */
.map-label {
    background: rgba(3, 17, 38, 0.48) !important;
    backdrop-filter: blur(18px) saturate(145%);
    -webkit-backdrop-filter: blur(18px) saturate(145%);
}

/* Top information chips */
.top-chip {
    background: rgba(0, 130, 255, 0.10) !important;
    backdrop-filter: blur(12px);
}

/* System status */
.status {
    background: rgba(7, 18, 34, 0.48) !important;
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
}

/* Inner icons */
.layer-icon,
.metric-symbol {
    background: rgba(255, 255, 255, 0.07);
}

/* Active layer */
.layer-item.active {
    background: rgba(0, 130, 255, 0.22) !important;
}

/* Keep text fully visible */
.topbar *,
.layer-menu *,
.overview-panel *,
.location-card *,
.trend-panel *,
.map-label *,
.status * {
    opacity: 1;
}

/* Soft glass borders */
.topbar,
.layer-menu,
.overview-panel,
.location-card,
.trend-panel,
.map-label {
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.20),
        inset 0 1px 0 rgba(255, 255, 255, 0.07);
}
/* RETURN TO HOME PAGE */

.home-button {
    display: flex;
    align-items: center;
    gap: 8px;

    padding: 10px 16px;

    color: #27cfff;
    text-decoration: none;

    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;

    background: rgba(0, 130, 255, 0.12);
    border: 1px solid rgba(39, 207, 255, 0.4);
    border-radius: 7px;

    backdrop-filter: blur(12px);
    transition: 0.3s ease;
}

.home-button:hover {
    background: rgba(0, 130, 255, 0.25);
    box-shadow: 0 0 20px rgba(39, 207, 255, 0.2);
}

.home-button span:first-child {
    font-size: 19px;
}

/* ==========================================
   HOME BUTTON — LANDING PAGE NAVIGATION
========================================== */

.home-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    padding: 10px 15px;

    color: #27cfff;
    text-decoration: none;

    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;

    white-space: nowrap;

    background: rgba(0, 130, 255, 0.12);
    border: 1px solid rgba(39, 207, 255, 0.38);
    border-radius: 7px;

    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);

    transition: all 0.3s ease;
}

.home-button:hover {
    color: #ffffff;
    background: rgba(0, 130, 255, 0.25);
    border-color: #27cfff;

    box-shadow:
        0 0 15px rgba(39, 207, 255, 0.22),
        inset 0 0 12px rgba(39, 207, 255, 0.08);

    transform: translateY(-2px);
}

.home-icon {
    font-size: 19px;
    line-height: 1;
}
