/* ═══════════════════════════════════════════════════════════════════════
   TREATMENT: funnel
   The free surface. JT: "this is our main funnel."

   MEASURED off deloitte.com's five highest-intent pages,
   harness/probe-deloitte-conversion.py, sampled at top, mid and bottom:

     THE STICKY ASK BAR, on /alliances/aws.html
       top  h=89 z=2000 transform=matrix(1,0,0,1,0,-89)   hidden
       mid  h=89 z=2000 transform=matrix(1,0,0,1,0,-89)   hidden
       bot  h=89 z=2002 transform=matrix(1,0,0,1,0,  0)   slid in
       text "The Deloitte & Amazon Web Services (AWS) alliance | Download"

     It is translated up by EXACTLY its own height until the reader goes
     deep, then slides to 0 and its z-index is raised. It carries the
     page's SUBJECT as well as the ask, which is why it reads as the page
     following you rather than as an interruption.

     ASK POSITIONS, 32 asks measured
       p25 0.20   median 0.50   p75 0.81
     They repeat the ask at three depths. They do not stack three asks in
     one view, which is also Gyi's rule: one primary per screen view.

     ASK STYLING, most common first
       20 of 32   transparent bg, radius 0, 16px/600, no transition
        4 of 32   white, radius 100px, 14px/400, .3s
        2 of 32   filled, radius 20px to 100px
     The loud button is RARE. Most asks are quiet text. Ours already has
     the growing underline, so the quiet ask is a solved component.

   ⛔ WE DO NOT COPY THEIR FORM. Their contact form is 54 fields and the
   cyber page's is 37. Microsoft OAuth is one click against that, and it
   is the largest conversion advantage available to this page.

   Scoped to main plus one fixed element, which is declared below and is
   the single deliberate exception to the chrome rule.
   ═══════════════════════════════════════════════════════════════════════ */

/* ── the sticky ask bar ─────────────────────────────────────────────────
   ⛔ This is fixed, so it is NOT inside main. apply-treatment.py lints
   treatment sheets for selectors that escape main; `.ask-bar` is prefixed
   with [data-treatment="funnel"] so it can only ever exist on this one
   page, which keeps the chrome uniform everywhere else. */
