:root {
    /* Palette HSL tailored - Industrial Premium Cyberpunk Theme */
    --bg-deep: 222, 28%, 7%;        /* #0a0d14 */
    --bg-card: 219, 24%, 12%;       /* #161d2b */
    --bg-card-hover: 219, 24%, 16%;
    --border-dim: 220, 15%, 18%;
    --border-glow: 24, 95%, 50%;    /* Safety Orange */
    --text-primary: 210, 20%, 98%;  /* Bright Slate */
    --text-secondary: 215, 15%, 68%;/* M muted */
    
    /* Accents */
    --accent-orange: 24, 95%, 53%;  /* High-viz Safety Orange #f97316 */
    --accent-orange-hover: 24, 95%, 62%;
    --accent-cyan: 188, 86%, 53%;   /* Cyber Tech Cyan #06b6d4 */
    --accent-cyan-glow: 188, 86%, 53%, 0.4;
    --accent-green: 150, 84%, 40%;  /* Active Operational Green */
    --accent-red: 0, 84%, 55%;      /* Emergency/Alert red */
    
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --glass-blur: blur(14px) saturate(180%);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
    -webkit-user-drag: none;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: hsl(var(--bg-deep));
    color: hsl(var(--text-primary));
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

h1, h2, h3, h4, .font-heading {
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
}

/* --- HEADER --- */
header {
    height: 70px;
    background: linear-gradient(180deg, rgba(10, 13, 20, 0.98) 0%, rgba(6, 8, 12, 0.95) 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    z-index: 100;
    position: relative;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
}

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

.header-logo {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, hsl(var(--accent-orange)) 0%, #a23c00 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(249, 115, 22, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.header-logo svg {
    width: 24px;
    height: 24px;
    fill: white;
}

.header-title-container {
    display: flex;
    flex-direction: column;
}

.header-title {
    font-size: 1.25rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    background: linear-gradient(90deg, #ffffff 0%, #cbd5e1 55%, hsl(var(--accent-orange)) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 800;
}

.header-subtitle {
    font-size: 0.72rem;
    color: hsl(var(--text-secondary));
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 600;
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 20px;
}

.user-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(22, 29, 43, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 6px 14px;
    border-radius: 40px;
}

.user-avatar {
    width: 26px;
    height: 26px;
    background: hsl(var(--accent-cyan));
    color: hsl(var(--bg-deep));
    border-radius: 50%;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-name {
    font-size: 0.78rem;
    font-weight: 500;
    color: hsl(var(--text-primary));
}

/* --- MAIN LAYOUT --- */
.dashboard-viewport {
    flex: 1;
    display: flex;
    overflow: hidden;
}

/* --- 360 VIEWER LEFT PANEL (60%) --- */
.viewer-panel {
    flex: 6;
    position: relative;
    background-color: #000;
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
}

#panorama-container {
    width: 100%;
    height: 100%;
}

/* Floating Toolbar Overlay (Left side inside viewer) */
.floating-toolbar {
    position: absolute;
    top: 24px;
    left: 24px;
    background: rgba(10, 13, 20, 0.85);
    backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 80;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.toolbar-btn {
    width: 42px;
    height: 42px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 8px;
    color: hsl(var(--text-secondary));
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}

.toolbar-btn svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
}

.toolbar-btn:hover {
    background-color: rgba(255, 255, 255, 0.04);
    color: hsl(var(--text-primary));
}

.toolbar-btn.active {
    background-color: rgba(6, 182, 212, 0.15);
    border-color: rgba(6, 182, 212, 0.3);
    color: hsl(var(--accent-cyan));
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.2);
}

/* Interaction Toast Notification */
.tool-toast {
    position: absolute;
    top: 24px;
    left: 80px;
    background: rgba(10, 13, 20, 0.9);
    backdrop-filter: var(--glass-blur);
    border: 1px solid hsl(var(--accent-cyan));
    border-radius: 8px;
    padding: 10px 18px;
    font-size: 0.78rem;
    color: hsl(var(--text-primary));
    z-index: 85;
    pointer-events: none;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slide-in-left 0.3s ease-out;
}

.tool-toast svg {
    width: 16px;
    height: 16px;
    stroke: hsl(var(--accent-cyan));
}

/* 2D Floor Plan Overlay (Bottom-Left inside viewer) */
.floorplan-overlay {
    position: absolute;
    bottom: 24px;
    left: 24px;
    width: 240px;
    height: 170px;
    background: rgba(10, 13, 20, 0.85);
    backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 12px;
    z-index: 80;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.floorplan-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.68rem;
    color: hsl(var(--text-secondary));
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.floorplan-svg-container {
    flex: 1;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.04);
    position: relative;
    overflow: hidden;
}

.floorplan-svg-container svg {
    width: 100%;
    height: 100%;
}

.floorplan-node {
    cursor: pointer;
    transition: var(--transition-smooth);
}

.floorplan-node circle {
    fill: #4b5563;
    stroke: #1f2937;
    stroke-width: 1.5;
    transition: var(--transition-smooth);
}

.floorplan-node:hover circle {
    fill: hsl(var(--accent-orange));
    r: 7;
}

.floorplan-node.active circle {
    fill: hsl(var(--accent-cyan));
    stroke: #0891b2;
    stroke-width: 2;
    r: 7;
}

.floorplan-node.active .floorplan-pulse {
    stroke: hsl(var(--accent-cyan));
    fill: none;
    stroke-width: 1;
    r: 10;
    opacity: 1;
    animation: node-pulse 1.8s infinite;
}

/* Custom CSS Hotspot Overlay inside Pannellum */
.custom-hotspot {
    width: 48px;
    height: 48px;
    background: rgba(249, 115, 22, 0.2);
    border: 2px solid hsl(var(--accent-orange));
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 15px rgba(249, 115, 22, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
    animation: hot-pulse 2s infinite;
}

.custom-hotspot::after {
    content: '';
    width: 8px;
    height: 8px;
    background-color: white;
    border-radius: 50%;
    transition: var(--transition-smooth);
}

.custom-hotspot:hover {
    background-color: hsl(var(--accent-orange));
    transform: scale(1.18);
    box-shadow: 0 0 25px hsl(var(--accent-orange));
}

.custom-hotspot:hover::after {
    background-color: hsl(var(--bg-deep));
}

/* 360 Bottom Bar View Controls Overlay */
.view-controls-overlay {
    position: absolute;
    bottom: 24px;
    right: 24px;
    background: rgba(10, 13, 20, 0.85);
    backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    padding: 6px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 80;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

/* --- TELEMETRY & CENTER SCADA SIDEBAR (40%) --- */
.scada-panel {
    flex: 4;
    background: hsl(var(--bg-deep));
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    padding: 24px;
    gap: 20px;
    z-index: 90;
}

/* Block Section Structure */
.panel-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.section-label {
    font-size: 0.72rem;
    color: hsl(var(--text-secondary));
    letter-spacing: 1.5px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-label svg {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    stroke-width: 2.2;
    fill: none;
}

/* SDK Status Card widget */
.sdk-status-card {
    background: linear-gradient(135deg, hsl(var(--bg-card)) 0%, rgba(22, 29, 43, 0.5) 100%);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.25);
    position: relative;
    overflow: hidden;
}

.sdk-status-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, hsl(var(--accent-cyan)), transparent);
}

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

.sdk-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: hsl(var(--text-primary));
}

.sdk-badge {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 6px;
}

.sdk-badge-dot {
    width: 6px;
    height: 6px;
    background-color: hsl(var(--accent-green));
    border-radius: 50%;
    box-shadow: 0 0 6px hsl(var(--accent-green));
}

.sdk-btn-row {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 12px;
}

.btn-primary {
    background: linear-gradient(90deg, hsl(var(--accent-cyan)) 0%, #0891b2 100%);
    border: none;
    color: hsl(var(--bg-deep));
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 0.82rem;
    padding: 10px 16px;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: var(--transition-smooth);
}

.btn-primary svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    stroke-width: 2.2;
    fill: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: hsl(var(--text-primary));
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 0.82rem;
    padding: 10px 16px;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: var(--transition-smooth);
}

.btn-secondary svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.15);
}

