/* Terverra careers — palette lifted from the recruitment poster:
   off-white canvas, deep red accent, Tajawal throughout. */
:root {
  --bg: #FBF7F5;
  --ink: #241012;
  --ink-soft: #5C4A4D;
  --muted: #8A7275;
  --brand: #8C1D2C;
  --brand-dark: #6E1522;
  --line: rgba(36, 16, 18, .10);
  --brand-line: rgba(140, 29, 44, .22);
  --card: #FFFFFF;
  --radius: 20px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Tajawal', system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* Workshop-floor diagonal stripes — the poster's texture, kept very faint. */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -2;
  background: repeating-linear-gradient(
    -45deg, rgba(140, 29, 44, .04) 0 2px, transparent 2px 26px);
}
body::after {
  content: "";
  position: fixed; z-index: -1;
  width: 700px; height: 700px; border-radius: 50%;
  top: -300px; inset-inline-start: -240px;
  background: radial-gradient(circle, rgba(140, 29, 44, .13) 0%, transparent 70%);
}

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { width: min(1080px, 92vw); margin-inline: auto; }
.narrow { width: min(760px, 92vw); }

/* --- top bar --- */
.topbar {
  border-bottom: 1px solid var(--line);
  background: rgba(251, 247, 245, .88);
  backdrop-filter: blur(8px);
  position: sticky; top: 0; z-index: 20;
}
.topbar .wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 0; gap: 16px;
}
.brand { font-weight: 900; font-size: 22px; letter-spacing: -.3px; color: var(--ink); }
.brand span { color: var(--brand); }
.topbar nav { display: flex; align-items: center; gap: 18px; font-size: 15px; }
.topbar nav a { color: var(--muted); font-weight: 500; }
.topbar nav a:hover { color: var(--brand); text-decoration: none; }

/* --- hero --- */
.hero { padding: 64px 0 8px; }
.kicker {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 20px; border-radius: 999px;
  background: rgba(140, 29, 44, .07);
  border: 1px solid rgba(140, 29, 44, .28);
  color: var(--brand); font-size: 15px; font-weight: 700;
}
.kicker i { width: 8px; height: 8px; border-radius: 50%; background: var(--brand); }

h1 {
  font-size: clamp(38px, 7vw, 68px);
  line-height: 1.15; font-weight: 900; letter-spacing: -1.5px;
  margin-top: 22px;
}
h1 em { font-style: normal; color: var(--brand); }

.lead {
  font-size: clamp(17px, 2.4vw, 21px);
  color: var(--ink-soft); max-width: 640px; margin-top: 18px;
}

.meta-row {
  display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px;
}
.chip {
  padding: 7px 16px; border-radius: 999px;
  background: #fff; border: 1px solid var(--line);
  font-size: 15px; font-weight: 600; color: var(--ink-soft);
}

.must {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin-top: 26px; padding: 16px 24px; border-radius: 14px;
  background: var(--brand); color: #FFF6F2;
}
.must b { font-size: 19px; font-weight: 800; }
.must span { font-size: 17px; opacity: .93; }

/* --- sections --- */
section { padding: 44px 0; }
.label {
  font-size: 14px; font-weight: 800; color: var(--muted);
  letter-spacing: 1.4px; margin-bottom: 18px;
}
h2 { font-size: clamp(24px, 4vw, 32px); font-weight: 900; letter-spacing: -.6px; }

.reqs { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 30px; list-style: none; }
.reqs li {
  display: flex; align-items: flex-start; gap: 11px;
  font-size: 17px; font-weight: 500; color: #33191D;
}
.reqs svg { flex: 0 0 auto; margin-top: 7px; }

.note {
  padding: 20px 24px; border-radius: 16px;
  background: rgba(140, 29, 44, .06);
  border-inline-start: 4px solid var(--brand);
  font-size: 17px; color: #6B3B41; font-weight: 500;
}

/* --- form --- */
.form-card {
  background: var(--card); border: 1px solid var(--brand-line);
  border-radius: var(--radius); padding: 34px;
  box-shadow: 0 14px 40px rgba(140, 29, 44, .07);
}
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 24px; }
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }
.field > label, .field-title {
  font-size: 15px; font-weight: 700; color: var(--ink);
}
.req-star { color: var(--brand); }
.hint { font-size: 13px; color: var(--muted); font-weight: 400; }

.input {
  width: 100%; padding: 12px 15px; font-family: inherit; font-size: 16px;
  color: var(--ink); background: #fff;
  border: 1px solid var(--line); border-radius: 12px;
  transition: border-color .15s, box-shadow .15s;
}
.input:focus {
  outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(140, 29, 44, .12);
}
select.input { appearance: none; background-image: none; cursor: pointer; }
textarea.input { resize: vertical; min-height: 84px; }
input[type="file"].input { padding: 10px 14px; font-size: 14px; cursor: pointer; }

