/* Landing page (overrides/home.html). Layout after anfra.ai, colours from extra.css. Everything is scoped to .qh. */

.md-main:has(.qh) { background: var(--qd-bg); }
.md-main:has(.qh) .md-main__inner { margin: 0; display: block; }
.qh {
  --qh-card: #12223a; --qh-line: #22385c; --qh-yes: #4ade80; --qh-no: #f87171;
  color: var(--qd-text); font-size: 16px; line-height: 1.6; padding-bottom: 40px;
}
.qh-wrap { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.qh a { color: var(--qd-mint); }
.qh code { font-family: "JetBrains Mono", ui-monospace, Menlo, monospace; font-size: .86em; background: var(--qd-code);
  border-radius: 4px; padding: .08em .35em; font-variant-ligatures: none; }
.qh h1, .qh h2, .qh h3 { font-family: "Figtree", system-ui, sans-serif; color: #f3f6fb; letter-spacing: -.02em; margin: 0; }
.qh h2 { font-size: clamp(28px, 3.4vw, 40px); line-height: 1.15; font-weight: 700; max-width: 30ch; }

/* ------------------------------------------------------------------------ hero */
.qh-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 56px; align-items: center;
  padding-top: 64px; padding-bottom: 48px; }
.qh-eyebrow { font-family: "JetBrains Mono", monospace; font-size: 13px; color: var(--qd-label); margin: 0 0 18px; }
.qh-eyebrow code { background: none; padding: 0; font-size: 1em; color: inherit; }
.qh h1 { font-size: clamp(36px, 4.6vw, 58px); line-height: 1.06; font-weight: 800; }
.qh h1 span { color: var(--qd-mint); }
.qh-lead { font-size: 18px; color: var(--qd-muted); margin: 22px 0 28px; max-width: 34em; }
.qh-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.qh-cta--center { justify-content: center; }
.qh-btn { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 20px; border-radius: 8px;
  border: 1px solid var(--qh-line); color: var(--qd-text) !important; font-weight: 600; background: rgba(255, 255, 255, .02); }
.qh-btn:hover { background: var(--qd-pill); }
.qh-btn--primary { background: var(--qd-accent); border-color: var(--qd-accent); color: #fff !important; }
.qh-btn--primary:hover { background: var(--qd-accent-hover); border-color: var(--qd-accent-hover); }
.qh-install { display: flex; align-items: center; gap: 10px; margin-top: 18px; padding: 10px 10px 10px 16px; max-width: 460px;
  background: var(--qd-code); border: 1px solid var(--qh-line); border-radius: 8px; }
.qh-install code { background: none; padding: 0; flex: 1; font-size: 14px; color: #dde6f3; }
.qh-install__prompt { color: var(--qd-mint); font-family: "JetBrains Mono", monospace; }
.qh-install--center { margin: 22px auto 0; text-align: left; }
.qh-copy { border: 0; background: none; color: var(--qd-label); cursor: pointer; padding: 4px; border-radius: 4px; display: inline-flex; }
.qh-copy:hover { color: #fff; background: var(--qd-pill); }
.qh-copy.ok { color: var(--qh-yes); }
.qh-note { display: flex; gap: 14px; align-items: center; margin-top: 14px; max-width: 460px; padding: 14px 16px;
  border: 1px solid var(--qh-line); border-radius: 10px; color: var(--qd-muted) !important; font-size: 14px; line-height: 1.5; }
.qh-note svg { color: var(--qd-mint); flex: none; }
.qh-note b { color: var(--qd-text); }
.qh-note u { color: var(--qd-mint); text-decoration: none; }
.qh-note:hover { background: rgba(255, 255, 255, .02); }

.qh-hero__shot { position: relative; }
.qh-frame { display: block; border-radius: 12px; overflow: hidden; border: 1px solid var(--qh-line);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .45); background: #f4f5f4; }
.qh-frame__bar { display: flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; background: #1b2840;
  font: 12px "JetBrains Mono", monospace; color: var(--qd-label); }
.qh-frame__bar i { width: 9px; height: 9px; border-radius: 50%; background: #34476a; }
.qh-frame__bar span { margin-left: 8px; }
.qh-frame img { display: block; width: 100%; height: auto; }
.qh-callout { position: absolute; right: -18px; bottom: -26px; width: 270px; padding: 12px 14px; border-radius: 10px;
  background: #fff; color: #0f1b2d; box-shadow: 0 14px 40px rgba(0, 0, 0, .35); font-size: 13px; line-height: 1.45; }
.qh-callout__head { display: flex; justify-content: space-between; gap: 8px; font-weight: 700; margin-bottom: 6px; }
.qh-callout__head a { color: #2563eb !important; font-weight: 500; font-size: 12px; }
.qh-callout__row b { font-size: 20px; }
.qh-callout__foot { color: #5b6b85; font-size: 12px; margin-top: 4px; }

/* -------------------------------------------------------------------- sections */
.qh-section { padding-top: 88px; }
.qh-sub { color: var(--qd-muted); font-size: 18px; max-width: 46em; margin: 16px 0 0; }
.qh-more { margin: 22px 0 0; font-weight: 600; }

.qh-compare { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 36px; }
.qh-col { border: 1px solid var(--qh-line); border-radius: 12px; padding: 22px 22px 10px; background: var(--qh-card); }
.qh-col h3 { font-size: 18px; margin-bottom: 12px; }
.qh-col--us { border-color: var(--qd-accent); box-shadow: 0 0 0 1px var(--qd-accent) inset, 0 12px 40px rgba(59, 130, 246, .15); }
.qh-col ul { list-style: none; margin: 0; padding: 0; }
.qh-col li { position: relative; padding: 0 0 12px 28px; color: var(--qd-muted); }
.qh-col li::before { position: absolute; left: 0; top: 0; font-weight: 700; }
.qh-col li.yes::before { content: "✓"; color: var(--qh-yes); }
.qh-col li.no::before { content: "✕"; color: var(--qh-no); }

.qh-flow { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; gap: 18px; align-items: center; margin-top: 36px; }
.qh-flow__col { display: flex; flex-direction: column; gap: 12px; }
.qh-flow__arrow { color: var(--qd-mint); font-size: 28px; }
.qh-box { border: 1px solid var(--qh-line); border-radius: 10px; padding: 14px 16px; background: var(--qh-card); }
.qh-box code { background: none; padding: 0; font-size: 15px; color: #f3f6fb; }
.qh-box b { color: #f3f6fb; }
.qh-box small { display: block; color: var(--qd-label); font-size: 13px; margin-top: 2px; }
.qh-box--core { text-align: center; padding: 28px 16px; border-color: var(--qd-accent);
  background: linear-gradient(180deg, rgba(59, 130, 246, .18), rgba(59, 130, 246, .04)); }
.qh-box--core b { font-size: 22px; }
.qh-steps3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; margin: 36px 0 0; padding: 0;
  list-style: none; counter-reset: s; }
.qh-steps3 li { counter-increment: s; color: var(--qd-muted); font-size: 15px; }
.qh-steps3 li::before { content: counter(s); display: flex; align-items: center; justify-content: center; width: 28px; height: 28px;
  border-radius: 50%; background: var(--qd-pill); color: var(--qd-mint); font-weight: 700; font-size: 14px; margin-bottom: 10px; }
.qh-steps3 b { color: var(--qd-text); }

.qh-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 40px; align-items: start; margin-top: 32px; }
.qh-tabs { border: 1px solid var(--qh-line); border-radius: 12px; overflow: hidden; background: var(--qd-code); }
.qh-tabs__bar { display: flex; border-bottom: 1px solid var(--qh-line); background: var(--qh-card); }
.qh-tabs__bar button { border: 0; background: none; color: var(--qd-label); font: 600 14px "Figtree", sans-serif;
  padding: 12px 18px; cursor: pointer; border-bottom: 2px solid transparent; }
.qh-tabs__bar button[aria-selected="true"] { color: #fff; border-bottom-color: var(--qd-accent); }
.qh-code { margin: 0; padding: 20px 22px; font: 14px/1.7 "JetBrains Mono", ui-monospace, monospace; color: #dde6f3;
  white-space: pre; overflow-x: auto; background: none; font-variant-ligatures: none; }
.qh-code .c { color: #6f84a8; }
.qh-code b { color: #8cc2ff; }
.qh-code i { font-style: normal; color: #fbbf24; }
.qh-figure { margin: 0; }
.qh-figure img { display: block; width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--qh-line);
  box-shadow: 0 20px 50px rgba(0, 0, 0, .35); }
.qh-figure figcaption { color: var(--qd-label); font-size: 14px; margin-top: 12px; }

.qh-steps4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 32px 0 0; padding: 0; list-style: none; }
.qh-steps4 li { border: 1px solid var(--qh-line); border-radius: 12px; padding: 20px; background: var(--qh-card); min-width: 0; }
.qh-steps4 span { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%;
  background: var(--qd-accent); color: #fff; font-weight: 700; font-size: 14px; }
.qh-steps4 b { display: block; margin: 12px 0 8px; font-size: 17px; }
.qh-steps4 code { display: block; padding: 8px 10px; overflow-wrap: anywhere; }
.qh-steps4 small { display: block; color: var(--qd-label); margin-top: 8px; font-size: 13px; }
.qh-steps4 small code { display: inline; padding: .08em .35em; }

.qh-gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 32px; }
.qh-card { display: block; border: 1px solid var(--qh-line); border-radius: 12px; overflow: hidden; background: var(--qh-card);
  color: var(--qd-text) !important; transition: transform .15s, border-color .15s; }
.qh-card:hover { transform: translateY(-2px); border-color: var(--qd-accent); }
.qh-card img { display: block; width: 100%; height: auto; }
.qh-card__meta { padding: 16px 18px 18px; }
.qh-card__meta b { font-size: 18px; }
.qh-card__meta p { color: var(--qd-muted); font-size: 14px; margin: 6px 0 10px; }
.qh-card__meta span { color: var(--qd-mint); font-weight: 600; font-size: 14px; }

.qh-list { margin: 0 0 24px; padding-left: 20px; color: var(--qd-muted); }
.qh-list li { margin-bottom: 10px; }
.qh-comment { border: 1px solid var(--qh-line); border-radius: 10px; overflow: hidden; font-size: 14px; }
.qh-comment__head { padding: 10px 14px; background: var(--qh-card); border-bottom: 1px solid var(--qh-line); color: var(--qd-label); }
.qh-comment__head b { color: var(--qd-text); }
.qh-comment__body { padding: 14px; }
.qh-comment__body p { margin: 0 0 10px; color: var(--qd-muted); }
.qh-comment__body p.h { color: var(--qd-text); font-weight: 700; font-size: 15px; }
.qh-comment__body table { border-collapse: collapse; width: 100%; font-size: 13px; }
.qh-comment__body th, .qh-comment__body td { border: 1px solid var(--qh-line); padding: 6px 8px; text-align: left; color: var(--qd-muted); }
.qh-comment__body th { color: var(--qd-text); background: rgba(255, 255, 255, .03); }

.qh-faq h2 { margin-bottom: 20px; }
.qh-faq details { border-bottom: 1px solid var(--qh-line); padding: 16px 0; max-width: 820px; }
.qh-faq summary { cursor: pointer; font-weight: 600; font-size: 17px; color: var(--qd-text); list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.qh-faq summary::-webkit-details-marker { display: none; }
.qh-faq summary::after { content: "+"; color: var(--qd-mint); font-size: 22px; line-height: 1; }
.qh-faq details[open] summary::after { content: "–"; }
.qh-faq details p { color: var(--qd-muted); margin: 10px 0 0; }

.qh-final { text-align: center; padding-top: 96px; padding-bottom: 24px; }
.qh-final h2 { margin: 0 auto; }
.qh-final__note { color: var(--qd-label); font-size: 14px; margin: 12px 0 22px; }

/* ------------------------------------------------------------------- responsive */
@media (max-width: 960px) {
  .qh-hero, .qh-split { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .qh-hero { padding-top: 40px; }
  .qh-callout { right: 8px; bottom: -22px; }
  .qh-compare, .qh-steps3 { grid-template-columns: minmax(0, 1fr); }
  .qh-steps4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .qh-flow { grid-template-columns: minmax(0, 1fr); }
  .qh-flow__arrow { transform: rotate(90deg); justify-self: center; }
  .qh-section { padding-top: 64px; }
}
@media (max-width: 600px) {
  .qh-wrap { padding: 0 16px; }
  .qh-steps4, .qh-gallery { grid-template-columns: minmax(0, 1fr); }
  .qh-callout { position: static; width: auto; margin-top: 12px; }
  .qh-lead, .qh-sub { font-size: 16px; }
}

/* author credit */
.qh-eyebrow a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.qh-eyebrow a:hover { color: var(--qd-mint); }
.qh-author { display: flex; justify-content: center; padding-top: 40px; padding-bottom: 8px; }
.qh-author__card { display: flex; align-items: center; gap: 14px; padding: 12px 18px 12px 12px; border: 1px solid var(--qh-line);
  border-radius: 999px; color: var(--qd-text) !important; background: rgba(255, 255, 255, .02); }
.qh-author__card:hover { border-color: var(--qd-mint); }
.qh-author__card img { width: 48px; height: 48px; border-radius: 50%; }
.qh-author__card small { display: block; font-size: 12px; color: var(--qd-label); }
.qh-author__card b { display: block; font-size: 16px; }
.qh-author__gh { color: var(--qd-mint); font-size: 14px; margin-left: 10px; }
@media (max-width: 600px) { .qh-author__gh { display: none; } }
