/* ═══════════════════════════════════════════════════════════════════
   CyberGaze Unified Intelligence Report System — Premium Design Layer
   Version 1.0 — Cyberpunk SOC Dashboard Aesthetic
   ═══════════════════════════════════════════════════════════════════ */

/* ── Design tokens ──────────────────────────────────────────────────── */
:root {
  --cg-bg-hero:    rgba(4, 10, 22, 0.97);
  --cg-bg-card:    rgba(8, 14, 28, 0.90);
  --cg-border-dim: rgba(0,255,157,0.08);
  --cg-border-mid: rgba(0,255,157,0.16);
  --cg-neon-green: #00ff9d;
  --cg-neon-blue:  #00b4ff;
  --cg-neon-purple:#a855f7;
  --cg-critical:   #f87171;
  --cg-high:       #fb923c;
  --cg-medium:     #facc15;
  --cg-low:        #00ff9d;
  --cg-text-pri:   #e5e7eb;
  --cg-text-sec:   #9ca3af;
  --cg-text-muted: #6b7280;
  --cg-mono:       'JetBrains Mono','Fira Code',monospace;
  --cg-radius:     12px;
  --cg-radius-sm:  6px;
}

/* ── Keyframes ──────────────────────────────────────────────────────── */
@keyframes cgFadeUp {
  from { opacity:0; transform:translateY(18px); }
  to   { opacity:1; transform:translateY(0); }
}
@keyframes cgSlideIn {
  from { opacity:0; transform:translateX(-10px); }
  to   { opacity:1; transform:translateX(0); }
}
@keyframes cgPulseGlow {
  0%,100% { box-shadow:0 0 5px rgba(0,255,157,0.2); }
  50%     { box-shadow:0 0 18px rgba(0,255,157,0.55), 0 0 32px rgba(0,255,157,0.18); }
}
@keyframes cgRingDraw {
  from { stroke-dasharray: 0 239; }
  to   { stroke-dasharray: var(--cg-da, 0) 239; }
}
@keyframes cgScanLine {
  0%   { top:0%;   opacity:0; }
  10%  { opacity:0.55; }
  90%  { opacity:0.55; }
  100% { top:100%; opacity:0; }
}
@keyframes cgCountUp {
  from { opacity:0; transform:scale(0.75); }
  to   { opacity:1; transform:scale(1); }
}
@keyframes cgShimmer {
  0%,100% { opacity:0.6; }
  50%     { opacity:1; }
}
@keyframes cgBlink {
  0%,100% { opacity:1; }
  50%     { opacity:0; }
}

/* ── Hero card ──────────────────────────────────────────────────────── */
.cg-hero {
  background: var(--cg-bg-hero);
  border: 1px solid var(--cg-border-mid);
  border-radius: var(--cg-radius);
  padding: 18px 20px 16px;
  margin-bottom: 10px;
  position: relative;
  overflow: hidden;
  animation: cgFadeUp 0.32s ease-out both;
}
.cg-hero::before {
  content: '';
  position: absolute;
  left:0; right:0; top:0; height:2px;
  background: linear-gradient(90deg, transparent, var(--cg-neon-green) 50%, var(--cg-neon-blue));
  opacity: 0.65;
}
.cg-hero::after {
  content: '';
  position: absolute;
  left:0; right:0; top:0; height:55%;
  background: linear-gradient(180deg, rgba(0,255,157,0.022) 0%, transparent 100%);
  pointer-events: none;
}
.cg-scanline {
  position: absolute;
  left:0; right:0; height:1px;
  background: linear-gradient(90deg, transparent, rgba(0,255,157,0.38), transparent);
  animation: cgScanLine 4s linear infinite;
  pointer-events: none;
  z-index: 1;
}

/* ── Hero layout ────────────────────────────────────────────────────── */
.cg-hero-top {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  position: relative;
  z-index: 2;
}
.cg-hero-meta { flex:1; min-width:160px; }

.cg-hero-scan-type {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
  flex-wrap: wrap;
}
.cg-hero-scan-label {
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cg-text-muted);
}
.cg-hero-scan-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  border: 1px solid;
}
.cg-hero-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--cg-text-pri);
  line-height: 1.2;
  margin-bottom: 3px;
}
.cg-hero-target {
  font-family: var(--cg-mono);
  font-size: 12px;
  color: var(--cg-neon-blue);
  word-break: break-all;
  margin-bottom: 5px;
}
.cg-hero-ts {
  font-size: 9px;
  color: var(--cg-text-muted);
  font-family: var(--cg-mono);
}
.cg-verdict {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 5px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  border: 1px solid;
  margin-top: 5px;
}

