/* ============================================================
   MediatorAI Simulation - Premium Walkthrough Stylesheet
   Apple-level polish on device mockups. Dark chrome, rich detail.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ============================================================
   CSS VARIABLES
   ============================================================ */
:root {
  /* Simulation-specific palette */
  --sim-bg: #0F0F14;
  --sim-surface: #FFFFFF;
  --sim-surface-alt: #F8FAFC;
  --sim-primary: #6366F1;
  --sim-primary-light: #818CF8;
  --sim-primary-dark: #4F46E5;
  --sim-accent: #10B981;
  --sim-accent-light: #34D399;
  --sim-text: #1E293B;
  --sim-text-secondary: #64748B;
  --sim-text-muted: #94A3B8;
  --sim-text-on-dark: #F1F5F9;
  --sim-border: #E2E8F0;

  /* Party colors */
  --sim-sarah: #8B5CF6;
  --sim-mike: #10B981;
  --sim-ai: #6366F1;

  /* Callout */
  --sim-callout-bg: #FEF3C7;
  --sim-callout-border: #F59E0B;
  --sim-callout-text: #92400E;

  /* Highlight */
  --sim-highlight: rgba(99, 102, 241, 0.1);

  /* Typography */
  --sim-font: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* Radii */
  --sim-radius-sm: 6px;
  --sim-radius-md: 8px;
  --sim-radius-lg: 12px;
  --sim-radius-xl: 16px;
  --sim-radius-2xl: 24px;
  --sim-radius-full: 9999px;

  /* Shadows */
  --sim-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --sim-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --sim-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --sim-shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
  --sim-shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

  /* Transitions */
  --sim-transition-fast: 150ms ease;
  --sim-transition-normal: 250ms ease;
  --sim-transition-slow: 400ms ease;
}


/* ============================================================
   BASE / BODY
   ============================================================ */
.sim-body {
  margin: 0;
  padding: 0;
  font-family: var(--sim-font);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  color: var(--sim-text);
  background: var(--sim-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.sim-body *,
.sim-body *::before,
.sim-body *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}


/* ============================================================
   HEADER
   ============================================================ */
.sim-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 56px;
  background: var(--sim-bg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
  z-index: 100;
}

.sim-back-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--sim-text-muted);
  text-decoration: none;
  transition: color var(--sim-transition-fast);
  white-space: nowrap;
}

.sim-back-link:hover {
  color: var(--sim-primary-light);
}

.sim-title {
  font-size: 16px;
  font-weight: 600;
  color: #FFFFFF;
  letter-spacing: -0.01em;
}

.sim-step-counter {
  font-size: 13px;
  font-weight: 500;
  color: var(--sim-text-muted);
  white-space: nowrap;
}


/* ============================================================
   PERSPECTIVE TABS
   ============================================================ */
.sim-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--sim-bg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
  z-index: 90;
}

.sim-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  font-family: var(--sim-font);
  font-size: 14px;
  font-weight: 500;
  color: var(--sim-text-muted);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--sim-radius-full);
  cursor: pointer;
  transition: all var(--sim-transition-normal);
  position: relative;
  white-space: nowrap;
}

.sim-tab:hover {
  color: var(--sim-text-on-dark);
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
}

.sim-tab.active {
  background: var(--sim-primary);
  color: #FFFFFF;
  border-color: var(--sim-primary);
  box-shadow: 0 2px 12px rgba(99, 102, 241, 0.35);
}

/* Tab avatar icon circles */
.sim-tab-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-size: 11px;
  font-weight: 700;
  color: #FFFFFF;
  flex-shrink: 0;
}

.sim-tab-sarah {
  background: var(--sim-sarah);
}

.sim-tab-mike {
  background: var(--sim-mike);
}

.sim-tab-ai {
  background: linear-gradient(135deg, var(--sim-ai), var(--sim-primary-dark));
}

.sim-tab.active .sim-tab-icon {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}

/* Tab badge notification */
.sim-tab-badge {
  display: none;
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  font-size: 11px;
  font-weight: 700;
  color: #FFFFFF;
  border-radius: var(--sim-radius-full);
  line-height: 18px;
  text-align: center;
  animation: badgeBounce 0.3s ease-out;
}

.sim-tab-badge.visible {
  display: block;
}

.sim-tab[data-perspective="sarah"] .sim-tab-badge {
  background: var(--sim-sarah);
}

.sim-tab[data-perspective="mike"] .sim-tab-badge {
  background: var(--sim-mike);
}

.sim-tab[data-perspective="ai"] .sim-tab-badge {
  background: var(--sim-ai);
}


/* ============================================================
   MAIN CONTENT AREA
   ============================================================ */
.sim-content {
  flex: 1;
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  padding-bottom: 100px; /* space for callout */
}

.sim-perspective {
  display: none;
  width: 100%;
  height: 100%;
  animation: simFadeIn 0.35s ease-out;
}

.sim-perspective.active {
  display: flex;
  align-items: center;
  justify-content: center;
}


/* ============================================================
   EMAIL CLIENT (Sarah's Perspective)
   ============================================================ */
.sim-device-email {
  display: flex;
  width: 100%;
  max-width: 960px;
  height: 100%;
  max-height: 560px;
  border-radius: var(--sim-radius-lg);
  overflow: hidden;
  box-shadow: var(--sim-shadow-2xl);
  border: 1px solid var(--sim-border);
}

/* -- Email Sidebar -- */
.sim-email-sidebar {
  width: 240px;
  min-width: 240px;
  background: #1E293B;
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
}

.sim-email-sidebar-header {
  padding: 16px 20px;
  font-size: 15px;
  font-weight: 700;
  color: #FFFFFF;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  letter-spacing: -0.01em;
}

.sim-email-list {
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.1) transparent;
}

.sim-email-list::-webkit-scrollbar {
  width: 4px;
}

.sim-email-list::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
}

/* Email list item */
.sim-email-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 20px;
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  transition: background var(--sim-transition-fast);
  position: relative;
  animation: emailSlideIn 0.3s ease-out;
}

.sim-email-item:hover {
  background: rgba(255, 255, 255, 0.04);
}

.sim-email-item.active {
  background: #2D3748;
}

.sim-email-item-unread {
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #3B82F6;
  animation: unreadPulse 2s ease-in-out infinite;
}

.sim-email-item-avatar {
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--sim-ai), var(--sim-primary-dark));
  color: #FFFFFF;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sim-email-item-content {
  flex: 1;
  min-width: 0;
}

