/* Waves Careers — public site */
:root {
  --brand: #662D91;
  --accent: #3B86CF;
  --ink: #221a2e;
  --ink-2: #4a4058;
  --muted: #7a7088;
  --line: #e9e4f0;
  --bg: #faf8fc;
  --surface: #ffffff;
  --tint: color-mix(in srgb, var(--brand) 7%, #fff);
  --tint-2: color-mix(in srgb, var(--brand) 14%, #fff);
  --danger: #c0392b;
  --ok: #1e8e5a;
  --warn: #b7791f;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(34, 26, 46, .04), 0 8px 24px -12px rgba(34, 26, 46, .12);
  --grad: linear-gradient(120deg, var(--accent) 0%, var(--brand) 55%);
  --font: "Readex Pro", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.3; margin: 0 0 .5em; font-weight: 600; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 55%, transparent); outline-offset: 2px; border-radius: 6px; }

.container { width: 100%; max-width: 1160px; margin-inline: auto; padding-inline: 20px; }
.narrow { max-width: 820px; }
.main { padding-block: 48px 72px; }
.muted { color: var(--muted); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font: inherit; font-weight: 500; font-size: 15px;
  padding: 11px 22px; border-radius: 999px; border: 1.5px solid transparent;
  cursor: pointer; text-decoration: none !important; white-space: nowrap;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, color .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: color-mix(in srgb, var(--brand) 88%, #000); box-shadow: 0 6px 18px -8px var(--brand); }
.btn-light { background: #fff; color: var(--brand); }
.btn-light:hover { box-shadow: 0 8px 24px -10px rgba(0,0,0,.35); }
.btn-outline-light { border-color: rgba(255,255,255,.6); color: #fff; }
.btn-outline-light:hover { background: rgba(255,255,255,.12); }
.btn-ghost { background: transparent; color: var(--ink-2); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn-sm { padding: 7px 16px; font-size: 14px; }
.btn.block { display: flex; width: 100%; }
.btn[disabled] { opacity: .6; cursor: not-allowed; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.92); backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 68px; }
.brand img { height: 40px; width: auto; }
.header-nav { display: flex; align-items: center; gap: 22px; font-size: 15px; }
.header-nav a:not(.btn) { color: var(--ink-2); }
.header-nav a:not(.btn):hover { color: var(--brand); text-decoration: none; }
.lang-btn { font-weight: 500; }

/* Hero */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background: var(--grad);
  padding: 88px 0 132px;
}
.hero-inner { position: relative; z-index: 2; max-width: 760px; }
.hero h1 { font-size: clamp(32px, 5vw, 54px); font-weight: 700; margin-bottom: .35em; }
.hero .lead { font-size: clamp(16px, 1.6vw, 19px); opacity: .92; max-width: 620px; }
.eyebrow {
  display: inline-block; font-size: 13px; font-weight: 500; letter-spacing: .02em;
  padding: 4px 12px; border-radius: 999px; margin-bottom: 18px;
  background: rgba(255,255,255,.16); color: inherit;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-waves { position: absolute; inset: auto 0 0 0; height: 160px; z-index: 1; }
.hero-waves svg { position: absolute; inset: auto 0 0 0; width: 100%; height: 100%; }
.hero-waves svg:first-child path { fill: rgba(255,255,255,.10); }
.hero-waves svg:last-child path { fill: var(--bg); }

/* Jobs list */
.jobs-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.jobs-head h2 { font-size: 28px; margin: 0; }
.job-search input {
  font: inherit; width: 300px; max-width: 100%;
  padding: 10px 18px; border-radius: 999px; border: 1.5px solid var(--line); background: #fff;
}
.job-search input:focus { border-color: var(--brand); outline: none; }

.dept-filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 26px; }
@media (max-width: 640px) {
  .dept-filter { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; margin-inline: -16px; padding-inline: 16px; }
}
.pill {
  flex: 0 0 auto; padding: 7px 16px; border-radius: 999px; font-size: 14px;
  background: #fff; border: 1px solid var(--line); color: var(--ink-2);
}
.pill:hover { border-color: var(--brand); color: var(--brand); text-decoration: none; }
.pill.active { background: var(--brand); border-color: var(--brand); color: #fff; }
.pill-count { display: inline-block; min-width: 20px; padding: 0 6px; margin-inline-start: 4px; border-radius: 999px; font-size: 12px; background: var(--tint-2); color: var(--brand); text-align: center; }
.pill.active .pill-count { background: rgba(255,255,255,.22); color: #fff; }

.job-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; }
.job-card {
  position: relative; display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.job-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--brand) 30%, var(--line)); }
.job-card.is-featured { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); }
.job-card-link { position: absolute; inset: 0; z-index: 1; }
.job-card .btn { position: relative; z-index: 2; }
.job-card-img { aspect-ratio: 1200 / 630; background: var(--tint); }
.job-card-img img { width: 100%; height: 100%; object-fit: cover; }
.job-card-body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.job-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.job-card h3 { font-size: 20px; margin-bottom: 6px; }
.job-summary { color: var(--ink-2); font-size: 15px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.job-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 16px; }
.deadline-note { font-size: 13px; color: var(--warn); font-weight: 500; }

.dept-tag { display: inline-block; font-size: 13px; font-weight: 500; color: var(--brand); background: var(--tint); padding: 3px 10px; border-radius: 6px; }
.dept-tag.light { background: rgba(255,255,255,.16); color: #fff; margin-bottom: 12px; }
.badge-featured { font-size: 12px; font-weight: 600; color: #fff; background: var(--grad); padding: 3px 10px; border-radius: 999px; }

.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.chip { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; color: var(--ink-2); background: var(--bg); border: 1px solid var(--line); padding: 3px 10px; border-radius: 999px; }
.chip svg { width: 14px; height: 14px; color: var(--muted); }

.empty { text-align: center; padding: 56px 24px; background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); }
.empty-icon { width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 18px; display: grid; place-items: center; background: var(--tint); color: var(--brand); font-size: 28px; }
.empty h3 { font-size: 20px; }
.empty p { color: var(--muted); }

.general-cta {
  margin-top: 56px; padding: 36px 40px; border-radius: 20px; color: #fff;
  background: var(--grad); display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  position: relative; overflow: hidden;
}
.general-cta::after {
  content: ""; position: absolute; inset-inline-end: -60px; top: -60px; width: 220px; height: 220px; border-radius: 50%;
  border: 36px solid rgba(255,255,255,.08); pointer-events: none;
}
.general-cta h2 { font-size: 24px; margin-bottom: 6px; }
.general-cta p { margin: 0; opacity: .9; max-width: 560px; }
.general-cta .btn { position: relative; z-index: 1; }

/* Job page */
.job-hero, .page-head { background: var(--grad); color: #fff; padding: 48px 0 56px; }
.job-hero h1, .page-head h1 { font-size: clamp(28px, 4vw, 42px); margin-bottom: .3em; }
.job-hero .lead, .page-head .lead { opacity: .9; margin: 0; font-size: 17px; }
.page-head .eyebrow { margin-bottom: 10px; }
.back-link { display: inline-block; color: rgba(255,255,255,.85); font-size: 14px; margin-bottom: 18px; }
.back-link:hover { color: #fff; }
.job-hero .back-link { display: block; width: fit-content; }

.job-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; align-items: start; }
.job-content { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; }
.job-content h2 { font-size: 21px; margin-top: 1.4em; }
.job-content h2:first-of-type { margin-top: 0; }
.job-banner { margin: -32px -32px 28px; }
.job-banner img { width: 100%; border-radius: var(--radius) var(--radius) 0 0; }
.prose p, .prose li { color: var(--ink-2); }
.prose ul { padding-inline-start: 1.3em; margin: 0 0 1em; }
.prose li { margin-bottom: .35em; }
.prose li::marker { color: var(--brand); }

.job-aside { position: sticky; top: 92px; display: grid; gap: 16px; }
.aside-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.aside-card h3 { font-size: 16px; }
.facts { margin: 0 0 20px; display: grid; gap: 12px; }
.facts div { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.facts div:last-child { border-bottom: 0; padding-bottom: 0; }
.facts dt { color: var(--muted); font-size: 14px; }
.facts dd { margin: 0; font-weight: 500; text-align: end; }
.share-row { display: flex; flex-wrap: wrap; gap: 8px; }
.share-btn {
  font: inherit; font-size: 13px; padding: 6px 12px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--line); background: var(--bg); color: var(--ink-2);
}
.share-btn:hover { border-color: var(--brand); color: var(--brand); text-decoration: none; }
.sticky-apply { display: none; }

.notice { padding: 14px 18px; border-radius: var(--radius-sm); margin-bottom: 20px; font-size: 15px; }
.notice.warn { background: #fff7e6; color: #8a5a00; border: 1px solid #f5dfae; }
.notice.error { background: #fdeeee; color: var(--danger); border: 1px solid #f4cccc; }

/* Chooser */
.block-title { font-size: 20px; margin: 8px 0 14px; }
.choose-list { display: grid; gap: 10px; margin-bottom: 36px; }
.choose-item {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 16px 20px; color: var(--ink);
}
.choose-item:hover { border-color: var(--brand); text-decoration: none; box-shadow: var(--shadow); }
.choose-item strong { display: block; font-weight: 600; }
.choose-item small { color: var(--muted); }
.choose-item .arrow { color: var(--brand); font-size: 20px; }
.dept-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.dept-card {
  display: flex; flex-direction: column; gap: 2px; padding: 18px 20px; border-radius: var(--radius-sm);
  background: #fff; border: 1px solid var(--line); color: var(--ink); position: relative; overflow: hidden;
}
.dept-card::before { content: ""; position: absolute; inset-block: 0; inset-inline-start: 0; width: 4px; background: var(--grad); opacity: 0; transition: opacity .2s; }
.dept-card:hover { border-color: var(--brand); text-decoration: none; }
.dept-card:hover::before { opacity: 1; }
.dept-card strong { font-weight: 600; }
.dept-card small { color: var(--muted); font-size: 13px; }

/* Application form */
.apply-form { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 32px; box-shadow: var(--shadow); }
.apply-form { position: relative; }
.hp { position: absolute !important; inset: 0 auto auto 0; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); opacity: 0; pointer-events: none; }

.stepper { list-style: none; margin: 0 0 28px; padding: 0; display: flex; gap: 6px; counter-reset: s; }
.stepper li { flex: 1; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.stepper li::before { content: ""; display: block; height: 4px; border-radius: 4px; background: var(--line); transition: background .3s; }
.stepper li.done::before, .stepper li.current::before { background: var(--grad); }
.stepper .dot { display: none; }
.stepper .lbl { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stepper li.current .lbl { color: var(--brand); font-weight: 600; }

.step { border: 0; padding: 0; margin: 0; min-width: 0; }
.js .step { display: none; }
.js .step.active { display: block; animation: stepIn .3s ease; }
@keyframes stepIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.step legend { font-size: 22px; font-weight: 600; margin-bottom: 22px; padding: 0; width: 100%; }
.step-count { display: block; font-size: 13px; font-weight: 500; color: var(--brand); margin-bottom: 4px; }
.step-dept legend::after { content: ""; display: block; width: 48px; height: 3px; border-radius: 3px; background: var(--grad); margin-top: 10px; }

.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 22px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field-textarea, .field-multiselect, .field-file, .field-yesno { grid-column: 1 / -1; }
.field-label { font-weight: 500; font-size: 15px; color: var(--ink); }
.req { color: var(--danger); }
.opt { color: var(--muted); font-weight: 400; font-size: 13px; }
.field-help { font-size: 13px; color: var(--muted); margin: 0; }
.field input[type=text], .field input[type=email], .field input[type=tel], .field input[type=url],
.field input[type=number], .field input[type=date], .field select, .field textarea {
  font: inherit; font-size: 15px; width: 100%;
  padding: 11px 14px; border-radius: var(--radius-sm); border: 1.5px solid var(--line); background: #fff; color: var(--ink);
  transition: border-color .15s, box-shadow .15s;
}
.field textarea { resize: vertical; min-height: 110px; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 12%, transparent);
}
.field input[readonly] { background: var(--bg); color: var(--ink-2); }
[dir=rtl] .field input[dir=ltr] { text-align: right; }
[dir=rtl] .field input[dir=ltr]::placeholder { text-align: right; }
.field.has-error input, .field.has-error select, .field.has-error textarea, .field.has-error .file-drop, .field.has-error .choice span { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: 13px; margin: 0; }

.choice-row, .choice-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.choice { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice span {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 18px; border-radius: 999px;
  border: 1.5px solid var(--line); background: #fff; font-size: 15px; transition: all .15s; user-select: none;
}
.choice-row .choice span { min-width: 92px; justify-content: center; }
.choice input:checked + span { border-color: var(--brand); background: var(--tint); color: var(--brand); font-weight: 500; }
.choice input:focus-visible + span { box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 18%, transparent); }
.choice-grid .choice input[type=checkbox]:checked + span::before { content: "✓"; font-weight: 700; }

.file-drop {
  display: flex; align-items: center; gap: 12px; padding: 18px 20px; border-radius: var(--radius-sm);
  border: 1.5px dashed color-mix(in srgb, var(--brand) 35%, var(--line)); background: var(--tint);
  cursor: pointer; color: var(--brand); transition: background .15s, border-color .15s; position: relative;
}
.file-drop:hover, .file-drop.drag { background: var(--tint-2); border-color: var(--brand); }
.file-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.file-drop svg { font-size: 22px; flex: 0 0 auto; }
.file-name { font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-drop.has-file { border-style: solid; }

.consent { display: flex; gap: 10px; align-items: flex-start; margin-top: 28px; padding: 16px; border-radius: var(--radius-sm); background: var(--bg); font-size: 14px; color: var(--ink-2); cursor: pointer; }
.consent input { margin-top: 5px; accent-color: var(--brand); width: 18px; height: 18px; flex: 0 0 auto; }
.consent.has-error { outline: 1.5px solid var(--danger); }

.form-nav { display: flex; gap: 12px; justify-content: space-between; margin-top: 32px; padding-top: 22px; border-top: 1px solid var(--line); }
.form-nav [data-next], .form-nav [data-submit] { margin-inline-start: auto; min-width: 150px; }
.js .form-nav [data-submit] { display: none; }
.js .form-nav.last [data-submit] { display: inline-flex; }
.js .form-nav.last [data-next] { display: none; }
.form-nav.first [data-prev] { visibility: hidden; }
html:not(.js) .form-nav [data-prev], html:not(.js) .form-nav [data-next] { display: none; }

/* Success */
.success-card { text-align: center; background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: 56px 28px; box-shadow: var(--shadow); }
.success-icon { width: 76px; height: 76px; margin: 0 auto 22px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--grad); font-size: 36px; }
.success-icon svg { stroke-width: 2.6; }
.success-card h1 { font-size: 28px; }
.success-card p { color: var(--ink-2); max-width: 520px; margin-inline: auto; }
.ref { font-size: 17px; margin: 22px auto 28px !important; padding: 12px 20px; background: var(--tint); border-radius: 10px; display: inline-block; }
.ref strong { color: var(--brand); letter-spacing: .04em; }

/* Footer */
.site-footer { background: #1d1428; color: rgba(255,255,255,.75); padding: 40px 0; font-size: 14px; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer-logo { height: 34px; width: auto; opacity: .95; }
.footer-links { display: flex; flex-wrap: wrap; gap: 18px; }
.footer-links a { color: rgba(255,255,255,.8); }
.footer-copy { margin: 0; width: 100%; color: rgba(255,255,255,.5); font-size: 13px; }

/* Responsive */
@media (max-width: 900px) {
  .job-layout { grid-template-columns: 1fr; }
  .job-aside { position: static; }
  .sticky-apply { display: block; position: sticky; bottom: 0; z-index: 40; padding: 12px 20px; background: rgba(255,255,255,.95); border-top: 1px solid var(--line); backdrop-filter: blur(8px); }
}
@media (max-width: 640px) {
  .container { padding-inline: 16px; }
  .header-inner { height: 60px; }
  .brand img { height: 32px; }
  .header-nav { gap: 14px; font-size: 14px; }
  .header-nav a:first-child { display: none; }
  .hero { padding: 56px 0 104px; }
  .main { padding-block: 32px 56px; }
  .job-grid { grid-template-columns: 1fr; }
  .job-search, .job-search input { width: 100%; }
  .apply-form { padding: 22px 18px; border-radius: 14px; }
  .fields { grid-template-columns: 1fr; }
  .stepper .lbl { display: none; }
  .stepper li.current .lbl { display: block; position: absolute; }
  .stepper { position: relative; padding-bottom: 22px; }
  .stepper li.current .lbl { inset-inline-start: 0; bottom: 0; }
  .job-content { padding: 22px; }
  .job-banner { margin: -22px -22px 22px; }
  .general-cta { padding: 28px 24px; }
  .form-nav .btn { min-width: 0; flex: 1; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
