/* ============================================================================
   ApexEvolv — CONTACT (contact.html)

   One page since 23 Nov 2026, on the client's brief: it replaces Find Talent
   and Submit Your CV (contact-find-talent.html, contact-submit-cv.html, now
   removed and redirected in _redirects to contact.html?form=talent and
   ?form=cv). Loaded on contact.html only, last.

   ONE SHORT SECTION between the header and the footer:
     left   the label, the headline, a paragraph; under it a caption and a
            ruled list of three rows; at its foot the email address and
            telephone number
     right  a switch (Find talent / Submit your CV) above a black box that
            holds the form
   The two columns finish level: the box stretches to the foot of the left
   column (the message field takes the spare height), and the direct lines
   sit at the foot of the left column.

   TWO VERSIONS IN THE MARKUP. Everything that changes with the switch
   carries data-v="talent" or data-v="cv". The page's script sets
   data-form on the section, and these rules hide the other version. With
   scripting off there is no data-form: both versions show, one under the
   other, and the switch is hidden. (No [data-rv] reveal on this page:
   motion.css hides [data-rv] until scripting reveals it, so with scripting
   off the forms would not show at all.)

   THE FORMS ARE ON NETLIFY FORMS (since 25 Nov 2026, on the client's brief):
   "find-talent" and "submit-cv", each with Netlify's honeypot (.ct-hp,
   hidden below). The inline script on the page checks the fields, sends the
   form in the background, disables the button while it does, and shows the
   thank-you (.ct-done) in the black box or, on failure, an error with the
   email address (.ct-msg a). Email notifications are set in the Netlify
   dashboard, not here.

   SINCE THE CLIENT'S FORMS BRIEF OF 26 NOV 2026: each field that is checked
   shows its own short error under it (.ct-err, written by the page's
   script) in a muted red (--ct-err) that holds 7.6:1 on the black box, and
   the field takes the same red outline; the line under the button only
   says "Please check the highlighted fields." The reassurance line sits on
   its own line above the button. The box has the site's card corners
   (--cardR) and its controls half of that. Still outstanding from the first version of this
   note: a PDPA privacy notice linked beside each button, with a consent
   line on the candidate form.

   The values are the brief's. Where a site token holds the same value it is
   used: --ink #121214, --mu #5E5F66, --goldDeep #7C5E24, --line
   rgba(18,18,20,.12), --line2 rgba(18,18,20,.20), --t-micro 11.84px,
   --t-body 17px; .wrap is the site container, .lab the section label, .btn
   the pill button.
   ============================================================================ */

/* ---- the section ------------------------------------------------------------ */
/* below the fixed header bar (59px), then the brief's 72px; 88px above the
   footer. .sec.ct outranks main > section:last-of-type in light.css */
.sec.ct{margin-top:59px;padding:72px 0 88px}
.ct__in{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));column-gap:32px;
  grid-template-rows:auto 1fr}
.ct__intro{grid-column:1 / 6;grid-row:1}
.ct__more{grid-column:1 / 6;grid-row:2;display:flex;flex-direction:column;padding-top:44px}
.ct__panel{grid-column:7 / -1;grid-row:1 / 3;display:flex;flex-direction:column}

/* ---- the left column ------------------------------------------------------------ */
.ct__intro .lab{margin:0}
.ct h1{margin:24px 0 0;max-width:none;font-size:52px;font-weight:600;letter-spacing:-.045em;
  line-height:1.04;color:var(--ink)}
.ct__lede{margin:24px 0 0;max-width:42ch;font-size:var(--t-body);line-height:1.6;color:var(--mu)}

/* the caption: label type, grey */
.ct-cap{margin:0;font-size:var(--t-micro);font-weight:700;letter-spacing:.14em;
  text-transform:uppercase;color:var(--mu)}
/* three rows on rules: the term, then what it means */
.ct-list{margin:14px 0 0;padding:0;border-top:1px solid var(--line2)}
.ct-list > div{display:grid;grid-template-columns:132px minmax(0,1fr);column-gap:20px;
  padding:16px 0;border-bottom:1px solid var(--line)}
.ct-list dt{font-size:var(--t-micro);font-weight:700;letter-spacing:.14em;text-transform:uppercase;
  line-height:24px;color:var(--ink)}
.ct-list dd{margin:0;font-size:15px;line-height:1.6;color:var(--mu)}

/* the direct lines, at the foot of the column */
.ct-direct{margin-top:auto;padding-top:36px}
.ct-direct__l{display:flex;flex-wrap:wrap;column-gap:28px;margin:6px 0 0}
.ct-direct__l a{display:inline-flex;align-items:center;min-height:44px;font-size:var(--t-body);
  font-weight:600;color:var(--ink);text-decoration:underline;text-decoration-thickness:1px;
  text-underline-offset:5px;text-decoration-color:var(--line2);transition:text-decoration-color .25s var(--e)}
