﻿:root {
  color-scheme: light;
  --bg: #f6efe4;
  --surface: rgba(255, 251, 245, 0.9);
  --surface-strong: #fffaf2;
  --surface-soft: #f3ede4;
  --text: #1f1b16;
  --muted: #6f6252;
  --line: rgba(91, 72, 43, 0.16);
  --line-strong: rgba(91, 72, 43, 0.28);
  --brand: #c86b3c;
  --brand-dark: #9f4f27;
  --accent: #264653;
  --success: #1f6f50;
  --danger: #9f2d2d;
  --shadow: 0 24px 60px rgba(73, 49, 24, 0.14);
  --shadow-soft: 0 10px 24px rgba(73, 49, 24, 0.08);
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(200, 107, 60, 0.22), transparent 32%),
    radial-gradient(circle at bottom right, rgba(38, 70, 83, 0.16), transparent 24%),
    linear-gradient(180deg, #f6efe4 0%, #fbf8f2 100%);
}

button,
input,
select { font: inherit; }

body[dir="rtl"] { font-family: "Tahoma", "Segoe UI", sans-serif; }

.shell { width: min(1180px, calc(100% - 32px)); margin: 0 auto; padding: 48px 0 64px; }
.hero { margin-bottom: 28px; }
.hero-top { display: flex; justify-content: space-between; gap: 24px; align-items: start; }
.hero-top > div:first-child { max-width: 760px; }

.eyebrow,
.section-label,
.question-step {
  margin: 0;
  color: var(--brand-dark);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.78rem;
  font-weight: 700;
}

body[dir="rtl"] .eyebrow,
body[dir="rtl"] .section-label,
body[dir="rtl"] .question-step { letter-spacing: 0; }

.hero h1,
.quiz-head h2,
.result-title,
.signup-head h2 { margin: 10px 0 0; line-height: 1.02; }
.hero h1 { font-size: clamp(2.4rem, 4vw, 4.7rem); max-width: 12ch; }

.lead,
.intro-copy,
.result-summary,
.jobs-head p,
.job-card p:last-child,
.option-copy,
.result-list,
.form-status,
.success-note { color: var(--muted); line-height: 1.6; }

.language-picker {
  display: grid;
  gap: 8px;
  min-width: 170px;
  color: var(--brand-dark);
  font-weight: 700;
}

.language-picker select {
  border: 1px solid var(--line);
  background: var(--surface-strong);
  color: var(--text);
  border-radius: 16px;
  padding: 12px 14px;
}

.platform { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 24px; align-items: start; }

