:root {
  --bg-base: #07090e;
  --bg-card: rgba(16, 20, 30, 0.72);
  --bg-card-hover: rgba(22, 28, 42, 0.85);
  --bg-input: #0c0f17;
  --bg-input-focus: #10141f;

  --stroke-subtle: rgba(255, 255, 255, 0.08);
  --stroke-card: rgba(255, 255, 255, 0.12);
  --stroke-hover: rgba(99, 102, 241, 0.4);

  --text-main: #f3f4f6;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;

  --accent-primary: #6366f1;
  --accent-primary-hover: #797cf8;
  --accent-cyan: #06b6d4;
  --accent-emerald: #10b981;
  --accent-rose: #f43f5e;
  --accent-amber: #f59e0b;

  --glow-primary: rgba(99, 102, 241, 0.25);
  --glow-cyan: rgba(6, 182, 212, 0.2);
  --glow-emerald: rgba(16, 185, 129, 0.25);
  --glow-rose: rgba(244, 63, 94, 0.25);

  --font-sans: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, monospace;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-full: 9999px;

  --transition-fast: 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-normal: 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Global Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  min-height: 100vh;
  background-color: var(--bg-base);
  color: var(--text-main);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
}

/* Ambient Backdrops */
.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(140px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.45;
  animation: pulse-ambient 12s ease-in-out infinite alternate;
}
.bg-glow-1 {
  width: 500px;
  height: 500px;
  top: -100px;
  left: 15%;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.35) 0%, transparent 70%);
}
.bg-glow-2 {
  width: 600px;
  height: 600px;
  bottom: 5%;
  right: 5%;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.22) 0%, transparent 70%);
  animation-delay: -5s;
}
.bg-glow-3 {
  width: 450px;
  height: 450px;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(16, 185, 129, 0.15) 0%, transparent 70%);
  animation-delay: -9s;
}

@keyframes pulse-ambient {
  0% { transform: scale(1) translate(0, 0); opacity: 0.35; }
  50% { transform: scale(1.12) translate(20px, -20px); opacity: 0.5; }
  100% { transform: scale(0.95) translate(-15px, 15px); opacity: 0.35; }
}

/* App Layout */
.app-layout {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 24px 80px;
}

/* Header */
.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--stroke-subtle);
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(6, 182, 212, 0.2));
  border: 1px solid rgba(99, 102, 241, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #a5b4fc;
  box-shadow: 0 0 20px rgba(99, 102, 241, 0.25);
}
.brand-icon svg { width: 22px; height: 22px; }

.brand-title {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  background: linear-gradient(135deg, #ffffff 30%, #c7d2fe 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  font-size: 0.82rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.badge-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.25);
  font-size: 0.82rem;
  font-weight: 600;
  color: #6ee7b7;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 10px #10b981;
  animation: pulse-ring 2s cubic-bezier(0.455, 0.03, 0.515, 0.955) infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Nav Tabs */
.nav-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0 auto 36px;
  background: rgba(14, 18, 27, 0.7);
  padding: 6px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--stroke-subtle);
  backdrop-filter: blur(12px);
  width: fit-content;
}

.nav-tab {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

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

.nav-tab.active {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.18), rgba(6, 182, 212, 0.12));
  color: #ffffff;
  border-color: rgba(99, 102, 241, 0.35);
  box-shadow: 0 4px 18px rgba(99, 102, 241, 0.15);
}

.tab-icon {
  width: 17px;
  height: 17px;
  opacity: 0.85;
}

.tab-pill {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: rgba(99, 102, 241, 0.3);
  color: #c7d2fe;
  text-transform: uppercase;
}

/* Tab Panels */
.tab-panel {
  display: none;
  animation: panel-fade 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

@keyframes panel-fade {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Glass Cards */
.glass-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--stroke-card);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  padding: 32px;
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.card-glow {
  position: absolute;
  top: -80px;
  right: -80px;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.15), transparent 70%);
  pointer-events: none;
}

/* Single Wizard View */
.single-wizard-card {
  max-width: 820px;
  margin: 0 auto;
  padding: 40px;
  width: 100%;
}

/* Stepper */
.wizard-stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 36px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--stroke-subtle);
}

.w-step {
  display: flex;
  align-items: center;
  gap: 12px;
  opacity: 0.45;
  transition: all var(--transition-normal);
}

.w-step.active {
  opacity: 1;
}

.w-step.completed {
  opacity: 1;
}

.w-step-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--stroke-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
  transition: all var(--transition-normal);
}

.w-step.active .w-step-num {
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #ffffff;
  border-color: #6366f1;
  box-shadow: 0 0 15px rgba(99, 102, 241, 0.4);
}