/* ── Risk ring ──────────────────────────────────────────────────────── */
.cg-ring-wrap {
  position: relative;
  width: 86px;
  height: 86px;
  flex-shrink: 0;
}
.cg-ring-svg { width:100%; height:100%; }
.cg-ring-track {
  fill: none;
  stroke: rgba(255,255,255,0.04);
  stroke-width: 9;
}
.cg-ring-fill {
  fill: none;
  stroke-width: 9;
  stroke-linecap: round;
  transform-origin: 50% 50%;
  transform: rotate(-90deg);
  animation: cgRingDraw 1.1s cubic-bezier(.34,1.56,.64,1) both;
}
.cg-ring-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}
.cg-ring-score {
  font-family: var(--cg-mono);
  font-size: 20px;
  font-weight: 700;
  line-height: 1;
}
.cg-ring-unit {
  font-size: 8px;
  color: var(--cg-text-muted);
  letter-spacing: 0.07em;
  margin-top: 1px;
}

/* ── Metrics row ────────────────────────────────────────────────────── */
.cg-metrics-row {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,0.05);
  position: relative;
  z-index: 2;
}
.cg-metric-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: rgba(5,10,20,0.72);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 8px 12px;
  min-width: 64px;
  flex: 1;
  animation: cgCountUp 0.4s ease-out both;
  transition: border-color 0.2s;
}
.cg-metric-chip:hover { border-color: rgba(0,255,157,0.18); }
.cg-metric-val {
  font-family: var(--cg-mono);
  font-size: 17px;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 3px;
  white-space: nowrap;
}
.cg-metric-lbl {
  font-size: 8px;
  color: var(--cg-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-align: center;
  white-space: nowrap;
}

/* ── Platform cards (social intel) ─────────────────────────────────── */
.cg-platform-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px,1fr));
  gap: 7px;
}
.cg-platform-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 11px 8px;
  border-radius: 8px;
  border: 1px solid;
  text-align: center;
  transition: border-color 0.18s, background 0.18s;
}
.cg-platform-card--found {
  background: rgba(0,255,157,0.04);
  border-color: rgba(0,255,157,0.14);
}
.cg-platform-card--notfound {
  background: rgba(107,114,128,0.03);
  border-color: rgba(107,114,128,0.09);
  opacity: 0.45;
}
.cg-platform-card--found:hover {
  border-color: rgba(0,255,157,0.32);
  background: rgba(0,255,157,0.07);
}
.cg-platform-icon { font-size: 20px; line-height: 1; }
.cg-platform-name {
  font-size: 10px;
  font-weight: 600;
  color: var(--cg-text-sec);
  word-break: break-all;
}
.cg-platform-status {
  font-size: 8px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.cg-platform-status--found    { color: var(--cg-neon-green); }
.cg-platform-status--notfound { color: var(--cg-text-muted); }
.cg-platform-link {
  font-size: 8px;
  color: var(--cg-neon-blue);
  text-decoration: none;
}
.cg-platform-link:hover { text-decoration: underline; }

/* ── Telemetry bar ──────────────────────────────────────────────────── */
.cg-telem-bar-bg {
  background: rgba(255,255,255,0.04);
  border-radius: 3px;
  height: 5px;
  overflow: hidden;
}
.cg-telem-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.85s cubic-bezier(.25,.46,.45,.94);
}

/* ── Live dot ────────────────────────────────────────────────────────── */
.cg-live-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--cg-neon-green);
  animation: cgPulseGlow 2s ease-in-out infinite;
  flex-shrink: 0;
  display: inline-block;
}

/* ── Kali hero (inside result modal) ────────────────────────────────── */
.cg-kali-hero {
  border-radius: var(--cg-radius);
  margin-bottom: 12px;
}

/* ── Staggered metric animation delays ──────────────────────────────── */
.cg-metric-chip:nth-child(1) { animation-delay:0.08s; }
.cg-metric-chip:nth-child(2) { animation-delay:0.14s; }
.cg-metric-chip:nth-child(3) { animation-delay:0.20s; }
.cg-metric-chip:nth-child(4) { animation-delay:0.26s; }

