/* security-film.css: /security only. The opening: a made-up shop that a red scan line peels away to
   show the server code behind it, then five holes light up red and are fixed one by one.

   security-film.js sets two things on .sx while you scroll:
     --cut         0 to 1, how far down the scan line has gone (the shop is gone above it)
     data-stage    0 shop, 1 code, 2 holes, 3 fixing, 4 all fixed
   and puts .is-lit / .is-fixed on each hole row. The scene is a tall section with a sticky stage, so
   the page scrolls normally the whole time; nothing ever holds the wheel or a finger.
   The still version (reduced motion, no JavaScript, or a script failure) is security-film-still.css. */

.sx{--cut:0; position:relative; height:300vh; background:var(--bg)}
.sx-stage{position:sticky; top:0; height:100vh; height:100svh; padding-top:68px; overflow:clip;
  display:flex; align-items:center}
/* the room the shop sits in: a soft red-tinged dark, so the frame floats */
.sx-stage::before{content:''; position:absolute; inset:0; pointer-events:none;
  background:radial-gradient(60% 70% at 72% 52%, rgba(239,35,60,.075), transparent 70%),
    radial-gradient(40% 50% at 70% 60%, rgba(214,222,232,.05), transparent 70%)}
.sx-grid{position:relative; display:grid; grid-template-columns:minmax(0, 360px) minmax(0, 1fr);
  gap:clamp(32px, 4.4vw, 72px); align-items:center; width:min(1320px, 100% - clamp(40px, 5vw, 80px))}

/* ── the words column: always lit, always clickable ── */
.sx-copy{display:grid; gap:var(--s5); position:relative; z-index:2}
.sx .display{font-size:clamp(38px, 3.6vw, 56px); line-height:1.02}
.sx .display em{font-style:normal; font-weight:500; display:block; margin-top:.08em}
.sx .display, .sx .display em{text-wrap:balance}
/* the calm last line, in the words column, once every hole is green */
.sx-done{display:flex; align-items:center; gap:12px; font-size:17px; font-weight:500; color:var(--ink);
  opacity:0; transform:translateY(6px); transition:opacity .6s var(--ease-out), transform .6s var(--ease-out)}
.sx-done-tick{flex:none; position:relative; width:22px; height:22px; border-radius:50%; background:#3FD69A;
  box-shadow:0 0 0 4px rgba(63,214,154,.14), 0 0 18px rgba(63,214,154,.35)}