.w-step.completed .w-step-num {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.4);
}

.w-step-text {
  display: flex;
  flex-direction: column;
}

.w-step-sub {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}

.w-step-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: #ffffff;
}

.w-divider {
  flex: 1;
  height: 2px;
  background: rgba(255, 255, 255, 0.06);
  margin: 0 16px;
  border-radius: var(--radius-full);
  transition: background 0.3s ease;
}

.w-divider.active {
  background: linear-gradient(90deg, #6366f1, rgba(6, 182, 212, 0.5));
}

/* Wizard Panes */
.wizard-pane {
  animation: panel-fade 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.verified-key-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.28);
  border-radius: var(--radius-md);
  padding: 12px 18px;
  margin-bottom: 24px;
}

.vkb-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.vkb-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #10b981;
}
.vkb-icon svg { width: 16px; height: 16px; }

.vkb-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #6ee7b7;
  letter-spacing: 0.06em;
}

.vkb-code {
  font-size: 0.95rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.08em;
}

.wizard-actions {
  margin-top: 28px;
  display: flex;
  justify-content: center;
}
.wizard-actions .btn {
  max-width: 320px;
}

.wizard-actions-split {
  margin-top: 24px;
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 14px;
}

.step-badge-alt {
  background: rgba(6, 182, 212, 0.15) !important;
  color: #38bdf8 !important;
  border-color: rgba(6, 182, 212, 0.3) !important;
}

.single-info-box {
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--stroke-subtle);
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

.info-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

.info-item svg {
  width: 17px;
  height: 17px;
  color: #10b981;
  flex-shrink: 0;
  margin-top: 2px;
}

.flow-step {
  transition: all var(--transition-normal);
}

.step-header {
  text-align: center;
  margin-bottom: 24px;
}

.step-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: rgba(99, 102, 241, 0.15);
  color: #a5b4fc;
  border: 1px solid rgba(99, 102, 241, 0.3);
}

.step-header h3 {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: #ffffff;
}

.step-header p {
  color: var(--text-secondary);
  font-size: 0.9rem;
}



/* Form Controls */
.form-group {
  margin-bottom: 18px;
}

label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 7px;
  letter-spacing: 0.02em;
}

.label-with-action, .label-with-count {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 7px;
}

.label-with-action label, .label-with-count label {
  margin-bottom: 0;
}

.helper-link {
  font-size: 0.78rem;
  color: #a5b4fc;
  text-decoration: none;
  font-weight: 600;
  transition: color var(--transition-fast);
}
.helper-link:hover { color: #ffffff; text-decoration: underline; }

.count-badge {
  font-size: 0.74rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  background: rgba(255, 255, 255, 0.05);
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 14px;
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  pointer-events: none;
}

.input, .textarea {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--stroke-subtle);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  padding: 13px 14px;
  outline: none;
  transition: all var(--transition-fast);
}

.input.with-icon {
  padding-left: 42px;
}

.input:focus, .textarea:focus {
  background: var(--bg-input-focus);
  border-color: rgba(99, 102, 241, 0.6);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15), 0 0 20px rgba(99, 102, 241, 0.1);
}

.input.mono, .textarea.mono {
  font-family: var(--font-mono);
}

.code-input-wrap {
  max-width: 340px;
  margin: 0 auto;
}

.code-input {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-align: center;
  text-transform: uppercase;
  padding: 16px;
  border-radius: var(--radius-md);
}

.btn-input-action {
  position: absolute;
  right: 10px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--transition-fast);
}
.btn-input-action:hover { color: var(--text-main); background: rgba(255, 255, 255, 0.05); }
.btn-input-action svg { width: 18px; height: 18px; }

.btn-toggle-pwd {
  position: absolute;
  right: 12px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--transition-fast);
}
.btn-toggle-pwd:hover { color: var(--text-main); }
.btn-toggle-pwd svg { width: 18px; height: 18px; }

.field-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 6px;
  line-height: 1.4;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 20px;
  border-radius: var(--radius-md);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
}

.btn svg { width: 18px; height: 18px; }

.btn-primary {
  background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
  color: #ffffff;
  box-shadow: 0 4px 18px rgba(99, 102, 241, 0.35);
}
.btn-primary:hover {
  background: linear-gradient(135deg, #7174fa 0%, #5b53f0 100%);
  box-shadow: 0 6px 24px rgba(99, 102, 241, 0.45);
  transform: translateY(-1px);
}
.btn-primary:active { transform: translateY(0); }

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

.btn-outline {
  background: transparent;
  border: 1px solid var(--stroke-card);
  color: var(--text-secondary);
}
.btn-outline:hover {
  border-color: rgba(255, 255, 255, 0.3);
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.03);
}