.sim-email-item-subject {
  font-size: 13px;
  font-weight: 600;
  color: #FFFFFF;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.sim-email-item-preview {
  font-size: 12px;
  color: var(--sim-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sim-email-item-date {
  font-size: 11px;
  color: var(--sim-text-muted);
  white-space: nowrap;
  flex-shrink: 0;
}

/* -- Email Main (Reading Pane) -- */
.sim-email-main {
  flex: 1;
  background: var(--sim-surface);
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.sim-email-empty {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  color: var(--sim-text-muted);
}

.sim-email-view {
  flex: 1;
  display: flex;
  flex-direction: column;
  animation: simFadeIn 0.25s ease-out;
}

.sim-email-view-header {
  padding: 24px 28px 16px;
  border-bottom: 1px solid var(--sim-border);
}

.sim-email-subject {
  font-size: 18px;
  font-weight: 600;
  color: var(--sim-text);
  line-height: 1.3;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.sim-email-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.sim-email-from {
  font-size: 14px;
  font-weight: 500;
  color: var(--sim-text);
}

.sim-email-date {
  font-size: 13px;
  color: var(--sim-text-muted);
}

.sim-email-body {
  flex: 1;
  padding: 24px 28px;
  overflow-y: auto;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.7;
  color: var(--sim-text);
  scrollbar-width: thin;
  scrollbar-color: var(--sim-border) transparent;
}

.sim-email-body::-webkit-scrollbar {
  width: 4px;
}

.sim-email-body::-webkit-scrollbar-thumb {
  background: var(--sim-border);
  border-radius: 2px;
}

.sim-email-body p {
  margin-bottom: 12px;
}

.sim-email-body p:last-child {
  margin-bottom: 0;
}

/* Reply bar */
.sim-email-reply-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  background: var(--sim-surface-alt);
  border-top: 1px solid var(--sim-border);
  flex-shrink: 0;
}

.sim-email-reply-input {
  flex: 1;
  min-height: 36px;
  padding: 8px 14px;
  font-family: var(--sim-font);
  font-size: 14px;
  color: var(--sim-text);
  background: var(--sim-surface);
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  line-height: 1.4;
  white-space: pre-wrap;
  word-wrap: break-word;
  overflow-y: auto;
  max-height: 80px;
}

.sim-email-reply-input:empty::before {
  content: 'Reply...';
  color: var(--sim-text-muted);
}

.sim-email-send-btn {
  padding: 8px 20px;
  font-family: var(--sim-font);
  font-size: 14px;
  font-weight: 600;
  color: #FFFFFF;
  background: var(--sim-primary);
  border: none;
  border-radius: var(--sim-radius-md);
  cursor: pointer;
  transition: all var(--sim-transition-fast);
  white-space: nowrap;
  flex-shrink: 0;
}

.sim-email-send-btn:hover {
  background: var(--sim-primary-dark);
}

.sim-email-send-btn.sending {
  opacity: 0.7;
  pointer-events: none;
}


/* ============================================================
   PHONE / SMS (Mike's Perspective)
   ============================================================ */
.sim-device-phone {
  display: flex;
  align-items: center;
  justify-content: center;
}

.sim-phone-frame {
  width: 375px;
  height: 700px;
  background: #000000;
  border: 3px solid #1C1C1E;
  border-radius: 40px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.06),
    var(--sim-shadow-2xl),
    0 0 80px rgba(0, 0, 0, 0.5);
  position: relative;
}

/* Notch */
.sim-phone-notch {
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 28px;
  background: #000000;
  border-radius: 0 0 18px 18px;
  z-index: 10;
}

/* Status bar */
.sim-phone-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px 8px;
  background: #F2F2F7;
  flex-shrink: 0;
  position: relative;
  z-index: 5;
}

.sim-phone-time {
  font-size: 15px;
  font-weight: 600;
  color: #000000;
  letter-spacing: 0.01em;
}

.sim-phone-indicators {
  display: flex;
  align-items: center;
  gap: 6px;
}

.sim-phone-signal {
  display: flex;
  gap: 1.5px;
  align-items: flex-end;
  height: 12px;
}

.sim-phone-signal::before {
  content: '';
  display: block;
  width: 3px;
  height: 4px;
  background: #000000;
  border-radius: 1px;
}

.sim-phone-signal::after {
  content: '';
  display: block;
  width: 3px;
  height: 7px;
  background: #000000;
  border-radius: 1px;
  box-shadow: 4.5px 0 0 0 #000000, 9px -3px 0 0 #000000, 13.5px -6px 0 0 #000000;
}

.sim-phone-wifi {
  width: 15px;
  height: 11px;
  position: relative;
}

.sim-phone-wifi::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 3px;
  height: 3px;
  background: #000000;
  border-radius: 50%;
}

.sim-phone-wifi::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 9px;
  height: 9px;
  border: 2px solid #000000;
  border-radius: 50%;
  clip-path: polygon(50% 100%, 0 30%, 100% 30%);
}

.sim-phone-battery {
  width: 24px;
  height: 11px;
  border: 1.5px solid #000000;
  border-radius: 2.5px;
  position: relative;
}

.sim-phone-battery::before {
  content: '';
  position: absolute;
  right: -4px;
  top: 50%;
  transform: translateY(-50%);
  width: 2px;
  height: 5px;
  background: #000000;
  border-radius: 0 1px 1px 0;
}

.sim-phone-battery::after {
  content: '';
  position: absolute;
  left: 1.5px;
  top: 1.5px;
  bottom: 1.5px;
  width: 65%;
  background: #000000;
  border-radius: 1px;
}

/* Navigation bar */
.sim-phone-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: #F2F2F7;
  border-bottom: 1px solid #D1D1D6;
  flex-shrink: 0;
}

.sim-phone-back-arrow {
  font-size: 20px;
  font-weight: 300;
  color: #007AFF;
  width: 32px;
}

.sim-phone-contact {
  font-size: 16px;
  font-weight: 600;
  color: #000000;
  letter-spacing: -0.01em;
}

.sim-phone-info-icon {
  width: 24px;
  height: 24px;
  border: 2px solid #007AFF;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  color: #007AFF;
  font-style: italic;
}

/* Messages area */
.sim-phone-messages {
  flex: 1;
  padding: 16px;
  background: #F2F2F7;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  scrollbar-width: none;
}

.sim-phone-messages::-webkit-scrollbar {
  display: none;
}

/* SMS Bubbles */
.sim-sms-bubble {
  padding: 10px 14px;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.45;
  max-width: 75%;
  word-wrap: break-word;
  animation: smsBubbleIn 0.2s ease-out;
}

.sim-sms-incoming {
  background: #E5E5EA;
  color: #000000;
  border-radius: 18px 18px 18px 6px;
  align-self: flex-start;
}

.sim-sms-outgoing {
  background: #007AFF;
  color: #FFFFFF;
  border-radius: 18px 18px 6px 18px;
  align-self: flex-end;
}

/* Typing indicator */
.sim-typing-indicator {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #E5E5EA;
  padding: 12px 16px;
  border-radius: 18px 18px 18px 6px;
  align-self: flex-start;
  animation: simFadeIn 0.2s ease-out;
}

.sim-typing-dot {
  width: 7px;
  height: 7px;
  background: #8E8E93;
  border-radius: 50%;
  animation: typingDots 1.4s ease-in-out infinite;
}

.sim-typing-dot:nth-child(2) {
  animation-delay: 0.2s;
}

.sim-typing-dot:nth-child(3) {
  animation-delay: 0.4s;
}

/* Phone input bar */
.sim-phone-input-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: #F2F2F7;
  border-top: 1px solid #D1D1D6;
  flex-shrink: 0;
}

.sim-phone-text-input {
  flex: 1;
  min-height: 36px;
  padding: 8px 14px;
  font-family: var(--sim-font);
  font-size: 15px;
  color: #000000;
  background: #FFFFFF;
  border: 1px solid #D1D1D6;
  border-radius: 18px;
  line-height: 1.4;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.sim-phone-text-input:empty::before {
  content: 'iMessage';
  color: #8E8E93;
}

.sim-phone-send {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #007AFF;
  border: none;
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  transition: all var(--sim-transition-fast);
}

.sim-phone-send::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 52%;
  transform: translate(-50%, -50%) rotate(-45deg);
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-bottom: 10px solid #FFFFFF;
}

.sim-phone-send:hover {
  background: #0056D6;
}

/* Home indicator */
.sim-phone-home-indicator {
  padding: 8px 0 6px;
  background: #F2F2F7;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sim-phone-home-indicator::after {
  content: '';
  width: 134px;
  height: 5px;
  background: #000000;
  border-radius: 3px;
  opacity: 0.2;
}


