/* Anonymous Viewer Banner Styles - Compact unified sign-in box (~33% smaller) */

.anonymous-viewer-banner {
  position: fixed;
  top: 56px;
  right: 10px;
  z-index: 100000;

  max-width: 200px;
  width: auto;

  background: linear-gradient(135deg, #1e1e2e 0%, #2d2d44 100%);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 8px;
  box-shadow:
    0 4px 16px rgba(0, 0, 0, 0.2),
    0 0 10px rgba(139, 92, 246, 0.08);

  animation: slideDown 0.25s ease-out;
}

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

.anonymous-viewer-banner.edit-triggered {
  background: linear-gradient(135deg, #2d1f3d 0%, #3d2d54 100%);
  border-color: rgba(236, 72, 153, 0.4);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.25),
    0 0 20px rgba(236, 72, 153, 0.15);
}

.banner-content {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px;
  padding-top: 8px;
}

.banner-header {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.banner-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: linear-gradient(135deg, #8b5cf6 0%, #6366f1 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.banner-icon svg {
  width: 14px;
  height: 14px;
}

.edit-triggered .banner-icon {
  background: linear-gradient(135deg, #ec4899 0%, #a855f7 100%);
}

.banner-text {
  flex: 1;
  min-width: 0;
}

.banner-headline {
  margin: 0 0 2px 0;
  font-size: 11px;
  color: #f0f0f0;
  line-height: 1.3;
}

.banner-headline strong {
  color: white;
}

.banner-summary {
  margin: 0;
  font-size: 10px;
  color: #a0a0b0;
  line-height: 1.3;
}

.banner-actions {
  display: flex;
  flex-direction: row;
  gap: 6px;
  width: 100%;
}

.banner-signup-btn {
  flex: 1;
  padding: 5px 10px;
  font-size: 10px;
  font-weight: 600;
  color: white;
  background: linear-gradient(135deg, #8b5cf6 0%, #6366f1 100%);
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.banner-signup-btn:hover {
  background: linear-gradient(135deg, #7c3aed 0%, #4f46e5 100%);
  box-shadow: 0 2px 12px rgba(139, 92, 246, 0.35);
  transform: translateY(-1px);
}

.edit-triggered .banner-signup-btn {
  background: linear-gradient(135deg, #ec4899 0%, #a855f7 100%);
}

.edit-triggered .banner-signup-btn:hover {
  background: linear-gradient(135deg, #db2777 0%, #9333ea 100%);
  box-shadow: 0 2px 12px rgba(236, 72, 153, 0.35);
}

.banner-dismiss-btn {
  position: absolute;
  top: 4px;
  right: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  padding: 0;
  color: #808090;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 1;
}

.banner-dismiss-btn svg {
  width: 10px;
  height: 10px;
}

.banner-dismiss-btn:hover {
  color: #f0f0f0;
  background: rgba(255, 255, 255, 0.15);
}

.banner-edit-notice {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 5px 10px;
  background: rgba(236, 72, 153, 0.1);
  border-top: 1px solid rgba(236, 72, 153, 0.2);
  border-radius: 0 0 8px 8px;
  font-size: 9px;
  color: #f472b6;
}

/* Modal overlay for CryptID sign-up */
.anonymous-banner-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 10001;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  animation: fadeIn 0.2s ease-out;
}

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

.anonymous-banner-modal {
  max-width: 420px;
  width: calc(100% - 40px);
  max-height: calc(100vh - 80px);
  overflow-y: auto;
  background: #1e1e2e;
  border-radius: 16px;
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
  animation: scaleIn 0.3s ease-out;
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Dark mode is default, light mode adjustments */
@media (prefers-color-scheme: light) {
  .anonymous-viewer-banner {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-color: rgba(139, 92, 246, 0.2);
    box-shadow:
      0 8px 24px rgba(0, 0, 0, 0.08),
      0 0 16px rgba(139, 92, 246, 0.08);
  }

  .banner-headline {
    color: #2d2d44;
  }

  .banner-headline strong {
    color: #1e1e2e;
  }

  .banner-summary {
    color: #606080;
  }

  .banner-dismiss-btn {
    color: #606080;
    background: rgba(0, 0, 0, 0.05);
  }

  .banner-dismiss-btn:hover {
    color: #2d2d44;
    background: rgba(0, 0, 0, 0.1);
  }
}

/* Responsive adjustments */
@media (max-width: 640px) {
  .anonymous-viewer-banner {
    top: 56px;
    right: 8px;
    max-width: 180px;
  }

  .banner-content {
    padding: 8px;
  }

  .banner-icon {
    width: 20px;
    height: 20px;
  }

  .banner-icon svg {
    width: 12px;
    height: 12px;
  }

  .banner-headline {
    font-size: 10px;
  }

  .banner-summary {
    font-size: 9px;
  }
}
