/* ============================================================
   How it Works — page CSS
   Scope: .hcg-hiw (page-how-it-works.php). Conditionally enqueued
   in hcg_assets() — loaded only on this page.

   Token-based only — no hardcoded surface/text colours. Every
   surface/text colour comes from the theme tokens (--hcg-bg,
   --hcg-surface, --hcg-text, --hcg-muted, ...) so the page is
   correct in every tone (light / dark / auto). Accent tints use
   color-mix() over the brand tokens — still token-driven.

   Reused from theme.css (NOT redefined here):
   .hcg-btn*, .hcg-grad, .hcg-eyebrow, .hcg-section-title,
   .hcg-section-sub, .hcg-split*, .hcg-action-row
   ============================================================ */

/* ---------- Layout primitives ---------- */
.hcg-hiw-band { padding: 96px 0; }
.hcg-hiw-band--surface { background: var(--hcg-surface); }
/* Wrap tracks the theme container so the page breathes on large
   desktop screens (and follows the Customizer container setting). */
.hcg-hiw-wrap { max-width: var(--hcg-container-max, 1440px); margin: 0 auto; padding: 0 28px; }
.hcg-hiw .hcg-eyebrow { display: block; margin-bottom: 14px; }

.hcg-hiw-head { max-width: 760px; margin: 0 auto 56px; text-align: center; }
.hcg-hiw-head .hcg-section-title { font-size: clamp(2rem, 3.4vw, 3rem); }
.hcg-hiw-head .hcg-section-sub { margin: 14px auto 0; text-align: center; }

/* ---------- Hero (centred, process-framed) ---------- */
.hcg-hiw-hero { padding: 116px 0 96px; text-align: center; }
.hcg-hiw-hero__title {
  font-family: var(--hcg-font-heading);
  font-weight: 800;
  font-size: clamp(2.4rem, 4.6vw, 3.9rem);
  line-height: 1.05;
  letter-spacing: -.02em;
  max-width: 20ch;
  margin: 0 auto;
}
.hcg-hiw-hero__sub {
  font-family: var(--hcg-font-heading);
  font-weight: 400;
  font-size: clamp(1.25rem, 2.1vw, 1.8rem);
  line-height: 1.2;
  color: var(--hcg-text-2);
  max-width: 40ch;
  margin: 18px auto 0;
}
.hcg-hiw-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 32px; }
.hcg-hiw-hero__trust { margin-top: 20px; font-size: .85rem; color: var(--hcg-muted); }

/* ---------- The Process — four-step connected flow ----------
   One vertical flow with a gradient spine connecting the nodes:
   the connector makes the sequence visible, so it reads as a
   process, not four loose cards. Capped narrow and centred —
   this is the page centrepiece. */
.hcg-hiw-flow { max-width: 620px; margin: 0 auto; }
.hcg-hiw-step {
  position: relative;
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 22px;
  padding-bottom: 40px;
}
.hcg-hiw-step:last-child { padding-bottom: 0; }
/* the spine — runs from under one node to the next */
.hcg-hiw-step::before {
  content: "";
  position: absolute;
  left: 25px;
  top: 54px;
  bottom: -4px;
  width: 2px;
  background: linear-gradient(180deg, var(--hcg-c1), var(--hcg-c2));
  opacity: .4;
}
.hcg-hiw-step:last-child::before { display: none; }
.hcg-hiw-step__node {
  width: 52px;
  height: 52px;
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  /* the flow always sits on a surface band — bg fill gives the node
     contrast against it in both tones */
  background: var(--hcg-bg);
  border: 1px solid var(--hcg-border-strong);
  color: var(--hcg-text);
  position: relative;
  z-index: 1;
}
.hcg-hiw-step__node .dashicons {
  font-size: 26px;
  width: 26px;
  height: 26px;
  line-height: 1;
}
/* a soft brand ring per step, cycling the three brand hues */
.hcg-hiw-step:nth-child(1) .hcg-hiw-step__node { box-shadow: 0 0 0 4px color-mix(in srgb, var(--hcg-c1) 12%, transparent); }
.hcg-hiw-step:nth-child(2) .hcg-hiw-step__node { box-shadow: 0 0 0 4px color-mix(in srgb, var(--hcg-c2) 12%, transparent); }
.hcg-hiw-step:nth-child(3) .hcg-hiw-step__node { box-shadow: 0 0 0 4px color-mix(in srgb, var(--hcg-c3) 12%, transparent); }
.hcg-hiw-step:nth-child(4) .hcg-hiw-step__node { box-shadow: 0 0 0 4px color-mix(in srgb, var(--hcg-c1) 12%, transparent); }
.hcg-hiw-step__num {
  font-family: var(--hcg-font-mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--hcg-muted);
  display: block;
  margin-bottom: 5px;
}
.hcg-hiw-step__body h3 {
  font-family: var(--hcg-font-heading);
  font-size: 1.3rem;
  margin: 0 0 8px;
}
.hcg-hiw-step__body p {
  color: var(--hcg-text-2);
  font-size: 1rem;
  line-height: 1.62;
  margin: 0;
}