/* ============================================================
   AI DASHBOARD
   ============================================================ */
.sim-device-dashboard {
  width: 100%;
  max-width: 960px;
  height: 100%;
  max-height: 560px;
  border-radius: var(--sim-radius-lg);
  overflow: hidden;
  box-shadow: var(--sim-shadow-2xl);
  border: 1px solid var(--sim-border);
  background: var(--sim-surface);
  display: flex;
  flex-direction: column;
}

/* Browser-style header bar */
.sim-dash-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  background: #F1F5F9;
  border-bottom: 1px solid var(--sim-border);
  flex-shrink: 0;
}

.sim-dash-header::before {
  content: '';
  display: flex;
  gap: 6px;
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #EF4444;
  box-shadow: 16px 0 0 #F59E0B, 32px 0 0 #22C55E;
}

.sim-dash-case-info {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: 40px;
}

.sim-dash-case-number {
  font-size: 13px;
  font-weight: 500;
  color: var(--sim-text-secondary);
}

.sim-dash-case-status {
  display: inline-block;
  padding: 2px 10px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--sim-radius-full);
  background: rgba(99, 102, 241, 0.1);
  color: var(--sim-primary);
}

.sim-dash-case-status.resolved {
  background: rgba(16, 185, 129, 0.1);
  color: var(--sim-accent);
}

/* Dashboard body: sidebar + main */
.sim-dash-body {
  display: flex;
  flex: 1;
  overflow: hidden;
}

/* -- Dashboard Sidebar -- */
.sim-dash-sidebar {
  width: 280px;
  min-width: 280px;
  background: var(--sim-surface-alt);
  border-right: 1px solid var(--sim-border);
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  scrollbar-width: thin;
  scrollbar-color: var(--sim-border) transparent;
}

.sim-dash-sidebar::-webkit-scrollbar {
  width: 4px;
}

.sim-dash-sidebar::-webkit-scrollbar-thumb {
  background: var(--sim-border);
  border-radius: 2px;
}

.sim-dash-sidebar h4 {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sim-text-muted);
  margin-bottom: 12px;
}

/* Parties */
.sim-dash-parties {
  display: flex;
  flex-direction: column;
}

.sim-dash-party {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
}

.sim-dash-party + .sim-dash-party {
  border-top: 1px solid var(--sim-border);
}

.sim-dash-party-avatar {
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #FFFFFF;
  flex-shrink: 0;
}

.sim-avatar-sarah {
  background: linear-gradient(135deg, var(--sim-sarah), #7C3AED);
}

.sim-avatar-mike {
  background: linear-gradient(135deg, var(--sim-mike), #059669);
}

.sim-dash-party-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--sim-text);
  line-height: 1.3;
}

.sim-dash-party-role {
  font-size: 12px;
  color: var(--sim-text-secondary);
  margin-top: 1px;
}

.sim-dash-party-channel {
  font-size: 11px;
  color: var(--sim-text-muted);
  margin-top: 2px;
}

/* Stage Tracker */
.sim-dash-stage-tracker {
  display: flex;
  flex-direction: column;
}

.sim-dash-stages {
  display: flex;
  flex-direction: column;
  position: relative;
  padding-left: 4px;
}

.sim-dash-stage {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
  position: relative;
  font-size: 13px;
  font-weight: 500;
  color: var(--sim-text-muted);
  transition: color var(--sim-transition-normal);
}

/* Vertical connecting line */
.sim-dash-stage:not(:last-child)::after {
  content: '';
  position: absolute;
  left: 7px;
  top: 28px;
  bottom: -4px;
  width: 2px;
  background: var(--sim-border);
  transition: background var(--sim-transition-normal);
}

.sim-dash-stage.completed:not(:last-child)::after {
  background: var(--sim-accent);
}

.sim-dash-stage.active:not(:last-child)::after {
  background: linear-gradient(to bottom, var(--sim-primary), var(--sim-border));
}

/* Stage dots */
.sim-dash-stage-dot {
  width: 16px;
  height: 16px;
  min-width: 16px;
  border-radius: 50%;
  border: 2px solid var(--sim-border);
  background: var(--sim-surface);
  position: relative;
  z-index: 2;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.sim-dash-stage.completed .sim-dash-stage-dot {
  background: var(--sim-accent);
  border-color: var(--sim-accent);
}

/* Checkmark inside completed dot */
.sim-dash-stage.completed .sim-dash-stage-dot::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 4px;
  width: 5px;
  height: 8px;
  border-right: 2px solid #FFFFFF;
  border-bottom: 2px solid #FFFFFF;
  transform: rotate(45deg);
}

.sim-dash-stage.completed {
  color: var(--sim-text);
}

.sim-dash-stage.active .sim-dash-stage-dot {
  background: var(--sim-primary);
  border-color: var(--sim-primary);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
  animation: stagePulse 2s ease-in-out infinite;
}

.sim-dash-stage.active {
  color: var(--sim-primary);
  font-weight: 600;
}

/* Sentiment */
.sim-dash-sentiment {
  display: flex;
  flex-direction: column;
}

.sim-dash-sentiment-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.sim-dash-sentiment-row > span {
  font-size: 12px;
  font-weight: 600;
  color: var(--sim-text-secondary);
  width: 46px;
  flex-shrink: 0;
}

.sim-dash-sentiment-bar {
  flex: 1;
  height: 6px;
  background: var(--sim-border);
  border-radius: 3px;
  overflow: hidden;
}

.sim-dash-sentiment-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.5s ease;
}

.sim-sentiment-sarah {
  background: linear-gradient(90deg, var(--sim-sarah), #A78BFA);
}

.sim-sentiment-mike {
  background: linear-gradient(90deg, var(--sim-mike), var(--sim-accent-light));
}

/* -- Dashboard Main Area (Activity Log) -- */
.sim-dash-main {
  flex: 1;
  padding: 20px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--sim-border) transparent;
}

.sim-dash-main::-webkit-scrollbar {
  width: 4px;
}

.sim-dash-main::-webkit-scrollbar-thumb {
  background: var(--sim-border);
  border-radius: 2px;
}

.sim-dash-log {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* Log entries */
.sim-log-entry {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--sim-radius-md);
  animation: logSlideIn 0.25s ease-out;
  transition: background var(--sim-transition-fast);
}

.sim-log-entry:hover {
  background: var(--sim-surface-alt);
}

.sim-log-time {
  font-size: 12px;
  font-weight: 500;
  color: var(--sim-text-muted);
  white-space: nowrap;
  min-width: 52px;
  padding-top: 1px;
  font-variant-numeric: tabular-nums;
}

.sim-log-icon {
  width: 24px;
  height: 24px;
  min-width: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #FFFFFF;
  flex-shrink: 0;
}

/* Log entry type colors */
.sim-log-icon.message_received {
  background: #3B82F6;
}

.sim-log-icon.analyzing {
  background: var(--sim-primary);
  animation: analyzeGlow 1.5s ease-in-out infinite;
}

.sim-log-icon.message_sent {
  background: var(--sim-accent);
}

.sim-log-icon.stage_advanced {
  background: #F59E0B;
}

.sim-log-icon.proposal_generated {
  background: var(--sim-primary);
}

.sim-log-icon.agreement_reached {
  background: var(--sim-accent);
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.4);
}

.sim-log-text {
  flex: 1;
  font-size: 14px;
  line-height: 1.5;
  color: var(--sim-text);
}

.sim-log-entry.analyzing .sim-log-text {
  color: var(--sim-primary);
  font-weight: 500;
}


