:root {
  --bg-main: #0b0f19;
  --bg-card: rgba(18, 25, 41, 0.75);
  --bg-card-hover: rgba(26, 36, 58, 0.9);
  --bg-input: #111827;
  --border-color: rgba(255, 255, 255, 0.08);
  --border-focus: #f43f5e;
  
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  
  --ig-gradient: linear-gradient(135deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  --ig-primary: #e1306c;
  
  --color-danger: #f43f5e;
  --color-danger-bg: rgba(244, 63, 94, 0.12);
  --color-success: #10b981;
  --color-success-bg: rgba(16, 185, 129, 0.12);
  --color-info: #0ea5e9;
  --color-info-bg: rgba(14, 165, 233, 0.12);
  --color-warning: #f59e0b;
  --color-warning-bg: rgba(245, 158, 11, 0.12);
  --color-purple: #a855f7;
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 25px rgba(225, 48, 108, 0.25);
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg-main);
  background-image: 
    radial-gradient(at 0% 0%, rgba(220, 39, 67, 0.08) 0px, transparent 50%),
    radial-gradient(at 100% 0%, rgba(188, 24, 136, 0.08) 0px, transparent 50%),
    radial-gradient(at 50% 100%, rgba(15, 23, 42, 0.8) 0px, transparent 50%);
  color: var(--text-main);
  min-height: 100vh;
  padding: 2rem 1.5rem 4rem;
  line-height: 1.5;
}

.app-container {
  max-width: 1200px;
  margin: 0 auto;
}

/* Glassmorphism Card Base */
.card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

/* Header */
.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.brand-icon {
  width: 50px;
  height: 50px;
  background: var(--ig-gradient);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-glow);
  color: #fff;
}

.brand h1 {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand h1 span {
  background: var(--ig-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.subtitle {
  color: var(--text-muted);
  font-size: 0.875rem;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
  text-decoration: none;
}

.btn-primary {
  background: var(--ig-gradient);
  color: #fff;
  box-shadow: 0 4px 15px rgba(225, 48, 108, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(225, 48, 108, 0.45);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.07);
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border-color);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-block {
  width: 100%;
  justify-content: center;
  padding: 0.85rem;
}

/* Source Selection Section */
.source-section {
  padding: 2.2rem;
  margin-bottom: 2.5rem;
  border: 1px solid rgba(225, 48, 108, 0.2);
  position: relative;
  overflow: hidden;
}

.source-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--ig-gradient);
}

.section-title-wrap {
  text-align: center;
  margin-bottom: 1.8rem;
}

.section-title-wrap h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.section-title-wrap p {
  color: var(--text-muted);
  font-size: 0.92rem;
}

/* Source Tabs */
.source-tabs {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  justify-content: center;
}

.source-tab-btn {
  flex: 1;
  max-width: 320px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--border-color);
  padding: 1rem;
  border-radius: var(--radius-md);
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
  font-weight: 600;
  font-size: 0.9rem;
}

.source-tab-btn:hover {
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--text-main);
}

.source-tab-btn.active {
  background: rgba(225, 48, 108, 0.08);
  border-color: var(--ig-primary);
  color: var(--text-main);
  box-shadow: 0 0 15px rgba(225, 48, 108, 0.15);
}

.badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-safe {
  background: var(--color-success-bg);
  color: var(--color-success);
}

.badge-bot {
  background: var(--color-warning-bg);
  color: var(--color-warning);
}

.badge-success {
  background: var(--color-success-bg);
  color: var(--color-success);
}

/* Tab Panes */
.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

/* Dropzone */
.upload-dropzone {
  border: 2px dashed rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  padding: 3rem 2rem;
  text-align: center;
  background: rgba(15, 23, 42, 0.4);
  cursor: pointer;
  transition: var(--transition);
}

.upload-dropzone:hover, .upload-dropzone.dragover {
  border-color: var(--ig-primary);
  background: rgba(225, 48, 108, 0.05);
  transform: scale(1.005);
}

.drop-icon {
  color: var(--ig-primary);
  margin-bottom: 1rem;
}

