/* ============================================
   AI Creator Toolkit — Premium UI v5.0
   Complete Generator Redesign
   ============================================ */

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

/* ── VARIABLES ─────────────────────────────── */
:root {
  --white: #FFFFFF;
  --bg: #F9FAFB;
  --bg-card: #FFFFFF;
  --border: #E5E7EB;
  --border-light: #F0F0F0;
  --border-focus: #FF385C;
  --primary: #FF385C;
  --primary-dark: #E01E50;
  --primary-light: #FFF5F7;
  --primary-glow: rgba(255, 56, 92, 0.15);
  --success: #10B981;
  --success-light: #ECFDF5;
  --youtube: #EF4444;
  --youtube-light: #FEF2F2;
  --video: #8B5CF6;
  --video-light: #F5F3FF;
  --text-h: #111827;
  --text-b: #374151;
  --text-s: #6B7280;
  --text-hint: #9CA3AF;

  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 4px 24px rgba(0, 0, 0, 0.08);
  --shadow-glow: 0 8px 32px rgba(255, 56, 92, 0.25);

  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 20px;
  --r-pill: 999px;

  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --spring: cubic-bezier(0.175, 0.885, 0.32, 1.1);
}

/* ── RESET & BASE ───────────────────────────── */
.act-hero *,
.act-sticky-bar *,
.act-wrapper * {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.act-wrapper {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 24px 80px;
  font-family: var(--font-body);
  color: var(--text-b);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* ══════════════════════════════════════════════
   HERO ENTRY SECTION
   ══════════════════════════════════════════════ */
.act-hero {
  max-width: 800px;
  margin: 0 auto;
  padding: 32px 24px 0; /* Align with wrapper padding horizontally */
  font-family: var(--font-body);
}

.act-hero-panel {
  padding: 48px 40px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 32px;
  border-bottom: 1px solid var(--border); /* Divider between hero and generator */
}

.act-hero-content {
  max-width: 540px;
}

.act-hero-title {
  font-family: var(--font-heading);
  font-size: 36px;
  font-weight: 800;
  color: var(--text-h);
  letter-spacing: -1px;
  margin-bottom: 12px;
}

.act-hero-desc {
  font-size: 16px;
  color: var(--text-s);
  line-height: 1.5;
}

.act-hero-actions {
  display: flex;
  gap: 20px;
  width: 100%;
}

@media (max-width: 600px) {
  .act-hero-actions {
    flex-direction: column;
  }
}

.act-hero-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  border-radius: var(--r-lg);
  font-family: var(--font-body);
  cursor: pointer;
  transition: all 0.3s var(--spring);
  text-align: left;
  width: 100%;
  border: none;
}

.act-hero-btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: var(--white);
  box-shadow: var(--shadow-glow);
}

.act-hero-btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 36px rgba(255, 56, 92, 0.4);
}

.act-hero-btn-secondary {
  background: var(--white);
  color: var(--text-h);
  border: 2px solid var(--border) !important;
}

.act-hero-btn-secondary:hover {
  border-color: var(--primary) !important;
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.act-hero-btn-icon {
  font-size: 28px;
  flex-shrink: 0;
}

.act-hero-btn-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.act-hero-btn-title {
  font-size: 16px;
  font-weight: 700;
}

.act-hero-btn-sub {
  font-size: 13px;
  opacity: 0.85;
  font-weight: 400;
}

/* Trust Strip */
.act-trust-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 24px;
  background: var(--gal-bg2, #F9FAFB);
  border-top: 1px solid var(--border);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-hint);
  flex-wrap: wrap;
  width: 100%;
}

.act-trust-strip span {
  white-space: nowrap;
}

.act-trust-tools {
  color: var(--text-s);
}
/* ══════════════════════════════════════════════
   TOP MODE TOGGLE SWITCH
   ══════════════════════════════════════════════ */
.act-top-toggle-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 32px 0 16px;
  z-index: 100;
}