/* ============================================================
   BROWSER MOCKUP (Form Perspective)
   ============================================================ */
.sim-device-browser {
  width: 100%;
  max-width: 700px;
  border-radius: var(--sim-radius-lg);
  overflow: hidden;
  box-shadow: var(--sim-shadow-2xl);
  border: 1px solid var(--sim-border);
  background: var(--sim-surface);
  margin: 0 auto;
}

.sim-browser-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 40px;
  padding: 0 16px;
  background: #F1F5F9;
  border-bottom: 1px solid var(--sim-border);
  flex-shrink: 0;
}

.sim-browser-dots {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #FF5F56;
  box-shadow: 18px 0 0 #FFBD2E, 36px 0 0 #27C93F;
  margin-left: 4px;
  flex-shrink: 0;
}

.sim-browser-url {
  font-size: 13px;
  font-weight: 400;
  color: var(--sim-text-muted);
  margin-left: 36px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sim-browser-content {
  background: var(--sim-surface);
  padding: 32px;
  overflow-y: auto;
}

.sim-mock-form {
  max-width: 500px;
  margin: 0 auto;
}

.sim-mock-form-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--sim-text);
  margin-bottom: 4px;
}

.sim-mock-form-subtitle {
  font-size: 14px;
  color: var(--sim-text-secondary);
  margin-bottom: 24px;
}

.sim-mock-field {
  margin-bottom: 16px;
}

.sim-mock-field label {
  font-size: 13px;
  font-weight: 500;
  color: var(--sim-text-secondary);
  display: block;
  margin-bottom: 4px;
}

.sim-mock-select,
.sim-mock-input,
.sim-mock-textarea {
  width: 100%;
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  padding: 10px 14px;
  font-family: var(--sim-font);
  font-size: 15px;
  color: var(--sim-text);
  background: var(--sim-surface);
  transition: border-color var(--sim-transition-fast);
}

.sim-mock-select:focus,
.sim-mock-input:focus,
.sim-mock-textarea:focus {
  outline: none;
  border-color: var(--sim-primary);
}

.sim-mock-textarea {
  min-height: 60px;
  resize: vertical;
}

.sim-mock-field-row {
  display: flex;
  gap: 16px;
}

.sim-mock-field-row > * {
  flex: 1;
}

.sim-mock-price {
  font-size: 20px;
  font-weight: 700;
  color: var(--sim-primary);
}

.sim-mock-price-note {
  font-size: 13px;
  font-weight: 400;
  color: var(--sim-text-muted);
}

.sim-mock-submit {
  width: 100%;
  padding: 14px;
  background: var(--sim-primary);
  color: #FFFFFF;
  font-family: var(--sim-font);
  font-weight: 600;
  font-size: 16px;
  border: none;
  border-radius: var(--sim-radius-md);
  cursor: pointer;
  margin-top: 8px;
  transition: background var(--sim-transition-fast);
}

.sim-mock-submit:hover {
  background: var(--sim-primary-dark);
}

/* Form perspective: hidden by default, shown with .active */
#perspective-form {
  display: none;
  width: 100%;
  height: 100%;
  animation: simFadeIn 0.35s ease-out;
}

#perspective-form.active {
  display: flex;
  align-items: center;
  justify-content: center;
}


/* ============================================================
   STRIPE CHECKOUT MOCKUP
   ============================================================ */
.sim-stripe-checkout {
  max-width: 420px;
  margin: 0 auto;
  padding: 32px 0;
}
.sim-stripe-header {
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--sim-border);
}
.sim-stripe-logo {
  margin-bottom: 16px;
}
.sim-stripe-amount {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sim-stripe-price {
  font-size: 36px;
  font-weight: 700;
  color: var(--sim-text);
}
.sim-stripe-desc {
  font-size: 14px;
  color: var(--sim-text-secondary);
}
.sim-stripe-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.sim-stripe-field label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--sim-text);
  margin-bottom: 6px;
}
.sim-stripe-input {
  border: 1px solid #d1d5db;
  border-radius: 6px;
  padding: 10px 12px;
  font-size: 15px;
  color: var(--sim-text);
  background: white;
  font-family: 'Inter', sans-serif;
}
.sim-stripe-card-row {
  margin-bottom: 0;
}
.sim-stripe-card-number {
  border-radius: 6px 6px 0 0;
  border-bottom: none;
  font-family: monospace;
  letter-spacing: 0.05em;
}
.sim-stripe-card-row-split {
  display: flex;
}
.sim-stripe-card-expiry {
  flex: 1;
  border-radius: 0 0 0 6px;
  border-right: none;
  font-family: monospace;
}
.sim-stripe-card-cvc {
  flex: 1;
  border-radius: 0 0 6px 0;
  font-family: monospace;
}
.sim-stripe-pay-btn {
  width: 100%;
  padding: 14px;
  background: #635BFF;
  color: white;
  font-weight: 600;
  font-size: 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
  transition: background 0.2s;
}
.sim-stripe-pay-btn:hover {
  background: #5046e5;
}
.sim-stripe-pay-btn.sim-stripe-processing {
  background: #a5a2ff;
  cursor: wait;
}
.sim-stripe-pay-btn.sim-stripe-success {
  background: #10B981;
}
.sim-stripe-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 20px;
  padding-top: 16px;
  font-size: 12px;
  color: #687385;
}
.sim-stripe-powered strong {
  color: #635BFF;
}
.sim-stripe-secure {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Payment confirmation overlay */
.sim-payment-confirmed {
  position: absolute;
  inset: 0;
  background: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  z-index: 10;
  opacity: 0;
  transition: opacity 0.3s ease;
  border-radius: 0 0 12px 12px;
}
.sim-payment-confirmed.visible {
  opacity: 1;
}
.sim-payment-confirmed-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #ECFDF5;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sim-payment-confirmed-icon svg {
  width: 32px;
  height: 32px;
  color: #10B981;
}
.sim-payment-confirmed-text {
  font-size: 20px;
  font-weight: 600;
  color: var(--sim-text);
}
.sim-payment-confirmed-detail {
  font-size: 14px;
  color: var(--sim-text-secondary);
}


/* ============================================================
   AGREEMENT DOCUMENT
   ============================================================ */
.sim-agreement {
  max-width: 600px;
  margin: 0 auto;
  padding: 8px 0;
}
.sim-agreement-header {
  text-align: center;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--sim-border);
}
.sim-agreement-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--sim-primary);
  background: rgba(99, 102, 241, 0.1);
  padding: 4px 12px;
  border-radius: 100px;
  margin-bottom: 12px;
}
.sim-agreement-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--sim-text);
  margin: 0 0 4px;
}
.sim-agreement-subtitle {
  font-size: 14px;
  color: var(--sim-text-secondary);
  margin: 0;
}
.sim-agreement-section h4 {
  font-size: 15px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--sim-text);
  margin: 0 0 12px;
}
.sim-agreement-terms {
  list-style: decimal;
  padding-left: 20px;
  font-size: 14px;
  line-height: 1.7;
  color: var(--sim-text);
  margin: 0 0 24px;
}
.sim-agreement-terms li {
  margin-bottom: 8px;
}
.sim-agreement-terms ul {
  list-style: disc;
  padding-left: 20px;
  margin: 4px 0;
}
.sim-agreement-signatures {
  display: flex;
  gap: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--sim-border);
}
.sim-agreement-sig {
  flex: 1;
}
.sim-sig-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--sim-text-secondary);
  margin-bottom: 8px;
}
.sim-sig-line {
  height: 44px;
  border-bottom: 2px solid var(--sim-text);
  display: flex;
  align-items: flex-end;
  padding-bottom: 4px;
  margin-bottom: 4px;
  position: relative;
}
.sim-sig-handwriting {
  font-family: 'Brush Script MT', 'Segoe Script', cursive;
  font-size: 28px;
  color: #1a365d;
  opacity: 0;
  transition: opacity 0.5s ease;
}
.sim-sig-handwriting.signed {
  opacity: 1;
}
.sim-sig-date {
  font-size: 12px;
  color: var(--sim-text-muted);
  min-height: 16px;
}
.sim-agreement-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--sim-border);
  font-size: 12px;
  color: var(--sim-text-muted);
}
.sim-agreement-seal {
  font-weight: 600;
  color: var(--sim-primary);
}

