/* ══════════════════════════════════════════════════════════════════════════
   HFS SITE ASSESSMENT MODULE STYLES (hfs.css)
   Scoped entirely to HFS components; maintains 100% base GIS compatibility
   ══════════════════════════════════════════════════════════════════════════ */

/* 1. MODAL BACKDROP & CARD (ChatGPT / Claude Style) */
.hfs-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(8, 12, 20, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: hfsFadeIn 0.25s ease-out;
}

@keyframes hfsFadeIn {
  from { opacity: 0; transform: scale(0.98); }
  to { opacity: 1; transform: scale(1); }
}

.hfs-modal-card {
  background: var(--bg-dropdown, #0d1527);
  border: 1px solid var(--border-highlight, rgba(255, 255, 255, 0.16));
  border-radius: 16px;
  width: 100%;
  max-width: 680px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.hfs-modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.02);
}

.hfs-modal-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.hfs-modal-icon {
  font-size: 24px;
}

.hfs-modal-title h3 {
  font-size: 15px;
  font-weight: 700;
  color: #38bdf8;
  letter-spacing: 0.5px;
}

.hfs-modal-sub {
  font-size: 11px;
  color: var(--text-secondary, #94a3b8);
}

.hfs-modal-body {
  padding: 18px 20px;
  overflow-y: auto;
  max-height: 70vh;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.hfs-modal-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  background: rgba(255, 255, 255, 0.02);
}

/* Quick Presets Banner */
.hfs-presets-banner {
  background: rgba(56, 189, 248, 0.08);
  border: 1px dashed rgba(56, 189, 248, 0.35);
  border-radius: 8px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Dropzone */
.hfs-dropzone {
  border: 2px dashed rgba(56, 189, 248, 0.4);
  background: rgba(255, 255, 255, 0.02);
  border-radius: 12px;
  padding: 28px 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.hfs-dropzone.dragover, .hfs-dropzone:hover {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.06);
}

.hfs-drop-icon {
  font-size: 32px;
  margin-bottom: 6px;
}

.hfs-dropzone h4 {
  font-size: 14px;
  color: var(--text-main, #f8fafc);
  margin-bottom: 4px;
}

.hfs-dropzone p {
  font-size: 11px;
  color: var(--text-secondary, #94a3b8);
  margin-bottom: 12px;
}

.hfs-supported-formats {
  font-size: 10px;
  color: #64748b;
  margin-top: 10px;
}

/* Staged items list */
.hfs-staged-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
}

.hfs-staged-item {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  border-radius: 6px;
  padding: 6px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
/* Validation Box */
.hfs-validation-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  border-radius: 8px;
  padding: 12px;
}

.hfs-validation-box h5 {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary, #94a3b8);
  margin-bottom: 8px;
}

.hfs-val-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.hfs-val-item {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  padding: 4px 6px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 4px;
}

.val-pass, .val-available { color: #34d399 !important; }
.val-pending { color: #fbbf24 !important; }
.val-fail { color: #f87171 !important; }

/* Buttons & Inputs */
.hfs-btn-primary {
  background: #0284c7;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  padding: 8px 16px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.hfs-btn-primary:hover { background: #0369a1; }

.hfs-btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-main, #f8fafc);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.12));
  border-radius: 6px;
  padding: 8px 14px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.hfs-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
}

.hfs-btn-icon {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
}

.hfs-btn-icon:hover { color: #ffffff; }

.hfs-input {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  padding: 6px 10px;
  color: #f8fafc;
  font-size: 12px;
}

/* 2. SLIDE-OVER DASHBOARD DRAWER */
.hfs-drawer {
  position: fixed;
  top: 52px;
  right: -520px;
  width: 480px;
  height: calc(100vh - 52px);
  background: var(--bg-sidebar, rgba(10, 16, 30, 0.94));
  border-left: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.09));
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 10000;
  display: flex;
  flex-direction: column;
  transition: right 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}

.hfs-drawer.open { right: 0; }

.hfs-drawer-header {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.02);
}

.hfs-drawer-title { display: flex; align-items: center; gap: 10px; }
.hfs-drawer-title h3 { font-size: 13px; font-weight: 700; color: #38bdf8; margin: 0; }
.hfs-subtitle { font-size: 10px; color: #94a3b8; }
.hfs-drawer-controls { display: flex; align-items: center; gap: 6px; }

.hfs-drawer-content {
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Cards & Summary */
.hfs-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  border-radius: 10px;
  padding: 14px;
}

.hfs-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.hfs-card-header h4 { font-size: 12px; font-weight: 700; color: #f8fafc; margin: 0; }

.hfs-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 12px;
}

.hfs-sum-item {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 6px;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
}

.hfs-sum-label { font-size: 10px; color: #94a3b8; margin-bottom: 2px; }
.hfs-sum-val { font-size: 13px; font-weight: 700; color: #f8fafc; }
.hfs-sum-sub { font-size: 10px; color: #64748b; margin-top: 2px; }

.highlight-blue { color: #38bdf8 !important; }
.highlight-amber { color: #fbbf24 !important; }
.highlight-green { color: #34d399 !important; }

.hfs-score-banner {
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 8px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Tables */
.hfs-table {
  border-collapse: collapse;
  width: 100%;
}

.hfs-table th {
  background: rgba(255, 255, 255, 0.06);
  color: #94a3b8;
  font-size: 10px;
  font-weight: 600;
  text-align: left;
  padding: 6px 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.hfs-table td {
  padding: 6px 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  color: #f8fafc;
  font-size: 11px;
}

.hfs-info-row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  font-size: 11px;
}

.hfs-info-row span { color: #94a3b8; }
.hfs-info-row strong { color: #f8fafc; }

/* Layer Grid */
.hfs-layers-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
  max-height: 220px;
  overflow-y: auto;
  padding-right: 4px;
}

.hfs-layer-checkbox {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #cbd5e1;
  cursor: pointer;
}

.hfs-badge {
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
}

.hfs-badge-accent {
  background: rgba(56, 189, 248, 0.2);
  color: #38bdf8;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
}

/* 7. FLOATING DEMARCATION GUIDE BANNER */
.hfs-draw-guide {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(13, 21, 39, 0.94);
  border: 1px solid #38bdf8;
  box-shadow: 0 10px 25px -5px rgba(2, 132, 199, 0.4), 0 0 15px rgba(56, 189, 248, 0.25);
  border-radius: 30px;
  padding: 10px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  z-index: 10000;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  animation: hfsGuideSlideDown 0.3s ease-out;
}

@keyframes hfsGuideSlideDown {
  from { opacity: 0; transform: translate(-50%, -20px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

.hfs-draw-guide-icon {
  font-size: 20px;
  animation: hfsPulse 1.5s infinite;
}

@keyframes hfsPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.18); }
  100% { transform: scale(1); }
}

.hfs-draw-guide-text {
  font-size: 13px;
  font-weight: 600;
  color: #f8fafc;
}

.hfs-draw-guide-sub {
  font-size: 11px;
  font-weight: 400;
  color: #94a3b8;
}

.hfs-draw-guide-btn {
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid rgba(239, 68, 68, 0.5);
  color: #fca5a5;
  border-radius: 16px;
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.hfs-draw-guide-btn:hover {
  background: rgba(239, 68, 68, 0.4);
  color: #ffffff;
}

/* 8. CITY FINDER, TRANSIT & COMPARISON MATRIX STYLES */
.hfs-city-chip {
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.3);
  color: #38bdf8;
  border-radius: 20px;
  padding: 4px 10px;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.hfs-city-chip:hover {
  background: rgba(56, 189, 248, 0.25);
  border-color: #38bdf8;
  color: #ffffff;
}

.hfs-city-card {
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.hfs-city-card:hover {
  border-color: rgba(56, 189, 248, 0.45) !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -4px rgba(0, 0, 0, 0.5);
}

.hfs-city-pin {
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: pointer;
}

.hfs-city-pin:hover {
  transform: scale(1.25);
  z-index: 1000 !important;
}

.val-fail {
  background: rgba(239, 68, 68, 0.2);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.4);
}

.val-pass {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.val-pending {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.val-available {
  background: rgba(56, 189, 248, 0.2);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.4);
}

/* 9. COLOR-CODED CABLE BOQ TABLE & MAP STYLES */
.hfs-cable-row {
  transition: all 0.2s ease;
  cursor: pointer;
}

.hfs-cable-row:hover {
  background: rgba(255, 255, 255, 0.07) !important;
  transform: translateX(4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.hfs-cable-tag {
  display: inline-block;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 1px 6px;
  border-radius: 4px;
  letter-spacing: 0.4px;
}

.hfs-volt-badge {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 800;
  text-align: center;
  white-space: nowrap;
}

.hfs-volt-ht {
  background: rgba(239, 68, 68, 0.22);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.6);
  box-shadow: 0 0 8px rgba(239, 68, 68, 0.25);
}

.hfs-volt-lt {
  background: rgba(245, 158, 11, 0.22);
  color: #fde047;
  border: 1px solid rgba(245, 158, 11, 0.6);
}

.hfs-volt-dc {
  background: rgba(20, 184, 166, 0.22);
  color: #5eead4;
  border: 1px solid rgba(20, 184, 166, 0.6);
}

.hfs-cable-spec-pill {
  font-family: 'Consolas', 'Courier New', monospace;
  font-size: 10px;
  font-weight: 600;
  color: #f1f5f9;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 2px 6px;
  border-radius: 4px;
  white-space: nowrap;
  display: inline-block;
}

.hfs-drop-badge {
  font-weight: 700;
  font-size: 11px;
}

.hfs-cable-legend {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

/* CAD & Engineering Layout Elements */
.hfs-firewall-tag {
  background: rgba(220, 38, 38, 0.2);
  color: #fca5a5;
  border: 1px solid rgba(220, 38, 38, 0.6);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.hfs-cad-label {
  font-family: 'Consolas', 'Courier New', monospace;
  font-size: 10px;
  font-weight: 700;
  color: #f8fafc;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(56, 189, 248, 0.4);
  border-radius: 3px;
  padding: 1px 4px;
  pointer-events: none;
  white-space: nowrap;
}

.hfs-esd-pulse {
  animation: hfsEsdPulse 1.5s infinite;
}

@keyframes hfsEsdPulse {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.25); opacity: 0.7; }
  100% { transform: scale(1); opacity: 1; }
}