.act-top-toggle {
  display: flex;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: var(--r-pill);
  padding: 5px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
  border: 1px solid rgba(0, 0, 0, 0.06);
  width: 100%;
  max-width: 400px;
}

.act-toggle-btn {
  flex: 1 1 0px;
  padding: 12px 18px;
  border: none;
  border-radius: var(--r-pill);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  color: var(--text-s);
  background: transparent;
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  white-space: nowrap;
}

.act-toggle-btn:hover {
  color: var(--text-h);
}

.act-toggle-btn.active {
  background: var(--primary);
  color: var(--white);
  box-shadow: 0 2px 10px var(--primary-glow);
}

@media (max-width: 600px) {
  .act-sticky-bar {
    top: 0;
    padding: 8px 12px;
  }

  .act-sticky-inner {
    max-width: 100%;
  }

  .act-sticky-tab {
    padding: 14px 12px;
    font-size: 13px;
    min-height: 56px;
  }
}

/* ── TAB SWITCHER (Image/YouTube/Video) ─────── */
.act-tabs {
  display: flex;
  padding: 24px 40px 0;
  overflow-x: auto;
  scrollbar-width: none;
  gap: 12px;
}

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

.act-tab {
  flex: 1;
  padding: 12px 16px;
  border: none;
  border-radius: var(--r-pill);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  color: var(--text-s);
  background: transparent;
  transition: all 0.3s ease;
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.act-tab:hover {
  color: var(--text-h);
}

.act-tab.active {
  background: var(--bg);
  color: var(--text-h);
}

/* ── MAIN CARD/PANEL ────────────────────────── */
.act-tab-panel {
  display: none;
}

.act-tab-panel.active {
  display: block;
  animation: actFadeIn 0.4s var(--spring) forwards;
  opacity: 1;
}

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

.act-main-card {
  padding: 32px 40px 48px;
  position: relative;
  overflow: hidden;
}

@media (max-width: 600px) {
  .act-main-card {
    padding: 20px 16px;
  }
}

/* ── PROGRESS BAR ──────────────────────────── */
.act-progress-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--border-light);
}

.act-progress-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 0 3px 3px 0;
  transition: width 0.4s ease;
}

/* ── STEP GROUPS ────────────────────────────── */
.act-step-group {
  margin-bottom: 32px;
  transition: opacity 0.3s ease-out, transform 0.3s ease-out;
}

.act-step-group:last-of-type {
  margin-bottom: 24px;
}

.step-hidden {
  opacity: 0;
  transform: translateY(16px);
  max-height: 0;
  overflow: hidden;
  margin: 0;
  pointer-events: none;
}

.step-visible {
  opacity: 1;
  transform: translateY(0);
  max-height: 3000px;
  overflow: visible;
  pointer-events: auto;
}

.act-step-header {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 20px;
}

.act-step-header-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.act-step-num {
  width: 28px;
  height: 28px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: var(--r-pill);
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.act-step-title {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 800;
  color: var(--text-h);
  letter-spacing: -0.3px;
  line-height: 1.2;
}

.act-step-hint {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-hint);
  font-weight: 400;
}

@media (max-width: 600px) {
  .act-step-title {
    font-size: 18px;
  }
}

/* ══════════════════════════════════════════════
   NICHE GRID — Flex Wrap (No Cutoff!)
   ══════════════════════════════════════════════ */
.act-niche-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.act-niche-card {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1.5px solid var(--border-light);
  border-radius: var(--r-pill);
  background: white;
  cursor: pointer;
  transition: all 0.25s var(--spring);
  position: relative;
  min-height: 44px;
}

.act-niche-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.act-niche-card.selected {
  border-color: var(--primary);
  background: var(--primary-light);
  box-shadow: 0 0 0 1px var(--primary);
}

.act-niche-icon {
  font-size: 20px;
  line-height: 1;
}

.act-niche-label {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-b);
}

.act-niche-card.selected .act-niche-label {
  color: var(--primary);
  font-weight: 700;
}