/* Radio groups render as tappable cards — better on a phone than bare dots. */
.field ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.field ul.inline { flex-direction: row; flex-wrap: wrap; }
.field ul li { flex: 1 1 auto; }
.field ul label {
  display: flex; align-items: center; gap: 11px; cursor: pointer;
  padding: 13px 17px; border-radius: 12px;
  background: #fff; border: 1px solid var(--line);
  font-size: 16px; font-weight: 500; color: var(--ink-soft);
  transition: border-color .15s, background .15s, color .15s;
}
.field ul label:hover { border-color: var(--brand-line); }
.field ul input[type="radio"] { accent-color: var(--brand); width: 18px; height: 18px; }
.field ul input[type="radio"]:checked + span,
.field ul label:has(input:checked) { color: var(--brand); border-color: var(--brand); font-weight: 700; }

.consent {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 18px 20px; border-radius: 14px;
  background: rgba(140, 29, 44, .05); border: 1px solid var(--brand-line);
  font-size: 15px; color: var(--ink-soft); margin-top: 6px;
}
.consent input[type="checkbox"] {
  accent-color: var(--brand); width: 19px; height: 19px;
  margin-top: 3px; flex: 0 0 auto; cursor: pointer;
}
.consent label { cursor: pointer; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 15px 38px; border: 0; border-radius: 14px; cursor: pointer;
  background: var(--brand); color: #FFF6F2;
  font-family: inherit; font-size: 18px; font-weight: 800;
  transition: background .15s, transform .1s;
}
.btn:hover { background: var(--brand-dark); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn.block { width: 100%; }
.btn.ghost {
  background: #fff; color: var(--brand); border: 1px solid var(--brand-line);
  font-size: 15px; font-weight: 700; padding: 10px 22px;
}
.btn.ghost:hover { background: rgba(140, 29, 44, .06); }

.errors {
  list-style: none; color: var(--brand); font-size: 14px; font-weight: 600;
}
.form-error {
  padding: 14px 20px; border-radius: 12px; margin-bottom: 22px;
  background: rgba(140, 29, 44, .09); border: 1px solid var(--brand-line);
  color: var(--brand-dark); font-weight: 600; font-size: 15px;
}

/* --- thanks --- */
.center-card {
  text-align: center; padding: 70px 0;
}
.tick {
  width: 84px; height: 84px; border-radius: 50%;
  background: rgba(140, 29, 44, .09);
  display: inline-flex; align-items: center; justify-content: center;
  margin-bottom: 24px;
}

/* --- dashboard --- */
.stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; }
.stat {
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  padding: 18px 20px; display: block;
}
.stat:hover { border-color: var(--brand-line); text-decoration: none; }
.stat.on { border-color: var(--brand); background: rgba(140, 29, 44, .04); }
.stat b { display: block; font-size: 30px; font-weight: 900; color: var(--ink); line-height: 1.2; }
.stat span { display: block; font-size: 14px; color: var(--muted); font-weight: 600; }

.toolbar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  margin: 26px 0 18px;
}
.toolbar .input { width: auto; flex: 1 1 240px; padding: 10px 14px; font-size: 15px; }

.table-wrap {
  background: #fff; border: 1px solid var(--line);
  border-radius: 16px; overflow: hidden;
}
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th {
  text-align: right; padding: 13px 16px; font-size: 13px; font-weight: 800;
  color: var(--muted); letter-spacing: .5px;
  background: rgba(140, 29, 44, .04); border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
td { padding: 13px 16px; border-bottom: 1px solid var(--line); color: var(--ink-soft); }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: rgba(140, 29, 44, .03); }
td a { font-weight: 700; }

.pill {
  display: inline-block; padding: 3px 12px; border-radius: 999px;
  font-size: 13px; font-weight: 700; white-space: nowrap;
}
.pill.yes { background: rgba(29, 120, 60, .10); color: #1D783C; }
.pill.no { background: rgba(140, 29, 44, .10); color: var(--brand); }
.pill.neutral { background: rgba(36, 16, 18, .07); color: var(--ink-soft); }

.empty { padding: 60px 20px; text-align: center; color: var(--muted); }

.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; }
.detail-grid dt {
  font-size: 13px; font-weight: 800; color: var(--muted);
  letter-spacing: .4px; margin-top: 18px;
}
.detail-grid dd { font-size: 17px; color: var(--ink); font-weight: 600; }

footer.site {
  margin-top: 40px; padding: 26px 0;
  border-top: 1px solid var(--line);
  font-size: 14px; color: var(--muted);
  display: flex; flex-wrap: wrap; gap: 10px;
  align-items: center; justify-content: space-between;
}

@media (max-width: 760px) {
  .grid-2, .reqs, .detail-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .form-card { padding: 22px; }
  .hero { padding: 40px 0 0; }
  .field ul.inline { flex-direction: column; }
  .table-wrap { overflow-x: auto; }
  table { min-width: 720px; }
}
