/* How it works page. Everything is scoped to hiw-*; the homepage teaser is scoped to .hiw-teaser. */

/* Hero: copy beside the five-step journey. The journey is plain text and never depends on the demo. */
@media(min-width:960px){.hiw-hero-body{align-items:center}}
.hiw-journey{list-style:none;margin:0;padding:0;display:grid;gap:12px;width:100%;max-width:520px;min-width:0;justify-self:center}
.hiw-journey li{display:grid;grid-template-columns:36px minmax(0,1fr);gap:16px;align-items:start;padding:14px 20px;border-radius:16px;background:rgba(17,18,20,.14);border:1px solid rgba(255,255,255,.18)}
.hiw-journey-number{display:grid;place-items:center;width:36px;height:36px;border-radius:50%;background:#fff;color:#0B5E46;font-size:15px;font-weight:700}
.hiw-journey strong{display:block;padding-top:6px;font-size:17px;font-weight:600;line-height:1.35}
.hiw-journey p{margin:4px 0 0;font-size:14px;line-height:1.5;color:#E4F2EC}

/* Demo section: dark charcoal stage. */
.hiw-demo{background:#111214;color:#fff}
.hiw-demo .eyebrow{color:#83DFC0}
.hiw-demo .section-intro p{color:#B5BAC1}
.hiw-stage{--guide-stroke:4px;margin:40px 0 0;padding:24px;border-radius:28px;background:#1D2026;border:1px solid #2E323A}
.hiw-stage-top{display:flex;flex-wrap:wrap;align-items:center;gap:8px 14px;margin-bottom:20px}
.hiw-badge{display:inline-flex;align-items:center;gap:8px;padding:5px 12px;border-radius:999px;background:#102F27;border:1px solid #2B5B4D;color:#83DFC0;font-size:13px;font-weight:500;line-height:1.4}
.hiw-badge:before{content:'';width:7px;height:7px;border-radius:50%;background:#41C797}
.hiw-stage-body{display:grid;grid-template-columns:minmax(0,1fr);gap:20px}
@media(min-width:960px){.hiw-js .hiw-stage-body{grid-template-columns:minmax(0,1fr) 260px;gap:24px}}

/* Without JS: a readable storyboard of all five scenes. With JS: scenes share one grid cell, so the stage height never changes. */
.hiw-scenes{display:grid;grid-template-columns:minmax(0,1fr);gap:20px;min-width:0}
@media(min-width:760px){.hiw-stage:not(.hiw-js) .hiw-scenes{grid-template-columns:repeat(2,minmax(0,1fr))}}
.hiw-scene{display:flex;flex-direction:column;gap:18px;min-width:0}
.hiw-js .hiw-scenes{gap:0}
.hiw-js .hiw-scene{grid-area:1/1;opacity:0;visibility:hidden}
.hiw-js .hiw-scene.is-active{opacity:1;visibility:visible}
.hiw-scene-visual{flex:1;display:grid;place-items:center;min-height:280px;padding:28px 20px;border-radius:20px;background:radial-gradient(70% 60% at 50% 45%,rgba(22,138,104,.2),transparent 72%),#15171B;border:1px solid #262A31;overflow:hidden}
.hiw-visual-inner{display:flex;flex-direction:column;align-items:center;gap:18px;width:100%;min-width:0}
.hiw-scene-caption{padding:0 4px}
.hiw-scene-step{display:block;font-size:13px;font-weight:500;color:#83DFC0}
.hiw-scene-caption h3{margin:6px 0 0;font-size:22px;font-weight:700;line-height:1.25;letter-spacing:-.02em}
.hiw-scene-caption p{margin:8px 0 0;max-width:620px;font-size:15px;line-height:1.6;color:#B5BAC1}

/* Image failure: keep the reserved box and show short text instead. */
.hiw-fallback{display:none}
.is-missing>.hiw-fallback{position:absolute;inset:0;display:grid;place-items:center;padding:8px;border-radius:inherit;background:#D9DDDB;color:#3A3F47;font-size:12px;font-weight:500;line-height:1.3;text-align:center}
.is-missing>img{visibility:hidden}

/* Consent is an illustration, with no live checkbox or submission. */
.hiw-consent{width:min(100%,350px);padding:24px;border-radius:18px;border:1px solid #D7DED9;background:#fff;color:#20242A;box-shadow:0 18px 35px -24px #000}
.hiw-consent-brand{display:flex;align-items:center;gap:10px;font-size:14px;font-weight:600}
.hiw-consent h4{margin:22px 0 10px;font-size:23px;line-height:1.2;letter-spacing:-.025em}
.hiw-consent p{margin:0;color:#5B6068;font-size:14px;line-height:1.6}
.hiw-consent ul{list-style:none;margin:20px 0;padding:0;display:grid;gap:12px;font-size:13px;line-height:1.5}
.hiw-consent li{padding-left:20px;position:relative}
.hiw-consent li:before{content:'✓';position:absolute;left:0;color:#168A68;font-weight:700}
.hiw-consent-agree{display:flex;align-items:center;gap:9px;padding-top:16px;border-top:1px solid #E4E9E6;font-size:12px;line-height:1.5}
.hiw-consent-agree>span{display:grid;place-items:center;flex:none;width:18px;height:18px;border-radius:4px;background:#168A68;color:#fff}
.hiw-consent-continue{display:flex;align-items:center;justify-content:space-between;margin-top:18px;padding:12px 15px;border-radius:8px;background:#168A68;color:#fff;font-size:13px;font-weight:600}

/* Step four uses two panels in the same reserved grid cell. No added stage height. */
.hiw-verification-panels{display:grid;gap:30px;width:100%;min-width:0;justify-items:center}
.hiw-js .hiw-verification-panels{gap:0}
.hiw-js .hiw-verification-panels>.hiw-visual-inner{grid-area:1/1;align-self:center}
.hiw-js .hiw-selfie-panel{opacity:0;visibility:hidden}
.hiw-js .hiw-comparison-panel{opacity:1;visibility:inherit}
.hiw-stage[data-hiw-phase=selfie] .hiw-selfie-panel{opacity:1;visibility:visible}
.hiw-stage[data-hiw-phase=selfie] .hiw-comparison-panel{opacity:0;visibility:hidden}
.hiw-stage[data-hiw-phase=id] .hiw-source-id,.hiw-stage[data-hiw-phase=transfer] .hiw-source-id{opacity:1;visibility:visible}
.hiw-stage[data-hiw-phase=id] .hiw-face-id{visibility:hidden}
.hiw-stage[data-hiw-phase=transfer] [data-hiw-source-photo]{visibility:hidden}
.hiw-stage[data-hiw-phase=id] .hiw-face-live,.hiw-stage[data-hiw-phase=transfer] .hiw-face-live{visibility:hidden}
.hiw-stage[data-hiw-phase=id] .hiw-photo-landmarks,.hiw-stage[data-hiw-phase=transfer] .hiw-photo-landmarks,
.hiw-stage[data-hiw-phase=id] .hiw-links,.hiw-stage[data-hiw-phase=transfer] .hiw-links,
.hiw-stage[data-hiw-phase=id] .hiw-face-label,.hiw-stage[data-hiw-phase=transfer] .hiw-face-label{visibility:hidden}
.hiw-stage[data-hiw-phase=match] .hiw-face-id,.hiw-stage[data-hiw-phase=settled] .hiw-face-id{opacity:1;visibility:visible;transform:none}

/* ID check: one scan band, then portrait and date-of-birth outlines. Base styles are the finished state. */
.hiw-stage .id-card.hiw-id{width:min(100%,380px);max-width:none}
.hiw-stage .id-card:after{display:none}
/* A generic demo license: fictional fields, with no real issuing authority or machine-readable data. */
.hiw-license{border-radius:10px;background:radial-gradient(ellipse at 90% 90%,rgba(162,149,183,.18),transparent 60%),repeating-linear-gradient(120deg,rgba(91,144,175,.045) 0 1px,transparent 1px 5px),#F4F6ED}
.hiw-license .id-card-face{grid-template-columns:28cqw minmax(0,1fr);grid-template-rows:auto 1fr auto;column-gap:4cqw;padding:2.8cqw 4cqw}
.hiw-license .id-card-band{align-items:center;padding-bottom:1.4cqw;margin-bottom:1.8cqw;border-bottom-color:rgba(57,83,102,.24)}
.hiw-license-heading{display:flex;align-items:baseline;gap:2.2cqw;min-width:0}
.hiw-license-region{font-size:max(8px,4.8cqw);font-weight:700;line-height:1.1;letter-spacing:-.025em;color:#264B67;text-transform:uppercase}
.hiw-license-title{font-size:max(6px,2.65cqw);font-weight:700;line-height:1.1;letter-spacing:.03em;color:#264B67;text-transform:uppercase}
.hiw-license .id-card-sample{font-size:max(6px,2.5cqw);padding:.6cqw 1.2cqw;letter-spacing:.12em}
.hiw-license .id-card-fields{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:1.1cqw 2.5cqw;padding-top:0}
.hiw-license .id-field{gap:.35cqw;min-width:0}
.hiw-license .id-field-label{font-size:1.9cqw;font-weight:500;line-height:1.1;letter-spacing:.035em;color:#4C5962}
.hiw-license-wide{grid-column:1/-1}
.hiw-license-value{font-size:2.65cqw;font-weight:600;line-height:1.15;color:#202935;letter-spacing:.02em;font-variant-numeric:tabular-nums}
.hiw-license-number{font-size:max(7px,3.2cqw);color:#914245}
.hiw-license-name .hiw-license-value{font-size:max(7px,3.15cqw);font-weight:700;letter-spacing:.025em}
.hiw-license-address{font-size:2.4cqw;font-weight:500;line-height:1.2}
.hiw-license-portrait{min-width:0}
.hiw-license .id-card-photo{border-radius:.8cqw}
.hiw-license-signature{display:block;margin-top:1.3cqw;font:italic max(7px,3cqw)/1.2 cursive;color:#304455;text-align:center}
.hiw-license-footer{grid-column:1/-1;display:block;margin-top:1.5cqw;padding-top:1.1cqw;border-top:1px solid rgba(57,83,102,.2);font-size:1.9cqw;font-weight:600;line-height:1.2;letter-spacing:.06em;text-align:center;text-transform:uppercase;color:#436252}
.hiw-target{position:relative}
.hiw-target-photo{display:block}
.hiw-target:after{content:'';position:absolute;inset:-1.6cqw;border:2px solid #41C797;border-radius:2.6cqw;pointer-events:none}
.hiw-target-field:after{inset:-1.4cqw -2.4cqw}
.hiw-scan{position:absolute;inset:0;overflow:hidden;border-radius:inherit;pointer-events:none}
.hiw-scan:before{content:'';position:absolute;left:0;right:0;top:0;height:24%;border-bottom:2px solid #41C797;background:linear-gradient(rgba(65,199,151,0),rgba(65,199,151,.3));opacity:0;transform:translateY(-100%)}
.hiw-legend{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;justify-content:center;gap:8px}
.hiw-legend li{display:inline-flex;align-items:center;gap:7px;padding:5px 11px;border-radius:999px;border:1px solid #2B5B4D;background:#102F27;color:#DDF3EA;font-size:12px;font-weight:500;line-height:1.4}
.hiw-legend li:before{content:'';width:10px;height:7px;border:1.5px solid #41C797;border-radius:2px}

/* Live selfie: the shared phone, emphasized, with the SVG halo (never a box shadow on the oval). */
.hiw-stage .phone.hiw-phone{width:230px;max-width:100%}
.hiw-stage .face-guide-glow{animation:none;opacity:.75}

/* The full ID gives way to its portrait, then the selfie comparison. The controller measures the transfer transform. */
.hiw-compare{width:min(100%,520px)}
.hiw-origin-cue{display:flex;align-items:center;justify-content:center;gap:9px;min-height:30px;margin-bottom:16px;font-size:12px;font-weight:500;color:#83DFC0}
.hiw-source-id{position:absolute;inset:0;display:grid;place-items:center;opacity:0;visibility:hidden;pointer-events:none}
.hiw-stage .id-card.hiw-extraction-id{width:min(100%,360px);max-width:none}
.hiw-source-photo{position:relative;display:block;outline:2px solid #41C797;outline-offset:3px;border-radius:1.8cqw}
.hiw-face-id{transform-origin:0 0;z-index:1;outline:2px solid #41C797;outline-offset:2px}
.hiw-compare-row{position:relative;display:grid;grid-template-columns:minmax(0,36fr) minmax(0,28fr) minmax(0,36fr);aspect-ratio:100/45}
.hiw-face{position:relative;display:block;grid-column:1;min-width:0;border-radius:12px;overflow:hidden;background:#2A2D33}
.hiw-face-live{grid-column:3;outline:2px solid #168A68;outline-offset:-2px}
.hiw-face img{display:block;width:100%;height:100%;object-fit:cover}
.hiw-landmarks{position:absolute;inset:0;width:100%;height:100%;overflow:visible;pointer-events:none}
.hiw-mesh path{fill:none;stroke:#83DFC0;stroke-width:.3;stroke-linejoin:round;opacity:.8}
.hiw-points circle{fill:#41C797;stroke:#fff;stroke-width:.25}
.hiw-links path{fill:none;stroke:#41C797;stroke-width:.3;stroke-dasharray:1;stroke-dashoffset:0;opacity:.6}
.hiw-compare-labels{display:grid;grid-template-columns:minmax(0,36fr) minmax(0,28fr) minmax(0,36fr);margin-top:12px;font-size:12px;font-weight:500;line-height:1.4;color:#ADB2BC;text-align:center}
.hiw-compare-labels span:last-child{grid-column:3}

/* Discord entry and verified role: a familiar Discord message. */
.hiw-start-server{padding:12px 16px;border-bottom:1px solid #2A2A2F;color:#F2F3F5;font-weight:600}
.hiw-start-member{display:flex;align-items:center;gap:10px;padding:16px;font-size:13px;color:#AEB3BD}
.hiw-start-member strong{color:#DBDEE1;font-weight:500}
.hiw-start .hiw-discord-msg{margin-top:0;margin-bottom:16px}
.hiw-start-button{position:relative;display:inline-flex;align-items:center;justify-content:center;min-height:36px;padding:8px 16px;border-radius:5px;background:#168A68;color:#fff;font-size:14px;font-weight:600}
.hiw-start-pointer{display:none;position:absolute;left:70%;top:55%;pointer-events:none}
.hiw-start-click{position:absolute;left:70%;top:55%;width:22px;height:22px;border:2px solid #83DFC0;border-radius:50%;opacity:0;pointer-events:none}
.hiw-result-note{font-size:12px;font-weight:500;color:#ADB2BC}
.hiw-discord{width:min(100%,400px);border-radius:14px;overflow:hidden;background:#1F1F23;border:1px solid #2E2E34;color:#DBDEE1;font-size:14px;text-align:left}
.hiw-discord-head{display:flex;align-items:center;gap:6px;padding:12px 16px;border-bottom:1px solid #2A2A2F;font-weight:600;color:#F2F3F5}
.hiw-discord-head span{color:#80848E;font-weight:400;font-size:16px}
.hiw-discord-msg{display:flex;gap:12px;margin:12px 0 8px;padding:12px 16px;background:rgba(22,138,104,.14);box-shadow:inset 2px 0 0 #3DBE8E}
.hiw-discord-bot{flex:none;width:36px;height:36px;border-radius:50%;background:#fff;display:grid;place-items:center}
.hiw-discord-bot img{width:23px;height:23px}
.hiw-discord-body{display:flex;flex-direction:column;align-items:flex-start;min-width:0}
.hiw-discord-meta{display:flex;align-items:center;gap:6px}
.hiw-discord-meta strong{font-weight:500;color:#F2F3F5}
.hiw-app{padding:1px 4px;border-radius:3px;background:#5865F2;color:#fff;font-size:9px;font-weight:600}
.hiw-discord-msg p{margin:4px 0 8px;line-height:1.45}
.hiw-mention{padding:0 3px;border-radius:3px;background:rgba(88,101,242,.3);color:#DEE0FC}
.hiw-role{display:inline-flex;align-items:center;gap:6px;padding:3px 8px;border-radius:4px;background:#111113;border:1px solid #2E2E34;font-size:12px;font-weight:500;color:#DBDEE1;white-space:nowrap}
.hiw-role:before{content:'';width:9px;height:9px;border-radius:50%;background:#3DBE8E}
.hiw-discord-member{display:flex;align-items:center;gap:10px;padding:4px 16px 16px}
.hiw-discord-member .discord-avatar{width:32px;height:32px}
.hiw-member-name{font-weight:500;color:#3DBE8E}
.hiw-discord-member .hiw-role{margin-left:auto}

/* Controls: hidden until JS runs. */
.hiw-controls{display:flex;flex-direction:column;gap:14px;min-width:0}
.hiw-controls-label{margin:0;font-size:13px;font-weight:500;color:#ADB2BC}
.hiw-steps{display:grid;gap:8px}
.hiw-step{display:grid;grid-template-columns:28px minmax(0,1fr);align-items:center;gap:8px 12px;width:100%;min-height:44px;padding:12px 14px;border-radius:14px;border:1px solid #2E323A;background:transparent;color:#C9CDD3;font-size:14px;font-weight:500;line-height:1.3;text-align:left}
.hiw-step:hover{border-color:#4A505A}
.hiw-step[aria-current=step]{background:#102F27;border-color:#2B5B4D;color:#fff}
.hiw-step-index{display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:#2A2D33;color:#fff;font-size:13px;font-weight:600}
.hiw-step[aria-current=step] .hiw-step-index,.hiw-step.is-done .hiw-step-index{background:#168A68}
.hiw-step-name{min-width:0}
.hiw-step-bar{grid-column:1/-1;height:3px;border-radius:2px;background:#2A2D33;overflow:hidden}
.hiw-step-bar span{display:block;height:100%;border-radius:inherit;background:#41C797;transform:scaleX(0);transform-origin:0 50%}
.hiw-step.is-done .hiw-step-bar span,.hiw-step[aria-current=step] .hiw-step-bar span{transform:none}
.hiw-actions{display:flex;gap:10px;margin-top:auto}
.hiw-control{flex:1;display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:0 16px;border-radius:999px;border:1px solid #3B3F46;background:#111214;color:#fff;font-size:14px;font-weight:500}
.hiw-control:hover{border-color:#5A606A}
.hiw-toggle[data-hiw-mode=pause] .hiw-icon-play,.hiw-toggle[data-hiw-mode=resume] .hiw-icon-pause{display:none}

/* Playback. Animations apply only while .is-animating; .is-held freezes them in place. */
.hiw-stage.is-held *,.hiw-stage.is-held *:before,.hiw-stage.is-held *:after{animation-play-state:paused!important}
.is-animating .is-active .hiw-scan:before{animation:hiw-scan 1.9s cubic-bezier(.45,0,.55,1) .2s both}
.is-animating .is-active .hiw-target:after{animation:hiw-outline .45s ease-out 1s both}
.is-animating .is-active .hiw-target-field:after{animation-delay:1.6s}
.is-animating .is-active .hiw-legend li{animation:hiw-light .45s ease-out 1s both}
.is-animating .is-active .hiw-legend li:nth-child(2){animation-delay:1.6s}
.is-animating .is-active .hiw-start-pointer{display:block;animation:hiw-pointer 3s ease both}
.is-animating .is-active .hiw-start-click{animation:hiw-click .6s ease-out 1.9s both}
.is-animating .is-active .hiw-start-button{animation:hiw-button .3s ease 1.9s both}
.is-animating .is-active .hiw-phone .face-guide{animation:hiw-guide 1.4s ease .3s both}
.is-animating .is-active .hiw-phone .face-guide-glow{animation:hiw-fade 1.2s ease .7s both}
.is-animating .is-active .hiw-discord-msg{animation:hiw-enter .5s ease-out .1s both}
.is-animating .is-active .hiw-discord-msg .hiw-role{animation:hiw-pop .4s ease-out .6s both}
.is-animating .is-active .hiw-discord-member{animation:hiw-enter .4s ease-out .9s both}
.is-animating .hiw-step[aria-current=step] .hiw-step-bar span{animation:hiw-progress 3s linear both}
.is-animating .hiw-step[data-hiw-step=id][aria-current=step] .hiw-step-bar span{animation-duration:3.5s}
.is-animating .hiw-step[data-hiw-step=verification][aria-current=step] .hiw-step-bar span{animation-duration:7s}
.is-animating .hiw-step[data-hiw-step=role][aria-current=step] .hiw-step-bar span{animation-duration:2.5s}
@keyframes hiw-pointer{0%,25%{opacity:0;transform:translate(64px,42px)}55%,62%{opacity:1;transform:none}65%{opacity:1;transform:scale(.85)}72%{opacity:1;transform:none}100%{opacity:0;transform:translate(8px,8px)}}
@keyframes hiw-click{0%{opacity:.8;transform:translate(-50%,-50%) scale(.2)}100%{opacity:0;transform:translate(-50%,-50%) scale(2)}}
@keyframes hiw-button{50%{background:#41C797;transform:scale(.97)}}
@keyframes hiw-scan{0%{opacity:0;transform:translateY(-100%)}8%,88%{opacity:1}100%{opacity:0;transform:translateY(417%)}}
@keyframes hiw-outline{from{opacity:0;transform:scale(1.06)}}
@keyframes hiw-light{from{opacity:.35}}
@keyframes hiw-enter{from{opacity:.3;transform:translateY(10px) scale(.98)}}
@keyframes hiw-guide{from{border-color:rgba(255,255,255,.7)}}
@keyframes hiw-fade{from{opacity:0}}
@keyframes hiw-draw{from{stroke-dashoffset:1}}
@keyframes hiw-pop{from{opacity:0;transform:scale(.85)}}
@keyframes hiw-progress{from{transform:scaleX(0)}}

/* Who sees what. */
.hiw-flow{list-style:none;margin:40px 0 0;padding:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}
.hiw-flow li{position:relative;display:flex;flex-direction:column;align-items:flex-start;gap:10px;min-width:0;padding:28px;border-radius:20px;background:#fff;border:1px solid #E1E4E1}
.hiw-flow li:not(:last-child):after{content:'';position:absolute;top:50%;right:-15px;width:8px;height:8px;border-top:2px solid #168A68;border-right:2px solid #168A68;transform:translateY(-50%) rotate(45deg)}
.hiw-flow-tag{font-size:13px;font-weight:600;color:#00815F}
.hiw-flow h3{margin:0;font-size:21px;font-weight:700;line-height:1.3;letter-spacing:-.015em}
.hiw-flow p{margin:0;font-size:15px;line-height:1.6;color:#5B606B}
.hiw-flow-example{margin-top:6px;max-width:100%;flex-wrap:wrap}
.hiw-flow-note{margin:24px 0 0;max-width:760px;font-size:15px;line-height:1.6;color:#5B606B}
.hiw-data-controls{margin-top:36px;padding:28px;border:1px solid #DEE5E1;border-radius:20px;background:#F4F7F5}
.hiw-data-controls>h3{margin:0;font-size:24px;line-height:1.3;font-weight:700;letter-spacing:-.02em}
.hiw-data-options{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:28px;margin-top:22px}
.hiw-data-options h4{margin:0;font-size:17px;line-height:1.4;font-weight:600}
.hiw-data-options p{margin:8px 0 0;max-width:520px;color:#5B606B;font-size:15px;line-height:1.6}
.hiw-data-controls .text-link{margin-top:22px;color:#00815F}

/* Homepage teaser: replaces the existing #how section with four short steps and a link. */
.how.hiw-teaser{min-height:0}
.hiw-teaser-steps{list-style:none;margin:40px 0 0;padding:0;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
.hiw-teaser-steps li{display:flex;flex-direction:column;gap:8px;min-width:0;padding:24px;border-radius:20px;background:#F4F5F4}
.hiw-teaser-number{display:grid;place-items:center;width:32px;height:32px;margin-bottom:6px;border-radius:50%;background:#111214;color:#fff;font-size:14px;font-weight:600}
.hiw-teaser-steps li:last-child .hiw-teaser-number{background:#168A68}
.hiw-teaser h3{margin:0;font-size:18px;font-weight:700;line-height:1.3;letter-spacing:-.01em}
.hiw-teaser-steps p{margin:0;font-size:15px;line-height:1.55;color:#5B6068}
.hiw-teaser .hiw-teaser-link{align-self:flex-start;margin-top:24px;color:#00815F}

@media(max-width:959px){
 .hiw-steps{grid-template-columns:repeat(5,minmax(0,1fr))}
 .hiw-actions{margin-top:0}
 .hiw-flow{grid-template-columns:minmax(0,1fr);gap:24px}
 .hiw-flow li:not(:last-child):after{top:auto;right:auto;left:50%;bottom:-18px;transform:translateX(-50%) rotate(135deg)}
 .hiw-teaser-steps{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:599px){
 .hiw-consent{padding:16px}
 .hiw-consent h4{font-size:21px}
 .hiw-journey li{padding:16px;gap:14px}
 .hiw-stage{margin-top:28px;padding:14px;border-radius:22px}
 .hiw-stage-top{margin-bottom:14px}
 .hiw-scene-visual{padding:20px 12px;border-radius:16px}
 .hiw-stage .phone.hiw-phone{width:220px}
 .hiw-scene-caption h3{font-size:20px}
 .hiw-scene-caption p{font-size:14px}
 .hiw-steps{grid-template-columns:repeat(2,minmax(0,1fr))}
 .hiw-step{padding:10px 12px;gap:8px 10px}
 .hiw-discord-member .hiw-role{margin-left:0}
 .hiw-discord-member{flex-wrap:wrap}
 .hiw-flow{margin-top:28px}
 .hiw-flow li{padding:22px 20px}
 .hiw-data-controls{padding:22px 20px}
 .hiw-data-options{grid-template-columns:minmax(0,1fr);gap:20px}
 .hiw-teaser-steps{grid-template-columns:minmax(0,1fr);margin-top:32px;gap:12px}
 .hiw-teaser-steps li{padding:20px}
}

/* Photo-local landmarks keep the face geometry stable when comparison tiles stack. */
.hiw-photo-landmarks{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}
.hiw-photo-landmarks .hiw-mesh path{stroke-width:.75}
.hiw-photo-landmarks .hiw-points circle{stroke-width:.6}
.hiw-face-label{position:absolute;left:8px;right:8px;bottom:8px;padding:4px 6px;border-radius:6px;background:rgba(17,18,20,.84);color:#fff;font-size:11px;font-weight:500;line-height:1.4;text-align:center}
@media(max-width:599px){
 .hiw-compare-row{grid-template-columns:minmax(0,1fr);aspect-ratio:auto;gap:38px;justify-items:center}
 .hiw-face,.hiw-face-live{grid-column:1;width:min(100%,184px);aspect-ratio:1122/1402}
 .hiw-face-live{grid-row:2}
 .hiw-landmarks{display:none}
 .hiw-compare-row:after{content:'';position:absolute;left:50%;top:50%;height:22px;border-left:2px dashed #41C797;transform:translate(-50%,-50%);opacity:.6}
}

/* Missing images omit overlays that would suggest a completed comparison. */
.hiw-stage .is-missing>.hiw-photo-landmarks,.hiw-stage .is-missing>.face-guide{display:none}

@media(max-width:599px){.hiw-stage[data-hiw-phase=id] .hiw-compare-row:after,.hiw-stage[data-hiw-phase=transfer] .hiw-compare-row:after{visibility:hidden}}
