:root {
  color-scheme: light;
  --ink: #172a2d;
  --muted: #6e807e;
  --line: #e3eae5;
  --paper: #f5f7f4;
  --card: #fff;
  --jade: #187b67;
  --jade-deep: #126451;
  --jade-pale: #e5f3ee;
  --lime: #c4dc8c;
  --coral: #bd6253;
  --coral-pale: #fff0ed;
  --shadow: 0 18px 60px rgba(24, 48, 42, .075);
  font-family: "DM Sans", "Noto Sans Arabic", sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; color: var(--ink); background: var(--paper); font-family: "Noto Sans Arabic", "DM Sans", sans-serif; }
button { font: inherit; }
[hidden] { display: none !important; }
.topbar { height: 78px; padding: 0 clamp(20px, 5vw, 72px); display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(23, 42, 45, .07); background: rgba(255,255,255,.7); }
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; color: var(--ink); }
.brand-mark { width: 42px; height: 42px; border-radius: 14px; background: var(--jade-pale); display: grid; place-items: center; }
.brand-mark img { width: 28px; height: 28px; }
.brand strong { display: block; font-size: 14px; font-weight: 800; line-height: 1.5; }
.brand small { display: block; direction: ltr; text-align: right; color: var(--muted); font: 600 8px "DM Sans", sans-serif; letter-spacing: .14em; }
.share-button { display: inline-flex; align-items: center; gap: 8px; color: var(--jade-deep); background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 9px 14px; font-size: 13px; font-weight: 700; cursor: pointer; transition: border-color .2s, transform .2s; }
.share-button:hover { border-color: #a6cdbd; transform: translateY(-1px); }
.share-button svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.page-shell { width: min(100% - 32px, 780px); margin: 50px auto 28px; }
.panel { background: var(--card); border: 1px solid rgba(23,42,45,.07); border-radius: 25px; box-shadow: var(--shadow); }
.intro-panel { position: relative; overflow: hidden; padding: clamp(30px, 7vw, 68px); min-height: 465px; background: radial-gradient(circle at 91% 8%, rgba(196,220,140,.32), transparent 28%), linear-gradient(145deg, #fff 45%, #f5faf6 100%); }
.intro-panel::after { content: ""; position: absolute; width: 190px; height: 190px; border: 1px solid rgba(24,123,103,.09); border-radius: 50%; left: -86px; bottom: -110px; box-shadow: 0 0 0 25px rgba(24,123,103,.025), 0 0 0 50px rgba(24,123,103,.02); pointer-events: none; }
.eyebrow { display: flex; align-items: center; gap: 9px; color: var(--jade); font-size: 12px; font-weight: 700; letter-spacing: .01em; }
.eyebrow-dot { width: 8px; height: 8px; border-radius: 50%; background: #8bbb69; box-shadow: 0 0 0 4px #eaf4df; }
h1 { font-size: clamp(34px, 6vw, 52px); line-height: 1.35; letter-spacing: -.04em; margin: 25px 0 13px; font-weight: 800; }
.intro-panel h1 span { color: var(--jade); }
.intro-copy { max-width: 530px; margin: 0; color: var(--muted); font-size: 15px; line-height: 1.95; }
.facts-row { display: flex; align-items: center; gap: 21px; margin: 31px 0 28px; }
.fact { display: flex; flex-direction: column; gap: 3px; color: var(--muted); font-size: 11px; }
.fact-number { color: var(--ink); font: 700 14px "DM Sans", sans-serif; direction: ltr; }
.fact-divider { width: 1px; height: 29px; background: var(--line); }
.primary-button, .secondary-button { min-height: 48px; padding: 0 20px; border-radius: 12px; font-size: 13px; font-weight: 700; cursor: pointer; transition: background .2s, transform .2s, box-shadow .2s; }
.primary-button { display: inline-flex; align-items: center; justify-content: center; gap: 13px; border: 1px solid var(--jade); color: #fff; background: var(--jade); box-shadow: 0 7px 17px rgba(24,123,103,.14); }
.primary-button:hover:not(:disabled) { background: var(--jade-deep); transform: translateY(-1px); box-shadow: 0 9px 21px rgba(24,123,103,.2); }
.primary-button:disabled { cursor: not-allowed; color: #97aaa4; border-color: #d9e3dd; background: #edf1ed; box-shadow: none; }
.secondary-button { color: var(--ink); border: 1px solid var(--line); background: #fff; }
.secondary-button:hover:not(:disabled) { border-color: #afcfc2; background: #f8fbf9; }
.secondary-button:disabled { color: #a5b0ad; cursor: not-allowed; background: #fafbfa; }
.start-button { min-width: 175px; }
.privacy-note { margin: 13px 0 0; color: #8a9996; font-size: 10px; }
.quiz-panel { padding: clamp(23px, 5vw, 43px); }
.quiz-topline { display: flex; align-items: center; justify-content: space-between; gap: 15px; color: var(--muted); font-size: 12px; font-weight: 600; }
.question-counter { color: var(--ink); }
.completion-label { direction: ltr; font: 600 11px "DM Sans", sans-serif; }
.progress-track { overflow: hidden; height: 6px; margin-top: 15px; border-radius: 8px; background: #ecf1ed; }
.progress-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--jade), #82b86e); transition: width .35s ease; }
.question-area { padding: 34px 0 26px; }
.question-label { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 11px; }
.question-index { color: var(--jade); font: 700 12px "DM Sans", sans-serif; }
.question-text { direction: ltr; text-align: left; font: 700 clamp(19px, 3.6vw, 25px)/1.5 "DM Sans", sans-serif; letter-spacing: -.025em; margin: 18px 0 25px; }
.options-list { display: flex; flex-direction: column; gap: 10px; }
.option { direction: ltr; text-align: left; width: 100%; min-height: 62px; padding: 10px 15px; display: flex; align-items: center; gap: 14px; border: 1px solid var(--line); border-radius: 13px; color: var(--ink); background: #fff; cursor: pointer; transition: background .18s, border-color .18s, transform .18s; }
.option:hover { border-color: #a9cdbf; background: #fbfdfb; transform: translateX(-2px); }
.option.selected { border-color: var(--jade); background: #f2f9f5; box-shadow: 0 0 0 2px rgba(24,123,103,.08); }
.option-letter { width: 32px; height: 32px; flex: 0 0 32px; border: 1px solid #e5ebe7; border-radius: 10px; display: grid; place-items: center; color: #647672; background: #f8faf8; font: 700 12px "DM Sans", sans-serif; }
.option.selected .option-letter { color: #fff; border-color: var(--jade); background: var(--jade); }
.option-text { flex: 1; font: 500 14px/1.6 "DM Sans", sans-serif; }
.option-check { width: 18px; height: 18px; border: 1px solid #dce5df; border-radius: 50%; }
.option.selected .option-check { border: 5px solid var(--jade); background: #fff; }
.quiz-navigation { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 21px; border-top: 1px solid #edf1ee; }
.save-hint { flex: 1; text-align: center; color: #899894; font-size: 10px; }
.next-button { min-width: 113px; }
.result-panel { padding: clamp(24px, 5vw, 44px); }
.result-heading { text-align: center; }
.result-kicker { color: var(--jade); font-size: 11px; font-weight: 800; }
.result-heading h1 { margin: 10px 0 4px; font-size: clamp(28px, 5vw, 38px); }
.result-heading p { margin: 0; color: var(--muted); font-size: 13px; }
.score-card { width: min(100%, 370px); margin: 25px auto 21px; padding: 19px; border: 1px solid #e8efea; border-radius: 18px; background: linear-gradient(130deg, #fbfdfb, #f4f9f5); display: flex; justify-content: center; align-items: center; gap: 22px; }
.score-ring { --score: 0%; width: 104px; height: 104px; display: grid; place-items: center; border-radius: 50%; background: conic-gradient(var(--jade) var(--score), #e2ebe5 var(--score)); position: relative; }
.score-ring::before { content: ""; position: absolute; inset: 7px; border-radius: 50%; background: #fff; }
.score-ring span { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.score-ring strong { font: 700 24px "DM Sans", sans-serif; color: var(--jade-deep); }
.score-ring small { color: var(--muted); font-size: 9px; }
.score-details { display: flex; flex-direction: column; gap: 5px; color: var(--muted); font-size: 12px; }
.score-details strong { color: var(--ink); font: 700 21px "DM Sans", sans-serif; }
.result-actions { display: flex; gap: 10px; justify-content: center; margin: 0 0 31px; }
.review-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.review-heading h2 { margin: 0; font-size: 17px; }
.review-heading span { color: var(--muted); font-size: 10px; }
.review-list { display: flex; flex-direction: column; gap: 11px; list-style: none; margin: 15px 0 0; padding: 0; }
.review-item { padding: 16px; border: 1px solid var(--line); border-right: 3px solid #91bca7; border-radius: 12px; background: #fff; }
.review-item.review-incorrect { border-right-color: #d98171; }
.review-top { display: flex; align-items: center; justify-content: space-between; color: var(--jade); font-size: 10px; font-weight: 700; }
.review-incorrect .review-top { color: var(--coral); }
.review-number { font: 700 11px "DM Sans", sans-serif; }
.review-question { margin: 10px 0 12px; color: var(--ink); font: 700 14px/1.6 "DM Sans", sans-serif; text-align: left; }
.review-answers { display: grid; gap: 6px; padding: 10px 11px; border-radius: 9px; background: #f8faf8; }
.review-answers p { margin: 0; color: #71817d; font-size: 10px; line-height: 1.65; }
.review-answers span, .review-explanation { font: 500 12px/1.65 "DM Sans", sans-serif; }
.review-answers .correct-answer { color: var(--jade-deep); font-weight: 700; }
.review-incorrect .your-answer { color: var(--coral); }
.review-explanation { margin: 9px 0 0; color: #6a7d77; text-align: left; }
.page-footer { display: flex; justify-content: space-between; gap: 12px; padding: 18px 4px; color: #8a9995; font-size: 9px; }
.toast { position: fixed; bottom: 24px; left: 50%; z-index: 5; transform: translate(-50%, 12px); opacity: 0; pointer-events: none; background: var(--ink); color: #fff; border-radius: 11px; padding: 11px 16px; font-size: 12px; transition: opacity .2s, transform .2s; }
.toast.visible { opacity: 1; transform: translate(-50%, 0); }
button:focus-visible, a:focus-visible { outline: 3px solid #85bda8; outline-offset: 3px; }
@media (max-width: 560px) {
  .topbar { height: 68px; padding: 0 16px; }
  .page-shell { width: calc(100% - 22px); margin: 22px auto 18px; }
  .panel { border-radius: 19px; }
  .intro-panel { min-height: auto; padding: 28px 22px 30px; }
  .intro-copy { font-size: 13px; }
  .facts-row { gap: 14px; }
  .fact { font-size: 9px; }
  .quiz-panel, .result-panel { padding: 21px 16px; }
  .question-area { padding-top: 27px; }
  .option { min-height: 58px; gap: 10px; padding: 9px 10px; }
  .option-text { font-size: 13px; }
  .quiz-navigation { flex-wrap: wrap; }
  .save-hint { order: 3; flex-basis: 100%; }
  .result-actions { flex-wrap: wrap; }
  .result-actions button { flex: 1; min-width: 140px; }
  .page-footer { font-size: 8px; }
}
