/* Job application: extends ../styles.css and ../forms/forms.css */
:root { --navy: #1F2A6B }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --navy: #3B4BB0 } }

.as-btn { background: none; border: 0; padding: 0; cursor: pointer; font: inherit }
.step-count { font-size: 15px; color: var(--label2); font-variant-numeric: tabular-nums; min-width: 40px; text-align: right }
.nav .nav-title { opacity: 1 }
.progress { max-width: 680px; margin: 8px auto 0; height: 3px; border-radius: 2px; background: var(--fill); overflow: hidden }
.progress span { display: block; height: 100%; width: 0; background: var(--blue); border-radius: 2px; transition: width .3s ease }

.step { display: flex; flex-direction: column; gap: 24px }
.step .hero h1 { font-size: 30px }
.opt { font-weight: 400; color: var(--label3); text-transform: none; letter-spacing: 0; margin-left: 4px }
.flabel .opt { color: var(--label3) }

/* Welcome */
.welcome { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 28px 8px 4px }
.logo { width: 72px; height: 72px; border-radius: 18px; background: var(--navy); color: #fff; display: grid; place-items: center;
  font: 600 24px/1 Georgia, "Times New Roman", serif; letter-spacing: .02em; margin-bottom: 10px; box-shadow: 0 6px 18px rgba(31, 42, 107, .25) }
.welcome h1 { font: 700 32px/1.15 var(--font-display); margin: 0 }
.lede { margin: 6px 0 0; color: var(--label2); font-size: 17px; max-width: 26em }
.welcome + .group .row-label { font-size: 15px; color: var(--label2); line-height: 1.4 }

/* Role cards */
.role-cards { display: flex; flex-direction: column }
.role { position: relative; display: flex; align-items: center; gap: 14px; width: 100%; border: 0; background: var(--card); padding: 14px 16px; text-align: left; cursor: pointer; min-height: 64px }
.role + .role::before { content: ""; position: absolute; top: 0; left: 54px; right: 0; border-top: .5px solid var(--sep) }
.role b { display: block; font-weight: 600; font-size: 17px }
.role small { display: block; color: var(--label2); font-size: 14px; margin-top: 1px }
.role .box, .doc .box { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--label3); display: grid; place-items: center }
.role[aria-checked="true"] .box { background: var(--blue); border-color: var(--blue) }
.role[aria-checked="true"] .box::after, .doc.has .box::after { content: ""; width: 10px; height: 6px; border-left: 2.2px solid #fff; border-bottom: 2.2px solid #fff; transform: rotate(-45deg) translate(1px, -1px) }

/* Chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px }
.chips button { border: 0; background: var(--fill); color: var(--label); border-radius: 999px; padding: 8px 14px; min-height: 40px; font-size: 15px; font-weight: 500; cursor: pointer }
.chips button[aria-pressed="true"] { background: var(--blue); color: #fff; font-weight: 600 }
.chips.days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px }
.chips.days button { padding: 8px 0; font-size: 14px }

.stack { display: flex; flex-direction: column; gap: 10px }

/* Documents */
.doc { position: relative; display: flex; align-items: center; gap: 14px; padding: 12px 16px; background: var(--card); min-height: 60px }
.doc + .doc::before { content: ""; position: absolute; top: 0; left: 54px; right: 0; border-top: .5px solid var(--sep) }
.doc.has .box { background: var(--green); border-color: var(--green) }
.doc-t { flex: 1; min-width: 0 }
.doc-t b { display: block; font-weight: 500 }
.doc-t span { display: block; font-size: 13px; color: var(--label2) }
.doc-t span.err { color: var(--red) }
.doc-t b .opt { display: inline; font-size: 13px }
.doc-files { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap }
.thumb { position: relative; width: 52px; height: 52px; border-radius: 8px; overflow: hidden; background: var(--fill); display: grid; place-items: center; font-size: 11px; font-weight: 700; color: var(--label2) }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block }
.thumb .x { position: absolute; top: 2px; right: 2px; width: 20px; height: 20px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .6); color: #fff; font-size: 13px; line-height: 1; cursor: pointer; display: grid; place-items: center; padding: 0 }
.thumb.busy::after { content: ""; position: absolute; inset: 0; background: rgba(255, 255, 255, .55) }
.thumb.failed { box-shadow: inset 0 0 0 2px var(--red) }
.doc-add { flex: none; border: 0; background: var(--fill); color: var(--blue); border-radius: 999px; padding: 8px 14px; min-height: 36px; font-size: 15px; font-weight: 600; cursor: pointer }
#w-docs.invalid .group { box-shadow: inset 0 0 0 1.5px var(--red) }

/* Jobs and references */
.jobs { display: flex; flex-direction: column; gap: 12px }
.job-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 16px 0; background: var(--card); font-size: 13px; font-weight: 600; color: var(--label2); text-transform: uppercase; letter-spacing: .03em }
.job-head .text-btn { font-size: 14px; text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--red) }

/* Validation */
.group-wrap.invalid > .group-title, .group-wrap.invalid .group-title { color: var(--red) }
.group-wrap.invalid .seg, .group-wrap.invalid .role-cards, .group-wrap.invalid .chips { box-shadow: inset 0 0 0 1.5px var(--red); border-radius: 10px }
.frow .ferr { font-size: 13px; color: var(--red) }
.bottom-err { margin: 0 0 8px; color: var(--red); font-size: 14px; text-align: center }
.sig { font-family: "Snell Roundhand", "Segoe Script", "Brush Script MT", cursive; font-size: 22px }
.steps .plain { margin: 0; color: var(--label) }
.steps a { color: var(--blue); text-decoration: none }

@media (max-width: 380px) { .chips.days button { font-size: 13px } }