.upload-dropzone h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.upload-dropzone p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
}

.file-hint {
  font-size: 0.78rem;
  color: var(--text-dim);
  background: rgba(255, 255, 255, 0.04);
  padding: 0.3rem 0.8rem;
  border-radius: 12px;
}

/* Guide Accordion */
.how-to-guide {
  margin-top: 1.5rem;
  background: rgba(15, 23, 42, 0.5);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  overflow: hidden;
}

.guide-header {
  padding: 0.9rem 1.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
}

.guide-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.guide-arrow {
  font-size: 0.75rem;
  color: var(--text-dim);
  transition: transform 0.2s ease;
}

.guide-content {
  display: none;
  padding: 1rem 1.5rem 1.25rem 2.5rem;
  border-top: 1px solid var(--border-color);
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.7;
}

.guide-content.open {
  display: block;
}

.guide-content li {
  margin-bottom: 0.4rem;
}

.guide-content code {
  background: rgba(255, 255, 255, 0.08);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  color: var(--text-main);
  font-size: 0.82rem;
}

/* Live Form */
.live-form {
  max-width: 520px;
  margin: 0 auto;
}

.alert {
  display: flex;
  gap: 0.8rem;
  padding: 1rem;
  border-radius: var(--radius-md);
  margin-bottom: 1.5rem;
  font-size: 0.85rem;
  line-height: 1.5;
}

.alert-info {
  background: rgba(14, 165, 233, 0.1);
  border: 1px solid rgba(14, 165, 233, 0.3);
  color: #7dd3fc;
}

.auth-tabs {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 1.2rem;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.88rem;
  color: var(--text-muted);
  cursor: pointer;
}

.radio-label input[type="radio"] {
  accent-color: var(--ig-primary);
}

.form-group {
  margin-bottom: 1.2rem;
}

.form-group label {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.help-link {
  color: var(--color-info);
  text-decoration: none;
  font-weight: 500;
}

.help-link:hover {
  text-decoration: underline;
}

.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 0.9rem;
  font-family: inherit;
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--ig-primary);
  box-shadow: 0 0 0 3px rgba(225, 48, 108, 0.15);
}

/* Progress Box */
.progress-box {
  margin-top: 1.5rem;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--border-color);
  padding: 1.25rem;
  border-radius: var(--radius-md);
}

.progress-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
}

.progress-bar-bg {
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 0.8rem;
}

.progress-bar-fill {
  height: 100%;
  background: var(--ig-gradient);
  transition: width 0.3s ease;
}