.intro-card,
.quiz-card,
.result-card,
.signup-card {
  border: 1px solid var(--line);
  background: var(--surface);
  backdrop-filter: blur(14px);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.intro-card { padding: 24px; position: sticky; top: 20px; }
.stat { display: grid; gap: 2px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.stat:first-child { padding-top: 0; }
.stat:last-of-type { border-bottom: 0; }
.stat-value { font-size: 2rem; font-weight: 700; }
.stat-label { color: var(--muted); }
.quiz-card { padding: 28px; }
.quiz-head,
.quiz-actions,
.question-top,
.jobs-head { display: flex; justify-content: space-between; gap: 16px; align-items: start; }
.progress-wrap { width: 100%; height: 12px; margin: 22px 0 26px; border-radius: 999px; background: rgba(38, 70, 83, 0.1); overflow: hidden; }
.progress-bar { width: 0; height: 100%; background: linear-gradient(90deg, var(--accent), var(--brand)); border-radius: inherit; transition: width 240ms ease; }
[data-quiz] { display: grid; gap: 18px; }
.question-card,
.result-panel,
.job-card { border: 1px solid var(--line); background: var(--surface-strong); border-radius: 22px; }
.question-card { padding: 20px; }
.question-title,
.result-panel h3,
.jobs-panel h3,
.job-card h4 { margin: 8px 0 0; }
.options { display: grid; gap: 12px; margin-top: 18px; }
.option { position: relative; }
.option input { position: absolute; opacity: 0; pointer-events: none; }
.option label { display: block; padding: 16px 18px; border: 1px solid var(--line); border-radius: 18px; cursor: pointer; transition: transform 180ms ease, border-color 180ms ease, background 180ms ease; }
.option label:hover { transform: translateY(-2px); border-color: rgba(200, 107, 60, 0.45); }
.option input:checked + label { border-color: var(--brand); background: rgba(200, 107, 60, 0.08); }
.option-title { display: block; font-weight: 700; }

.ghost-button,
.secondary-button,
.primary-button {
  border-radius: 999px;
  padding: 11px 16px;
  cursor: pointer;
  border: 1px solid var(--line);
  color: var(--text);
}

.ghost-button,
.secondary-button { background: transparent; }
.primary-button {
  background: linear-gradient(135deg, var(--brand), #b7562a);
  color: #fffaf2;
  border-color: transparent;
  box-shadow: var(--shadow-soft);
}

.quiz-actions { margin-top: 22px; }
[data-output] { margin-top: 28px; }
.signup-card,
.result-card { padding: 28px; }
.signup-head { margin-bottom: 20px; }
.signup-form { display: grid; gap: 22px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 20px; }

.form-field {
  display: grid;
  gap: 10px;
}

.field-label {
  font-size: 0.95rem;
  font-weight: 800;
  color: #241f18;
}

.field-control,
.select-shell {
  width: 100%;
}

.field-control {
  appearance: none;
  min-height: 58px;
  border-radius: 18px;
  border: 1px solid rgba(116, 93, 58, 0.18);
  background: linear-gradient(180deg, #f9f4ec 0%, #f4ede4 100%);
  color: var(--text);
  padding: 0 18px;
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.field-control::placeholder {
  color: #857765;
}

.field-control:hover {
  border-color: var(--line-strong);
}

.field-control:focus {
  border-color: rgba(200, 107, 60, 0.9);
  box-shadow: 0 0 0 4px rgba(200, 107, 60, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.field-control-select {
  padding-inline-end: 52px;
  cursor: pointer;
}

.select-shell {
  position: relative;
  display: block;
}

.select-shell::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 18px;
  width: 12px;
  height: 12px;
  border-right: 2px solid var(--brand-dark);
  border-bottom: 2px solid var(--brand-dark);
  transform: translateY(-60%) rotate(45deg);
  pointer-events: none;
}

body[dir="rtl"] .select-shell::after {
  right: auto;
  left: 18px;
}

.field-control-date::-webkit-calendar-picker-indicator {
  opacity: 0.85;
  cursor: pointer;
}

.form-status:empty,
.success-note:empty { display: none; }
.form-status.is-error { color: var(--danger); }
.form-status.is-success,
.success-note { color: var(--success); }

.result-grid,
.jobs-grid { display: grid; gap: 18px; }
.result-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 24px; }
.result-panel,
.jobs-panel { padding: 20px; }
.result-list { margin: 16px 0 0; padding-left: 18px; }
body[dir="rtl"] .result-list { padding-left: 0; padding-right: 18px; }
.jobs-panel { margin-top: 18px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface-strong); }
.jobs-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 18px; }
.job-card { padding: 18px; }
.job-sector { margin: 0; color: var(--brand-dark); font-size: 0.85rem; font-weight: 700; }

@media (max-width: 980px) {
  .platform { grid-template-columns: 1fr; }
  .intro-card { position: static; }
  .jobs-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
  .shell { width: min(100% - 20px, 100%); padding: 24px 0 40px; }
  .hero-top,
  .quiz-head,
  .quiz-actions,
  .jobs-head,
  .result-grid,
  .form-grid { display: grid; }
  .quiz-card,
  .result-card,
  .intro-card,
  .signup-card { padding: 20px; border-radius: 22px; }
  .jobs-grid { grid-template-columns: 1fr; }
}
