/* ===========================================================
   Rejoice Careers — shared design system (load before page CSS)
   Fonts: <link> Sora (600,700,800) + Inter (400,500,600,700)
   =========================================================== */

*, *::before, *::after { box-sizing: border-box; }

:root {
  --ink:      #0b1120;
  --ink-2:    #33415c;
  --muted:    #64748b;
  --faint:    #94a3b8;

  --bg:       #f6f7fb;
  --card:     #ffffff;
  --line:     #e6e9f2;
  --tint:     #eef0fb;

  --brand:    #4f46e5;
  --brand-2:  #7c3aed;
  --brand-deep: #1e1b4b;
  --accent:   #f59e0b;
  --success:  #059669;
  --danger:   #dc2626;

  --grad: linear-gradient(120deg, #4f46e5, #7c3aed);
  --grad-deep: linear-gradient(135deg, #111536 0%, #1e1b4b 55%, #312e81 100%);

  --radius:    18px;
  --radius-sm: 12px;
  --shadow:    0 10px 30px rgba(15, 23, 42, .08);
  --shadow-lg: 0 20px 50px rgba(30, 27, 75, .16);

  --font-head: 'Sora', system-ui, -apple-system, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
}

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.2; margin: 0 0 .5em; color: var(--ink); }
p  { margin: 0 0 1em; }
a  { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }

.container { width: min(1160px, 92%); margin-inline: auto; }

/* ----- Buttons ----- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font-family: var(--font-body); font-weight: 600; font-size: 1rem;
  padding: .8rem 1.7rem; border-radius: 999px; border: 0; cursor: pointer;
  text-decoration: none !important; transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
  line-height: 1.2;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 8px 20px rgba(79, 70, 229, .35); }
.btn-primary:hover { box-shadow: 0 12px 26px rgba(79, 70, 229, .45); transform: translateY(-1px); }
.btn-light  { background: #fff; color: var(--brand-deep); border: 1.5px solid var(--line); }
.btn-light:hover { border-color: var(--brand); color: var(--brand); }
.btn-ghost  { background: rgba(255,255,255,.12); color: #fff; border: 1.5px solid rgba(255,255,255,.35); }
.btn-ghost:hover { background: rgba(255,255,255,.2); }
.btn-sm { padding: .5rem 1.1rem; font-size: .9rem; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ----- Cards & chips ----- */
.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.chip {
  display: inline-flex; align-items: center; gap: .35rem;
  font-size: .8rem; font-weight: 600; padding: .28rem .75rem;
  border-radius: 999px; background: var(--tint); color: var(--brand-deep);
  white-space: nowrap;
}
.chip-amber { background: #fef3c7; color: #92400e; }
.chip-green { background: #d1fae5; color: #065f46; }

/* ----- Forms ----- */
label { font-weight: 600; font-size: .92rem; color: var(--ink-2); display: block; margin-bottom: .4rem; }
.req { color: var(--danger); }
input[type=text], input[type=tel], input[type=email], input[type=number],
input[type=date], input[type=url], input[type=password], select, textarea {
  width: 100%; font: inherit; color: var(--ink);
  padding: .72rem .95rem; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: #fff; outline: none; transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--brand); box-shadow: 0 0 0 4px rgba(79, 70, 229, .12);
}
textarea { min-height: 96px; resize: vertical; }
.field { margin-bottom: 1.15rem; }
.field .help { font-size: .82rem; color: var(--muted); margin-top: .35rem; }
.field .err { display: none; font-size: .82rem; color: var(--danger); margin-top: .35rem; font-weight: 600; }
.field.has-error .err { display: block; }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: var(--danger); }

/* pill-style radio / checkbox groups */
.optgroup { display: flex; flex-wrap: wrap; gap: .55rem; }
.optpill { position: relative; }
.optpill input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.optpill span {
  display: inline-block; padding: .5rem 1rem; border-radius: 999px;
  border: 1.5px solid var(--line); background: #fff; font-size: .9rem; font-weight: 500;
  color: var(--ink-2); cursor: pointer; transition: all .15s; user-select: none;
}
.optpill input:checked + span { background: var(--brand); border-color: var(--brand); color: #fff; }
.optpill input:focus-visible + span { box-shadow: 0 0 0 4px rgba(79, 70, 229, .18); }

/* ----- Utilities ----- */
.grid { display: grid; gap: 1.25rem; }
.text-center { text-align: center; }
.muted { color: var(--muted); }
.mt-1 { margin-top: .5rem; } .mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 2rem; }
.hidden { display: none !important; }

@media (max-width: 640px) {
  body { font-size: 15px; }
  .btn { padding: .75rem 1.4rem; }
}