.btn-accent {
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.35);
  color: #c7d2fe;
}
.btn-accent:hover {
  background: rgba(99, 102, 241, 0.25);
  border-color: rgba(99, 102, 241, 0.55);
}

.btn-sm {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}
.btn-sm svg { width: 14px; height: 14px; }

.btn-link {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  margin-top: 14px;
  transition: color var(--transition-fast);
}
.btn-link:hover { color: #ffffff; }

.btn:disabled, .btn-sm:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

/* Feedback message box */
.msg-box {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  background: rgba(244, 63, 94, 0.1);
  color: #fda4af;
  border: 1px solid rgba(244, 63, 94, 0.25);
  text-align: center;
}
.msg-box.ok {
  background: rgba(16, 185, 129, 0.1);
  color: #a7f3d0;
  border-color: rgba(16, 185, 129, 0.25);
}

/* Orbital Spinner & Job Running State */
.job-status-container {
  text-align: center;
  padding: 24px 0 10px;
}

.spinner-orbital {
  position: relative;
  width: 90px;
  height: 90px;
  margin: 0 auto 24px;
}

.orbital-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid transparent;
}

.ring-1 {
  border-top-color: #6366f1;
  border-right-color: rgba(99, 102, 241, 0.2);
  animation: spin 1.2s cubic-bezier(0.68, -0.55, 0.27, 1.55) infinite;
}

.ring-2 {
  inset: 10px;
  border-bottom-color: #06b6d4;
  border-left-color: rgba(6, 182, 212, 0.2);
  animation: spin-reverse 1.6s cubic-bezier(0.68, -0.55, 0.27, 1.55) infinite;
}

.orbital-core {
  position: absolute;
  inset: 24px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.3), transparent 70%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #a5b4fc;
  animation: pulse-core 2s ease-in-out infinite;
}
.orbital-core svg { width: 20px; height: 20px; }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes spin-reverse { to { transform: rotate(-360deg); } }
@keyframes pulse-core {
  0%, 100% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.1); opacity: 1; }
}

.stage-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 4px;
}

.stage-sub {
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: #a5b4fc;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.progress-bar-wrap {
  margin: 20px auto 14px;
  height: 5px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-full);
  overflow: hidden;
  max-width: 320px;
}

.progress-bar-fill {
  height: 100%;
  width: 45%;
  background: linear-gradient(90deg, #6366f1, #06b6d4);
  border-radius: inherit;
  animation: shimmer-slide 1.5s ease-in-out infinite;
}

@keyframes shimmer-slide {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(250%); }
}

.job-hint {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* Result States (Success / Fail) */
.result-state {
  text-align: center;
  padding: 10px 0;
}

.result-icon-wrap {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.result-icon-wrap svg { width: 32px; height: 32px; }

.result-icon-wrap.success {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #10b981;
  box-shadow: 0 0 30px rgba(16, 185, 129, 0.25);
}

.result-icon-wrap.fail {
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.35);
  color: #f43f5e;
  box-shadow: 0 0 30px rgba(244, 63, 94, 0.25);
}

.success-chip, .fail-chip {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  margin-bottom: 12px;
}
.success-chip {
  background: rgba(16, 185, 129, 0.12);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}
.fail-chip {
  background: rgba(244, 63, 94, 0.12);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.3);
}

.result-state h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: #ffffff;
}

.result-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.claim-url-box {
  background: #090c13;
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 20px;
  text-align: left;
  box-shadow: 0 0 25px rgba(99, 102, 241, 0.12);
}

.url-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 6px;
}

.url-value {
  font-size: 0.86rem;
  color: #a5b4fc;
  word-break: break-all;
  line-height: 1.45;
  user-select: all;
}

.result-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.error-detail-card {
  background: rgba(244, 63, 94, 0.08);
  border: 1px solid rgba(244, 63, 94, 0.25);
  border-radius: var(--radius-md);
  padding: 14px;
  color: #fda4af;
  font-size: 0.85rem;
  word-break: break-word;
  margin-bottom: 20px;
}

.fail-tip {
  text-align: left;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--stroke-subtle);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin-bottom: 20px;
  font-size: 0.84rem;
  color: var(--text-secondary);
}
.fail-tip strong { color: var(--text-main); }
.fail-tip ul { margin-left: 20px; margin-top: 6px; }
.fail-tip li { margin-bottom: 4px; }