/* ── Report panel fade ───────────────────────────────────────────────── */
#osint-extra-sections { animation: cgFadeUp 0.38s ease-out both; }
#result-modal-body    { animation: cgFadeUp 0.28s ease-out both; }

/* ── Mobile ──────────────────────────────────────────────────────────── */
@media (max-width: 480px) {
  .cg-hero-top     { flex-direction: column; }
  .cg-ring-wrap    { width:70px; height:70px; }
  .cg-ring-score   { font-size:16px; }
  .cg-hero-title   { font-size:13px; }
  .cg-metric-val   { font-size:14px; }
  .cg-metrics-row  { gap:5px; }
  .cg-metric-chip  { min-width:52px; padding:7px 8px; }
  .cg-platform-grid{ grid-template-columns: repeat(auto-fill, minmax(105px,1fr)); }
}

/* ═══════════════════════════════════════════════════════════════════
   Phase 2 — Shared System Styles (unified-report.js CSS classes)
   ═══════════════════════════════════════════════════════════════════ */

/* ── SharedCardSystem ────────────────────────────────────────────────── */
.cgr-section {
  animation: cgFadeUp 0.32s ease-out both;
}
.cgr-section:not(.cgr-accordion):hover > div {
  border-color: rgba(0,255,157,0.2) !important;
  box-shadow: 0 2px 18px rgba(0,255,157,0.07);
  transition: border-color 0.22s ease, box-shadow 0.22s ease;
}

/* ── SharedAccordionEngine ───────────────────────────────────────────── */
.cgr-accordion > div {
  transition: padding 0.22s ease;
}
.cgr-accordion summary {
  user-select: none;
  outline: none;
  transition: border-color 0.18s ease;
}
.cgr-accordion summary:hover {
  border-color: rgba(0,255,157,0.24) !important;
}

/* ── SharedMetricsRenderer ───────────────────────────────────────────── */
.cgr-metric-cell {
  animation: cgCountUp 0.35s ease-out both;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  cursor: default;
}
.cgr-metric-cell:hover {
  transform: translateY(-2px);
  border-color: rgba(0,255,157,0.22) !important;
  box-shadow: 0 4px 22px rgba(0,255,157,0.09);
}

/* ── SharedFindingsRenderer ──────────────────────────────────────────── */
.cgr-finding-row {
  animation: cgSlideIn 0.28s ease-out both;
  transition: border-color 0.16s ease, transform 0.16s ease;
  cursor: default;
}
.cgr-finding-row:hover {
  transform: translateX(2px);
  border-color: rgba(255,255,255,0.13) !important;
}

/* ── SharedKeyValSystem ──────────────────────────────────────────────── */
.cgr-kv-table tr {
  transition: background 0.14s ease;
}
.cgr-kv-table tr:hover {
  background: rgba(0,255,157,0.025);
}

/* ── SharedSeveritySystem ────────────────────────────────────────────── */
.cgr-sev-dot[style*="#f87171"],
.cgr-sev-dot[style*="#fb923c"] {
  animation: cgPulseGlow 2.4s ease-in-out infinite;
}

/* ── SharedIntelGrid ─────────────────────────────────────────────────── */
.cgr-intel-grid { animation: cgFadeUp 0.3s ease-out both; }
.cgr-intel-cell {
  transition: border-color 0.16s ease, background 0.16s ease;
  cursor: default;
}
.cgr-intel-cell:hover {
  border-color: rgba(0,255,157,0.16) !important;
  background: rgba(0,255,157,0.04) !important;
}

/* ── SharedRecommendationRenderer ────────────────────────────────────── */
.cgr-rec-item {
  transition: border-color 0.16s ease, transform 0.16s ease;
  cursor: default;
}
.cgr-rec-item:hover {
  border-color: rgba(0,255,157,0.13) !important;
  transform: translateX(2px);
}

/* ── Mobile overrides for Phase 2 ────────────────────────────────────── */
@media (max-width: 480px) {
  .cgr-metric-cell:hover { transform: none; }
  .cgr-finding-row:hover { transform: none; }
  .cgr-rec-item:hover    { transform: none; }
  .cgr-intel-grid        { grid-template-columns: 1fr !important; }
}

