/* ============================================================================
   Xeno Executor — components.css
   Script cards, injector cards, pill chips, the dark "terminal window" code
   block, the <select> filter bar, table of contents, FAQ, feature grid, install
   steps, and the longread components (byline, tables, screenshot placeholders,
   callouts, glossary, pros/cons). Soft shadows on white cards are this theme's
   signature look.
   ========================================================================== */

/* ── Card grid ─────────────────────────────────────────────────────────── */
.cardgrid {
  display: grid; gap: 20px;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  align-items: start;
}
.cardgrid--wide { grid-template-columns: repeat(auto-fill, minmax(360px, 1fr)); }

/* ── Pill chips (fully rounded pills — this theme's chip style) ─────────────── */
.pill {
  display: inline-flex; align-items: center; gap: 4px;
  border-radius: var(--r-pill); font-size: 11px; font-weight: 600; text-transform: uppercase;
  letter-spacing: .04em; padding: 4px 10px; line-height: 1.3;
  background: var(--brand-soft); color: var(--brand);
}
.pill--game { background: var(--surface); border: 1px solid var(--line); color: var(--text); text-transform: none; font-weight: 600; font-size: 12px; }
.pill--ver { font-family: var(--ff-code); text-transform: none; letter-spacing: 0; background: var(--sheet); border: 1px solid var(--brand); color: var(--brand); }
.pill--key { background: var(--brand); color: var(--on-brand); }
.pill--safe { background: rgba(20,145,95,.12); color: var(--live); }
.pill--ok  { background: rgba(20,145,95,.12); color: var(--live); text-transform: none; }
.pill--warn{ background: rgba(180,83,9,.12); color: var(--hold); text-transform: none; }

/* ── Feature grid ──────────────────────────────────────────────────────── */
.featgrid { list-style: none; padding: 0; margin: 0 0 10px; display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.featgrid__item {
  position: relative; background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-card);
  box-shadow: var(--shadow); padding: 14px 16px 14px 42px; color: var(--text);
}
.featgrid__item::before {
  content: '✕'; position: absolute; left: 15px; top: 14px; color: var(--brand);
  font-weight: 700; font-size: 13px;
}

/* ── Install / ordered steps ───────────────────────────────────────────── */
.stepflow { list-style: none; padding: 0; margin: 0 0 18px; counter-reset: step; display: grid; gap: 12px; }
.stepflow__step {
  position: relative; padding: 14px 16px 14px 56px; counter-increment: step;
  background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow);
}
.stepflow__step::before {
  content: counter(step); position: absolute; left: 14px; top: 12px;
  width: 30px; height: 30px; border-radius: var(--r-pill);
  background: var(--brand-soft); color: var(--brand); font-family: var(--ff-head); font-weight: 700;
  display: grid; place-items: center; font-size: 15px;
}

/* ── Table of contents (.jumpto) ───────────────────────────────────────── */
.jumpto {
  background: var(--sheet); border: 1px solid var(--line); border-left: 3px solid var(--brand);
  border-radius: var(--r-card); box-shadow: var(--shadow); padding: 14px 18px; margin: 0 0 26px;
}
.jumpto__label { display: block; font-family: var(--ff-code); color: var(--dim); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 6px; }
.jumpto__list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; }
.jumpto__list a { color: var(--brand); font-weight: 600; }
.jumpto__list a:hover { text-decoration: underline; }

/* ── FAQ (details/summary) ─────────────────────────────────────────────── */
.faqbox { display: grid; gap: 10px; max-width: 80ch; }
.faqbox__item { background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow); overflow: hidden; }
.faqbox__q { cursor: pointer; padding: 15px 44px 15px 18px; font-family: var(--ff-head); font-size: 16px; list-style: none; position: relative; }
.faqbox__q::-webkit-details-marker { display: none; }
.faqbox__q::after { content: '+'; position: absolute; right: 18px; top: 50%; transform: translateY(-50%); color: var(--brand); font-family: var(--ff-code); font-size: 20px; line-height: 1; }
.faqbox__item[open] .faqbox__q::after { content: '\2013'; }
.faqbox__a { padding: 0 18px 16px; color: var(--dim); }
.faqbox__a p { margin: 0; }
.faqbox__a a { color: var(--brand); text-decoration: underline; }

