/* ==========================================================================
   alternatives.css — /alternatives hub + the six competitor comparison pages.
   Additive only; depends on variables.css, base.css, components.css.
   ========================================================================== */

/* Shared helpers (mirrors tools.css so the pages can be used independently). */
.btn--sm { padding: 0.55rem 1rem; font-size: var(--fs-small); gap: 0.4rem; }
.btn--block { display: flex; width: 100%; justify-content: center; margin-top: var(--space-5); }
.section-title { text-align: center; margin-bottom: var(--space-8); }
.container--narrow { max-width: 820px; }
.cta-band__actions { display: flex; gap: var(--space-3); justify-content: center; flex-wrap: wrap; }
.cta-band__actions .btn--ghost { color: #fff; border-color: rgba(255, 255, 255, 0.45); }
.cta-band__actions .btn--ghost:hover { background: rgba(255, 255, 255, 0.12); }

.alt-head { max-width: 720px; margin: 0 auto var(--space-8); text-align: center; }
.alt-head h2 { margin-top: var(--space-2); }
.alt-head .lead { margin-top: var(--space-3); }

/* ==========================================================================
   1. Hero
   ========================================================================== */
.alt-hero {
  position: relative;
  padding: calc(var(--space-16) + 1rem) 0 var(--space-10);
  overflow: hidden;
  background:
    radial-gradient(1000px 460px at 15% -15%, rgba(91, 52, 240, 0.15), transparent 62%),
    radial-gradient(800px 380px at 90% 0%, rgba(37, 21, 159, 0.10), transparent 60%),
    var(--color-bg-alt);
}
.alt-hero::after {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(to right, rgba(37, 21, 159, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(37, 21, 159, 0.04) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(680px 400px at 30% 10%, #000 30%, transparent 100%);
  pointer-events: none;
}
.alt-hero__grid {
  position: relative; z-index: 1;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: var(--space-10);
  align-items: center;
}
.alt-hero--hub > .container { position: relative; z-index: 1; max-width: 860px; }
.alt-hero h1 { font-size: var(--fs-h1); letter-spacing: -0.02em; }
.alt-hero__angle {
  margin-top: var(--space-4);
  font-size: 1.2rem;
  font-weight: var(--fw-semibold);
  color: var(--color-primary);
  padding-left: var(--space-4);
  border-left: 3px solid var(--color-accent);
}
.alt-hero .lead { margin-top: var(--space-4); max-width: 60ch; }
.alt-hero__cta { display: flex; gap: var(--space-3); flex-wrap: wrap; margin-top: var(--space-6); }
.alt-hero__note { margin-top: var(--space-4); font-size: var(--fs-small); color: var(--color-text-muted); }
.alt-hero__note a { color: var(--color-accent); font-weight: var(--fw-semibold); }
@media (max-width: 900px) {
  .alt-hero__grid { grid-template-columns: 1fr; gap: var(--space-8); }
}

/* ---- The versus card ------------------------------------------------------ */
.versus { padding: var(--space-6); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }
.versus__row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--space-3);
  text-align: center;
}
.versus__side { display: flex; flex-direction: column; align-items: center; gap: 0.35rem; min-width: 0; }
.versus__side img { margin-bottom: 0.35rem; }
.versus__name { font-weight: var(--fw-semibold); color: var(--color-text-muted); font-size: 1.05rem; }
.versus__side strong {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  letter-spacing: -0.02em;
  color: var(--color-text-muted);
}
.versus__side strong span { font-size: 0.9rem; font-weight: var(--fw-regular); }
.versus__side em { font-style: normal; font-size: var(--fs-small); color: var(--color-text-muted); }
.versus__side--us strong { color: var(--color-primary); }
.versus__side--us em { color: var(--color-accent); font-weight: var(--fw-semibold); }
.versus__vs {
  display: grid; place-items: center;
  width: 42px; height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  color: #fff;
  font-size: 0.8rem;
  font-weight: var(--fw-bold);
  text-transform: uppercase;
  box-shadow: 0 6px 18px rgba(91, 52, 240, 0.3);
}
.versus__model {
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid var(--color-border);
  font-size: var(--fs-small);
  color: var(--color-text-muted);
  line-height: var(--lh-body);
}
.versus__model strong { color: var(--color-text); }
.versus__stamp { margin-top: var(--space-3); font-size: 0.72rem; color: var(--color-text-muted); }

/* ==========================================================================
   2. At a glance
   ========================================================================== */
.alt-glance {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-5);
}
@media (max-width: 980px) { .alt-glance { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .alt-glance { grid-template-columns: 1fr; } }
.alt-glance__item {
  padding: var(--space-5);
  border-radius: var(--radius-lg);
  transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out);
}
.alt-glance__item:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.alt-glance__k {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--color-text-muted);
  margin-bottom: var(--space-2);
}
.alt-glance__item strong {
  display: block;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  color: var(--color-primary);
  margin-bottom: var(--space-2);
}
.alt-glance__item p { font-size: var(--fs-small); color: var(--color-text-muted); line-height: var(--lh-body); }

/* ==========================================================================
   3. Comparison table
   ========================================================================== */
