/* products a: "Grid". Six product areas in a 3x2 grid of cards; each card carries a tiny illustration that
   plays when the card comes into view, lifts on hover and links to the section that shows it. */
.products-a { position: relative; padding: clamp(90px, 12vw, 160px) 0; }
.products-a__head { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 20px 48px; align-items: end; margin-bottom: clamp(40px, 5vw, 64px); }
.products-a__lead { max-width: 42ch; margin: 0 0 8px; }
[data-products-title] > div { padding-bottom: .12em; margin-bottom: -.12em; } /* SplitText line masks: room for descenders */

.products-a__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; perspective: 1400px; }
.products-a__item { display: flex; min-width: 0; }

/* The card is the link. GSAP moves the list item; the card itself keeps its CSS hover lift. */
.products-a__card {
  position: relative; isolation: isolate; flex: 1; min-width: 0;
  display: flex; flex-direction: column; overflow: hidden;
  border-radius: var(--r-card); background: color-mix(in srgb, var(--surface) 88%, transparent); border: 1px solid var(--line);
  transition: transform .6s var(--ease-out), box-shadow .6s var(--ease-out), border-color .3s;
}
.products-a__card:hover, .products-a__card:focus-visible { transform: translateY(-6px); box-shadow: var(--shadow-card); border-color: var(--line-2); }
.products-a__card:focus-visible { outline: 3px solid var(--logo); outline-offset: 3px; border-radius: var(--r-card); }

/* ---- illustration strip ---- */
.products-a__art {
  position: relative; height: 188px; flex: none; overflow: hidden;
  display: grid; place-items: center; align-content: center;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface-2) 70%, transparent);
}
.products-a__art > * { position: relative; }
.products-a__n { position: absolute; left: 18px; top: 16px; font: 500 12px/1 var(--font); letter-spacing: .06em; color: var(--text-2); opacity: .8; }

/* ---- body ---- */
.products-a__body { position: relative; z-index: 1; flex: 1; display: grid; grid-template-rows: auto 1fr auto; gap: 12px; padding: 24px 26px 22px; }
.products-a__title-row { display: flex; align-items: center; gap: 14px; }
.products-a__title { font: 700 var(--t-h2)/1.25 var(--font); letter-spacing: -.01em; }
.products-a__text { font-size: var(--t-medium); line-height: 1.55; color: var(--text-2); max-width: 40ch; }
.products-a__go { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 6px; padding-top: 14px; border-top: 1px solid var(--line); font: 600 14px/1 var(--font); color: var(--text-2); transition: color .3s; }
.products-a__go i { display: grid; place-items: center; color: var(--text-2); transition: color .3s, transform .5s var(--ease-out); }
.products-a__go svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transform: rotate(-45deg); transition: transform .5s var(--ease-out); }
.products-a__card:hover .products-a__go, .products-a__card:focus-visible .products-a__go { color: var(--text); }
.products-a__card:hover .products-a__go i, .products-a__card:focus-visible .products-a__go i { color: var(--accent); transform: translateX(3px); }
.products-a__card:hover .products-a__go svg, .products-a__card:focus-visible .products-a__go svg { transform: rotate(0deg); }

/* shared: abstract "text" lines inside the illustrations (the pictures carry no data of their own) */
.products-a__skel { display: block; width: var(--w, 80px); height: 7px; border-radius: 4px; background: color-mix(in srgb, var(--text) 14%, transparent); }
.products-a__skel--strong { height: 9px; background: color-mix(in srgb, var(--text) 30%, transparent); }

/* ---- 01 Accept: the selection glides across the marks, the secure pay bar fills and ticks ---- */
.products-a__art--accept { gap: 18px; }
.products-a__pay { display: inline-flex; align-items: center; gap: 10px; height: 38px; padding: 0 8px 0 14px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1); }
.products-a__pay-lock { width: 16px; height: 16px; fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.products-a__pay-bar { width: 96px; height: 6px; border-radius: 6px; overflow: hidden; background: color-mix(in srgb, var(--text) 10%, transparent); }
.products-a__pay-bar i { display: block; height: 100%; border-radius: inherit; background: var(--accent); transform-origin: left; }
.products-a__pay-ok { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--ok); }
.products-a__pay-ok svg { width: 13px; height: 13px; fill: none; stroke: var(--on-ok); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.products-a__marks { position: relative; display: flex; gap: 10px; }
.products-a__mark { width: 60px; height: 40px; border-radius: 9px; display: grid; place-items: center; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-1); }
.products-a__mark .m--visa { --m: .95; } .products-a__mark .m--mc { --m: .95; } .products-a__mark .m--apple { --m: .8; } .products-a__mark .m--gpay { --m: .8; }
.products-a__sel { position: absolute; z-index: 1; left: -3px; top: -3px; width: 66px; height: 46px; border-radius: 12px; border: 2px solid var(--accent); pointer-events: none; }