/* ── Injector cards (/analogi/) ────────────────────────────────────────── */
.altbox { background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow); padding: 20px; transition: box-shadow .15s, transform .12s; }
.altbox:hover { box-shadow: var(--shadow-hi); transform: translateY(-2px); }
.altbox__head { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.altbox__mono { width: 46px; height: 46px; flex: none; border-radius: var(--r-btn); background: var(--brand-soft); color: var(--brand); font-family: var(--ff-head); font-size: 22px; display: grid; place-items: center; }
.altbox__id { min-width: 0; }
.altbox__name { font-size: 19px; margin: 0; }
.altbox__platform { color: var(--dim); font-size: 13px; margin: 2px 0 0; font-family: var(--ff-code); }
.altbox__flags { margin-left: auto; display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.altbox__desc { color: var(--dim); margin: 0 0 12px; }
.altbox__perks { list-style: none; padding: 0; margin: 0 0 12px; display: grid; gap: 6px; }
.altbox__perks li { position: relative; padding-left: 22px; font-size: 14px; }
.altbox__perks li::before { content: '✕'; position: absolute; left: 0; color: var(--brand); font-size: 11px; top: 3px; }
.altbox__steps { margin: 0 0 14px; padding-left: 1.2em; color: var(--dim); font-size: 14px; }
.altbox__steps li { margin-bottom: 4px; }
.altbox__btn { width: 100%; }

/* ── Empty state ───────────────────────────────────────────────────────── */
.emptybox {
  background: var(--sheet); border: 1px dashed var(--line); border-radius: var(--r-card);
  padding: 30px; text-align: center; color: var(--dim);
}
.emptybox a { color: var(--brand); text-decoration: underline; }

/* ── Long-form content (longreads): sub-headings, lead paragraph ──────────── */
.block h3 { font-size: clamp(18px, 2.6vw, 22px); margin: 26px 0 10px; }
.block h4 { font-size: 17px; margin: 18px 0 8px; }
.leadp { font-size: 18px; color: var(--text); }
.block > ul:not([class]), .block > ol:not([class]) { display: grid; gap: 8px; }
.block > ul:not([class]) li, .block > ol:not([class]) li { padding-left: 2px; }

/* ── TL;DR / quick-answer box (top of longreads — helps readers + AI extraction) ── */
.tldr { background: var(--brand-soft); border: 1px solid var(--line); border-left: 3px solid var(--brand); border-radius: var(--r-card); box-shadow: var(--shadow); padding: 16px 18px; margin: 0 0 24px; }
.tldr__label { display: block; font-family: var(--ff-head); font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--brand); margin-bottom: 4px; }
.tldr p { margin: 0; color: var(--text); }
.tldr a { color: var(--brand); text-decoration: underline; }

/* ── E-E-A-T byline / page meta bar ──────────────────────────────────────── */
.byline {
  display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 0 0 22px; padding: 12px 16px;
  background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow);
  font-size: 13px; color: var(--dim);
}
.byline__item { display: inline-flex; align-items: center; gap: 6px; }
.byline strong { color: var(--text); font-weight: 600; }

/* ── Content tables (scroll on mobile) ───────────────────────────────────── */
.tablebox { overflow-x: auto; margin: 18px 0; border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow); }
.xtable { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 460px; background: var(--sheet); }
.xtable th, .xtable td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.xtable thead th { background: var(--brand-soft); color: var(--text); font-weight: 600; font-family: var(--ff-text); white-space: nowrap; }
.xtable tbody tr:last-child td { border-bottom: 0; }
.xtable td:first-child { color: var(--text); font-weight: 600; }

/* ── Image placeholders (figures for future screenshots) ─────────────────── */
.shotph { margin: 18px 0; }
.shotph__frame {
  aspect-ratio: 16 / 9; border: 1px dashed var(--line); border-radius: var(--r-card); background: var(--sheet);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  color: var(--dim); text-align: center; padding: 18px;
}
.shotph__ico { font-size: 26px; opacity: .6; }
.shotph__hint { font-family: var(--ff-code); font-size: 12px; letter-spacing: .04em; }
.shotph__cap { margin: 8px 2px 0; font-size: 13px; color: var(--dim); }
.shotph__cap b { color: var(--text); font-weight: 600; }
/* real screenshot (xex_figure) — actual <img> instead of the dashed placeholder */
.shotph__img { display: block; width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow); background: var(--terminal); }

/* ── Callouts / notes ────────────────────────────────────────────────────── */
.callout { border: 1px solid var(--line); border-left: 3px solid var(--brand); border-radius: var(--r-card); box-shadow: var(--shadow); background: var(--sheet); padding: 14px 18px; margin: 18px 0; }
.callout--warn { border-left-color: var(--hold); }
.callout__t { display: block; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.callout p:last-child { margin-bottom: 0; }
.callout a { color: var(--brand); text-decoration: underline; }

/* ── Glossary / definition list ──────────────────────────────────────────── */
.terms { display: grid; gap: 10px; margin: 18px 0; }
.terms__item { background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow); padding: 12px 16px; }
.terms__t { font-weight: 600; color: var(--text); }
.terms__d { color: var(--dim); margin: 2px 0 0; }

/* ── Pros / cons ─────────────────────────────────────────────────────────── */
.weigh { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 18px 0; }
.weigh__col { background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow); padding: 16px; }
.weigh__col h4 { margin: 0 0 8px; }
.weigh--pro h4 { color: var(--live); }
.weigh--con h4 { color: var(--hold); }
.weigh__col ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.weigh__col li { position: relative; padding-left: 20px; font-size: 14px; color: var(--dim); }
.weigh--pro li::before { content: '+'; position: absolute; left: 0; color: var(--live); font-weight: 700; }
.weigh--con li::before { content: '\2212'; position: absolute; left: 0; color: var(--hold); font-weight: 700; }
@media (max-width: 560px) { .weigh { grid-template-columns: 1fr; } }

/* ── Ad slot (restyled narrower by gate.css on the funnel pages) ──────────── */
.ad-slot { min-height: 90px; margin: 20px 0; }
.ad-slot:empty { min-height: 90px; }

@media (max-width: 480px) {
  .cardgrid, .cardgrid--wide { grid-template-columns: 1fr; }
}