.progress-stats {
  display: flex;
  gap: 1.5rem;
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* Profile Banner */
.profile-banner {
  padding: 1.5rem 2rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.profile-meta {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.profile-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--ig-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
  box-shadow: 0 4px 15px rgba(225, 48, 108, 0.3);
}

.profile-meta h2 {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.meta-sub {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  font-size: 0.82rem;
  margin-top: 0.2rem;
}

.dot {
  color: var(--text-dim);
}

/* Stat Cards Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  transition: var(--transition);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.stat-card:hover {
  transform: translateY(-3px);
  background: var(--bg-card-hover);
  border-color: rgba(255, 255, 255, 0.18);
}

.stat-card.active {
  border-color: var(--ig-primary);
  background: rgba(225, 48, 108, 0.08);
}

.stat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.stat-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
}

.stat-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.icon-danger { background: var(--color-danger-bg); color: var(--color-danger); }
.icon-success { background: var(--color-success-bg); color: var(--color-success); }
.icon-info { background: var(--color-info-bg); color: var(--color-info); }
.icon-purple { background: rgba(168, 85, 247, 0.12); color: var(--color-purple); }
.icon-pink { background: rgba(225, 48, 108, 0.12); color: var(--ig-primary); }

.stat-value {
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 0.25rem;
}

.text-danger { color: var(--color-danger); }
.text-success { color: var(--color-success); }
.text-info { color: var(--color-info); }

.stat-desc {
  font-size: 0.74rem;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Content Card & Tabs */
.content-card {
  padding: 1.5rem;
}

.content-tabs-wrap {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 1.25rem;
  margin-bottom: 1.5rem;
}

.content-tabs {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 4px;
}

.content-tabs::-webkit-scrollbar {
  height: 4px;
}
.content-tabs::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

.nav-tab {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 600;
  padding: 0.6rem 1rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
  transition: var(--transition);
  font-family: inherit;
}

.nav-tab:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
}

.nav-tab.active {
  background: rgba(225, 48, 108, 0.12);
  color: #fff;
  border-color: rgba(225, 48, 108, 0.3);
}

.count-pill {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.15rem 0.45rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
}

.nav-tab.active .count-pill {
  background: rgba(225, 48, 108, 0.3);
  color: #fff;
}

.pill-danger {
  background: var(--color-danger-bg);
  color: var(--color-danger);
}

/* Controls (Search, Sort, Whitelist) */
.table-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.search-box {
  position: relative;
  flex: 1;
  min-width: 240px;
}

.search-box svg {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-dim);
}

.search-box input {
  width: 100%;
  padding: 0.65rem 1rem 0.65rem 2.6rem;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 0.88rem;
  font-family: inherit;
  transition: var(--transition);
}

.search-box input:focus {
  outline: none;
  border-color: var(--ig-primary);
}

.filter-checkbox {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  cursor: pointer;
  user-select: none;
}

.filter-checkbox input {
  accent-color: var(--ig-primary);
}

.sort-select {
  padding: 0.65rem 1rem;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 0.85rem;
  font-family: inherit;
  cursor: pointer;
}

/* User Card Grid */
.users-list-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 0.85rem;
}

.user-card {
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.9rem 1.1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  transition: var(--transition);
}

.user-card:hover {
  background: rgba(26, 36, 58, 0.8);
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
}

.user-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  overflow: hidden;
}

.user-avatar-sm {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-muted);
  flex-shrink: 0;
}

.user-details {
  overflow: hidden;
}

.user-name-row {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.user-username {
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-decoration: none;
}

.user-username:hover {
  color: var(--ig-primary);
  text-decoration: underline;
}

.user-date {
  font-size: 0.74rem;
  color: var(--text-dim);
}

/* Actions in User Card */
.user-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

.btn-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
}

.btn-icon:hover {
  background: rgba(255, 255, 255, 0.15);
  color: var(--text-main);
}

.btn-whitelist.active {
  color: #fbbf24;
  border-color: rgba(251, 191, 36, 0.3);
  background: rgba(251, 191, 36, 0.1);
}

/* Diff Panel */
.diff-container {
  padding: 1rem 0;
}

.diff-header {
  margin-bottom: 1.5rem;
}

.diff-header h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
}

.diff-header p {
  color: var(--text-muted);
  font-size: 0.88rem;
}

.diff-selectors {
  display: flex;
  align-items: flex-end;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.selector-group {
  flex: 1;
  min-width: 220px;
}

.selector-group label {
  display: block;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.selector-arrow {
  color: var(--text-dim);
  font-size: 1.5rem;
  padding-bottom: 0.5rem;
}

.account-overview {
  margin: 1.25rem 0 1.5rem;
  padding: 1.25rem 1.5rem;
}

.account-overview-head {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}

.account-overview-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 1.25rem;
  background: var(--ig-gradient);
  color: #fff;
}

.account-overview-head h2 {
  margin: 0;
  font-size: 1.25rem;
}

.account-overview-sub {
  margin: 0.2rem 0 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.account-overview-head .btn {
  margin-left: auto;
}

.account-overview-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.ao-stat {
  padding: 0.75rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.02);
}

.ao-label {
  display: block;
  color: var(--text-muted);
  font-size: 0.75rem;
  margin-bottom: 0.25rem;
}

.ao-stat strong {
  font-size: 1.05rem;
}

.account-overview-changes h3 {
  font-size: 0.95rem;
  margin: 0 0 0.65rem;
}

.overview-change-list {
  list-style: none;
  max-height: 180px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.overview-change-list li {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.45rem 0.6rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  font-size: 0.85rem;
}

.overview-change-list a {
  color: var(--text-main);
  text-decoration: none;
}

.overview-change-badge {
  color: var(--text-muted);
  white-space: nowrap;
}

.import-history {
  margin: 0 0 1.5rem;
  padding: 1rem 1.25rem;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
}

.import-history h4 {
  margin: 0 0 0.75rem;
  font-size: 0.95rem;
}

.import-history-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: 220px;
  overflow-y: auto;
}

.import-history-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.35rem 1rem;
  padding: 0.65rem 0.75rem;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--color-border, #eee);
  font-size: 0.85rem;
}