/* Perspective containers for new views */
#perspective-payment,
#perspective-agreement {
  display: none;
}
#perspective-payment.active,
#perspective-agreement.active {
  display: flex;
  align-items: center;
  justify-content: center;
}


/* ============================================================
   HIGHLIGHT CALLOUT
   ============================================================ */
.sim-callout {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 48px);
  max-width: 720px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 20px;
  background: var(--sim-callout-bg);
  border-left: 4px solid var(--sim-callout-border);
  border-radius: 0 var(--sim-radius-md) var(--sim-radius-md) 0;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
  z-index: 80;
  animation: calloutSlideUp 0.3s ease-out;
  opacity: 0;
  pointer-events: none;
}

.sim-callout.visible {
  opacity: 1;
  pointer-events: auto;
}

.sim-callout-icon {
  width: 22px;
  height: 22px;
  min-width: 22px;
  border-radius: 50%;
  background: var(--sim-callout-border);
  color: #FFFFFF;
  font-size: 12px;
  font-weight: 700;
  font-style: italic;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
}

.sim-callout-text {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.55;
  color: var(--sim-callout-text);
}


/* ============================================================
   BOTTOM CONTROLS
   ============================================================ */
.sim-controls {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 24px;
  height: 64px;
  background: var(--sim-bg);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
  z-index: 100;
}

.sim-btn {
  padding: 8px 20px;
  font-family: var(--sim-font);
  font-size: 14px;
  font-weight: 600;
  border: none;
  border-radius: var(--sim-radius-full);
  cursor: pointer;
  transition: all var(--sim-transition-normal);
  white-space: nowrap;
}

.sim-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.sim-btn-prev {
  background: rgba(255, 255, 255, 0.08);
  color: var(--sim-text-muted);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.sim-btn-prev:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.12);
  color: var(--sim-text-on-dark);
}

.sim-btn-next {
  background: var(--sim-primary);
  color: #FFFFFF;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

.sim-btn-next:hover:not(:disabled) {
  background: var(--sim-primary-dark);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.4);
  transform: translateY(-1px);
}

.sim-btn-auto {
  background: rgba(255, 255, 255, 0.06);
  color: var(--sim-text-muted);
  border: 1px solid rgba(255, 255, 255, 0.08);
  margin-left: auto;
}

.sim-btn-auto:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--sim-text-on-dark);
}

.sim-btn-auto.playing {
  background: rgba(99, 102, 241, 0.15);
  color: var(--sim-primary-light);
  border-color: rgba(99, 102, 241, 0.3);
}

/* Timeline */
.sim-timeline {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 0 8px;
  position: relative;
}

.sim-timeline-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: 2px solid rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  z-index: 2;
  flex-shrink: 0;
}

.sim-timeline-dot.completed {
  background: var(--sim-primary);
  border-color: var(--sim-primary);
}

.sim-timeline-dot.current {
  width: 14px;
  height: 14px;
  background: var(--sim-primary);
  border-color: var(--sim-primary-light);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.25);
  animation: timelinePulse 2s ease-in-out infinite;
}

.sim-timeline-dot:hover:not(.current) {
  transform: scale(1.3);
  border-color: var(--sim-primary-light);
}

.sim-timeline-line {
  height: 2px;
  flex: 1;
  background: rgba(255, 255, 255, 0.1);
  max-width: 32px;
}

.sim-timeline-line.completed {
  background: var(--sim-primary);
}


/* ============================================================
   SUCCESS OVERLAY
   ============================================================ */
.sim-success {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.sim-success.visible {
  display: flex;
  animation: simFadeIn 0.3s ease-out;
}

.sim-success-card {
  background: var(--sim-surface);
  border-radius: var(--sim-radius-xl);
  padding: 48px;
  max-width: 500px;
  width: 90%;
  text-align: center;
  box-shadow: var(--sim-shadow-2xl);
  animation: successScaleIn 0.5s ease-out 0.15s both;
  position: relative;
  overflow: hidden;
}

/* Animated checkmark */
.sim-success-check {
  width: 72px;
  height: 72px;
  margin: 0 auto 24px;
  position: relative;
}

.sim-success-check svg {
  width: 100%;
  height: 100%;
}

.sim-success-check .check-circle {
  fill: none;
  stroke: var(--sim-accent);
  stroke-width: 3;
  stroke-dasharray: 220;
  stroke-dashoffset: 220;
  animation: drawCircle 0.6s ease-out 0.4s forwards;
}

.sim-success-check .check-mark {
  fill: none;
  stroke: var(--sim-accent);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 48;
  stroke-dashoffset: 48;
  animation: drawCheck 0.4s ease-out 0.9s forwards;
}

.sim-success h2 {
  font-size: 28px;
  font-weight: 800;
  color: var(--sim-text);
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.sim-success-tagline {
  font-size: 16px;
  color: var(--sim-text-secondary);
  margin-bottom: 24px;
  line-height: 1.5;
}

/* Stats grid */
.sim-success-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.sim-success-stat {
  padding: 16px;
  background: var(--sim-surface-alt);
  border-radius: var(--sim-radius-lg);
  border: 1px solid var(--sim-border);
  text-align: center;
}

.sim-success-stat-value {
  font-size: 24px;
  font-weight: 800;
  color: var(--sim-text);
  letter-spacing: -0.02em;
  display: block;
}

.sim-success-stat-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--sim-text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 2px;
  display: block;
}

.sim-success-message {
  font-size: 15px;
  font-weight: 600;
  color: var(--sim-text);
  margin-bottom: 28px;
  font-style: italic;
}

.sim-success-back {
  display: inline-flex;
  align-items: center;
  padding: 12px 32px;
  font-family: var(--sim-font);
  font-size: 15px;
  font-weight: 600;
  color: #FFFFFF;
  background: linear-gradient(135deg, var(--sim-primary), var(--sim-primary-dark));
  border: none;
  border-radius: var(--sim-radius-full);
  cursor: pointer;
  transition: all var(--sim-transition-normal);
  text-decoration: none;
  box-shadow: 0 2px 12px rgba(99, 102, 241, 0.3);
}

.sim-success-back:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
}

/* Alternative checkmark SVG classes (new form flow) */
.sim-checkmark-svg {
  width: 80px;
  height: 80px;
  margin: 0 auto 24px;
}

.sim-checkmark-circle {
  stroke: #10B981;
  stroke-width: 2;
  fill: none;
  stroke-dasharray: 157;
  stroke-dashoffset: 157;
  animation: drawCircle 0.6s ease forwards;
}

.sim-checkmark-check {
  stroke: #10B981;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  stroke-dasharray: 50;
  stroke-dashoffset: 50;
  animation: drawCheck 0.4s ease 0.6s forwards;
}

/* Alternative success headings/buttons (new form flow) */
.sim-success-heading {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 24px;
  color: var(--sim-text);
}

