/* ============================================================================
   SYHF 2026 — Impact Award participant status (impact-status.html)

   Builds on impact.css (the award's near-black + dark-gold identity, its
   .imp tokens, buttons and app bar). Nothing here introduces a hue: gold is
   the award accent, mint (--syhs-tint-mint) is the locked success signal,
   the on-dark error red is the locked error role.

   ONE dominant move per state: the verdict headline. Under it, the
   signature: the award's dotted waves twisted into a double strand (the DNA
   helix motif) that DRAWS ITSELF only as far as this applicant has got —
   submitted → under review → finalist → winners announced. Horizontal on
   wide screens; on phones it becomes a vertical rail beside the steps
   (authored, not a squeezed row).

   Contrast (on --imp-ground #0b0a07): text #f4f1e8 17.5:1 · soft #c9c3b0
   11.2:1 · mute #a8a28f 7.8:1 · gold #CC9E00 7.97:1 · gold-hi 10.9:1 ·
   mint #66d3a1 10.6:1 · error #ff8a80 8.9:1. Dark text on gold fill 7.97:1.
   ========================================================================== */
.ims { --ims-mint: var(--syhs-tint-mint, #66d3a1); --ims-err: var(--syhs-error-on-dark, #ff8a80); }
.ims-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.ims-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
#ims-main:focus { outline: none; }
.ims-wrap { max-width: 72rem; margin: 0 auto; padding-inline: clamp(1rem, 4vw, 2rem); }
.ims-sec { padding-block: clamp(2.75rem, 7vw, 5rem); border-top: 1px solid var(--imp-line); }
.ims-h3 { margin: 0 0 0.6rem; font-size: 1.5rem; font-weight: 700; letter-spacing: -0.01em; }

/* ---- The strand ---------------------------------------------------------- */
.ims-strand { fill: none; stroke-width: 3; stroke-linecap: round; stroke-dasharray: 0.1 9; vector-effect: non-scaling-stroke; }
.ims-strand--a { stroke: var(--imp-gold); }
.ims-strand--b { stroke: var(--imp-teal); opacity: 0.8; }

/* ---- Loading -------------------------------------------------------------- */
.ims-loading { padding-block: clamp(3rem, 9vw, 6rem); }
.ims-skel { height: 1.1rem; max-width: 34rem; margin-top: 0.9rem; border-radius: 8px;
  background: linear-gradient(90deg, rgba(244,241,232,0.06), rgba(244,241,232,0.12), rgba(244,241,232,0.06));
  background-size: 200% 100%; animation: ims-shimmer 1.4s linear infinite; }
.ims-skel--h { height: 3.4rem; max-width: 30rem; }
.ims-skel--short { max-width: 18rem; }
@keyframes ims-shimmer { to { background-position: -200% 0; } }

/* ---- Gate ------------------------------------------------------------------ */
.ims-gate { display: grid; gap: clamp(1.5rem, 4vw, 3.5rem); padding-block: clamp(2.5rem, 8vw, 5.5rem); align-items: start; }
.ims-gate__title, .ims-fault__title { margin: 0 0 1rem; font-size: clamp(2.3rem, 1.5rem + 3.6vw, 4.2rem); font-weight: 700; line-height: 1.02; letter-spacing: -0.035em; text-wrap: balance; }
.ims-gate__title em, .ims-title em, .ims-close__title em { font-family: var(--font-serif); font-style: italic; font-weight: 400; color: var(--imp-gold-hi); letter-spacing: -0.01em; }
.ims-gate__form { padding: clamp(1.25rem, 3vw, 2rem); border: 1px solid var(--imp-line); border-radius: var(--imp-r); background: rgba(244,241,232,0.035); }
@media (min-width: 860px) { .ims-gate { grid-template-columns: 1.15fr 1fr; } }

/* ---- Forms --------------------------------------------------------------- */
.ims-field { display: grid; gap: 0.4rem; margin-bottom: 1rem; }
.ims-field label { font-size: 0.9rem; font-weight: 600; color: var(--imp-text); }
.ims-field input { min-height: 48px; padding: 0 0.95rem; border-radius: 12px; border: 1px solid var(--syhs-field-edge);
  background: rgba(11,10,7,0.6); color: var(--imp-text); font: inherit; font-size: 1rem; }
.ims-field input::placeholder { color: var(--imp-mute); opacity: 1; }
.ims-field input:focus-visible { border-color: var(--imp-gold-hi); }
.ims-field input[aria-invalid="true"] { border-color: var(--ims-err); }
.ims-field__err { margin: 0; min-height: 0; font-size: 0.86rem; color: var(--ims-err); }
.ims-field__err:empty { display: none; }
.ims-field__err:not(:empty)::before { content: "! "; font-weight: 800; }
.ims-submit { width: 100%; justify-content: center; cursor: pointer; font: inherit; font-weight: 700; }
.ims-submit[disabled] { opacity: 0.6; cursor: progress; }
.ims-note { margin: 1rem 0 0; font-size: 0.92rem; color: var(--imp-soft); }
.ims-alert { margin: 0 0 1rem; padding: 0.85rem 1rem; border-radius: 12px; border: 1px solid rgba(255,138,128,0.5);
  background: rgba(255,138,128,0.08); color: var(--imp-text); font-size: 0.95rem; line-height: 1.5; }
.ims-alert.is-ok { border-color: rgba(102,211,161,0.5); background: rgba(102,211,161,0.08); }
.ims-linkbtn { padding: 0.6rem 0; min-height: 44px; border: 0; background: none; color: var(--imp-gold-hi); font: inherit; font-size: 0.92rem; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

/* ---- Fault ----------------------------------------------------------------- */
.ims-fault { position: relative; padding-block: clamp(3rem, 9vw, 6rem); }
.ims-fault__thread { display: block; width: min(100%, 26rem); height: 48px; margin-bottom: 1.5rem; opacity: 0.55; }
/* A broken strand: the gap says "disconnected" without an icon. */
.ims-fault__thread { -webkit-mask: linear-gradient(90deg, #000 42%, transparent 42% 58%, #000 58%); mask: linear-gradient(90deg, #000 42%, transparent 42% 58%, #000 58%); }

/* ---- Hero ----------------------------------------------------------------- */
.ims-hero { position: relative; padding-block: clamp(2.5rem, 7vw, 5rem) clamp(2rem, 5vw, 3.5rem); overflow: hidden; isolation: isolate; }
.ims-hero__grid { display: grid; gap: 1.5rem; align-items: end; }
@media (min-width: 900px) { .ims-hero__grid { grid-template-columns: minmax(0, 1fr) auto; } }
.ims-title { margin: 0 0 1.1rem; font-size: clamp(2.4rem, 1.3rem + 5.2vw, 5.4rem); font-weight: 800; line-height: 0.98; letter-spacing: -0.04em; text-wrap: balance; max-width: 15ch; }
[dir="rtl"] .ims-title { line-height: 1.2; letter-spacing: 0; }
.ims-message { max-width: 60ch; margin: 0 0 1rem; font-size: clamp(1.05rem, 1rem + 0.3vw, 1.2rem); line-height: 1.65; color: var(--imp-soft); }
.ims-meta { margin: 0; font-size: 0.9rem; color: var(--imp-mute); font-variant-numeric: tabular-nums; }
.ims-meta strong { color: var(--imp-text); font-weight: 600; }
/* The stamp: a single oversized mark for the verdict, decorative. */
.ims-stamp { margin: 0; font-family: var(--font-serif); font-style: italic; font-size: clamp(4rem, 2rem + 8vw, 9rem); line-height: 0.8;
  color: transparent; -webkit-text-stroke: 1px rgba(204,158,0,0.55); pointer-events: none; user-select: none; }
@media (max-width: 899px) { .ims-stamp { display: none; } }
.ims[data-view="winner"] .ims-stamp, .ims[data-view="finalist"] .ims-stamp { -webkit-text-stroke-color: var(--imp-gold); }

/* State accents: the kicker carries the state in words AND colour. */
.ims[data-view="finalist"] #ims-kicker, .ims[data-view="post_finalist"] #ims-kicker, .ims[data-view="winner"] #ims-kicker { color: var(--imp-gold-hi); }
.ims[data-view="not_shortlisted"] #ims-kicker, .ims[data-view="post_review"] #ims-kicker { color: var(--imp-soft); }

/* ---- Thread + steps ------------------------------------------------------ */
.ims-thread { position: relative; margin-top: clamp(2rem, 5vw, 3rem); --ims-progress: 0; }
.ims-thread__h, .ims-thread__v { position: absolute; pointer-events: none; }
.ims-thread__h { left: 0; right: 0; top: 0; width: 100%; height: 44px; }
.ims-thread__v { display: none; }
/* Draw only to where this applicant has got. --ims-progress is 0..1. */
.ims-thread__h { clip-path: inset(0 calc((1 - var(--ims-progress)) * 100%) 0 0); transition: clip-path 1.6s var(--ease-draw, ease); }
.ims-thread::before { content: ""; position: absolute; left: 0; right: 0; top: 21px; border-top: 1px dashed rgba(244,241,232,0.16); }
[dir="rtl"] .ims-thread__h { transform: scaleX(-1); }
.ims-steps { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin: 0; padding: 0; list-style: none; }
.ims-step { padding-top: 58px; position: relative; }
.ims-step::before { content: ""; position: absolute; top: 12px; inset-inline-start: 0; width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid rgba(244,241,232,0.3); background: var(--imp-ground); transition: background 300ms, border-color 300ms, box-shadow 300ms; }
.ims-step.is-done::before { border-color: var(--imp-gold); background: var(--imp-gold); }
.ims-step.is-now::before { border-color: var(--imp-gold-hi); background: var(--imp-gold-hi); box-shadow: 0 0 0 6px rgba(204,158,0,0.18), 0 0 24px rgba(230,188,46,0.45); }
.ims-step.is-muted::before { border-style: dashed; }
.ims-step.is-ended::before { border-color: var(--imp-soft); background: transparent; }
.ims-step__k { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--imp-mute); }
.ims-step__v { display: block; margin-top: 0.3rem; font-weight: 700; color: var(--imp-text); }
.ims-step__d { display: block; margin-top: 0.15rem; font-size: 0.85rem; color: var(--imp-mute); font-variant-numeric: tabular-nums; }
.ims-step.is-now .ims-step__v { color: var(--imp-gold-hi); }
.ims-step.is-future .ims-step__v { color: var(--imp-soft); font-weight: 500; }

@media (max-width: 719px) {
  /* Phones: the strand stands up and becomes a rail beside the steps. */
  .ims-thread { padding-inline-start: 44px; }
  .ims-thread::before { top: 0; bottom: 0; left: auto; right: auto; inset-inline-start: 21px; border-top: 0; border-inline-start: 1px dashed rgba(244,241,232,0.16); }
  .ims-thread__h { display: none; }
  .ims-thread__v { display: block; top: 0; bottom: 0; inset-inline-start: 2px; width: 40px; height: 100%;
    clip-path: inset(0 0 calc((1 - var(--ims-progress)) * 100%) 0); transition: clip-path 1.6s var(--ease-draw, ease); }
  .ims-steps { grid-template-columns: 1fr; gap: 1.4rem; }
  .ims-step { padding-top: 0; min-height: 44px; }
  .ims-step::before { top: 2px; inset-inline-start: -33px; }
}

/* ---- Representatives -------------------------------------------------------- */
.ims-team__grid { display: grid; gap: clamp(1.75rem, 4vw, 3rem); }
@media (min-width: 980px) { .ims-team__grid { grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); align-items: start; }
  .ims-team__intro { position: sticky; top: 5.5rem; } }
.ims-count { margin: 0 0 1.25rem; font-family: var(--font-serif); font-size: 1.35rem; color: var(--imp-text); }
.ims-count b { font-family: var(--font-sans); font-size: 2.6rem; font-weight: 800; color: var(--imp-gold); font-variant-numeric: tabular-nums; margin-inline-end: 0.2rem; }
.ims-wa { margin-top: 1.25rem; padding: 1.25rem; border-radius: var(--imp-r); border: 1px solid rgba(204,158,0,0.4); background: rgba(204,158,0,0.06); }
.ims-wa__k { margin: 0 0 0.3rem; font-weight: 700; }
.ims-wa__p { margin: 0 0 1rem; color: var(--imp-soft); line-height: 1.55; }

.ims-reps { display: grid; gap: 1rem; margin: 0 0 1.25rem; padding: 0; list-style: none; }
.ims-badge { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1rem; padding: 1.15rem 1.25rem;
  border-radius: var(--imp-r); border: 1px solid var(--imp-line); background: rgba(244,241,232,0.04); overflow: hidden;
  animation: ims-badge-in 420ms var(--ease-editorial, ease-out) both; }
/* the lanyard notch: a badge, not a card */
.ims-badge::before { content: ""; position: absolute; top: 0; inset-inline-start: 1.25rem; width: 44px; height: 4px; border-radius: 0 0 4px 4px; background: var(--imp-gold); }
.ims-badge--lead::before { background: var(--imp-gold-hi); width: 64px; }
.ims-badge.is-leaving { animation: ims-badge-out 220ms ease-in both; }
@keyframes ims-badge-in { from { opacity: 0; transform: translateY(10px); } }
@keyframes ims-badge-out { to { opacity: 0; transform: scale(0.97); } }
.ims-badge__k { margin: 0.35rem 0 0.25rem; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--imp-gold); }
.ims-badge__n { margin: 0; font-size: 1.2rem; font-weight: 700; overflow-wrap: anywhere; }
.ims-badge__r { margin: 0.15rem 0 0.6rem; color: var(--imp-soft); }
.ims-badge__c { margin: 0; display: grid; gap: 0.15rem; font-size: 0.88rem; color: var(--imp-mute); overflow-wrap: anywhere; }
.ims-badge__ref { margin: 0.6rem 0 0; font-weight: 700; letter-spacing: 0.06em; font-variant-numeric: tabular-nums; direction: ltr; unicode-bidi: isolate; }
.ims-badge__qr { width: 104px; height: 104px; padding: 6px; border-radius: 10px; background: #fff; align-self: start; }
.ims-badge__qr canvas, .ims-badge__qr img { display: block; width: 100% !important; height: 100% !important; }
.ims-badge__qr[hidden] { display: none; }
.ims-badge__acts { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 0.5rem; padding-top: 0.75rem; border-top: 1px solid var(--imp-line); }
.ims-chip { display: inline-flex; align-items: center; min-height: 44px; padding: 0 1rem; border-radius: 999px; border: 1px solid rgba(244,241,232,0.28);
  background: transparent; color: var(--imp-text) !important; font: inherit; font-size: 0.9rem; font-weight: 600; text-decoration: none; cursor: pointer; }
.ims-chip:hover { border-color: var(--imp-gold); }
.ims-chip--danger { border-color: rgba(255,138,128,0.45); color: var(--ims-err) !important; }
.ims-chip--danger:hover { border-color: var(--ims-err); }
.ims-chip--confirm { background: var(--ims-err); border-color: transparent; color: #1a0d0b !important; }
.ims-chip[disabled] { opacity: 0.55; cursor: progress; }
@media (max-width: 479px) {
  /* Phones: the QR stays beside the name (a badge reads name + code at a
     glance) but shrinks; actions become full-width thumb targets. */
  .ims-badge { gap: 0.75rem; padding: 1rem; }
  .ims-badge__qr { width: 76px; height: 76px; padding: 4px; margin-top: 0.35rem; }
  .ims-badge__n { font-size: 1.08rem; }
  .ims-badge__acts .ims-chip { flex: 1 1 auto; justify-content: center; }
}

.ims-addrep { padding: clamp(1.15rem, 3vw, 1.6rem); border-radius: var(--imp-r); border: 1px dashed rgba(204,158,0,0.45); }
.ims-addrep__h { margin: 0 0 1rem; font-size: 1.1rem; }
.ims-addrep__grid { display: grid; gap: 0 1rem; }
@media (min-width: 620px) { .ims-addrep__grid { grid-template-columns: 1fr 1fr; } }
.ims-full { margin: 0; padding: 1rem 1.15rem; border-radius: 14px; border: 1px solid var(--imp-line); color: var(--imp-soft); }

/* ---- Workshops: square cards ----------------------------------------------- */
.ims-ws__head { display: grid; gap: 0.5rem 2rem; margin-bottom: clamp(1.5rem, 4vw, 2.25rem); }
@media (min-width: 860px) { .ims-ws__head { grid-template-columns: 1fr minmax(0, 22rem); align-items: end; } }
.ims-ws__note { margin: 0; color: var(--imp-mute); font-size: 0.92rem; line-height: 1.55; }
.ims-ws__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(0.75rem, 2.4vw, 1.4rem); margin: 0; padding: 0; list-style: none; }
@media (min-width: 760px) { .ims-ws__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1120px) { .ims-ws__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.ims-wsc { display: flex; flex-direction: column; min-width: 0; }
.ims-wsc__sq { position: relative; aspect-ratio: 1 / 1; border-radius: var(--imp-r); overflow: hidden; border: 1px solid var(--imp-line); background: #15130d; }
.ims-wsc__sq img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(0.35) contrast(1.05); transition: filter 300ms; }
.ims-wsc:hover .ims-wsc__sq img { filter: none; }
.ims-wsc__sq::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(11,10,7,0.88)); }
/* Designed placeholder: initials over the strand, never a grey box. */
.ims-wsc__ph { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--font-serif); font-style: italic;
  font-size: clamp(2.2rem, 7vw, 3.6rem); color: var(--imp-gold); }
.ims-wsc__ph svg { position: absolute; inset: 35% -10% auto; width: 120%; height: 30%; opacity: 0.6; }
.ims-wsc__when { position: absolute; z-index: 1; inset-inline: 0.75rem; bottom: 0.7rem; margin: 0; display: grid; gap: 0.05rem; }
.ims-wsc__day { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--imp-gold-hi); }
.ims-wsc__time { font-size: clamp(1rem, 0.9rem + 0.6vw, 1.35rem); font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.ims-wsc__live { position: absolute; z-index: 1; top: 0.7rem; inset-inline-start: 0.7rem; padding: 0.25rem 0.6rem; border-radius: 999px;
  background: var(--ims-mint); color: #0b0a07; font-size: 0.72rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; }
.ims-wsc__t { margin: 0.8rem 0 0.2rem; font-size: clamp(0.98rem, 0.92rem + 0.3vw, 1.1rem); font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; }
.ims-wsc__p { margin: 0 0 0.75rem; font-size: 0.88rem; color: var(--imp-soft); overflow-wrap: anywhere; }
.ims-wsc__go { margin-top: auto; width: 100%; justify-content: center; padding-inline: 0.8rem; text-align: center; font-size: 0.92rem; }
.ims-wsc__go[aria-disabled="true"] { background: transparent; border: 1px dashed rgba(244,241,232,0.36); color: var(--imp-soft) !important; cursor: not-allowed; }
.ims-wsc__cd { margin: 0.45rem 0 0; min-height: 1.3em; font-size: 0.82rem; color: var(--imp-mute); font-variant-numeric: tabular-nums; text-align: center; }
.ims-wsc.is-open .ims-wsc__sq { border-color: var(--ims-mint); box-shadow: 0 0 0 1px var(--ims-mint); }
.ims-wsc.is-ended { opacity: 0.62; }
.ims-empty { margin: 0; padding: 1.25rem; border-radius: 14px; border: 1px dashed var(--imp-line); color: var(--imp-soft); }
@media (max-width: 479px) {
  .ims-wsc__go { min-height: 44px; font-size: 0.85rem; padding-inline: 0.5rem; }
}

/* ---- Documents ------------------------------------------------------------- */
.ims-docs__grid { display: grid; gap: 1.5rem; }
@media (min-width: 860px) { .ims-docs__grid { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); } }
.ims-docs__note { margin: 0 0 1rem; color: var(--imp-soft); line-height: 1.55; }
.ims-refresh { cursor: pointer; font: inherit; font-weight: 700; }
.ims-doclist { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--imp-line); }
.ims-doc { display: grid; grid-template-columns: 2.6rem minmax(0, 1fr) auto; gap: 0.9rem; align-items: center; padding: 0.95rem 0; border-bottom: 1px solid var(--imp-line); }
.ims-doc__ix { font-family: var(--font-serif); font-style: italic; font-size: 1.4rem; color: var(--imp-gold); text-align: center; }
.ims-doc__k { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--imp-mute); }
.ims-doc__n { display: block; margin-top: 0.15rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; direction: ltr; unicode-bidi: plaintext; text-align: start; }
.ims-doc .ims-chip { white-space: nowrap; }
.ims-doc .ims-chip[aria-disabled="true"] { border-style: dashed; color: var(--imp-mute) !important; cursor: not-allowed; }