/* ═══════════════════════════════════════════════════════════════════
   Premium Intelligence Report — Unified Window System (cgp-*)
   One cinematic container per scan. Replaces stacked debug panels.
   ═══════════════════════════════════════════════════════════════════ */

/* ── Window shell ────────────────────────────────────────────────── */
.cgp-window {
  background: linear-gradient(160deg, rgba(4,10,22,0.98) 0%, rgba(6,12,26,0.96) 100%);
  border: 1px solid rgba(0,255,157,0.14);
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  animation: cgFadeUp 0.35s ease-out both;
  box-shadow: 0 4px 40px rgba(0,0,0,0.55), 0 0 0 1px rgba(0,255,157,0.04) inset;
}
.cgp-window::before {
  content: '';
  position: absolute;
  left: 0; right: 0; top: 0; height: 2px;
  background: linear-gradient(90deg, transparent 0%, var(--cg-neon-green) 40%, var(--cg-neon-blue) 100%);
  opacity: 0.7;
}

/* ── Top bar ─────────────────────────────────────────────────────── */
.cgp-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  background: rgba(0,0,0,0.22);
}
.cgp-scan-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 20px;
  border: 1px solid;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.cgp-ts {
  font-size: 9px;
  color: var(--cg-text-muted);
  font-family: var(--cg-mono);
}

/* ── Hero row ────────────────────────────────────────────────────── */
.cgp-hero-row {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 18px 20px 14px;
  flex-wrap: wrap;
  position: relative;
  z-index: 2;
}

/* ── Ring gauge ──────────────────────────────────────────────────── */
.cgp-ring-wrap {
  position: relative;
  width: 88px;
  height: 88px;
  flex-shrink: 0;
}
.cgp-ring-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.cgp-ring-inner {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* ── Verdict panel ───────────────────────────────────────────────── */
.cgp-verdict-panel {
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
  min-width: 120px;
}
.cgp-target-txt {
  font-family: var(--cg-mono);
  font-size: 13px;
  color: var(--cg-neon-blue);
  word-break: break-all;
  font-weight: 600;
}
.cgp-verdict-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 5px;
  border: 1px solid;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  align-self: flex-start;
  font-family: var(--cg-mono);
}

/* ── Metrics cluster ─────────────────────────────────────────────── */
.cgp-metrics-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  flex: 2;
  min-width: 200px;
}
.cgp-metric {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: rgba(5,10,20,0.75);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 9px;
  padding: 9px 13px;
  min-width: 62px;
  flex: 1;
  animation: cgCountUp 0.4s ease-out both;
  transition: border-color 0.18s, transform 0.18s;
}
.cgp-metric:hover {
  border-color: rgba(0,255,157,0.2);
  transform: translateY(-1px);
}
.cgp-metric-val {
  font-family: var(--cg-mono);
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 4px;
  white-space: nowrap;
}
.cgp-metric-lbl {
  font-size: 8px;
  color: var(--cg-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-align: center;
}

/* ── Body ────────────────────────────────────────────────────────── */
.cgp-body {
  padding: 0 0 16px;
}

/* ── Sections ────────────────────────────────────────────────────── */
.cgp-section {
  padding: 14px 20px;
  border-top: 1px solid rgba(255,255,255,0.04);
  animation: cgFadeUp 0.3s ease-out both;
}
.cgp-section-body {
  overflow-wrap: break-word;
  word-break: break-word;
  min-width: 0;
}
.cgp-section-hdr {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 10px;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.cgp-section-icon { font-size: 13px; flex-shrink: 0; }
.cgp-section-line {
  flex: 1;
  height: 1px;
  opacity: 0.5;
}

/* ── Info grid ───────────────────────────────────────────────────── */
.cgp-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 6px;
}
.cgp-info-cell {
  background: rgba(5,10,20,0.6);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 7px;
  padding: 8px 11px;
  transition: border-color 0.15s;
}
.cgp-info-cell:hover { border-color: rgba(0,255,157,0.15); }
.cgp-info-label {
  font-size: 9px;
  color: var(--cg-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 3px;
}
.cgp-info-value {
  font-size: 11px;
  color: var(--cg-text-pri);
  font-family: var(--cg-mono);
  word-break: break-all;
  line-height: 1.4;
}

/* ── Pills ───────────────────────────────────────────────────────── */
.cgp-pill {
  display: inline-flex;
  align-items: center;
  background: rgba(0,180,255,0.06);
  border: 1px solid;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-family: var(--cg-mono);
  white-space: nowrap;
}

/* ── Finding rows ────────────────────────────────────────────────── */
.cgp-finding {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 8px 10px;
  border: 1px solid;
  border-radius: 7px;
  margin-bottom: 5px;
  animation: cgSlideIn 0.25s ease-out both;
  transition: border-color 0.14s, transform 0.14s;
}
.cgp-finding:hover { transform: translateX(2px); }
.cgp-finding-title {
  font-size: 11.5px;
  color: var(--cg-text-pri);
  font-weight: 600;
  word-break: break-word;
}
.cgp-finding-desc {
  font-size: 11px;
  color: var(--cg-text-sec);
  margin-top: 2px;
  line-height: 1.5;
}
.cgp-finding-ev {
  font-size: 10px;
  color: var(--cg-text-muted);
  font-family: var(--cg-mono);
  margin-top: 3px;
}

/* ── Platform cards ──────────────────────────────────────────────── */
.cgp-platform-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  justify-content: flex-start;
}
.cgp-platform-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 12px 8px;
  border-radius: 10px;
  border: 1px solid;
  text-align: center;
  transition: all 0.18s ease;
  position: relative;
  flex: 0 0 130px;
  max-width: 160px;
}
.cgp-platform-found {
  background: rgba(0,180,255,0.05);
  border-color: rgba(0,180,255,0.22);
}
.cgp-platform-found:hover {
  background: rgba(0,180,255,0.1);
  border-color: rgba(0,180,255,0.4);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,180,255,0.12);
}
.cgp-platform-missing {
  background: rgba(107,114,128,0.03);
  border-color: rgba(107,114,128,0.08);
  opacity: 0.38;
}
.cgp-plat-icon { font-size: 22px; line-height: 1; }
.cgp-plat-name {
  font-size: 9px;
  font-weight: 600;
  color: var(--cg-text-sec);
  word-break: break-all;
}
.cgp-plat-status {
  font-size: 8px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}
