/* ════════════════════════════════════════════════════════════════
   GEAUXCONNECT — CIVIL 3D-STYLE TOOLS CSS  v3
═══════════════════════════════════════════════════════════════════ */

/* When a Civil tool is taking over clicks */
.cad-civil-active,
.cad-civil-active * {
  cursor: crosshair !important;
}
.cad-civil-active .leaflet-marker-icon,
.cad-civil-active .leaflet-marker-pane,
.cad-civil-active .leaflet-overlay-pane svg path {
  cursor: crosshair !important;
}

/* Active tool banner — sits at top-center of map */
.cad-active-banner {
  position: absolute;
  top: 12px; left: 50%;
  transform: translateX(-50%);
  z-index: 12200;
  background: linear-gradient(135deg, rgba(247,203,93,.95), rgba(247,180,60,.95));
  color: #1a0f06;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.25);
  font: 800 12px 'Segoe UI', Arial, sans-serif;
  letter-spacing: .03em;
  box-shadow: 0 6px 20px rgba(0,0,0,.5);
  pointer-events: none;
  display: none;
  white-space: nowrap;
  max-width: calc(100% - 40px);
  overflow: hidden; text-overflow: ellipsis;
}
.cad-banner-cancel {
  font-weight: 600;
  font-size: 10px;
  opacity: 0.7;
  margin-left: 8px;
}