@media (max-width: 600px) {
  .act-niche-card {
    padding: 8px 14px;
  }
  .act-niche-icon {
    font-size: 18px;
  }
  .act-niche-label {
    font-size: 13px;
  }
}

/* ══════════════════════════════════════════════
   SMART QUESTIONS — Pill Buttons
   ══════════════════════════════════════════════ */
.act-questions-wrap {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.act-question-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.act-question-text {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  color: #333;
}

.act-pills-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.act-pill {
  padding: 10px 18px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-pill);
  background: var(--white);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-b);
  cursor: pointer;
  transition: all 0.2s ease;
  min-height: 44px;
  display: flex;
  align-items: center;
  white-space: nowrap;
}

.act-pill:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.act-pill.selected {
  border-color: var(--primary);
  background: var(--primary);
  color: var(--white);
}

/* Text input style for question pills */
.act-question-input {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 500;
  color: var(--text-h);
  background: var(--white);
  transition: all 0.2s ease;
  min-height: 44px;
}

/* ══════════════════════════════════════════════
   NEW: SUB-CATEGORY HORIZONTAL SCROLL (YT & VIDEO)
   ══════════════════════════════════════════════ */
.act-subcat-scroll {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-top: 16px;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge */
}
.act-subcat-scroll::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}
.act-subcat-pill {
  flex-shrink: 0;
  padding: 12px 20px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-pill);
  font-family: var(--font-heading);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-b);
  cursor: pointer;
  transition: all 0.2s ease;
  will-change: transform;
}
.act-subcat-pill:hover {
  border-color: var(--text-s);
  transform: translateY(-2px);
}
.act-subcat-pill.selected {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
  box-shadow: 0 4px 16px var(--primary-glow);
}

/* Custom coloring for YouTube & Video tabs based on class */
.act-btn-yt { background: var(--youtube); }
.act-btn-yt:hover { background: #DC2626; box-shadow: 0 8px 32px rgba(239, 68, 68, 0.25); }
.act-btn-video { background: var(--video); }
.act-btn-video:hover { background: #7C3AED; box-shadow: 0 8px 32px rgba(139, 92, 246, 0.25); }

#act-panel-youtube .act-subcat-pill.selected {
  background: var(--youtube); border-color: var(--youtube);
}
#act-panel-video .act-subcat-pill.selected {
  background: var(--video); border-color: var(--video);
}

/* ══════════════════════════════════════════════
   NEW: DEEP WIZARD QUESTION CARDS & MULTI-SELECT
   ══════════════════════════════════════════════ */
.act-question-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 24px;
  margin-top: 16px;
  box-shadow: var(--shadow-sm);
  animation: actSlideIn 0.3s var(--spring) forwards;
}

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

.act-question-title {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  color: var(--text-h);
  margin-bottom: 4px;
}

.act-question-desc {
  font-size: 14px;
  color: var(--text-hint);
  margin-bottom: 16px;
}

.act-answers-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.act-ans-pill {
  padding: 10px 16px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-pill);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-b);
  cursor: pointer;
  transition: all 0.2s ease;
}

.act-ans-pill:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}

.act-ans-pill.selected {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
}

/* Multi-select variants */
.act-ans-pill.multi-selected {
  background: var(--bg-card);
  border-color: var(--primary);
  color: var(--primary);
  box-shadow: inset 0 0 0 1px var(--primary);
}
.act-ans-pill.multi-selected::after {
  content: "✓";
  margin-left: 6px;
  font-weight: 700;
}

.act-continue-btn {
  margin-top: 16px;
  padding: 10px 24px;
  background: var(--text-h);
  color: var(--white);
  border: none;
  border-radius: var(--r-pill);
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
}
.act-continue-btn:hover { opacity: 0.9; }
.act-continue-btn:disabled { opacity: 0.5; cursor: not-allowed; }

.act-skip-btn {
  margin-top: 16px;
  margin-left: 12px;
  background: transparent;
  border: none;
  color: var(--text-hint);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}
.act-skip-btn:hover { color: var(--text-s); text-decoration: underline; }