.sim-success-btn {
  display: inline-block;
  padding: 12px 32px;
  background: var(--sim-primary);
  color: #FFFFFF;
  text-decoration: none;
  border-radius: var(--sim-radius-md);
  font-family: var(--sim-font);
  font-weight: 600;
  font-size: 15px;
  transition: all var(--sim-transition-normal);
  border: none;
  cursor: pointer;
}

.sim-success-btn:hover {
  background: var(--sim-primary-dark);
  transform: translateY(-1px);
}

/* Confetti particle (new form flow) */
.sim-confetti-particle {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  animation: confettiRise 2s ease-out forwards;
  pointer-events: none;
}

/* Confetti particles */
.sim-confetti {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  pointer-events: none;
}

.sim-confetti:nth-child(odd) {
  border-radius: 2px;
  width: 5px;
  height: 8px;
}

.sim-confetti.c1 { background: var(--sim-primary); animation: confettiRise 2.5s ease-out infinite; left: 10%; animation-delay: 0s; }
.sim-confetti.c2 { background: var(--sim-accent); animation: confettiRise 2.8s ease-out infinite; left: 20%; animation-delay: 0.3s; }
.sim-confetti.c3 { background: var(--sim-sarah); animation: confettiRise 2.2s ease-out infinite; left: 35%; animation-delay: 0.6s; }
.sim-confetti.c4 { background: var(--sim-primary-light); animation: confettiRise 2.6s ease-out infinite; left: 50%; animation-delay: 0.15s; }
.sim-confetti.c5 { background: var(--sim-accent-light); animation: confettiRise 2.4s ease-out infinite; left: 65%; animation-delay: 0.45s; }
.sim-confetti.c6 { background: var(--sim-sarah); animation: confettiRise 2.7s ease-out infinite; left: 78%; animation-delay: 0.75s; }
.sim-confetti.c7 { background: var(--sim-primary); animation: confettiRise 2.3s ease-out infinite; left: 90%; animation-delay: 0.2s; }
.sim-confetti.c8 { background: var(--sim-mike); animation: confettiRise 2.9s ease-out infinite; left: 5%; animation-delay: 0.5s; }
.sim-confetti.c9 { background: var(--sim-primary-light); animation: confettiRise 2.1s ease-out infinite; left: 42%; animation-delay: 0.85s; }
.sim-confetti.c10 { background: var(--sim-accent); animation: confettiRise 2.55s ease-out infinite; left: 58%; animation-delay: 0.35s; }
.sim-confetti.c11 { background: var(--sim-sarah); animation: confettiRise 2.65s ease-out infinite; left: 82%; animation-delay: 0.1s; }
.sim-confetti.c12 { background: var(--sim-primary); animation: confettiRise 2.35s ease-out infinite; left: 15%; animation-delay: 0.7s; }


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

/* Generic fade in */
@keyframes simFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Callout slide up + fade */
@keyframes calloutSlideUp {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* Email sidebar item slides in */
@keyframes emailSlideIn {
  from {
    opacity: 0;
    transform: translateY(-12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* SMS bubble appears */
@keyframes smsBubbleIn {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Typing indicator dots */
@keyframes typingDots {
  0%, 60%, 100% {
    transform: translateY(0);
    opacity: 0.4;
  }
  30% {
    transform: translateY(-4px);
    opacity: 1;
  }
}

/* Unread email dot pulse */
@keyframes unreadPulse {
  0%, 100% {
    opacity: 1;
    transform: translateY(-50%) scale(1);
  }
  50% {
    opacity: 0.5;
    transform: translateY(-50%) scale(1.3);
  }
}

/* Badge bounce in */
@keyframes badgeBounce {
  0% {
    transform: scale(0);
  }
  60% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
  }
}

/* Dashboard log entry slide in */
@keyframes logSlideIn {
  from {
    opacity: 0;
    transform: translateX(16px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Stage dot pulse */
@keyframes stagePulse {
  0%, 100% {
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
  }
  50% {
    box-shadow: 0 0 0 8px rgba(99, 102, 241, 0.1);
  }
}

/* Timeline current dot pulse */
@keyframes timelinePulse {
  0%, 100% {
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.25);
  }
  50% {
    box-shadow: 0 0 0 6px rgba(99, 102, 241, 0.15);
  }
}

/* Analyzing glow on log icon */
@keyframes analyzeGlow {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4);
  }
  50% {
    box-shadow: 0 0 12px 4px rgba(99, 102, 241, 0.25);
  }
}

/* Success overlay scale in */
@keyframes successScaleIn {
  from {
    opacity: 0;
    transform: scale(0.85);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* SVG checkmark circle draw */
@keyframes drawCircle {
  to {
    stroke-dashoffset: 0;
  }
}

/* SVG checkmark path draw */
@keyframes drawCheck {
  to {
    stroke-dashoffset: 0;
  }
}

/* Confetti rising particles */
@keyframes confettiRise {
  0% {
    opacity: 1;
    transform: translateY(0) rotate(0deg);
  }
  50% {
    opacity: 0.8;
  }
  100% {
    opacity: 0;
    transform: translateY(-400px) rotate(720deg);
  }
}

/* Sentiment bar fill */
@keyframes sentimentFill {
  from {
    width: 0;
  }
}

/* General slide up */
@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* General pulse */
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

/* Fade in up */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}


/* ============================================================
   CASE PAGE TAB ICON
   ============================================================ */
.sim-tab-casepage {
  background: linear-gradient(135deg, #F59E0B, #D97706);
}

.sim-tab[data-perspective="casepage"] .sim-tab-badge {
  background: #F59E0B;
}


/* ============================================================
   CASE PAGE PERSPECTIVE CONTAINER
   ============================================================ */
#perspective-casepage {
  display: none;
}

#perspective-casepage.active {
  display: flex;
  align-items: center;
  justify-content: center;
}


/* ============================================================
   CASE PAGE LAYOUT & STYLES
   ============================================================ */
.sim-casepage-content {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sim-casepage-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  border-bottom: 1px solid var(--sim-border);
}

.sim-casepage-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--sim-text);
}

.sim-casepage-status {
  display: inline-block;
  padding: 2px 10px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--sim-radius-full);
  background: rgba(99, 102, 241, 0.1);
  color: var(--sim-primary);
}

.sim-casepage-body {
  display: flex;
  flex-direction: row;
  flex: 1;
  gap: 0;
  overflow: hidden;
}

.sim-casepage-parties {
  width: 340px;
  min-width: 340px;
  padding: 20px;
  border-right: 1px solid var(--sim-border);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.sim-casepage-parties-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.sim-casepage-parties-header h4 {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sim-text-muted);
}

.sim-casepage-add-btn {
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 600;
  background: var(--sim-primary);
  color: #FFFFFF;
  border: none;
  border-radius: var(--sim-radius-full);
  cursor: pointer;
}

.sim-casepage-party-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sim-casepage-party-card {
  display: flex;
  flex-direction: row;
  padding: 14px 16px;
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  align-items: center;
  gap: 12px;
  background: var(--sim-surface);
  transition: background 0.15s;
}

.sim-casepage-party-card:hover {
  background: var(--sim-surface-alt);
}

.sim-casepage-party-avatar {
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #FFFFFF;
  flex-shrink: 0;
}

.sim-casepage-party-info {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 2px;
}

.sim-casepage-party-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--sim-text);
}

.sim-casepage-party-email {
  font-size: 12px;
  color: var(--sim-text-muted);
}

.sim-casepage-party-role-tag {
  display: inline-block;
  padding: 2px 8px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--sim-radius-full);
  background: rgba(139, 92, 246, 0.1);
  color: #8B5CF6;
}