.cgp-plat-found    { color: var(--cg-neon-green); }
.cgp-plat-notfound { color: var(--cg-text-muted); }
.cgp-plat-followers {
  font-size: 8px;
  color: var(--cg-text-muted);
  font-family: var(--cg-mono);
}
.cgp-plat-verified {
  font-size: 7px;
  color: var(--cg-neon-blue);
  font-weight: 700;
}
.cgp-plat-link {
  font-size: 8px;
  color: var(--cg-neon-blue);
  text-decoration: none;
}
.cgp-plat-link:hover { text-decoration: underline; }

/* ── Breach cards ────────────────────────────────────────────────── */
.cgp-breach-card {
  background: rgba(239,68,68,0.05);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: 9px;
  padding: 12px 14px;
  margin-bottom: 8px;
  animation: cgFadeUp 0.28s ease-out both;
  transition: border-color 0.16s;
}
.cgp-breach-card:hover { border-color: rgba(239,68,68,0.35); }
.cgp-breach-hdr {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.cgp-breach-name {
  font-weight: 700;
  font-size: 13px;
  color: #f87171;
  flex: 1;
}
.cgp-breach-date {
  font-size: 10px;
  color: var(--cg-text-muted);
  font-family: var(--cg-mono);
}
.cgp-breach-verified {
  font-size: 8px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 3px;
  background: rgba(239,68,68,0.12);
  color: #f87171;
  letter-spacing: 0.06em;
}
.cgp-breach-count {
  font-size: 10px;
  color: var(--cg-text-muted);
  font-family: var(--cg-mono);
}
.cgp-breach-classes {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 6px;
}
.cgp-breach-class {
  background: rgba(249,115,22,0.08);
  border: 1px solid rgba(249,115,22,0.22);
  color: #fb923c;
  font-size: 9px;
  padding: 2px 6px;
  border-radius: 3px;
}
.cgp-breach-desc {
  font-size: 11px;
  color: var(--cg-text-muted);
  line-height: 1.5;
}

/* ── Redirect chain ──────────────────────────────────────────────── */
.cgp-redirect-chain { display: flex; flex-direction: column; gap: 3px; }
.cgp-redirect-step  { display: flex; align-items: flex-start; gap: 8px; }
.cgp-redirect-arrow {
  width: 20px;
  text-align: center;
  color: rgba(0,180,255,0.35);
  font-size: 14px;
  padding-top: 3px;
  flex-shrink: 0;
}
.cgp-redirect-url {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(5,5,10,0.7);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 6px;
  padding: 6px 10px;
  flex-wrap: wrap;
}
.cgp-redirect-code {
  font-size: 10px;
  font-weight: 700;
  font-family: var(--cg-mono);
  flex-shrink: 0;
}
.cgp-redirect-href {
  font-size: 10px;
  color: var(--cg-text-sec);
  font-family: var(--cg-mono);
  word-break: break-all;
}

/* ── Port grid ───────────────────────────────────────────────────── */
.cgp-port-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.cgp-port-chip {
  background: rgba(5,10,20,0.7);
  border: 1px solid;
  border-radius: 5px;
  padding: 4px 10px;
  font-size: 11px;
  font-family: var(--cg-mono);
  font-weight: 600;
  transition: border-color 0.14s, transform 0.14s;
}
.cgp-port-chip:hover {
  transform: translateY(-1px);
}

/* ── Map embed ───────────────────────────────────────────────────── */
.cgp-map-embed {
  width: 100%;
  height: 200px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(0,255,157,0.1);
  margin-top: 10px;
}

/* ── Flags / warnings ────────────────────────────────────────────── */
.cgp-flags { display: flex; flex-direction: column; gap: 5px; }
.cgp-flag-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 6px 10px;
  background: rgba(249,115,22,0.06);
  border-left: 2px solid rgba(249,115,22,0.5);
  border-radius: 0 5px 5px 0;
  font-size: 11px;
  color: #fb923c;
  line-height: 1.4;
}

