/* =============================================================================
   realtime-mobile.css — Mobile UI styles for redditstyle.html (Realtime Mode)
   Follows the same colour scheme as overnight-mobile.css / mobile.css
   Only active when #mobile-realtime-ui is displayed (≤ 768px)
   ============================================================================= */

/* ── Mobile Realtime Wrapper ─────────────────────────────────────────────── */
#mobile-realtime-ui {
  display: none;
  padding-top: 60px; /* space for fixed navbar */
}

/* ═══════════════════════════════════════════════════════════════════════════
   MOBILE HERO BANNER
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-hero {
  padding: 2rem 1.2rem 1.6rem;
  text-align: center;
  background: linear-gradient(180deg, #070c16 0%, #04060c 100%);
  border-bottom: 1px solid #1e2d45;
}

.mob-rt-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: #34d399;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.3rem 0.9rem;
  border-radius: 40px;
  margin-bottom: 1rem;
}

.mob-rt-hero h1 {
  font-size: 1.9rem;
  font-weight: 700;
  color: #f1f5f9;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 0.7rem;
}

.mob-rt-hero h1 span {
  color: #818cf8;
}

.mob-rt-hero p {
  font-size: 0.9rem;
  color: #8897b3;
  max-width: 340px;
  margin: 0 auto 1.2rem;
  line-height: 1.55;
}

.mob-rt-cta-row {
  display: flex;
  gap: 0.6rem;
  justify-content: center;
  flex-wrap: wrap;
}

.mob-rt-btn-primary {
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color: #fff;
  font-weight: 600;
  font-size: 0.88rem;
  padding: 0.65rem 1.4rem;
  border-radius: 60px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
  transition: transform 0.15s;
  border: none;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
}
.mob-rt-btn-primary:active { transform: scale(0.97); }
.mob-rt-btn-primary:disabled { opacity: 0.35; cursor: not-allowed; transform: none; }

.mob-rt-btn-ghost {
  background: transparent;
  border: 1.5px solid #4f46e5;
  color: #c7d2e8;
  font-weight: 600;
  font-size: 0.88rem;
  padding: 0.65rem 1.4rem;
  border-radius: 60px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: background 0.15s;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
}
.mob-rt-btn-ghost:active { background: rgba(99, 102, 241, 0.12); }

/* ═══════════════════════════════════════════════════════════════════════════
   STEP INDICATORS — Mobile horizontal pills
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-step-indicators {
  display: flex;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.8rem 1rem;
  background: #070c16;
  border-bottom: 1px solid #1e2d45;
  position: sticky;
  top: 60px;
  z-index: 50;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.mob-rt-step-pill {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.75rem;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #546180;
  font-size: 0.72rem;
  font-weight: 600;
  white-space: nowrap;
  transition: all 0.2s;
  cursor: pointer;
  flex-shrink: 0;
}

.mob-rt-step-pill.active {
  background: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.4);
  color: #818cf8;
}

.mob-rt-step-pill.completed {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.25);
  color: #34d399;
}

.mob-rt-step-pill .pill-num {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 700;
  flex-shrink: 0;
}

.mob-rt-step-pill.active .pill-num {
  background: rgba(99, 102, 241, 0.3);
}

.mob-rt-step-pill.completed .pill-num {
  background: rgba(16, 185, 129, 0.2);
}

/* ═══════════════════════════════════════════════════════════════════════════
   MOBILE FORM CARD — Shared wrapper
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-form-wrap {
  padding: 0.8rem 1rem 2rem;
}

.mob-rt-card {
  background: #111827;
  border: 1px solid #1e2d45;
  border-radius: 24px;
  overflow: hidden;
}

.mob-rt-card-header {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 1rem 1.2rem;
  border-bottom: 1px solid #1e2d45;
  background: #0d1421;
}

.mob-rt-card-icon {
  font-size: 1.4rem;
  line-height: 1;
}

.mob-rt-card-header h2 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #f1f5f9;
  margin: 0;
  line-height: 1.2;
}

.mob-rt-card-header p {
  font-size: 0.78rem;
  color: #8897b3;
  margin: 0;
}

.mob-rt-card-body {
  padding: 1rem 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   SHARED FORM ELEMENTS
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: #8897b3;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  display: block;
  margin-bottom: 0.3rem;
}

.mob-rt-textarea {
  width: 100%;
  background: #070c16;
  border: 1px solid #1e2d45;
  border-radius: 14px;
  color: #f1f5f9;
  font-size: 0.88rem;
  font-family: 'Inter', sans-serif;
  padding: 0.8rem 1rem;
  resize: vertical;
  min-height: 140px;
  transition: border-color 0.2s;
  line-height: 1.5;
  box-sizing: border-box;
}
.mob-rt-textarea:focus {
  outline: none;
  border-color: #4f46e5;
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.15);
}
.mob-rt-textarea::placeholder { color: #3f5070; }

.mob-rt-select {
  width: 100%;
  background: #070c16;
  border: 1px solid #1e2d45;
  border-radius: 10px;
  color: #c7d2e8;
  font-size: 0.82rem;
  font-family: 'Inter', sans-serif;
  padding: 0.55rem 0.7rem;
  cursor: pointer;
  transition: border-color 0.2s;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23546180'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.6rem center;
  padding-right: 1.8rem;
}
.mob-rt-select:focus { outline: none; border-color: #4f46e5; }

.mob-rt-select-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
}

.mob-rt-input {
  width: 100%;
  background: #070c16;
  border: 1px solid #1e2d45;
  border-radius: 10px;
  color: #f1f5f9;
  font-size: 0.82rem;
  font-family: 'Inter', sans-serif;
  padding: 0.55rem 0.7rem;
  transition: border-color 0.2s;
  box-sizing: border-box;
}
.mob-rt-input:focus { outline: none; border-color: #4f46e5; }

/* ── Char counter ── */
.mob-rt-char-counter {
  text-align: right;
  font-size: 0.72rem;
  color: #546180;
  font-weight: 500;
  margin-top: -0.4rem;
}
.mob-rt-char-counter.warn { color: #fbbf24; }
.mob-rt-char-counter.over { color: #f87171; }

/* ── Explicit warning ── */
.mob-rt-explicit-warning {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-radius: 12px;
  padding: 0.7rem 0.9rem;
  color: #fca5a5;
  font-size: 0.8rem;
  line-height: 1.5;
  display: none;
}

/* ── Rate limit info ── */
.mob-rt-rate-note {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 10px;
  font-size: 0.72rem;
  color: #a5b4fc;
}

/* ── Status message ── */
.mob-rt-status {
  display: none;
  padding: 0.65rem 0.9rem;
  border-radius: 12px;
  font-size: 0.82rem;
  text-align: center;
  line-height: 1.5;
}
.mob-rt-status.visible { display: block; }
.mob-rt-status.info    { background: rgba(99, 102, 241, 0.08); border: 1px solid rgba(99, 102, 241, 0.2); color: #a5b4fc; }
.mob-rt-status.success { background: rgba(16, 185, 129, 0.08); border: 1px solid rgba(16, 185, 129, 0.2); color: #34d399; }
.mob-rt-status.error   { background: rgba(239, 68, 68, 0.08); border: 1px solid rgba(239, 68, 68, 0.2); color: #f87171; }

/* ═══════════════════════════════════════════════════════════════════════════
   STEP CONTENT — Each step hidden/shown
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-step {
  display: none;
}
.mob-rt-step.active {
  display: block;
}

/* ── Action button rows ── */
.mob-rt-action-row {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-top: 0.5rem;
}

.mob-rt-action-row-h {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.mob-rt-btn-action {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 60px;
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: none;
  box-sizing: border-box;
}
.mob-rt-btn-action:disabled { opacity: 0.35; cursor: not-allowed; }
.mob-rt-btn-action:not(:disabled):active { transform: scale(0.98); }

.mob-rt-btn-action.primary {
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color: #fff;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
}

.mob-rt-btn-action.secondary {
  background: transparent;
  border: 1.5px solid #1e2d45;
  color: #c7d2e8;
}
.mob-rt-btn-action.secondary:not(:disabled):active {
  border-color: #4f46e5;
  background: rgba(99, 102, 241, 0.05);
}

.mob-rt-btn-action.danger {
  background: transparent;
  border: 1.5px solid rgba(239, 68, 68, 0.3);
  color: #f87171;
}

.mob-rt-btn-action.success {
  background: linear-gradient(135deg, #059669, #10b981);
  color: #fff;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.25);
}

.mob-rt-btn-action.warning {
  background: linear-gradient(135deg, #d97706, #f59e0b);
  color: #0a0800;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.25);
}

.mob-rt-btn-action.small {
  flex: 1;
  min-width: 0;
  padding: 0.55rem 0.8rem;
  font-size: 0.8rem;
}

/* ── Navigation buttons ── */
.mob-rt-nav-row {
  display: flex;
  justify-content: space-between;
  gap: 0.6rem;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  margin-top: 0.5rem;
}

.mob-rt-nav-btn {
  padding: 0.6rem 1.2rem;
  border-radius: 60px;
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.15s;
  white-space: nowrap;
}
.mob-rt-nav-btn:disabled { opacity: 0.35; cursor: not-allowed; }

.mob-rt-nav-btn.back {
  background: transparent;
  border: 1px solid #1e2d45;
  color: #8897b3;
}
.mob-rt-nav-btn.back:active { border-color: #4f46e5; color: #c7d2e8; }

.mob-rt-nav-btn.next {
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  border: none;
  color: #fff;
  box-shadow: 0 3px 10px rgba(99, 102, 241, 0.25);
  margin-left: auto;
}

/* ═══════════════════════════════════════════════════════════════════════════
   STEP 1 — SCRIPT
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-script-tools {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.mob-rt-tool-btn {
  flex: 1;
  min-width: 100px;
  padding: 0.5rem 0.75rem;
  border-radius: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: #8897b3;
  transition: all 0.15s;
}
.mob-rt-tool-btn:active {
  background: rgba(99, 102, 241, 0.1);
  border-color: rgba(99, 102, 241, 0.3);
  color: #a5b4fc;
}

.mob-rt-tool-btn.clean {
  border-color: rgba(99, 102, 241, 0.2);
  color: #818cf8;
}
.mob-rt-tool-btn.remove-bad {
  border-color: rgba(239, 68, 68, 0.2);
  color: #f87171;
}

/* ═══════════════════════════════════════════════════════════════════════════
   STEP 2 — VOICE + ALIGNMENT
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-voice-section {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.mob-rt-speed-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.mob-rt-speed-row input[type="range"] {
  flex: 1;
  accent-color: #6366f1;
  background: transparent;
  border: none;
  padding: 0;
}

.mob-rt-speed-val {
  font-family: monospace;
  font-size: 0.88rem;
  font-weight: 700;
  color: #818cf8;
  min-width: 3ch;
  text-align: right;
}

/* Audio player */
.mob-rt-audio-box {
  background: #070c16;
  border: 1px solid #1e2d45;
  border-radius: 14px;
  padding: 0.8rem;
}

.mob-rt-audio-box audio {
  width: 100%;
  border-radius: 8px;
  display: block;
}

/* Aligner picker */
.mob-rt-aligner-section {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(59, 130, 246, 0.15);
  border-radius: 16px;
  padding: 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.mob-rt-aligner-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: #818cf8;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.mob-rt-aligner-cards {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mob-rt-aligner-card {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
  padding: 0.75rem;
  border-radius: 14px;
  border: 1.5px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  cursor: pointer;
  transition: all 0.15s;
}
.mob-rt-aligner-card:active,
.mob-rt-aligner-card.active {
  border-color: rgba(99, 102, 241, 0.5);
  background: rgba(99, 102, 241, 0.08);
}

.mob-rt-aligner-card input[type="radio"] {
  display: none;
}

.mob-rt-aligner-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  color: #818cf8;
  flex-shrink: 0;
}
.mob-rt-aligner-card.active .mob-rt-aligner-icon {
  background: rgba(99, 102, 241, 0.25);
  color: #fff;
}

.mob-rt-aligner-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: #f1f5f9;
}

.mob-rt-aligner-desc {
  font-size: 0.7rem;
  color: #546180;
  line-height: 1.4;
  margin-top: 0.15rem;
}

.mob-rt-aligner-tags {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
  margin-top: 0.3rem;
}

.mob-rt-aligner-tag {
  font-size: 0.58rem;
  font-weight: 700;
  padding: 0.1rem 0.4rem;
  border-radius: 30px;
  text-transform: uppercase;
}
.mob-rt-aligner-tag.green  { background: rgba(34,197,94,0.1);  color: #4ade80; border: 1px solid rgba(34,197,94,0.3); }
.mob-rt-aligner-tag.blue   { background: rgba(59,130,246,0.1); color: #818cf8; border: 1px solid rgba(59,130,246,0.3); }
.mob-rt-aligner-tag.purple { background: rgba(168,85,247,0.1); color: #c084fc; border: 1px solid rgba(168,85,247,0.3); }
.mob-rt-aligner-tag.yellow { background: rgba(251,191,36,0.1); color: #f59e0b; border: 1px solid rgba(251,191,36,0.3); }
.mob-rt-aligner-tag.gray   { background: rgba(100,116,139,0.12); color: #8897b3; border: 1px solid rgba(100,116,139,0.3); }

/* Pass toggle for Qwen */
.mob-rt-pass-row {
  display: none;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 0.75rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 10px;
  flex-wrap: wrap;
}
.mob-rt-pass-row.visible { display: flex; }

.mob-rt-pass-toggle {
  display: flex;
  gap: 0.3rem;
}

.mob-rt-pass-btn {
  padding: 0.35rem 0.65rem;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: #8897b3;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  font-family: 'Inter', sans-serif;
}
.mob-rt-pass-btn.active {
  background: rgba(99, 102, 241, 0.15);
  border-color: #6366f1;
  color: #818cf8;
}

.mob-rt-pass-hint {
  font-size: 0.68rem;
  color: #546180;
  font-style: italic;
}

/* Pipeline status bars (mobile-friendly) */
.mob-rt-pipeline-bars {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   STEP 2.5 — SUBTITLE STYLE (simplified for mobile)
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-sub-section {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mob-rt-sub-heading {
  font-size: 0.78rem;
  font-weight: 700;
  color: #f59e0b;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* Mode tabs */
.mob-rt-mode-tabs {
  display: flex;
  gap: 0.35rem;
}

.mob-rt-mode-tab {
  flex: 1;
  padding: 0.45rem 0.5rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: #8897b3;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
  font-family: 'Inter', sans-serif;
}
.mob-rt-mode-tab:active,
.mob-rt-mode-tab.active {
  background: rgba(245, 158, 11, 0.15);
  border-color: #f59e0b;
  color: #f59e0b;
}

/* Style panel */
.mob-rt-style-panel {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.mob-rt-style-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
}

.mob-rt-style-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.mob-rt-style-field.full {
  grid-column: 1 / -1;
}

.mob-rt-style-field label {
  font-size: 0.68rem;
  font-weight: 600;
  color: #546180;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Pill toggles */
.mob-rt-pill-toggle {
  display: flex;
  gap: 0.25rem;
}

.mob-rt-pill-btn {
  flex: 1;
  padding: 0.3rem 0.4rem;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: #8897b3;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
  font-family: 'Inter', sans-serif;
}
.mob-rt-pill-btn.active {
  background: rgba(245, 158, 11, 0.15);
  border-color: #f59e0b;
  color: #f59e0b;
}

/* Colour rows */
.mob-rt-colour-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.mob-rt-colour-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex: 1;
  min-width: 0;
}

.mob-rt-colour-swatch {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.15);
  flex-shrink: 0;
}

.mob-rt-colour-hex {
  font-size: 0.75rem;
  font-family: monospace;
  color: #c7d2e8;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mob-rt-colour-pick-btn {
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.25);
  color: #818cf8;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.25rem 0.55rem;
  border-radius: 20px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  white-space: nowrap;
  transition: background 0.15s;
  flex-shrink: 0;
  font-family: 'Inter', sans-serif;
}
.mob-rt-colour-pick-btn:active { background: rgba(99, 102, 241, 0.2); }

/* Live preview */
.mob-rt-preview-chip-wrap {
  background: #04060c;
  border-radius: 12px;
  border: 1px solid #1e2d45;
  padding: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
}

.mob-rt-preview-chip {
  font-size: 1.2rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  text-align: center;
  line-height: 1.2;
  transition: font-family 0.15s, color 0.15s;
  user-select: none;
}

/* Slider row */
.mob-rt-slider-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.mob-rt-slider-row input[type="range"] {
  flex: 1;
  accent-color: #f59e0b;
  background: transparent;
  border: none;
  padding: 0;
}

.mob-rt-slider-val {
  font-family: monospace;
  font-size: 0.8rem;
  color: #f59e0b;
  font-weight: 700;
  min-width: 2.5ch;
  text-align: right;
}

/* ── Colour Pool (Mix / Gradient modes) ── */
.mob-rt-colour-pool {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: 14px;
  padding: 0.85rem;
  display: none;
  flex-direction: column;
  gap: 0.6rem;
}
.mob-rt-colour-pool.visible { display: flex; }

.mob-rt-pool-label {
  font-size: 0.7rem;
  font-weight: 700;
  color: #f59e0b;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.mob-rt-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.mob-rt-preset-btn {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.28rem 0.6rem;
  border-radius: 30px;
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  transition: all 0.12s;
  font-size: 0.68rem;
  font-weight: 600;
  color: #8897b3;
  font-family: 'Inter', sans-serif;
}
.mob-rt-preset-btn:active {
  border-color: currentColor;
  background: rgba(255, 255, 255, 0.09);
  transform: translateY(-1px);
}

.mob-rt-preset-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.25);
  flex-shrink: 0;
}

.mob-rt-pool-items {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  max-height: 150px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #f59e0b #0b1120;
}

.mob-rt-pool-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.5rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
}

.mob-rt-pool-swatch {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  flex-shrink: 0;
}

.mob-rt-pool-hex {
  font-family: monospace;
  font-size: 0.72rem;
  color: #c7d2e8;
  flex: 1;
}

.mob-rt-pool-del {
  background: transparent;
  border: none;
  color: #546180;
  cursor: pointer;
  font-size: 0.75rem;
  padding: 0.15rem 0.3rem;
  border-radius: 4px;
  transition: color 0.12s;
  font-family: 'Inter', sans-serif;
}
.mob-rt-pool-del:active { color: #ef4444; }

.mob-rt-mix-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.mob-rt-mix-label {
  font-size: 0.72rem;
  color: #8897b3;
}

.mob-rt-mix-input {
  width: 50px;
  background: #0d1017;
  border: 1px solid #1e2d45;
  color: #e8edf5;
  padding: 0.25rem 0.4rem;
  border-radius: 30px;
  font-size: 0.78rem;
  text-align: center;
  font-family: 'Inter', sans-serif;
}

.mob-rt-pattern-preview {
  font-size: 0.68rem;
  color: #8897b3;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  padding: 0.4rem 0.6rem;
  line-height: 1.5;
  word-break: break-all;
}

/* ═══════════════════════════════════════════════════════════════════════════
   STEP 3 — BACKGROUND VIDEO
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-video-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

.mob-rt-video-btn {
  background: #070c16;
  border: 1.5px solid #1e2d45;
  border-radius: 12px;
  padding: 0.65rem 0.5rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  color: #8897b3;
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.mob-rt-video-btn:active,
.mob-rt-video-btn.selected {
  background: rgba(99, 102, 241, 0.12);
  border-color: #6366f1;
  color: #818cf8;
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.25);
}

/* ═══════════════════════════════════════════════════════════════════════════
   STEP 4 — GENERATE + RESULT
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}

.mob-rt-info-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.mob-rt-info-label {
  font-size: 0.65rem;
  color: #546180;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.mob-rt-info-value {
  font-size: 0.85rem;
  color: #e2e8f0;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

/* Result card */
.mob-rt-result {
  display: none;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 0.75rem;
}
.mob-rt-result.visible { display: flex; }

.mob-rt-result-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #34d399;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.mob-rt-result-video {
  background: #000;
  border-radius: 14px;
  overflow: hidden;
}

.mob-rt-result-video video {
  width: 100%;
  max-height: 350px;
  display: block;
  object-fit: contain;
}

.mob-rt-dl-area {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mob-rt-dl-text {
  font-size: 0.82rem;
  color: #e2e8f0;
  font-weight: 600;
}

.mob-rt-dl-sub {
  font-size: 0.72rem;
  color: #546180;
}

/* Progress track */
.mob-rt-dl-track {
  height: 4px;
  background: rgba(255, 255, 255, 0.07);
  border-radius: 99px;
  overflow: hidden;
}

.mob-rt-dl-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #4f46e5, #10b981);
  border-radius: 99px;
  transition: width 0.18s ease;
}

.mob-rt-dl-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
  color: #3f5070;
  font-variant-numeric: tabular-nums;
}

/* ═══════════════════════════════════════════════════════════════════════════
   HOW IT WORKS — Mobile compact
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-how {
  padding: 2rem 1rem 2.4rem;
  background: #070c16;
  border-top: 1px solid #111827;
}

.mob-rt-how h2 {
  text-align: center;
  font-size: 1.3rem;
  font-weight: 700;
  color: #f1f5f9;
  margin-bottom: 1.2rem;
}

.mob-rt-steps {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.mob-rt-step-card {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  background: #111827;
  border: 1px solid #1e2d45;
  border-radius: 16px;
  padding: 0.85rem 1rem;
  transition: border-color 0.2s;
}
.mob-rt-step-card:active { border-color: #4f46e5; }

.mob-rt-step-card-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: #818cf8;
  flex-shrink: 0;
}

.mob-rt-step-card h3 {
  font-size: 0.88rem;
  font-weight: 700;
  color: #f1f5f9;
  margin-bottom: 0.2rem;
}

.mob-rt-step-card p {
  font-size: 0.78rem;
  color: #8897b3;
  line-height: 1.45;
}

/* ═══════════════════════════════════════════════════════════════════════════
   MOBILE FOOTER (reused pattern)
   ═══════════════════════════════════════════════════════════════════════════ */
.mob-rt-footer {
  background: #0b1120;
  border-top: 1px solid #1e2d45;
  padding: 2rem 1.2rem 1.2rem;
  color: #c7d2e8;
}

.mob-rt-footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem 1rem;
  margin-bottom: 1.5rem;
}

.mob-rt-footer-logo-col {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.3rem;
}

.mob-rt-footer-logo {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 1.1rem;
  font-weight: 600;
  color: #c7d2e8;
}
.mob-rt-footer-logo img { height: 32px; width: auto; }

.mob-rt-footer-tagline {
  font-size: 0.75rem;
  color: #546180;
}

.mob-rt-footer-col h4 {
  font-size: 0.82rem;
  font-weight: 700;
  color: #f1f5f9;
  margin-bottom: 0.7rem;
  border-left: 2px solid #4f46e5;
  padding-left: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.mob-rt-footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.mob-rt-footer-col a {
  color: #8897b3;
  font-size: 0.8rem;
  text-decoration: none;
  transition: color 0.15s;
}
.mob-rt-footer-col a:active { color: #818cf8; }

.mob-rt-footer-social {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.mob-rt-footer-social a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: #8897b3;
  font-size: 0.8rem;
  text-decoration: none;
  padding: 0.3rem 0.7rem;
  border-radius: 30px;
  border: 1px solid #1e2d45;
  background: #111827;
  transition: color 0.15s, border-color 0.15s;
}
.mob-rt-footer-social a:active { color: #818cf8; border-color: #4f46e5; }

.mob-rt-footer-email {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem 0;
  border-top: 1px solid #1e2d45;
  border-bottom: 1px solid #1e2d45;
  margin-bottom: 1rem;
}

.mob-rt-footer-email a {
  color: #8897b3;
  font-size: 0.78rem;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.mob-rt-footer-email a i { color: #818cf8; }
.mob-rt-footer-email a:active { color: #c7d2e8; }

.mob-rt-footer-copy {
  text-align: center;
  font-size: 0.72rem;
  color: #546180;
  line-height: 1.6;
}

/* ── Spin utility ── */
@keyframes mob-rt-spin { to { transform: rotate(360deg); } }
.mob-rt-spin { animation: mob-rt-spin 0.8s linear infinite; display: inline-block; }

/* ── Cancel stage button ── */
.mob-rt-cancel-btn {
  background: transparent;
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #f87171;
  padding: 0.4rem 0.9rem;
  border-radius: 30px;
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.mob-rt-cancel-btn:active { background: rgba(239, 68, 68, 0.1); }

/* ═══════════════════════════════════════════════════════════════════
   MOBILE PIPELINE STATUS BARS — Mirrors of desktop progress bars
   ═══════════════════════════════════════════════════════════════════ */

.mob-rt-pipeline-bars {
  display: none;
  margin-top: 0.75rem;
}

.mob-rt-pipeline-bars .archx-bar {
  margin: 0;
  font-size: 0.74rem;
  border-radius: 12px;
  padding: 0.8rem 1rem 0.75rem;
}

.mob-rt-pipeline-bars .archx-top {
  gap: 0.4rem;
}

.mob-rt-pipeline-bars .archx-head {
  font-size: 0.65rem;
}

.mob-rt-pipeline-bars .archx-msg {
  font-size: 0.72rem;
}

.mob-rt-pipeline-bars .archx-pct {
  font-size: 0.8rem;
}

.mob-rt-pipeline-bars .archx-stats {
  gap: 0.8rem;
}

.mob-rt-pipeline-bars .archx-stat {
  min-width: 36px;
}

.mob-rt-pipeline-bars .archx-sl {
  font-size: 0.55rem;
}

.mob-rt-pipeline-bars .archx-sv {
  font-size: 0.74rem;
}

.mob-rt-pipeline-bars .archx-note {
  font-size: 0.62rem;
}

.mob-rt-pipeline-bars .archx-track {
  height: 4px;
}

/* Cancel button inside mobile bars */
.mob-rt-pipeline-bars .archx-cancel-btn,
.mob-rt-pipeline-bars .stage-cancel-btn {
  background: transparent;
  border: 1px solid rgba(239,68,68,0.3);
  color: #f87171;
  padding: 0.4rem 0.9rem;
  border-radius: 30px;
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.4rem;
  transition: all 0.15s;
}

.mob-rt-pipeline-bars .archx-cancel-btn:hover,
.mob-rt-pipeline-bars .stage-cancel-btn:hover {
  background: rgba(239,68,68,0.1);
  border-color: #f87171;
}

/* ═══════════════════════════════════════════════════════════════════
   MOBILE DOWNLOAD AREA V2 — Full progress like desktop
   ═══════════════════════════════════════════════════════════════════ */

.mob-rt-dl-area-v2 {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 16px;
  padding: 1rem 1.1rem;
  margin-top: 0.75rem;
  font-family: 'Inter', sans-serif;
}

.mob-rt-dl-state {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mob-rt-dl-idle-copy strong {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: #e2e8f0;
  margin-bottom: 0.2rem;
}

.mob-rt-dl-idle-copy span {
  font-size: 0.75rem;
  color: #546180;
}

/* Downloading state */
.mob-rt-dl-progress-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.6rem;
}

.mob-rt-dl-progress-label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: #e2e8f0;
}

.mob-rt-dl-pct {
  color: #10b981;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
}

.mob-rt-dl-cancel-btn {
  background: transparent;
  border: 1px solid rgba(239,68,68,0.3);
  color: #f87171;
  padding: 0.3rem 0.8rem;
  border-radius: 30px;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.mob-rt-dl-cancel-btn:hover {
  background: rgba(239,68,68,0.1);
  border-color: #f87171;
}

.mob-rt-dl-track-v2 {
  height: 5px;
  background: rgba(255,255,255,0.07);
  border-radius: 99px;
  overflow: hidden;
  margin-bottom: 0.5rem;
}

.mob-rt-dl-bar-v2 {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #4f46e5, #10b981);
  border-radius: 99px;
  transition: width 0.2s ease;
  position: relative;
  overflow: hidden;
}

.mob-rt-dl-bar-v2::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.35), transparent);
  animation: archxSweep 2.2s linear infinite;
}

@keyframes archxSweep {
  from { transform: translateX(-100%); }
  to { transform: translateX(350%); }
}

.mob-rt-dl-meta-v2 {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: #3f5070;
  font-variant-numeric: tabular-nums;
}

/* Done state */
.mob-rt-dl-done-msg {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: #34d399;
  margin-bottom: 0.5rem;
}

.mob-rt-dl-done-size {
  font-size: 0.72rem;
  color: #546180;
  font-weight: 400;
  margin-left: 0.2rem;
}

/* Error state */
.mob-rt-dl-error-msg {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.82rem;
  color: #f87171;
  margin-bottom: 0.5rem;
}

/* ═══════════════════════════════════════════════════════════════════
   MOBILE RESULT AREA — Better visibility
   ═══════════════════════════════════════════════════════════════════ */

.mob-rt-result {
  display: none;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
  animation: fadeIn 0.3s ease;
}

.mob-rt-result.visible {
  display: flex;
}

.mob-rt-result-title {
  font-size: 1rem;
  font-weight: 700;
  color: #34d399;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.mob-rt-result-video {
  border-radius: 16px;
  overflow: hidden;
  background: #000;
  line-height: 0;
}

.mob-rt-result-video video {
  width: 100%;
  max-height: 350px;
  display: block;
  object-fit: contain;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Spin animation for mobile */
.mob-rt-spin {
  display: inline-block;
  animation: archxSpin 0.75s linear infinite;
}

/* archxSpin keyframes: styles/reddit-injected.css (loaded after this file on redditstyle.html) */

/* ── Mobile Phone Preview Shell ── */
.mob-phone-preview-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}
.mob-phone-shell {
  width: 140px;
  background: #0a0f1e;
  border-radius: 22px;
  border: 2px solid rgba(99,102,241,0.35);
  box-shadow: 0 0 24px rgba(99,102,241,0.15);
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}
.mob-phone-notch {
  width: 40px; height: 8px;
  background: #0a0f1e;
  border-radius: 0 0 8px 8px;
  margin: 0 auto;
  position: relative; z-index: 10;
}
.mob-phone-screen {
  position: relative;
  width: 100%;
  padding-bottom: 177.78%;
  overflow: hidden;
  background: #0d1117;
}
.mob-phone-bg-sim {
  position: absolute; inset: 0;
  display: flex; align-items: flex-end;
  overflow: hidden;
}
.mob-phone-bg-bars {
  display: flex; gap: 2px; align-items: flex-end;
  width: 100%; height: 100%;
  padding: 0 2px;
}
.mob-pb-bar {
  flex: 1;
  height: var(--h);
  background: var(--c);
  opacity: 0.7;
  border-radius: 2px 2px 0 0;
}
.mob-phone-bg-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.15) 50%, rgba(0,0,0,0.4) 100%);
}
.mob-phone-sub-area {
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  z-index: 5;
  width: max-content;
  max-width: 90%;
  text-align: center;
  pointer-events: none;
  transition: top 0.2s ease;
}
.mob-phone-screen-fade {
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 25%; z-index: 4;
  background: linear-gradient(transparent, rgba(0,0,0,0.4));
  pointer-events: none;
}
.mob-phone-status-bar {
  position: absolute; top: 0; left: 0; right: 0;
  display: flex; justify-content: space-between; align-items: center;
  padding: 3px 8px; z-index: 10;
  font-size: 0.45rem; color: rgba(255,255,255,0.8);
}
.mob-phone-home-bar {
  height: 6px;
  background: rgba(255,255,255,0.15);
  border-radius: 3px;
  width: 40%;
  margin: 4px auto;
}
.mob-phone-transport {
  display: flex; gap: 0.6rem; align-items: center;
}
.mob-transport-btn {
  background: rgba(99,102,241,0.12);
  border: 1px solid rgba(99,102,241,0.3);
  color: #a5b4fc;
  border-radius: 50%;
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; cursor: pointer;
  transition: background 0.15s;
}
.mob-transport-btn:hover { background: rgba(99,102,241,0.25); }
.mob-transport-play {
  background: rgba(99,102,241,0.25);
  border-color: rgba(99,102,241,0.6);
  width: 40px; height: 40px;
  font-size: 0.9rem;
}
.mob-phone-time-row {
  font-size: 0.65rem;
  color: #546180;
  font-family: monospace;
}
.mob-waveform-wrap {
  position: relative;
  width: 100%;
  max-width: 280px;
  height: 48px;
  background: #0f1525;
  border-radius: 8px;
  overflow: hidden;
}
.mob-wed-playhead-line {
  position: absolute;
  top: 0; bottom: 0;
  width: 2px;
  background: rgba(59,130,246,0.9);
  box-shadow: 0 0 6px rgba(59,130,246,0.6);
  pointer-events: none;
  transition: left 0.05s linear;
}