@font-face {
  font-family: "Sora";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/fonts/sora-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074,
    U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Sora";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/fonts/sora-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Plex";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/fonts/plex-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074,
    U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Plex";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/fonts/plex-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --ink: #0f1c16;
  --ink-soft: #40514a;
  --ink-faint: #78877f;
  --paper: #f6f7f4;
  --white: #fff;
  --cyan: #25aadd;
  --cyan-deep: #1483ad;
  --teal: #57b4b1;
  --ice: #eafefe;
  --line: #e3e6e0;
  --line-strong: #cbd2cc;
  --danger: #b3261e;
  --danger-bg: #fdeceb;
  --warn: #9a6300;
  --warn-bg: #fff6e5;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(15, 28, 22, 0.04), 0 8px 24px -12px rgba(15, 28, 22, 0.14);
  --font-display: "Sora", ui-sans-serif, system-ui, sans-serif;
  --font-sans: "Plex", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
}

.wrap { max-width: 680px; margin: 0 auto; padding: 32px 20px 96px; }

/* ---------- header ---------- */
.eyebrow {
  font-family: var(--font-display);
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--cyan-deep);
  margin-bottom: 10px;
}
h1 {
  font-family: var(--font-display);
  font-size: clamp(26px, 5.5vw, 34px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 10px;
  font-weight: 700;
}
.lede { color: var(--ink-soft); font-size: 16.5px; margin: 0; }
header.page { margin-bottom: 24px; }

/* ---------- deadline banner ---------- */
.deadline {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: linear-gradient(180deg, var(--ice), #fff);
  border: 1px solid #bfe8f5;
  border-left: 4px solid var(--cyan);
  border-radius: var(--radius);
  padding: 14px 18px;
  margin-bottom: 22px;
}
.deadline.is-urgent { background: linear-gradient(180deg, var(--warn-bg), #fff); border-color: #f0d9a8; border-left-color: #d99400; }
.deadline.is-past { background: linear-gradient(180deg, var(--danger-bg), #fff); border-color: #f3c2be; border-left-color: var(--danger); }
.deadline-count {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
  color: var(--cyan-deep);
}
.deadline.is-urgent .deadline-count { color: #8a5f00; }
.deadline.is-past .deadline-count { color: var(--danger); }
.deadline p { margin: 0; font-size: 14.5px; color: var(--ink-soft); }
.deadline strong { color: var(--ink); }

/* ---------- explainer ---------- */
.explainer {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
}
.explainer h2 {
  font-family: var(--font-display);
  font-size: 17px;
  margin: 0 0 10px;
  letter-spacing: -0.01em;
}
.explainer p { margin: 0 0 12px; font-size: 15px; color: var(--ink-soft); }
.explainer p:last-child { margin-bottom: 0; }
.explainer strong { color: var(--ink); font-weight: 600; }
.points { list-style: none; margin: 14px 0; padding: 0; display: grid; gap: 10px; }
.points li {
  position: relative;
  padding-left: 30px;
  font-size: 15px;
  color: var(--ink-soft);
}
.points li::before {
  content: "";
  position: absolute;
  left: 0; top: 6px;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--ice);
  border: 1px solid #bfe8f5;
}
.points li.no::before { background: var(--danger-bg); border-color: #f3c2be; }
.points li.no::after {
  content: "";
  position: absolute;
  left: 5.5px; top: 14px;
  width: 7px; height: 1.5px;
  background: var(--danger);
}
.points li.yes::after {
  content: "";
  position: absolute;
  left: 6px; top: 10.5px;
  width: 4px; height: 7.5px;
  border: solid var(--cyan-deep);
  border-width: 0 1.8px 1.8px 0;
  transform: rotate(42deg);
}
.kicker {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  border-top: 1px solid var(--line);
  padding-top: 14px;
  margin-top: 4px;
}

/* ---------- privacy disclosure ---------- */
.notice {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 24px;
  overflow: hidden;
}
.notice > summary {
  cursor: pointer;
  list-style: none;
  padding: 16px 20px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.notice > summary::-webkit-details-marker { display: none; }
.notice > summary::before {
  content: "";
  width: 7px; height: 7px;
  border: solid var(--cyan-deep);
  border-width: 0 2px 2px 0;
  transform: rotate(-45deg);
  transition: transform 0.18s ease;
  flex-shrink: 0;
  margin-left: 2px;
}
.notice[open] > summary::before { transform: rotate(45deg); }
.notice > summary:hover { background: #fbfcfb; }
.notice-body { padding: 0 20px 20px; font-size: 14.5px; color: var(--ink-soft); }
.notice-body h3 {
  font-family: var(--font-display);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink);
  margin: 18px 0 6px;
}
.notice-body h3:first-child { margin-top: 0; }
.notice-body p { margin: 0 0 10px; }
.notice-body ul { margin: 6px 0 10px; padding-left: 20px; }
.notice-body li { margin: 3px 0; }

/* ---------- form ---------- */
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px 6px;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
}
.card > h2 {
  font-family: var(--font-display);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cyan-deep);
  margin: 0 0 18px;
  font-weight: 600;
}
.section-hint { margin: -10px 0 18px; }
.field { margin-bottom: 20px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

label { display: block; font-weight: 600; font-size: 14.5px; margin-bottom: 5px; }
.required::after { content: " *"; color: var(--danger); font-weight: 400; }
.hint { font-size: 13px; color: var(--ink-faint); margin: -1px 0 8px; }

input[type="text"], input[type="date"], input[type="tel"], input[type="email"], select, textarea {
  width: 100%;
  font: inherit;
  font-size: 16px; /* below 16px iOS Safari zooms the whole page on focus */
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  padding: 11px 13px;
  transition: border-color 0.15s, box-shadow 0.15s;
  -webkit-appearance: none;
  appearance: none;
}
select {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2340514a' stroke-width='1.8' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  padding-right: 36px;
}
input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: none;
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(37, 170, 221, 0.18);
}
textarea { resize: vertical; min-height: 96px; line-height: 1.5; }

.field-error {
  display: none;
  font-size: 13px;
  color: var(--danger);
  margin-top: 6px;
  font-weight: 500;
}
/* Scoped to [data-field] rather than .field so the two halves of the phone
   control can be invalid — and show their message — independently. */
[data-field].invalid input,
[data-field].invalid select,
[data-field].invalid textarea { border-color: var(--danger); }

/* ---------- phone ---------- */
/* The dial-code selector needs real width to stay readable, so this row runs
   wider than the even 50/50 split the other paired fields use. */
.row2-phone { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }
.phone-group { display: grid; grid-template-columns: minmax(0, 168px) minmax(0, 1fr); gap: 10px; }
.phone-group select, .phone-group input { width: 100%; }
.phone-preview {
  font-size: 13px;
  color: var(--ink-faint);
  margin-top: 7px;
  min-height: 1.2em;
  font-variant-numeric: tabular-nums;
}
.phone-preview strong {
  color: var(--ink-soft);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-weight: 600;
  letter-spacing: 0.01em;
}
/* Below this the two-up row has already collapsed, so the phone control gets
   the full width back and the selector can breathe again. */
@media (max-width: 620px) {
  .phone-group { grid-template-columns: minmax(0, 180px) minmax(0, 1fr); }
}
@media (max-width: 380px) {
  .phone-group { grid-template-columns: 1fr; gap: 8px; }
}

/* ---------- passport page upload ---------- */
.doc-preview {
  width: 132px;
  aspect-ratio: 3 / 2;
  flex-shrink: 0;
  border-radius: 9px;
  border: 1px dashed var(--line-strong);
  background: #fafbfa center / cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 11.5px;
  color: var(--ink-faint);
  padding: 8px;
  overflow: hidden;
}
.doc-preview.has-image { border-style: solid; }
.doc-preview.is-pdf {
  border-style: solid;
  background: var(--ice);
  border-color: #bfe8f5;
  color: var(--cyan-deep);
  font-weight: 600;
  font-family: var(--font-display);
  font-size: 15px;
  letter-spacing: 0.04em;
  flex-direction: column;
  gap: 2px;
}
.doc-preview .doc-name {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 11.5px;
  letter-spacing: 0;
  color: var(--ink-faint);
}
.field-warn {
  display: none;
  font-size: 13px;
  color: var(--warn);
  background: var(--warn-bg);
  border-radius: 7px;
  padding: 8px 10px;
  margin-top: 8px;
}
.field-warn.show { display: block; }
.counter { font-size: 12.5px; color: var(--ink-faint); text-align: right; margin-top: 5px; }
.counter.near { color: var(--warn); }

/* ---------- photo ---------- */
.photo-row { display: flex; gap: 18px; align-items: flex-start; }
.photo-preview {
  width: 108px;
  aspect-ratio: 4 / 5;
  flex-shrink: 0;
  border-radius: 9px;
  border: 1px dashed var(--line-strong);
  background: #fafbfa center / cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 11.5px;
  color: var(--ink-faint);
  padding: 8px;
  overflow: hidden;
}
.photo-preview.has-image { border-style: solid; border-color: var(--line-strong); }
.photo-controls { flex: 1; min-width: 0; }
input[type="file"] {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.file-btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 14px;
  background: var(--white);
  border: 1px solid var(--cyan);
  color: var(--cyan-deep);
  padding: 9px 16px;
  border-radius: 9px;
  cursor: pointer;
  margin-bottom: 0;
}
.file-btn:hover { background: var(--ice); }
input[type="file"]:focus-visible + .file-btn { box-shadow: 0 0 0 3px rgba(37, 170, 221, 0.18); }
.photo-meta { font-size: 12.5px; color: var(--ink-faint); margin-top: 8px; }
.photo-meta.ok { color: var(--teal); font-weight: 500; }

/* ---------- consent ---------- */
.consent {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow: var(--shadow);
}
.consent input[type="checkbox"] {
  margin: 3px 0 0;
  width: 19px; height: 19px;
  accent-color: var(--cyan-deep);
  flex-shrink: 0;
}
.consent label { font-weight: 400; font-size: 14.5px; margin: 0; color: var(--ink-soft); }
.consent a { color: var(--cyan-deep); }
#consentError { margin: 8px 0 0; }

/* ---------- submit ---------- */
.submit-row { margin-top: 22px; }
button.primary {
  width: 100%;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  color: var(--white);
  background: var(--ink);
  border: none;
  border-radius: 10px;
  padding: 16px;
  cursor: pointer;
  transition: background 0.15s, opacity 0.15s;
}
button.primary:hover:not(:disabled) { background: #1b3227; }
button.primary:focus-visible { outline: 3px solid rgba(37, 170, 221, 0.5); outline-offset: 2px; }
button.primary:disabled { background: var(--line-strong); cursor: not-allowed; }
.submit-help { text-align: center; font-size: 13px; color: var(--ink-faint); margin-top: 10px; }

.progress { height: 4px; background: var(--line); border-radius: 99px; overflow: hidden; margin-top: 12px; display: none; }
.progress.show { display: block; }
.progress-bar { height: 100%; width: 0; background: var(--cyan); transition: width 0.2s ease; }

#formError {
  display: none;
  background: var(--danger-bg);
  border: 1px solid #f3c2be;
  border-left: 3px solid var(--danger);
  color: #8c1d17;
  padding: 13px 16px;
  border-radius: 10px;
  font-size: 14.5px;
  margin-bottom: 18px;
}
#formError.show { display: block; }

/* ---------- success ---------- */
.success { display: none; }
.success.show { display: block; }
.success-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 36px 28px;
  text-align: center;
  box-shadow: var(--shadow);
}
.tick {
  width: 52px; height: 52px;
  border-radius: 50%;
  background: var(--ice);
  border: 1px solid #bfe8f5;
  margin: 0 auto 18px;
  position: relative;
}
.tick::after {
  content: "";
  position: absolute;
  left: 20px; top: 14px;
  width: 9px; height: 18px;
  border: solid var(--cyan-deep);
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(42deg);
}
.success-card h2 { font-family: var(--font-display); font-size: 23px; margin: 0 0 10px; letter-spacing: -0.01em; }
.success-card p { color: var(--ink-soft); font-size: 15px; margin: 0 0 14px; }
.reference {
  display: inline-block;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.04em;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  padding: 10px 18px;
  margin: 4px 0 18px;
}
.next-steps {
  text-align: left;
  background: var(--paper);
  border-radius: 10px;
  padding: 18px 20px;
  margin-top: 8px;
}
.next-steps h3 { font-family: var(--font-display); font-size: 13px; text-transform: uppercase; letter-spacing: 0.08em; margin: 0 0 10px; }
.next-steps ul { margin: 0; padding-left: 20px; font-size: 14.5px; color: var(--ink-soft); }
.next-steps li { margin: 6px 0; }

/* ---------- footer ---------- */
footer.page {
  margin-top: 32px;
  text-align: center;
  font-size: 12.5px;
  color: var(--ink-faint);
  line-height: 1.7;
}
footer.page a { color: var(--ink-faint); }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

@media (max-width: 520px) {
  .row2 { grid-template-columns: 1fr; gap: 0; }
  .wrap { padding: 24px 16px 72px; }
  .card { padding: 18px 18px 4px; }
  .explainer { padding: 18px; }
  .deadline { flex-direction: column; gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