/* Active tool button glow — same style as user's existing .tool-btn.active */
.cad-panel-body .cad-btn.active {
  background: linear-gradient(135deg, rgba(247,203,93,.30), rgba(247,180,60,.20)) !important;
  border-color: rgba(247,203,93,.55) !important;
  color: var(--gold-2, #f7cb5d) !important;
  box-shadow: 0 0 0 2px rgba(247,203,93,.20), 0 4px 12px rgba(247,203,93,.15);
}

/* ─── Status bar ─── */
.cad-statusbar {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: 18px; padding: 8px 14px; margin-top: 8px;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(10,20,34,.92), rgba(14,26,40,.92));
  border: 1px solid var(--line, rgba(247,203,93,.24));
  font-family: 'Consolas','Cascadia Mono','Menlo',monospace;
  font-size: 11px; color: var(--muted, #d3dfeb);
  box-shadow: 0 4px 14px rgba(0,0,0,.25);
}
.cad-statusbar .g { display: inline-flex; align-items: center; gap: 5px; }
.cad-statusbar .g.push { margin-left: auto; }
.cad-statusbar .lbl { color: var(--gold-2, #f7cb5d); font-weight: 700; letter-spacing: .04em; }
.cad-statusbar .val { color: #fff; font-weight: 600; }

/* ─── Civil tools menu ─── */
.cad-menu {
  position: absolute; z-index: 12000;
  background: rgba(10,20,34,.98);
  border: 1px solid var(--line, rgba(247,203,93,.24));
  border-radius: 16px;
  box-shadow: 0 12px 40px rgba(0,0,0,.5);
  padding: 12px;
  min-width: 380px;
  font-family: 'Segoe UI', Arial, sans-serif;
}
.cad-menu-head {
  font-size: 10px; font-weight: 900; letter-spacing: .14em;
  text-transform: uppercase; color: var(--gold-2, #f7cb5d);
  margin: 8px 4px 6px;
  display: flex; justify-content: space-between; align-items: center;
}
.cad-menu-head:first-child { margin-top: 0; }
.cad-menu-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.cad-menu-btn {
  text-align: left; padding: 10px 12px; border-radius: 10px;
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08);
  color: #fff; font-size: 12px; font-weight: 700; cursor: pointer;
  transition: all .14s ease;
}
.cad-menu-btn:hover {
  background: rgba(247,203,93,.14);
  border-color: rgba(247,203,93,.30);
  color: var(--gold-2, #f7cb5d);
}

/* ─── Tiny help (?) button ─── */
.cad-help-tiny {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(247,203,93,.18); color: var(--gold-2, #f7cb5d);
  border: 1px solid rgba(247,203,93,.40);
  font: 800 12px 'Segoe UI', sans-serif; cursor: pointer;
  text-transform: none; letter-spacing: 0;
}
.cad-help-tiny:hover { background: rgba(247,203,93,.32); }

/* ════════════════════════════════════════════════════════════
   SIDE-DOCK PANEL  — works in fullscreen
════════════════════════════════════════════════════════════ */
.cad-panel {
  position: fixed; top: 0; bottom: 0;
  width: 380px; max-width: 100vw;
  background: linear-gradient(180deg, rgba(18,34,52,.98), rgba(14,26,40,.98));
  border-left: 1px solid var(--line, rgba(247,203,93,.24));
  border-right: 1px solid var(--line, rgba(247,203,93,.24));
  box-shadow: 0 20px 50px rgba(0,0,0,.5);
  display: flex; flex-direction: column;
  z-index: 12500;          /* HIGHER than fullscreen wrap */
  font-family: 'Segoe UI', Arial, sans-serif;
  color: var(--cream, #f6efe5);
  transition: transform .25s ease;
  pointer-events: auto;
}
.cad-panel-right { right: 0; transform: translateX(100%); }
.cad-panel-left  { left:  0; transform: translateX(-100%); }
body.cad-panel-open .cad-panel-right,
body.cad-panel-open .cad-panel-left { transform: translateX(0); }

.cad-panel-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 14px;
  background: rgba(0,0,0,.28);
  border-bottom: 1px solid var(--line, rgba(247,203,93,.24));
  font-size: 14px; font-weight: 900; color: var(--gold-2, #f7cb5d);
}
.cad-panel-head-r { display: inline-flex; gap: 6px; align-items: center; }
.cad-panel-btn {
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.10);
  color: #fff; width: 28px; height: 28px; border-radius: 7px;
  cursor: pointer; font-size: 13px;
}
.cad-panel-btn:hover { background: rgba(255,255,255,.12); }
.cad-panel-body { flex: 1; overflow-y: auto; padding: 14px; }

/* Map shifts when panel is open (only on bigger screens) */
@media (min-width: 900px) {
  body.cad-panel-open.cad-panel-shift-right .map-wrap { margin-right: 380px; }
  body.cad-panel-open.cad-panel-shift-left  .map-wrap { margin-left:  380px; }
}

/* ════════════════════════════════════════════════════════════
   OVERLAY popup (for inputs that need confirmation, e.g. New Pipe)
   These float ABOVE the panel and the map.
════════════════════════════════════════════════════════════ */
.cad-overlay {
  position: fixed; inset: 0; z-index: 13500;
  background: rgba(0,8,20,.55);
  display: flex; align-items: center; justify-content: center;
  backdrop-filter: blur(4px);
  font-family: 'Segoe UI', Arial, sans-serif;
}
.cad-overlay-card {
  width: min(540px, 92vw); max-height: 88vh; overflow: auto;
  background: linear-gradient(180deg, rgba(18,34,52,.98), rgba(14,26,40,.98));
  border: 1px solid var(--line, rgba(247,203,93,.24));
  border-radius: 18px;
  box-shadow: 0 20px 60px rgba(0,0,0,.65);
  color: var(--cream, #f6efe5);
}
.cad-overlay-head {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line, rgba(247,203,93,.24));
  font-size: 16px; font-weight: 900; color: var(--gold-2, #f7cb5d);
}
.cad-overlay .cad-form { padding: 16px 18px; }

/* ─── Form bits ─── */
.cad-form { display: grid; gap: 12px; }
.cad-form label {
  display: block; font-size: 12px; font-weight: 700;
  color: var(--gold-2, #f7cb5d); text-transform: uppercase;
  letter-spacing: .06em;
}
.cad-form input, .cad-form select, .cad-form textarea {
  width: 100%; margin-top: 6px;
  padding: 10px 12px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,.16);
  background: #183b59; color: #fff;
  font: 400 13px 'Segoe UI', Arial, sans-serif;
  outline: none;
}
.cad-form input[type="color"] { padding: 4px; height: 38px; }
.cad-form input[type="file"] { padding: 6px; }
.cad-form input:focus, .cad-form select:focus, .cad-form textarea:focus {
  border-color: rgba(247,203,93,.5);
  box-shadow: 0 0 0 3px rgba(247,203,93,.18);
}
.cad-row { display: flex; gap: 8px; align-items: flex-end; }
.cad-or { text-align: center; color: var(--muted, #d3dfeb); font-size: 11px; padding: 4px 0; }
.cad-form-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; align-items: center; }
.cad-btn {
  padding: 10px 14px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.08); color: #fff;
  font-size: 13px; font-weight: 800; cursor: pointer;
}
.cad-btn:hover { background: rgba(255,255,255,.16); }
.cad-btn.primary {
  background: linear-gradient(135deg, var(--blue, #3578b6), var(--blue-2, #1f5f99));
  border-color: rgba(255,255,255,.16);
}
.cad-btn.danger {
  background: linear-gradient(135deg, #b03030, #7c1e1e);
  border-color: rgba(255,120,120,.20);
}
.cad-help { font-size: 12px; color: var(--muted, #d3dfeb); line-height: 1.55; }
.cad-warn {
  background: rgba(192,64,64,0.18); color: #ffd2d2;
  border: 1px solid rgba(255,120,120,0.35);
  padding: 8px 12px; border-radius: 8px;
  font-size: 12px; font-weight: 700;
}

/* Help body */
.cad-help-body { font-size: 13px; line-height: 1.6; color: var(--cream, #f6efe5); }
.cad-help-body h3 { color: var(--gold-2, #f7cb5d); margin-top: 0; }
.cad-help-body h4 { color: var(--gold-2, #f7cb5d); margin-top: 14px; margin-bottom: 6px; font-size: 13px; }
.cad-help-body ol, .cad-help-body ul { margin: 6px 0 0 22px; }
.cad-help-body li { margin: 4px 0; }
.cad-help-body kbd {
  background: rgba(255,255,255,0.12); padding: 2px 6px; border-radius: 4px;
  font-family: monospace; font-size: 11px; border: 1px solid rgba(255,255,255,.18);
}
.cad-help-body code {
  background: rgba(255,255,255,0.10); padding: 1px 6px; border-radius: 4px;
  font-family: monospace; font-size: 12px; color: var(--gold-2, #f7cb5d);
}

/* Bookmarks */
.cad-bm-list { margin-top: 8px; display: grid; gap: 6px; }
.cad-bm-row {
  display: grid; grid-template-columns: 1fr auto auto;
  align-items: center; gap: 10px;
  padding: 8px 10px; border-radius: 10px;
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08);
}
.cad-bm-go { text-align: left; background: transparent; border: 0; color: #fff; font-weight: 700; cursor: pointer; font-size: 13px; }
.cad-bm-go:hover { color: var(--gold-2, #f7cb5d); }
.cad-bm-meta { font-size: 11px; color: var(--muted, #d3dfeb); font-family: monospace; }
.cad-bm-del { background: rgba(192,64,64,.6); border: 0; color: #fff; width: 26px; height: 26px; border-radius: 6px; cursor: pointer; }
.cad-empty { text-align: center; color: var(--muted, #d3dfeb); font-style: italic; padding: 14px 0; font-size: 13px; }

/* Pipe network summary */
.cad-pipe-summary {
  margin-top: 6px; padding: 10px 12px; border-radius: 12px;
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08);
}
.cad-pipe-summary-title {
  font-size: 11px; font-weight: 900; letter-spacing: .12em;
  text-transform: uppercase; color: var(--gold-2, #f7cb5d);
  margin-bottom: 8px;
}
.cad-pipe-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.cad-sub { font-size: 11px; font-weight: 800; color: var(--cream, #f6efe5); margin-bottom: 6px; opacity: 0.85; }
.cad-row-mini {
  display: flex; justify-content: space-between;
  font-size: 12px; padding: 4px 0;
  border-bottom: 1px solid rgba(255,255,255,.05);
}
.cad-row-mini:last-child { border-bottom: 0; }
.cad-row-mini.head { font-weight: 900; color: var(--gold-2, #f7cb5d); border-bottom: 1px solid var(--line); }

/* Map labels */
.cad-pipe-tooltip {
  background: rgba(10,20,34,.95) !important; color: #fff !important;
  border: 1px solid rgba(247,203,93,.35) !important; border-radius: 6px !important;
  font: 700 11px 'Consolas','Menlo',monospace !important;
  padding: 4px 7px !important; box-shadow: 0 4px 12px rgba(0,0,0,.4) !important;
}
.cad-pipe-tooltip.pipe { background: rgba(53,120,182,.95) !important; border-color: rgba(255,255,255,.30) !important; }
.cad-pipe-tooltip.culvert { background: rgba(205,91,28,.95) !important; }
.cad-pipe-tooltip.bridge { background: rgba(122,92,171,.95) !important; }
.cad-pipe-tooltip.road { background: rgba(60,60,60,.95) !important; }
.cad-pipe-tooltip.pad { background: rgba(205,155,81,.95) !important; }
.cad-pipe-tooltip:before { display: none !important; }

/* Bearing labels */
.cad-bd-label-icon { background: transparent; border: none; }
.cad-bd-chip {
  display: inline-block; padding: 3px 7px; border-radius: 4px;
  background: rgba(247,203,93,.95); color: #1a0f06;
  font: 700 10px 'Consolas','Menlo',monospace;
  box-shadow: 0 2px 6px rgba(0,0,0,.4); white-space: nowrap;
  border: 1px solid rgba(0,0,0,0.15);
}

/* Flow arrows */
.cad-flow-arrow { background: transparent !important; border: none !important; }
.cad-flow-arrow-inner {
  display: inline-block;
  font-size: 22px; line-height: 1;
  color: #1f88c4; text-shadow: 0 0 4px rgba(0,0,0,0.7);
  transform-origin: center;
}

/* Direction pad for Connect Points */
.cad-dirpad {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 6px;
  margin-top: 12px;
  padding: 12px;
  border-radius: 12px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
}
.cad-dirpad button {
  padding: 14px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.08);
  color: #fff; font-size: 18px; font-weight: 900;
  border-radius: 10px; cursor: pointer;
}
.cad-dirpad button:hover {
  background: rgba(247,203,93,.20); color: var(--gold-2, #f7cb5d);
  border-color: rgba(247,203,93,.40);
}
.cad-dirpad button.wide { grid-column: 1 / -1; font-size: 13px; }

/* Right-click context menu */
.cad-ctxmenu {
  position: absolute; z-index: 14000;
  background: rgba(10,20,34,.98);
  border: 1px solid var(--line, rgba(247,203,93,.24));
  border-radius: 10px; padding: 4px;
  box-shadow: 0 8px 24px rgba(0,0,0,.5);
  display: flex; flex-direction: column;
  font-family: 'Segoe UI', Arial, sans-serif;
}
.cad-ctxmenu button {
  background: transparent; border: 0; color: #fff;
  padding: 8px 14px; text-align: left; font-size: 13px; font-weight: 700;
  cursor: pointer; border-radius: 6px; min-width: 160px;
}
.cad-ctxmenu button:hover { background: rgba(247,203,93,.18); color: var(--gold-2, #f7cb5d); }
.cad-ctxmenu button.d:hover { background: rgba(192,64,64,.7); color: #fff; }

/* Quantity takeoff */
.cad-takeoff {
  margin-top: 6px; padding: 12px;
  border-radius: 12px;
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08);
}

/* 3D viewer */
.cad-3d-wrap {
  position: fixed; right: 18px; bottom: 70px; z-index: 11500;
  width: min(520px, 90vw); height: min(420px, 70vh);
  background: rgba(10,20,34,.98);
  border: 1px solid var(--line, rgba(247,203,93,.24));
  border-radius: 18px; overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,.6);
  display: flex; flex-direction: column;
}
.cad-3d-head, .cad-pano-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 14px;
  background: rgba(0,0,0,.35);
  border-bottom: 1px solid var(--line, rgba(247,203,93,.24));
  font: 800 13px 'Segoe UI', sans-serif;
  color: var(--gold-2, #f7cb5d);
}
.cad-3d-close, .cad-pano-close {
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.10);
  color: #fff; width: 26px; height: 26px; border-radius: 6px; cursor: pointer;
}
.cad-3d-map { flex: 1; }

/* Mapillary 360° pano */
.cad-pano-wrap {
  position: fixed; left: 18px; bottom: 70px; z-index: 11500;
  width: min(520px, 90vw); height: min(380px, 60vh);
  background: rgba(10,20,34,.98);
  border: 1px solid var(--line, rgba(247,203,93,.24));
  border-radius: 18px; overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,.6);
  display: flex; flex-direction: column;
}
.cad-pano-viewer { flex: 1; background: #000; }

/* ════════════════════════════════════════════════════════════
   FULL-PAGE — fixed z-index so panels float above
════════════════════════════════════════════════════════════ */
body.cad-fullscreen-active { overflow: hidden; }
.map-wrap.cad-fullscreen {
  position: fixed !important;
  inset: 0 !important;
  z-index: 9990 !important;
  margin: 0 !important;
  padding: 8px !important;
  border-radius: 0 !important;
  border: none !important;
}
.map-wrap.cad-fullscreen #map {
  height: calc(100vh - 120px) !important;
  border-radius: 8px !important;
}
.map-wrap.cad-fullscreen .map-resizer { display: none !important; }
.tool-btn.active {
  background: rgba(247,203,93,.22);
  border-color: rgba(247,203,93,.4);
  color: var(--gold-2, #f7cb5d);
}

/* ════════════════════════════════════════════════════════════
   v4.0 — Manage modal & Civil Tools active-button styling
════════════════════════════════════════════════════════════ */
.cad-manage-card {
  width: min(560px, 92vw);
  max-height: 85vh;
}
.cad-manage-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255,255,255,.07);
  gap: 10px;
}
.cad-manage-row:last-child { border-bottom: none; }
.cad-manage-label { flex: 1; font-size: 13px; }
.cad-manage-actions { display: inline-flex; gap: 6px; align-items: center; }
.cad-btn-tiny {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  color: var(--cream, #f6efe5);
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 11px;
  cursor: pointer;
}
.cad-btn-tiny:hover { background: rgba(247,203,93,.15); border-color: rgba(247,203,93,.35); }
.cad-btn-tiny.danger { color: #f88; }
.cad-btn-tiny.danger:hover { background: rgba(248,80,80,.15); border-color: rgba(248,80,80,.45); }
.cad-x-close {
  margin-left: auto;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.10);
  color: #fff;
  width: 26px; height: 26px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
}
.cad-x-close:hover { background: rgba(248,80,80,.18); border-color: rgba(248,80,80,.4); }

/* Civil Tools button active state — matches existing .tool-btn.active style */
#civilToolsBtn.active {
  background: rgba(247,203,93,.18);
  border-color: rgba(247,203,93,.30);
  color: var(--gold-2, #f7cb5d);
}

/* ════════════════════════════════════════════════════════════
   v5.1 — Fullscreen panels: BOTH hidden by default
   - LEFT (GIS Layers): shows only when 📋 Layers button toggled
   - RIGHT (Tools/Calculators popups): shows ONLY when body has .cad-has-tools-content
     (set by JS when #dynamicHost gains children)
═══════════════════════════════════════════════════════════ */
/* Hide both by default in fullscreen */
body.cad-fullscreen-active aside.panel {
  display: none !important;
}
/* RIGHT aside auto-shows only when JS marks body as having Tools/Calculators content */
body.cad-fullscreen-active.cad-has-tools-content section.layout > aside.panel:last-of-type {
  display: flex !important;
  position: fixed !important;
  top: 8px !important;
  right: 8px !important;
  bottom: 8px !important;
  width: 380px;
  max-width: 92vw;
  z-index: 9999 !important;
  overflow-y: auto;
  pointer-events: auto;
  flex-direction: column;
}
/* Show the LEFT aside (GIS Layers) ONLY when toggle is clicked */
body.cad-fullscreen-active.cad-show-gis-panel section.layout > aside.panel:first-of-type {
  display: flex !important;
  position: fixed !important;
  top: 8px !important;
  left: 8px !important;
  bottom: 8px !important;
  width: 320px;
  max-width: 92vw;
  z-index: 9999 !important;
  overflow-y: auto;
  pointer-events: auto;
  flex-direction: column;
}
body.cad-fullscreen-active .side-host,
body.cad-fullscreen-active #dynamicHost {
  z-index: 10001 !important;
}
/* GIS panel toggle button shown in fullscreen mode */
.cad-gis-toggle {
  position: fixed;
  top: 14px;
  left: 64px;  /* to the right of Leaflet zoom controls (which sit at left: 10px, ~44px wide) */
  z-index: 10005;
  background: rgba(18,34,52,.92);
  border: 1px solid rgba(247,203,93,.40);
  color: var(--gold-2, #f7cb5d);
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  display: none;  /* shown only in fullscreen */
  box-shadow: 0 4px 14px rgba(0,0,0,.5);
}
.cad-gis-toggle:hover {
  background: rgba(247,203,93,.18);
  border-color: rgba(247,203,93,.60);
}
body.cad-fullscreen-active .cad-gis-toggle { display: inline-block; }

/* Color legend in help popup */
.cad-legend { display: flex; flex-direction: column; gap: 6px; margin: 10px 0; }
.cad-legend-row {
  display: flex; align-items: center; gap: 10px;
  padding: 6px 8px;
  background: rgba(255,255,255,.04);
  border-radius: 6px;
  font-size: 13px;
}
.cad-legend-swatch {
  display: inline-block;
  width: 20px; height: 20px;
  border-radius: 4px;
  border: 1px solid rgba(255,255,255,.20);
  flex-shrink: 0;
}

/* Reshape handles — vertex (square) and midpoint (small circle) */
.cad-reshape-handle { background: transparent; border: none; }
.cad-handle-vertex {
  width: 14px; height: 14px;
  background: #f7cb5d;
  border: 2px solid #1a1020;
  border-radius: 3px;
  cursor: move;
  box-shadow: 0 0 6px rgba(247,203,93,.6);
}
.cad-handle-vertex:hover { background: #fff; transform: scale(1.2); }
.cad-handle-midpoint {
  width: 10px; height: 10px;
  background: rgba(247,203,93,0.6);
  border: 1.5px solid #1a1020;
  border-radius: 50%;
  cursor: copy;
}
.cad-handle-midpoint:hover { background: #fff; transform: scale(1.3); }

/* Back button in placement banner */
.cad-banner-back {
  margin: 0 10px;
  background: rgba(247,203,93,.15);
  border: 1px solid rgba(247,203,93,.40);
  color: #f7cb5d;
  padding: 4px 12px;
  border-radius: 6px;
  font-weight: 700;
  cursor: pointer;
  font-size: 12px;
}
.cad-banner-back:hover {
  background: rgba(247,203,93,.30);
}

/* ════════════════════════════════════════════════════════════
/* ════════════════════════════════════════════════════════════
   v5.2 — Civil Items list rendered INSIDE #dynamicHost
   (same place Tools/Calculators populate)
═══════════════════════════════════════════════════════════ */
.cad-items-host {
  font-family: 'Segoe UI', Arial, sans-serif;
  color: #f6efe5;
}
.cad-items-host-head {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 14px 10px;
  border-bottom: 1px solid rgba(247,203,93,.18);
}
.cad-items-host-title {
  flex: 1;
  font-weight: 800;
  font-size: 14px;
  color: #f7cb5d;
  letter-spacing: 0.3px;
}
.cad-items-host-actions {
  display: flex; gap: 6px;
}
.cad-items-host-actions button {
  background: rgba(247,203,93,.15);
  border: 1px solid rgba(247,203,93,.40);
  color: #f7cb5d;
  padding: 5px 10px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 11px;
  cursor: pointer;
  transition: background .12s;
}
.cad-items-host-actions button:hover:not(:disabled) {
  background: rgba(247,203,93,.30);
}
.cad-items-host-actions button:disabled {
  opacity: 0.40;
  cursor: not-allowed;
}
.cad-items-host-body {
  padding: 10px 12px 14px;
  max-height: 60vh;
  overflow-y: auto;
}
.cad-items-card {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 12px;
  margin: 6px 0;
  background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.02));
  border: 1px solid rgba(247,203,93,.18);
  border-radius: 10px;
  cursor: pointer;
  transition: background .12s, border-color .12s, transform .08s;
}
.cad-items-card:hover {
  background: linear-gradient(180deg, rgba(247,203,93,.08), rgba(247,203,93,.04));
  border-color: rgba(247,203,93,.45);
  transform: translateY(-1px);
}
.cad-items-card-icon {
  flex-shrink: 0;
  font-size: 20px;
  width: 28px;
  text-align: center;
}
.cad-items-card-text {
  flex: 1;
  min-width: 0;
}
.cad-items-card-label {
  font-weight: 700;
  font-size: 14px;
  color: #f7cb5d;
  letter-spacing: 0.2px;
  margin-bottom: 2px;
}
.cad-items-card-detail {
  font-size: 12px;
  color: rgba(255,255,255,.70);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cad-items-card-x {
  flex-shrink: 0;
  background: rgba(248,80,80,.12);
  border: 1px solid rgba(248,80,80,.30);
  color: #f87070;
  width: 28px; height: 28px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 800;
  line-height: 1;
  padding: 0;
  transition: background .12s;
}
.cad-items-card-x:hover {
  background: rgba(248,80,80,.30);
}