/* ── Paste rows ──────────────────────────────────────────────────── */
.cgp-paste-row {
  padding: 5px 8px;
  font-size: 10px;
  color: #facc15;
  font-family: var(--cg-mono);
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

/* ── Clean state (no breach found) ──────────────────────────────── */
.cgp-clean-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
  font-size: 14px;
  color: var(--cg-neon-green);
  font-weight: 700;
  text-align: center;
  gap: 6px;
}

/* ── Recommendations ─────────────────────────────────────────────── */
.cgp-recs {
  padding: 14px 20px 16px;
  border-top: 1px solid rgba(255,255,255,0.06);
  background: rgba(0,0,0,0.18);
}
.cgp-recs-title {
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cg-neon-green);
  margin-bottom: 9px;
}
.cgp-rec-item {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 7px 10px;
  margin-bottom: 5px;
  background: rgba(5,10,20,0.55);
  border: 1px solid rgba(255,255,255,0.04);
  border-radius: 6px;
  transition: border-color 0.15s, transform 0.15s;
}
.cgp-rec-item:hover {
  border-color: rgba(0,255,157,0.12);
  transform: translateX(2px);
}
.cgp-rec-num { font-size: 12px; flex-shrink: 0; margin-top: 1px; }
.cgp-rec-text {
  font-size: 11px;
  color: var(--cg-text-sec);
  line-height: 1.5;
}

/* ── Stagger animations ──────────────────────────────────────────── */
.cgp-section:nth-child(1)   { animation-delay: 0.04s; }
.cgp-section:nth-child(2)   { animation-delay: 0.08s; }
.cgp-section:nth-child(3)   { animation-delay: 0.12s; }
.cgp-section:nth-child(4)   { animation-delay: 0.16s; }
.cgp-section:nth-child(5)   { animation-delay: 0.20s; }
.cgp-section:nth-child(6)   { animation-delay: 0.24s; }
.cgp-section:nth-child(7)   { animation-delay: 0.27s; }
.cgp-section:nth-child(8)   { animation-delay: 0.30s; }
.cgp-section:nth-child(9)   { animation-delay: 0.33s; }
.cgp-section:nth-child(10)  { animation-delay: 0.36s; }
.cgp-section:nth-child(11)  { animation-delay: 0.39s; }
.cgp-section:nth-child(12)  { animation-delay: 0.42s; }
.cgp-section:nth-child(n+13){ animation-delay: 0.45s; }
.cgp-metric:nth-child(1)    { animation-delay: 0.06s; }
.cgp-metric:nth-child(2)    { animation-delay: 0.10s; }
.cgp-metric:nth-child(3)    { animation-delay: 0.14s; }
.cgp-metric:nth-child(4)    { animation-delay: 0.18s; }