/* ================= BATCH VIEW ================= */
.batch-layout {
  display: grid;
  grid-template-columns: 420px 1fr;
  gap: 24px;
  align-items: start;
}

.section-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.icon-chip {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #a5b4fc;
}
.icon-chip svg { width: 20px; height: 20px; }

.section-title-wrap h3 { font-size: 1.15rem; font-weight: 700; color: #ffffff; }
.section-title-wrap p { font-size: 0.8rem; color: var(--text-secondary); }

.format-callout {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--stroke-subtle);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  margin-bottom: 18px;
}

.callout-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 5px;
}

.callout-code {
  font-size: 0.78rem;
  color: #93c5fd;
  margin-bottom: 2px;
}

.textarea {
  resize: vertical;
  line-height: 1.5;
  font-size: 0.84rem;
}

.batch-actions-row {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 10px;
  margin-top: 6px;
}

/* Batch Monitor */
.monitor-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.monitor-header h3 { font-size: 1.15rem; font-weight: 700; color: #ffffff; }
.monitor-header p { font-size: 0.8rem; color: var(--text-secondary); }

.export-btn-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 18px;
}

.stat-pill {
  background: rgba(14, 18, 27, 0.6);
  border: 1px solid var(--stroke-subtle);
  border-radius: var(--radius-md);
  padding: 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.stat-num {
  font-size: 1.35rem;
  font-weight: 800;
  font-family: var(--font-mono);
}

.stat-label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.stat-total .stat-num { color: #f3f4f6; }
.stat-running .stat-num { color: #38bdf8; }
.stat-success .stat-num { color: #34d399; }
.stat-fail .stat-num { color: #fb7185; }

.batch-progress-wrapper {
  height: 6px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-full);
  margin-bottom: 20px;
  overflow: hidden;
}

.batch-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #6366f1, #06b6d4, #10b981);
  transition: width 0.3s ease;
}

.batch-table-container {
  max-height: 480px;
  overflow-y: auto;
  border: 1px solid var(--stroke-subtle);
  border-radius: var(--radius-md);
  background: rgba(12, 15, 23, 0.6);
}

.batch-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
  text-align: left;
}

.batch-table th {
  position: sticky;
  top: 0;
  background: #111520;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 10px 14px;
  border-bottom: 1px solid var(--stroke-subtle);
  z-index: 2;
}

.batch-table td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  color: var(--text-main);
  vertical-align: middle;
}

.batch-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.batch-table .empty-row td {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
}

.status-badge.queued {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
}
.status-badge.running {
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.3);
}
.status-badge.success {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}
.status-badge.failed {
  background: rgba(244, 63, 94, 0.15);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.3);
}

.status-badge.running::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #38bdf8;
  animation: pulse-ring 1.5s infinite;
}

.file-saved-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  padding: 10px 14px;
  background: rgba(16, 185, 129, 0.06);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: var(--radius-md);
  font-size: 0.8rem;
  color: #a7f3d0;
}
.file-saved-banner svg { width: 18px; height: 18px; flex-shrink: 0; color: #10b981; }
.file-saved-banner code { font-family: var(--font-mono); font-weight: 600; color: #ffffff; }

/* ================= GUIDE & INSTRUCTIONS VIEW ================= */
.guide-container {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.guide-hero {
  padding: 36px;
}

.hero-chip {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: #a5b4fc;
  margin-bottom: 12px;
}

.guide-hero h2 {
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 8px;
  color: #ffffff;
}

.guide-hero p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 800px;
  margin-bottom: 20px;
}

.alert-box {
  display: flex;
  gap: 14px;
  padding: 16px;
  border-radius: var(--radius-md);
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.3);
  color: #fde68a;
  font-size: 0.9rem;
}

.alert-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  color: #f59e0b;
}

/* Guide Sections */
.guide-section {
  padding: 30px;
}

.section-badge-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.num-badge {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 800;
  color: #6366f1;
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.35);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
}

.section-badge-header h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #ffffff;
}

.section-desc {
  color: var(--text-secondary);
  font-size: 0.92rem;
  margin-bottom: 20px;
}

/* Requirements Grid */
.req-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}

.req-item {
  display: flex;
  gap: 14px;
  padding: 16px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--stroke-subtle);
  transition: border-color var(--transition-fast);
}
.req-item:hover { border-color: rgba(255, 255, 255, 0.15); }

.req-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.req-item.danger .req-icon {
  background: rgba(244, 63, 94, 0.18);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.35);
}

.req-item.info .req-icon {
  background: rgba(6, 182, 212, 0.18);
  color: #38bdf8;
  border: 1px solid rgba(6, 182, 212, 0.35);
}