/* ══════════════════════════════════════════════
   NEW: SUMMARY CHIPS (Rewind State)
   ══════════════════════════════════════════════ */
.act-summary-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.act-summary-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-b);
  cursor: pointer;
  transition: all 0.2s ease;
  animation: actFadeIn 0.3s ease forwards;
}

.act-summary-chip:hover {
  background: var(--border-light);
  border-color: var(--text-hint);
}
.act-summary-chip::after {
  content: "✎";
  margin-left: 6px;
  font-size: 11px;
  opacity: 0.5;
}
.act-summary-chip:hover::after { opacity: 1; }

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

.act-question-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-glow);
}

.act-question-input::placeholder {
  color: var(--text-hint);
}

/* ══════════════════════════════════════════════
   STEP 3: ASPECT RATIO TILES
   ══════════════════════════════════════════════ */
.act-step3-section {
  margin-bottom: 24px;
}

.act-step3-section:last-child {
  margin-bottom: 0;
}

.act-ratio-scroll {
  position: relative;
}

.act-ratio-track {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
}

.act-ratio-track::-webkit-scrollbar {
  display: none;
}

.act-ratio-tile {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px 20px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  background: var(--white);
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.act-ratio-tile:hover {
  border-color: var(--primary);
  background: var(--bg);
}

.act-ratio-tile.selected {
  border-color: var(--primary);
  background: var(--primary-light);
  box-shadow: inset 0 0 0 1px var(--primary);
}

.act-ratio-shape {
  background: var(--text-hint);
  border-radius: 4px;
  transition: background 0.2s;
}

.act-ratio-tile.selected .act-ratio-shape {
  background: var(--primary);
}

.act-ratio-label {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-b);
}

.act-ratio-tile.selected .act-ratio-label {
  color: var(--primary);
}

/* Tooltip on ratio tiles */
.act-ratio-tooltip {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 12px;
  background: var(--text-h);
  color: var(--white);
  font-size: 12px;
  font-weight: 500;
  border-radius: var(--r-sm);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 50;
}

.act-ratio-tile:hover .act-ratio-tooltip {
  opacity: 1;
}

/* Mobile fade indicator */
.act-ratio-fade {
  display: none;
}

@media (max-width: 600px) {
  .act-ratio-fade {
    display: block;
    position: absolute;
    top: 0;
    right: 0;
    bottom: 4px;
    width: 48px;
    background: linear-gradient(to right, transparent, var(--white));
    pointer-events: none;
  }
}

/* ── DETAIL SLIDER ─────────────────────────── */
.act-slider-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.act-slider-label {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-hint);
  white-space: nowrap;
}

.act-detail-slider {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  background: var(--border);
  border-radius: 4px;
  outline: none;
}

.act-detail-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--primary);
  cursor: pointer;
  box-shadow: 0 2px 8px var(--primary-glow);
}

.act-detail-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--primary);
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 8px var(--primary-glow);
}

/* ── FORM INPUTS ────────────────────────────── */
.act-input {
  box-sizing: border-box !important;
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 500;
  color: var(--text-h);
  background: var(--white);
  transition: all 0.2s ease;
}

.act-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-glow);
}

.act-input::placeholder {
  color: var(--text-hint);
}

.act-textarea {
  box-sizing: border-box !important;
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 500;
  color: var(--text-h);
  background: var(--white);
  transition: all 0.2s ease;
  resize: vertical;
}

.act-textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-glow);
}

.act-textarea::placeholder {
  color: var(--text-hint);
}

.act-field-label {
  display: block;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-h);
  margin-bottom: 8px;
}

.act-field-label .opt {
  font-weight: 400;
  color: var(--text-hint);
}

/* ── GENERATE BUTTON ────────────────────────── */
.act-generate-btn {
  width: 100%;
  padding: 18px 24px;
  height: 56px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  border: none;
  border-radius: var(--r-lg);
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s var(--spring);
  box-shadow: var(--shadow-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  position: relative;
  overflow: hidden;
  margin-top: 8px;
}

.act-generate-btn::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: skewX(-20deg);
  transition: all 0.5s;
}