/* Facility Overview Stats grid */
.overview-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.stat-item {
    background: hsl(var(--bg-card));
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    padding: 12px 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    text-align: center;
    transition: var(--transition-smooth);
}

.stat-item:hover {
    background-color: hsl(var(--bg-card-hover));
    transform: translateY(-2px);
}

.stat-icon {
    width: 32px;
    height: 32px;
    background: rgba(6, 182, 212, 0.05);
    border: 1px solid rgba(6, 182, 212, 0.15);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: hsl(var(--accent-cyan));
}

.stat-icon svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
}

.stat-details {
    display: flex;
    flex-direction: column;
}

.stat-num {
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    color: hsl(var(--text-primary));
}

.stat-lbl {
    font-size: 0.6rem;
    color: hsl(var(--text-secondary));
    text-transform: uppercase;
}

/* Zone Navigation Table */
.zone-nav-table {
    display: flex;
    flex-direction: column;
    background: hsl(var(--bg-card));
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 14px;
    overflow: hidden;
}

.zone-nav-header {
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 10px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.zone-header-title {
    font-size: 0.72rem;
    font-weight: 700;
    color: hsl(var(--text-secondary));
    text-transform: uppercase;
}

.zone-view-all {
    font-size: 0.65rem;
    color: hsl(var(--accent-cyan));
    cursor: pointer;
    text-decoration: none;
    font-weight: 600;
}

.zone-view-all:hover {
    color: hsl(var(--accent-cyan));
    text-decoration: underline;
}

.zone-row {
    padding: 10px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    transition: var(--transition-smooth);
}

.zone-row:last-child {
    border-bottom: none;
}

.zone-row-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.zone-row-id {
    font-family: monospace;
    font-size: 0.75rem;
    color: hsl(var(--text-secondary));
}

.zone-row-name {
    font-size: 0.78rem;
    font-weight: 600;
    color: hsl(var(--text-primary));
}

.zone-row-lbl {
    font-size: 0.72rem;
    color: hsl(var(--text-secondary));
}

.zone-row:hover {
    background-color: hsl(var(--bg-card-hover));
}

.zone-row.active {
    background-color: rgba(6, 182, 212, 0.06);
}

.zone-row.active .zone-row-name {
    color: hsl(var(--accent-cyan));
}

.zone-row.active .zone-row-id {
    color: hsl(var(--accent-cyan));
}

/* Asset Cards Grid */
.assets-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.asset-card {
    background: hsl(var(--bg-card));
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.asset-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0;
    background-color: hsl(var(--accent-orange));
    transition: var(--transition-smooth);
}

.asset-card:hover {
    background-color: hsl(var(--bg-card-hover));
    transform: translateY(-2px);
    border-color: rgba(255, 255, 255, 0.08);
}

.asset-card.active {
    background-color: rgba(249, 115, 22, 0.06);
    border-color: rgba(249, 115, 22, 0.3);
}

.asset-card.active::before {
    width: 3px;
}

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

.asset-tag {
    font-family: monospace;
    font-size: 0.72rem;
    font-weight: 700;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 2px 6px;
    border-radius: 4px;
    color: hsl(var(--text-secondary));
}

.asset-status-dot {
    width: 6px;
    height: 6px;
    background-color: hsl(var(--accent-green));
    border-radius: 50%;
    box-shadow: 0 0 5px hsl(var(--accent-green));
}

.asset-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: hsl(var(--text-primary));
}

