/*
   KlerkIt Gateway homepage ("/", Views/Home/Gateway.cshtml). Loaded only by that view; every class is .gw-* scoped.
   No external fonts or icon fonts.

   Layout modes (gateway.js uses the same media queries):
     >= 1180px wide and >= 600px high : one screen, copy | stage; the stage canvas is scaled to fit width AND height.
     >= 1180px wide, < 600px high      : same two columns, canvas scaled to width, page scrolls.
     900 - 1179px                      : copy above the stage, canvas scaled to width.
     < 900px                           : no canvas; the same cards become a vertical flow with arrows (no tiny nodes).
*/
:root {
    --gw-ink: #11294a;
    --gw-ink-2: #173d61;
    --gw-text: #34546e;
    --gw-muted: #56708a;
    --gw-small: #57708a;
    --gw-line: #dbe8f3;
    --gw-card: rgba(255, 255, 255, .96);
    --gw-bg: #f8fbff;
    --gw-gutter: clamp(16px, 3vw, 56px);
    --gw-radius: 16px;
    --gw-shadow: 0 14px 36px rgba(30, 98, 150, .10), 0 2px 6px rgba(17, 100, 155, .06);
    --gw-ease: cubic-bezier(.22, .8, .26, 1);
    --gw-focus: #0b63ff;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
body {
    background: var(--gw-bg);
    color: var(--gw-ink);
    font-family: Inter, "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}
a:focus-visible { outline: 3px solid var(--gw-focus); outline-offset: 3px; }
.gw-sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.gw-ico { width: 1em; height: 1em; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- page frame ---------- */
.gw-page { position: relative; isolation: isolate; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; overflow: hidden; }
.gw-ambient { position: absolute; inset: 0; z-index: -1; pointer-events: none; overflow: hidden;
    background: radial-gradient(ellipse at 74% 36%, #edf8ff 0%, rgba(237, 248, 255, 0) 48%), radial-gradient(ellipse at 5% 100%, #e6f5fc 0%, rgba(230, 245, 252, 0) 55%), var(--gw-bg); }
.gw-amb { position: absolute; border-radius: 50%; will-change: transform; }
.gw-amb-1 { right: -8%; top: -18%; width: 64vmax; height: 64vmax; background: radial-gradient(circle, rgba(204, 236, 252, .7) 0%, rgba(204, 236, 252, 0) 62%); animation: gw-breathe 12s ease-in-out infinite alternate; }
.gw-amb-2 { left: -24%; bottom: -42%; width: 58vmax; height: 58vmax; background: radial-gradient(circle, rgba(214, 245, 236, .75) 0%, rgba(214, 245, 236, 0) 62%); animation: gw-breathe 15s ease-in-out infinite alternate-reverse; }
.gw-mesh { position: absolute; inset: 0; background-image: radial-gradient(rgba(70, 120, 160, .13) .9px, transparent .9px); background-size: 26px 26px;
    -webkit-mask-image: linear-gradient(90deg, transparent 22%, #000 62%); mask-image: linear-gradient(90deg, transparent 22%, #000 62%); }

.gw-frame { width: min(1800px, calc(100% - 2 * var(--gw-gutter))); margin: 0 auto; flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }

.gw-header { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 16px; height: clamp(64px, 9vh, 100px); }
.gw-brand { display: inline-flex; align-items: center; gap: 11px; color: var(--gw-ink-2); text-decoration: none; border-radius: 12px; }
.gw-brand-mark { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: linear-gradient(135deg, #1d4ed8, #0ea5e9); color: #fff; font-size: 18px; font-weight: 900; letter-spacing: -.03em; box-shadow: 0 6px 16px rgba(29, 78, 216, .28); }
.gw-brand-name { font-size: 24px; font-weight: 800; letter-spacing: -.03em; }
.gw-langs { display: flex; gap: 4px; padding: 5px; background: #fff; border: 1px solid var(--gw-line); border-radius: 999px; box-shadow: 0 8px 24px rgba(22, 78, 120, .10); }
.gw-lang { display: inline-flex; align-items: center; min-height: 36px; padding: 0 15px; border-radius: 999px; font-size: 14px; font-weight: 650; color: #4b647c; text-decoration: none; white-space: nowrap; transition: background-color .2s, color .2s, box-shadow .2s; }
.gw-lang:hover { color: var(--gw-ink-2); background: #eef6fc; }
.gw-lang.is-active { color: #fff; background: linear-gradient(120deg, #136cca, #1883c4); box-shadow: 0 3px 10px rgba(23, 122, 199, .32); }

/* ---------- copy ---------- */
.gw-main { flex: 1 1 auto; min-height: 0; display: grid; grid-template-columns: minmax(0, 35fr) minmax(0, 65fr); grid-template-rows: minmax(0, 1fr); gap: clamp(20px, 2.4vw, 48px); padding-bottom: clamp(12px, 2.6vh, 36px); }
.gw-copy { align-self: center; max-width: 720px; padding-bottom: 2vh; }
.gw-copy > * { animation: gw-appear .7s var(--gw-ease) both; }
.gw-copy > :nth-child(2) { animation-delay: .06s; }
.gw-copy > :nth-child(3) { animation-delay: .12s; }
.gw-copy > :nth-child(4) { animation-delay: .18s; }
.gw-copy > :nth-child(5) { animation-delay: .24s; }

.gw-eyebrow { margin: 0 0 clamp(14px, 2.4vh, 26px); font-size: 13px; font-weight: 800; letter-spacing: .24em; text-transform: uppercase; color: #11718a; }
.gw-h1 { margin: 0; font-size: clamp(34px, min(3.35vw, 6.3vh), 66px); line-height: 1.1; letter-spacing: -.035em; font-weight: 800; color: #15304d; text-wrap: balance; }
/* second sentence on its own line; the bottom padding keeps descenders inside the box the gradient (background-clip: text) is painted in,
   the negative margin keeps the line height unchanged */
.gw-h1 em { display: block; margin-top: .08em; padding-bottom: .12em; margin-bottom: -.12em; font-style: normal; color: #1675d1; background: linear-gradient(110deg, #1675d1, #0a9493); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.gw-desc { margin: clamp(14px, 2.6vh, 28px) 0 clamp(18px, 3.4vh, 36px); max-width: 640px; font-size: clamp(15px, min(1.08vw, 2vh), 20px); line-height: 1.65; color: var(--gw-muted); }
:lang(ms) .gw-h1 { font-size: clamp(30px, min(2.95vw, 5.6vh), 58px); }
:lang(zh) .gw-eyebrow { letter-spacing: .14em; }
:lang(zh) .gw-h1 { letter-spacing: 0; line-height: 1.2; }

.gw-ctas { display: flex; flex-wrap: wrap; gap: 14px; }
.gw-cta { display: inline-flex; align-items: center; gap: 12px; min-height: 60px; padding: 9px 18px 9px 11px; border-radius: 16px; text-decoration: none; transition: transform .25s var(--gw-ease), box-shadow .25s, background-color .25s, border-color .25s; }
.gw-cta:hover { transform: translateY(-3px); }
.gw-cta:active { transform: translateY(-1px); }
.gw-cta-ic { width: 42px; height: 42px; flex: none; border-radius: 12px; display: grid; place-items: center; font-size: 21px; }
.gw-cta-label { font-size: 17px; font-weight: 780; line-height: 1.25; }
.gw-cta-arrow { margin-left: 2px; font-size: 18px; transition: transform .25s var(--gw-ease); }
.gw-cta:hover .gw-cta-arrow { transform: translateX(4px); }
.gw-cta-primary { color: #fff; background: linear-gradient(115deg, #1270d4, #0f80c0); box-shadow: 0 12px 26px rgba(23, 119, 205, .28); }
.gw-cta-primary .gw-cta-ic { background: rgba(255, 255, 255, .17); }
.gw-cta-primary:hover { box-shadow: 0 17px 32px rgba(23, 119, 205, .38); }
.gw-cta-secondary { color: #135b8a; background: #fff; border: 1px solid #b7d9ed; box-shadow: 0 9px 24px rgba(18, 99, 155, .08); }
.gw-cta-secondary .gw-cta-ic { background: #e9f5fd; color: #1474c0; }
.gw-cta-secondary:hover { border-color: #7fbfe2; background: #f6fbff; box-shadow: 0 14px 28px rgba(18, 99, 155, .14); }

.gw-benefits { list-style: none; margin: clamp(22px, 4.6vh, 50px) 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; max-width: 680px; }
.gw-benefit { display: flex; align-items: center; gap: 10px; font-size: clamp(12.5px, .8vw, 15px); font-weight: 620; line-height: 1.4; color: var(--gw-text); }
.gw-benefit-ic { width: 42px; height: 42px; flex: none; border-radius: 50%; display: grid; place-items: center; font-size: 19px; background: #fff; border: 1.5px solid #b9daee; color: #1479c9; box-shadow: 0 5px 14px rgba(28, 134, 203, .08); }
.gw-benefit-ic.is-green { color: #0c9a82; border-color: #b5e5d8; }
.gw-benefit-ic.is-indigo { color: #3a64c4; border-color: #c4d2f1; }

/* ---------- stage / canvas ---------- */
.gw-stage { position: relative; min-width: 0; min-height: 0; }
.gw-canvas {
    --gw-scale: .8;
    position: absolute; left: 50%; top: 50%; width: 1000px;
    transform: translate(-50%, -50%) scale(var(--gw-scale)); transform-origin: 50% 50%;
    display: grid; grid-template-columns: 296px minmax(0, 1fr) 270px; grid-template-areas: "in hub prep" "band band band";
}
.gw-js .gw-canvas:not(.is-ready) { opacity: 0; animation: gw-reveal 0s 1.5s forwards; }   /* safety net if the script never runs */
.gw-wires { position: absolute; left: 0; top: 0; z-index: 0; overflow: visible; pointer-events: none; }

.gw-col-in { grid-area: in; display: flex; flex-direction: column; justify-content: center; gap: 12px; }
/* assistant above the hub; the 70px gap holds the dashed ring (22px) and the connector between them */
.gw-col-hub { grid-area: hub; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 0 30px; }
.gw-col-prep { grid-area: prep; display: flex; flex-direction: column; justify-content: center; gap: 22px; }
/* accounting software (left) | accountant handoff (centre); the third column stays empty under the insights card */
.gw-band { grid-area: band; display: grid; grid-template-columns: 296px minmax(0, 1fr) 270px; margin-top: 30px; }
.gw-band .gw-node-handoff { grid-column: 2; grid-row: 1; justify-self: center; align-self: center; width: 300px; max-width: 100%; }
.gw-band .gw-node-systems { grid-column: 1; grid-row: 1; }
/* sits in the empty third column of the bottom band (under the spending overview) instead of costing a row of its own */
.gw-note { grid-area: band; grid-column: 3; justify-self: end; align-self: end; position: relative; z-index: 1; margin: 0; font-size: 12.5px; color: var(--gw-small); text-align: right; }
.gw-flow-arrow { display: none; }

/* cards */
.gw-node { position: relative; z-index: 1; padding: 15px 16px; background: var(--gw-card); border: 1px solid var(--gw-line); border-radius: var(--gw-radius); box-shadow: var(--gw-shadow); transition: border-color .3s, box-shadow .3s; }
.gw-node:hover { border-color: #8fcde6; box-shadow: 0 20px 46px rgba(41, 116, 161, .18), 0 0 0 4px rgba(101, 190, 220, .14); }
.gw-js .gw-canvas .gw-node { opacity: 0; }
.gw-canvas.is-ready .gw-node { animation: gw-appear .7s var(--gw-ease) var(--d, 0s) both; }
.gw-node-head { display: flex; align-items: center; gap: 11px; }
.gw-node h3 { margin: 0; font-size: 16px; line-height: 1.25; font-weight: 780; color: #173d5b; }
.gw-node-sub { margin: 3px 0 0; font-size: 13px; line-height: 1.35; color: var(--gw-small); }
.gw-ic { width: 38px; height: 38px; flex: none; border-radius: 11px; display: grid; place-items: center; font-size: 19px; background: #e6f3ff; color: #1677c4; transition: transform .3s var(--gw-ease); }
.gw-node:hover .gw-ic { transform: translateY(-2px) scale(1.06); }
.gw-ic.is-green { background: #ddf7ee; color: #0b8f78; }
.gw-ic.is-purple { background: #efe9ff; color: #6f4fd0; }
.gw-ic.is-gold { background: #fff2d6; color: #a86a05; }
.gw-ic.is-slate { background: #e9f0f6; color: #3d6684; }

.gw-tx { list-style: none; margin: 10px 0 0; padding: 0; }
.gw-tx li { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px solid #e9f1f7; font-size: 13px; color: #3e6780; }
.gw-tx li:last-child { border-bottom: 0; padding-bottom: 0; }
.gw-tx b { font-weight: 700; white-space: nowrap; color: #24506d; }
.gw-tx b.is-in { color: #0a7f63; }
.gw-docs { display: flex; gap: 8px; margin: 10px 0 0; }
.gw-doc { width: 40px; height: 44px; border-radius: 8px; border: 1px solid #c9e1ee; background: linear-gradient(150deg, #fff, #eaf5fb); display: grid; place-items: center; color: #1584be; font-size: 19px; transition: transform .3s var(--gw-ease); }
.gw-node-docs:hover .gw-doc { transform: translateY(-2px); }
.gw-node-docs:hover .gw-doc:nth-child(2) { transition-delay: .05s; }
.gw-node-docs:hover .gw-doc:nth-child(3) { transition-delay: .1s; }
.gw-quote-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 10px 0 0; }
.gw-quote { font-size: 13.5px; font-style: italic; color: #3c5a73; }
.gw-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 0; }
.gw-tag { display: inline-flex; align-items: center; padding: 5px 9px; border-radius: 8px; background: #e9f5fb; font-size: 12.5px; font-weight: 650; line-height: 1.2; color: #2f6a87; }
.gw-tag.is-ready { background: #dff7ec; color: #07704f; }
.gw-tag.is-roadmap { background: #fff4dc; color: #7f5205; }
/* amber = not confirmed: a possible link, or a difference that still needs an explanation */
.gw-tag.is-possible { background: #fff4dc; color: #7f5205; }
.gw-tag.is-warn { background: #ffecc8; color: #7f5205; white-space: nowrap; animation: gw-glow 3.4s ease-in-out infinite; }

/* marketplace settlement example (illustrative) */
.gw-node-marketplace { border-color: #eadfc6; background: linear-gradient(145deg, #fff, #fffcf6); }
.gw-payout { margin: 10px 0 0; font-size: 13px; color: #5f7a8f; }
.gw-payout div { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; }
.gw-payout dt, .gw-payout dd { margin: 0; }
.gw-payout dd { font-weight: 750; color: #184567; white-space: nowrap; }
.gw-difference { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; margin: 6px 0 0; padding-top: 8px; border-top: 1px solid #f0e6d3; font-size: 13px; font-weight: 700; color: #8a5a09; }
.gw-difference b { font-weight: 800; }
.gw-sample { display: block; margin: 8px 0 0; font-size: 12.5px; line-height: 1.3; color: #7a6a58; }

/* eWallet card: the amber chip above it labels the dashed possible-match connector from the bank statement */
.gw-link-chip { display: flex; align-items: center; height: 22px; margin: -2px 0; padding-left: 44px; position: relative; z-index: 1; }
.gw-link-chip .gw-tag { padding: 3px 8px; font-size: 12.5px; }
.gw-wallet-possible { display: none; }
/* pinned to the top of the hub column: the input and output connectors curve into the hub below it, so none runs behind this card */
.gw-node-assistant { position: absolute; top: 0; left: 30px; right: 30px; margin: 0 auto; max-width: 270px; padding: 12px 14px; }
.gw-node-assistant .gw-ic { width: 34px; height: 34px; font-size: 18px; }
/* AI assistants row: Claude is the tested connection (solid); ChatGPT and "More" are possible connections (dashed, not verified) */
.gw-ai-row { display: flex; flex-wrap: nowrap; gap: 6px; margin: 9px 0 0; padding: 0; list-style: none; }
.gw-ai { display: inline-flex; align-items: center; gap: 5px; padding: 4px 8px 4px 5px; border-radius: 9px; background: #fff; border: 1px solid #bfe0ef; font-size: 12.5px; font-weight: 700; line-height: 1.2; color: #25506d; white-space: nowrap; transition: transform .25s var(--gw-ease), border-color .25s, box-shadow .25s; }
.gw-ai-ic { width: 20px; height: 20px; flex: none; border-radius: 6px; display: grid; place-items: center; font-size: 14px; background: #fff1e8; color: #c4622d; }
.gw-ai.is-possible { border-style: dashed; color: #4a6b82; }
.gw-ai.is-possible .gw-ai-ic { background: #e3f6f1; color: #0b8f78; }
.gw-ai.is-more { border-style: dashed; color: #5d7a90; }
.gw-ai.is-more .gw-ai-ic { background: #eaf1f7; color: #5a7a95; }
.gw-ai:hover { transform: translateY(-2px); border-color: #8fcde6; box-shadow: 0 6px 14px rgba(41, 116, 161, .14); }
.gw-ai-note { margin: 7px 0 0; font-size: 12px; line-height: 1.3; color: var(--gw-small); }
.gw-node-assistant h3 { font-size: 15px; }

.gw-closing { display: none; position: absolute; left: 50%; bottom: 10px; margin: 0; transform: translateX(-50%); font-size: 12px; letter-spacing: .02em; white-space: nowrap; color: #5d7689; }
.gw-systems-list { margin: 3px 0 0; font-size: 12.5px; font-weight: 700; color: #1a6896; white-space: nowrap; }
.gw-systems-list span { color: #8fb0c5; }
.gw-insight { display: flex; justify-content: space-between; align-items: flex-end; gap: 10px; margin: 11px 0 0; padding-top: 9px; border-top: 1px solid #e8f1f8; }
.gw-insight-label { display: block; font-size: 12.5px; color: var(--gw-small); }
.gw-insight-value { display: block; font-size: 17px; font-weight: 780; color: #1f5d88; }
.gw-bars { display: flex; align-items: flex-end; gap: 4px; height: 30px; }
.gw-bars i { display: block; width: 8px; border-radius: 3px 3px 0 0; background: linear-gradient(#11a6c9, #6b8df4); transform-origin: bottom; animation: gw-bar 3.2s var(--gw-ease) infinite alternate; }
.gw-bars i:nth-child(1) { height: 13px; }
.gw-bars i:nth-child(2) { height: 24px; animation-delay: .3s; }
.gw-bars i:nth-child(3) { height: 17px; animation-delay: .6s; }
.gw-bars i:nth-child(4) { height: 29px; animation-delay: .9s; }
.gw-bars i:nth-child(5) { height: 20px; animation-delay: 1.2s; }
.gw-bars i:nth-child(6) { height: 27px; animation-delay: 1.5s; }

/* hub: the circle itself never moves, so connector endpoints stay exact; only its ring, halo and mark animate */
.gw-hub { position: relative; z-index: 1; width: 226px; height: 226px; flex: none; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px; text-align: center;
    background: radial-gradient(circle at 37% 27%, #fff 0%, #eafaff 46%, #cbeafc 100%); border: 2px solid #fff;
    box-shadow: 0 0 0 9px #e9f7fd, 0 0 0 11px rgba(158, 220, 243, .4), 0 22px 60px rgba(28, 129, 194, .22), inset 0 0 28px rgba(105, 186, 255, .3); }
.gw-hub::before { content: ""; position: absolute; inset: -22px; border: 1.5px dashed rgba(110, 190, 225, .75); border-radius: 50%; animation: gw-spin 60s linear infinite; }
.gw-hub::after { content: ""; position: absolute; inset: -11px; border: 2px solid rgba(42, 170, 220, .35); border-radius: 50%; animation: gw-pulse 3.6s ease-out infinite; pointer-events: none; }
.gw-js .gw-canvas .gw-hub { opacity: 0; }
.gw-canvas.is-ready .gw-hub { animation: gw-hub-in .8s var(--gw-ease) .3s both; }
.gw-hub-mark { width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center; background: linear-gradient(135deg, #1d4ed8, #0ea5e9); color: #fff; font-size: 30px; font-weight: 900; box-shadow: 0 10px 24px rgba(29, 78, 216, .3); animation: gw-breath 4.8s ease-in-out infinite; }
.gw-hub-name { margin-top: 10px; font-size: 24px; font-weight: 800; letter-spacing: -.03em; color: #174365; }
.gw-hub-tag { margin-top: 5px; max-width: 160px; font-size: 13px; line-height: 1.35; color: #45667f; }

/* connectors (paths are written by gateway.js) */
.gw-wire { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.gw-wire-base { stroke-width: 2.2; opacity: .4; transition: opacity .3s, stroke-width .3s; }
.gw-wire-group.is-secondary .gw-wire-base { stroke-dasharray: 5 8; opacity: .6; }
.gw-wire-flow { stroke-width: 2.4; stroke-dasharray: 3 13; opacity: 0; transition: opacity .6s; animation: gw-flow 2s linear infinite; }
.gw-wires.is-live .gw-wire-flow { opacity: .8; }
.gw-wire-base.is-drawing { transition: stroke-dashoffset 1s var(--gw-ease); }
.gw-wire-group.is-hot .gw-wire-base { opacity: .85; stroke-width: 3; }
.gw-particle-halo { opacity: .2; }
/* possible related movement: amber dashes that drift, with an open (hollow) dot at each end; no particles, nothing is confirmed */
.gw-relation .gw-wire-rel { stroke: #d99a3d; stroke-width: 2; stroke-dasharray: 3 6; opacity: 0; transition: opacity .8s; animation: gw-flow 2.4s linear infinite; }
.gw-wires.is-live .gw-relation .gw-wire-rel { opacity: .95; }
.gw-relation-dot { fill: #fff; stroke: #d99a3d; stroke-width: 2; opacity: 0; transition: opacity .8s; }
.gw-wires.is-live .gw-relation-dot { opacity: 1; }
.gw-relation.is-hot .gw-wire-rel { stroke-width: 2.6; }

/* language switch: text fades out, is replaced with textContent, fades back in */
[data-gw-i] { transition: opacity .18s ease; }
.gw-switching [data-gw-i] { opacity: 0; }

/* the tab is hidden: freeze every CSS animation (gateway.js also pauses the SVG particles) */
.gw-paused *, .gw-paused *::before, .gw-paused *::after { animation-play-state: paused !important; }

/* ---------- breakpoints ---------- */
@media (min-width: 1180px) and (min-height: 600px) {
    .gw-page { height: 100vh; height: 100dvh; }
}
@media (min-width: 1500px) and (min-height: 800px) {
    .gw-closing { display: block; }
}
@media (max-width: 1439.98px) {
    .gw-main { grid-template-columns: minmax(0, 38fr) minmax(0, 62fr); }
    .gw-benefits { gap: 10px; }
    .gw-benefit-ic { width: 36px; height: 36px; font-size: 17px; }
}
@media (max-width: 1179.98px) {
    .gw-main { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto; gap: 30px; }
    .gw-copy { max-width: 760px; padding: 2vh 0 0; }
    .gw-h1, :lang(ms) .gw-h1 { font-size: clamp(32px, 5vw, 54px); }
    .gw-desc { font-size: 17px; }
    /* full width first: with only a height, aspect-ratio would derive the width from it (and the scale from that) */
    .gw-stage { width: 100%; aspect-ratio: 980 / 690; }   /* ratio only until gateway.js sets the exact height */
    .gw-benefits { max-width: 720px; }
}
@media (min-width: 1180px) and (max-height: 599.98px) {
    .gw-stage { min-height: 460px; }
}
/* short desktop screens (1366x768, 1280x720, ...): the approved headline is long, so the copy column tightens up */
@media (min-width: 1180px) and (max-height: 860px) {
    .gw-header { height: 62px; }
    .gw-eyebrow { margin-bottom: 12px; font-size: 12px; }
    .gw-h1, :lang(ms) .gw-h1 { font-size: clamp(32px, min(2.9vw, 5.2vh), 52px); }
    .gw-desc { margin: 14px 0 18px; font-size: clamp(14px, min(1vw, 2vh), 17px); line-height: 1.5; }
    .gw-cta { min-height: 52px; }
    .gw-cta-label { font-size: 15.5px; }
    .gw-cta-ic { width: 36px; height: 36px; font-size: 18px; }
    .gw-benefits { margin-top: 18px; }
    .gw-benefit-ic { width: 34px; height: 34px; font-size: 16px; }
    .gw-main { padding-bottom: 8px; }
    .gw-copy { padding-bottom: 0; }
}
/* the closing line has its own strip at the bottom of the page, so it can never touch the network */
@media (min-width: 1500px) and (min-height: 800px) {
    .gw-main { padding-bottom: 36px; }
}

/* phones and small tablets: a readable vertical flow, no scaled canvas */
@media (max-width: 899.98px) {
    .gw-header { height: auto; padding: 14px 0; flex-wrap: wrap; }
    .gw-brand-mark { width: 36px; height: 36px; font-size: 16px; }
    .gw-brand-name { font-size: 21px; }
    .gw-lang { min-height: 34px; padding: 0 11px; font-size: 13px; }
    .gw-stage { aspect-ratio: auto; height: auto !important; }
    .gw-canvas { position: static; width: auto; transform: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-areas: none; gap: 14px; }
    .gw-js .gw-canvas:not(.is-ready) { opacity: 1; animation: none; }
    .gw-col-in, .gw-col-hub, .gw-col-prep, .gw-band { display: contents; }
    .gw-wires { display: none; }
    .gw-link-chip { display: none; }
    .gw-wallet-possible { display: flex; }
    .gw-node-bank { order: 1; } .gw-node-wallet { order: 2; } .gw-node-marketplace { order: 3; } .gw-node-docs { order: 4; }
    .gw-flow-arrow-1 { order: 5; }
    .gw-hub { order: 6; }
    .gw-node-assistant { order: 7; grid-column: 1 / -1; position: relative; left: auto; right: auto; margin: 0; max-width: none; }
    .gw-flow-arrow-2 { order: 8; }
    .gw-node-meaning { order: 9; } .gw-node-group { order: 10; } .gw-node-review { order: 11; } .gw-node-insights { order: 12; }
    .gw-flow-arrow-3 { order: 13; }
    .gw-band .gw-node-handoff { order: 14; grid-column: auto; grid-row: auto; width: auto; justify-self: stretch; align-self: stretch; }
    .gw-band .gw-node-systems { order: 15; grid-column: auto; grid-row: auto; }
    /* grid-area reset: the desktop "note" area does not exist here, and a named area would bypass auto-placement/order */
    .gw-note { grid-area: auto; order: 16; grid-column: 1 / -1; justify-self: start; margin: 4px 0 18px; }
    .gw-flow-arrow { display: flex; grid-column: 1 / -1; justify-content: center; font-size: 22px; color: #3b9ec4; }
    .gw-flow-arrow .gw-ico { animation: gw-nudge 2.4s ease-in-out infinite; }
    .gw-hub { grid-column: 1 / -1; width: auto; height: auto; flex-direction: row; flex-wrap: wrap; justify-content: center; gap: 6px 14px; padding: 18px; border-radius: 22px;
        box-shadow: 0 0 0 6px #e9f7fd, 0 16px 40px rgba(28, 129, 194, .18); }
    .gw-hub::before, .gw-hub::after { display: none; }
    .gw-hub-mark { width: 48px; height: 48px; border-radius: 14px; font-size: 22px; }
    .gw-hub-name { margin: 0; font-size: 22px; }
    .gw-hub-tag { margin: 0; max-width: none; flex-basis: 100%; font-size: 14px; }
    .gw-systems-list { white-space: normal; }
}
@media (max-width: 599.98px) {
    .gw-canvas { grid-template-columns: minmax(0, 1fr); }
    .gw-langs { width: 100%; justify-content: space-between; }
    .gw-lang { flex: 1 1 auto; justify-content: center; padding: 0 8px; }
    .gw-eyebrow { font-size: 12px; letter-spacing: .18em; }
    .gw-h1, :lang(ms) .gw-h1 { font-size: clamp(30px, 8.6vw, 42px); }
    .gw-desc { font-size: 16px; }
    .gw-cta { width: 100%; }
    .gw-cta-arrow { margin-left: auto; }
    .gw-benefits { grid-template-columns: minmax(0, 1fr); gap: 12px; }
}

@media (forced-colors: active) {
    .gw-h1 em { -webkit-text-fill-color: currentColor; background: none; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .gw-js .gw-canvas, .gw-js .gw-canvas .gw-node, .gw-js .gw-canvas .gw-hub { opacity: 1 !important; }
    .gw-wires.is-live .gw-wire-flow { opacity: 0; }
}

@keyframes gw-breathe { to { transform: scale(1.12); } }
@keyframes gw-spin { to { transform: rotate(360deg); } }
@keyframes gw-pulse { 0% { transform: scale(1); opacity: .65; } 100% { transform: scale(1.28); opacity: 0; } }
@keyframes gw-breath { 50% { transform: scale(1.045); } }
@keyframes gw-appear { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes gw-hub-in { from { opacity: 0; transform: scale(.9); } to { opacity: 1; transform: none; } }
@keyframes gw-flow { to { stroke-dashoffset: -32; } }
@keyframes gw-bar { from { transform: scaleY(.8); } to { transform: scaleY(1); } }
@keyframes gw-reveal { to { opacity: 1; } }
@keyframes gw-nudge { 50% { transform: translateY(3px); } }
@keyframes gw-glow { 0%, 100% { box-shadow: 0 0 0 0 rgba(225, 160, 50, 0); } 50% { box-shadow: 0 0 0 4px rgba(225, 160, 50, .22); } }