.import-history-item strong {
  grid-column: 1 / -1;
}

.import-history-meta {
  color: var(--color-muted, #6b7280);
}

.diff-you-unfollowed h4 { color: var(--color-warning, #b45309); }
.diff-you-followed h4 { color: var(--color-info, #0369a1); }

.diff-results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.diff-box {
  background: rgba(15, 23, 42, 0.5);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  padding: 1.25rem;
}

.diff-box h4 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.diff-lost h4 { color: var(--color-danger); }
.diff-gained h4 { color: var(--color-success); }

.diff-list {
  list-style: none;
  max-height: 350px;
  overflow-y: auto;
}

.diff-list li {
  padding: 0.6rem 0.8rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.86rem;
}

.diff-list li a {
  color: var(--text-main);
  text-decoration: none;
  font-weight: 600;
}

.diff-list li a:hover {
  color: var(--ig-primary);
  text-decoration: underline;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--text-dim);
}

.empty-state svg {
  margin-bottom: 1rem;
  opacity: 0.5;
}

.empty-state p {
  font-size: 0.95rem;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.8rem 1.4rem;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  font-weight: 600;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 9999;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* Responsive */
@media (max-width: 768px) {
  body {
    padding: 1rem 0.75rem;
  }
  .app-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .header-actions {
    width: 100%;
    justify-content: space-between;
  }
  .source-tabs {
    flex-direction: column;
  }
  .source-tab-btn {
    max-width: 100%;
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .table-controls {
    flex-direction: column;
    align-items: stretch;
  }
  .selector-arrow {
    display: none;
  }
}

/* Header Account Selector & User Pill */
.header-center {
  display: flex;
  align-items: center;
}

.account-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(225, 48, 108, 0.3);
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-md);
  box-shadow: 0 0 15px rgba(225, 48, 108, 0.1);
}

.account-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 600;
  white-space: nowrap;
}

.account-select {
  background: transparent;
  border: none;
  color: #fff;
  font-weight: 700;
  font-size: 0.88rem;
  font-family: inherit;
  cursor: pointer;
  outline: none;
}

.account-select option {
  background: var(--bg-input);
  color: var(--text-main);
}

.btn-account-add {
  background: rgba(225, 48, 108, 0.15);
  border: 1px solid rgba(225, 48, 108, 0.3);
  color: #fff;
  width: 26px;
  height: 26px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.btn-account-add:hover {
  background: var(--ig-gradient);
  transform: scale(1.05);
}

.user-pill {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-md);
}

.user-avatar {
  font-size: 0.9rem;
}

.user-name {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-main);
}

.btn-logout {
  background: transparent;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.2rem;
  border-radius: 4px;
  transition: var(--transition);
}

.btn-logout:hover {
  color: var(--color-danger);
}

/* Modals */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 1.5rem;
}

.modal-card {
  background: #111827;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  padding: 2rem;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
  position: relative;
  animation: modalFadeIn 0.2s ease-out;
}

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

.modal-close {
  position: absolute;
  top: 1rem;
  right: 1.2rem;
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
}

.modal-close:hover {
  color: var(--text-main);
}

.modal-header {
  margin-bottom: 1.5rem;
}

.modal-header h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
}

.modal-header p {
  color: var(--text-muted);
  font-size: 0.84rem;
}

.modal-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 1.5rem;
  gap: 1rem;
}