.sx-done-tick::after{content:''; position:absolute; left:8px; top:5px; width:4px; height:8px;
  border:solid #06150E; border-width:0 2px 2px 0; transform:rotate(45deg)}
.sx[data-stage="4"] .sx-done{opacity:1; transform:none}
.sx-hint-row{display:grid}
.sx-hint-row > *{grid-area:1 / 1}
.sx .lede{font-size:17px; max-width:34ch}
.sx .actions{display:flex; flex-wrap:wrap; gap:var(--s3)}
.sx-steps{list-style:none; display:grid; grid-template-columns:repeat(4, minmax(0, 1fr)); gap:10px; margin-top:var(--s3)}
.sx-step{display:grid; gap:9px; font:500 11px/1.2 var(--font-ui); letter-spacing:.08em; text-transform:uppercase;
  color:var(--faint); transition:color .4s var(--ease-out)}
.sx-step-bar{display:block; height:2px; border-radius:2px; background:rgba(242,243,241,.12); overflow:hidden}
.sx-step-bar i{display:block; height:100%; background:var(--ink); transform-origin:0 50%; transform:scaleX(var(--f, 0))}
.sx-step[data-step="2"] .sx-step-bar i{background:#EF233C}
.sx-step[data-step="3"] .sx-step-bar i{background:#3FD69A}
.sx-step.is-on{color:var(--ink)}
.sx-hint{display:flex; align-items:center; gap:10px; font-size:13px; color:var(--dim); transition:opacity .5s var(--ease-out)}
.sx-hint-arrow{width:14px; height:22px; border:1.5px solid var(--line-strong); border-radius:8px; position:relative}
.sx-hint-arrow::after{content:''; position:absolute; left:50%; top:5px; width:2px; height:5px; margin-left:-1px; border-radius:1px;
  background:var(--dim); animation:sx-wheel 2.2s var(--ease-out) infinite}
@keyframes sx-wheel{0%{transform:translateY(0); opacity:0} 25%{opacity:1} 80%{transform:translateY(7px); opacity:0} 100%{opacity:0}}
.sx[data-stage]:not([data-stage="0"]) .sx-hint{opacity:0}

/* ── the browser frame ── */
.sx-frame{--fh:min(calc(100svh - 68px - 44px), 860px);
  position:relative; z-index:1; height:var(--fh); display:flex; flex-direction:column; border-radius:14px; overflow:hidden;
  background:#0F1015; border:1px solid rgba(255,255,255,.10);
  box-shadow:0 1px 0 rgba(255,255,255,.06) inset, 0 50px 120px -40px rgba(0,0,0,.85), 0 30px 60px -30px rgba(0,0,0,.6)}
.sx-chrome{flex:none; height:40px; display:grid; grid-template-columns:80px minmax(0, 1fr) 80px; align-items:center;
  padding:0 14px; background:#1B1C22; border-bottom:1px solid rgba(0,0,0,.6)}
.sx-dots{display:flex; gap:7px}
.sx-dots i{width:11px; height:11px; border-radius:50%; background:#3A3C44}
.sx-addr{justify-self:center; display:flex; align-items:center; gap:7px; max-width:100%; min-width:0;
  padding:6px 16px; border-radius:8px; background:#111217; color:#8E949C; font:12px/1 var(--font-ui); white-space:nowrap}
.sx-addr > span{overflow:hidden; text-overflow:ellipsis}
.sx-addr svg{flex:none; color:#8E949C}
.sx-view{position:relative; flex:1; min-height:0; overflow:hidden}

/* ── underneath: the code editor ── */
.sx-editor{position:absolute; inset:0; display:flex; flex-direction:column; background:#0F1015;
  --lh:clamp(13px, calc((100svh - 214px) / 39), 19px); --fs:calc(var(--lh) * .68)}
.sx-tabs{flex:none; display:flex; height:32px; background:#15161C; border-bottom:1px solid rgba(255,255,255,.05)}
.sx-tab{display:flex; align-items:center; padding:0 18px; font:12px/1 var(--font-ui); color:#D9DDE3; background:#0F1015;
  border-right:1px solid rgba(255,255,255,.05); box-shadow:inset 0 1px 0 #DFE5EB}
.sx-tab-dim{color:#6B7079; background:transparent; box-shadow:none}
.sx-code-wrap{position:relative; flex:1; min-height:0; overflow:hidden}
.sx-code{list-style:none; margin:0; padding:10px 0; font:400 var(--fs)/var(--lh) var(--font-mono); color:#C9CED6;
  font-variant-ligatures:none; transform:translateY(var(--shift, 0px)); transition:transform .6s var(--ease-out)}
.sx-row{position:relative; display:grid; grid-template-columns:48px 18px minmax(0, 1fr) auto; align-items:center;
  min-height:var(--lh); padding-right:14px}
.sx-n{color:#474C55; text-align:right; padding-right:6px; font-size:.92em; font-variant-numeric:tabular-nums}
.sx-txt{display:block; min-width:0; white-space:pre; overflow:hidden}
.sx-hole .sx-txt{display:grid}
.sx-bad, .sx-good{grid-area:1 / 1; white-space:pre}
.sx-code i{font-style:normal}
.sx-code .k{color:#C4A7FF}
.sx-code .s{color:#E6C28B}
.sx-code .f{color:#7FCFEA}
.sx-code .p{color:#AFC0D3}
.sx-code .nu{color:#F0A877}
.sx-code .o{color:#7A818B}

/* a hole, before it is found: an ordinary line */
.sx-good{clip-path:inset(0 100% 0 0); transition:clip-path .55s var(--ease-out)}
.sx-bad{clip-path:inset(0 0 0 0); transition:clip-path .45s var(--ease-out), opacity .45s}
.sx-hole::before{content:''; position:absolute; inset:0; pointer-events:none; opacity:0;
  background:linear-gradient(90deg, rgba(239,35,60,.20), rgba(239,35,60,.07) 60%, rgba(239,35,60,.02));
  box-shadow:inset 2px 0 0 #EF233C; transition:opacity .35s var(--ease-out), background .5s, box-shadow .5s}
.sx-mark{position:relative; width:8px; height:8px; justify-self:center}
.sx-hole .sx-mark::before{content:''; position:absolute; inset:0; border-radius:50%; background:#EF233C;
  box-shadow:0 0 0 3px rgba(239,35,60,.18), 0 0 12px rgba(239,35,60,.7); transform:scale(0); transition:transform .35s var(--ease-out), background .4s, box-shadow .4s}
/* on a wide screen the tag floats at the line's right end, so it never makes the line taller */
.sx-tag{position:absolute; right:14px; top:50%; margin-top:-11px; display:inline-grid; align-items:center;
  height:22px; padding:0 10px 0 22px; border-radius:999px; font:500 11.5px/1 var(--font-ui); letter-spacing:.01em; white-space:nowrap;
  color:#FF9AA6; background:rgba(239,35,60,.12); border:1px solid rgba(239,35,60,.34);
  opacity:0; transform:translateX(8px); transition:opacity .35s var(--ease-out), transform .45s var(--ease-out), color .4s, background .4s, border-color .4s}
.sx-tag-bad, .sx-tag-good{grid-area:1 / 1; transition:opacity .35s}
.sx-tag-good{opacity:0}
/* the tag's icon: a red "!" mark, later a green tick */
.sx-tag::before{content:'!'; position:absolute; left:6px; top:50%; width:12px; height:12px; margin-top:-6px; border-radius:50%;
  background:#EF233C; color:#16060A; font:700 9px/12px var(--font-ui); text-align:center; transition:background .4s, color .4s}
.sx-tag::after{content:''; position:absolute; left:9.5px; top:50%; width:3px; height:6px; margin-top:-4.5px; opacity:0;
  border:solid #06150E; border-width:0 1.6px 1.6px 0; transform:rotate(45deg); transition:opacity .3s}

/* found: the line lights up red, once, with a short flare */
.sx-hole.is-lit::before{opacity:1; animation:sx-flare 1s var(--ease-out)}
.sx-hole.is-lit .sx-mark::before{transform:scale(1)}
.sx-hole.is-lit .sx-tag{opacity:1; transform:none}
@keyframes sx-flare{0%{background:linear-gradient(90deg, rgba(239,35,60,.55), rgba(239,35,60,.25) 60%, rgba(239,35,60,.08))} 100%{}}

/* fixed: the bad line wipes out, the corrected line writes in, everything turns green */
.sx-hole.is-fixed::before{background:linear-gradient(90deg, rgba(63,214,154,.17), rgba(63,214,154,.06) 60%, rgba(63,214,154,.015));
  box-shadow:inset 2px 0 0 #3FD69A; animation:none}
.sx-hole.is-fixed .sx-mark::before{background:#3FD69A; box-shadow:0 0 0 3px rgba(63,214,154,.16), 0 0 10px rgba(63,214,154,.5)}
.sx-hole.is-fixed .sx-bad{clip-path:inset(0 0 0 100%); opacity:0}
.sx-hole.is-fixed .sx-good{clip-path:inset(0 0 0 0); transition-delay:.12s}
.sx-hole.is-fixed .sx-tag{color:#8BEBC3; background:rgba(63,214,154,.10); border-color:rgba(63,214,154,.34)}
.sx-hole.is-fixed .sx-tag::before{content:''; background:#3FD69A}
.sx-hole.is-fixed .sx-tag::after{opacity:1}
.sx-hole.is-fixed .sx-tag-bad{opacity:0}
.sx-hole.is-fixed .sx-tag-good{opacity:1}

/* the status bar doubles as the caption */
.sx-status{flex:none; display:flex; align-items:center; gap:16px; height:28px; padding:0 14px; background:#15161C;
  border-top:1px solid rgba(255,255,255,.05); font:12px/1 var(--font-ui); color:#9AA0A8; position:relative}
.sx-st{position:absolute; left:14px; display:flex; align-items:center; gap:8px; opacity:0; transition:opacity .35s var(--ease-out)}
.sx-st b{font-weight:600; color:#DDE1E6; font-variant-numeric:tabular-nums}
.sx-dot{width:7px; height:7px; border-radius:50%; background:#6B7079}
.sx-st-1 .sx-dot{background:#EF233C; box-shadow:0 0 8px rgba(239,35,60,.7)}
.sx-st-2 .sx-dot{background:#E9B949}
.sx-st-3{color:#8BEBC3; font-weight:500}
.sx-st-3 .sx-dot{background:#3FD69A; box-shadow:0 0 8px rgba(63,214,154,.6)}
.sx:is([data-stage="0"], [data-stage="1"]) .sx-st-0,
.sx[data-stage="2"] .sx-st-1, .sx[data-stage="3"] .sx-st-2, .sx[data-stage="4"] .sx-st-3{opacity:1}
.sx-status-end{margin-left:auto; color:#5F656E}

/* ── on top: the made-up shop ── */
.sx-shop{position:absolute; inset:0; z-index:1; overflow:hidden; background:#F6F3EE; color:#1E1C19;
  font-family:var(--font-ui); clip-path:inset(calc(var(--cut) * 100%) 0 0 0)}
.sx-announce{height:28px; display:grid; place-items:center; background:#1E1C19; color:#E9E4DB;
  font-size:11.5px; letter-spacing:.04em}
.sx-head{display:grid; grid-template-columns:1fr auto 1fr; align-items:center; height:62px; padding:0 30px; border-bottom:1px solid #E2DCD2}
.sx-brand{display:flex; align-items:baseline; gap:8px; font:400 23px/1 'Iowan Old Style','Palatino Linotype','Book Antiqua',Palatino,Georgia,serif; letter-spacing:-.01em}
.sx-brand small{font:500 9px/1 var(--font-ui); letter-spacing:.3em; text-transform:uppercase; color:#7B746A}
.sx-nav{display:flex; gap:28px; font-size:13px; color:#3B3832}
.sx-icons{justify-self:end; display:flex; align-items:center; gap:22px; font-size:13px; color:#3B3832}
.sx-cart{display:flex; align-items:center; gap:6px}
.sx-feature{display:grid; grid-template-columns:1.1fr .9fr; gap:34px; align-items:center; margin:22px 30px 0}
.sx-feature-img{aspect-ratio:16 / 11; overflow:hidden; border-radius:4px; background:#D9CFC4}
.sx-feature-img img, .sx-card img{display:block; width:100%; height:100%; object-fit:cover}
.sx-feature-img img{object-position:50% 58%; transform:scale(1.02)}
.sx-feature-copy{display:grid; gap:12px; align-content:center}
.sx-kicker{font-size:10.5px; letter-spacing:.24em; text-transform:uppercase; color:#8A7F72}
.sx-feature-title{font:400 clamp(26px, 2.5vw, 36px)/1.05 'Iowan Old Style','Palatino Linotype','Book Antiqua',Palatino,Georgia,serif; letter-spacing:-.015em}
.sx-feature-text{font-size:13.5px; line-height:1.55; color:#5E584F; max-width:30ch}
.sx-feature-buy{display:flex; align-items:center; gap:18px; margin-top:6px}
.sx-price{font-size:16px; font-weight:500}
.sx-add{font-size:12.5px; font-weight:500; padding:11px 20px; border-radius:999px; background:#1E1C19; color:#F6F3EE}
.sx-grid-head{display:flex; align-items:baseline; justify-content:space-between; margin:30px 30px 14px;
  font:400 20px/1 'Iowan Old Style','Palatino Linotype','Book Antiqua',Palatino,Georgia,serif}
.sx-filter{display:flex; gap:18px; font:12.5px/1 var(--font-ui); color:#7B746A}
.sx-filter b{font-weight:500; color:#1E1C19; border-bottom:1px solid #1E1C19; padding-bottom:3px}
.sx-products{display:grid; grid-template-columns:repeat(3, minmax(0, 1fr)); gap:18px; padding:0 30px}
.sx-card{display:grid; gap:4px; font-size:13px}
.sx-card img{aspect-ratio:4 / 5; height:auto; border-radius:4px; background:#E8E2D9; margin-bottom:8px}
.sx-card p{color:#1E1C19}
.sx-card span{color:#6E675E}
.sx-card-m{display:none}

/* ── the scan line ── */
.sx-scan{position:absolute; left:0; right:0; top:calc(var(--cut) * 100%); z-index:2; height:0; pointer-events:none; opacity:0;
  transition:opacity .3s}
.sx[data-sweep] .sx-scan{opacity:1}
.sx-scan i{position:absolute; left:0; right:0; top:-1px; height:2px; background:#FF2E48;
  box-shadow:0 0 6px 1px rgba(255,46,72,.9), 0 0 26px 4px rgba(239,35,60,.45)}
/* the afterglow on the code it has just passed */
.sx-scan::before{content:''; position:absolute; left:0; right:0; bottom:0; height:160px;
  background:linear-gradient(to top, rgba(239,35,60,.16), rgba(239,35,60,.04) 45%, transparent)}
/* the shop's edge right under the line: a soft burn, so the cut never looks like a hard crop */
.sx-scan::after{content:''; position:absolute; left:0; right:0; top:0; height:26px;
  background:linear-gradient(to bottom, rgba(70,8,16,.55), rgba(239,35,60,.12) 40%, transparent)}

/* ── after the opening, the torch section is the second beat ── */
.sx + .sc-hero{padding-top:var(--s9)}

/* ── laptops with short screens: a little tighter ── */
@media (max-height:780px) and (min-width:701px){
  .sx .display{font-size:clamp(34px, 3.2vw, 46px)}
  .sx-copy{gap:var(--s4)}
  .sx .lede{font-size:15.5px}
}
@media (max-width:1100px) and (min-width:701px){
  .sx-grid{grid-template-columns:minmax(0, 300px) minmax(0, 1fr)}
  .sx-tag{font-size:10.5px}
  .sx-nav{display:none}
}

/* ── phone: the same story, shorter, stacked ── */
@media (max-width:700px){
  .sx{height:250vh}
  .sx-stage{padding-top:80px; padding-bottom:12px; align-items:stretch}
  .sx-grid{display:flex; flex-direction:column; gap:14px; width:calc(100% - 32px)}
  .sx-copy{gap:12px}
  .sx .label{font-size:10px}
  .sx .display{font-size:29px; line-height:1.05}
  .sx .lede{font-size:14.5px; line-height:1.45}
  .sx .actions{flex-wrap:nowrap; gap:10px}
  .sx .actions .btn{padding:12px 16px; font-size:14px; white-space:nowrap}
  .sx-steps{display:none}
  .sx-hint{font-size:12.5px}
  .sx-frame{flex:1 1 auto; height:auto; min-height:0; border-radius:12px}
  .sx-chrome{height:30px; grid-template-columns:44px minmax(0, 1fr) 20px; padding:0 10px}
  .sx-dots{gap:5px} .sx-dots i{width:8px; height:8px}
  .sx-addr{font-size:10.5px; padding:4px 10px}
  .sx-tabs{display:none}
  .sx-editor{--lh:12.5px; --fs:9.3px}
  .sx-row{grid-template-columns:24px 12px minmax(0, 1fr); padding-right:0}
  .sx-n{padding-right:4px; font-size:.85em}
  .sx-mh{display:none}
  .sx-mark{width:6px; height:6px}
  /* long lines fade out at the frame's edge, as a narrow editor would show them */
  .sx-txt{-webkit-mask-image:linear-gradient(90deg, #000 88%, transparent); mask-image:linear-gradient(90deg, #000 88%, transparent)}
  .sx .label{display:none}
  .sx-done{font-size:14.5px; gap:10px}
  .sx-done-tick{width:18px; height:18px}
  .sx-done-tick::after{left:6.5px; top:3.5px; width:3.5px; height:7px}
  /* the label opens under its line only once the hole is found, so an unfound hole is an ordinary line */
  .sx-hole{grid-template-rows:var(--lh) 0; transition:grid-template-rows .4s var(--ease-out)}
  .sx-hole.is-lit{grid-template-rows:var(--lh) 18px}
  .sx-tag{position:relative; right:auto; top:auto; margin:0; height:16px; grid-column:3; grid-row:2; justify-self:start; align-self:start;
    padding:0 8px 0 19px; font-size:10px}
  .sx-tag::before{left:5px; width:10px; height:10px; margin-top:-5px; font-size:8px; line-height:10px}
  .sx-tag::after{left:8px; width:2.5px; height:5px; margin-top:-3.8px}
  .sx-status{height:22px; font-size:10.5px; padding:0 10px}
  .sx-st{left:10px}
  .sx-status-end{display:none}
  .sx-announce{height:22px; font-size:9.5px; letter-spacing:.02em}
  .sx-head{height:44px; padding:0 14px; grid-template-columns:1fr auto}
  .sx-brand{font-size:17px}
  .sx-brand small{font-size:7.5px}
  .sx-nav, .sx-icons > span:first-child{display:none}
  .sx-icons{font-size:12px}
  .sx-feature{display:none}
  .sx-grid-head{margin:14px 14px 10px; font-size:16px}
  .sx-filter{display:none}
  .sx-products{grid-template-columns:repeat(2, minmax(0, 1fr)); gap:10px 10px; padding:0 14px}
  .sx-card{font-size:11.5px; gap:2px}
  .sx-card img{aspect-ratio:1 / 1; margin-bottom:5px; object-position:50% 62%}
  .sx-card-m{display:grid}
}
