/* Careers page: list, role detail sheet, application form. Mobile first; desktop from "AAKRI Careers". */

/* ───────────── List ───────────── */
.jobs { padding: 40px var(--gutter) 64px; }
.jobs[hidden], .role-view[hidden] { display: none; }
.jobs__head { display: flex; flex-direction: column; gap: 12px; }
.jobs__head h1 { font-size: clamp(30px, 4.4vw, 44px); line-height: 1.15; font-weight: 500; letter-spacing: -0.01em; }
.jobs__head p { font-size: 15px; line-height: 1.6; color: var(--text-secondary); }
.jobs__tools { margin-top: 28px; }
.jobs__search { position: relative; display: flex; align-items: center; }
.jobs__search svg { position: absolute; left: 16px; width: 18px; height: 18px; color: var(--text-disabled); pointer-events: none; }
.jobs__search input {
  width: 100%; min-height: 54px; padding: 0 16px 0 42px; border-radius: 27px;
  border: 1px solid var(--divider); background: var(--bg-paper); color: var(--text); font-size: 15px; outline: none;
  -webkit-appearance: none; appearance: none;
}
.jobs__search input:focus { border-color: var(--lime); }
.jobs__search input::placeholder { color: var(--text-disabled); }
.jobs__list { margin: 32px 0 0; padding: 0; list-style: none; border-top: 1px solid var(--divider); }
.jobs__list li[hidden] { display: none; }
.job-row {
  display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px 24px; align-items: center;
  padding: 24px 0; border-bottom: 1px solid var(--divider);
  color: var(--text); text-decoration: none; transition: background-color 0.2s ease;
}
.job-row:hover { background: rgba(255, 255, 255, 0.03); color: var(--text); }
.job-row__main { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.job-row__title { font-size: 17px; line-height: 1.3; font-weight: 600; }
.job-row__dept { font-size: 13px; color: var(--text-secondary); }
.job-row__tags { display: flex; flex-wrap: wrap; gap: 8px; }
.job-row__cta { display: none; justify-self: end; font-size: 14px; font-weight: 600; color: var(--lime); white-space: nowrap; }
.tag {
  min-height: 28px; padding: 0 12px; border-radius: 999px; background: rgba(255, 255, 255, 0.05);
  display: inline-flex; align-items: center; font-size: 12px; font-weight: 500; color: var(--text-secondary);
}
.tag--lg { min-height: 30px; font-size: 13px; font-weight: 400; color: var(--text-secondary); }
.jobs__empty { padding: 40px 0; text-align: center; font-size: 15px; color: var(--text-secondary); }

.jobs__general {
  margin-top: 32px; padding: 24px 28px; border-radius: 24px; background: var(--surface); border: 1px solid var(--border);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px;
}
.jobs__general > div { display: flex; flex-direction: column; gap: 4px; }
.jobs__general-title { font-size: 17px; font-weight: 600; }
.jobs__general-text { font-size: 14px; color: var(--text-secondary); }
.jobs__general-btn { min-height: 46px; padding: 0 22px; font-size: 14px; background: transparent; cursor: pointer; border: 1px solid var(--divider); }

@media (min-width: 640px) {
  .jobs__head p { font-size: 18px; }
  .job-row__title { font-size: 19px; }
}
@media (min-width: 1024px) {
  .jobs { padding: 72px 24px 104px; }
  .job-row { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) auto; }
  .job-row__cta { display: block; }
}

/* ───────────── Application form popup (bottom sheet on mobile) ───────────── */
.overlay {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(4, 6, 3, 0.72); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  display: flex; align-items: flex-end; justify-content: center;
}
.overlay[hidden] { display: none; }
.sheet {
  position: relative; width: 100%; max-height: 92vh; max-height: 92dvh; overflow-y: auto; overscroll-behavior: contain;
  background: var(--bg-elevated); border: 1px solid var(--divider); border-radius: 24px 24px 0 0;
  padding: 24px 20px 28px;
}
.sheet[hidden] { display: none; }
.sheet__close {
  position: sticky; top: 0; float: right; z-index: 2; margin: -4px -4px 0 12px;
  width: 44px; height: 44px; border-radius: 22px; border: 1px solid var(--divider);
  background: var(--bg-elevated); color: var(--text); font-size: 20px; line-height: 1; cursor: pointer;
}
.sheet__close--inline { position: static; float: none; margin: 0; flex: none; }
@media (min-width: 640px) {
  .overlay { align-items: center; padding: 24px; }
  .sheet { max-height: 90vh; border-radius: 24px; padding: 32px; }
}
@media (prefers-reduced-motion: no-preference) {
  .overlay:not([hidden]) { animation: overlay-in 0.2s ease-out; }
  .overlay:not([hidden]) .sheet { animation: sheet-in 0.3s var(--ease-out); }
}
@keyframes overlay-in { from { opacity: 0; } }
@keyframes sheet-in { from { transform: translateY(24px); opacity: 0; } }