.modal-tab {
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.5rem 0.2rem;
  cursor: pointer;
  font-family: inherit;
  transition: var(--transition);
}

.modal-tab.active {
  color: #fff;
  border-bottom-color: var(--ig-primary);
}
/* Append Landing Page Styles */
.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  transition: var(--transition);
}

.nav-links a:hover {
  color: var(--text-main);
}

/* Hero Section */
.hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 4rem 1rem 5rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(225, 48, 108, 0.1);
  border: 1px solid rgba(225, 48, 108, 0.3);
  padding: 0.45rem 1.1rem;
  border-radius: 30px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 2rem;
  box-shadow: 0 0 20px rgba(225, 48, 108, 0.15);
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 10px #10b981;
  animation: pulseGreen 2s infinite;
}

@keyframes pulseGreen {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.hero-title {
  font-size: 3.4rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 1.4rem;
  max-width: 880px;
}

.gradient-text {
  background: var(--ig-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 700px;
  margin-bottom: 2.5rem;
  line-height: 1.65;
}

.hero-cta-group {
  display: flex;
  gap: 1.25rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 2.8rem;
}

.btn-lg {
  padding: 0.85rem 1.8rem;
  font-size: 1rem;
  border-radius: var(--radius-md);
}

.hero-trust-strip {
  display: flex;
  gap: 2.5rem;
  justify-content: center;
  flex-wrap: wrap;
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 500;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.trust-item svg {
  color: var(--ig-primary);
}

/* Interactive Hero Mockup */
.hero-mockup-wrapper {
  position: relative;
  width: 100%;
  max-width: 900px;
  margin-top: 4rem;
}

.mockup-glow {
  position: absolute;
  inset: -30px;
  background: radial-gradient(ellipse at center, rgba(225, 48, 108, 0.22) 0%, rgba(188, 24, 136, 0.08) 45%, transparent 70%);
  filter: blur(50px);
  z-index: 0;
  pointer-events: none;
}

.hero-mockup {
  position: relative;
  z-index: 1;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.8);
}

.mockup-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--border-color);
}

.mockup-dots {
  display: flex;
  gap: 6px;
}