.asset-details {
    font-size: 0.68rem;
    color: hsl(var(--text-secondary));
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* Maintenance Workflow Workflow bar */
.workflow-stages {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: hsl(var(--bg-card));
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 14px;
    padding: 10px;
    position: relative;
}

.workflow-connector {
    position: absolute;
    top: 50%;
    left: 12.5%;
    width: 75%;
    height: 2px;
    background-color: rgba(255, 255, 255, 0.05);
    z-index: 1;
    transform: translateY(-50%);
}

.workflow-stage {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
    cursor: pointer;
    z-index: 2;
    transition: var(--transition-smooth);
}

.workflow-stage-bubble {
    width: 24px;
    height: 24px;
    background: #1f2937;
    border: 1.5px solid #374151;
    border-radius: 50%;
    font-size: 0.72rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: justify;
    color: hsl(var(--text-secondary));
    transition: var(--transition-smooth);
    align-items: center;
    justify-content: center;
}

.workflow-stage-label {
    font-size: 0.65rem;
    font-weight: 600;
    color: hsl(var(--text-secondary));
    text-transform: uppercase;
}

.workflow-stage:hover .workflow-stage-bubble {
    background-color: #374151;
    color: white;
}

.workflow-stage.active .workflow-stage-bubble {
    background: linear-gradient(135deg, hsl(var(--accent-orange)) 0%, #c2410c 100%);
    border-color: hsl(var(--accent-orange));
    color: white;
    box-shadow: 0 0 10px rgba(249, 115, 22, 0.4);
}

.workflow-stage.active .workflow-stage-label {
    color: hsl(var(--accent-orange));
    font-weight: 700;
}

/* Closeout Maintenance Table log */
.closeout-log-widget {
    background: hsl(var(--bg-card));
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 14px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.closeout-header {
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.closeout-table {
    width: 100%;
    border-collapse: collapse;
}

.closeout-table th {
    font-size: 0.62rem;
    color: hsl(var(--text-secondary));
    text-transform: uppercase;
    text-align: left;
    padding: 10px 16px;
    background: rgba(0,0,0,0.05);
    border-bottom: 1px solid rgba(255,255,255,0.03);
}

.closeout-table td {
    padding: 10px 16px;
    font-size: 0.72rem;
    color: hsl(var(--text-secondary));
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.closeout-table tr:last-child td {
    border-bottom: none;
}

.closeout-table tr:hover td {
    background-color: rgba(255,255,255,0.01);
}

.wo-desc-cell {
    color: hsl(var(--text-primary)) !important;
    font-weight: 600;
}

.status-badge-closed {
    background: rgba(16, 185, 129, 0.1);
    color: hsl(var(--accent-green));
    border: 1px solid rgba(16, 185, 129, 0.2);
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
}

.status-badge-active {
    background: rgba(249, 115, 22, 0.1);
    color: hsl(var(--accent-orange));
    border: 1px solid rgba(249, 115, 22, 0.2);
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
}

/* Security Notice */
.privacy-notice {
    background: rgba(255, 255, 255, 0.01);
    border: 1px dashed rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.privacy-icon {
    color: hsl(var(--text-secondary));
    flex-shrink: 0;
}

.privacy-icon svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
}

.privacy-text {
    font-size: 0.68rem;
    color: hsl(var(--text-secondary));
    line-height: 1.4;
}

/* --- GLASSMORPHIC POPUP MODALS --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(4, 6, 10, 0.8);
    backdrop-filter: blur(8px);
    z-index: 200;
    display: none;
    align-items: center;
    justify-content: center;
    animation: fade-in 0.25s ease-out;
}

.modal-content {
    width: 460px;
    background: rgba(22, 29, 43, 0.75);
    backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 18px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
    animation: scale-up 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

.modal-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: hsl(var(--text-primary));
}

.modal-close {
    background: transparent;
    border: none;
    color: hsl(var(--text-secondary));
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}

.modal-close svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    stroke-width: 2.2;
}

.modal-close:hover {
    color: hsl(var(--text-primary));
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-label {
    font-size: 0.68rem;
    font-weight: 700;
    color: hsl(var(--text-secondary));
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-input {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 10px 14px;
    color: hsl(var(--text-primary));
    font-family: inherit;
    font-size: 0.82rem;
    transition: var(--transition-smooth);
}

.form-input:focus {
    outline: none;
    border-color: hsl(var(--accent-cyan));
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.2);
}

/* --- KEYFRAME ANIMATIONS --- */
@keyframes hot-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(249, 115, 22, 0.6);
    }
    70% {
        box-shadow: 0 0 0 12px rgba(249, 115, 22, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(249, 115, 22, 0);
    }
}

@keyframes node-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(6, 182, 212, 0.6);
        r: 7;
        opacity: 0.8;
    }
    70% {
        box-shadow: 0 0 0 8px rgba(6, 182, 212, 0);
        r: 11;
        opacity: 0;
    }
    100% {
        box-shadow: 0 0 0 0 rgba(6, 182, 212, 0);
        r: 7;
        opacity: 0;
    }
}

@keyframes sweep {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scale-up {
    from {
        opacity: 0;
        transform: scale(0.92);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slide-in-left {
    from {
        opacity: 0;
        transform: translateX(-15px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Custom Scrollbar for Right SCADA Panel */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* --- TELEMETRY PULSE ORANGE ANIMATION --- */
.pulse-orange-text {
    animation: text-pulse 2s infinite;
}

@keyframes text-pulse {
    0% {
        text-shadow: 0 0 2px rgba(249, 115, 22, 0.2);
    }
    50% {
        text-shadow: 0 0 8px rgba(249, 115, 22, 0.6);
        color: #ff9248;
    }
    100% {
        text-shadow: 0 0 2px rgba(249, 115, 22, 0.2);
    }
}

/* --- RESPONSIBILITY COLLAPSING --- */
@media (max-width: 1200px) {
    .dashboard-viewport {
        flex-direction: column;
    }
    .viewer-panel {
        height: 55vh;
        flex: none;
    }
    .scada-panel {
        flex: none;
        height: 45vh;
    }
}