.act-generate-btn:hover::after {
  left: 150%;
}

.act-generate-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 36px rgba(255, 56, 92, 0.4);
}

.act-generate-btn:active {
  transform: translateY(0);
}

.act-btn-yt {
  background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
  box-shadow: 0 8px 32px rgba(239, 68, 68, 0.3);
}

.act-btn-yt:hover {
  box-shadow: 0 12px 36px rgba(239, 68, 68, 0.4);
}

.act-btn-video {
  background: linear-gradient(135deg, #8B5CF6 0%, #7C3AED 100%);
  box-shadow: 0 8px 32px rgba(139, 92, 246, 0.3);
}

.act-btn-video:hover {
  box-shadow: 0 12px 36px rgba(139, 92, 246, 0.4);
}

.act-generate-btn.loading {
  opacity: 0.9;
  cursor: wait;
  transform: scale(0.98);
}

.act-generate-btn.loading .act-btn-label {
  display: none;
}

.act-btn-spinner {
  width: 24px;
  height: 24px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: actSpin 0.8s linear infinite;
  display: none;
}

.act-generate-btn.loading .act-btn-spinner {
  display: block;
}

@keyframes actSpin {
  to { transform: rotate(360deg); }
}

/* ══════════════════════════════════════════════
   RESULT BOX
   ══════════════════════════════════════════════ */
.act-result-box {
  margin-top: 24px;
  background: white;
  border: 2px solid var(--border);
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  display: none;
  animation: actReveal 0.5s var(--spring) forwards;
  transform-origin: top;
}

.act-generator-wrap {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  min-height: 400px;
  overflow: hidden; /* Ensures child elements don't break the rounded corners */
  display: flex;
  flex-direction: column;
}

@keyframes actReveal {
  from { opacity: 0; transform: scaleY(0.95) translateY(-10px); }
  to { opacity: 1; transform: scaleY(1) translateY(0); }
}

.act-result-header {
  padding: 14px 24px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.act-result-label {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.act-prompt-output {
  padding: 24px;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-h);
  font-weight: 500;
  user-select: all;
  -webkit-user-select: all;
  cursor: text;
}

.act-result-charcount {
  padding: 0 24px 8px;
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-hint);
  text-align: right;
}

.act-result-actions {
  padding: 16px 24px;
  background: var(--bg);
  border-top: 1px solid var(--border);
  display: flex;
  gap: 12px;
}

.act-action-btn {
  padding: 12px 20px;
  border-radius: var(--r-md);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
}

.act-action-primary {
  flex: 2;
  background: var(--primary);
  color: var(--white);
  border: none;
  box-shadow: 0 4px 12px var(--primary-glow);
}

.act-action-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
}

.act-action-primary.copied {
  background: var(--success);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.act-action-secondary {
  flex: 1;
  background: var(--white);
  color: var(--text-b);
  border: 1.5px solid var(--border);
}

.act-action-secondary:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.act-use-on {
  padding: 16px 24px 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  background: var(--bg);
}

.act-use-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-hint);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  width: 100%;
  margin-bottom: 4px;
}

.act-tool-pill {
  padding: 8px 16px;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-b);
  text-decoration: none;
  transition: all 0.2s;
  box-shadow: var(--shadow-sm);
}

.act-tool-pill:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

/* ── TOOLTIP SYSTEM ────────────────────────── */
.act-tooltip {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 12px;
  background: var(--text-h);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 500;
  border-radius: var(--r-sm);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 50;
}

.act-tooltip.show {
  opacity: 1;
}

@media (hover: none) and (pointer: coarse) {
  .act-tooltip {
    display: none !important;
  }
}

/* ── STEP TRANSITION HINT ──────────────────── */
.act-step-transition-hint {
  text-align: center;
  padding: 12px 0;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--success);
  font-weight: 600;
  animation: actPulse 1s ease-in-out;
  opacity: 0;
}