.cmp-wrap {
  overflow-x: auto;                 /* the table scrolls, the page never does */
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  background: #fff;
  box-shadow: var(--shadow-md);
  -webkit-overflow-scrolling: touch;
}
.cmp { width: 100%; border-collapse: collapse; min-width: 560px; }
.cmp thead th {
  position: sticky; top: 0; z-index: 1;
  background: var(--color-bg-alt);
  padding: var(--space-4) var(--space-5);
  text-align: left;
  font-size: var(--fs-small);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
  border-bottom: 1px solid var(--color-border);
  white-space: nowrap;
}
.cmp thead th.cmp__us,
.cmp tbody td.cmp__us { text-align: center; }
.cmp thead th.cmp__us {
  color: #fff;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
}
.cmp thead th:last-child { text-align: center; }
.cmp tbody th {
  padding: var(--space-4) var(--space-5);
  text-align: left;
  font-weight: var(--fw-medium);
  color: var(--color-text);
  border-bottom: 1px solid var(--color-border);
}
.cmp tbody td {
  padding: var(--space-4) var(--space-5);
  text-align: center;
  border-bottom: 1px solid var(--color-border);
  vertical-align: middle;
}
.cmp tbody tr:last-child th,
.cmp tbody tr:last-child td { border-bottom: 0; }
.cmp tbody tr { transition: background var(--dur-fast) var(--ease-out); }
.cmp tbody tr:hover { background: #f8faff; }
.cmp tbody td.cmp__us { background: rgba(91, 52, 240, 0.045); font-weight: var(--fw-semibold); }

.cmp-yes, .cmp-no {
  display: inline-grid; place-items: center;
  width: 30px; height: 30px; border-radius: 50%;
}
.cmp-yes { background: #e6f6ee; color: #1f7a4d; }
.cmp-no  { background: #f2f4f8; color: #98a1b8; }
.cmp-note { font-size: var(--fs-small); color: var(--color-text-muted); line-height: 1.4; display: inline-block; }
.cmp__us .cmp-note { color: var(--color-primary); }

.cmp-foot {
  margin-top: var(--space-4);
  font-size: var(--fs-small);
  color: var(--color-text-muted);
  text-align: center;
}
.cmp-foot a { color: var(--color-accent); }

/* ==========================================================================
   4. Pricing side by side
   ========================================================================== */
.price-vs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-5);
  align-items: start;
}
@media (max-width: 820px) { .price-vs { grid-template-columns: 1fr; } }
.price-vs__col {
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.price-vs__col--us {
  border: 2px solid transparent;
  background:
    linear-gradient(#fff, #fff) padding-box,
    linear-gradient(135deg, var(--color-primary), var(--color-accent)) border-box;
  box-shadow: var(--shadow-lg);
}
.price-vs__col h3 { font-size: var(--fs-h3); margin-bottom: var(--space-2); }
.price-vs__model {
  font-size: var(--fs-small);
  color: var(--color-text-muted);
  line-height: var(--lh-body);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--color-border);
}
.price-vs__list { list-style: none; display: grid; gap: var(--space-1); margin-top: var(--space-4); flex: 1 1 auto; }
.price-vs__list li {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0 var(--space-4);
  padding: var(--space-3) var(--space-3);
  border-radius: var(--radius-md);
  transition: background var(--dur-fast) var(--ease-out);
}
.price-vs__list li:hover { background: var(--color-bg-alt); }
.price-vs__list li.is-best {
  background: linear-gradient(135deg, rgba(37, 21, 159, 0.06), rgba(91, 52, 240, 0.09));
}
.price-vs__plan { font-weight: var(--fw-semibold); color: var(--color-text); }
.price-vs__plan em {
  font-style: normal;
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.12rem 0.45rem;
  margin-left: 0.4rem;
  border-radius: var(--radius-pill);
  background: var(--color-primary);
  color: #fff;
  vertical-align: middle;
}
.price-vs__amt { font-weight: var(--fw-bold); color: var(--color-primary); white-space: nowrap; }
.price-vs__what {
  grid-column: 1 / -1;
  font-size: var(--fs-small);
  color: var(--color-text-muted);
  margin-top: 0.2rem;
}
.price-vs__src {
  margin-top: var(--space-5);
  font-size: var(--fs-small);
  color: var(--color-text-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.price-vs__src:hover { color: var(--color-accent); }

/* ==========================================================================
   5. The honest section
   ========================================================================== */
.alt-fair {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6);
}
@media (max-width: 900px) { .alt-fair { grid-template-columns: 1fr; gap: var(--space-5); } }
.alt-fair__item { display: flex; gap: var(--space-4); align-items: flex-start; }
.alt-fair__icon {
  flex: 0 0 36px; height: 36px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: #e6f6ee;
  color: #1f7a4d;
}
.alt-fair__item h3 { font-size: 1.05rem; margin-bottom: var(--space-2); }
.alt-fair__item p { font-size: var(--fs-small); color: var(--color-text-muted); line-height: var(--lh-body); }

/* ==========================================================================
   6. Switch-if cards
   ========================================================================== */
.alt-switch {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-5);
}
@media (max-width: 900px) { .alt-switch { grid-template-columns: 1fr; } }
.alt-switch__item {
  position: relative;
  padding: var(--space-6);
  padding-top: var(--space-8);
  border-radius: var(--radius-lg);
  transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out);
}
.alt-switch__item:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.alt-switch__n {
  position: absolute;
  top: calc(-1 * var(--space-4));
  left: var(--space-6);
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  color: #fff;
  font-weight: var(--fw-bold);
  box-shadow: 0 8px 20px rgba(91, 52, 240, 0.3);
}
.alt-switch__item h3 { font-size: 1.1rem; margin-bottom: var(--space-2); }
.alt-switch__item p { color: var(--color-text-muted); font-size: var(--fs-small); line-height: var(--lh-body); }

/* ==========================================================================
   7. Migration steps
   ========================================================================== */
.alt-steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6);
  position: relative;
}
@media (max-width: 900px) { .alt-steps { grid-template-columns: 1fr; } }
.alt-steps li { position: relative; padding-top: var(--space-6); }
.alt-steps li::before {
  /* the connecting rail */
  content: "";
  position: absolute;
  top: 22px; left: 44px; right: -24px;
  height: 2px;
  background: linear-gradient(90deg, var(--color-accent), rgba(91, 52, 240, 0.15));
}
.alt-steps li:last-child::before { display: none; }
@media (max-width: 900px) { .alt-steps li::before { display: none; } }
.alt-steps__n {
  position: absolute;
  top: 0; left: 0;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--color-accent);
  color: var(--color-primary);
  font-weight: var(--fw-bold);
}
.alt-steps li h3 { margin-top: var(--space-6); font-size: 1.1rem; margin-bottom: var(--space-2); }
.alt-steps li p { color: var(--color-text-muted); line-height: var(--lh-body); }
.alt-steps li a { color: var(--color-accent); font-weight: var(--fw-medium); }