[data-treatment="funnel"] .ask-bar{
  position:fixed;left:0;right:0;bottom:0;z-index:70;
  background:var(--deep);color:var(--on-deep);
  border-top:3px solid var(--hue,#0f5450);
  transform:translateY(100%);
  transition:transform .42s cubic-bezier(.22,.61,.36,1);
  will-change:transform}
[data-treatment="funnel"] .ask-bar.is-up{transform:translateY(0)}
[data-treatment="funnel"] .ask-bar-in{
  max-width:var(--max);margin:0 auto;padding:14px var(--gut);
  display:flex;align-items:center;gap:14px 22px;flex-wrap:wrap;
  min-height:72px}
[data-treatment="funnel"] .ask-bar-sub{
  font-family:var(--sans);font-size:15px;font-weight:600;
  color:var(--on-deep);margin:0;flex:1 1 320px;min-width:0}
[data-treatment="funnel"] .ask-bar-sub span{
  display:block;font-weight:400;font-size:13.5px;
  color:var(--on-deep-muted)}
[data-treatment="funnel"] .ask-bar .btn{margin:0;flex:0 0 auto}
@media (prefers-reduced-motion:reduce){
  [data-treatment="funnel"] .ask-bar{transition:none}
}
/* On a phone the bar is the whole bottom of the screen, so it stacks and
   the button goes full width rather than being squeezed beside the text. */
@media(max-width:620px){
  [data-treatment="funnel"] .ask-bar-in{padding-block:12px;min-height:0}
  [data-treatment="funnel"] .ask-bar .btn{width:100%;justify-content:center}
  [data-treatment="funnel"] .ask-bar-sub span{display:none}
}

/* ── the sign-in block: one button, no form ────────────────────────────── */
[data-treatment="funnel"] main .signin{
  display:flex;flex-direction:column;align-items:flex-start;gap:12px}
[data-treatment="funnel"] main .signin .btn{min-height:52px;font-size:16px}
[data-treatment="funnel"] main .signin .ms-mark{
  display:inline-grid;grid-template-columns:repeat(2,9px);gap:2px;
  margin-right:10px}
[data-treatment="funnel"] main .signin .ms-mark i{
  width:9px;height:9px;display:block}
[data-treatment="funnel"] main .signin .ms-mark i:nth-child(1){background:#f25022}
[data-treatment="funnel"] main .signin .ms-mark i:nth-child(2){background:#7fba00}
[data-treatment="funnel"] main .signin .ms-mark i:nth-child(3){background:#00a4ef}
[data-treatment="funnel"] main .signin .ms-mark i:nth-child(4){background:#ffb900}
/* ⛔ NOT .note. register-v23.css defines .note as a DARK callout
   (background:var(--deep)), so this caption rendered as a navy box under
   the sign-in button. Same class-collision shape as .band being v23's
   amber chip. Named .signin-note so it cannot collide. */
[data-treatment="funnel"] main .signin .signin-note{
  font-size:13px;color:var(--ink-dim);margin:0;max-width:52ch}

/* ── the allowance meter: the limit, shown as a fact not a warning ─────── */
[data-treatment="funnel"] main .meter{
  display:flex;align-items:center;gap:8px;margin:0 0 14px}
[data-treatment="funnel"] main .meter i{
  width:26px;height:6px;border-radius:3px;background:var(--hue,#0f5450);
  display:block}
[data-treatment="funnel"] main .meter i.spent{background:var(--rule-light)}
[data-treatment="funnel"] main .meter span{
  font-family:var(--sans);font-size:12.5px;font-weight:700;
  letter-spacing:.06em;text-transform:uppercase;color:var(--ink-dim);
  margin-left:6px}

/* ── the three-way comparison, which is the conversion argument ────────── */
[data-treatment="funnel"] main .ladder{
  display:grid;gap:14px;
  grid-template-columns:repeat(auto-fit,minmax(min(260px,100%),1fr))}
[data-treatment="funnel"] main .ladder>div{
  background:#fff;border:1px solid var(--rule-light);
  border-radius:var(--r-soft);padding:clamp(18px,2vw,26px);min-width:0}
[data-treatment="funnel"] main .ladder>div h3{
  font-family:var(--sans);font-size:14px;margin:0 0 10px}
[data-treatment="funnel"] main .ladder>div p{
  font-size:14.5px;line-height:1.5;margin:0 0 8px;max-width:none}
[data-treatment="funnel"] main .ladder>div .verdict{
  font-family:var(--sans);font-size:13px;font-weight:700;margin:0}
/* The middle column is the one only we can write, so it carries the
   weight. Its colour is the risk family regardless of page accent. */
[data-treatment="funnel"] main .ladder>div.risk{
  border-top:3px solid #b91c1c}
[data-treatment="funnel"] main .ladder>div.risk .verdict{color:#b91c1c}
[data-treatment="funnel"] main .ladder>div.now{
  border-top:3px solid var(--rule-light)}
[data-treatment="funnel"] main .ladder>div.paid{
  border-top:3px solid var(--hue,#0f5450)}
[data-treatment="funnel"] main .ladder>div.paid .verdict{
  color:var(--hue,#0f5450)}

/* Asks repeat at the measured depths rather than stacking. Each inline ask
   is the quiet text form, which was 20 of their 32. */
[data-treatment="funnel"] main .ask-inline{
  display:inline-flex;align-items:center;min-height:44px;
  font-family:var(--sans);font-size:16px;font-weight:600;
  color:var(--hue,#0f5450);text-decoration:none;border:0}

/* ═══════════════════════════════════════════════════════════════════════
   THE ACKNOWLEDGEMENT GATE
   JT: "id really like the animations to be check boxes indemnifying us,
   before they get to the search bar. make it a bit of a game, use 4MAT,
   4 boxes, then access, each releases us from being able to be sued in
   theory."

   ⛔ WHAT THIS ACTUALLY DOES, so nobody later believes more of it than is
   true. A clickwrap does not make us unsueable. It establishes NOTICE and
   ASSENT: it makes the disclaimer and the limitation of liability
   conspicuous and provable, and conspicuous clickwrap is enforced far more
   readily than terms buried behind a footer link. That is a defence, not
   immunity, and the wording is an attorney's call.

   THE 4MAT MAPPING, which is why this is four boxes and not one:
     1 Engage   why      what this is for, and what it is not
     2 Inform   what     what it does, and where it stops
     3 Practice how      what YOU must do before relying on it
     4 Create   what if  what happens to what you type

   Each box teaches one quadrant. The reader finishes the gate having been
   taught the product, which is the opposite of a EULA nobody reads.

   THE GAME, kept professional. A rail fills, each row locks in, the
   search surface un-dims on the fourth. No confetti: the audience is
   attorneys and the tone that converts them is competence.

   ⛔ ACCESSIBILITY IS NOT OPTIONAL HERE. These are REAL checkboxes with
   real labels, reachable and operable by keyboard, 44px targets, and the
   submit control carries aria-disabled rather than being hidden, so a
   screen reader user is told why it is not yet available.
   ═══════════════════════════════════════════════════════════════════════ */

[data-treatment="funnel"] main .gate{
  background:#fff;border:1px solid var(--rule-light);
  border-radius:var(--r-soft);padding:clamp(20px,2.4vw,32px);
  max-width:760px}
[data-treatment="funnel"] main .gate>h2{margin-bottom:6px}
[data-treatment="funnel"] main .gate .gate-sub{
  font-size:14.5px;color:var(--ink-dim);margin:0 0 20px;max-width:60ch}

/* the progress rail */
[data-treatment="funnel"] main .gate-rail{
  display:flex;gap:6px;margin:0 0 22px;padding:0;list-style:none}
[data-treatment="funnel"] main .gate-rail li{
  flex:1 1 0;height:5px;border-radius:3px;background:var(--rule-light);
  transition:background .4s cubic-bezier(.22,.61,.36,1)}
[data-treatment="funnel"] main .gate-rail li.on{background:var(--hue,#15803d)}

/* one acknowledgement */
[data-treatment="funnel"] main .ack{
  display:grid;grid-template-columns:28px minmax(0,1fr);gap:0 14px;
  align-items:start;padding:16px 0;
  border-top:1px solid var(--rule-light);
  transition:opacity .35s ease}
[data-treatment="funnel"] main .ack:first-of-type{border-top:0}
[data-treatment="funnel"] main .ack input[type=checkbox]{
  width:24px;height:24px;margin:2px 0 0;accent-color:var(--hue,#15803d);
  cursor:pointer}
/* The 44px target is the LABEL, which is the thing a thumb lands on. */
/* ⛔ grid-column:2 OR THE LABEL LANDS IN THE 28px CHECKBOX COLUMN.
   .q, .why and .then each carry it explicitly; the label did not, so it
   auto-placed into column 1 and every acknowledgement rendered one word
   per line. Visible in the first capture of the page. */
[data-treatment="funnel"] main .ack label{
  grid-column:2;
  cursor:pointer;min-height:44px;display:flex;align-items:center;
  font-family:var(--sans);font-size:15.5px;font-weight:600;
  line-height:1.4;color:var(--ink)}
[data-treatment="funnel"] main .ack .why{
  grid-column:2;margin:0;font-size:14px;line-height:1.55;
  color:var(--ink-muted);max-width:62ch}
[data-treatment="funnel"] main .ack .q{
  grid-column:2;font-family:var(--sans);font-size:11px;font-weight:700;
  letter-spacing:.08em;text-transform:uppercase;color:var(--ink-dim);
  margin:0 0 4px}

/* locked in. A left rule in the accent, and the row settles. */
[data-treatment="funnel"] main .ack.done{opacity:.72}
[data-treatment="funnel"] main .ack.done label{color:var(--ink-dim)}
@media (prefers-reduced-motion:no-preference){
  html.js-motion[data-treatment="funnel"] main .ack.done label{
    animation:ack-lock .34s cubic-bezier(.22,.61,.36,1)}
}
@keyframes ack-lock{
  0%{transform:translateX(0)}
  40%{transform:translateX(5px)}
  100%{transform:translateX(0)}}

/* the release */
[data-treatment="funnel"] main .gate-out{
  margin-top:22px;padding-top:20px;border-top:1px solid var(--rule-light);
  opacity:.45;filter:saturate(.25);
  transition:opacity .45s ease,filter .45s ease}
[data-treatment="funnel"] main .gate.unlocked .gate-out{
  opacity:1;filter:none}
[data-treatment="funnel"] main .gate-out .btn[aria-disabled="true"]{
  pointer-events:none}
[data-treatment="funnel"] main .gate-count{
  font-family:var(--sans);font-size:12.5px;font-weight:700;
  letter-spacing:.06em;text-transform:uppercase;color:var(--ink-dim);
  margin:0 0 12px}
[data-treatment="funnel"] main .gate.unlocked .gate-count{
  color:var(--hue,#15803d)}

/* The stamp: what is recorded, shown plainly. A gate whose record is
   hidden is the kind of dark pattern this page exists to be the opposite
   of. */
[data-treatment="funnel"] main .gate-stamp{
  margin:14px 0 0;font-size:12.5px;line-height:1.5;color:var(--ink-dim);
  max-width:62ch}

/* The third line of each box: the bridge.
   JT: "each box also explains, removes hesitations, or skepticism, also
   leads people to why the paid product is the right choice for pro legal
   work."

   Every limitation we disclose IS a paid feature stated in the negative,
   so the disclaimer and the sales argument are the same four sentences.
   Set apart by a rule and the page hue so a skimmer can read only these
   four lines and still get the whole commercial argument. */
[data-treatment="funnel"] main .ack .then{
  grid-column:2;margin:10px 0 0;padding:10px 0 0 14px;
  border-left:2px solid var(--hue,#15803d);
  font-size:14px;line-height:1.55;color:var(--ink-muted);max-width:62ch}
[data-treatment="funnel"] main .ack .then a{
  font-weight:700;color:var(--hue,#15803d);white-space:nowrap}
[data-treatment="funnel"] main .ack.done .then{opacity:1}

/* ── THE FIXED BAR MUST NOT OWN 39% OF THE PHONE ────────────────────────
   MEASURED at 390x844: .ask-bar was 329px tall and fixed at z-index 70,
   with nothing reserving space for it, so the three comparison cards
   below it were painted over and unreadable at every scroll position.
   The bar is designed here as a 72px row; free-tier-limits.py later put
   two explanatory paragraphs in it, 184px of the 329.

   Both paragraphs now also render in the page beside the sign-in button
   (inline-ask-bar-copy.py), so hiding them inside the FIXED bar on a
   phone loses nothing. Verified before writing this rule: their text
   appeared nowhere else in the document.

   ⛔ RESERVING THE SPACE IS NOT OPTIONAL. Slimming the bar shrinks the
   occlusion but does not remove it: without padding at the end of the
   document the last band is still permanently underneath it. */
@media(max-width:620px){
  [data-treatment="funnel"] .ask-bar .ask-bar-modes,
  [data-treatment="funnel"] .ask-bar .ask-bar-note{display:none}
}
[data-treatment="funnel"] body{padding-bottom:132px}
@media(max-width:620px){
  [data-treatment="funnel"] body{padding-bottom:156px}
}
[data-treatment="funnel"] main .ask-copy-inline{margin:0 0 18px}
[data-treatment="funnel"] main .ask-copy-inline p{
  font-size:15px;line-height:1.55;margin:0 0 8px;max-width:58ch}

/* ═══ THE CHECK PANEL ═══════════════════════════════════════════════════
   /legal-citation-checker/ published "Paste the passage you need checked"
   while carrying no text input at all — four consent checkboxes, no form,
   no fetch, and a sign-in button that was an <a href="/access/"> to a beta
   email-capture page. This styles the input that promise needs.

   It sits inside .gate-out, so it inherits the dimmed-until-unlocked
   treatment above and the pointer-events:none rule on aria-disabled
   buttons — which doubles as the double-submit guard while a check runs. */
[data-treatment="funnel"] main .check{
  margin-top:22px;padding-top:20px;border-top:1px solid var(--rule-light)}
[data-treatment="funnel"] main .check-h{
  font-size:19px;line-height:1.3;margin:0 0 6px}
[data-treatment="funnel"] main .check-modes{
  font-size:14px;line-height:1.5;color:var(--ink-dim);margin:0 0 14px;
  max-width:60ch}

/* The label is visible, not a placeholder. A placeholder disappears the
   moment someone types and is not a label to a screen reader. */
[data-treatment="funnel"] main .check-label{
  display:block;font-family:var(--sans);font-size:12.5px;font-weight:700;
  letter-spacing:.06em;text-transform:uppercase;color:var(--ink-dim);
  margin:0 0 7px}
[data-treatment="funnel"] main .check-text{
  display:block;width:100%;box-sizing:border-box;
  font:inherit;font-size:16px;line-height:1.55;
  padding:13px 14px;border:1px solid var(--rule-light);
  border-radius:var(--r-soft,6px);background:#fff;color:var(--ink);
  resize:vertical;min-height:132px}
[data-treatment="funnel"] main .check-text:focus-visible{
  outline:3px solid var(--hue,#15803d);outline-offset:2px}
/* Disabled until all four boxes are ticked. Stated visually as well as in
   the DOM, so the reason is legible rather than inferred. */
[data-treatment="funnel"] main .check-text:disabled{
  background:#f6f6f4;color:var(--ink-muted);cursor:not-allowed}
[data-treatment="funnel"] main .check-count{
  font-family:var(--sans);font-size:12.5px;color:var(--ink-dim);
  margin:7px 0 14px}

[data-treatment="funnel"] main .check-note{
  margin:13px 0 0;font-size:14.5px;line-height:1.55;color:var(--ink);
  max-width:62ch}

/* ⛔ THREE OUTCOMES, THREE TREATMENTS, AND THE THIRD IS NOT A VERDICT.
   found / not-in-our-index / could-not-check. The middle one is amber and
   never red: absence from our corpus is a statement about our coverage,
   not proof a case is fabricated, and a false red costs an attorney as
   much as a false green. The third is grey because a search outage is our
   fault and says nothing about the citation either way. */
[data-treatment="funnel"] main .check-out{
  list-style:none;margin:16px 0 0;padding:0}
[data-treatment="funnel"] main .check-row{
  padding:13px 0 14px;border-top:1px solid var(--rule-light)}
[data-treatment="funnel"] main .check-row:first-child{border-top:0}
[data-treatment="funnel"] main .check-cite{
  font-family:var(--sans);font-size:15.5px;font-weight:700;
  margin:0 0 5px;color:var(--ink)}
[data-treatment="funnel"] main .check-verdict{
  font-family:var(--sans);font-size:12px;font-weight:700;
  letter-spacing:.06em;text-transform:uppercase;margin:0 0 6px}
[data-treatment="funnel"] main .check-verdict.is-found{color:#15803d}
[data-treatment="funnel"] main .check-verdict.is-absent{color:#b45309}
[data-treatment="funnel"] main .check-verdict.is-unknown{color:var(--ink-dim)}
/* ⛔ THE THIRD VERDICT, AND IT IS THE MOST DANGEROUS ONE TO GET WRONG.
   "Real citation, different case" is not a find and not an absence. It is
   RED, not amber: an absent citation means we could not confirm it, which
   is a statement about our holdings. A name mismatch means the text asserts
   something the record contradicts, which is a finding about the TEXT, and
   it is the one an attorney must act on before filing.
   #b91c1c on the card ground measures 6.4:1, clear of the 4.5 floor.
   The row gets a left rule so it is findable in a list without reading. */
[data-treatment="funnel"] main .check-verdict.is-mismatch{color:#b91c1c}
[data-treatment="funnel"] main .check-row.is-mismatch{
  border-left:3px solid #b91c1c;padding-left:14px}
[data-treatment="funnel"] main .check-row.is-mismatch .check-why{
  font-size:13.5px;line-height:1.55;color:var(--ink);margin-top:6px}
[data-treatment="funnel"] main .check-meta,
[data-treatment="funnel"] main .check-treatment{
  font-size:14px;line-height:1.55;color:var(--ink-dim);margin:0 0 6px;
  max-width:62ch}
[data-treatment="funnel"] main .check-treatment{font-weight:600;color:#b45309}
[data-treatment="funnel"] main .check-stamp{
  margin:16px 0 0;font-size:12.5px;line-height:1.5;color:var(--ink-dim);
  max-width:62ch}