@keyframes actPulse {
  0% { opacity: 0; transform: translateY(-4px); }
  30% { opacity: 1; transform: translateY(0); }
  80% { opacity: 1; }
  100% { opacity: 0; }
}

/* ── ADS ───────────────────────────────────── */
.act-ad {
  text-align: center;
  margin-bottom: 32px;
}

.act-ad-middle {
  text-align: center;
  margin: 24px 0;
  display: none;
}

.act-ad-footer {
  text-align: center;
  margin-top: 64px;
}

/* ── MOBILE SPECIFIC ───────────────────────── */
@media (max-width: 600px) {
  .act-wrapper {
    padding: 0 12px 60px;
  }

  /* Prevent iOS zoom on focus */
  .act-input,
  .act-textarea,
  .act-question-input {
    font-size: 16px !important;
  }

  .act-result-actions {
    flex-direction: column;
  }

  .act-action-btn {
    justify-content: center;
  }
}

/* ── GENERATE BUTTON PULSE (first visit) ───── */
.act-generate-btn.pulse-ring {
  animation: actBtnPulse 2s ease-in-out infinite;
}

@keyframes actBtnPulse {
  0% { box-shadow: var(--shadow-glow); }
  50% { box-shadow: 0 0 0 8px rgba(255, 56, 92, 0.15), var(--shadow-glow); }
  100% { box-shadow: var(--shadow-glow); }
}

/* ══════════════════════════════════════════════
   NEW FLOW UI STYLES
   ══════════════════════════════════════════════ */
.step-hidden {
    display: none !important;
}

.step-visible {
    display: block !important;
    animation: actFadeIn 0.4s ease-out;
}

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

/* SUMMARY CHIPS */
.act-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}
.act-summary-chip {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  padding: 6px 14px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-b);
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
}
.act-summary-chip:hover {
  background: #FEE2E2;
  border-color: #EF4444;
  color: #B91C1C;
  text-decoration: line-through;
}

/* SMART QUESTIONS FLOW */
.act-question-card {
  background: white;
  border-radius: var(--r-xl);
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  animation: actSlideUp 0.3s ease-out;
}
@keyframes actSlideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.act-question-title {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  color: var(--text-a);
  margin-bottom: 16px;
}

.act-answers-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.act-ans-pill {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  padding: 10px 18px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-b);
  cursor: pointer;
  transition: all 0.2s var(--spring);
}
.act-ans-pill:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-2px);
  background: var(--primary-light);
}

.act-continue-btn {
  background: var(--primary);
  color: white;
  border: none;
  padding: 10px 24px;
  border-radius: var(--r-pill);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.2s;
}
.act-continue-btn:hover { opacity: 0.9; }

.act-skip-btn {
  background: transparent;
  color: var(--text-c);
  border: none;
  font-size: 13px;
  font-family: var(--font-body);
  text-decoration: underline;
  cursor: pointer;
  margin-left: 12px;
}
.act-skip-btn:hover { color: var(--text-a); }

/* NEGATIVE PROMPT ACCORDION */
.act-negative-prompt-accordion {
  margin-top: 16px;
  border-top: 1px solid var(--border-light);
  padding-top: 16px;
}
.act-neg-accordion-btn {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-b);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: var(--r-md);
  transition: background 0.2s;
}
.act-neg-accordion-btn:hover {
  background: var(--surface);
}
.act-neg-arrow { margin-left: auto; font-size: 12px; color: var(--text-c); }
.act-neg-accordion-content {
  display: none;
  margin-top: 12px;
}
.act-negative-output {
  background: #FFF1F2;
  border-color: #FECDD3;
  color: #BE123C;
  font-size: 13px;
}

/* ☕ DONATION SECTION STYLES */
.act-donation-wrapper {
    margin-top: 40px;
    padding-bottom: 40px;
    display: flex;
    justify-content: center;
}