.req-text {
  font-size: 0.88rem;
  color: var(--text-main);
  line-height: 1.45;
}

/* Section 02 Intro & Sub-steps */
.guide-intro-note {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--stroke-subtle);
  border-radius: var(--radius-md);
  padding: 18px;
  margin-bottom: 24px;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}
.guide-intro-note strong { color: #ffffff; }

.highlight-warn {
  margin-top: 10px;
  color: #fde68a !important;
  font-weight: 500;
}

.sub-step-block {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--stroke-subtle);
}

.sub-step-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}

.sub-step-num {
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  background: rgba(6, 182, 212, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(6, 182, 212, 0.3);
}

.sub-step-title h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffffff;
}

.step-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.step-list li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.step-num-pill {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--stroke-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 700;
  color: #a5b4fc;
  flex-shrink: 0;
  margin-top: 2px;
}

.step-body {
  flex: 1;
}

.step-body p {
  color: var(--text-main);
  font-size: 0.9rem;
  margin-bottom: 8px;
  line-height: 1.5;
}
.step-body strong { color: #ffffff; }

.guide-external-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: #a5b4fc;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  margin-top: 4px;
  transition: all var(--transition-fast);
}
.guide-external-btn:hover {
  background: rgba(99, 102, 241, 0.22);
  color: #ffffff;
  border-color: rgba(99, 102, 241, 0.5);
}
.guide-external-btn svg { width: 14px; height: 14px; }

/* Comparison row */
.comparison-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin: 12px 0 6px;
}

.comparison-card {
  padding: 14px;
  border-radius: var(--radius-md);
  background: rgba(10, 14, 22, 0.7);
  border: 1px solid var(--stroke-subtle);
}

.comparison-card.correct {
  border-color: rgba(16, 185, 129, 0.35);
  background: rgba(16, 185, 129, 0.05);
}

.comparison-card.wrong {
  border-color: rgba(244, 63, 94, 0.35);
  background: rgba(244, 63, 94, 0.05);
}

.comp-badge {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 6px;
}
.comparison-card.correct .comp-badge { color: #34d399; }
.comparison-card.wrong .comp-badge { color: #fb7185; }

.comp-val {
  font-size: 0.82rem;
  word-break: break-all;
  color: #ffffff;
  margin-bottom: 4px;
}
.comp-val.wrong-text {
  text-decoration: line-through;
  opacity: 0.75;
}

.comp-hint {
  font-size: 0.74rem;
  color: var(--text-muted);
}

/* Tool link card */
.tool-link-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: rgba(10, 14, 22, 0.7);
  border: 1px solid rgba(6, 182, 212, 0.25);
  margin-top: 8px;
}

.tool-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: rgba(6, 182, 212, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #38bdf8;
  flex-shrink: 0;
}
.tool-icon svg { width: 18px; height: 18px; }

.tool-content {
  flex: 1;
}

.tool-url {
  font-size: 0.86rem;
  color: #ffffff;
  margin-bottom: 2px;
}
.tool-url .highlight { color: #38bdf8; font-weight: 700; }

.tool-example {
  font-size: 0.76rem;
  color: var(--text-muted);
}
.tool-example a { color: #a5b4fc; text-decoration: underline; }

.warning-callout {
  margin-top: 10px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.25);
  font-size: 0.84rem;
  color: #fde68a;
  line-height: 1.45;
}

/* Toast Container */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  background: rgba(18, 24, 38, 0.95);
  border: 1px solid var(--stroke-card);
  color: #ffffff;
  font-size: 0.88rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(16px);
  animation: toast-in 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.toast.toast-success {
  border-color: rgba(16, 185, 129, 0.4);
}
.toast.toast-success svg { color: #10b981; }

.toast.toast-error {
  border-color: rgba(244, 63, 94, 0.4);
}
.toast.toast-error svg { color: #f43f5e; }

@keyframes toast-in {
  from { opacity: 0; transform: translateY(12px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Responsive adjustments */
@media (max-width: 900px) {
  .single-layout {
    grid-template-columns: 1fr;
  }
  .batch-layout {
    grid-template-columns: 1fr;
  }
  .app-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }
  .comparison-row {
    grid-template-columns: 1fr;
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .tool-link-card {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 600px) {
  .app-layout { padding: 20px 14px 60px; }
  .glass-card { padding: 20px 16px; }
  .nav-tabs { width: 100%; overflow-x: auto; }
  .nav-tab { padding: 8px 12px; font-size: 0.85rem; }
  .result-actions { grid-template-columns: 1fr; }
}
