/**
 * AI Detective Products - Styles
 * Shared styles for Chrome Extension, Web App, and Website
 * Version: 2.0.0 - Full-screen product panels
 * Created: January 4, 2026
 */

/* ============================================
   PRODUCTS SECTION IN SETTINGS
   ============================================ */

/* Product Cards */
.product-card {
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 14px;
  transition: all 0.3s ease;
}

/* Subscribed Product (Active) */
.product-subscribed {
  background: linear-gradient(135deg, #6b7280, #4b5563);
  box-shadow: 0 2px 8px rgba(107, 114, 128, 0.3);
}

/* Not Subscribed Products - SAME GRAY AS SUBSCRIBED */
.product-not-subscribed {
  background: linear-gradient(135deg, #6b7280, #4b5563);
  box-shadow: 0 2px 8px rgba(107, 114, 128, 0.3);
  border: none;
}

body.dark-mode .product-not-subscribed {
  background: linear-gradient(135deg, #6b7280, #4b5563);
  box-shadow: 0 2px 8px rgba(107, 114, 128, 0.3);
  border: none;
}

body.pitch-black-mode .product-not-subscribed {
  background: linear-gradient(135deg, #6b7280, #4b5563);
  box-shadow: 0 2px 8px rgba(107, 114, 128, 0.3);
  border: none;
}

/* Product Header (Icon + Name + Toggle) */
.product-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.product-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.product-icon {
  font-size: 28px;
}

.product-name {
  font-weight: 600;
  font-size: 15px;
  color: white;
}

.product-not-subscribed .product-name {
  color: white;
}

body.dark-mode .product-not-subscribed .product-name {
  color: white;
}

.product-status {
  font-size: 12px;
  font-weight: 500;
  margin-top: 2px;
}

.product-status-active {
  color: rgba(255, 255, 255, 0.9);
}

.product-description {
  font-size: 12px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.95);
}

.product-not-subscribed .product-description {
  color: rgba(255, 255, 255, 0.9);
}

body.dark-mode .product-not-subscribed .product-description {
  color: rgba(255, 255, 255, 0.9);
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 54px;
  height: 28px;
  cursor: pointer;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #d1d5db;
  transition: 0.4s;
  border-radius: 28px;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 22px;
  width: 22px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Checked state */
.toggle-switch input:checked + .toggle-slider {
  background-color: #10b981;
}

.toggle-switch input:checked + .toggle-slider:before {
  transform: translateX(26px);
}

/* Disabled toggle - MUST override checked state */
.toggle-disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.toggle-disabled .toggle-slider {
  cursor: not-allowed;
  background-color: #e5e7eb !important;
}

/* Force disabled toggles to stay OFF position even if checked in DOM */
.toggle-disabled input:checked + .toggle-slider {
  background-color: #e5e7eb !important;
}

.toggle-disabled input:checked + .toggle-slider:before {
  transform: translateX(0) !important;
}

body.dark-mode .toggle-disabled .toggle-slider,
body.dark-mode .toggle-disabled input:checked + .toggle-slider {
  background-color: #4b5563 !important;
}

body.dark-mode .toggle-disabled input:checked + .toggle-slider:before {
  transform: translateX(0) !important;
}

body.pitch-black-mode .toggle-disabled .toggle-slider,
body.pitch-black-mode .toggle-disabled input:checked + .toggle-slider {
  background-color: #374151 !important;
}

body.pitch-black-mode .toggle-disabled input:checked + .toggle-slider:before {
  transform: translateX(0) !important;
}

/* Subscribe Button */
.product-subscribe-btn {
  background: #8b5cf6;
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  margin-top: 10px;
  width: 100%;
  transition: all 0.3s ease;
}

.product-subscribe-btn:hover {
  background: #7c3aed;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

/* ============================================
   TOOLS BUTTON IN HEADER
   ============================================ */

#toolsToggle {
  background: linear-gradient(135deg, #8b5cf6, #7c3aed);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(139, 92, 246, 0.3);
}

#toolsToggle:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

#toolsToggle:active {
  transform: translateY(0);
}

/* ============================================
   FULL-SCREEN TOOLS PANEL
   For Chrome Extension: Takes full popup
   For Web App: Matches 390px centered card-deck
   ============================================ */

.tools-fullscreen-panel {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #f0f2f5;
  z-index: 10000;
  display: none;
  flex-direction: column;
  animation: fadeIn 0.3s ease;
}

body.dark-mode .tools-fullscreen-panel {
  background: #1f2937;
}

body.pitch-black-mode .tools-fullscreen-panel {
  background: #000000;
}

/* ============================================
   WEB APP SPECIFIC: Match card-deck dimensions
   When body has data-platform="webapp", constrain to 390px
   ============================================ */
body[data-platform="webapp"] .tools-fullscreen-panel {
  /* Match the web app's centered card layout */
  width: 100%;
  max-width: 390px;
  left: 50%;
  transform: translateX(-50%);
  /* Match web app body padding */
  padding: 16px;
  box-sizing: border-box;
  /* Add subtle border for definition */
  border-left: 1px solid var(--border-color, #e5e7eb);
  border-right: 1px solid var(--border-color, #e5e7eb);
}

body[data-platform="webapp"].dark-mode .tools-fullscreen-panel {
  background: var(--bg-color, #1c1c1c);
  border-color: #333;
}

body[data-platform="webapp"].pitch-black-mode .tools-fullscreen-panel {
  background: #000000;
  border-color: #333;
}

/* Panel Header */
.tools-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 32px;
  background: #2c2c2c;
  color: white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Web App: Compact header for 390px width */
body[data-platform="webapp"] .tools-panel-header {
  padding: 12px 16px;
}

body[data-platform="webapp"] .tools-panel-header.wc-header {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  gap: 10px;
  padding: 12px 0;
  background: transparent;
  border-bottom: 1px solid var(--border-color, #e5e7eb);
}

body[data-platform="webapp"].dark-mode .tools-panel-header.wc-header,
body[data-platform="webapp"].pitch-black-mode .tools-panel-header.wc-header {
  border-color: #333;
}

.tools-panel-branding {
  display: flex;
  align-items: center;
  gap: 16px;
}

.tools-close-btn {
  background: none;
  border: 2px solid white;
  color: white;
  padding: 8px 16px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 22px;
  font-weight: bold;
  transition: all 0.2s ease;
}

.tools-close-btn:hover {
  background: white;
  color: #2c2c2c;
}

/* Panel Body */
.tools-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 32px;
}

/* Web App: Compact body padding */
body[data-platform="webapp"] .tools-panel-body {
  padding: 0;
}

/* Panel Grid Layout */
.tools-panel-grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 24px;
  max-width: 1400px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .tools-panel-grid {
    grid-template-columns: 1fr;
  }
}

.tools-panel-main {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.tools-panel-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Product Section Cards */
.product-section-card {
  background: white;
  padding: 24px;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

body.dark-mode .product-section-card {
  background: #374151;
  color: #d1d5db;
}

.product-section-title {
  margin: 0 0 20px 0;
  color: #1f2937;
  font-size: 20px;
  font-weight: 600;
}

body.dark-mode .product-section-title {
  color: #f3f4f6;
}

.product-sidebar-title {
  margin: 0 0 20px 0;
  color: #1f2937;
  font-size: 18px;
  font-weight: 600;
}

body.dark-mode .product-sidebar-title {
  color: #f3f4f6;
}

/* Input Fields */
.product-input-label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 8px;
  color: #1f2937;
}

body.dark-mode .product-input-label {
  color: #f3f4f6;
}

.product-input {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 15px;
  font-family: monospace;
  background: #f9fafb;
  transition: all 0.2s ease;
}

body.dark-mode .product-input {
  background: #1f2937;
  border-color: #4b5563;
  color: #f3f4f6;
}

.product-input:focus {
  outline: none;
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

/* Buttons */
.product-primary-btn {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, #8b5cf6, #7c3aed);
  color: white;
  border: none;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
  transition: all 0.3s ease;
}

.product-primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(139, 92, 246, 0.4);
}

.product-primary-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* Detection Layers */
.detection-layers {
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 13px;
}

.detection-layer {
  padding: 12px;
  border-radius: 6px;
  border-left: 4px solid;
}

.detection-layer.active {
  background: #f0fdf4;
  border-color: #10b981;
}

body.dark-mode .detection-layer.active {
  background: rgba(16, 185, 129, 0.1);
}

.detection-layer.pending {
  background: #fef3c7;
  border-color: #f59e0b;
}

body.dark-mode .detection-layer.pending {
  background: rgba(245, 158, 11, 0.1);
}

.layer-name {
  font-weight: 600;
  margin-bottom: 4px;
}

.detection-layer.active .layer-name {
  color: #10b981;
}

.detection-layer.pending .layer-name {
  color: #f59e0b;
}

.layer-desc {
  color: #6b7280;
}

body.dark-mode .layer-desc {
  color: #9ca3af;
}

/* Upsell Card */
.product-upsell-card {
  background: linear-gradient(135deg, #8b5cf6, #7c3aed);
  padding: 24px;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(139, 92, 246, 0.4);
  text-align: center;
}

.product-upsell-btn {
  width: 100%;
  padding: 14px;
  background: white;
  color: #8b5cf6;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.product-upsell-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.3);
}

/* Scan Results */
.product-results-container {
  margin-top: 24px;
}

.scan-result-card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  border: 3px solid;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  animation: slideIn 0.4s ease;
}

body.dark-mode .scan-result-card {
  background: #374151;
}

.result-safe {
  border-color: #10b981;
  background: rgba(16, 185, 129, 0.05);
}

body.dark-mode .result-safe {
  background: rgba(16, 185, 129, 0.1);
}

.result-suspicious {
  border-color: #f59e0b;
  background: rgba(245, 158, 11, 0.05);
}

body.dark-mode .result-suspicious {
  background: rgba(245, 158, 11, 0.1);
}

.result-dangerous {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.05);
}

body.dark-mode .result-dangerous {
  background: rgba(239, 68, 68, 0.1);
}

.trust-score-display {
  text-align: center;
  margin-bottom: 24px;
}

.score-circle {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 42px;
  font-weight: 700;
  color: white;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.trust-score-label {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
}

.trust-score-subtitle {
  font-size: 14px;
  color: #6b7280;
}

body.dark-mode .trust-score-subtitle {
  color: #9ca3af;
}

.scan-details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 20px;
}

@media (max-width: 480px) {
  .scan-details-grid {
    grid-template-columns: 1fr;
  }
}

.detail-item {
  padding: 12px;
  background: #f9fafb;
  border-radius: 8px;
}

body.dark-mode .detail-item {
  background: #1f2937;
}

.detail-item strong {
  display: block;
  font-size: 12px;
  color: #6b7280;
  margin-bottom: 4px;
}

body.dark-mode .detail-item strong {
  color: #9ca3af;
}

.detail-item span {
  font-size: 14px;
  font-weight: 500;
  color: #1f2937;
}

body.dark-mode .detail-item span {
  color: #f3f4f6;
}

/* Cursor Settings (Link Scanner) */
.cursor-setting-item {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  padding: 14px;
  background: #f9fafb;
  border-radius: 8px;
  transition: all 0.2s ease;
}

body.dark-mode .cursor-setting-item {
  background: #1f2937;
}

.cursor-setting-item:hover {
  background: #f3f4f6;
}

body.dark-mode .cursor-setting-item:hover {
  background: #374151;
}

.cursor-setting-item input[type="checkbox"] {
  width: 22px;
  height: 22px;
}

.cursor-setting-item span {
  font-size: 15px;
  color: #1f2937;
  font-weight: 500;
}

body.dark-mode .cursor-setting-item span {
  color: #f3f4f6;
}

/* Cursor Flash Cards */
.cursor-flash-card {
  text-align: center;
  padding: 20px;
  border-radius: 12px;
  border: 3px solid;
  transition: all 0.2s ease;
}

.cursor-flash-card:hover {
  transform: translateY(-4px);
}

.cursor-flash-card.safe {
  background: #f0fdf4;
  border-color: #10b981;
}

body.dark-mode .cursor-flash-card.safe {
  background: rgba(16, 185, 129, 0.1);
}

.cursor-flash-card.suspicious {
  background: #fefce8;
  border-color: #f59e0b;
}

body.dark-mode .cursor-flash-card.suspicious {
  background: rgba(245, 158, 11, 0.1);
}

.cursor-flash-card.danger {
  background: #fef2f2;
  border-color: #ef4444;
}

body.dark-mode .cursor-flash-card.danger {
  background: rgba(239, 68, 68, 0.1);
}

.flash-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

.flash-label {
  font-size: 14px;
  color: #1f2937;
  font-weight: 600;
  margin-bottom: 8px;
}

body.dark-mode .flash-label {
  color: #f3f4f6;
}

.flash-indicator {
  font-size: 13px;
  color: #6b7280;
}

body.dark-mode .flash-indicator {
  color: #9ca3af;
}

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================
   WEBSITE CHECKER - REDESIGNED UI (Mobile-First)
   ============================================ */

/* Hide scrollbars when tools panel is open */
html.tools-panel-open,
body.tools-panel-open {
  overflow: hidden !important;
}

/* LEFT: Logo (click opens settings) */
.wc-header-left {
  display: flex;
  align-items: center;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.wc-header-left:hover {
  opacity: 0.8;
}

.wc-app-icon {
  width: 36px;
  height: 36px;
  object-fit: contain;
  border-radius: 8px;
}

/* CENTER: Product title */
.wc-header-center {
  text-align: center;
}

.wc-title {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-color, #333);
}

body.dark-mode .wc-title,
body.pitch-black-mode .wc-title {
  color: var(--text-color, #eee);
}

.wc-subtitle {
  margin: 0;
  font-size: 12px;
  color: #10b981;
}

/* RIGHT: Action buttons */
.wc-header-right {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

/* Header buttons - emoji style like main extension */
.wc-header-btn {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  padding: 4px;
  color: var(--text-color, #333);
  transition: opacity 0.2s ease;
}

.wc-header-btn:hover {
  opacity: 0.7;
}

body.dark-mode .wc-header-btn,
body.pitch-black-mode .wc-header-btn {
  color: var(--text-color, #eee);
}

/* WC Header - 3-column layout */
.wc-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: var(--card-bg, #fff);
  border-bottom: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .wc-header {
  background: var(--bg-color, #1c1c1c);
  border-color: #333;
}

body.pitch-black-mode .wc-header {
  background: #000000;
  border-color: #333;
}

/* Panel Body */
.tools-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 0;
  background: var(--bg-color, #f0f2f5);
  /* Hide scrollbar but keep scroll functionality (mobile-focused design) */
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}

/* Hide scrollbar for Chrome, Safari, Opera */
.tools-panel-body::-webkit-scrollbar {
  display: none;
}

body.dark-mode .tools-panel-body {
  background: var(--bg-color, #1c1c1c);
}

body.pitch-black-mode .tools-panel-body {
  background: #000000;
}

/* Main Container */
.wc-panel-container {
  max-width: 420px;
  margin: 0 auto;
  padding: 20px;
  padding-bottom: 80px; /* Space for sticky stats bar */
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

/* Web App: Container already constrained by parent 390px */
body[data-platform="webapp"] .wc-panel-container {
  max-width: 100%;
  padding: 16px 0;
  padding-bottom: 70px;
}

/* Input Section */
.wc-input-section {
  background: var(--card-bg, #ffffff);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  margin-bottom: 16px;
  border: 2px solid transparent;
}

/* Web App: Match card styling from main app */
body[data-platform="webapp"] .wc-input-section {
  padding: 16px;
  border-radius: 8px;
}

body.dark-mode .wc-input-section {
  background: var(--card-bg, #2c2c2c);
  border-color: #333;
}

body.pitch-black-mode .wc-input-section {
  background: #000;
  border-color: #333;
}

.wc-input-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-color, #333);
  margin-bottom: 10px;
}

body.dark-mode .wc-input-label {
  color: var(--text-color, #eee);
}

/* URL Input Wrapper for Clear Button */
.wc-url-input-wrapper {
  position: relative;
  width: 100%;
  margin-bottom: 14px;
}

.wc-url-input-wrapper .wc-url-input {
  margin-bottom: 0;
  padding-right: 36px; /* Space for clear button */
}

.wc-url-clear-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: #9ca3af;
  font-size: 16px;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.wc-url-clear-btn:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.1);
}

body.dark-mode .wc-url-clear-btn {
  color: #6b7280;
}

body.dark-mode .wc-url-clear-btn:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.15);
}

body.pitch-black-mode .wc-url-clear-btn {
  color: #555;
}

body.pitch-black-mode .wc-url-clear-btn:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.15);
}

.wc-url-input {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 14px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f9fafb;
  color: var(--text-color, #333);
  margin-bottom: 14px;
  box-sizing: border-box;
  transition: all 0.2s ease;
}

body.dark-mode .wc-url-input {
  background: #1f2937;
  border-color: #4b5563;
  color: var(--text-color, #f3f4f6);
}

body.pitch-black-mode .wc-url-input {
  background: #111;
  border-color: #333;
  color: #eee;
}

.wc-url-input::placeholder {
  color: #6b7280;
}

.wc-url-input:focus {
  outline: none;
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.25);
}

.wc-scan-btn {
  width: 100%;
  padding: 14px 20px;
  background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
  color: white;
  border: none;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.35);
  transition: all 0.3s ease;
}

.wc-scan-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(139, 92, 246, 0.45);
}

.wc-scan-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* Section Title */
.wc-section-title {
  margin: 0 0 16px 0;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-color, #333);
}

body.dark-mode .wc-section-title,
body.pitch-black-mode .wc-section-title {
  color: var(--text-color, #eee);
}

/* Button Row (Settings + History) */
.wc-button-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 14px;
}

.wc-secondary-btn {
  padding: 12px;
  background: var(--card-bg, #f9fafb);
  color: var(--text-color, #333);
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

body.dark-mode .wc-secondary-btn {
  background: #1f2937;
  border-color: #4b5563;
  color: var(--text-color, #eee);
}

body.pitch-black-mode .wc-secondary-btn {
  background: #111;
  border-color: #333;
  color: #eee;
}

.wc-secondary-btn:hover {
  border-color: #8b5cf6;
  background: rgba(139, 92, 246, 0.1);
}

/* Disclaimer */
.wc-disclaimer {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 12px;
  color: #92400e;
  margin-bottom: 16px;
  line-height: 1.5;
}

.wc-disclaimer span {
  font-weight: 700;
  color: #d97706;
}

body.dark-mode .wc-disclaimer,
body.pitch-black-mode .wc-disclaimer {
  background: rgba(245, 158, 11, 0.1);
  color: #fbbf24;
}

body.dark-mode .wc-disclaimer span,
body.pitch-black-mode .wc-disclaimer span {
  color: #f59e0b;
}

/* ============================================
   SETTINGS CONTAINER
   ============================================ */
.wc-settings-container {
  background: var(--card-bg, #ffffff);
  border: 1px solid var(--border-color, #e5e7eb);
  border-radius: 12px;
  padding: 16px;
  margin-top: 16px;
  animation: slideDown 0.3s ease;
}

body.dark-mode .wc-settings-container {
  background: var(--card-bg, #2c2c2c);
  border-color: #444;
}

body.pitch-black-mode .wc-settings-container {
  background: #000000;
  border-color: #333;
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

.wc-settings-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .wc-settings-header,
body.pitch-black-mode .wc-settings-header {
  border-color: #444;
}

.wc-settings-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-color, #333);
}

body.dark-mode .wc-settings-title,
body.pitch-black-mode .wc-settings-title {
  color: #eee;
}

.wc-settings-close {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: var(--text-color, #666);
  padding: 4px 8px;
  border-radius: 4px;
  transition: background 0.2s;
}

.wc-settings-close:hover {
  background: rgba(0, 0, 0, 0.1);
}

body.dark-mode .wc-settings-close,
body.pitch-black-mode .wc-settings-close {
  color: #aaa;
}

body.dark-mode .wc-settings-close:hover,
body.pitch-black-mode .wc-settings-close:hover {
  background: rgba(255, 255, 255, 0.1);
}

.wc-setting-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--border-color, #e5e7eb);
  border-radius: 8px;
  margin-bottom: 8px;
  transition: background 0.2s;
}

body.dark-mode .wc-setting-row,
body.pitch-black-mode .wc-setting-row {
  border-color: #444;
}

.wc-setting-clickable {
  cursor: pointer;
}

.wc-setting-clickable:hover {
  background: rgba(139, 92, 246, 0.1);
}

.wc-setting-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.wc-setting-icon {
  font-size: 20px;
}

.wc-setting-text {
  display: flex;
  flex-direction: column;
}

.wc-setting-label {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-color, #333);
}

body.dark-mode .wc-setting-label,
body.pitch-black-mode .wc-setting-label {
  color: #eee;
}

.wc-setting-desc {
  font-size: 12px;
  color: #666;
}

body.dark-mode .wc-setting-desc,
body.pitch-black-mode .wc-setting-desc {
  color: #aaa;
}

.wc-setting-arrow {
  font-size: 24px;
  color: #8b5cf6;
  font-weight: bold;
}

.wc-settings-divider {
  height: 1px;
  background: var(--border-color, #e5e7eb);
  margin: 12px 0;
}

body.dark-mode .wc-settings-divider,
body.pitch-black-mode .wc-settings-divider {
  background: #444;
}

/* Toggle Switch */
.wc-toggle {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 26px;
}

.wc-toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.wc-toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #d1d5db;
  transition: 0.3s;
  border-radius: 26px;
}

.wc-toggle-slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 0.3s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.wc-toggle input:checked + .wc-toggle-slider {
  background: linear-gradient(135deg, #8b5cf6, #7c3aed);
}

.wc-toggle input:checked + .wc-toggle-slider:before {
  transform: translateX(24px);
}

/* ============================================
   DYNAMIC CONTENT SECTIONS (Stats, Threat Intel)
   ============================================ */
.wc-content-section {
  background: var(--card-bg, #ffffff);
  border: 1px solid var(--border-color, #e5e7eb);
  border-radius: 12px;
  padding: 16px;
  margin-top: 16px;
  animation: slideDown 0.3s ease;
}

body.dark-mode .wc-content-section {
  background: var(--card-bg, #2c2c2c);
  border-color: #444;
}

body.pitch-black-mode .wc-content-section {
  background: #000000;
  border-color: #333;
}

.wc-section-header {
  display: flex;
  align-items: center;
  margin-bottom: 16px;
  gap: 8px;
}

.wc-section-header h3 {
  margin: 0;
  font-size: 16px;
  color: var(--text-color, #333);
  flex-shrink: 0;
}

body.dark-mode .wc-section-header h3,
body.pitch-black-mode .wc-section-header h3 {
  color: #eee;
}

.wc-section-close {
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
  color: #666;
  padding: 4px 8px;
  border-radius: 4px;
  margin-left: auto;
}

.wc-section-close:hover {
  background: rgba(0, 0, 0, 0.1);
}

body.dark-mode .wc-section-close,
body.pitch-black-mode .wc-section-close {
  color: #aaa;
}

/* Real-Time Stats Grid */
.wc-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.wc-live-stat {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(124, 58, 237, 0.1));
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 8px;
  padding: 16px;
  text-align: center;
}

.wc-live-value {
  display: block;
  font-size: 24px;
  font-weight: 700;
  color: #8b5cf6;
}

.wc-live-label {
  display: block;
  font-size: 12px;
  color: #666;
  margin-top: 4px;
}

body.dark-mode .wc-live-label,
body.pitch-black-mode .wc-live-label {
  color: #aaa;
}

.wc-powered-by {
  font-size: 11px;
  color: #3b82f6;
  margin-top: 12px;
  text-align: center;
  font-weight: 600;
}

/* Threat Intelligence Cards */
.wc-live-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  background: #10b981;
  color: white;
  border-radius: 6px;
  font-size: 10px;
  font-weight: 700;
  margin-left: 8px;
}

.wc-threat-card {
  padding: 14px;
  background: var(--card-bg, #f5f5f5);
  border-radius: 8px;
  border: 1px solid var(--border-color, #e5e7eb);
  margin-bottom: 10px;
}

body.dark-mode .wc-threat-card {
  background: #1a1a1a;
  border-color: #333;
}

body.pitch-black-mode .wc-threat-card {
  background: #0a0a0a;
  border-color: #222;
}

.wc-threat-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.wc-threat-card-icon {
  font-size: 18px;
}

.wc-threat-card-name {
  font-weight: 700;
  font-size: 14px;
}

.wc-threat-card-title {
  font-weight: 600;
  font-size: 13px;
  color: var(--text-color, #333);
  margin-bottom: 12px;
}

body.dark-mode .wc-threat-card-title,
body.pitch-black-mode .wc-threat-card-title {
  color: #eee;
}

.wc-threat-card-detail {
  font-size: 12px;
  color: var(--text-color, #666);
  opacity: 0.8;
}

body.dark-mode .wc-threat-card-detail,
body.pitch-black-mode .wc-threat-card-detail {
  color: #bbb;
}

.wc-brands-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 12px;
}

.wc-brand-row {
  display: flex;
  justify-content: space-between;
  color: var(--text-color, #666);
}

body.dark-mode .wc-brand-row,
body.pitch-black-mode .wc-brand-row {
  color: #bbb;
}

.wc-brands-empty {
  text-align: center;
  color: var(--text-color, #666);
  opacity: 0.6;
  padding: 8px;
  font-size: 12px;
}

.wc-powered-by-inline {
  font-size: 11px;
  color: #3b82f6;
  margin-top: 4px;
  font-weight: 600;
}

/* ============================================
   STICKY STATS BAR (Sites Scanned / Threats Blocked)
   ============================================ */
.wc-sticky-stats {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 12px;
  padding: 10px 16px;
  background: var(--card-bg, #ffffff);
  border-top: 1px solid var(--border-color, #e5e7eb);
  box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.1);
  z-index: 100;
  transition: transform 0.3s ease;
}

/* Web App: Constrain sticky bar to 390px centered container */
body[data-platform="webapp"] .wc-sticky-stats {
  max-width: 390px;
  left: 50%;
  right: auto;
  transform: translateX(-50%);
  padding: 10px 16px;
  border-radius: 0;
}

body[data-platform="webapp"] .wc-sticky-stats.hidden {
  transform: translateX(-50%) translateY(100%);
}

body.dark-mode .wc-sticky-stats {
  background: var(--card-bg, #2c2c2c);
  border-color: #444;
}

body.pitch-black-mode .wc-sticky-stats {
  background: #000;
  border-color: #333;
}

.wc-sticky-stats.hidden {
  transform: translateY(100%);
}

/* Compact stat buttons */
.wc-stat-btn {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  font-size: 12px;
  min-width: auto;
}

.wc-stat-btn .wc-stat-emoji {
  font-size: 14px;
  line-height: 1;
}

.wc-stat-btn .wc-stat-count {
  font-size: 13px;
  font-weight: 700;
  color: #8b5cf6;
}

.wc-stat-btn .wc-stat-label {
  font-size: 11px;
  color: #666;
  white-space: nowrap;
}

body.dark-mode .wc-stat-label,
body.pitch-black-mode .wc-stat-label {
  color: #aaa;
}

/* Dynamic Content Area */
#wcDynamicContent {
  flex: 1;
}

.wc-spinner {
  animation: spin 1s linear infinite;
}

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

/* Results Section */
.wc-result-card {
  background: var(--card-bg, #ffffff);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  margin-bottom: 16px;
  border: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .wc-result-card {
  background: var(--card-bg, #2c2c2c);
  border-color: #4b5563;
}

.wc-score-section {
  text-align: center;
  padding-bottom: 16px;
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 16px;
}

body.dark-mode .wc-score-section {
  border-color: #4b5563;
}

.wc-score-circle {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 4px solid;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  background: #f9fafb;
}

body.dark-mode .wc-score-circle {
  background: #1f2937;
}

.wc-score-value {
  font-size: 28px;
  font-weight: 700;
}

.wc-score-label {
  font-size: 16px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Details Sections */
.wc-details-section {
  margin-top: 14px;
  padding: 14px;
  background: var(--card-bg, #f5f5f5);
  border-radius: 8px;
  border: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .wc-details-section {
  background: #1a1a1a;
  border-color: #333;
}

.wc-details-title {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-color, #333);
  margin-bottom: 12px;
}

body.dark-mode .wc-details-title {
  color: #eee;
}

.wc-details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.wc-detail-item {
  padding: 10px;
  background: var(--bg-color, #fff);
  border-radius: 6px;
  border: 1px solid var(--border-color, #ddd);
}

body.dark-mode .wc-detail-item {
  background: #2c2c2c;
  border-color: #444;
}

.wc-detail-label {
  display: block;
  font-size: 11px;
  color: var(--text-color, #888);
  opacity: 0.8;
  margin-bottom: 4px;
}

.wc-detail-value {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-color, #333);
}

body.dark-mode .wc-detail-value {
  color: #eee;
}

.wc-details-note {
  padding: 8px 12px;
  background: rgba(139, 92, 246, 0.1);
  border-radius: 6px;
  border-left: 3px solid #8b5cf6;
}

/* Privacy & SSL Notices */
.wc-privacy-notice {
  margin-top: 12px;
  padding: 8px 12px;
  background: #fef3c7;
  border-radius: 6px;
  border-left: 3px solid #f59e0b;
  font-size: 13px;
  color: #92400e;
}

body.dark-mode .wc-privacy-notice {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
}

.wc-ssl-warning {
  margin-top: 12px;
  padding: 8px 12px;
  background: #fef3c7;
  border-radius: 6px;
  border-left: 3px solid #f59e0b;
  font-size: 13px;
  color: #92400e;
}

body.dark-mode .wc-ssl-warning {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
}

.wc-ssl-danger {
  margin-top: 12px;
  padding: 8px 12px;
  background: #fef2f2;
  border-radius: 6px;
  border-left: 3px solid #ef4444;
  font-size: 13px;
  color: #991b1b;
}

body.dark-mode .wc-ssl-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
}

.wc-threats-list-expanded {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Action Buttons */
.wc-action-buttons {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.wc-action-btn {
  flex: 1;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.wc-copy-btn {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border: 1px solid #6366f1;
  color: #ffffff;
}

body.dark-mode .wc-copy-btn {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border-color: #6366f1;
  color: #ffffff;
}

.wc-copy-btn:hover {
  background: linear-gradient(135deg, #5558e8, #7c4fe3);
  transform: translateY(-1px);
}

.wc-block-btn {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #ef4444;
}

body.dark-mode .wc-block-btn {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.4);
}

.wc-block-btn:hover {
  background: rgba(239, 68, 68, 0.25);
}

/* History Page */
.wc-history-header-stacked {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  margin-bottom: 20px;
}

.wc-back-arrow-stacked {
  background: none;
  border: none;
  color: #8b5cf6;
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.wc-back-arrow-stacked:hover {
  background: rgba(139, 92, 246, 0.15);
  transform: translateX(-3px);
}

body.dark-mode .wc-back-arrow-stacked {
  color: #a78bfa;
}

.wc-history-title-stacked {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-color, #333);
  padding-left: 2px;
}

body.dark-mode .wc-history-title-stacked {
  color: var(--text-color, #eee);
}

.wc-history-list {
  flex: 1;
  overflow-y: auto;
}

.wc-history-empty {
  text-align: center;
  padding: 40px;
  color: #9ca3af;
}

.wc-history-empty span {
  font-size: 48px;
  display: block;
  margin-bottom: 12px;
  opacity: 0.5;
}

.wc-history-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  background: var(--card-bg, #ffffff);
  border-radius: 10px;
  margin-bottom: 10px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  border-left: 4px solid;
}

body.dark-mode .wc-history-item {
  background: var(--card-bg, #2c2c2c);
}

.wc-history-item.safe {
  border-color: #10b981;
}

.wc-history-item.caution {
  border-color: #f59e0b;
}

.wc-history-item.danger {
  border-color: #ef4444;
}

.wc-history-score {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
  flex-shrink: 0;
  color: #ffffff;
}

.wc-history-score.safe {
  background: linear-gradient(135deg, #10b981, #059669);
}

.wc-history-score.caution {
  background: linear-gradient(135deg, #f59e0b, #d97706);
}

.wc-history-score.danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
}

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

.wc-history-url {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-color, #333);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.dark-mode .wc-history-url {
  color: var(--text-color, #eee);
}

.wc-history-meta {
  font-size: 11px;
  color: #9ca3af;
  margin-top: 2px;
}

body.dark-mode .wc-history-meta {
  color: #9ca3af;
}

/* Block Domain Confirmation Popup */
.wc-confirm-popup {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 20000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wc-confirm-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
}

.wc-confirm-dialog {
  position: relative;
  background: var(--card-bg, #ffffff);
  border-radius: 16px;
  padding: 32px;
  max-width: 360px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: popIn 0.2s ease;
}

body.dark-mode .wc-confirm-dialog {
  background: var(--card-bg, #2d2d2d);
  border: 1px solid #404040;
}

@keyframes popIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.wc-confirm-logo {
  margin-bottom: 16px;
}

.wc-confirm-logo img {
  border-radius: 12px;
}

.wc-confirm-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-color, #333);
  margin: 0 0 12px 0;
}

body.dark-mode .wc-confirm-title {
  color: var(--text-color, #eee);
}

.wc-confirm-message {
  font-size: 14px;
  color: var(--text-color, #666);
  margin: 0 0 8px 0;
}

.wc-confirm-message strong {
  color: #ef4444;
}

body.dark-mode .wc-confirm-message {
  color: var(--text-color, #aaa);
}

.wc-confirm-note {
  font-size: 12px;
  color: #9ca3af;
  margin: 0 0 24px 0;
}

.wc-confirm-buttons {
  display: flex;
  gap: 12px;
}

.wc-confirm-btn {
  flex: 1;
  padding: 12px 20px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.wc-confirm-no {
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  color: var(--text-color, #333);
}

body.dark-mode .wc-confirm-no {
  background: #374151;
  border-color: #4b5563;
  color: var(--text-color, #eee);
}

body.pitch-black-mode .wc-confirm-no {
  background: #1f2937;
  border-color: #374151;
  color: #e5e7eb;
}

.wc-confirm-no:hover {
  background: #e5e7eb;
}

body.dark-mode .wc-confirm-no:hover {
  background: #4b5563;
}

.wc-confirm-yes {
  background: #ef4444;
  border: 1px solid #dc2626;
  color: #ffffff;
}

.wc-confirm-yes:hover {
  background: #dc2626;
  transform: translateY(-1px);
}

/* Loading spinner */
.wc-loading-spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  color: #666;
  font-size: 14px;
}

body.dark-mode .wc-loading-spinner {
  color: #aaa;
}

/* Status warning for offline mode */
.wc-status-warning {
  padding: 12px;
  background: rgba(245, 158, 11, 0.15);
  border-radius: 8px;
  color: #d97706;
  font-size: 13px;
  text-align: center;
}

body.dark-mode .wc-status-warning {
  color: #fbbf24;
}

/* ============================================
   LINK SCANNER STYLES
   ============================================ */

/* Link Scanner Container */
.ls-container {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Section Cards */
.ls-section-card {
  background: var(--card-bg, #ffffff);
  padding: 16px;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

body.dark-mode .ls-section-card {
  background: var(--card-bg, #374151);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

body.pitch-black-mode .ls-section-card {
  background: #1f2937;
}

.ls-section-title {
  margin: 0 0 12px 0;
  color: var(--text-color, #333);
  font-size: 14px;
  font-weight: 600;
}

body.dark-mode .ls-section-title {
  color: var(--text-color, #f3f4f6);
}

/* Setting Rows */
.ls-setting-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-color, #f0f0f0);
}

body.dark-mode .ls-setting-row {
  border-bottom-color: var(--border-color, #4b5563);
}

.ls-setting-row-last {
  border-bottom: none;
  padding-bottom: 0;
}

.ls-setting-highlight {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(124, 58, 237, 0.05));
  margin: -10px -12px 10px -12px;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid rgba(139, 92, 246, 0.3);
}

body.dark-mode .ls-setting-highlight {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.2), rgba(124, 58, 237, 0.1));
  border-color: rgba(139, 92, 246, 0.4);
}

.ls-setting-label {
  font-size: 12px;
  color: var(--text-color, #333);
  display: block;
}

body.dark-mode .ls-setting-label {
  color: var(--text-color, #e5e7eb);
}

.ls-setting-desc {
  font-size: 10px;
  color: #666;
  display: block;
  margin-top: 2px;
}

body.dark-mode .ls-setting-desc {
  color: #9ca3af;
}

/* Toggle Switch */
.ls-toggle {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}

.ls-toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.ls-toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: 0.3s;
  border-radius: 12px;
}

.ls-toggle-slider::before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 2px;
  bottom: 2px;
  background-color: white;
  transition: 0.3s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.ls-toggle input:checked + .ls-toggle-slider {
  background-color: #8b5cf6;
}

.ls-toggle input:checked + .ls-toggle-slider::before {
  transform: translateX(20px);
}

body.dark-mode .ls-toggle-slider {
  background-color: #4b5563;
}

/* Flash Effects */
.ls-flash-effects {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ls-flash-card {
  padding: 12px;
  border-radius: 6px;
  border-left: 4px solid;
}

.ls-flash-safe {
  background: #f0fdf4;
  border-left-color: #4caf50;
}

body.dark-mode .ls-flash-safe {
  background: rgba(76, 175, 80, 0.15);
}

.ls-flash-suspicious {
  background: #fefce8;
  border-left-color: #f59e0b;
}

body.dark-mode .ls-flash-suspicious {
  background: rgba(245, 158, 11, 0.15);
}

.ls-flash-danger {
  background: #fef2f2;
  border-left-color: #ef4444;
}

body.dark-mode .ls-flash-danger {
  background: rgba(239, 68, 68, 0.15);
}

.ls-flash-header {
  font-weight: 600;
  font-size: 12px;
  color: var(--text-color, #333);
  margin-bottom: 6px;
}

body.dark-mode .ls-flash-header {
  color: var(--text-color, #e5e7eb);
}

.ls-flash-preview {
  font-size: 20px;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.ls-flash-logo {
  width: 20px;
  height: 20px;
  vertical-align: middle;
}

.ls-flash-desc {
  font-size: 10px;
  color: #666;
}

body.dark-mode .ls-flash-desc {
  color: #9ca3af;
}

/* Activity Grid */
.ls-activity-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.ls-activity-stat {
  text-align: center;
  padding: 12px;
  border-radius: 8px;
  border: 2px solid;
}

.ls-stat-safe {
  background: #f0fdf4;
  border-color: #4caf50;
}

body.dark-mode .ls-stat-safe {
  background: rgba(76, 175, 80, 0.15);
}

.ls-stat-suspicious {
  background: #fefce8;
  border-color: #f59e0b;
}

body.dark-mode .ls-stat-suspicious {
  background: rgba(245, 158, 11, 0.15);
}

.ls-stat-blocked {
  background: #fef2f2;
  border-color: #ef4444;
}

body.dark-mode .ls-stat-blocked {
  background: rgba(239, 68, 68, 0.15);
}

.ls-stat-number {
  font-size: 24px;
  font-weight: bold;
}

.ls-stat-safe .ls-stat-number { color: #4caf50; }
.ls-stat-suspicious .ls-stat-number { color: #f59e0b; }
.ls-stat-blocked .ls-stat-number { color: #ef4444; }

.ls-stat-label {
  font-size: 10px;
  color: var(--text-color, #333);
  margin-top: 4px;
}

body.dark-mode .ls-stat-label {
  color: var(--text-color, #e5e7eb);
}

/* Last Scan Box */
.ls-last-scan-box {
  margin-top: 16px;
  padding: 12px;
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-radius: 8px;
  border-left: 4px solid #6366f1;
}

body.dark-mode .ls-last-scan-box {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(99, 102, 241, 0.05) 100%);
}

body.pitch-black-mode .ls-last-scan-box {
  background: #000000;
  border-left: none;
  border: 1px solid #4b5563;
  border-radius: 8px;
}

.ls-last-scan-box.ls-no-scans {
  border-left-color: #94a3b8;
  opacity: 0.7;
}

/* Collapsible Evidence Header */
.ls-last-scan-header,
.ls-evidence-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  padding: 4px 0;
  user-select: none;
  transition: opacity 0.2s ease;
}

.ls-last-scan-header:hover,
.ls-evidence-header:hover {
  opacity: 0.8;
}

.ls-toggle-arrow {
  font-size: 10px;
  color: #6366f1;
  transition: transform 0.3s ease;
  margin-left: 8px;
}

body.dark-mode .ls-toggle-arrow,
body.pitch-black-mode .ls-toggle-arrow {
  color: #a5b4fc;
}

.ls-last-scan-content-wrapper {
  margin-top: 8px;
  animation: lsSlideDown 0.2s ease;
}

@keyframes lsSlideDown {
  from { opacity: 0; max-height: 0; }
  to { opacity: 1; max-height: 500px; }
}

.ls-last-scan-title {
  font-size: 12px;
  font-weight: bold;
  color: #6366f1;
}

.ls-last-scan-content {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ls-last-scan-url {
  font-size: 12px;
  font-weight: 600;
  word-break: break-all;
  padding: 6px 8px;
  border-radius: 4px;
  background: rgba(0,0,0,0.05);
}

body.dark-mode .ls-last-scan-url {
  background: rgba(255,255,255,0.08);
}

body.pitch-black-mode .ls-last-scan-url {
  background: #111111;
}

.ls-last-scan-url.safe { color: #4caf50; border-left: 3px solid #4caf50; }
.ls-last-scan-url.suspicious { color: #f59e0b; border-left: 3px solid #f59e0b; }
.ls-last-scan-url.blocked, .ls-last-scan-url.danger { color: #ef4444; border-left: 3px solid #ef4444; }

.ls-last-scan-time {
  font-size: 10px;
  color: #64748b;
}

.ls-last-scan-evidence {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 6px;
}

.ls-evidence-tag {
  font-size: 10px;
  color: #475569;
  background: rgba(0,0,0,0.04);
  padding: 2px 6px;
  border-radius: 4px;
  display: inline-block;
}

body.dark-mode .ls-evidence-tag {
  background: rgba(255,255,255,0.06);
  color: #94a3b8;
}

body.pitch-black-mode .ls-evidence-tag {
  background: #111111;
  color: #94a3b8;
}

.ls-no-scan-text {
  font-size: 12px;
  color: #64748b;
  font-style: italic;
}

/* Test Scan Button */
.ls-test-scan-btn {
  width: 100%;
  margin-top: 12px;
  padding: 10px 16px;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ls-test-scan-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.ls-test-scan-btn:active {
  transform: translateY(0);
}

/* Threat Section */
.ls-threat-section {
  /* Inherits from .ls-section-card */
  position: relative;
}

.ls-threat-card {
  padding: 12px;
  background: #fef2f2;
  border-radius: 6px;
  border: 2px solid #ef4444;
}

body.dark-mode .ls-threat-card {
  background: rgba(239, 68, 68, 0.15);
}

.ls-threat-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.ls-threat-icons {
  font-size: 24px;
}

.ls-threat-info {
  flex: 1;
}

.ls-threat-url {
  font-size: 11px;
  color: var(--text-color, #333);
  font-family: monospace;
  font-weight: 600;
  margin-bottom: 4px;
  word-break: break-all;
}

body.dark-mode .ls-threat-url {
  color: var(--text-color, #e5e7eb);
}

.ls-threat-status {
  font-size: 10px;
  color: #ef4444;
  font-weight: 600;
}

.ls-evidence-box {
  background: var(--card-bg, white);
  padding: 12px;
  border-radius: 6px;
  margin-bottom: 12px;
}

body.dark-mode .ls-evidence-box {
  background: rgba(0, 0, 0, 0.2);
}

.ls-evidence-title {
  font-weight: 600;
  font-size: 11px;
  color: var(--text-color, #333);
  margin-bottom: 8px;
}

body.dark-mode .ls-evidence-title {
  color: var(--text-color, #e5e7eb);
}

.ls-evidence-content {
  font-size: 10px;
  color: #666;
  line-height: 1.6;
}

body.dark-mode .ls-evidence-content {
  color: #9ca3af;
}

.ls-copy-btn {
  width: 100%;
  padding: 10px;
  background: #e5e7eb;
  color: var(--text-color, #333);
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ls-copy-btn:hover {
  background: #d1d5db;
}

body.dark-mode .ls-copy-btn {
  background: #4b5563;
  color: #e5e7eb;
}

body.dark-mode .ls-copy-btn:hover {
  background: #6b7280;
}

/* No Threats Message */
.ls-no-threat-msg {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: #f0fdf4;
  border-radius: 8px;
}

body.dark-mode .ls-no-threat-msg {
  background: rgba(76, 175, 80, 0.15);
}

.ls-no-threat-icon {
  font-size: 32px;
}

.ls-no-threat-text {
  font-size: 13px;
  color: #4caf50;
  font-weight: 500;
}

/* Footer Buttons */
.ls-footer-buttons {
  display: flex;
  gap: 8px;
}

.ls-footer-btn {
  flex: 1;
  padding: 10px;
  background: #2c2c2c;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ls-footer-btn:hover {
  background: #444;
}

body.dark-mode .ls-footer-btn {
  background: #1f2937;
}

body.dark-mode .ls-footer-btn:hover {
  background: #374151;
}

/* ============================================
   CLIPBOARD SCANNER STYLES (Vertical Layout)
   ============================================ */

/* Container */
.pls-container {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* URL Input Section */
.pls-url-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pls-url-wrapper {
  position: relative;
}

.pls-url-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 16px;
  pointer-events: none;
}

.pls-url-input {
  width: 100%;
  padding: 14px 44px 14px 40px;
  background: var(--card-bg, #f0f2f5);
  border: 2px solid var(--border-color, #d1d5db);
  border-radius: 12px;
  color: var(--text-color, #333);
  font-size: 14px;
  transition: all 0.2s;
}

body.dark-mode .pls-url-input {
  background: #1f2937;
  border-color: #374151;
  color: #fff;
}

body.pitch-black-mode .pls-url-input {
  background: #111;
  border-color: #333;
  color: #fff;
}

.pls-url-input:focus {
  outline: none;
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2);
}

.pls-url-input::placeholder {
  color: #9ca3af;
}

.pls-clear-btn {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: #6b7280;
  border: none;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: white;
  transition: all 0.2s;
}

.pls-clear-btn:hover {
  background: #ef4444;
}

.pls-scan-btn {
  width: 100%;
  background: linear-gradient(135deg, #8b5cf6, #6366f1);
  color: white;
  border: none;
  padding: 14px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s;
}

.pls-scan-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(139, 92, 246, 0.4);
}

.pls-scan-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Scanned Page Info */
.pls-scanned-page {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(99, 102, 241, 0.05));
  border-radius: 12px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.pls-scanned-icon {
  width: 36px;
  height: 36px;
  background: var(--card-bg, #fff);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

body.dark-mode .pls-scanned-icon,
body.pitch-black-mode .pls-scanned-icon {
  background: #1f2937;
}

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

.pls-scanned-url {
  font-size: 13px;
  color: var(--text-color, #333);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pls-scanned-meta {
  font-size: 11px;
  color: #9ca3af;
  margin-top: 2px;
}

/* Stats Row */
.pls-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.pls-stat-box {
  background: var(--card-bg, #fff);
  border-radius: 10px;
  padding: 12px 6px;
  text-align: center;
  border: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .pls-stat-box {
  background: #1f2937;
  border-color: #374151;
}

body.pitch-black-mode .pls-stat-box {
  background: #111;
  border-color: #333;
}

.pls-stat-value {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 2px;
}

.pls-stat-value.pls-total { color: #8b5cf6; }
.pls-stat-value.pls-safe { color: #22c55e; }
.pls-stat-value.pls-warning { color: #f59e0b; }
.pls-stat-value.pls-danger { color: #ef4444; }

.pls-stat-label {
  font-size: 10px;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Section */
.pls-section {
  background: var(--card-bg, #fff);
  border-radius: 12px;
  padding: 16px;
  border: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .pls-section {
  background: #1f2937;
  border-color: #374151;
}

body.pitch-black-mode .pls-section {
  background: #111;
  border-color: #333;
}

.pls-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.pls-section-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-color, #333);
  display: flex;
  align-items: center;
  gap: 8px;
}

.pls-live-badge {
  background: #22c55e;
  color: white;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 9px;
  font-weight: 700;
  animation: plsPulse 2s infinite;
}

@keyframes plsPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

/* Filter Pills */
.pls-filter-pills {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
  overflow-x: auto;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
}

.pls-filter-pill {
  padding: 6px 12px;
  background: var(--card-bg, #f3f4f6);
  border: 1px solid var(--border-color, #e5e7eb);
  border-radius: 20px;
  font-size: 12px;
  color: #6b7280;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
}

body.dark-mode .pls-filter-pill {
  background: #374151;
  border-color: #4b5563;
  color: #9ca3af;
}

body.pitch-black-mode .pls-filter-pill {
  background: #1f2937;
  border-color: #374151;
  color: #9ca3af;
}

.pls-filter-pill:hover {
  border-color: #8b5cf6;
  color: #8b5cf6;
}

.pls-filter-pill.active {
  background: #8b5cf6;
  border-color: #8b5cf6;
  color: white;
}

/* Link Cards */
.pls-links-container {
  max-height: 350px;
  overflow-y: auto;
}

.pls-link-card {
  background: var(--card-bg, #f9fafb);
  border-radius: 10px;
  padding: 14px;
  margin-bottom: 10px;
  border: 1px solid var(--border-color, #e5e7eb);
  border-left: 3px solid #22c55e;
}

body.dark-mode .pls-link-card {
  background: #111827;
  border-color: #374151;
}

body.pitch-black-mode .pls-link-card {
  background: #0a0a0a;
  border-color: #333;
}

.pls-link-card.pls-warning {
  border-left-color: #f59e0b;
}

.pls-link-card.pls-danger {
  border-left-color: #ef4444;
}

.pls-link-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 6px;
}

.pls-link-url {
  font-size: 12px;
  color: #60a5fa;
  word-break: break-all;
  flex: 1;
}

.pls-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 600;
  white-space: nowrap;
}

.pls-status-badge.pls-badge-safe {
  background: rgba(34, 197, 94, 0.15);
  color: #22c55e;
}

.pls-status-badge.pls-badge-warning {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
}

.pls-status-badge.pls-badge-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
}

.pls-link-threat {
  font-size: 11px;
  color: #9ca3af;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Action Buttons */
.pls-action-row {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}

.pls-action-btn {
  flex: 1;
  padding: 10px;
  background: var(--card-bg, #f3f4f6);
  border: 1px solid var(--border-color, #e5e7eb);
  border-radius: 8px;
  color: var(--text-color, #333);
  font-size: 11px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
}

body.dark-mode .pls-action-btn {
  background: #374151;
  border-color: #4b5563;
  color: #e5e7eb;
}

body.pitch-black-mode .pls-action-btn {
  background: #1f2937;
  border-color: #374151;
  color: #e5e7eb;
}

.pls-action-btn:hover {
  background: #e5e7eb;
}

body.dark-mode .pls-action-btn:hover,
body.pitch-black-mode .pls-action-btn:hover {
  background: #4b5563;
}

/* Recent Scans */
.pls-recent-scans {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pls-recent-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: var(--card-bg, #f9fafb);
  border: 1px solid var(--border-color, #e5e7eb);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

body.dark-mode .pls-recent-item {
  background: #111827;
  border-color: #374151;
}

body.pitch-black-mode .pls-recent-item {
  background: #0a0a0a;
  border-color: #333;
}

.pls-recent-item:hover {
  background: #e5e7eb;
}

body.dark-mode .pls-recent-item:hover,
body.pitch-black-mode .pls-recent-item:hover {
  background: #374151;
}

.pls-recent-icon {
  font-size: 16px;
}

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

.pls-recent-url {
  font-size: 12px;
  color: var(--text-color, #333);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pls-recent-meta {
  font-size: 10px;
  color: #9ca3af;
  margin-top: 2px;
}

/* Empty State */
.pls-empty-state {
  text-align: center;
  padding: 40px 20px;
  color: #9ca3af;
}

.pls-empty-icon {
  font-size: 40px;
  margin-bottom: 12px;
  opacity: 0.5;
}

.pls-empty-text {
  font-size: 14px;
  margin-bottom: 6px;
}

.pls-empty-hint {
  font-size: 12px;
  opacity: 0.7;
}

/* Scanning Overlay */
.pls-scanning-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 10;
  border-radius: 12px;
}

.pls-spinner {
  width: 48px;
  height: 48px;
  border: 3px solid #374151;
  border-top-color: #8b5cf6;
  border-radius: 50%;
  animation: plsSpin 1s linear infinite;
  margin-bottom: 16px;
}

@keyframes plsSpin {
  to { transform: rotate(360deg); }
}

.pls-scanning-text {
  font-size: 15px;
  color: #fff;
  margin-bottom: 6px;
}

.pls-scanning-progress {
  font-size: 12px;
  color: #9ca3af;
}

/* Scrollbar */
.pls-links-container::-webkit-scrollbar {
  width: 6px;
}

.pls-links-container::-webkit-scrollbar-track {
  background: transparent;
}

.pls-links-container::-webkit-scrollbar-thumb {
  background: #6b7280;
  border-radius: 3px;
}

.pls-links-container::-webkit-scrollbar-thumb:hover {
  background: #8b5cf6;
}

/* ============================================
   VIEW ALL BUTTON (Header Row)
   ============================================ */

.ls-section-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.ls-section-header-row .ls-section-title {
  margin-bottom: 0;
}

.ls-view-all-btn {
  padding: 6px 12px;
  background: transparent;
  color: #8b5cf6;
  border: 1px solid #8b5cf6;
  border-radius: 6px;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.ls-view-all-btn:hover {
  background: rgba(139, 92, 246, 0.1);
}

/* ============================================
   LINK SCANNER MODALS (Settings & Whitelist)
   ============================================ */

.ls-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.ls-modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.ls-modal {
  background: var(--card-bg, #ffffff);
  border-radius: 12px;
  width: 90%;
  max-width: 420px;
  max-height: 85vh;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  transform: scale(0.9) translateY(20px);
  transition: transform 0.25s ease;
}

.ls-modal-overlay.active .ls-modal {
  transform: scale(1) translateY(0);
}

body.dark-mode .ls-modal {
  background: var(--card-bg, #1f2937);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

body.pitch-black-mode .ls-modal {
  background: #111;
}

.ls-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color, #e5e7eb);
  background: linear-gradient(135deg, #8b5cf6, #7c3aed);
  color: white;
}

body.dark-mode .ls-modal-header {
  border-bottom-color: var(--border-color, #374151);
}

.ls-modal-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.ls-modal-close {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: white;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  transition: background 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ls-modal-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

.ls-modal-body {
  padding: 20px;
  overflow-y: auto;
  max-height: calc(85vh - 120px);
}

.ls-modal-section {
  margin-bottom: 20px;
}

.ls-modal-section:last-child {
  margin-bottom: 0;
}

.ls-modal-section-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-color, #374151);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

body.dark-mode .ls-modal-section-title {
  color: var(--text-color, #e5e7eb);
}

/* Settings Modal Specific */
.ls-settings-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-color, #f0f0f0);
}

.ls-settings-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

body.dark-mode .ls-settings-item {
  border-bottom-color: var(--border-color, #374151);
}

.ls-settings-item-info {
  flex: 1;
}

.ls-settings-item-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-color, #333);
  margin-bottom: 2px;
}

body.dark-mode .ls-settings-item-label {
  color: var(--text-color, #e5e7eb);
}

.ls-settings-item-desc {
  font-size: 11px;
  color: #666;
}

body.dark-mode .ls-settings-item-desc {
  color: #9ca3af;
}

/* Notification Sound Selector */
.ls-sound-selector {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.ls-sound-option {
  padding: 8px 12px;
  background: #f3f4f6;
  border: 2px solid transparent;
  border-radius: 6px;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ls-sound-option:hover {
  background: #e5e7eb;
}

.ls-sound-option.active {
  border-color: #8b5cf6;
  background: rgba(139, 92, 246, 0.1);
}

body.dark-mode .ls-sound-option {
  background: #374151;
  color: #e5e7eb;
}

body.dark-mode .ls-sound-option:hover {
  background: #4b5563;
}

body.dark-mode .ls-sound-option.active {
  background: rgba(139, 92, 246, 0.2);
}

/* Action Buttons (Clear, Export, Cancel - same style as sound options) */
.ls-action-btn {
  padding: 8px 16px;
  background: #f3f4f6;
  border: 2px solid transparent;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  color: #374151;
}

.ls-action-btn:hover {
  background: #e5e7eb;
  border-color: #8b5cf6;
}

body.dark-mode .ls-action-btn {
  background: #374151;
  color: #e5e7eb;
  border-color: transparent;
}

body.dark-mode .ls-action-btn:hover {
  background: #4b5563;
  border-color: #8b5cf6;
}

body.pitch-black-mode .ls-action-btn {
  background: #1a1a1a;
  color: #e5e7eb;
  border: 1px solid #333333;
}

body.pitch-black-mode .ls-action-btn:hover {
  background: #2a2a2a;
  border-color: #8b5cf6;
}

/* Liability Disclaimer */
.ls-disclaimer {
  padding: 10px 12px;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: 8px;
  font-size: 11px;
  color: #92400e;
  line-height: 1.4;
  margin-bottom: 12px;
}

.ls-disclaimer span {
  font-weight: 600;
}

body.dark-mode .ls-disclaimer {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.25);
  color: #fbbf24;
}

body.pitch-black-mode .ls-disclaimer {
  background: rgba(245, 158, 11, 0.08);
  border-color: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
}

/* ============================================
   PITCH BLACK MODE - LINK SCANNER
   ============================================ */

/* Section Cards - pure black with gray border */
body.pitch-black-mode .ls-section-card {
  background: #000000 !important;
  border: 1px solid #333333;
}

/* Sound selector buttons */
body.pitch-black-mode .ls-sound-option {
  background: #1a1a1a;
  color: #e5e7eb;
  border: 1px solid #333333;
}

body.pitch-black-mode .ls-sound-option:hover {
  background: #2a2a2a;
}

body.pitch-black-mode .ls-sound-option.active {
  background: rgba(139, 92, 246, 0.25);
  border-color: #8b5cf6;
}

/* Flash effect cards - darker backgrounds with borders */
body.pitch-black-mode .ls-flash-safe {
  background: rgba(76, 175, 80, 0.1);
  border-color: #4caf50;
}

body.pitch-black-mode .ls-flash-suspicious {
  background: rgba(245, 158, 11, 0.1);
  border-color: #f59e0b;
}

body.pitch-black-mode .ls-flash-danger {
  background: rgba(239, 68, 68, 0.1);
  border-color: #ef4444;
}

/* Activity stats - darker with borders */
body.pitch-black-mode .ls-stat-safe {
  background: rgba(76, 175, 80, 0.08);
  border-color: #4caf50;
}

body.pitch-black-mode .ls-stat-suspicious {
  background: rgba(245, 158, 11, 0.08);
  border-color: #f59e0b;
}

body.pitch-black-mode .ls-stat-blocked {
  background: rgba(239, 68, 68, 0.08);
  border-color: #ef4444;
}

/* Threat section */
body.pitch-black-mode .ls-threat-section {
  background: #000000;
  border: 1px solid #333333;
}

body.pitch-black-mode .ls-threat-card {
  background: #0a0a0a;
  border: 1px solid #2a2a2a;
}

body.pitch-black-mode .ls-no-threat-msg {
  background: rgba(76, 175, 80, 0.08);
  border: 1px solid rgba(76, 175, 80, 0.3);
}

/* Evidence box */
body.pitch-black-mode .ls-evidence-box {
  background: #0a0a0a;
  border: 1px solid #2a2a2a;
}

/* Setting rows border */
body.pitch-black-mode .ls-setting-row {
  border-bottom-color: #2a2a2a;
}

/* Setting highlight */
body.pitch-black-mode .ls-setting-highlight {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(124, 58, 237, 0.08));
  border-color: rgba(139, 92, 246, 0.3);
}

/* Modal styles */
body.pitch-black-mode .ls-modal {
  background: #000000;
  border: 1px solid #333333;
}

body.pitch-black-mode .ls-modal-header {
  border-bottom-color: #333333;
}

body.pitch-black-mode .ls-modal-section {
  border-bottom-color: #2a2a2a;
}

body.pitch-black-mode .ls-settings-item {
  border-bottom-color: #2a2a2a;
}

/* Whitelist Modal Specific */
.ls-whitelist-input-row {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.ls-whitelist-input {
  flex: 1;
  padding: 10px 12px;
  border: 2px solid var(--border-color, #e5e7eb);
  border-radius: 8px;
  font-size: 13px;
  background: var(--card-bg, #ffffff);
  color: var(--text-color, #333);
  outline: none;
  transition: border-color 0.2s ease;
}

.ls-whitelist-input:focus {
  border-color: #8b5cf6;
}

body.dark-mode .ls-whitelist-input {
  background: var(--card-bg, #374151);
  color: var(--text-color, #e5e7eb);
  border-color: var(--border-color, #4b5563);
}

.ls-whitelist-add-btn {
  padding: 10px 16px;
  background: #8b5cf6;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease;
  white-space: nowrap;
}

.ls-whitelist-add-btn:hover {
  background: #7c3aed;
}

.ls-whitelist-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 200px;
  overflow-y: auto;
}

.ls-whitelist-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  background: #f9fafb;
  border-radius: 6px;
  border: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .ls-whitelist-item {
  background: #374151;
  border-color: var(--border-color, #4b5563);
}

.ls-whitelist-domain {
  font-size: 12px;
  font-family: monospace;
  color: var(--text-color, #333);
}

body.dark-mode .ls-whitelist-domain {
  color: var(--text-color, #e5e7eb);
}

.ls-whitelist-remove {
  background: #ef4444;
  color: white;
  border: none;
  width: 24px;
  height: 24px;
  border-radius: 4px;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.ls-whitelist-remove:hover {
  background: #dc2626;
}

.ls-whitelist-empty {
  text-align: center;
  padding: 24px;
  color: #9ca3af;
  font-size: 12px;
}

/* ============================================
   SCAN HISTORY MODAL STYLES
   ============================================ */

.ls-scan-history-toggle {
  padding: 12px;
  background: #f9fafb;
  border-radius: 8px;
  border: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .ls-scan-history-toggle {
  background: #374151;
  border-color: var(--border-color, #4b5563);
}

.ls-toggle-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
}

.ls-toggle-label input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.ls-toggle-slider {
  position: relative;
  width: 40px;
  height: 22px;
  background: #d1d5db;
  border-radius: 11px;
  transition: background 0.3s ease;
}

.ls-toggle-slider::before {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  background: white;
  border-radius: 50%;
  transition: transform 0.3s ease;
}

.ls-toggle-label input:checked + .ls-toggle-slider {
  background: #8b5cf6;
}

.ls-toggle-label input:checked + .ls-toggle-slider::before {
  transform: translateX(18px);
}

body.dark-mode .ls-toggle-slider {
  background: #4b5563;
}

.ls-scan-history-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 280px;
  overflow-y: auto;
}

.ls-scan-history-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: #f9fafb;
  border-radius: 8px;
  border: 1px solid var(--border-color, #e5e7eb);
  cursor: pointer;
  transition: all 0.2s ease;
}

.ls-scan-history-item:hover {
  background: #f3f4f6;
  border-color: #8b5cf6;
}

body.dark-mode .ls-scan-history-item {
  background: #374151;
  border-color: var(--border-color, #4b5563);
}

body.dark-mode .ls-scan-history-item:hover {
  background: #3f4758;
  border-color: #8b5cf6;
}

.ls-scan-history-status {
  font-size: 18px;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  flex-shrink: 0;
}

.ls-scan-history-status.ls-status-blocked {
  background: rgba(239, 68, 68, 0.15);
}

.ls-scan-history-status.ls-status-suspicious {
  background: rgba(245, 158, 11, 0.15);
}

.ls-scan-history-status.ls-status-safe {
  background: rgba(34, 197, 94, 0.15);
}

.ls-scan-history-info {
  flex: 1;
  min-width: 0;
}

.ls-scan-history-url {
  font-size: 12px;
  font-family: 'SF Mono', Consolas, monospace;
  color: var(--text-color, #333);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.dark-mode .ls-scan-history-url {
  color: var(--text-color, #e5e7eb);
}

.ls-scan-history-time {
  font-size: 10px;
  color: #9ca3af;
  margin-top: 2px;
}

.ls-scan-history-view {
  background: #8b5cf6;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease;
  flex-shrink: 0;
}

.ls-scan-history-view:hover {
  background: #7c3aed;
}

.ls-scan-history-empty {
  text-align: center;
  padding: 32px 16px;
  color: #9ca3af;
  font-size: 12px;
  line-height: 1.6;
}

/* Scan Detail Modal Styles */
.ls-scan-detail-url {
  padding: 12px;
  background: #f9fafb;
  border-radius: 8px;
  font-size: 12px;
  word-break: break-all;
}

body.dark-mode .ls-scan-detail-url {
  background: #374151;
}

.ls-scan-detail-status.ls-status-blocked {
  background: rgba(239, 68, 68, 0.15);
  color: #dc2626;
}

.ls-scan-detail-status.ls-status-suspicious {
  background: rgba(245, 158, 11, 0.15);
  color: #d97706;
}

.ls-scan-detail-status.ls-status-safe {
  background: rgba(34, 197, 94, 0.15);
  color: #16a34a;
}

body.dark-mode .ls-scan-detail-status.ls-status-blocked {
  color: #f87171;
}

body.dark-mode .ls-scan-detail-status.ls-status-suspicious {
  color: #fbbf24;
}

body.dark-mode .ls-scan-detail-status.ls-status-safe {
  color: #4ade80;
}

.ls-modal-btn-danger {
  background: #ef4444;
  color: white;
  border: none;
}

.ls-modal-btn-danger:hover {
  background: #dc2626;
}

/* Modal Footer */
.ls-modal-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border-color, #e5e7eb);
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

body.dark-mode .ls-modal-footer {
  border-top-color: var(--border-color, #374151);
}

.ls-modal-btn {
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ls-modal-btn-secondary {
  background: #e5e7eb;
  color: #374151;
  border: none;
}

.ls-modal-btn-secondary:hover {
  background: #d1d5db;
}

body.dark-mode .ls-modal-btn-secondary {
  background: #4b5563;
  color: #e5e7eb;
}

body.dark-mode .ls-modal-btn-secondary:hover {
  background: #6b7280;
}

.ls-modal-btn-primary {
  background: #8b5cf6;
  color: white;
  border: none;
}

.ls-modal-btn-primary:hover {
  background: #7c3aed;
}

/* ============================================
   CURSOR FLASH ANIMATIONS (Safe/Suspicious/Danger)
   ============================================ */

@keyframes ls-cursor-flash-safe {
  0%, 100% { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Ccircle cx='12' cy='12' r='10' fill='%234caf50'/%3E%3C/svg%3E") 12 12, auto; }
  50% { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Crect width='24' height='24' rx='3' fill='%23fff'/%3E%3Ctext x='12' y='17' font-size='14' text-anchor='middle'%3E🔵%3C/text%3E%3C/svg%3E") 12 12, auto; }
}

@keyframes ls-cursor-flash-suspicious {
  0%, 100% { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Cpolygon points='12,2 22,22 2,22' fill='%23f59e0b'/%3E%3C/svg%3E") 12 12, auto; }
  50% { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Crect width='24' height='24' rx='3' fill='%23fff'/%3E%3Ctext x='12' y='17' font-size='14' text-anchor='middle'%3E🔵%3C/text%3E%3C/svg%3E") 12 12, auto; }
}

@keyframes ls-cursor-flash-danger {
  0%, 100% { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Ccircle cx='12' cy='12' r='10' fill='%23ef4444'/%3E%3Crect x='6' y='10' width='12' height='4' fill='white'/%3E%3C/svg%3E") 12 12, auto; }
  50% { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Ctext x='12' y='18' font-size='18' text-anchor='middle'%3E💩%3C/text%3E%3C/svg%3E") 12 12, auto; }
}

/* Link flash cursor classes */
a.ls-link-safe,
a.ls-link-safe * {
  animation: ls-cursor-flash-safe 0.8s ease-in-out infinite;
}

a.ls-link-suspicious,
a.ls-link-suspicious * {
  animation: ls-cursor-flash-suspicious 0.6s ease-in-out infinite;
}

a.ls-link-danger,
a.ls-link-danger * {
  animation: ls-cursor-flash-danger 0.4s ease-in-out infinite;
}

/* Threat Log Styles */
.ls-threat-log {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 300px;
  overflow-y: auto;
}

.ls-threat-log-item {
  padding: 12px;
  background: #fef2f2;
  border-radius: 8px;
  border-left: 4px solid #ef4444;
}

body.dark-mode .ls-threat-log-item {
  background: rgba(239, 68, 68, 0.15);
}

.ls-threat-log-item.ls-threat-suspicious {
  background: #fefce8;
  border-left-color: #f59e0b;
}

body.dark-mode .ls-threat-log-item.ls-threat-suspicious {
  background: rgba(245, 158, 11, 0.15);
}

.ls-threat-log-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.ls-threat-log-url {
  font-size: 11px;
  font-family: monospace;
  color: var(--text-color, #333);
  font-weight: 600;
  word-break: break-all;
  flex: 1;
}

body.dark-mode .ls-threat-log-url {
  color: var(--text-color, #e5e7eb);
}

.ls-threat-log-time {
  font-size: 10px;
  color: #666;
  flex-shrink: 0;
  margin-left: 8px;
}

body.dark-mode .ls-threat-log-time {
  color: #9ca3af;
}

.ls-threat-log-reason {
  font-size: 10px;
  color: #ef4444;
  margin-top: 4px;
}

/* ============================================
   ADDRESS ID (Product 5) STYLES
   ============================================ */

.aid-panel-container {
  padding: 16px;
  max-width: 600px;
  margin: 0 auto;
}

/* Section Styles */
.aid-section {
  background: #fff;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
  border: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .aid-section {
  background: #1f2937;
  border-color: var(--border-color, #374151);
}

.aid-section-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .aid-section-header {
  border-color: var(--border-color, #374151);
}

.aid-section-icon {
  font-size: 18px;
}

.aid-section-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-color, #333);
  flex: 1;
}

body.dark-mode .aid-section-title {
  color: var(--text-color, #e5e7eb);
}

.aid-add-btn {
  background: #22c55e;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease;
}

.aid-add-btn:hover {
  background: #16a34a;
}

/* Compare Form */
.aid-compare-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

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

.aid-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-color, #666);
}

body.dark-mode .aid-label {
  color: var(--text-color, #9ca3af);
}

.aid-input-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.aid-input {
  flex: 1;
  padding: 10px 12px;
  border: 1px solid var(--border-color, #e5e7eb);
  border-radius: 8px;
  font-size: 13px;
  font-family: monospace;
  background: #f9fafb;
  color: var(--text-color, #333);
}

body.dark-mode .aid-input {
  background: #374151;
  border-color: var(--border-color, #4b5563);
  color: var(--text-color, #e5e7eb);
}

.aid-input:focus {
  outline: none;
  border-color: #3b82f6;
}

.aid-paste-btn {
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-color, #e5e7eb);
  border-radius: 8px;
  background: #f9fafb;
  cursor: pointer;
  font-size: 16px;
  transition: background 0.2s ease;
}

body.dark-mode .aid-paste-btn {
  background: #374151;
  border-color: var(--border-color, #4b5563);
}

.aid-paste-btn:hover {
  background: #e5e7eb;
}

body.dark-mode .aid-paste-btn:hover {
  background: #4b5563;
}

.aid-select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border-color, #e5e7eb);
  border-radius: 8px;
  font-size: 13px;
  background: #f9fafb;
  color: var(--text-color, #333);
  cursor: pointer;
}

body.dark-mode .aid-select {
  background: #374151;
  border-color: var(--border-color, #4b5563);
  color: var(--text-color, #e5e7eb);
}

.aid-compare-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  margin-top: 8px;
}

.aid-compare-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.aid-compare-btn:active {
  transform: translateY(0);
}

/* Compare Result */
.aid-compare-result {
  margin-top: 16px;
  border-radius: 8px;
  overflow: hidden;
}

.aid-result-match {
  background: linear-gradient(135deg, #dcfce7, #bbf7d0);
  border: 1px solid #22c55e;
  padding: 16px;
  border-radius: 8px;
}

.aid-result-mismatch {
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border: 2px solid #ef4444;
  padding: 16px;
  border-radius: 8px;
}

body.dark-mode .aid-result-match {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(22, 163, 74, 0.2));
}

body.dark-mode .aid-result-mismatch {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(220, 38, 38, 0.2));
}

.aid-result-error {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fef3c7;
  border: 1px solid #f59e0b;
  padding: 12px;
  border-radius: 8px;
  color: #92400e;
  font-size: 13px;
}

body.dark-mode .aid-result-error {
  background: rgba(245, 158, 11, 0.2);
  color: #fcd34d;
}

.aid-result-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.aid-result-icon {
  font-size: 24px;
}

.aid-result-title {
  font-size: 16px;
  font-weight: 700;
  color: #333;
}

body.dark-mode .aid-result-title {
  color: #e5e7eb;
}

.aid-result-warning {
  font-size: 14px;
  font-weight: 600;
  color: #dc2626;
  margin-bottom: 12px;
}

.aid-result-success {
  font-size: 14px;
  color: #166534;
}

body.dark-mode .aid-result-success {
  color: #86efac;
}

/* Diff Display */
.aid-diff-container {
  background: rgba(0, 0, 0, 0.05);
  border-radius: 8px;
  padding: 12px;
  overflow-x: auto;
}

body.dark-mode .aid-diff-container {
  background: rgba(0, 0, 0, 0.3);
}

.aid-diff-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 8px;
}

.aid-diff-row:last-child {
  margin-bottom: 0;
}

.aid-diff-label {
  font-size: 11px;
  font-weight: 600;
  color: #666;
  min-width: 60px;
  padding-top: 2px;
}

body.dark-mode .aid-diff-label {
  color: #9ca3af;
}

.aid-diff-chars {
  display: flex;
  flex-wrap: wrap;
  gap: 1px;
  font-family: monospace;
  font-size: 12px;
}

.aid-diff-char {
  padding: 2px 3px;
  border-radius: 2px;
}

.aid-char-match {
  background: rgba(34, 197, 94, 0.2);
  color: #166534;
}

.aid-char-diff {
  background: #ef4444;
  color: white;
  font-weight: 700;
}

body.dark-mode .aid-char-match {
  color: #86efac;
}

/* Saved Addresses List */
.aid-saved-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.aid-saved-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: #f9fafb;
  border-radius: 8px;
  border: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .aid-saved-item {
  background: #374151;
  border-color: var(--border-color, #4b5563);
}

.aid-saved-icon {
  font-size: 24px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e5e7eb;
  border-radius: 8px;
}

body.dark-mode .aid-saved-icon {
  background: #4b5563;
}

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

.aid-saved-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-color, #333);
  margin-bottom: 2px;
}

body.dark-mode .aid-saved-label {
  color: var(--text-color, #e5e7eb);
}

.aid-saved-address {
  font-size: 11px;
  font-family: monospace;
  color: #666;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.dark-mode .aid-saved-address {
  color: #9ca3af;
}

.aid-saved-chain {
  font-size: 10px;
  color: #3b82f6;
  font-weight: 500;
  margin-top: 2px;
}

.aid-saved-actions {
  display: flex;
  gap: 8px;
}

.aid-copy-btn,
.aid-delete-btn {
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: background 0.2s ease;
}

.aid-copy-btn {
  background: #e5e7eb;
}

body.dark-mode .aid-copy-btn {
  background: #4b5563;
}

.aid-copy-btn:hover {
  background: #d1d5db;
}

body.dark-mode .aid-copy-btn:hover {
  background: #6b7280;
}

.aid-delete-btn {
  background: #fee2e2;
  color: #ef4444;
}

.aid-delete-btn:hover {
  background: #fecaca;
}

/* Empty State */
.aid-empty-state {
  text-align: center;
  padding: 24px;
}

.aid-empty-icon {
  font-size: 48px;
  opacity: 0.5;
  margin-bottom: 12px;
}

.aid-empty-text {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-color, #666);
  margin-bottom: 4px;
}

body.dark-mode .aid-empty-text {
  color: var(--text-color, #9ca3af);
}

.aid-empty-hint {
  font-size: 12px;
  color: #9ca3af;
}

/* Stats Section */
.aid-stats-section {
  padding: 12px;
}

.aid-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.aid-stat-box {
  text-align: center;
  padding: 16px 8px;
  background: #f9fafb;
  border-radius: 8px;
}

body.dark-mode .aid-stat-box {
  background: #374151;
}

.aid-stat-value {
  font-size: 24px;
  font-weight: 700;
  color: #3b82f6;
  margin-bottom: 4px;
}

.aid-stat-value.aid-stat-danger {
  color: #ef4444;
}

.aid-stat-label {
  font-size: 11px;
  color: #666;
  font-weight: 500;
}

body.dark-mode .aid-stat-label {
  color: #9ca3af;
}

/* Modal Styles */
.aid-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 20px;
}

.aid-modal-overlay.active {
  display: flex;
}

.aid-modal {
  background: white;
  border-radius: 16px;
  max-width: 400px;
  width: 100%;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  overflow: hidden;
}

body.dark-mode .aid-modal {
  background: #1f2937;
}

.aid-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color, #e5e7eb);
}

body.dark-mode .aid-modal-header {
  border-color: var(--border-color, #374151);
}

.aid-modal-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-color, #333);
}

body.dark-mode .aid-modal-title {
  color: var(--text-color, #e5e7eb);
}

.aid-modal-close {
  background: none;
  border: none;
  font-size: 24px;
  color: #666;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition: background 0.2s ease;
}

.aid-modal-close:hover {
  background: #f3f4f6;
}

body.dark-mode .aid-modal-close {
  color: #9ca3af;
}

body.dark-mode .aid-modal-close:hover {
  background: #374151;
}

.aid-modal-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.aid-modal-footer {
  display: flex;
  gap: 12px;
  padding: 16px 20px;
  border-top: 1px solid var(--border-color, #e5e7eb);
  justify-content: flex-end;
}

body.dark-mode .aid-modal-footer {
  border-color: var(--border-color, #374151);
}

.aid-modal-btn {
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease;
}

.aid-modal-btn-secondary {
  background: #f3f4f6;
  border: 1px solid var(--border-color, #e5e7eb);
  color: var(--text-color, #333);
}

body.dark-mode .aid-modal-btn-secondary {
  background: #374151;
  border-color: var(--border-color, #4b5563);
  color: var(--text-color, #e5e7eb);
}

.aid-modal-btn-secondary:hover {
  background: #e5e7eb;
}

body.dark-mode .aid-modal-btn-secondary:hover {
  background: #4b5563;
}

.aid-modal-btn-primary {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border: none;
  color: white;
}

.aid-modal-btn-primary:hover {
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.ls-threat-suspicious .ls-threat-log-reason {
  color: #f59e0b;
}