/* ── Kali modal variant ──────────────────────────────────────────── */
.cgp-kali-hdr {
  border-radius: var(--cg-radius);
  margin-bottom: 12px;
}
.cgp-kali-hdr .cgp-hero-row { padding-bottom: 16px; }

/* ── Mobile ──────────────────────────────────────────────────────── */
@media (max-width: 600px) {
  .cgp-hero-row     { flex-direction: column; gap: 12px; }
  .cgp-ring-wrap    { width: 72px; height: 72px; }
  .cgp-metrics-row  { min-width: unset; gap: 5px; }
  .cgp-metric       { min-width: 52px; padding: 8px 10px; }
  .cgp-metric-val   { font-size: 14px; }
  .cgp-info-grid    { grid-template-columns: 1fr 1fr; }
  .cgp-platform-grid{ grid-template-columns: repeat(auto-fill, minmax(96px,1fr)); }
  .cgp-metric:hover { transform: none; }
  .cgp-finding:hover{ transform: none; }
  .cgp-rec-item:hover { transform: none; }
}

/* ═══════════════════════════════════════════════════════════════════
   Phase 3 — Premium Platform Cards, Confidence, IOC, Malware Hero
   ═══════════════════════════════════════════════════════════════════ */

/* Platform card v3 — glassmorphism + neon glow */
.cgp-platform-found {
  background: rgba(0,180,255,0.04) !important;
  border-color: rgba(0,180,255,0.18) !important;
}
.cgp-platform-found:hover {
  background: rgba(0,180,255,0.09) !important;
  border-color: rgba(0,180,255,0.45) !important;
  transform: translateY(-3px) !important;
  box-shadow: 0 6px 24px rgba(0,180,255,0.14), 0 0 0 1px rgba(0,180,255,0.1) !important;
}
.cgp-platform-card .cgp-match-badge {
  position: absolute;
  top: 5px; right: 5px;
  font-size: 6.5px;
  font-weight: 800;
  letter-spacing: .07em;
  padding: 1px 5px;
  border-radius: 3px;
  text-transform: uppercase;
  opacity: .85;
  white-space: nowrap;
}
.cgp-conf-bar-wrap {
  width: 100%;
  height: 2px;
  background: rgba(255,255,255,0.05);
  border-radius: 1px;
  margin: 2px 0 3px;
  overflow: hidden;
}
.cgp-conf-bar-fill {
  height: 100%;
  border-radius: 1px;
  transition: width 0.95s cubic-bezier(.25,.46,.45,.94);
}
.cgp-plat-name-v2 {
  font-size: 10px;
  font-weight: 700;
  color: #e5e7eb;
  letter-spacing: 0.01em;
  word-break: break-all;
}
.cgp-cat-pill {
  font-size: 7.5px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  padding: 1px 6px;
  border-radius: 10px;
  border: 1px solid;
  white-space: nowrap;
}

/* Staggered platform card entry */
.cgp-platform-grid > *:nth-child(1)  { animation: cgFadeUp .24s .03s ease-out both; }
.cgp-platform-grid > *:nth-child(2)  { animation: cgFadeUp .24s .06s ease-out both; }
.cgp-platform-grid > *:nth-child(3)  { animation: cgFadeUp .24s .09s ease-out both; }
.cgp-platform-grid > *:nth-child(4)  { animation: cgFadeUp .24s .12s ease-out both; }
.cgp-platform-grid > *:nth-child(5)  { animation: cgFadeUp .24s .15s ease-out both; }
.cgp-platform-grid > *:nth-child(6)  { animation: cgFadeUp .24s .18s ease-out both; }
.cgp-platform-grid > *:nth-child(n+7){ animation: cgFadeUp .24s .21s ease-out both; }

/* IOC chips — clickable intelligence indicators */
.cgp-ioc-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: rgba(248,113,113,0.06);
  border: 1px solid rgba(248,113,113,0.22);
  color: #f87171;
  font-size: 10px;
  font-family: 'JetBrains Mono', monospace;
  padding: 3px 8px;
  border-radius: 5px;
  cursor: default;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