.ct-direct__l a:hover{text-decoration-color:var(--goldDeep)}

/* ---- the switch -------------------------------------------------------------------- */
.ct-switch{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px;padding:4px;
  border:1px solid var(--line2);border-radius:980px;background:#FFFFFF}
.ct-switch button{height:48px;border-radius:980px;background:transparent;color:var(--mu);
  font-size:var(--t-micro);font-weight:700;letter-spacing:.14em;text-transform:uppercase;
  cursor:pointer;transition:background-color .25s var(--e),color .25s var(--e)}
.ct-switch button:hover{color:var(--ink)}
.ct-switch button[aria-pressed="true"]{background:#121214;color:#FFFFFF}

/* ---- the black box and its form ------------------------------------------------------ */
.ct-box{
  --gold:#D6BE93; --goldDeep:#D6BE93; --goldHi:#E2CDA6; --onGold:#12100A;
  /* a muted red for errors, between the gold and the black: 7.6:1 on
     #12110F as text, so it passes AA as text and as an outline */
  --ct-err:#E0907F;
  /* the controls' corners: half the card's, so they sit inside the box's
     curve rather than echo it at full size */
  --ct-r:calc(var(--cardR) / 2);
  flex:1;display:flex;flex-direction:column;margin-top:20px;padding:40px;
  background:#12110F;border-top:1px solid rgba(214,190,147,.6);border-radius:var(--cardR);color:#FFFFFF}
.ct-rows{flex:1;display:flex;flex-direction:column;gap:20px}
/* fields in a row line up by their foot, should one label wrap */
.ct-row{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;align-items:end}
.ct-row--1{grid-template-columns:minmax(0,1fr)}
/* the message row takes the box's spare height */
.ct-row--grow{flex:1;align-items:stretch}

.ct-fld{display:flex;flex-direction:column;gap:8px;min-width:0}
/* A field is three tracks: its label, its control, and its error, if any.
   The tracks are shared across the row (subgrid), so the controls in a row
   stay level when one label wraps, and an error under one field does not
   push its neighbour down. With no error the third track is empty and
   takes no height, so the row is exactly as it was. */
@supports (grid-template-rows:subgrid){
  .ct-row{row-gap:0}
  .ct-fld{display:grid;grid-row:span 3;grid-template-rows:subgrid;gap:0}
  .ct-fld > .ct-fld__l{align-self:end;margin-bottom:8px}
  .ct-row--grow{grid-template-rows:auto minmax(0,1fr) auto}
  .ct-row--grow .ct-fld textarea{align-self:stretch}
}
/* the error, under its field */
.ct-err{display:block;margin-top:8px;font-size:13.5px;font-weight:400;line-height:1.45;
  letter-spacing:normal;text-transform:none;color:var(--ct-err)}
.ct-err:empty{display:none}
.ct-fld__l{font-size:var(--t-micro);font-weight:700;letter-spacing:.14em;text-transform:uppercase;
  line-height:1.3;color:rgba(244,243,239,.9)}
.ct-fld__l small{margin-left:.5em;font-size:1em;font-weight:600;letter-spacing:.1em;color:rgba(244,243,239,.62)}
.ct-fld input,.ct-fld textarea{display:block;width:100%;height:50px;padding:0 16px;
  font:inherit;font-size:15.5px;font-weight:400;letter-spacing:normal;text-transform:none;line-height:1.4;
  color:#FFFFFF;caret-color:#D6BE93;background:rgba(244,243,239,.06);
  border:1px solid rgba(244,243,239,.4);border-radius:var(--ct-r);text-overflow:ellipsis;
  transition:border-color .2s var(--e),box-shadow .2s var(--e)}
.ct-fld input::placeholder,.ct-fld textarea::placeholder{color:rgba(244,243,239,.6);opacity:1}
.ct-fld input:focus,.ct-fld textarea:focus{outline:none;border-color:#D6BE93;box-shadow:0 0 0 3px rgba(214,190,147,.24)}
.ct-fld input[aria-invalid="true"],.ct-fld textarea[aria-invalid="true"]{border-color:var(--ct-err)}
.ct-fld input[aria-invalid="true"]:focus,.ct-fld textarea[aria-invalid="true"]:focus{
  border-color:var(--ct-err);box-shadow:0 0 0 3px rgba(224,144,127,.26)}
.ct-fld textarea{flex:1;height:auto;min-height:96px;padding:13px 16px;resize:none}

/* the CV: a field-sized control with a real file input laid over it */
/* At 1440 the control is 242px wide (half the box) and "Attach your CV" with
   "PDF or Word" needs about 254px at 15.5px with 16px padding and 10px gaps,
   so the name is set at 14.5px (the brief gives no size for it) with 13px
   padding and 8px gaps: about 211px of content in 214. Narrower than that
   (1024px windows), "PDF or Word" gives way rather than the name; the
   container query measures the content box. */
.ct-file{position:relative;display:flex;align-items:center;gap:8px;height:50px;padding:0 13px;
  border:1px dashed rgba(244,243,239,.46);border-radius:var(--ct-r);color:#FFFFFF;container-type:inline-size;
  transition:border-color .2s var(--e),box-shadow .2s var(--e)}
@container (max-width:211px){.ct-file__k{display:none}}
.ct-file input{position:absolute;inset:0;width:100%;height:100%;padding:0;opacity:0;cursor:pointer}
.ct-file svg{width:17px;height:17px;flex:none;fill:none;stroke:#D6BE93;stroke-width:1.6;
  stroke-linecap:round;stroke-linejoin:round}
.ct-file__n{flex:1;min-width:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;
  font-size:14.5px;font-weight:400;letter-spacing:normal;text-transform:none}
.ct-file__k{flex:none;font-size:13px;font-weight:400;letter-spacing:normal;text-transform:none;color:rgba(244,243,239,.7)}
.ct-file:hover{border-color:rgba(244,243,239,.7)}
.ct-file:focus-within{border-color:#D6BE93;box-shadow:0 0 0 3px rgba(214,190,147,.24)}
/* a file that is the wrong type or too large, as the other fields mark theirs */
.ct-file:has(input[aria-invalid="true"]){border-color:var(--ct-err)}
.ct-file:has(input[aria-invalid="true"]):focus-within{box-shadow:0 0 0 3px rgba(224,144,127,.26)}

/* the last rows: the reassurance on its own line, full width, then the
   button. (Side by side, the CV form's note was squeezed into four narrow
   lines beside its longer button.) A privacy line or consent box, when one
   is added, goes between the two, 16px apart like these, the button last. */
.ct-go{display:flex;flex-direction:column;align-items:flex-end;gap:16px;margin-top:28px}
.ct-go__note{align-self:stretch;margin:0;font-size:13.5px;line-height:1.5;color:rgba(244,243,239,.74)}
.btn.ct-send{height:54px;padding:0 28px;font-size:.76rem;font-weight:700;letter-spacing:.14em;
  text-transform:uppercase;cursor:pointer}
/* while the form is sending */
.btn.ct-send:disabled{opacity:.55;cursor:progress}
.ct-msg{margin:14px 0 0;font-size:13.5px;line-height:1.5;color:#E2CDA6}
.ct-msg:empty{display:none}
/* the email address offered when sending fails */
.ct-msg a{color:inherit;text-decoration:underline;text-underline-offset:3px}
.ct-msg a:hover{color:#FFFFFF}

/* Netlify's honeypot: out of sight and out of the tab order, but in the page
   (not display:none), so a form-filling bot still finds and fills it */
.ct-hp{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;
  clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap;border:0}

/* sent: the thank-you takes the form's place in the same black box, under
   the label's short gold rule, set like the site's subheadings */
.ct-box--done > :not(.ct-done){display:none}
.ct-done{flex:1;display:flex;flex-direction:column;justify-content:center;gap:22px;outline:none}
.ct-done::before{content:"";width:32px;height:1px;background:#D6BE93}
.ct-done__t{margin:0;max-width:24ch;font-size:28px;font-weight:600;letter-spacing:-.03em;
  line-height:1.25;color:#FFFFFF}

/* ---- the two versions -------------------------------------------------------------------- */
.ct[data-form="talent"] [data-v="cv"],
.ct[data-form="cv"] [data-v="talent"]{display:none}
/* scripting off: no switch, both versions one under the other */
.ct:not([data-form]) .ct-switch{display:none}
.ct:not([data-form]) .ct-box + .ct-box{margin-top:32px}
.ct:not([data-form]) [data-v] + [data-v]{margin-top:24px}

/* ---- 900px and under: one column -------------------------------------------------------------
   label, heading, paragraph; switch and box; caption and list; direct lines
   (the markup's own order) */
@media(max-width:900px){
  .sec.ct{padding:44px 0 56px}
  .ct__in{grid-template-columns:minmax(0,1fr);grid-template-rows:none}
  .ct__intro,.ct__more,.ct__panel{grid-column:1 / -1;grid-row:auto}
  .ct h1{font-size:38px}
  .ct__panel{margin-top:32px}
  .ct-box{padding:24px}
  .ct-row--grow{flex:none}
  .ct-go{flex-direction:column;align-items:stretch;gap:16px}
  .btn.ct-send{width:100%;justify-content:center}
  .ct-done{padding:12px 0}
  .ct-done__t{font-size:22px}
}
/* 600px and under: one field to a row; each list term above its text */
@media(max-width:600px){
  .ct-row{grid-template-columns:minmax(0,1fr)}
  @supports (grid-template-rows:subgrid){ .ct-row > .ct-fld + .ct-fld{margin-top:20px} }
  .ct-list > div{grid-template-columns:minmax(0,1fr);row-gap:4px}
}
