/* ================================================================
   AutomationByExperts — V2 actor-first design layer
   ================================================================
   Loaded AFTER style.css, which still owns the base reset, buttons,
   sections, blog and project styles. This file adds (and where
   needed, overrides) everything the Apify-focused rebuild needs:
   nav dropdown, page heroes, answer blocks, category + actor cards,
   filters, referral band, forms and the homepage sections.
   ================================================================ */

:root {
  --surface:     #101018;
  --surface-2:   #16161f;
  --surface-3:   #1c1c28;
  --line:        rgba(148, 163, 184, 0.14);
  --line-strong: rgba(129, 140, 248, 0.45);
  --ink:         #f4f4ff;
  --ink-2:       #a7aec0;
  --ink-3:       #737b8f;
  --ok:          #34d399;
  --radius-sm:   10px;
  --radius-md:   14px;
  --radius-xl:   24px;
  --lift:        0 10px 40px rgba(0, 0, 0, 0.45);
}

.container-narrow { max-width: 800px; }
.hidden { display: none !important; }

/* ---------- Nav dropdown ---------- */
.nav-drop { position: relative; }
.nav-drop-trigger { display: inline-flex; align-items: center; gap: 0.3rem; }

.nav-drop-menu {
  position: absolute;
  top: calc(100% + 0.9rem);
  left: 50%;
  transform: translateX(-50%) translateY(-6px);
  width: 340px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--lift);
  padding: 0.5rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
  z-index: 200;
}
.nav-drop:hover .nav-drop-menu,
.nav-drop:focus-within .nav-drop-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}
/* Invisible bridge so the menu survives the gap under the trigger. */
.nav-drop-menu::before {
  content: "";
  position: absolute;
  top: -0.9rem;
  left: 0;
  right: 0;
  height: 0.9rem;
}
.nav-drop-menu a {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  padding: 0.6rem 0.7rem;
  border-radius: var(--radius-sm);
  transition: background 0.15s ease;
}
.nav-drop-menu a:hover { background: rgba(99, 102, 241, 0.12); }
.nav-drop-menu .ndm-icon { font-size: 1.15rem; line-height: 1.4; flex-shrink: 0; }
.nav-drop-menu strong {
  display: block;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
}
.nav-drop-menu small {
  display: block;
  font-size: 0.74rem;
  color: var(--ink-3);
  line-height: 1.45;
  margin-top: 0.1rem;
}
.nav-drop-menu .ndm-all {
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
  border-top: 1px solid var(--line);
  margin-top: 0.3rem;
  padding-top: 0.7rem;
}

/* On mobile the nav is a stacked panel — flatten the dropdown into it. */
@media (max-width: 900px) {
  .nav-drop-menu {
    position: static;
    transform: none;
    opacity: 1;
    visibility: visible;
    width: 100%;
    box-shadow: none;
    background: transparent;
    border: none;
    border-left: 2px solid var(--line);
    border-radius: 0;
    margin: 0.35rem 0 0.6rem 0.5rem;
    padding: 0 0 0 0.5rem;
  }
  .nav-drop-menu small { display: none; }
  .nav-drop-menu .ndm-all { border-top: none; justify-content: flex-start; }
}

/* ---------- Page hero ---------- */
.page-hero {
  position: relative;
  padding: calc(var(--nav-height) + 3.5rem) 0 3.25rem;
  background:
    radial-gradient(60rem 28rem at 50% -12rem, rgba(99, 102, 241, 0.18), transparent 65%),
    var(--bg-primary);
  border-bottom: 1px solid var(--line);
  text-align: center;
}
.page-hero .container { max-width: 900px; }
.hero-emoji { font-size: 2.9rem; line-height: 1; display: block; margin-bottom: 0.75rem; }
.page-title {
  font-size: clamp(1.9rem, 4.4vw, 3rem);
  font-weight: 900;
  letter-spacing: -0.025em;
  line-height: 1.12;
  margin-bottom: 0.9rem;
}
.page-sub {
  font-size: clamp(0.98rem, 1.7vw, 1.12rem);
  color: var(--ink-2);
  max-width: 40rem;
  margin: 0 auto;
  line-height: 1.65;
}
.hero-stat-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.75rem;
}
.page-hero .hero-cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.85rem;
  margin-top: 1.75rem;
}