.act-donation-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 24px;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 32px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    max-width: 600px;
    width: 100%;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.act-donation-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.act-donation-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #F59E0B, #EC4899, #8B5CF6);
}

.act-donation-content {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 16px;
}

.act-donation-icon {
    font-size: 32px;
    background: #FFF7ED;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

.act-donation-wrapper .act-donation-text h3 {
    margin: 0 !important;
    padding: 0 !important;
    font-size: 24px !important;
    font-weight: 800 !important;
    color: #1E293B !important;
    font-family: var(--font-head) !important;
    line-height: 1.2 !important;
}

.act-donation-wrapper .act-donation-text p {
    margin: 6px 0 0 0 !important;
    font-size: 15px !important;
    color: #475569 !important;
    line-height: 1.5 !important;
}

.act-qr-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    padding: 12px;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.act-qr-code {
    width: 120px;
    height: 120px;
    object-fit: contain;
    border-radius: 8px;
}

.act-qr-hint {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94A3B8;
}

/* Responsive adjustments */
@media (max-width: 640px) {
    .act-donation-card {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    .act-donation-content {
        flex-direction: column;
    }
}
/* Support QR Box in Results & Studio */
.act-support-qr-box, #act-studio-donation-qr {
    margin-top: 16px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.7) !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(0, 0, 0, 0.05) !important;
    border-radius: 16px;
    text-align: center;
    animation: actSlideDown 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.act-support-qr-box p, #act-studio-donation-qr p {
    font-size: 13px !important;
    color: #475569 !important;
    margin: 0 0 12px 0 !important;
    line-height: 1.5 !important;
    font-weight: 500 !important;
}

.act-support-qr-box img, #act-studio-donation-qr img {
    width: 140px !important;
    height: 140px !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08) !important;
    background: white !important;
    padding: 8px !important;
    border: 1px solid #f1f5f9 !important;
    display: inline-block !important;
}

.act-support-qr-box .act-qr-hint, #act-studio-donation-qr .act-qr-hint-text {
    display: block !important;
    font-size: 10px !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    color: #94A3B8 !important;
    margin-top: 10px !important;
}

.act-support-btn:hover {
    background: #FFF7ED !important;
    color: #C2410C !important;
    border-color: #FDBA74 !important;
}

@keyframes actSlideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Gallery Modal Support Styling */
.act-modal-support-btn:hover {
    background: #FFF7ED !important;
    color: #C2410C !important;
    border-color: #FDBA74 !important;
}

#act-gallery-donation-qr, #act-gallery-donation-qr-paid {
    margin-top: 16px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.7) !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(0, 0, 0, 0.05) !important;
    border-radius: 16px;
    text-align: center;
    animation: actSlideDown 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

#act-gallery-donation-qr p, #act-gallery-donation-qr-paid p {
    font-size: 13px !important;
    color: #475569 !important;
    margin: 0 0 12px 0 !important;
    line-height: 1.5 !important;
    font-weight: 500 !important;
}

#act-gallery-donation-qr img, #act-gallery-donation-qr-paid img {
    width: 140px !important;
    height: 140px !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08) !important;
    background: white !important;
    padding: 8px !important;
    border: 1px solid #f1f5f9 !important;
    display: inline-block !important;
}

/* Prominent Coffee Button & Urge Message */
.act-support-urge {
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    margin-bottom: 8px;
    font-style: italic;
    animation: actFadeIn 0.5s ease-out;
}

.act-coffee-btn-prominent {
    background: linear-gradient(135deg, #F97316, #EA580C) !important;
    color: white !important;
    border: none !important;
    padding: 8px 16px !important;
    border-radius: 10px !important;
    font-weight: 800 !important;
    font-size: 13px !important;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(234, 88, 12, 0.25) !important;
    transition: all 0.2s ease !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
}

.act-coffee-btn-prominent:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 16px rgba(234, 88, 12, 0.4) !important;
    background: linear-gradient(135deg, #FB923C, #F97316) !important;
}

.act-coffee-btn-prominent:active {
    transform: translateY(0) !important;
}

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