/* ───────────── Role detail page ───────────── */
.role-view { padding: 24px var(--gutter) 64px; }
.role-view__back {
  min-height: 44px; display: inline-flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 500; color: var(--text-secondary); text-decoration: none;
}
.role-view__back:hover { color: var(--text); }
.role-page { margin-top: 16px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; align-items: start; }
.role-page[hidden] { display: none; }
.role-page__main { min-width: 0; display: flex; flex-direction: column; }
.role-page h1 { margin-top: 14px; font-size: 30px; line-height: 1.15; font-weight: 500; letter-spacing: -0.01em; outline: none; }
.role-page__tags { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 8px; }
.role-page__about { margin-top: 28px; font-size: 16px; line-height: 1.7; color: var(--text-secondary); }
.role-page h2 { margin-top: 32px; font-size: 19px; font-weight: 600; }
.role-page__about + h2 { margin-top: 36px; }
.dot-list { margin: 14px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.dot-list li { position: relative; padding-left: 17px; font-size: 15px; line-height: 1.6; color: var(--text-secondary); }
.dot-list li::before { content: ''; position: absolute; left: 0; top: 10px; width: 5px; height: 5px; border-radius: 50%; background: var(--lime); }
.role-page__aside {
  position: relative; padding: 28px; border-radius: 24px; background: var(--surface); border: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 16px;
}
.role-page__aside-title { font-size: 17px; font-weight: 600; }
.role-page__aside-text { font-size: 14px; line-height: 1.6; color: var(--text-secondary); }
@media (min-width: 1024px) {
  .role-view { padding: 48px 24px 104px; }
  .role-page { margin-top: 20px; grid-template-columns: minmax(0, 1fr) 340px; gap: 40px clamp(40px, 5vw, 80px); }
  .role-page h1 { font-size: 44px; }
  .role-page__aside { position: sticky; top: 100px; }
}

.btn-lime, .btn-ghost {
  min-height: 50px; padding: 0 24px; border-radius: 999px; border: 0; cursor: pointer;
  font-size: 15px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}
.btn-lime { background: var(--lime); color: var(--on-lime); }
.btn-lime:hover { background: var(--lime-hover); }
.btn-lime--lg { min-height: 52px; font-size: 16px; }
.btn-ghost { min-height: 46px; font-size: 14px; background: transparent; color: var(--text); border: 1px solid var(--divider); }
.btn-ghost:hover { border-color: var(--lime); }

/* Application form */
.apply-sheet { max-width: 620px; }
.apply-sheet__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.apply-sheet__head > div { display: flex; flex-direction: column; gap: 6px; }
.apply-sheet__head .pg-eyebrow { letter-spacing: 0.14em; }
.apply-sheet__title { font-size: 22px; line-height: 1.3; font-weight: 600; }
.apply-form { margin-top: 24px; display: flex; flex-direction: column; gap: 16px; }
.apply-form__row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
@media (min-width: 640px) { .apply-form__row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.field__label { font-size: 13px; font-weight: 600; color: var(--text-secondary); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: 0 14px; border-radius: 12px;
  border: 1px solid var(--divider); background: var(--bg-2); color: var(--text); font-size: 15px; outline: none;
}
.field select { padding: 0 12px; }
.field textarea { padding: 12px 14px; line-height: 1.5; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--lime); }
.field input::placeholder, .field textarea::placeholder { color: var(--text-disabled); }
.field.is-invalid input, .field.is-invalid select { border-color: var(--error); }
.field__err { font-size: 12px; color: var(--error); }
.field__err:empty { display: none; }
.field__err--consent { margin-top: -8px; }
.file-drop {
  display: flex; align-items: center; gap: 14px; min-height: 56px; padding: 12px 14px; border-radius: 12px;
  border: 1px dashed var(--divider); background: var(--bg-2); cursor: pointer; transition: border-color 0.2s ease;
}
.file-drop:hover, .file-drop:focus-within { border-color: var(--lime); }
.field.is-invalid .file-drop { border-color: var(--error); }
.file-drop svg { width: 22px; height: 22px; flex: none; color: var(--lime); }
.file-drop__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.file-drop__name { font-size: 14px; font-weight: 500; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-drop__hint { font-size: 12px; color: var(--text-secondary); }
.consent { display: flex; align-items: flex-start; gap: 12px; cursor: pointer; font-size: 13px; line-height: 1.55; color: var(--text-secondary); }
.consent input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--lime); flex: none; }
.apply-form .btn-lime { margin-top: 4px; }
.apply-form .btn-lime[disabled] { opacity: 0.6; cursor: progress; }

.apply-done { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 16px; padding: 24px 0; }
.apply-done[hidden] { display: none; }
.apply-done__icon { width: 64px; height: 64px; border-radius: 50%; background: rgba(var(--primary-rgb), 0.12); color: var(--lime); display: flex; align-items: center; justify-content: center; }
.apply-done__icon svg { width: 28px; height: 28px; }
.apply-done__title { font-size: 22px; font-weight: 600; }
.apply-done__text { max-width: 380px; font-size: 15px; line-height: 1.6; color: var(--text-secondary); }
.apply-done .btn-outline { margin-top: 8px; min-height: 48px; padding: 0 28px; font-size: 15px; background: transparent; cursor: pointer; }