/* ---------- Breadcrumbs ---------- */
.crumbs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  color: var(--ink-3);
  margin-bottom: 1.5rem;
}
.crumbs a { color: var(--ink-2); transition: color 0.2s ease; }
.crumbs a:hover { color: var(--accent); }
.crumbs span[aria-current] { color: var(--ink); font-weight: 600; }

/* ---------- Answer block (answer-engine friendly summary) ---------- */
.answer-block {
  text-align: left;
  max-width: 46rem;
  margin: 2rem auto 0;
  background: linear-gradient(180deg, rgba(99, 102, 241, 0.08), rgba(99, 102, 241, 0.02));
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  padding: 1.4rem 1.6rem;
}
.answer-label {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 0.5rem;
}
.answer-text {
  font-size: 0.95rem;
  line-height: 1.75;
  color: var(--ink-2);
  margin: 0;
}
.answer-text strong { color: var(--ink); }

/* ---------- Category cards ---------- */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(255px, 1fr));
  gap: 1.1rem;
  margin-top: 2.5rem;
}
.cat-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.4rem;
  transition: border-color 0.22s ease, transform 0.22s ease, background 0.22s ease;
}
.cat-card:hover {
  border-color: var(--line-strong);
  background: var(--surface-3);
  transform: translateY(-3px);
}
.cat-card-icon { font-size: 1.9rem; line-height: 1; margin-bottom: 0.85rem; }
.cat-card h3 {
  font-size: 1.02rem;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 0.4rem;
  line-height: 1.3;
}
.cat-card p {
  font-size: 0.85rem;
  color: var(--ink-2);
  line-height: 1.6;
  flex: 1;
  margin-bottom: 1rem;
}
.cat-card-more { font-size: 0.8rem; font-weight: 700; color: var(--accent); }

/* ---------- Actor grid & cards ---------- */
.actors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(318px, 1fr));
  gap: 1.1rem;
  margin-top: 2rem;
}
.actor-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color 0.22s ease, transform 0.22s ease, box-shadow 0.22s ease;
}
.actor-card:hover {
  border-color: var(--line-strong);
  transform: translateY(-3px);
  box-shadow: var(--lift);
}
.actor-card-overlay { position: absolute; inset: 0; z-index: 1; }
.actor-card-header {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  padding: 1.35rem 1.4rem 0.9rem;
}
.actor-card-icon { font-size: 1.85rem; line-height: 1; flex-shrink: 0; }
.actor-card-meta { flex: 1; min-width: 0; }
.actor-card-name {
  font-size: 1rem;
  font-weight: 800;
  color: var(--ink);
  line-height: 1.32;
  margin: 0 0 0.35rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.64rem;
}
.actor-card-tagline {
  font-size: 0.83rem;
  color: var(--ink-2);
  line-height: 1.55;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 3.85rem;
}
.actor-card-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding: 0 1.4rem 1.1rem;
  margin-top: auto;
}
.actor-card-ctas {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
  padding: 0.9rem 1.4rem 1.2rem;
  border-top: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.22);
}
.actor-card-ctas .btn {
  justify-content: center;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 0.6rem 0.7rem;
  border-radius: var(--radius-sm);
}
@media (max-width: 480px) {
  .actors-grid { grid-template-columns: 1fr; }
}

/* Stat pills */
.stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  font-size: 0.73rem;
  color: var(--ink-2);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.18rem 0.65rem;
  white-space: nowrap;
}
.stat-pill.price {
  color: var(--ok);
  border-color: rgba(52, 211, 153, 0.3);
  background: rgba(52, 211, 153, 0.07);
  font-weight: 700;
}