.sim-role-observer {
  background: rgba(245, 158, 11, 0.1);
  color: #D97706;
}

.sim-casepage-party-channel {
  font-size: 12px;
  color: var(--sim-text-muted);
  margin-left: auto;
  white-space: nowrap;
}

.sim-casepage-remove-btn {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid var(--sim-border);
  color: var(--sim-text-muted);
  cursor: pointer;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  margin-left: 8px;
}

.sim-casepage-remove-btn:hover {
  background: rgba(239, 68, 68, 0.1);
  border-color: #EF4444;
  color: #EF4444;
}

.sim-casepage-add-form {
  border-top: 1px solid var(--sim-border);
  padding-top: 16px;
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.sim-casepage-add-field label {
  font-size: 12px;
  font-weight: 500;
  color: var(--sim-text-secondary);
  margin-bottom: 4px;
  display: block;
}

.sim-casepage-input {
  width: 100%;
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  padding: 10px 14px;
  font-family: var(--sim-font);
  font-size: 15px;
  color: var(--sim-text);
  background: var(--sim-surface);
  transition: border-color var(--sim-transition-fast);
}

.sim-casepage-add-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.sim-casepage-cancel-btn {
  padding: 6px 16px;
  font-size: 13px;
  font-weight: 500;
  background: transparent;
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  cursor: pointer;
  color: var(--sim-text-secondary);
}

.sim-casepage-confirm-btn {
  padding: 6px 16px;
  font-size: 13px;
  font-weight: 600;
  background: var(--sim-primary);
  color: #FFFFFF;
  border: none;
  border-radius: var(--sim-radius-md);
  cursor: pointer;
}

.sim-casepage-log {
  flex: 1;
  padding: 20px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sim-casepage-log h4 {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sim-text-muted);
  margin-bottom: 12px;
}

.sim-casepage-log-list {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0;
  scrollbar-width: thin;
}

.sim-casepage-log-entry {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--sim-border);
  font-size: 13px;
  animation: logSlideIn 0.25s ease-out;
}

.sim-casepage-log-dot {
  width: 8px;
  height: 8px;
  min-width: 8px;
  border-radius: 50%;
  margin-top: 5px;
  flex-shrink: 0;
}

.sim-casepage-log-time {
  font-size: 12px;
  font-weight: 500;
  color: var(--sim-text-muted);
  white-space: nowrap;
  min-width: 60px;
  font-variant-numeric: tabular-nums;
}

.sim-casepage-log-text {
  flex: 1;
  color: var(--sim-text);
  line-height: 1.4;
}


/* ============================================================
   CASE PAGE HIGHLIGHT ANIMATION
   ============================================================ */
@keyframes casepageHighlight {
  0% { background: rgba(245, 158, 11, 0.15); }
  100% { background: transparent; }
}

.sim-casepage-log-entry-new {
  animation: casepageHighlight 1.5s ease-out, logSlideIn 0.25s ease-out;
}


/* ============================================================
   RESPONSIVE -- Tablet (max-width: 768px)
   ============================================================ */
@media (max-width: 768px) {
  .sim-header {
    padding: 0 16px;
    height: 48px;
  }

  .sim-title {
    font-size: 14px;
  }

  .sim-tabs {
    padding: 8px 16px;
    gap: 6px;
    overflow-x: auto;
    justify-content: flex-start;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .sim-tabs::-webkit-scrollbar {
    display: none;
  }

  .sim-tab {
    font-size: 13px;
    padding: 6px 14px;
    flex-shrink: 0;
  }

  .sim-content {
    padding: 16px;
    padding-bottom: 90px;
  }

  /* Email: single column, no sidebar */
  .sim-device-email {
    flex-direction: column;
    max-height: none;
    height: auto;
    max-height: 100%;
  }

  .sim-email-sidebar {
    width: 100%;
    min-width: 100%;
    max-height: 140px;
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .sim-email-list {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    gap: 0;
  }

  .sim-email-item {
    min-width: 200px;
    border-bottom: none;
    border-right: 1px solid rgba(255, 255, 255, 0.04);
  }

  /* Phone: scale down */
  .sim-phone-frame {
    width: 320px;
    height: 600px;
    border-radius: 32px;
  }

  .sim-phone-notch {
    width: 100px;
    height: 24px;
    border-radius: 0 0 14px 14px;
  }

  /* Dashboard: stack */
  .sim-device-dashboard {
    max-height: none;
    height: auto;
    max-height: 100%;
  }

  .sim-dash-body {
    flex-direction: column;
  }

  .sim-dash-sidebar {
    width: 100%;
    min-width: 100%;
    max-height: 200px;
    border-right: none;
    border-bottom: 1px solid var(--sim-border);
    flex-direction: row;
    flex-wrap: wrap;
    gap: 16px;
    overflow-x: auto;
  }

  .sim-dash-sidebar > div {
    min-width: 200px;
  }

  /* Controls */
  .sim-controls {
    padding: 0 12px;
    height: 56px;
    gap: 8px;
  }

  .sim-btn {
    padding: 6px 14px;
    font-size: 13px;
  }

  .sim-timeline-dot {
    width: 8px;
    height: 8px;
  }

  .sim-timeline-dot.current {
    width: 11px;
    height: 11px;
  }

  .sim-timeline-line {
    max-width: 16px;
  }

  /* Callout */
  .sim-callout {
    bottom: 68px;
    width: calc(100% - 24px);
    padding: 10px 14px;
  }

  .sim-callout-text {
    font-size: 13px;
  }

  /* Success overlay */
  .sim-success-card {
    padding: 32px 24px;
  }

  .sim-success h2 {
    font-size: 24px;
  }

  .sim-success-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }

  .sim-success-stat {
    padding: 12px;
  }

  .sim-success-stat-value {
    font-size: 20px;
  }
}


/* ============================================================
   RESPONSIVE -- Mobile (max-width: 480px)
   ============================================================ */
@media (max-width: 480px) {
  .sim-header {
    padding: 0 12px;
    height: 44px;
  }

  .sim-back-link {
    font-size: 13px;
  }

  .sim-title {
    font-size: 13px;
  }

  .sim-step-counter {
    font-size: 12px;
  }

  .sim-content {
    padding: 12px;
    padding-bottom: 80px;
  }

  .sim-phone-frame {
    width: 280px;
    height: 520px;
    border-radius: 28px;
  }

  .sim-phone-notch {
    width: 80px;
    height: 20px;
    border-radius: 0 0 12px 12px;
  }

  .sim-sms-bubble {
    font-size: 14px;
    max-width: 85%;
  }

  .sim-controls {
    height: 52px;
    padding: 0 8px;
    gap: 6px;
  }

  .sim-btn {
    padding: 6px 12px;
    font-size: 12px;
  }

  .sim-btn-auto {
    display: none;
  }

  .sim-timeline-dot {
    width: 6px;
    height: 6px;
  }

  .sim-timeline-dot.current {
    width: 9px;
    height: 9px;
  }

  .sim-timeline-line {
    max-width: 8px;
  }

  .sim-callout {
    bottom: 60px;
    width: calc(100% - 16px);
    padding: 8px 12px;
    gap: 8px;
  }

  .sim-callout-icon {
    width: 18px;
    height: 18px;
    min-width: 18px;
    font-size: 10px;
  }

  .sim-callout-text {
    font-size: 12px;
  }

  .sim-success-card {
    padding: 28px 20px;
  }

  .sim-success h2 {
    font-size: 22px;
  }

  .sim-success-stats {
    grid-template-columns: 1fr;
  }
}


/* ============================================================
   PRINT STYLES
   ============================================================ */
@media print {
  .sim-header,
  .sim-tabs,
  .sim-controls,
  .sim-callout,
  .sim-success {
    display: none !important;
  }

  .sim-body {
    height: auto;
    overflow: visible;
    background: #FFFFFF;
  }

  .sim-content {
    padding: 0;
  }

  .sim-perspective {
    display: block !important;
    page-break-after: always;
  }
}


/* ============================================================
   SCENARIO NAVIGATION
   ============================================================ */
.sim-scenario-nav {
  background: #0D0D12;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding: 0;
  overflow: hidden;
}

.sim-scenario-nav-inner {
  display: flex;
  gap: 2px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 8px 16px;
}

.sim-scenario-nav-inner::-webkit-scrollbar {
  display: none;
}

.sim-scenario-tab {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--sim-radius-md);
  color: var(--sim-text-muted);
  font-family: var(--sim-font);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--sim-transition-fast);
  flex-shrink: 0;
}