a.cgp-ioc-chip { cursor: pointer; }
.cgp-ioc-chip:hover {
  background: rgba(248,113,113,0.12);
  border-color: rgba(248,113,113,0.45);
  transform: translateY(-1px);
}
.cgp-ioc-chip--ip  {
  color: #fb923c;
  border-color: rgba(249,115,22,0.28);
  background: rgba(249,115,22,0.06);
}
.cgp-ioc-chip--ip:hover { background: rgba(249,115,22,0.12); border-color: rgba(249,115,22,0.5); }
.cgp-ioc-chip--url {
  color: #facc15;
  border-color: rgba(250,204,21,0.28);
  background: rgba(250,204,21,0.05);
}
.cgp-ioc-chip--url:hover { background: rgba(250,204,21,0.1); border-color: rgba(250,204,21,0.5); }
.cgp-ioc-chip--c2 {
  color: #f87171;
  border-color: rgba(239,68,68,0.38);
  background: rgba(239,68,68,0.08);
  font-weight: 700;
}
.cgp-ioc-label {
  font-size: 8.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  margin-bottom: 5px;
}

/* Malware threat overview hero */
.cgp-threat-overview {
  background: rgba(239,68,68,0.06);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 2px;
  position: relative;
  overflow: hidden;
}
.cgp-threat-overview::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0; width: 3px;
  background: linear-gradient(180deg, #f87171, #fb923c);
}
.cgp-malware-icon { font-size: 28px; line-height: 1; }
.cgp-threat-family {
  font-size: 14px;
  font-weight: 700;
  color: #f87171;
  margin-bottom: 5px;
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: .02em;
}
.cgp-attack-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 7px; }
.cgp-attack-chip {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 4px;
  border: 1px solid;
  animation: cgCountUp 0.35s ease-out both;
}
.cgp-threat-stats { display: flex; gap: 14px; flex-wrap: wrap; }
.cgp-threat-stat { font-size: 10px; }
.cgp-threat-stat > span:first-child { color: #6b7280; }
.cgp-threat-stat > span:last-child  { font-weight: 700; font-family: 'JetBrains Mono', monospace; }

/* ASN / Cloud Provider badge */
.cgp-cloud-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 8px;
  margin-bottom: 10px;
  border: 1px solid;
}
.cgp-cloud-name  { font-size: 13px; font-weight: 700; }
.cgp-cloud-label {
  font-size: 8px;
  color: var(--cg-text-muted);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 1px;
}

/* Reputation / blacklist list */
.cgp-rep-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 5px 10px;
  border-radius: 5px;
  margin-bottom: 4px;
  font-size: 10px;
  border: 1px solid rgba(255,255,255,0.04);
  background: rgba(5,10,20,0.5);
  transition: border-color 0.14s;
}
.cgp-rep-item:hover { border-color: rgba(255,255,255,0.1); }
.cgp-rep-clean { border-color: rgba(0,255,157,0.1); }
.cgp-rep-bad   { border-color: rgba(239,68,68,0.18); background: rgba(239,68,68,0.04); }

/* AI Executive Brief — CrowdStrike / SentinelOne style */
.cgp-ai-brief {
  background: rgba(168, 85, 247, 0.04);
  border: 1px solid rgba(168, 85, 247, 0.12);
  border-radius: 8px;
  padding: 14px 16px;
  overflow-wrap: break-word;
  word-break: break-word;
  min-width: 0;
}
.cgp-ai-brief p {
  color: #9ca3af;
  font-size: 11.5px;
  line-height: 1.7;
  margin: 0 0 8px;
}
.cgp-ai-brief ul, .cgp-ai-brief ol {
  padding-left: 18px;
  margin: 4px 0 8px;
}
.cgp-ai-brief li {
  color: #9ca3af;
  font-size: 11px;
  line-height: 1.6;
  margin-bottom: 3px;
}
.cgp-ai-brief code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  background: rgba(255,255,255,0.05);
  padding: 1px 5px;
  border-radius: 3px;
  color: #00b4ff;
}

/* Mobile adjustments */
@media (max-width: 600px) {
  .cgp-threat-overview { padding: 11px 12px; }
  .cgp-ioc-chip { max-width: 160px; font-size: 9px; }
  .cgp-attack-chip { font-size: 8px; padding: 1px 6px; }
  .cgp-cloud-badge { padding: 8px 10px; }
}