/* ---------- Filter bar ---------- */
.filter-bar {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}
.filter-bar .search-input { flex: 1 1 320px; min-width: 0; }
.filter-sort { flex: 0 0 auto; width: auto; min-width: 170px; }
.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}
.chip {
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ink-2);
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.42rem 0.9rem;
  transition: all 0.18s ease;
}
.chip:hover { border-color: var(--line-strong); color: var(--ink); }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }

.empty-state { text-align: center; padding: 3rem 1rem; color: var(--ink-2); }
.empty-state p { margin-bottom: 1.1rem; }

/* ---------- Steps ---------- */
.steps-grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.1rem;
  margin-top: 2.5rem;
  padding: 0;
}
.steps-grid li {
  position: relative;
  min-width: 0;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.35rem 1.35rem;
}
.steps-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--gradient);
  color: #fff;
  font-weight: 800;
  font-size: 0.9rem;
  margin-bottom: 0.85rem;
}
.steps-grid strong {
  display: block;
  font-size: 0.96rem;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 0.4rem;
  line-height: 1.35;
}
.steps-grid p {
  font-size: 0.86rem;
  color: var(--ink-2);
  line-height: 1.65;
  margin: 0;
}

/* ---------- FAQ (<details> variant) ---------- */
details.faq-item {
  padding: 0;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: hidden;
}
details.faq-item summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.05rem 1.3rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.5;
}
details.faq-item summary::-webkit-details-marker { display: none; }
details.faq-item summary::after {
  content: "+";
  flex-shrink: 0;
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--accent);
  line-height: 1;
  transition: transform 0.2s ease;
}
details.faq-item[open] summary::after { transform: rotate(45deg); }
details.faq-item > p {
  padding: 0 1.3rem 1.2rem;
  margin: 0;
  font-size: 0.9rem;
  color: var(--ink-2);
  line-height: 1.75;
}
details.faq-item > p a { color: var(--accent); text-decoration: underline; }

/* ---------- Panels & forms ---------- */
.card-panel {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  padding: 2rem;
  margin-top: 2.5rem;
}
.card-panel-lead {
  margin-top: 0;
  border-color: var(--line-strong);
  box-shadow: var(--lift);
}
@media (max-width: 560px) { .card-panel { padding: 1.35rem; } }

.suggest-form { display: flex; flex-direction: column; gap: 1.1rem; }
.form-grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
  gap: 1.1rem;
}
.form-group { display: flex; flex-direction: column; gap: 0.4rem; min-width: 0; }
.form-label { font-size: 0.83rem; font-weight: 700; color: var(--ink-2); }
.form-hint { font-size: 0.76rem; color: var(--ink-3); line-height: 1.55; }
.form-input {
  width: 100%;
  box-sizing: border-box;
  min-width: 0;
  background: var(--bg-primary);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.72rem 1rem;
  color: var(--ink);
  font-family: inherit;
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.2s ease;
}
.form-input:focus { border-color: var(--accent); }
.form-input::placeholder { color: var(--ink-3); }
.form-textarea { resize: vertical; min-height: 92px; }
.form-msg {
  display: none;
  padding: 0.9rem 1.1rem;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  line-height: 1.6;
}
.form-msg.ok {
  display: block;
  background: rgba(52, 211, 153, 0.1);
  border: 1px solid rgba(52, 211, 153, 0.3);
  color: var(--ok);
}
.form-msg.err {
  display: block;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #f87171;
}

