/**
 * v2Onboarding.css - Styles for onboarding, tours, tooltips, and helper UI
 */

/* ==========================================================================
   EMPTY STATE
   ========================================================================== */

.v2-empty-state-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 500px;
  padding: var(--v2-spacing-xl, 32px);
}

.v2-empty-state-card {
  max-width: 600px;
  text-align: center;
  padding: var(--v2-spacing-xxl, 48px);
  background: var(--v2-bg-card, #ffffff);
  border-radius: var(--v2-border-radius-xl, 16px);
  border: 1px solid var(--v2-border-color, #e5e7eb);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

.v2-empty-state-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--v2-spacing-lg, 24px);
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: white;
}

.v2-empty-state-card h2 {
  margin: 0 0 var(--v2-spacing-md, 16px);
  font-size: 24px;
  font-weight: 700;
  color: var(--v2-text-primary, #111827);
}

.v2-empty-state-description {
  margin: 0 0 var(--v2-spacing-xl, 32px);
  font-size: 15px;
  color: var(--v2-text-secondary, #6b7280);
  line-height: 1.6;
}

.v2-empty-state-actions {
  display: flex;
  gap: var(--v2-spacing-md, 16px);
  justify-content: center;
  margin-bottom: var(--v2-spacing-xl, 32px);
}

.v2-empty-state-features {
  text-align: left;
  padding: var(--v2-spacing-lg, 24px);
  background: var(--v2-bg-page, #f9fafb);
  border-radius: var(--v2-border-radius, 8px);
  margin-bottom: var(--v2-spacing-lg, 24px);
}

.v2-empty-state-features h4 {
  margin: 0 0 var(--v2-spacing-md, 16px);
  font-size: 14px;
  font-weight: 600;
  color: var(--v2-text-primary, #111827);
}

.v2-empty-state-features ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.v2-empty-state-features li {
  display: flex;
  align-items: center;
  gap: var(--v2-spacing-sm, 8px);
  padding: var(--v2-spacing-xs, 4px) 0;
  font-size: 14px;
  color: var(--v2-text-secondary, #6b7280);
}

.v2-empty-state-features li i {
  color: #10b981;
  font-size: 12px;
}

.v2-empty-state-sample {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--v2-spacing-sm, 8px);
  color: var(--v2-text-muted, #9ca3af);
  font-size: 13px;
}

/* ==========================================================================
   COACHMARKS TOUR
   ========================================================================== */

.v2-coachmarks-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100000;
  pointer-events: none;
}

.v2-coachmarks-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  pointer-events: auto;
}

.v2-coachmarks-highlight {
  position: absolute;
  border: 3px solid #3b82f6;
  border-radius: 8px;
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5);
  pointer-events: none;
  transition: all 0.3s ease;
}

.v2-coachmarks-tooltip {
  position: absolute;
  width: 340px;
  background: white;
  border-radius: var(--v2-border-radius-lg, 12px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  padding: var(--v2-spacing-lg, 24px);
  pointer-events: auto;
  z-index: 1;
}

.v2-coachmarks-tooltip::before {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  background: white;
  transform: rotate(45deg);
}

.v2-coachmarks-tooltip.arrow-top::before {
  bottom: -8px;
  left: 50%;
  margin-left: -8px;
  box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.1);
}

.v2-coachmarks-tooltip.arrow-bottom::before {
  top: -8px;
  left: 50%;
  margin-left: -8px;
  box-shadow: -4px -4px 8px rgba(0, 0, 0, 0.1);
}

.v2-coachmarks-tooltip.arrow-left::before {
  right: -8px;
  top: 50%;
  margin-top: -8px;
  box-shadow: 4px -4px 8px rgba(0, 0, 0, 0.1);
}

.v2-coachmarks-tooltip.arrow-right::before {
  left: -8px;
  top: 50%;
  margin-top: -8px;
  box-shadow: -4px 4px 8px rgba(0, 0, 0, 0.1);
}

.v2-coachmarks-tooltip-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--v2-spacing-md, 16px);
}

.v2-coachmarks-step-indicator {
  font-size: 12px;
  font-weight: 500;
  color: var(--v2-text-muted, #9ca3af);
}

.v2-coachmarks-close {
  background: none;
  border: none;
  font-size: 16px;
  color: var(--v2-text-muted, #9ca3af);
  cursor: pointer;
  padding: 4px;
}

.v2-coachmarks-close:hover {
  color: var(--v2-text-primary, #111827);
}

.v2-coachmarks-title {
  margin: 0 0 var(--v2-spacing-sm, 8px);
  font-size: 16px;
  font-weight: 600;
  color: var(--v2-text-primary, #111827);
}

.v2-coachmarks-content {
  margin: 0 0 var(--v2-spacing-lg, 24px);
  font-size: 14px;
  color: var(--v2-text-secondary, #6b7280);
  line-height: 1.6;
}

.v2-coachmarks-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--v2-spacing-md, 16px);
}

.v2-coachmarks-skip {
  font-size: 13px;
}

.v2-coachmarks-nav {
  display: flex;
  gap: var(--v2-spacing-sm, 8px);
}

.v2-coachmarks-dont-show {
  display: flex;
  align-items: center;
  gap: var(--v2-spacing-xs, 4px);
  font-size: 12px;
  color: var(--v2-text-muted, #9ca3af);
  cursor: pointer;
}

.v2-coachmarks-dont-show input {
  margin: 0;
}

/* ==========================================================================
   HELP DRAWER
   ========================================================================== */

.v2-help-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  z-index: 100000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.v2-help-drawer.open {
  opacity: 1;
  visibility: visible;
}

.v2-help-drawer-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.3);
}

.v2-help-drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 360px;
  background: var(--v2-bg-card, #ffffff);
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s ease;
}

.v2-help-drawer.open .v2-help-drawer-panel {
  transform: translateX(0);
}

.v2-help-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--v2-spacing-lg, 24px);
  border-bottom: 1px solid var(--v2-border-color, #e5e7eb);
}

.v2-help-drawer-title {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: var(--v2-text-primary, #111827);
}

.v2-help-drawer-close {
  background: none;
  border: none;
  font-size: 18px;
  color: var(--v2-text-muted, #9ca3af);
  cursor: pointer;
  padding: 4px;
}

.v2-help-drawer-close:hover {
  color: var(--v2-text-primary, #111827);
}

.v2-help-drawer-content {
  flex: 1;
  overflow-y: auto;
  padding: var(--v2-spacing-lg, 24px);
}

.v2-help-section {
  margin-bottom: var(--v2-spacing-xl, 32px);
}

.v2-help-section h4 {
  display: flex;
  align-items: center;
  gap: var(--v2-spacing-sm, 8px);
  margin: 0 0 var(--v2-spacing-md, 16px);
  font-size: 14px;
  font-weight: 600;
  color: var(--v2-text-primary, #111827);
}

.v2-help-section h4 i {
  color: var(--v2-primary, #3b82f6);
}

.v2-help-section p {
  margin: 0 0 var(--v2-spacing-sm, 8px);
  font-size: 13px;
  color: var(--v2-text-secondary, #6b7280);
  line-height: 1.6;
}

.v2-help-list {
  margin: 0;
  padding-left: var(--v2-spacing-lg, 24px);
  font-size: 13px;
  color: var(--v2-text-secondary, #6b7280);
  line-height: 1.8;
}

.v2-help-list li {
  margin-bottom: var(--v2-spacing-xs, 4px);
}

.v2-help-shortcuts {
  list-style: none;
  margin: 0;
  padding: 0;
}

.v2-help-shortcuts li {
  display: flex;
  align-items: center;
  gap: var(--v2-spacing-sm, 8px);
  padding: var(--v2-spacing-xs, 4px) 0;
  font-size: 13px;
  color: var(--v2-text-secondary, #6b7280);
}

.v2-help-shortcuts kbd {
  display: inline-block;
  padding: 2px 6px;
  font-family: monospace;
  font-size: 12px;
  background: var(--v2-bg-page, #f9fafb);
  border: 1px solid var(--v2-border-color, #e5e7eb);
  border-radius: 4px;
  color: var(--v2-text-primary, #111827);
}

.v2-help-drawer-actions {
  display: flex;
  flex-direction: column;
  gap: var(--v2-spacing-sm, 8px);
  padding: var(--v2-spacing-lg, 24px);
  border-top: 1px solid var(--v2-border-color, #e5e7eb);
}

.v2-help-action {
  width: 100%;
  justify-content: center;
}

.v2-help-drawer-footer {
  padding: var(--v2-spacing-md, 16px) var(--v2-spacing-lg, 24px);
  border-top: 1px solid var(--v2-border-color, #e5e7eb);
}

.v2-keyboard-tips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--v2-spacing-md, 16px);
}

.v2-keyboard-tip {
  display: flex;
  align-items: center;
  gap: var(--v2-spacing-xs, 4px);
  font-size: 12px;
  color: var(--v2-text-muted, #9ca3af);
}

.v2-keyboard-tip kbd {
  display: inline-block;
  padding: 2px 6px;
  font-family: monospace;
  font-size: 11px;
  background: var(--v2-bg-page, #f9fafb);
  border: 1px solid var(--v2-border-color, #e5e7eb);
  border-radius: 3px;
}

/* ==========================================================================
   CONFIRM MODAL
   ========================================================================== */

.v2-confirm-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100001;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.v2-confirm-modal.open {
  opacity: 1;
}

.v2-confirm-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
}

.v2-confirm-dialog {
  position: relative;
  z-index: 1;
  width: 90%;
  max-width: 400px;
  background: var(--v2-bg-card, #ffffff);
  border-radius: var(--v2-border-radius-lg, 12px);
  padding: var(--v2-spacing-xl, 32px);
  text-align: center;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  transform: scale(0.95);
  transition: transform 0.2s ease;
}

.v2-confirm-modal.open .v2-confirm-dialog {
  transform: scale(1);
}

.v2-confirm-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto var(--v2-spacing-lg, 24px);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}

.v2-confirm-info .v2-confirm-icon {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
}

.v2-confirm-warning .v2-confirm-icon {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
}

.v2-confirm-danger .v2-confirm-icon {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
}

.v2-confirm-title {
  margin: 0 0 var(--v2-spacing-sm, 8px);
  font-size: 18px;
  font-weight: 600;
  color: var(--v2-text-primary, #111827);
}

.v2-confirm-message {
  margin: 0 0 var(--v2-spacing-xl, 32px);
  font-size: 14px;
  color: var(--v2-text-secondary, #6b7280);
  line-height: 1.6;
}

.v2-confirm-actions {
  display: flex;
  gap: var(--v2-spacing-md, 16px);
  justify-content: center;
}

.v2-btn-danger {
  background: #ef4444 !important;
  border-color: #ef4444 !important;
}

.v2-btn-danger:hover {
  background: #dc2626 !important;
  border-color: #dc2626 !important;
}

/* ==========================================================================
   TOOLTIP
   ========================================================================== */

.v2-tooltip {
  position: absolute;
  z-index: 100002;
  max-width: 280px;
  padding: var(--v2-spacing-sm, 8px) var(--v2-spacing-md, 16px);
  background: #1f2937;
  color: white;
  font-size: 13px;
  line-height: 1.5;
  border-radius: var(--v2-border-radius, 8px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  display: none;
  pointer-events: none;
}

.v2-tooltip.visible {
  opacity: 1;
  transform: translateY(0);
}

.v2-tooltip::before {
  content: '';
  position: absolute;
  width: 8px;
  height: 8px;
  background: #1f2937;
  transform: rotate(45deg);
}

.v2-tooltip-top::before {
  bottom: -4px;
  left: 50%;
  margin-left: -4px;
}

.v2-tooltip-bottom::before {
  top: -4px;
  left: 50%;
  margin-left: -4px;
}

.v2-tooltip-left::before {
  right: -4px;
  top: 50%;
  margin-top: -4px;
}

.v2-tooltip-right::before {
  left: -4px;
  top: 50%;
  margin-top: -4px;
}

/* Inline help icon */
.v2-inline-help {
  display: inline-flex;
  align-items: center;
  margin-left: var(--v2-spacing-xs, 4px);
  color: var(--v2-text-muted, #9ca3af);
  cursor: help;
}

.v2-inline-help:hover {
  color: var(--v2-primary, #3b82f6);
}

/* ==========================================================================
   TOAST NOTIFICATIONS
   ========================================================================== */

.v2-toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  align-items: center;
  gap: var(--v2-spacing-sm, 8px);
  padding: var(--v2-spacing-md, 16px) var(--v2-spacing-lg, 24px);
  background: #1f2937;
  color: white;
  border-radius: var(--v2-border-radius, 8px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  font-size: 14px;
  font-weight: 500;
  z-index: 100003;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.v2-toast.show {
  opacity: 1;
  transform: translateY(0);
}

.v2-toast-success {
  background: #10b981;
}

.v2-toast-error {
  background: #ef4444;
}

.v2-toast-warning {
  background: #f59e0b;
}

.v2-toast-info {
  background: #3b82f6;
}

/* ==========================================================================
   DARK THEME
   ========================================================================== */

.dark-theme .v2-empty-state-card {
  background: var(--v2-bg-surface, #111520) !important;
  border-color: var(--v2-border, #1e2433) !important;
}

.dark-theme .v2-empty-state-card h2 {
  color: var(--v2-text-primary, #e6e9f0) !important;
}

.dark-theme .v2-empty-state-description {
  color: var(--v2-text-secondary, #a3a8b8) !important;
}

.dark-theme .v2-empty-state-features {
  background: #0c111a !important;
}

.dark-theme .v2-empty-state-features h4 {
  color: var(--v2-text-primary, #e6e9f0) !important;
}

.dark-theme .v2-empty-state-features li {
  color: var(--v2-text-secondary, #a3a8b8) !important;
}

.dark-theme .v2-coachmarks-tooltip,
.dark-theme .v2-coachmarks-tooltip::before {
  background: #1f2937 !important;
}

.dark-theme .v2-coachmarks-title {
  color: #f3f4f6 !important;
}

.dark-theme .v2-coachmarks-content {
  color: #d1d5db !important;
}

.dark-theme .v2-help-drawer-panel {
  background: #111520 !important;
}

.dark-theme .v2-help-drawer-header,
.dark-theme .v2-help-drawer-actions,
.dark-theme .v2-help-drawer-footer {
  border-color: var(--v2-border, #1e2433) !important;
}

.dark-theme .v2-help-drawer-title,
.dark-theme .v2-help-section h4 {
  color: var(--v2-text-primary, #e6e9f0) !important;
}

.dark-theme .v2-help-section p,
.dark-theme .v2-help-list,
.dark-theme .v2-help-shortcuts li {
  color: var(--v2-text-secondary, #a3a8b8) !important;
}

.dark-theme .v2-help-shortcuts kbd,
.dark-theme .v2-keyboard-tip kbd {
  background: #0c111a !important;
  border-color: var(--v2-border, #1e2433) !important;
  color: var(--v2-text-primary, #e6e9f0) !important;
}

.dark-theme .v2-confirm-dialog {
  background: #111520 !important;
}

.dark-theme .v2-confirm-title {
  color: var(--v2-text-primary, #e6e9f0) !important;
}

.dark-theme .v2-confirm-message {
  color: var(--v2-text-secondary, #a3a8b8) !important;
}

.dark-theme .v2-tooltip {
  background: #374151 !important;
}

.dark-theme .v2-tooltip::before {
  background: #374151 !important;
}