/* ==========================================================================
   8. Quotes
   ========================================================================== */
.alt-quotes { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-5); }
@media (max-width: 820px) { .alt-quotes { grid-template-columns: 1fr; } }
.alt-quote { padding: var(--space-6); border-radius: var(--radius-lg); }
.alt-quote blockquote {
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--color-text);
  position: relative;
  padding-left: var(--space-5);
  border-left: 3px solid var(--color-accent);
}
.alt-quote figcaption { margin-top: var(--space-4); padding-left: var(--space-5); }
.alt-quote figcaption strong { display: block; color: var(--color-primary); }
.alt-quote figcaption span { font-size: var(--fs-small); color: var(--color-text-muted); }

/* ==========================================================================
   9. Hub + "compare something else"
   ========================================================================== */
.alt-hub, .alt-others {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-5);
}
@media (max-width: 900px) { .alt-hub, .alt-others { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .alt-hub, .alt-others { grid-template-columns: 1fr; } }

.alt-hub__card, .alt-others__card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  overflow: hidden;
  color: var(--color-text);
  transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out);
}
.alt-hub__card::before, .alt-others__card::before {
  content: "";
  position: absolute;
  inset-inline: 0; top: 0; height: 2px;
  background: linear-gradient(90deg, var(--color-accent), var(--color-primary));
  opacity: 0;
  transition: opacity var(--dur-base) var(--ease-out);
}
.alt-hub__card:hover, .alt-others__card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.alt-hub__card:hover::before, .alt-others__card:hover::before { opacity: 1; }

.alt-hub__vs {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--color-text-muted);
  margin-bottom: var(--space-3);
}
.alt-hub__vs em { font-style: normal; color: var(--color-accent); font-weight: var(--fw-bold); }
.alt-hub__card h2 { font-size: 1.2rem; margin-bottom: var(--space-3); }
.alt-hub__angle { font-weight: var(--fw-medium); color: var(--color-primary); margin-bottom: var(--space-3); }
.alt-hub__model { font-size: var(--fs-small); color: var(--color-text-muted); line-height: var(--lh-body); flex: 1 1 auto; }
.alt-hub__model strong { color: var(--color-text); }
.alt-hub__go { margin-top: var(--space-5); font-weight: var(--fw-semibold); color: var(--color-accent); }

.alt-others__card strong { font-size: 1.05rem; color: var(--color-text); margin-bottom: var(--space-2); }
.alt-others__card span { font-size: var(--fs-small); color: var(--color-text-muted); line-height: var(--lh-body); flex: 1 1 auto; }
.alt-others__card em { font-style: normal; margin-top: var(--space-4); font-weight: var(--fw-semibold); color: var(--color-accent); font-size: var(--fs-small); }

/* ==========================================================================
   10. Rules list (hub)
   ========================================================================== */
.alt-rules { list-style: none; display: grid; gap: var(--space-4); }
.alt-rules li {
  padding: var(--space-5);
  border-radius: var(--radius-md);
  background: #fff;
  border: 1px solid var(--color-border);
  color: var(--color-text-muted);
  line-height: var(--lh-body);
  border-left: 3px solid var(--color-accent);
}
.alt-rules li strong { color: var(--color-text); }