/* ---------- Referral band ---------- */
.ref-band-wrap { padding-top: 0; }
.ref-band {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 2.5rem;
  align-items: center;
  background:
    radial-gradient(36rem 20rem at 12% 0%, rgba(139, 92, 246, 0.16), transparent 70%),
    var(--surface-2);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
}
.ref-band-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.13em;
  color: var(--accent);
  margin-bottom: 0.7rem;
}
.ref-band h2 {
  font-size: clamp(1.35rem, 2.6vw, 1.95rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 0.8rem;
}
.ref-band p {
  font-size: 0.93rem;
  color: var(--ink-2);
  line-height: 1.75;
  margin-bottom: 1.1rem;
}
.ref-band-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.5rem 1.25rem;
  padding: 0;
}
.ref-band-list li {
  position: relative;
  padding-left: 1.5rem;
  font-size: 0.86rem;
  color: var(--ink-2);
  line-height: 1.55;
}
.ref-band-list li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  color: var(--ok);
  font-weight: 800;
}
.ref-band-cta { display: flex; flex-direction: column; gap: 0.75rem; }
.ref-band-cta .btn { justify-content: center; text-align: center; }
.ref-band-cta small {
  font-size: 0.72rem;
  color: var(--ink-3);
  text-align: center;
  line-height: 1.5;
}
@media (max-width: 860px) {
  .ref-band { grid-template-columns: 1fr; gap: 1.75rem; padding: 1.75rem; }
}

/* ---------- Footer additions ---------- */
.footer-disclosure {
  font-size: 0.75rem;
  color: var(--ink-3);
  line-height: 1.6;
  max-width: 34rem;
}
.footer-brand .btn { margin-top: 1rem; }

/* ---------- Homepage ---------- */
.split-panel {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  align-items: center;
}
@media (max-width: 860px) { .split-panel { grid-template-columns: 1fr; gap: 1.75rem; } }

.mini-list { display: flex; flex-direction: column; gap: 0.6rem; }
.mini-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.1rem;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.mini-item:hover { border-color: var(--line-strong); transform: translateX(3px); }
.mini-item .mi-icon { font-size: 1.35rem; flex-shrink: 0; }
.mini-item .mi-body { flex: 1; min-width: 0; }
.mini-item strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.mini-item small { font-size: 0.76rem; color: var(--ink-3); }
.mini-item .mi-go { color: var(--accent); font-weight: 800; flex-shrink: 0; }

/* Problem -> solution cards */
.solve-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.1rem;
  margin-top: 2.5rem;
}
.solve-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.6rem 1.5rem;
  transition: border-color 0.22s ease, transform 0.22s ease;
}
.solve-card:hover { border-color: var(--line-strong); transform: translateY(-3px); }
.solve-q {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.11em;
  color: var(--ink-3);
  margin-bottom: 0.5rem;
}
.solve-card h3 {
  font-size: 1.02rem;
  font-weight: 800;
  color: var(--ink);
  line-height: 1.4;
  margin-bottom: 0.6rem;
}
.solve-card p {
  font-size: 0.87rem;
  color: var(--ink-2);
  line-height: 1.7;
  flex: 1;
  margin-bottom: 1.1rem;
}
.solve-card .solve-link { font-size: 0.83rem; font-weight: 700; color: var(--accent); }

/* ---------- Actor detail: related strip ---------- */
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(215px, 1fr));
  gap: 0.9rem;
  margin-top: 1.25rem;
}
.related-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1.1rem;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.related-card:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.related-card .rc-icon { font-size: 1.5rem; margin-bottom: 0.55rem; }
.related-card strong {
  font-size: 0.87rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.4;
  margin-bottom: 0.3rem;
}
.related-card small { font-size: 0.76rem; color: var(--ink-3); line-height: 1.5; }