/* ---- Closing --------------------------------------------------------------- */
.ims-close { position: relative; padding-block: clamp(4rem, 12vw, 8rem); border-top: 1px solid var(--imp-line); overflow: hidden; text-align: center; isolation: isolate; }
.ims-close__thread { position: absolute; z-index: -1; left: -5%; top: 50%; width: 110%; height: 120px; transform: translateY(-50%); opacity: 0.5; }
[dir="rtl"] .ims-close__thread { transform: translateY(-50%) scaleX(-1); }
.ims-close__title { margin: 0 auto; max-width: 14ch; font-size: clamp(2.6rem, 1.4rem + 6vw, 6.4rem); font-weight: 800; line-height: 0.98; letter-spacing: -0.04em; text-wrap: balance; }
[dir="rtl"] .ims-close__title { line-height: 1.25; letter-spacing: 0; }
.ims-signout { padding-block: 1.5rem 3rem; }

/* ---- Motion: the hero's entrance is its own choreography, not a reveal copy */
@media (prefers-reduced-motion: no-preference) {
  .ims-hero.is-in .ims-title { animation: ims-rise 700ms var(--ease-editorial, ease-out) both; }
  .ims-hero.is-in .ims-message { animation: ims-rise 700ms 120ms var(--ease-editorial, ease-out) both; }
  .ims-hero.is-in .ims-stamp { animation: ims-stamp 900ms 200ms cubic-bezier(0.34, 1.4, 0.64, 1) both; }
  .ims-close.is-in .ims-close__thread { animation: ims-unspool 2.4s var(--ease-draw, ease) both; }
}
@keyframes ims-rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes ims-stamp { from { opacity: 0; transform: rotate(-8deg) scale(1.15); } }
@keyframes ims-unspool { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@media (prefers-reduced-motion: reduce) {
  .ims-thread__h, .ims-thread__v { transition: none; }
  .ims-badge, .ims-badge.is-leaving { animation: none; }
  .ims-skel { animation: none; }
}