.sim-scenario-tab:hover {
  background: rgba(255, 255, 255, 0.04);
  color: var(--sim-text-on-dark);
  border-color: rgba(255, 255, 255, 0.08);
}

.sim-scenario-tab.active {
  background: rgba(99, 102, 241, 0.12);
  color: #818CF8;
  border-color: rgba(99, 102, 241, 0.3);
}

.sim-scenario-num {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  font-size: 11px;
  font-weight: 700;
  color: var(--sim-text-muted);
  flex-shrink: 0;
}

.sim-scenario-tab.active .sim-scenario-num {
  background: rgba(99, 102, 241, 0.3);
  color: #818CF8;
}

.sim-scenario-label {
  font-size: 13px;
}


/* ============================================================
   SCENARIO INFO BAR
   ============================================================ */
.sim-scenario-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 24px;
  background: rgba(99, 102, 241, 0.04);
  border-bottom: 1px solid rgba(99, 102, 241, 0.1);
}

.sim-scenario-info-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--sim-text-on-dark);
}

.sim-scenario-info-subtitle {
  font-size: 12px;
  color: var(--sim-text-muted);
}


/* ============================================================
   TIME SKIP OVERLAY
   ============================================================ */
.sim-time-skip {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10, 10, 15, 0.9);
  backdrop-filter: blur(8px);
  animation: simTimeSkipIn 0.4s ease-out;
}

.sim-time-skip-content {
  text-align: center;
}

.sim-time-skip-icon {
  color: var(--sim-primary-light);
  margin-bottom: 16px;
  animation: simTimeSkipPulse 1.5s ease-in-out infinite;
}

.sim-time-skip-text {
  font-size: 28px;
  font-weight: 700;
  color: var(--sim-text-on-dark);
  letter-spacing: -0.5px;
}

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

@keyframes simTimeSkipPulse {
  0%, 100% { opacity: 0.7; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.05); }
}


/* ============================================================
   CASE CLOSED OVERLAY
   ============================================================ */
.sim-case-closed {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(12px);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.sim-case-closed.sim-case-closed-visible {
  opacity: 1;
}

.sim-case-closed-card {
  background: var(--sim-surface);
  border-radius: var(--sim-radius-xl);
  padding: 48px;
  text-align: center;
  max-width: 440px;
  width: 90%;
  box-shadow: var(--sim-shadow-2xl);
}

.sim-case-closed-icon {
  margin-bottom: 20px;
}

.sim-case-closed-heading {
  font-size: 24px;
  font-weight: 700;
  color: #EF4444;
  margin-bottom: 12px;
}

.sim-case-closed-reason {
  font-size: 16px;
  font-weight: 600;
  color: var(--sim-text);
  margin-bottom: 8px;
}

.sim-case-closed-description {
  font-size: 14px;
  color: var(--sim-text-secondary);
  line-height: 1.6;
  margin-bottom: 16px;
}

.sim-case-closed-refund {
  font-size: 13px;
  color: var(--sim-text-muted);
  padding: 12px 16px;
  background: #F8FAFC;
  border-radius: var(--sim-radius-md);
  margin-bottom: 24px;
}

.sim-case-closed-btn {
  display: inline-block;
  padding: 10px 24px;
  background: var(--sim-primary);
  color: white;
  border-radius: var(--sim-radius-md);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  transition: background var(--sim-transition-fast);
}

.sim-case-closed-btn:hover {
  background: var(--sim-primary-dark);
}


/* ============================================================
   NOTIFICATION BANNER
   ============================================================ */
.sim-notification-banner {
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-radius: var(--sim-radius-md);
  font-size: 13px;
  font-weight: 500;
  box-shadow: var(--sim-shadow-lg);
  animation: simNotifSlideIn 0.3s ease-out;
  max-width: 90%;
}

.sim-notification-banner.sim-notif-warning {
  background: #FEF3C7;
  color: #92400E;
  border: 1px solid #F59E0B;
}

.sim-notification-banner.sim-notif-error {
  background: #FEE2E2;
  color: #991B1B;
  border: 1px solid #EF4444;
}

.sim-notification-banner.sim-notif-info {
  background: #DBEAFE;
  color: #1E40AF;
  border: 1px solid #3B82F6;
}

.sim-notification-banner.sim-notif-success {
  background: #D1FAE5;
  color: #065F46;
  border: 1px solid #10B981;
}

.sim-notification-icon {
  font-size: 16px;
  flex-shrink: 0;
}

.sim-notification-close {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  opacity: 0.5;
  padding: 0 4px;
  line-height: 1;
}

.sim-notification-close:hover {
  opacity: 1;
}

@keyframes simNotifSlideIn {
  from { opacity: 0; transform: translateX(-50%) translateY(-10px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}


/* ============================================================
   ABUSE SCREEN LOG ENTRY (in AI Dashboard)
   ============================================================ */
.sim-abuse-entry {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: var(--sim-radius-md);
  padding: 12px;
  margin: 8px 0;
}

.sim-abuse-entry-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.sim-abuse-entry-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: var(--sim-radius-full);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.sim-abuse-badge-warning {
  background: rgba(245, 158, 11, 0.15);
  color: #F59E0B;
}

.sim-abuse-badge-critical {
  background: rgba(239, 68, 68, 0.15);
  color: #EF4444;
}

.sim-abuse-entry-strike {
  font-size: 12px;
  color: var(--sim-text-secondary);
  font-weight: 600;
}

.sim-abuse-entry-message {
  font-size: 13px;
  color: var(--sim-text-secondary);
  font-style: italic;
  padding: 8px;
  background: rgba(0, 0, 0, 0.03);
  border-radius: var(--sim-radius-sm);
}

.sim-abuse-entry-result {
  margin-top: 8px;
  font-size: 12px;
  font-weight: 600;
}

.sim-abuse-result-flagged {
  color: #EF4444;
}

.sim-abuse-result-clean {
  color: #10B981;
}


/* ============================================================
   REFUND NOTIFICATION (in Payment perspective)
   ============================================================ */
.sim-refund-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.97);
  border-radius: inherit;
  z-index: 10;
  animation: simFadeIn 0.3s ease-out;
}

.sim-refund-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #DBEAFE;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: #3B82F6;
}

.sim-refund-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--sim-text);
  margin-bottom: 4px;
}

.sim-refund-detail {
  font-size: 14px;
  color: var(--sim-text-secondary);
  margin-bottom: 4px;
}

.sim-refund-reason {
  font-size: 12px;
  color: var(--sim-text-muted);
}