.mockup-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.mockup-dots span:nth-child(1) { background: #ef4444; }
.mockup-dots span:nth-child(2) { background: #f59e0b; }
.mockup-dots span:nth-child(3) { background: #10b981; }

.mockup-address {
  font-size: 0.76rem;
  color: var(--text-dim);
  font-family: monospace;
  background: rgba(0, 0, 0, 0.3);
  padding: 0.2rem 0.8rem;
  border-radius: 6px;
}

.mockup-badge {
  font-size: 0.7rem;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  font-weight: 600;
}

.mockup-content {
  padding: 1.8rem;
}

.mockup-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.mockup-stat-card {
  padding: 1.1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  text-align: left;
}

.mockup-stat-card.danger {
  background: rgba(244, 63, 94, 0.08);
  border-color: rgba(244, 63, 94, 0.2);
}

.mockup-stat-card.success {
  background: rgba(16, 185, 129, 0.08);
  border-color: rgba(16, 185, 129, 0.2);
}

.mockup-stat-card.info {
  background: rgba(14, 165, 233, 0.08);
  border-color: rgba(14, 165, 233, 0.2);
}

.mstat-title {
  font-size: 0.76rem;
  color: var(--text-muted);
  font-weight: 600;
}

.mstat-val {
  font-size: 1.7rem;
  font-weight: 800;
  margin: 0.2rem 0;
}

.mockup-stat-card.danger .mstat-val { color: var(--color-danger); }
.mockup-stat-card.success .mstat-val { color: var(--color-success); }
.mockup-stat-card.info .mstat-val { color: var(--color-info); }

.mstat-sub {
  font-size: 0.72rem;
  color: var(--text-dim);
}

.mockup-rows {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.mockup-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
}

.mockup-user {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.mockup-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
}

.mockup-uname {
  font-size: 0.85rem;
  font-weight: 700;
  text-align: left;
}

.mockup-sub {
  font-size: 0.72rem;
  color: var(--text-dim);
  text-align: left;
}

.m-badge-danger {
  font-size: 0.72rem;
  background: var(--color-danger-bg);
  color: var(--color-danger);
  padding: 0.25rem 0.65rem;
  border-radius: 12px;
  font-weight: 600;
}

.m-badge-success {
  font-size: 0.72rem;
  background: var(--color-success-bg);
  color: var(--color-success);
  padding: 0.25rem 0.65rem;
  border-radius: 12px;
  font-weight: 600;
}

/* Landing Section */
.landing-section {
  padding: 5rem 0;
  text-align: center;
}

.section-badge {
  color: var(--ig-primary);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
}

.section-heading {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 0.8rem;
  letter-spacing: -0.02em;
}

.section-subtext {
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto 3rem;
  font-size: 1rem;
  line-height: 1.6;
}

/* Feature Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  text-align: left;
}

.feature-card {
  padding: 2.2rem;
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-6px);
  border-color: rgba(225, 48, 108, 0.35);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
}

.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.feature-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.feature-card p {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.6;
}

/* Steps Grid */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  text-align: left;
}

.step-card {
  padding: 2.2rem;
  position: relative;
}

.step-number {
  font-size: 2.6rem;
  font-weight: 900;
  background: var(--ig-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.75rem;
  line-height: 1;
}

.step-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.step-card p {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.6;
}

/* Security Banner */
.security-banner {
  margin: 4rem 0;
  padding: 2.5rem 3rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(15, 23, 42, 0.8) 100%);
  border: 1px solid rgba(16, 185, 129, 0.3);
  text-align: left;
}

.security-icon-wrap {
  color: var(--color-success);
  flex-shrink: 0;
}

.security-content {
  flex: 1;
  min-width: 280px;
}

.security-content h3 {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.security-content p {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* Landing Footer */
.landing-footer {
  padding: 3rem 0 1rem;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
  border-top: 1px solid var(--border-color);
  margin-top: 4rem;
}

/* Cookie Helper Box */
.cookie-helper-box {
  background: rgba(14, 165, 233, 0.08);
  border: 1px solid rgba(14, 165, 233, 0.25);
  border-radius: var(--radius-md);
  padding: 0.9rem 1.1rem;
  margin-bottom: 0.75rem;
}

.cookie-helper-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 0.4rem;
}

.cookie-badge {
  font-size: 0.82rem;
  font-weight: 700;
  color: #38bdf8;
}

.btn-copy-code {
  background: rgba(14, 165, 233, 0.2);
  color: #bae6fd;
  border: 1px solid rgba(14, 165, 233, 0.4);
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.btn-copy-code:hover {
  background: rgba(14, 165, 233, 0.35);
  color: #fff;
}

.cookie-helper-text {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.cookie-helper-text code {
  background: rgba(0, 0, 0, 0.3);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  color: #f43f5e;
  font-size: 0.82rem;
}

/* Checkpoint Verification Box */
.checkpoint-verification-box {
  margin-top: 1.5rem;
  padding: 1.5rem;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.12) 0%, rgba(18, 25, 41, 0.95) 100%);
  border: 1px solid rgba(245, 158, 11, 0.4);
  box-shadow: 0 8px 25px rgba(245, 158, 11, 0.15);
  animation: fadeIn 0.3s ease;
}

.checkpoint-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.checkpoint-icon {
  font-size: 2rem;
  background: rgba(245, 158, 11, 0.2);
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.checkpoint-header h4 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #f59e0b;
  margin-bottom: 0.3rem;
}

.checkpoint-header p {
  font-size: 0.88rem;
  color: var(--text-main);
  line-height: 1.5;
}

.checkpoint-form-row {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.checkpoint-form-row input {
  flex: 1;
  min-width: 180px;
}

.checkpoint-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 1rem;
}

/* Responsive adjustments */
@media (max-width: 900px) {
  .hero-title {
    font-size: 2.6rem;
  }
  .mockup-stats-grid {
    grid-template-columns: 1fr;
  }
  .nav-links {
    display: none;
  }
}