/* ================================================================
   Actor detail page
   Moved out of the apify_actor.html inline <style> block so the page
   can use the shared head partial like every other template.
   ================================================================ */

    /* ─── Actor page-specific additions ─── */

    .actor-hero-icon {
      font-size: 3.2rem;
      line-height: 1;
      margin-bottom: .75rem;
      display: block;
    }
    .actor-hero-badge {
      display: inline-flex;
      align-items: center;
      gap: .3rem;
      font-size: .72rem;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: .06em;
      padding: .22rem .7rem;
      border-radius: 12px;
      margin-bottom: .6rem;
    }
    .actor-hero-badge.hot  { background: linear-gradient(135deg,#f59e0b,#ef4444); color:#fff; }
    .actor-hero-badge.tip  { background: linear-gradient(135deg,#06b6d4,#3b82f6); color:#fff; }
    .actor-hero-badge.std  { background: var(--accent); color:#fff; }

    .actor-stat-row {
      display: flex;
      flex-wrap: wrap;
      gap: .5rem;
      margin: 1rem 0 1.5rem;
    }
    .actor-stat-chip {
      display: inline-flex;
      align-items: center;
      gap: .3rem;
      font-size: .8rem;
      color: var(--text-secondary);
      background: rgba(255,255,255,.05);
      border: 1px solid var(--border);
      border-radius: 20px;
      padding: .2rem .75rem;
    }
    .actor-stat-chip.price {
      color: #10b981;
      border-color: rgba(16,185,129,.3);
      background: rgba(16,185,129,.07);
      font-weight: 700;
    }

    .actor-hero-ctas {
      display: flex;
      gap: .85rem;
      flex-wrap: wrap;
      margin-top: .25rem;
    }

    /* ─── Article sections ─── */
    .actor-section {
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: 14px;
      padding: 1.6rem 1.75rem;
      margin: 1.75rem 0;
    }
    .actor-section:first-of-type { margin-top: 0; }

    .actor-section-h {
      font-size: 1.05rem;
      font-weight: 800;
      color: var(--text-primary);
      margin: 0 0 1.15rem;
      padding-bottom: .75rem;
      border-bottom: 1px solid var(--border);
      display: flex;
      align-items: center;
      gap: .45rem;
    }

    /* Fields checklist */
    .fields-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(195px, 1fr));
      gap: .45rem;
    }
    .field-item {
      display: flex;
      align-items: flex-start;
      gap: .45rem;
      background: rgba(16,185,129,.04);
      border: 1px solid rgba(16,185,129,.14);
      border-radius: 8px;
      padding: .5rem .75rem;
      font-size: .82rem;
      color: var(--text-secondary);
      line-height: 1.4;
      min-width: 0;
    }
    .field-chk { color: #10b981; font-weight: 700; flex-shrink: 0; margin-top: 1px; }

    /* Use-cases */
    .uc-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
      gap: .8rem;
    }
    .uc-card {
      background: rgba(99,102,241,.04);
      border: 1px solid rgba(99,102,241,.13);
      border-radius: 10px;
      padding: .9rem 1.1rem;
    }
    .uc-card strong {
      display: block;
      font-size: .88rem;
      font-weight: 700;
      color: var(--text-primary);
      margin-bottom: .3rem;
    }
    .uc-card p {
      font-size: .83rem;
      color: var(--text-secondary);
      line-height: 1.6;
      margin: 0;
    }

    /* Steps */
    .steps-ol { list-style: none; padding: 0; margin: 0; counter-reset: steps; }
    .steps-ol li {
      counter-increment: steps;
      display: flex;
      align-items: flex-start;
      gap: .9rem;
      padding: .7rem 0;
      border-bottom: 1px solid rgba(255,255,255,.05);
    }
    .steps-ol li:last-child { border-bottom: none; padding-bottom: 0; }
    .steps-ol li::before {
      content: counter(steps);
      background: var(--accent);
      color: #fff;
      min-width: 24px; height: 24px;
      border-radius: 50%;
      display: flex; align-items: center; justify-content: center;
      font-size: .72rem; font-weight: 700;
      flex-shrink: 0; margin-top: 3px;
    }
    .steps-ol li .step-body { display: flex; flex-direction: column; gap: .2rem; }
    .steps-ol li strong { font-size: .9rem; color: var(--text-primary); }
    .steps-ol li p { font-size: .86rem; color: var(--text-secondary); line-height: 1.65; margin: 0; }

    /* Pricing */
    .pricing-box {
      display: flex;
      align-items: center;
      gap: 1.5rem;
      background: rgba(16,185,129,.05);
      border: 1px solid rgba(16,185,129,.22);
      border-radius: 12px;
      padding: 1.15rem 1.4rem;
      flex-wrap: wrap;
    }
    .pricing-num  { font-size: 2.2rem; font-weight: 900; color: #10b981; white-space: nowrap; line-height: 1; }
    .pricing-unit { font-size: .76rem; color: var(--text-secondary); margin-top: .2rem; }
    .pricing-text { font-size: .88rem; color: var(--text-secondary); line-height: 1.65; flex: 1; min-width: 180px; }

    /* Bottom CTA stripe */
    .actor-cta-stripe {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 1.25rem;
      background: linear-gradient(135deg, rgba(99,102,241,.12) 0%, rgba(139,92,246,.08) 100%);
      border: 1px solid rgba(99,102,241,.3);
      border-radius: 14px;
      padding: 1.5rem 1.75rem;
      margin-top: 1.75rem;
      flex-wrap: wrap;
    }
    .actor-cta-stripe h3 { font-size: 1.05rem; font-weight: 800; color: var(--text-primary); margin: 0 0 .25rem; }
    .actor-cta-stripe p  { font-size: .86rem; color: var(--text-secondary); margin: 0; }
    .actor-cta-btns { display: flex; gap: .75rem; flex-wrap: wrap; }
    .actor-cta-btns .btn { white-space: nowrap; }

    /* Sidebar – actor list */
    .sidebar-actor-list { display: flex; flex-direction: column; gap: .4rem; }
    .sidebar-actor-item {
      display: flex;
      align-items: center;
      gap: .65rem;
      padding: .6rem .85rem;
      border: 1px solid var(--border);
      border-radius: 9px;
      text-decoration: none;
      color: var(--text-secondary);
      font-size: .83rem;
      transition: all .18s;
      background: rgba(255,255,255,.02);
    }
    .sidebar-actor-item:hover {
      border-color: var(--accent);
      color: var(--accent);
      background: rgba(99,102,241,.06);
    }
    .sidebar-actor-item.current {
      border-color: var(--accent);
      background: rgba(99,102,241,.09);
      color: var(--text-primary);
      font-weight: 600;
    }
    .sai-icon { font-size: 1.15rem; flex-shrink: 0; }

    /* Sidebar affiliate CTA */
    .sidebar-actor-cta {
      background: var(--accent);
      color: #fff;
      border: none;
      border-radius: 10px;
      padding: .75rem 1rem;
      font-size: .88rem;
      font-weight: 700;
      text-align: center;
      display: block;
      text-decoration: none;
      transition: background .2s, transform .2s;
      margin-top: .5rem;
    }
    .sidebar-actor-cta:hover { background: var(--accent-2, #7c3aed); transform: translateY(-1px); }

    @media (max-width: 900px) {
      .uc-grid { grid-template-columns: 1fr; }
    }
    @media (max-width: 640px) {
      .actor-section { padding: 1.15rem; }
      .fields-grid { grid-template-columns: 1fr 1fr; }
      .pricing-box { flex-direction: column; align-items: flex-start; gap: .75rem; }
      .actor-cta-stripe { flex-direction: column; }
      .actor-cta-btns { width: 100%; }
      .actor-cta-btns .btn { flex: 1; text-align: center; }
    }
    @media (max-width: 420px) {
      .fields-grid { grid-template-columns: 1fr; }
    }

/* ================================================================
   MOBILE + PERFORMANCE PASS
   ================================================================ */

/* ---------- Scroll reveal (replaces the AOS library) ----------
   `reveal-ready` is added by main.js only when it can actually run the
   reveal, so content is never left invisible if the script fails.
   Vertical-only movement: AOS's horizontal offsets pushed elements past
   the viewport edge, which is what made pages feel wider than the screen. */
.reveal-ready [data-aos] {
  opacity: 0;
  transform: translate3d(0, 18px, 0);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal-ready [data-aos="zoom-in"] { transform: scale(0.95); }
.reveal-ready [data-aos].is-revealed,
.reveal-all [data-aos] { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal-ready [data-aos] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* ---------- Nothing may exceed the viewport ---------- */
/* The canvas is absolutely positioned; without this it can size itself
   from a stale offsetWidth and render wider than the hero. */
.hero-bg, .hero-bg canvas { max-width: 100%; }

/* Long unbroken strings (URLs, slugs) shouldn't push a container open. */
.answer-text, .actor-card-tagline, .cat-card p, .solve-card p,
.related-card strong, .memo-card p { overflow-wrap: anywhere; }

/* Grid/flex children need this to be allowed to shrink below content width. */
.ref-band, .ref-band-text, .ref-band-cta, .split-panel > * { min-width: 0; }
.ref-band-list li { overflow-wrap: anywhere; }

/* ---------- Buttons must never clip their own label ----------
   style.css sets `.btn { white-space: nowrap }` plus `overflow: hidden`
   for the shine effect, so long labels were being cut off mid-word on
   narrow screens instead of wrapping. */
@media (max-width: 640px) {
  .btn {
    white-space: normal;
    text-align: center;
    padding-left: 1.15rem;
    padding-right: 1.15rem;
    max-width: 100%;
  }
  .page-hero .hero-cta .btn,
  .ref-band-cta .btn,
  .actor-cta-btns .btn { width: 100%; }

  /* These carry their own `white-space: nowrap` at higher specificity, so
     they need naming explicitly or their labels stay clipped. */
  .actor-cta-btns .btn,
  .tool-detail-main-cta,
  .post-cta-banner .btn[style] { white-space: normal !important; }
}

/* ---------- Blog card tags: wrap instead of clipping ---------- */
.blog-card-tags {
  flex-wrap: wrap;
  height: auto;
  min-height: 1.6rem;
  overflow: visible;
  row-gap: 0.35rem;
}

/* ---------- /tools card head: let the title wrap ---------- */
@media (max-width: 600px) {
  .tcard-head { flex-wrap: wrap; row-gap: 0.5rem; }
  .tcard-titles { flex: 1 1 100%; }
  .tcard-titles h3 { font-size: 1.05rem; overflow-wrap: anywhere; }
}

/* ---------- Article readability ----------------------------------------
   Body copy used --text-secondary (#9ca3af) at 1rem, which is a label colour,
   not a reading colour, and in-body links used --accent (~3.6:1 on the page
   background — below WCAG AA). Both are lifted here. */
.post-content {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text-body);
}
.post-content p,
.post-content li,
.post-content td { color: var(--text-body); }
.post-content p { margin-bottom: 1.25rem; }
.post-content li { margin-bottom: 0.6rem; }
.post-content ul, .post-content ol { margin-bottom: 1.4rem; }

/* Headings get more air above than below, so each section reads as a block. */
.post-content h2 {
  font-size: 1.55rem;
  line-height: 1.3;
  margin: 3rem 0 1rem;
}
.post-content h3 {
  font-size: 1.2rem;
  line-height: 1.4;
  margin: 2.25rem 0 0.75rem;
}
.post-content h2 + p,
.post-content h3 + p { margin-top: 0; }

/* Links inside body copy: readable indigo instead of the dim brand indigo. */
.post-content a:not(.cta-btn):not(.actor-cta):not(.btn) {
  color: var(--accent-light);
  text-decoration-color: rgba(165, 180, 252, 0.45);
  text-underline-offset: 3px;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}
.post-content a:not(.cta-btn):not(.actor-cta):not(.btn):hover {
  color: #c7d2fe;
  text-decoration-color: #c7d2fe;
}

/* ---------- Tables in article bodies -----------------------------------
   These were `display:block; overflow-x:auto`, which drops the table box and
   leaves cells with no padding and columns that collide (see any post with a
   comparison table). The table is a real table again; main.js wraps it in
   .table-wrap, which is what scrolls on narrow screens. */
.post-content .table-wrap {
  margin: 1.75rem 0;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg-card);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.post-content table {
  width: 100%;
  max-width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  line-height: 1.55;
}
/* Only inside the scroll wrapper — without JS the table still fits by wrapping
   rather than pushing the page sideways. */
.post-content .table-wrap table { min-width: 540px; }

.post-content thead th {
  background: rgba(99, 102, 241, 0.12);
  color: var(--text-primary);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-align: left;
  white-space: nowrap;
  padding: 0.8rem 1.1rem;
  border-bottom: 1px solid var(--border);
}
.post-content td {
  padding: 0.8rem 1.1rem;
  border-top: 1px solid rgba(99, 102, 241, 0.1);
  vertical-align: top;
}
.post-content tbody tr:nth-child(even) { background: rgba(255, 255, 255, 0.02); }
.post-content tbody tr:hover { background: rgba(99, 102, 241, 0.07); }
/* Keep the first column and any link cell on one line — a wrapped product name
   or actor link is what made the columns look interleaved. */
.post-content td:first-child { white-space: nowrap; font-weight: 600; color: var(--text-primary); }
.post-content td a { white-space: nowrap; }

@media (max-width: 640px) {
  .post-content thead th, .post-content td { padding: 0.65rem 0.85rem; }
  .post-content table { font-size: 0.9rem; }
}

.post-content pre, .post-content code { overflow-wrap: anywhere; }
.post-content pre { overflow-x: auto; }
.post-content img { height: auto; }

/* ---------- Images keep their aspect ratio while loading ---------- */
.blog-card-img, .post-banner-img { aspect-ratio: 1200 / 630; object-fit: cover; }

/* ---------- Accessibility: WCAG AA contrast ----------
   The original muted greys and the solid accent all landed between 3.5:1
   and 4.4:1 on these dark surfaces — under the 4.5:1 required for body
   text. Lightened just enough to pass while keeping the same character.
   `--accent` itself is unchanged: it still has to work as a button fill,
   so text usages get `--accent-text` instead. */
:root {
  --ink-3:      #8f97ab;   /* was #737b8f — 3.98:1 */
  --text-muted: #8d95a3;   /* was #6b7280 — 3.49:1 */
  --accent-text: #818cf8;  /* accent for text on dark — 5.65:1 */
}

.cat-card-more,
.solve-card .solve-link,
.answer-label,
.ref-band-tag,
.nav-drop-menu .ndm-all,
.crumbs a:hover,
.empty-state a,
details.faq-item summary::after,
details.faq-item > p a,
.memo-col-add:hover,
.mini-item .mi-go { color: var(--accent-text); }

/* ---------- Tap targets ----------
   Lighthouse wants interactive controls to be at least ~48px on mobile.
   The filter chips and small buttons were ~28-30px tall. */
@media (max-width: 900px) {
  .chip,
  .vt-btn,
  .memo-mini {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }
  .filter-chips { gap: 0.6rem; }
  .nav-drop-menu a,
  .footer-links a,
  .crumbs a { padding-top: 0.35rem; padding-bottom: 0.35rem; }
}

/* ---------- Trademark / non-affiliation notice ----------
   Rendered on actor pages whose subject site is a third-party brand. Kept
   visually quiet but above the fold in the article, so it reads as a genuine
   disclaimer rather than buried boilerplate. */
.actor-disclaimer {
  border: 1px solid var(--line);
  border-left: 3px solid var(--ink-3);
  border-radius: 10px;
  padding: 0.85rem 1.05rem;
  margin: 0 0 1.75rem;
  background: rgba(148, 163, 184, 0.05);
}
.actor-disclaimer p {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.65;
  color: var(--ink-2);
}
.actor-disclaimer .ad-label {
  display: block;
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink-3);
  margin-bottom: 0.3rem;
}