/* ---- 02 Protect: a beam scans the shield; each attempt is passed or stopped ---- */
.products-a__art--protect { grid-template-columns: auto auto; gap: 34px; }
.products-a__shield { position: relative; width: 84px; height: 94px; }
.products-a__shield svg { width: 100%; height: 100%; overflow: visible; }
.products-a__shield-fill { fill: var(--surface-3); }
.products-a__shield-o { fill: none; stroke: var(--line-2); stroke-width: 2; stroke-linejoin: round; }
.products-a__shield-c { fill: none; stroke: var(--ok); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.products-a__beam { position: absolute; left: -14px; right: -14px; top: 0; height: 2px; border-radius: 2px; opacity: 0;
  background: linear-gradient(90deg, transparent, var(--accent-2) 30%, var(--accent-2) 70%, transparent);
  }
.products-a__checks { display: grid; gap: 12px; }
.products-a__checks li { display: flex; align-items: center; gap: 10px; }
.products-a__checks i { position: relative; flex: none; width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--line-2); transition: background-color .3s, border-color .3s, box-shadow .3s; }
.products-a__checks li.is-scan i { border-color: var(--accent); }
.products-a__checks li.is-done i { border-color: var(--ok); background: var(--ok); }
.products-a__checks li.is-done i::after { content: ""; position: absolute; left: 5px; top: 1.5px; width: 5px; height: 9px; border: solid var(--on-ok); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.products-a__checks li.is-block i { border-color: var(--bad); background: var(--bad); }
.products-a__checks li.is-block i::before, .products-a__checks li.is-block i::after { content: ""; position: absolute; left: 3.5px; top: 7px; width: 9px; height: 2px; border-radius: 2px; background: var(--on-bad); transform: rotate(45deg); }
.products-a__checks li.is-block i::after { transform: rotate(-45deg); }

/* ---- 03 Settle: blocks stack up on both sides until the two columns stand level ---- */
.products-a__stacks { position: relative; display: flex; align-items: flex-end; gap: 16px; padding-top: 10px; }
.products-a__stack { display: flex; flex-direction: column-reverse; gap: 4px; width: 56px; height: 100px; padding: 4px; overflow: hidden; border-radius: 10px; background: color-mix(in srgb, var(--text) 5%, transparent); }
.products-a__stack i { height: var(--h); border-radius: 5px; flex: none; }
.products-a__stack--in i { background: color-mix(in srgb, var(--text) 32%, transparent); }
.products-a__stack--in i:nth-child(2) { opacity: .75; } .products-a__stack--in i:nth-child(3) { opacity: .5; }
.products-a__stack--out i { background: var(--accent); }
.products-a__stack--out i:nth-child(2) { opacity: .7; }
.products-a__eq { align-self: center; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font: 500 16px/1 var(--font); color: var(--ok-fg); border: 1px solid color-mix(in srgb, var(--ok) 55%, transparent); }
.products-a__level { position: absolute; left: -12px; right: -12px; top: 13px; height: 0; border-top: 1px dashed var(--ok); }

/* ---- 04 Pay out: money leaves the balance for the bank, a card and a refund ---- */
.products-a__svg { width: 100%; height: 100%; overflow: visible; }
.products-a__art--payout { padding: 0 8px; }
.products-a__tracks path { fill: none; stroke: var(--line-2); stroke-width: 1.5; stroke-dasharray: 3 6; }
.products-a__lines path { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; }
.products-a__bal rect { fill: var(--logo); }
.products-a__bal use { color: #fff; }
.products-a__dest text { font: 500 12px var(--font); fill: var(--text); }
.products-a__dest rect:first-of-type { fill: var(--surface); stroke: var(--line); stroke-width: 1; transition: stroke .4s, fill .4s; }
.products-a__dest-ic { fill: none; stroke: var(--text-2); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; transition: stroke .4s; }
.products-a__dest.is-lit rect:first-of-type { stroke: var(--ok); fill: var(--ok-bg); }
.products-a__dest.is-lit .products-a__dest-ic { stroke: var(--ok-fg); }
.products-a__dest.is-lit text { fill: var(--ok-fg); }
.products-a__coin { fill: var(--accent-2); opacity: 0; }

/* ---- 05 Resolve: a case whose clock runs while evidence is added, then its chip turns green ---- */
.products-a__case { width: min(250px, 84%); display: grid; gap: 14px; padding: 14px 14px 13px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-card); }
.products-a__case-top { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; }
.products-a__case-ic { width: 32px; height: 32px; display: grid; place-items: center; color: var(--text-2); }
.products-a__case-ic svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.products-a__case-lines { display: grid; gap: 6px; }
.products-a__status { display: grid; }
.products-a__chip { grid-area: 1 / 1; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; }
.products-a__chip svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.products-a__chip--warn { color: var(--text-2); background: var(--surface-3); visibility: hidden; } /* the finished state: resolved */
.products-a__chip--ok { color: var(--on-ok); background: var(--ok); }
.products-a__chip--ok svg { stroke-width: 3; }
.products-a__case-foot { display: flex; align-items: center; justify-content: space-between; padding-top: 12px; border-top: 1px solid var(--line); }
.products-a__timer { width: 30px; height: 30px; transform: rotate(-90deg); }
.products-a__timer circle { fill: none; stroke: var(--surface-3); stroke-width: 4; }
.products-a__timer .products-a__timer-v { stroke: var(--accent); stroke-linecap: round; stroke-dasharray: 36 88; }
.products-a__files { display: flex; gap: 6px; }
.products-a__files i { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: var(--surface-2); border: 1px solid var(--line); color: var(--text-2); }
.products-a__files svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* ---- 06 Report: bars and an export ---- */
.products-a__report { width: min(290px, 86%); display: grid; grid-template-columns: 1fr auto; align-items: start; row-gap: 14px; }
.products-a__export { grid-column: 2; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1); }
.products-a__export svg { width: 16px; height: 16px; fill: none; stroke: var(--text-2); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.products-a__bars { grid-column: 1 / -1; height: 78px; display: flex; align-items: flex-end; gap: 6px; }
.products-a__bars i { flex: 1; height: 100%; border-radius: 4px 4px 2px 2px; transform-origin: bottom; transform: scaleY(var(--h));
  background: color-mix(in srgb, var(--text) 22%, transparent); }
.products-a__bars i:last-child { background: var(--ok); }

.products-a__side { display: grid; gap: 22px; }

/* ---- initial states (motion only; landing.js / a.js reveal them) ---- */
.motion .products-a [data-products-fade], .motion .products-a [data-products-title] { visibility: hidden; }
/* Focusable content starts transparent rather than invisible, so the keyboard can still reach it before it is revealed. */
.motion .products-a__item { opacity: 0; }

/* ---- responsive ---- */
@media (max-width: 1080px) {
  .products-a__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 899.98px) {
  .products-a__head { grid-template-columns: 1fr; gap: 18px; align-items: start; }
}
@media (max-width: 640px) {
  .products-a__grid { grid-template-columns: 1fr; gap: 16px; }
  .products-a__art { height: 176px; }
  .products-a__body { padding: 22px 22px 20px; }
}
@media (max-width: 380px) {
  .products-a__mark { width: 54px; }
  .products-a__sel { width: 60px; }
}
/* A failed setup shows the finished section (a.js adds the class). */
.motion .products-a--static [data-products-fade], .motion .products-a--static [data-products-title] { visibility: visible; }
.motion .products-a--static .products-a__item { opacity: 1; }

/* The illustrative transactions run across the full width at the foot of the section. */
.products-a { overflow-x: clip; }
.products-a__ticker { margin-top: clamp(32px, 4vw, 56px); border-bottom: 1px solid var(--line); }