/* ---------- Privacy strip (compact, bordered band) ---------- */
.hcg-hiw-trust {
  padding: 34px 0;
  border-top: 1px solid var(--hcg-border);
  border-bottom: 1px solid var(--hcg-border);
}
.hcg-hiw-trust__label {
  text-align: center;
  font-size: .8rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--hcg-muted);
  margin: 0 0 20px;
}
.hcg-hiw-trust__row {
  display: flex;
  gap: clamp(22px, 5vw, 60px);
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}
.hcg-hiw-trust__item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: .95rem;
  color: var(--hcg-text-2);
}
.hcg-hiw-trust__item .dashicons {
  font-size: 20px;
  width: 20px;
  height: 20px;
  line-height: 1;
  /* brand gradient clipped to the glyph */
  background: var(--hcg-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

/* ---------- The Output — CSS-drawn app frame + formula panel ----------
   No screenshot: the panel is built from theme tokens so it stays
   crisp and correct in every tone. Sits in the .hcg-split visual slot. */
.hcg-hiw-frame {
  border-radius: var(--hcg-r-xl);
  border: 1px solid var(--hcg-border-strong);
  background: var(--hcg-surface);
  overflow: hidden;
  box-shadow: var(--hcg-shadow-lg);
}
/* the section is a surface band — drop the frame onto bg for contrast */
.hcg-hiw-band--surface .hcg-hiw-frame { background: var(--hcg-bg); }
.hcg-hiw-frame__bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--hcg-border);
}
.hcg-hiw-frame__dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--hcg-border-strong);
}
.hcg-hiw-frame__title {
  margin-left: 8px;
  font-family: var(--hcg-font-mono);
  font-size: 11px;
  color: var(--hcg-muted);
}
.hcg-hiw-frame__body { padding: 22px; }

.hcg-hiw-formula__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--hcg-border);
}
.hcg-hiw-formula__brand {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--hcg-font-heading);
  font-weight: 700;
  font-size: 1rem;
}
.hcg-hiw-formula__avatar {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: var(--hcg-gradient);
  flex: 0 0 auto;
}
.hcg-hiw-formula__id {
  font-family: var(--hcg-font-mono);
  font-size: 11px;
  color: var(--hcg-muted);
}
.hcg-hiw-formula__block { margin-top: 16px; }
.hcg-hiw-formula__label {
  font-family: var(--hcg-font-body);
  font-size: .66rem;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--hcg-accent);
  margin-bottom: 9px;
}
.hcg-hiw-formula__diag {
  font-size: .95rem;
  color: var(--hcg-text-2);
  line-height: 1.65;
  margin: 0;
}
.hcg-hiw-formula__row {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 14px;
  padding: 8px 0;
  border-top: 1px solid var(--hcg-border);
  font-size: .92rem;
  color: var(--hcg-text-2);
}
.hcg-hiw-formula__row:first-of-type { border-top: 0; }
.hcg-hiw-formula__zone {
  font-family: var(--hcg-font-mono);
  font-size: .78rem;
  color: var(--hcg-muted);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.hcg-hiw-formula__warn {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  margin-top: 16px;
  padding: 11px 13px;
  border-radius: var(--hcg-r);
  background: color-mix(in srgb, var(--hcg-c3) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--hcg-c3) 30%, transparent);
  font-size: .86rem;
  line-height: 1.5;
  color: var(--hcg-text-2);
}
.hcg-hiw-formula__warn .dashicons {
  flex: 0 0 auto;
  font-size: 16px;
  width: 16px;
  height: 16px;
  line-height: 1;
  margin-top: 1px;
  color: var(--hcg-c3);
}

/* ---------- Does / Doesn't (dashicons: bicolor + mono) ---------- */
.hcg-hiw-does {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  max-width: 860px;
  margin: 0 auto;
}
.hcg-hiw-does__card { border: 1px solid var(--hcg-border); border-radius: var(--hcg-r-xl); padding: 28px; }
.hcg-hiw-does__card h3 { font-family: var(--hcg-font-heading); font-size: 1.2rem; margin: 0 0 16px; }
.hcg-hiw-does__card ul { margin: 0; padding: 0; list-style: none; }
.hcg-hiw-does__card li {
  color: var(--hcg-text-2);
  margin: 12px 0;
  display: flex;
  gap: 11px;
  align-items: flex-start;
}
.hcg-hiw-does__card .dashicons {
  flex: 0 0 auto;
  font-size: 22px;
  width: 22px;
  height: 22px;
  line-height: 1;
}
.hcg-hiw-does__yes { border-top: 3px solid var(--hcg-c1); }
.hcg-hiw-does__no { border-top: 3px solid var(--hcg-muted); }
/* bicolor — brand gradient clipped to the glyph */
.hcg-hiw-does__yes .dashicons {
  background: var(--hcg-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
/* mono */
.hcg-hiw-does__no .dashicons { color: var(--hcg-muted); }
.hcg-hiw-does__copy { text-align: center; color: var(--hcg-text-2); max-width: 60ch; margin: 36px auto 0; }

/* ---------- Final CTA ---------- */
.hcg-hiw-final { text-align: center; padding: 110px 0; }
.hcg-hiw-final .hcg-section-title { font-size: clamp(2.2rem, 4vw, 3.4rem); max-width: 20ch; margin: 0 auto; }
.hcg-hiw-final .hcg-section-sub { margin: 16px auto 0; text-align: center; }
.hcg-hiw-final .hcg-action-row { display: flex; justify-content: center; }

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  .hcg-hiw-band { padding: 64px 0; }
  .hcg-hiw-hero { padding: 84px 0 60px; }
  .hcg-hiw-does { grid-template-columns: 1fr; }
}
